Skip to content
dimmiDocs

AI agent

Change an action connection

PATCH/api/v1/ai/action-connections/{connection}

Authorization

Authorizationstringrequired

An API token, sent as Bearer <token>.

Needs the ai:actions ability

Path parameters

connectionstringrequired

Id of the action connection, starting with acn_, such as acn_01jx2m8k4t. Find it with GET /ai/action-connections.

Body

application/json
auth_configobject
Show child attributes
header_namestring

Needed when auth_type is api_key_header: the name of the HTTP header the key travels in. 1 to 64 letters, digits or hyphens, such as X-Api-Key.

prefixstring

Only for auth_type bearer: the word put before the token in the Authorization header in place of Bearer, such as Token. Left out, it is Bearer.

query_paramstring

Needed when auth_type is api_key_query: the name of the query parameter the key travels in. 1 to 64 letters, digits or hyphens only (no underscore), such as apikey.

auth_typestring

How the connection signs its requests: "none", "bearer", "api_key_header", "api_key_query" or "basic". api_key_header also needs auth_config.header_name and api_key_query needs auth_config.query_param; "none" clears the stored secret. Such as "bearer".

Maximum length: 40

base_urlstring

The https address every action's path is added to; requests can never leave it. A full https address with no credentials, query or fragment, at most 512 characters, such as https://api.example.com.

Maximum length: 512

default_headersobject

Headers sent with every request through this connection, as an object of header name to value, at most 10, values at most 256 characters, such as {"X-Api-Version": "2024-01"}. Not allowed: Authorization, Content-Type, Cookie, Host, User-Agent and names starting with Dimmi-.

kindstring

The connection's kind: "http" for an HTTP API or "mcp" for an MCP server. When creating: needed, and fixed from then on. When updating: it does not change, so leave it out.

Available options:httpmcp

namestring

The name of the action connection, at most 60 characters.

Maximum length: 60

passwordstring

The password, as text. It is stored encrypted and never shown again.

Maximum length: 4096

statusstring

"active", or "disabled" to stop every action on the connection. When creating: it has no effect, a new connection always starts active, so leave it out. When updating: switches the connection off or back on; PATCH /ai/action-connections/{connection} is the way to disable one.

Maximum length: 16

timeout_msinteger

A length of time in milliseconds, such as 10000 for ten seconds.

Format: int32

tokenstring

The secret bearer token or API key, as text, at most 4096 characters. It is only written: stored encrypted and never returned or shown again.

Maximum length: 4096

usernamestring

The user name for basic auth, sent together with password, at most 256 characters, such as api-user.

Maximum length: 256

variablesobject

Named values the connection's actions can use in their templates as {connection.name}, as an object of name to text. At most 20; names are lowercase letters, digits and _, up to 40 characters; values up to 256 characters. Such as {"account_id": "acct_42", "region": "eu"}.

Response 200

OK
dataobjectrequired
Show child attributes
actions_countintegerrequired

How many actions use this connection. Counted in lists; 0 when the connection is read alone.

Format: int64

auth_configobjectrequired
Show child attributes
header_namestring

Needed when auth_type is api_key_header: the name of the HTTP header the key travels in. 1 to 64 letters, digits or hyphens, such as X-Api-Key.

prefixstring

Only for auth_type bearer: the word put before the token in the Authorization header in place of Bearer, such as Token. Left out, it is Bearer.

query_paramstring

Needed when auth_type is api_key_query: the name of the query parameter the key travels in. 1 to 64 letters, digits or hyphens only (no underscore), such as apikey.

auth_typestringrequired

How requests prove who they are: none, bearer, api_key_header, api_key_query or basic.

base_urlstringrequired

The address every request of this connection starts from, such as https://api.example.com, or the MCP server's URL.

created_atstringrequired

When it was created, as an RFC 3339 time, such as 2026-01-31T09:00:00Z.

Format: date-time

default_headersobjectrequired

Headers sent with every request of this connection, by name. Empty when none.

has_secretbooleanrequired

True when a token or password is stored for the connection. The secret itself is never returned.

idstringrequired

The id of this record. Send it wherever an endpoint asks for this record; never use its name or title in its place.

kindstringrequired

What the connection reaches: http for an HTTP API, mcp for a remote MCP server.

last_errorstring | nullrequired

Error code of the last failed call or test, such as auth_failed or unavailable. Null when none has failed.

last_error_atstring | nullrequired

When a call or test through this connection last failed. Null when none has.

Format: date-time

last_success_atstring | nullrequired

When a call or test last reached the connection. Null when none has.

Format: date-time

namestringrequired

The name the team gave the connection, such as Orders API. Up to 60 characters.

objectstringrequired

The kind of record this is, the same for every record of its kind, such as article.

secret_hintstring | nullrequired

The last four characters of the stored secret after an ellipsis, such as …9f2c, to tell keys apart. Null when there is no secret or it is under 8 characters.

statusstringrequired

Whether the connection can be used: active, error (its actions are not offered until a test passes) or disabled.

status_reasonstring | nullrequired

Why the connection is in error: host_blocked, or auth after three refused credentials in a row. Null otherwise.

timeout_msintegerrequired

How long a request may take, in milliseconds, from 1000 to 15000. Defaults to 8000.

Format: int32

tools_synced_atstring | nullrequired

When the MCP server's tools were last synced into actions. Null when never synced.

Format: date-time

updated_atstringrequired

When it last changed, as an RFC 3339 time, such as 2026-01-31T09:00:00Z.

Format: date-time

variablesobjectrequired

Plain named values that request templates read as {connection.<name>}, such as a region or account id. Not for secrets. Empty when none.

Response error

Error
codestringrequired

Stable code for programs to tell errors apart, such as validation_failed or internal_error.

errorsobject

Each rejected field mapped to its messages. Only present when the input was invalid.

messagestringrequired

What went wrong, in words safe to show a person.