feat(channels): add google chat adapter and webhook route

This commit is contained in:
William Valentin
2026-02-16 02:07:55 -08:00
parent 51ff5523ae
commit 693dcd8421
15 changed files with 463 additions and 3 deletions
+24
View File
@@ -375,6 +375,30 @@ describe('configSchema — teams', () => {
});
});
describe('configSchema — google_chat', () => {
const minimalConfig = {
telegram: { bot_token: 'test', allowed_chat_ids: [1] },
models: { default: { provider: 'anthropic', model: 'claude-3' } },
};
it('accepts google_chat config and defaults filters', () => {
const result = configSchema.parse({
...minimalConfig,
google_chat: {
service_account_key_file: '/tmp/gchat-service-account.json',
},
});
expect(result.google_chat).toBeDefined();
if (!result.google_chat) {
throw new Error('Expected google_chat config');
}
expect(result.google_chat.service_account_key_file).toBe('/tmp/gchat-service-account.json');
expect(result.google_chat.allowed_space_names).toEqual([]);
expect(result.google_chat.require_mention).toBe(true);
});
});
describe('configSchema — whatsapp', () => {
const minimalConfig = {
telegram: { bot_token: 'test', allowed_chat_ids: [1] },