Skip to content

Try a credential against the provider without storing it

POST
/v1/integrations/{provider}/test-connection
curl --request POST \
--url https://api.adversarial.com/api/v1/integrations/example/test-connection \
--header 'Content-Type: application/json' \
--data '{ "auth_method": "api_key", "connection_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "credentials": {}, "settings": {} }'
provider
required
string

Provider slug

Media typeapplication/json

A credential to try against the provider without storing anything.

object
auth_method
required

Authentication method selected from the provider catalog.

string
Allowed values: api_key basic bearer oauth2_client_credentials
connection_id

Connection whose stored secret to use when credentials is omitted.

string | null format: uuid
credentials

Complete write-only input for the selected authentication method. Omit it to try the secret connection_id already holds.

object
settings
required

Provider connection values that do not contain secrets.

object

Provider verdict on the credential

Media typeapplication/json

The result of checking a credential. A rejection is the answer to the question asked, so it is ok: false rather than an error status.

object
message

On failure, the sanitized reason. On success, absent when the provider accepted the credential, or a note on what was checked when the provider cannot check credentials without side effects.

string | null
ok
required

Whether the credential passed the check. When message is present on success, the provider was not contacted and message says what was checked.

boolean

Example generated

{
"message": "example",
"ok": true
}

Invalid provider configuration

Unknown provider or connection