Skip to main content
Version: v43

NewClientCredential

Reques body for creating a new ClientCredential object

namestringrequired

Human readable name for the client credential

commentstring

Optional human readable comment

target objectrequired

ApiTargetHandle represents a reference to an API target (ID and optional metadata)

idstringrequired

API target unique identifier

namestring

Optional human readable API target name

deletedboolean

Whether the API target has been deleted

not_beforestring<date-time>

NotBefore specifies the start of the client credential validity period. If not specified, the start is set to time of creation.

not_afterstring<date-time>

NotAfter specifies the end of the client credential validity period. If not specified, the end is set according to policy settings.

source_addressstring[]

Optional IP address and/or CIDRs from which requests using this client credential are allowed.

privx_login_session_requiredstring

Controls whether a valid PrivX login session is required for the owner of the client credential when using it. When set to DEFAULT, the API Proxy level setting require_privx_login_session decides the behaviour.

Possible values: [DEFAULT, ENABLED, DISABLED]

enabledboolean

Whether this client credential is enabled or not. Requests authenticated with disabled credentials are rejected.

typestring

Optional client credential type. If not specified, the type is automatically selected based on target credential type.

Possible values: [``, token, basicauth, certificate]

NewClientCredential
{
"name": "string",
"comment": "string",
"target": {
"id": "string",
"name": "string",
"deleted": true
},
"not_before": "2024-07-29T15:51:28.071Z",
"not_after": "2024-07-29T15:51:28.071Z",
"source_address": [
"string"
],
"privx_login_session_required": "DEFAULT",
"enabled": true,
"type": ""
}