Skip to main content
POST
TypeScript

Headers

Idempotency-Key
string

A unique identifier for the request. If the request is sent multiple times with the same idempotency key, the server will return the same response as the first request. The idempotency key is valid for 24 hours.

Body

application/json

A new reusable OAuth 2.0 client credential set. Attach it to a webhook by passing the returned id as that webhook's webhookOauthId. Several webhooks may share one credential set, so rotating its client secret covers all of them at once. With private_key_jwt there is no client secret: Fireblocks generates the key pairs itself and publishes their public halves at the jwksUri it returns.

name
string
required

A label for this credential set, shown when listing them.

Required string length: 1 - 128
Example:

"Production treasury gateway"

clientId
string
required

OAuth client ID used to authenticate with the token endpoint.

Required string length: 1 - 255
Example:

"my-client-id"

url
string
required

Token endpoint URL. HTTPS on port 443 only, and the host must resolve publicly — localhost and private, link-local or loopback addresses are rejected.

Maximum string length: 2048
Pattern: ^https://
Example:

"https://auth.example.com/oauth/token"

clientSecret
string

OAuth client secret. Write-only — never returned. Limited to 480 bytes UTF-8 encoded. With client_secret_jwt it signs the assertion rather than being sent. Required with client_secret_basic, client_secret_post and client_secret_jwt (400 if missing). Must not be sent with private_key_jwt, which uses a Fireblocks-held key instead (400 otherwise).

Required string length: 1 - 480
Example:

"my-client-secret"

authMethod
string
default:client_secret_basic

How the client credentials reach the token endpoint. client_secret_basic uses an HTTP Basic header, client_secret_post uses form fields in the body, and client_secret_jwt sends a JWT assertion signed with the secret, so the secret itself is never transmitted. private_key_jwt sends a JWT assertion signed with a private key Fireblocks generates and holds for these credentials, so there is no shared secret at all; your authorization server verifies it with the public keys at the jwksUri returned with the credentials. Creating credentials with private_key_jwt generates two key pairs, the signing key and its successor. Defaults to client_secret_basic.

Example:

"client_secret_basic"

signingAlg
enum<string> | null

Algorithm of the key pairs generated for private_key_jwt, and of the assertions signed with them. Defaults to RS256 when authMethod is private_key_jwt, where null is refused (400); omit it instead. Only valid with private_key_jwt: with any other method a value is a 400, and null, meaning no algorithm, is accepted.

Available options:
RS256,
PS256,
ES256
Example:

"RS256"

customJwtClaims
object | null

Extra claims for the JWT assertion. Used only when authMethod is client_secret_jwt or private_key_jwt. The usual one to set is aud, which defaults to the token endpoint URL; some authorization servers expect their own identifier instead. A value may be any JSON type except null — null is reserved for deleting a claim on update. iss, sub, jti, iat and exp are set by Fireblocks and cannot be overridden. Names are case-sensitive. The whole object must be under 16 KB. Values are write-only; responses return only the claim names. On update this merges claim by claim rather than replacing — see WebhookOauthCustomJwtClaimsUpdate.

Example:
customBodyParams
object | null

Extra parameters for the token request body — scope most commonly, sometimes audience or resource. Applies to every authentication method. Values must be strings, because the token request body is form-encoded rather than JSON. An empty string is allowed. grant_type, client_id, client_secret, client_assertion and client_assertion_type are set by Fireblocks and cannot be overridden. Names are case-sensitive. The whole object must be under 16 KB. Values are write-only; responses return only the parameter names. On update this merges key by key rather than replacing — see WebhookOauthCustomBodyParamsUpdate.

Example:
webhookCustomHeadersId
string<uuid> | null

The id of the set of custom HTTP headers added to the token request to your authorization server — not to the webhook delivery — from /v1/webhooks_settings/custom_headers. A gateway API key is the usual case. The set can be shared with webhooks and with other credentials, and the same rules apply as for a webhook delivery. A value is a string, or an array of strings sent as one header line per element (Cookie and Authorization accept only a string), the reserved header names — the same as for a webhook delivery, including Host, Content-Type and Content-Length — are set by Fireblocks and cannot be overridden, and Authorization is sent with client_secret_post or client_secret_jwt, which send the credentials in the body — useful when your token endpoint sits behind a gateway — but is not sent with client_secret_basic, where Fireblocks sends its own Authorization header with the credentials. Replaces the inline customHeaders field, which is now refused with a 400, so use webhookCustomHeadersId. Omit, or send null, for a token request with no extra headers. An unknown id, or one belonging to another workspace, is a 404.

Example:

"6f1b7c62-0f2e-4f1a-9a5e-9f2b1c3d4e5f"

webhookMtlsId
string<uuid> | null

The id of the mTLS configuration presented to the token endpoint, from /v1/webhooks_settings/mtls. It can be the same configuration a webhook uses, so one certificate, signed from GET /v1/webhooks_settings/mtls_csr, serves both the token endpoint and the receiver. Omit, or send null, for a token request without mTLS. Requires a configuration of this workspace (404 otherwise) that is linked to a private key (400 otherwise).

Example:

"6f1b7c62-0f2e-4f1a-9a5e-9f2b1c3d4e5f"

Response

created the OAuth credentials successfully

A stored OAuth 2.0 client credential set, referenced by webhooks through their webhookOauthId. Deliveries for a webhook that references one carry Authorization: Bearer {token}, using a token fetched from url and cached until it expires, so your authorization server sees far fewer token requests than deliveries. Secret material is never returned: clientSecret is absent from this schema entirely, and the customJwtClaims and customBodyParams fields are reduced to their names, without the configured values. Extra token request headers are a separate resource, referenced by webhookCustomHeadersId. The key pairs of private_key_jwt credentials are never returned here either; their public halves are published at the URL in jwksUri.

id
string<uuid>
required

The id of the OAuth credentials. Pass this as a webhook's webhookOauthId to attach them.

Example:

"123e4567-e89b-12d3-a456-426614174000"

name
string
required

The label given to this credential set.

Example:

"Production treasury gateway"

clientId
string
required

OAuth client ID used to authenticate with the token endpoint.

Example:

"my-client-id"

url
string
required

Token endpoint URL.

Example:

"https://auth.example.com/oauth/token"

authMethod
string
default:client_secret_basic
required

How the client credentials are presented to the token endpoint: client_secret_basic, client_secret_post, client_secret_jwt or private_key_jwt. Credentials created without this field report client_secret_basic, which is what they use.

Example:

"client_secret_basic"

createdAt
integer<int64>
required

The date and time the OAuth credentials were created, in milliseconds.

Example:

1625097600000

updatedAt
integer<int64>
required

The date and time the OAuth credentials were last updated, in milliseconds.

Example:

1625097600000

signingAlg
enum<string>

Algorithm of the key pairs, and of the assertions signed with them. Present only when authMethod is private_key_jwt. Which key is signing is never returned; each assertion names it in its kid header. Defaults to RS256 on create only.

Available options:
RS256,
PS256,
ES256
Example:

"RS256"

customJwtClaims
string[]

Names of the additional claims placed in the JWT assertion. Claim values are write-only and are never returned. Absent when no custom claims are configured.

Example:
customBodyParams
string[]

Names of the additional parameters added to the token request body. Parameter values are write-only and are never returned. Absent when no custom parameters are configured.

Example:
webhookCustomHeadersId
string<uuid>

The id of the set of custom headers added to the token request sent to the authorization server — not to the webhook delivery. Absent when the token request adds none. Header values are write-only and are never returned; read the header names from /v1/webhooks_settings/custom_headers/{webhookCustomHeadersId}.

Example:

"6f1b7c62-0f2e-4f1a-9a5e-9f2b1c3d4e5f"

webhookMtlsId
string<uuid>

The id of the mTLS configuration presented to the token endpoint. Absent when the token request does not use mTLS. Read the certificate from /v1/webhooks_settings/mtls/{id}.

Example:

"6f1b7c62-0f2e-4f1a-9a5e-9f2b1c3d4e5f"

jwksUri
string<uri>
read-only

The public URL of these credentials' JWKS. Register it as the client's jwks_uri on your authorization server. Present for private_key_jwt only.

Example:

"https://keys.fireblocks.io/webhooks-oauth/123e4567-e89b-12d3-a456-426614174000/.well-known/jwks.json"