Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
feat: add trigger instance type and polling interval to triggers.create (PLEN-4489) (#5186)
## Summary ComposioHQ/platform#13820 lets a trigger instance be created as a webhook or a poll, and reports which one it uses. The upsert endpoint gains `type` and `polling_interval`, and the upsert and list-active responses gain `type`, `fallback_reason` and `polling_interval`. The trigger types API already returns `type`, `types` and `requires_webhook_endpoint_setup`. The TypeScript SDK maps every request and response field by hand, so none of these reach SDK users today. The Python SDK returns the generated models, but `triggers.create()` has no keyword arguments for the two new request fields. ComposioHQ/platform#13820 is live in production, and `@composio/client` / `composio-client` 2.0.0 carry its fields, so this PR moves both clients from rc.23 to 2.0.0. Linear: [PLEN-4489](https://linear.app/composio/issue/PLEN-4489/sdk-updates-for-trigger-apis) ## Changes - TypeScript `triggers.create()`: accepts `type` (`'webhook' | 'poll'`) and `pollingInterval` (positive integer), and returns `type`, `fallbackReason` and `pollingInterval` alongside `triggerId`. - TypeScript `triggers.listActive()`: each item carries `type`, `fallbackReason` and `pollingInterval`. - TypeScript `triggers.getType()` / `listTypes()`: return `type`, `types` and `requiresWebhookEndpointSetup`. `listTypes()` items now go through the same mapper as `getType()`, so they're camelCase like the rest of the SDK. - Python `triggers.create()`: accepts `type` and `polling_interval`. Its responses, `list_active()` and `get_type()` already return the generated models, so the new response fields arrive with the client bump. - Client bump: `@composio/client` (pnpm catalog and lockfile) and `composio-client` (`python/pyproject.toml`, `python/setup.py`, `uv.lock`) move from `2.0.0-rc.23` to `2.0.0` ([release](https://github.com/ComposioHQ/composio-client/releases/tag/client-v2.0.0)). CLI test stubs for `createTrigger` gain the three response fields that 2.0.0 makes required; the CLI already prints whatever the API returns. - Breaking in the client, passed through by this bump: POST and PATCH requests, including tool execution and trigger creation, are sent once unless the individual call sets `maxRetries`. Core never set `maxRetries`, so its writes stop retrying on a lost response or retryable status. Other requests keep their retries. - `pyasn1` moves from 0.6.4 to 0.6.5 in `uv.lock`, the release that fixes the four CVEs `py.audit.yml` reports against 0.6.4 (CVE-2026-119194 to CVE-2026-119197). - Changesets: `trigger-instance-type` and `client-2-0-0`, both `@composio/core` and `@composio/slim` minor. ## Type of change - [ ] Bug fix - [x] New feature - [ ] Refactor/Chore - [ ] Documentation - [ ] Breaking change ## How Has This Been Tested? Against the published 2.0.0: - `pnpm typecheck` (workspace): clean. - `pnpm --filter @composio/core test`: 1971 passed, 2 expected fail. - `pnpm --filter @composio/cli test`: 2915 passed, 1 skipped. 21 failed locally, all outside triggers: 19 in `cli-main` and `tools.execute.transport` pass once `CLAUDECODE` is unset (the CLI prints a Claude Code tip), and the 2 `upgrade-binary` beta-release tests fail the same way without this bump. - `nox -s chk` (ruff and mypy on `composio/`, `providers/`, `tests/`, `scripts/`): clean. - `nox -s tst --force-python 3.12`: 2632 passed, 34 skipped; provider suites pass. - `py.audit.yml`'s workspace export and pip-audit, run locally: no known vulnerabilities. - Prettier and oxlint on the changed TypeScript files; ruff format and check on the changed Python files. ## Checklist - [ ] I have read the Code of Conduct and this PR adheres to it - [ ] I have read and understand every line of this diff, including any LLM-generated code - [x] Any third-party docs links or promotional content follow the [third-party links policy](https://github.com/ComposioHQ/composio/blob/next/CONTRIBUTING.md#third-party-links-in-docs) - [x] I ran linters/tests locally and they passed - [ ] I updated documentation as needed - [x] I added tests or explain why not applicable - [x] I added a changeset if this change affects published packages ## Additional context - Not in this PR: docs-site pages for the new fields, and CLI flags for `triggers create`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: jkomyno <alberto@composio.dev>