Update the specified settings on a custom profile. New certificates issued with this profile use the updated settings; existing certificates are unaffected.
PATCH /organizations/{organizationId}/profiles/{profileId}
PATCH https://zanpki.com/organizations/{organizationId}/profiles/{profileId}
| Operation ID |
organizations.organizationId.profiles.profileId.patch
|
|---|---|
| Access | Browser session signed in through ZanAuth, using the access token cookie alongside its ID token and refresh token cookies. Or: An access token issued for this site by its ZanAuth issuer, or a static key. |
Parameters
| Name | In | Type | Description | |
|---|---|---|---|---|
organizationId
| Path | Required | string (snowflake) | Organization ID. |
profileId
| Path | Required | string (snowflake) | Profile ID. |
Idempotency-Key
| Header | Optional | string | This key identifies one request so that sending it again does not carry it out twice. Use a new random value, such as a UUID, for each new request, and send the same value again only with that same request. If you send the same request again with the same key within 10 minutes of the first response, and the first request was carried out, it is not carried out again. Instead, the server returns the first response, or HTTP 409 if that response was too large to keep. The same request means the same method, path, query, body, and Accept header, sent the same way (both as plain HTTP or both as an AI agent's tool call) by the same signed-in person or program, or from the same IP address if you are not signed in. If the first request was refused or failed, sending it again with the same key runs it again. If the first request is still being processed, the server returns HTTP 409. Wait a few seconds, then send the request again with the same key. If the same caller uses the same key for a different request to the same operation, the server returns HTTP 422. The key must be 1 to 255 printable ASCII characters long. If the server cannot record the key, for example during a database fault, the request is carried out without this check. |
Request body
Required, sent as application/x-www-form-urlencoded, application/json.
Schema: ChangeProfileBody
| Property | Type | Description | |
|---|---|---|---|
certificate_profiles_name
| string | Optional | Profile name (1 to 100 characters), shown in certificate issuance forms. |
certificate_profiles_key_types
| list of one of: 1, 2, 3, 4, 5, 6, 7, 8, 9 | Optional | Allowed key types for certificates using this profile (select at least one): 1 (RSA 2048), 2 (RSA 3072), 3 (RSA 4096), 4 (EC P-256), 5 (EC P-384), 6 (EC P-521), 7 (ML-DSA-44), 8 (ML-DSA-65), and 9 (ML-DSA-87). |
certificate_profiles_default_key_type
| one of: 1, 2, 3, 4, 5, 6, 7, 8, 9 | Optional | Default key type preselected in issuance forms. Must be one of the profile's allowed key types. If you leave it out, the base profile's default is used when the profile allows it (RSA 4096 for every built-in profile), and otherwise the first allowed key type. |
certificate_profiles_digest
| one of: 1, 2, 3, 4, null | Optional | Default signature hash algorithm when none is specified: 1 (SHA-256), 2 (SHA-384), 3 (SHA-512), 4 (pure ML-DSA), or null to match the signing authority's key. An ML-DSA authority always signs with pure ML-DSA, and an RSA or EC authority uses its key's default instead of 4. |
certificate_profiles_default_days
| integer (int32) | Optional | Default certificate lifetime in days when none is specified (such as for ACME orders), from 1 up to the maximum days. |
certificate_profiles_most_days
| integer (int32) | Optional | Maximum certificate lifetime allowed by this profile (1 to 825 days). |
certificate_profiles_name_kinds
| list of one of: 1, 2, 6, 7 | Optional | Allowed subject alternative name (SAN) types for certificates using this profile: 1 (email addresses), 2 (DNS names), 6 (URIs), and 7 (IP addresses). Server profiles require DNS names or IP addresses. |
certificate_profiles_subject_organization
| string, or null | Optional | Default subject organization (O) applied when a certificate request omits it. Organizational unit, city, state, and country work the same way. |
certificate_profiles_subject_unit
| string, or null | Optional | Default organizational unit (OU) applied to a certificate's subject when omitted. |
certificate_profiles_subject_city
| string, or null | Optional | Default city or locality (L) applied to a certificate's subject when omitted. |
certificate_profiles_subject_state
| string, or null | Optional | Default state or province (ST) applied to a certificate's subject when omitted. |
certificate_profiles_subject_country
| string, or null | Optional | Default two-letter uppercase ISO country code (C) applied to a certificate's subject when omitted. |
Responses
| Status | Description | Schema | Content type |
|---|---|---|---|
| 204 | Profile saved. | ||
| 403 | Your roles do not permit this action. | Problem | application/json |
| 422 | The request input was rejected. The errors object lists each validation failure. | ValidationProblem | application/json |
| Any other status | The request was rejected. The problem type identifies the error, and the detail field provides a human-readable explanation. | Problem | application/json |
403 Your roles do not permit this action.
| Property | Type | Description | |
|---|---|---|---|
type
| string | Required | A URL that identifies the kind of problem. Its last segment, such as auth_required or input_invalid, is the code your app should check. |
title
| string | Required | The HTTP status as text, such as Not Found. |
status
| integer (int32) | Required | The HTTP status code of the response. |
detail
| string | Required | A human-readable explanation of what went wrong. |
instance
| string | Required | The path the request was sent to. |
422 The request input was rejected. The errors object lists each validation failure.
| Property | Type | Description | |
|---|---|---|---|
type
| string | Required | A URL that identifies the kind of problem. Its last segment, such as auth_required or input_invalid, is the code your app should check. |
title
| string | Required | The HTTP status as text, such as Not Found. |
status
| integer (int32) | Required | The HTTP status code of the response. |
detail
| string | Required | A human-readable explanation of what went wrong. |
instance
| string | Required | The path the request was sent to. |
errors
| InputErrors | Required | Validation errors for each rejected value. Parameter errors are returned as a list, and body errors as a tree matching the request body structure. |
Any other status: The request was rejected. The problem type identifies the error, and the detail field provides a human-readable explanation.
| Property | Type | Description | |
|---|---|---|---|
type
| string | Required | A URL that identifies the kind of problem. Its last segment, such as auth_required or input_invalid, is the code your app should check. |
title
| string | Required | The HTTP status as text, such as Not Found. |
status
| integer (int32) | Required | The HTTP status code of the response. |
detail
| string | Required | A human-readable explanation of what went wrong. |
instance
| string | Required | The path the request was sent to. |
Example
curl -X PATCH 'https://zanpki.com/organizations/{organizationId}/profiles/{profileId}' \
-H 'Authorization: Bearer <access token>' \
-H 'Content-Type: application/json' \
-d '{}'