---
title: "Create a secret"
method: POST
path: "/secrets"
tags: ["secrets"]
---

# Create a secret

`POST /secrets`

## Request body

- SecretPost
  - `content` string, required — The contents of the secret.
  - `description` string — Description of the resource.
  - `mime_type` 'application/x-hotp-secret' | 'application/x-pem-file' | 'application/json', required — The mime_type of the secret format.

## Response `200`

The secret was successfully created.

- Secret
  - `description` string, required — Description of the resource.
  - `href` string, required — The endpoint for the secret resource.
  - `mime_type` 'application/x-hotp-secret' | 'application/x-pem-file' | 'application/json', required — The mime_type of the secret format.

---

[API](https://skmtc.dev/webscale/apis/webscale-apis.md) · [All operations](https://skmtc.dev/webscale/apis/webscale-apis/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/webscale/webscale-apis/revisions/c98d872b50cb/schema)
