Skip to content

/cas/ (POST)

POST
/cas/
curl --request POST \
--url https://pki.example.com/api/v1/cas/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "subject": { "commonName": "example", "organization": "example", "organizationalUnit": "example", "country": "example", "state": "example", "locality": "example" }, "keyAlgorithm": "RSA-2048", "validityYears": 20, "tags": [ "example" ] }'

Create a new self-signed root Certificate Authority

Media typeapplication/json
object
subject
required
object
commonName
required
string
>= 1 characters <= 64 characters
organization
required
string
>= 1 characters <= 64 characters
organizationalUnit
string
<= 64 characters
country
required
string
>= 2 characters <= 2 characters
state
string
<= 64 characters
locality
string
<= 64 characters
keyAlgorithm
required
string
Allowed values: RSA-2048 RSA-4096
validityYears
integer
default: 20 >= 1 <= 30
tags
Array<string>

Default Response

Media typeapplication/json
object
id
string format: uuid
subject
string
serialNumber
string
keyAlgorithm
string
nullable
notBefore
string format: date-time
notAfter
string format: date-time
status
string
Allowed values: active

Example

{
"status": "active"
}

Default Response

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
Array<object>
object
field
string
message
string

Example generated

{
"error": {
"code": "example",
"message": "example",
"details": [
{
"field": "example",
"message": "example"
}
]
}
}

Default Response

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
Array<object>
object
field
string
message
string

Example generated

{
"error": {
"code": "example",
"message": "example",
"details": [
{
"field": "example",
"message": "example"
}
]
}
}