Trustpoint Management API

Overview

The Trustpoint Management API provides a comprehensive set of REST endpoints for administering and configuring Trustpoint. This API enables secure, programmatic access to manage users, domains, certificate authorities, devices, workflows, and system settings.

Note

This is the Management API (/api/). For certificate enrollment operations, see the REST PKI API, EST API, or CMP API.

Key Features

The Management API allows you to:

  • Certificate Authority Management: Create and manage CAs, domains, and certificate profiles

  • Device Management: Register, onboard, and monitor devices

  • User Management: Manage user accounts, roles, and permissions

  • Workflow Management: Configure and monitor approval workflows

  • System Administration: Configure security settings, view logs, and monitor system health

Base URL

All Management API endpoints are accessible under:

https://<trustpoint-host>/api/

Authentication

The Management API uses JWT (JSON Web Tokens) for authentication.

Obtaining a Token

Request an access token using your username and password. When the global OTP requirement is enabled, also include your authenticator code or an unused recovery code as the otp string:

POST /api/token/
Content-Type: application/json

{
    "username": "your-username",
    "password": "your-password",
    "otp": "012345"
}

Omit otp when OTP is disabled. Users need the users.use_rest_api permission. If OTP is required and no confirmed authenticator exists, enroll through the web interface first. Missing, invalid, reused, or throttled codes return HTTP 401 without issuing tokens. Recovery codes can be used once.

Service accounts continue to use the client credentials grant without OTP; see Service Accounts.

Response:

{
    "access": "<access-token>",
    "refresh": "<refresh-token>"
}

Using the Token

Include the access token in the Authorization header:

Authorization: Bearer <access-token>

Example:

curl -X GET https://trustpoint.example.com/api/domains/ \
  -H "Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGc..."

Refreshing the Token

Access tokens expire after a period. Use the refresh token to obtain a new access token:

POST /api/token/refresh/
Content-Type: application/json

{
    "refresh": "<refresh-token>"
}

Refreshing an existing token does not require another OTP. Enabling OTP does not invalidate tokens that were already issued.

Interactive Documentation

Trustpoint provides interactive API documentation using Swagger UI and ReDoc:

  • Swagger UI: https://<trustpoint-host>/swagger/

  • ReDoc: https://<trustpoint-host>/redoc/

  • OpenAPI schema: https://<trustpoint-host>/schema/

The interactive documentation allows you to:

  • Browse all available endpoints

  • View request/response schemas

  • Test API calls directly in the browser

  • Generate code samples

Definition

REST PKI

POST /api/rest-pki/revoke/

Revoke a certificate belonging to an issued credential

Revoke the certificate of the given issued credential.

Example request:

POST /api/rest-pki/revoke/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "issued_credential_id": 1,
    "revocation_reason": "unspecified"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "detail": "string",
        "issued_credential_id": 1
    }
    

  • 400 Bad Request – Bad Request - validation error or invalid revocation reason

  • 401 Unauthorized – Unauthorized - authentication required

  • 403 Forbidden – Forbidden - user lacks the revoke_certificates permission

  • 404 Not Found – Not Found - issued credential does not exist

  • 422 Unprocessable Entity – Unprocessable Entity - certificate already revoked or expired

  • 500 Internal Server Error – Internal Server Error - revocation failed

Backup

GET /api/backups/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Query Parameters:
  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

  • user (string)

Example request:

GET /api/backups/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "remote_directory": "string"
        }
    ]
    

POST /api/backups/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Example request:

POST /api/backups/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "remote_directory": "string"
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "remote_directory": "string"
    }
    

GET /api/backups/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this Backup Option.

Example request:

GET /api/backups/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "remote_directory": "string"
    }
    

PUT /api/backups/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this Backup Option.

Example request:

PUT /api/backups/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "remote_directory": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "remote_directory": "string"
    }
    

PATCH /api/backups/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this Backup Option.

Example request:

PATCH /api/backups/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "remote_directory": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "remote_directory": "string"
    }
    

DELETE /api/backups/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this Backup Option.

Status Codes:

Certificate Profile

GET /api/cert-profiles/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Query Parameters:
  • created_at (string)

  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

  • unique_name (string)

Example request:

GET /api/cert-profiles/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "unique_name": "string"
        }
    ]
    

POST /api/cert-profiles/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Example request:

POST /api/cert-profiles/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

GET /api/cert-profiles/{id}/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this certificate profile model.

Example request:

GET /api/cert-profiles/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

PUT /api/cert-profiles/{id}/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this certificate profile model.

Example request:

PUT /api/cert-profiles/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

PATCH /api/cert-profiles/{id}/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this certificate profile model.

Example request:

PATCH /api/cert-profiles/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

DELETE /api/cert-profiles/{id}/

ViewSet for managing Certificate Profile instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this certificate profile model.

Status Codes:

Certificate

GET /api/certificates/

List certificates

Retrieve certificates from the database.

Query Parameters:
  • not_valid_before (string)

  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

  • serial_number (string)

Example request:

GET /api/certificates/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "common_name": "string"
        }
    ]
    

GET /api/certificates/{id}/

List, inspect, download, and delete stored certificates.

Parameters:
  • id (integer) – A unique integer value identifying this certificate model.

Example request:

GET /api/certificates/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "common_name": "string"
    }
    

DELETE /api/certificates/{id}/

List, inspect, download, and delete stored certificates.

Parameters:
  • id (integer) – A unique integer value identifying this certificate model.

Status Codes:

Device

GET /api/devices/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Query Parameters:
  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

Example request:

GET /api/devices/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "common_name": "string",
            "serial_number": "string",
            "device_type": 0,
            "created_at": "2026-11-17T08:23:06.065629",
            "domain": 1,
            "onboarding_config": 1,
            "no_onboarding_config": 1
        }
    ]
    

POST /api/devices/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Example request:

POST /api/devices/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "common_name": "string",
    "serial_number": "string",
    "device_type": 0,
    "domain": 1,
    "onboarding_config": 1,
    "no_onboarding_config": 1
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "common_name": "string",
        "serial_number": "string",
        "device_type": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "domain": 1,
        "onboarding_config": 1,
        "no_onboarding_config": 1
    }
    

GET /api/devices/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this device model.

Example request:

GET /api/devices/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "common_name": "string",
        "serial_number": "string",
        "device_type": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "domain": 1,
        "onboarding_config": 1,
        "no_onboarding_config": 1
    }
    

PUT /api/devices/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this device model.

Example request:

PUT /api/devices/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "common_name": "string",
    "serial_number": "string",
    "device_type": 0,
    "domain": 1,
    "onboarding_config": 1,
    "no_onboarding_config": 1
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "common_name": "string",
        "serial_number": "string",
        "device_type": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "domain": 1,
        "onboarding_config": 1,
        "no_onboarding_config": 1
    }
    

PATCH /api/devices/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this device model.

Example request:

PATCH /api/devices/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "common_name": "string",
    "serial_number": "string",
    "device_type": 0,
    "domain": 1,
    "onboarding_config": 1,
    "no_onboarding_config": 1
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "common_name": "string",
        "serial_number": "string",
        "device_type": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "domain": 1,
        "onboarding_config": 1,
        "no_onboarding_config": 1
    }
    

DELETE /api/devices/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this device model.

Status Codes:

Domain

GET /api/domains/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Query Parameters:
  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

Example request:

GET /api/domains/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "unique_name": "string"
        }
    ]
    

POST /api/domains/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Example request:

POST /api/domains/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

GET /api/domains/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this domain model.

Example request:

GET /api/domains/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

PUT /api/domains/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this domain model.

Example request:

PUT /api/domains/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

PATCH /api/domains/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this domain model.

Example request:

PATCH /api/domains/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string"
    }
    

DELETE /api/domains/{id}/

ViewSet for managing Device instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this domain model.

Status Codes:

Issuing-CA

GET /api/issuing-cas/

List Issuing CAs

Retrieve all Issuing CAs from the database.

Query Parameters:
  • is_active (boolean)

  • issuing_ca_type (integer) –

    • 0 - Auto-Generated Root

    • 1 - Auto-Generated

    • 2 - Local-Unprotected

    • 3 - Local-PKCS11

    • 4 - Remote-EST

    • 5 - Remote-CMP

  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

  • unique_name (string)

Example request:

GET /api/issuing-cas/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "unique_name": "string",
            "common_name": "string",
            "issuing_ca_type": 0,
            "issuing_ca_type_display": "string",
            "is_active": true,
            "created_at": "2026-11-17T08:23:06.065629",
            "updated_at": "2026-11-17T08:23:06.065629",
            "last_crl_issued_at": "2026-11-17T08:23:06.065629",
            "has_crl": true
        }
    ]
    

GET /api/issuing-cas/{id}/

Retrieve Issuing CA

Retrieve details of a specific Issuing CA by ID.

Parameters:
  • id (integer) – A unique integer value identifying this issuing ca model.

Example request:

GET /api/issuing-cas/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "common_name": "string",
        "issuing_ca_type": 0,
        "issuing_ca_type_display": "string",
        "is_active": true,
        "created_at": "2026-11-17T08:23:06.065629",
        "updated_at": "2026-11-17T08:23:06.065629",
        "last_crl_issued_at": "2026-11-17T08:23:06.065629",
        "has_crl": true
    }
    

GET /api/issuing-cas/{id}/crl/

Download CRL

Download the Certificate Revocation List (CRL) for this Issuing CA. Requires authentication. Supports both PEM (default) and DER formats via the format query parameter. If no CRL is available, use the POST /api/issuing-cas/<pk>/generate-crl/ endpoint to generate one first.

Parameters:
  • id (integer) – A unique integer value identifying this issuing ca model.

Query Parameters:
  • encoding (string) – CRL encoding: “pem” (default) or “der”

Example request:

GET /api/issuing-cas/{id}/crl/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    CRLGenerated - CRL Generated:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "detail": "CRL file downloaded successfully."
    }
    

  • 400 Bad Request –

    InvalidFormatParameter - Invalid format parameter:

    HTTP/1.1 400 Bad Request
    Content-Type: application/json
    
    {
        "error": "No CRL available for Issuing CA \"MyCA\".",
        "hint": "Generate a CRL first using POST /api/issuing-cas/1/generate-crl/"
    }
    

  • 404 Not Found –

    NotFound - Not Found:

    HTTP/1.1 404 Not Found
    Content-Type: application/json
    
    {
        "error": "No CRL available for Issuing CA \"MyCA\".",
        "hint": "Generate a CRL first using POST /api/issuing-cas/1/generate-crl/"
    }
    

POST /api/issuing-cas/{id}/generate-crl/

Generate CRL

Manually generate a new Certificate Revocation List (CRL) for this Issuing CA. No request body is required.

Parameters:
  • id (integer) – A unique integer value identifying this issuing ca model.

Status Codes:
  • 200 OK –

    CRLGenerated - CRL Generated:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "message": "CRL generated successfully for Issuing CA \"MyCA\".",
        "last_crl_issued_at": "2025-12-02T16:30:00Z"
    }
    

  • 500 Internal Server Error –

    ServerError - Server Error:

    HTTP/1.1 500 Internal Server Error
    Content-Type: application/json
    
    {
        "detail": "Failed to generate CRL"
    }
    

Logging

DELETE /api/logging/delete/{file_name}/

Delete a log file by name.

DELETE /logs/delete/app.log/

Parameters:
  • file_name (string)

Status Codes:
GET /api/logging/download/{file_name}/

Download a log file by name: /logs/download/?file=app.log

Parameters:
  • file_name (string)

Example request:

GET /api/logging/download/{file_name}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "name": "string",
        "size": 1,
        "modified": "2026-11-17T08:23:06.065629"
    }
    

GET /api/logging/list_files/

Return detailed info for all log files.

Example request:

GET /api/logging/list_files/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "name": "string",
        "size": 1,
        "modified": "2026-11-17T08:23:06.065629"
    }
    

Signer

GET /api/signed-messages/

List all signed messages

Returns a list of all signed messages, ordered by creation date (newest first).

Query Parameters:
  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

  • signer (integer)

Example request:

GET /api/signed-messages/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "signer": 1,
            "signer_name": "string",
            "hash_value": "string",
            "signature": "string",
            "created_at": "2026-11-17T08:23:06.065629"
        }
    ]
    

GET /api/signed-messages/{id}/

Retrieve a signed message

Returns details of a specific signed message.

Parameters:
  • id (integer) – A unique integer value identifying this signed message model.

Example request:

GET /api/signed-messages/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "signer": 1,
        "signer_name": "string",
        "hash_value": "string",
        "signature": "string",
        "created_at": "2026-11-17T08:23:06.065629"
    }
    

GET /api/signers/

ViewSet for Signer operations.

Query Parameters:
  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

Example request:

GET /api/signers/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "unique_name": "string",
            "certificate_cn": "string",
            "certificate_not_valid_after": "2026-11-17T08:23:06.065629",
            "signature_suite": "string",
            "created_at": "2026-11-17T08:23:06.065629",
            "updated_at": "2026-11-17T08:23:06.065629"
        }
    ]
    

GET /api/signers/{id}/

ViewSet for Signer operations.

Parameters:
  • id (integer) – A unique integer value identifying this signer model.

Example request:

GET /api/signers/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "certificate_cn": "string",
        "certificate_not_valid_after": "2026-11-17T08:23:06.065629",
        "signature_suite": "string",
        "created_at": "2026-11-17T08:23:06.065629",
        "updated_at": "2026-11-17T08:23:06.065629"
    }
    

GET /api/signers/{id}/certificate/

Get the signer’s certificate in PEM format.

Parameters:
  • id (integer) – A unique integer value identifying this signer model.

Example request:

GET /api/signers/{id}/certificate/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "certificate_cn": "string",
        "certificate_not_valid_after": "2026-11-17T08:23:06.065629",
        "signature_suite": "string",
        "created_at": "2026-11-17T08:23:06.065629",
        "updated_at": "2026-11-17T08:23:06.065629"
    }
    

POST /api/signers/sign/

Sign a hash value

Signs a hash value using the specified signer. The hash value must be provided as a hexadecimal string. The signature is returned in hexadecimal format.

Status Codes:

Tls

GET /api/tls/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Query Parameters:
  • credential_type (integer) –

    • 0 - Trustpoint TLS Server

    • 1 - Root CA

    • 2 - Issuing CA

    • 3 - Issued Credential

    • 4 - DevOwnerID

    • 5 - Signer

  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

Example request:

GET /api/tls/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "credential_type": 0,
            "created_at": "2026-11-17T08:23:06.065629"
        }
    ]
    

POST /api/tls/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Example request:

POST /api/tls/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "credential_type": 0
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "credential_type": 0,
        "created_at": "2026-11-17T08:23:06.065629"
    }
    

GET /api/tls/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this credential model.

Example request:

GET /api/tls/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "credential_type": 0,
        "created_at": "2026-11-17T08:23:06.065629"
    }
    

PUT /api/tls/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this credential model.

Example request:

PUT /api/tls/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "credential_type": 0
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "credential_type": 0,
        "created_at": "2026-11-17T08:23:06.065629"
    }
    

PATCH /api/tls/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this credential model.

Example request:

PATCH /api/tls/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "credential_type": 0
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "credential_type": 0,
        "created_at": "2026-11-17T08:23:06.065629"
    }
    

DELETE /api/tls/{id}/

ViewSet for managing Backup instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this credential model.

Status Codes:

Auth

POST /api/token/

Takes a set of user credentials and returns an access and refresh JSON web token pair to prove the authentication of those credentials.

Example request:

POST /api/token/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "username": "string",
    "password": "string",
    "otp": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "username": "string",
        "password": "string",
        "otp": "string",
        "access": "string",
        "refresh": "string"
    }
    

POST /api/token/refresh/

Takes a refresh type JSON web token and returns an access type JSON web token if the refresh token is valid.

Example request:

POST /api/token/refresh/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "refresh": "string"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "access": "string",
        "refresh": "string"
    }
    

Truststore

GET /api/truststores/

List Truststores

Retrieve truststore from the database.

Query Parameters:
  • intended_usage (integer) –

    • 0 - IDevID

    • 1 - TLS

    • 2 - Generic

    • 3 - Device Owner ID

  • ordering (string) – Which field to use when ordering the results.

  • search (string) – A search term.

Example request:

GET /api/truststores/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    [
        {
            "id": 1,
            "unique_name": "string",
            "intended_usage": 0,
            "created_at": "2026-11-17T08:23:06.065629",
            "trust_store_file": "https://example.com"
        }
    ]
    

POST /api/truststores/

Create a new truststore

Add a new truststore by providing its unique_name, intended_usage and trust_store_file.

Example request:

POST /api/truststores/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string",
    "intended_usage": 0,
    "trust_store_file": "https://example.com"
}
Status Codes:
  • 201 Created –

    Example response:

    HTTP/1.1 201 Created
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "intended_usage": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "trust_store_file": "https://example.com"
    }
    

GET /api/truststores/{id}/

ViewSet for managing Truststore instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this truststore model.

Example request:

GET /api/truststores/{id}/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "intended_usage": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "trust_store_file": "https://example.com"
    }
    

PUT /api/truststores/{id}/

ViewSet for managing Truststore instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this truststore model.

Example request:

PUT /api/truststores/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string",
    "intended_usage": 0,
    "trust_store_file": "https://example.com"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "intended_usage": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "trust_store_file": "https://example.com"
    }
    

PATCH /api/truststores/{id}/

ViewSet for managing Truststore instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this truststore model.

Example request:

PATCH /api/truststores/{id}/ HTTP/1.1
Host: example.com
Content-Type: application/json

{
    "unique_name": "string",
    "intended_usage": 0,
    "trust_store_file": "https://example.com"
}
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {
        "id": 1,
        "unique_name": "string",
        "intended_usage": 0,
        "created_at": "2026-11-17T08:23:06.065629",
        "trust_store_file": "https://example.com"
    }
    

DELETE /api/truststores/{id}/

ViewSet for managing Truststore instances.

Supports standard CRUD operations such as list, retrieve, create, update, and delete.

Parameters:
  • id (integer) – A unique integer value identifying this truststore model.

Status Codes:

schema

GET /schema/

OpenApi3 schema for this API. Format can be selected via content negotiation.

  • YAML: application/vnd.oai.openapi

  • JSON: application/vnd.oai.openapi+json

Query Parameters:
  • format (string)

  • lang (string)

Example request:

GET /schema/ HTTP/1.1
Host: example.com
Status Codes:
  • 200 OK –

    Example response:

    HTTP/1.1 200 OK
    Content-Type: application/json
    
    {}
    

CA and CRL management

CA and CRL administration requires authentication and the manage_cas permission. Private keys and upstream authentication secrets are never included in these responses. Upload actions accept multipart/form-data; configuration and enrollment actions accept JSON.

CA inventories

GET /api/cas/ and GET /api/cas/{id}/ expose the full CA inventory, including keyless CAs and autogenerated roots, with parent relationships, certificate identifiers, and CRL settings. Filter by ca_type, is_active, or parent_ca. /api/issuing-cas/ retains its issuing-CA-only inventory.

For either inventory:

  • DELETE /api/cas/{id}/ or DELETE /api/issuing-cas/{id}/ deletes an unused CA. Child CAs, unexpired issued certificates, and protected references prevent deletion.

  • GET /api/cas/{id}/certificate/?encoding=pem downloads its public certificate. encoding=der is also supported.

  • GET /api/cas/{id}/issued-certificates/ lists its issued certificates, including public PEM content and validity information.

The certificate download and issued-certificate actions also exist under /api/issuing-cas/{id}/. Downloads return 404 when the CA has no certificate.

Creating issuing CAs

The existing POST /api/issuing-cas/ PEM import contract remains supported: private_key_pem, ca_certificate_pem, optional certificate_chain_pem, private_key_password, and unique_name.

Additional actions:

  • POST /api/issuing-cas/import-pkcs12/: upload pkcs12_file with optional pkcs12_password and unique_name.

  • POST /api/issuing-cas/generate/: supply unique_name and key_type to create a self-signed issuing CA. The security policy must enable local auto-generated PKI creation. The SelfSignedCA_ prefix is added to the name if omitted. Multiple CAs are supported; no parent CA or domain is created.

  • POST /api/issuing-cas/configure-est/ and configure-cmp/: configure an upstream CA using unique_name, key_type, remote_host, remote_port, and remote_path. EST additionally requires est_username and est_password; CMP requires cmp_shared_secret. Set is_ra_mode to true for a registration authority configuration.

  • POST /api/issuing-cas/configure-external-csr/: supply unique_name and key_type to create a managed key for an externally signed CA.

The backend’s supported key types and the active security policy apply to all creation methods, as they do in the Web UI.

Upstream enrollment and external signing

Associate an existing truststore before upstream enrollment:

POST /api/issuing-cas/12/truststore/
Content-Type: application/json

{"trust_store": 5}

The truststore’s intended usage is validated. EST uses a TLS truststore; CMP uses an Issuing CA Chain truststore. An EST RA first associates an Issuing CA Chain, then a TLS truststore. The CA-chain step populates the RA certificate and chain relationships.

POST /api/issuing-cas/{id}/enroll/ requests the configured upstream EST or CMP CA certificate. Certificate content is validated against the selected profile; the default profile is issuing_ca. For example:

{
    "common_name": "Example Issuing CA",
    "organization_name": "Example",
    "country_name": "DE",
    "state_or_province_name": "Berlin",
    "days": 365
}

Use cert_profile_pk to select another profile. Subject/SAN/validity fields follow that profile’s requirements. CMP also accepts an optional integer sender_kid. Upstream client errors return 502.

For external signing, POST /api/issuing-cas/{id}/csr/ accepts the same certificate-content fields and returns a PEM CSR attachment. Then upload the issued certificate as the multipart certificate field to POST /api/issuing-cas/{id}/import-certificate/. The certificate must be a CA certificate with the required signing usages and must match the managed private key. Existing certificates cannot be replaced through these actions; use a rollover instead.

CRL configuration and inventory

PATCH /api/issuing-cas/{id}/crl-settings/ accepts any subset of:

{
    "crl_cycle_enabled": true,
    "crl_cycle_interval_hours": 12,
    "crl_validity_hours": 24,
    "auto_crl_on_revocation_enabled": true
}

Omitted settings are preserved. Interval, validity, CA activation, and security policy checks match the Web UI. Scheduling is updated through the existing CA scheduling service.

POST /api/issuing-cas/{id}/generate-crl/ and GET /api/issuing-cas/{id}/crl/?encoding=pem remain available. Fractional validity hours are preserved when generating a CRL.

The new inventory tracks historical and unassociated CRLs:

  • GET /api/crls/: list CRLs; filter by ca, is_active, or crl_number.

  • POST /api/crls/: upload crl_file in PEM or DER encoding, with optional ca and set_active (default true). When a CA is supplied, its subject and signature must match the CRL. Unassociated CRLs remain inactive.

  • GET /api/crls/{id}/: inspect metadata, issuer, PEM contents, and revocations. Serial numbers are hexadecimal strings to preserve their full precision.

  • GET /api/crls/{id}/download/?encoding=der: download PEM or DER contents.

  • DELETE /api/crls/{id}/: delete a CRL.

CRL identifiers always refer to CRL records, without falling back to CA IDs. Importing an active CRL deactivates the previous active CRL in the same transaction. Duplicate imports return 409 without changing the active CRL.

CA rollovers

GET /api/ca-rollovers/ lists rollover history. Filter by old_issuing_ca, new_issuing_ca, or state; retrieve one with GET /api/ca-rollovers/{id}/.

Plan a rollover with POST /api/ca-rollovers/. Supply old_issuing_ca and one of these method values:

  • pkcs12: pkcs12_file, optional pkcs12_password and unique_name.

  • separate_files: private_key_file, ca_certificate, optional private_key_file_password, ca_certificate_chain, and unique_name.

  • est or cmp: the corresponding upstream connection/authentication fields and key_type described above, with a new unique_name.

Optional transition_scheduled_at and notes apply to every method. Generated-key replacements remain in awaiting_new_ca until their CA certificate is enrolled or uploaded through the issuing CA API.

Advance the rollover through dedicated POST actions:

  • /api/ca-rollovers/{id}/start/

  • /api/ca-rollovers/{id}/transition/

  • /api/ca-rollovers/{id}/complete/

  • /api/ca-rollovers/{id}/cancel/

These actions enforce the existing rollover state machine and write the same audit events as the Web UI. Invalid state transitions return 409. Direct updates to rollover state fields are not supported.

Certificate details and downloads

Certificate reads and downloads require authentication, using the existing certificate API access policy.

GET /api/certificates/ now includes serial numbers, SHA-256 fingerprints, validity dates, status, CA/self-signed flags, issuer certificate identifiers, and public key algorithm/size. The original id and common_name fields remain available. Existing search, filters, ordering, and pagination apply.

GET /api/certificates/{id}/ additionally provides:

  • Subject and issuer attributes with OIDs, labels, and RDN grouping. Repeated distinguished-name attributes are preserved.

  • Signature algorithm, signature value, public key information, and PEM contents.

  • Every X.509 extension with its OID, criticality, decoded common-extension values, and exact DER contents as der_hex. Other extension values have a readable representation alongside their DER contents.

  • The known issuer chain as certificate identifiers, from direct issuer to root.

  • Revocation date, reason, and CA identifier, or null when not revoked.

  • Associated local issued-credential/device/profile identifiers and metadata, plus the number of certificates referencing this certificate as their issuer.

Serial numbers and fingerprints are hexadecimal strings, preserving their full precision. Status codes are OK, REV (revoked), EXP (expired), and NYV (not yet valid); status_display provides a readable label. X.509 version uses its stored zero-based enumeration (2 means version 3).

Single certificate download

Download a public certificate with:

GET /api/certificates/42/download/?file_format=pem

Supported file_format values are pem (default), der, pkcs7_pem, and pkcs7_der. Responses are binary attachments with the appropriate MIME type and filename extension. Filenames include certificate IDs so certificates with identical common names remain distinguishable.

Set include_chain=true to include known issuer certificates:

GET /api/certificates/42/download/?file_format=pkcs7_pem&include_chain=true

PEM downloads place the selected certificate before its issuers. PKCS#7 containers include the same certificate set. A single DER file cannot contain multiple certificates: use PEM, PKCS#7, or an archive to download a chain. Only issuer certificates already present in Trustpoint are included; no external certificates are fetched.

Multiple certificate download

Request an archive using JSON:

POST /api/certificates/download/
Content-Type: application/json

{
    "certificate_ids": [42, 43],
    "file_format": "pem",
    "archive_format": "zip",
    "include_chain": true
}

certificate_ids must contain between 1 and 1000 positive integers. archive_format supports zip (default) and tar_gz. Every selected certificate is a separate file in the chosen certificate format. With include_chain, known issuer certificates are also separate files, including when DER is selected. Duplicate selections and shared issuer certificates appear only once. Archive member names are safe, unique filenames.

Unknown certificate IDs return 404 without producing a partial archive. Unsupported formats, invalid options, and cyclic issuer relationships return 400. Downloads contain public certificates only, without private keys or credential bundles.