---
updatedAt: 2025-04-29T20:31:46.000Z
agentTools:
  projectIndex: https://docs.border0.com/llms.txt
---

# Generate a cert request and sign the CSR with socket's CA cert

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "description": "https://border0.com",
    "title": "Border0 API",
    "contact": {},
    "version": "1.0"
  },
  "paths": {
    "/mtls-ca/socket/{socket_dnsname}/csr": {
      "post": {
        "security": [
          {
            "Border0_Token": []
          }
        ],
        "summary": "Generate a cert request and sign the CSR with socket's CA cert",
        "parameters": [
          {
            "description": "Socket DNS name",
            "name": "socket_dnsname",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/v1.certificateSigningRequest"
              }
            }
          },
          "description": "Update socket's custom cert",
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ca_certificate": {
                      "type": "string"
                    },
                    "client_certificate": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v1.BaseErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v1.BaseErrorResponse"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "Border0_Token": {
        "type": "apiKey",
        "name": "Authorization",
        "in": "header"
      }
    },
    "schemas": {
      "v1.BaseErrorResponse": {
        "type": "object",
        "properties": {
          "error_message": {
            "type": "string"
          },
          "status_code": {
            "type": "integer"
          }
        }
      },
      "v1.certificateSigningRequest": {
        "type": "object",
        "required": [
          "csr"
        ],
        "properties": {
          "csr": {
            "type": "string"
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  }
}
```