Update a Connection
Partially updates a connection you previously created. Only the fields present in the body are applied — anything you omit keeps its current value.
What you can’t change here: provider_id, flow_type, payment_methods and the INTEGRATION_TYPE param are immutable. To change any of them, create a new connection and repoint your routing rules at it.
Path Parameters
The id returned by Create a Connection. Must belong to the account your API key is scoped to.
Body
UUID of the account the connection belongs to.
New label for this connection. Max 255 characters, and must still be unique within the account. Omit it to keep the current label.
Params to change, as a flat array of {param_id, value} pairs — the same shape as Create a Connection.
Params are merged by param_id over the connection’s current params: a param_id you don’t send keeps its current value. You only need to send what you’re actually changing. Every param_id you do send is validated against the provider catalog.
Cost configuration. Unlike params, costs is not merged — when present it replaces the connection’s entire cost table. Omit it to leave the existing costs untouched.
Response
Returns the refreshed connection, in the same shape as Retrieve a Connection.
Unique identifier for the connection. Unchanged by an update.
Your internal label for this connection.
The provider this connection belongs to.
Current status.
Always PAYIN.
List of supported payment methods.
The connection’s full param set after the merge — not just the ones you sent. Sensitive values are masked as ***.
Cost configuration for the connection.
ISO 8601 timestamp.
ISO 8601 timestamp. Bumped by a successful update.
curl -X PATCH 'https://api.whitelabel.com/v1/connections/f1a3c4d5-7b8e-4a2c-9d1e-3f4a5b6c7d8e' \
-H 'public-api-key: <YOUR_PUBLIC_KEY>' \
-H 'private-secret-key: <YOUR_SECRET_KEY>' \
-H 'Content-Type: application/json' \
-d '{
"account_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"params": [
{ "param_id": "API_KEY", "value": "sk_live_new..." }
]
}'curl -X PATCH 'https://api.whitelabel.com/v1/connections/f1a3c4d5-7b8e-4a2c-9d1e-3f4a5b6c7d8e' \
-H 'public-api-key: <YOUR_PUBLIC_KEY>' \
-H 'private-secret-key: <YOUR_SECRET_KEY>' \
-H 'Content-Type: application/json' \
-d '{
"account_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"merchant_connection_id": "stripe-us-prod-002"
}'{
"connection_id": "f1a3c4d5-7b8e-4a2c-9d1e-3f4a5b6c7d8e",
"merchant_connection_id": "stripe-us-prod-002",
"provider_id": "STRIPE",
"status": "ACTIVE",
"flow_type": "PAYIN",
"payment_methods": ["CARD", "GOOGLE_PAY", "APPLE_PAY"],
"params": [
{ "param_id": "API_KEY", "value": "***" },
{ "param_id": "PUBLISHABLE_KEY", "value": "pk_live_..." },
{ "param_id": "INTEGRATION_TYPE", "value": "PAYMENT_INTENTS" },
{ "param_id": "3DS_ENABLED", "value": true },
{ "param_id": "ORIGIN_URL", "value": "https://checkout.acme.com" }
],
"costs": [
{
"sort_number": 1,
"cost_name": "Transaction Fee",
"currency": "USD",
"cost_values": {
"successful": { "fixed_fee": 0.30, "percentage": 2.9 },
"unsuccessful": { "fixed_fee": 0.0, "percentage": 0.0 }
}
}
],
"created_at": "2026-05-12T10:24:00Z",
"updated_at": "2026-05-12T11:02:17Z"
}{
"type": "validation_error",
"code": "UNKNOWN_PARAM",
"message": "Param 'FOO' is not part of the catalog for provider 'STRIPE'",
"details": { "provider_id": "STRIPE", "param_id": "FOO" }
}{
"type": "conflict",
"code": "CONNECTION_MERCHANT_ID_CONFLICT",
"message": "A connection with merchant_connection_id 'stripe-us-prod-002' already exists in this account",
"details": { "merchant_connection_id": "stripe-us-prod-002" }
}Secret handling: params marked secret: true in the catalog are always returned as "value": "***". Sending "***" back is not how you keep a secret — just omit the param_id entirely and its stored value is preserved.
Errors
| HTTP | code |
|---|---|
400 | UNKNOWN_PARAMA param_id isn’t part of the provider’s catalog. |
400 | INVALID_PARAM_VALUEA value doesn’t match the catalog’s field_type or allowed options. |
400 | UNSUPPORTED_CURRENCYA costs[].currency isn’t in the provider’s supported list. |
400 | VALIDATION_ERRORconnection_id isn’t a valid UUID, or merchant_connection_id exceeds 255 characters. |
400 | MALFORMED_BODYThe body isn’t valid JSON. |
401 | NOT_AUTHENTICATEDMissing or invalid API key. |
404 | CONNECTION_NOT_FOUNDUnknown connection_id, or the id belongs to a different account. |
409 | CONNECTION_MERCHANT_ID_CONFLICTmerchant_connection_id already exists in this account. |
/connections/{connection_id}Partially updates a connection. Only the fields present in the body are applied.
Path Parameters
Body application/json
Response
OK
Bad Request
Unauthorized
Not Found
Conflict