Connect a sending provider (credentials.manage, recent authentication). The credential is encrypted and never shown again.
const url = 'https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/connections';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"provider":"ses","name":"example","region":"example","config":{"additionalProperty":"example"},"secret":{"additionalProperty":"example"},"authMode":"keys","setupId":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/connections \ --header 'Content-Type: application/json' \ --data '{ "provider": "ses", "name": "example", "region": "example", "config": { "additionalProperty": "example" }, "secret": { "additionalProperty": "example" }, "authMode": "keys", "setupId": "example" }'The connection starts as pending: POST /v1/connections/{id}/check checks it and sets it to active or error. The response includes webhookUrl only once: it contains the secret for the provider’s events and Replifier only stores its hash. SES (DAT-3230): authMode: "role" with setupId and roleArn connects without keys (validates AssumeRole, GetCallerIdentity, GetAccount and GetEmailIdentity); with keys, root account keys are rejected (ses_root_keys_rejected).
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Example
brd_01hx0000000000000000000000Request Bodyrequired
Section titled “Request Bodyrequired”object
object
Provider credential (SES: accessKeyId and secretAccessKey; SendGrid: apiKey; Mailjet: apiKey and apiSecret; Azure: connectionString; SMTP: username and password). Never returned.
object
SES (DAT-3230): keys (default) or role.
SES with keys: the ses:setup configuration whose suggested policy was used (it is recorded).
object
Example
arn:aws:iam::123456789012:role/ReplifierSES-midominio-comResponses
Section titled “Responses”Connection created
object
object
object
object
object
Role mode: validation result (e.g. the sandbox warning).
object
Example
{ "connection": { "provider": "ses", "status": "pending", "lastCheck": [ { "status": "ok" } ] }, "checks": [ { "status": "ok" } ]}With the credentials_change approval rule: it waits for another person; webhookUrl belongs to the connection that will be created once approved
object
Brand of the action; null if it applies to the whole organization.
executed: approved and the action took place; failed: approved but the action failed (see failureCode); expired: 72 h passed without a decision.
What the approver sees (no secrets).
object
Person (usr_…) or API key (key_…) that requested it.
Error code of the action when it ended up failed.
People who can decide it (excluding the requester). 0: the dashboard suggests inviting someone. Null if it is no longer pending and in listings (computed when it is requested and when it is fetched).
Example
{ "action": "security_policy_change", "status": "pending", "requestedSource": "panel"}Invalid data
object
object
Example
{ "error": { "code": "not_found" }}No session, expired session, or invalid, expired or revoked API key
object
object
Example
{ "error": { "code": "not_found" }}Not allowed, API key missing the scope, IP not allowed, or request rejected (csrf_rejected)
object
object
Example
{ "error": { "code": "not_found" }}Does not exist or is not visible to you
object
object
Example
{ "error": { "code": "not_found" }}Internal error
object
object
Example
{ "error": { "code": "not_found" }}Error
object
object
Example
{ "error": { "code": "not_found" }}Service temporarily unavailable
object
object
Example
{ "error": { "code": "not_found" }}