Publish a Custom connector module
publish_module_versionPublish a Custom service's Python bundle, bind its version, declare schema and suggest Requests for review. Requires an existing Custom service datasource; catalogue cards are refused as datasource_is_a_card. For OAuth toolkit self, omit platform_datasource_id: this datasource supplies its own connection. Other platform_calls require a ready Composio card as platform_datasource_id and both connections to allow AI agent actions before approval. Otherwise, only a real publish requires a connected datasource (refused with datasource_not_ready), and the connection must allow the AI agent to build and try actions before approval (datasource_artifact_authority_not_granted). dry_run: true validates without writes even while the datasource is configuring or failed, without that connection permission. Republish preserves unchanged approvals; changed or removed operations lose approval. Results report carried and invalidated approvals and pending Requests. Request Service refusals retain code and request_id; platform_calls_invalid includes the rule and manifest path to fix. platform_origins_changed needs a changed bundle for new origins; manifest_not_replaced needs changed source, lockfile or runtime for a corrected manifest. Read describe_connector_programming for the manifest vocabulary, examples, timeout notices, write budgets, dry-run write semantics and publication result fields. Supply exactly one of source and base_artifact_hash. source is the whole file. base_artifact_hash is the current version with 1 to 100 edits of {old_string, new_string}; expected_sha256 is the source sha256 from read_module_version. Read that first. module_base_not_current, edit_stale, edit_not_found, edit_ambiguous, module_too_many_edits, module_edit_work_limit and module_not_published name the refusals. Through MCP a caller who is not a human Project Administrator is refused earlier, at the dispatch gate, with tool_not_enabled, because publish_module_version is not offered to them; the service's own administrator_role_required is a second check behind it.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"datasource_id": "<datasource_id>"
},
"name": "publish_module_version"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| edits | No | 1 to 100 replacements in the base source, in order: {old_string, new_string}. Each old_string must match once. Accepts an array or a JSON string. | |
| module | No | Module name to publish under. Default: the manifest's own module. With base_artifact_hash, an omitted manifest takes the base version's module and a sent manifest names its own module. An explicit module always wins | |
| source | No | The whole Python source. Omit it when base_artifact_hash names the current version. At most 4194304 bytes | |
| dry_run | No | Validate the bundle and manifest without publishing or writing, even before the Custom service datasource is connected (default false) | |
| runtime | No | Interpreter this bundle declares: use a dated runtime such as python3.12-2027.01, which stages the ekaya helper; a bare id such as python3.12 names the interpreter alone and stages no ekaya helper. Part of the artifact hash. With base_artifact_hash, omit it to keep the base version's runtime | |
| lockfile | No | requirements.lock for the bundle; part of the artifact hash; at most 1048576 bytes. With base_artifact_hash, omit it to keep the base version's lockfile | |
| manifest | No | The contract this bundle declares: module, runtime, and one entry per operation with its name, entity (namespace.entity) and its result — output columns for rows, or result: "document" with an envelope and projections. Required with source. Omitted with a base, the current version's manifest is kept; send one whole to replace it. At most 1048576 bytes, and one operation's envelope at most 262144 | |
| datasource_id | Yes | The service datasource this artifact runs for (UUID) | |
| expected_sha256 | No | Optional sha256 of the base source from read_module_version. Refused when the source has changed. | |
| base_artifact_hash | No | 64 lowercase hex of the current published version. Read it with read_module_version. Send this or source, not both. | |
| platform_datasource_id | No | Omit for OAuth toolkit self, which uses this datasource's own connection. Required for other platform_calls: a ready Composio-card datasource in this project for the declared toolkit. Its connection supplies publication metadata and toolkit execution. The Custom datasource's declared credentials supply the module's environment through its separate environment connection. See describe_connector_programming for toolkit scope. A real publish requires both datasources to allow AI agent actions before approval. The card itself is never published onto. |