Write a connection's records through the customer's provider (BYO token, used once)
apply connection: reference page for this CustomDomain™ API operation in the connections group. Covers parameters, request body, responses and error codes.
Rail B (API-token apply). The scoped provider credential is used once to write the records and is never stored. The connection advances to propagating; the poller promotes it to live once the records appear in public DNS.
A widget JWT applies to its own application's connections (a domain-bound token to its own domain only). An API key applies to a connection of any application in its tenant; a member's key needs a role that operates apps (not viewer).
A widget token must be the connection's end user: a connection that names another end user than the token's end_user_ref, or names one while the token names none, answers 403 token_wrong_end_user before anything is read or changed, and a connection that names none is any token's. An API key, an app-scoped token and a delegated agent token are not limited by it.
Short-lived widget JWT minted server-side via POST /v1/tokens. Scoped to one application (and optionally one domain).
In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/connections/string/apply" \ -H "Content-Type: application/json" \ -d '{ "credential": { "token": "string" }, "records": [ { "type": "CNAME", "value": "string" } ] }'{ "connection": { "id": "string", "application_id": "string", "domain": "string", "host": "string", "provider_id": "string", "setup_type": "automatic", "status": "pending", "managed": true, "created_at": "2019-08-24T14:15:22Z", "sandbox": true, "last_checked_at": "2019-08-24T14:15:22Z", "www_redirect": true, "override_spf": true, "validate_dmarc": true, "validate_caa": true, "monitor": true, "batch_id": "string", "end_user_ref": "string", "client_label": "string", "retried_at": "2019-08-24T14:15:22Z", "routing": { "mode": "edge", "cname_target": "string", "apex_ipv4": [ "string" ], "set_at": "2019-08-24T14:15:22Z" }, "records_source": "integrator", "created_via": "", "secure_root_domain": true, "redirect_to": "http://example.com", "power_root_path_access": [ "string" ], "error_code": "string", "error_message": "string", "write_rail": "api_key", "provider_account_id": "string", "removal_started_at": "2019-08-24T14:15:22Z", "dns_hosting": { "state": "none", "by": "customdomain", "provider": "string", "zone": "string", "since": "2019-08-24T14:15:22Z" } }, "records": [ { "type": "CNAME", "host": "string", "value": "string", "ttl": 3600, "priority": 0, "applied": true, "change": "created", "prior": [ { "type": "string", "value": "string", "ttl": 0, "priority": 0 } ], "prior_source": "provider" } ]}{ "code": "string", "title": "string", "details": "string"}{ "code": "string", "title": "string", "details": "string"}{ "code": "string", "title": "string", "details": "string"}{ "code": "string", "title": "string", "details": "string"}{ "code": "string", "title": "string", "details": "string"}