> ## Documentation Index
> Fetch the complete documentation index at: https://docs.prophecy.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Add secret to fabric

> Create a new secret in a specific fabric



## OpenAPI

````yaml post /api/orchestration/fabric/{fabricId}/secret
openapi: 3.0.3
info:
  title: Prophecy Secrets API
  description: API for managing Prophecy secrets
  version: 1.0.0
servers: []
security: []
paths:
  /api/orchestration/fabric/{fabricId}/secret:
    parameters:
      - name: fabricId
        in: path
        description: The unique ID of the parent fabric
        required: true
        schema:
          type: string
    post:
      tags:
        - Secrets
      summary: Add secret to fabric
      description: Create a new secret in a specific fabric
      operationId: createSecret
      parameters:
        - $ref: '#/components/parameters/X-AUTH-TOKEN'
      requestBody:
        description: Secret object to be created. Properties vary by `subKind`.
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - kind
                - subKind
                - properties
              properties:
                kind:
                  type: string
                  description: Secret management provider
                  enum:
                    - prophecy
                subKind:
                  type: string
                  description: Secret sub-type
                  enum:
                    - text
                    - binary
                    - username_password
                    - m2m_oauth
                properties:
                  type: object
                  description: >-
                    Secret properties that vary by `subKind`.


                    Find specific properties in the **Secrets > Properties**
                    section of the API documentation.
            example:
              subKind: text
              properties:
                name: your-secret-name
                value: your-secret-value
              kind: prophecy
      responses:
        '200':
          description: Secret created successfully
          content:
            application/json:
              schema:
                type: object
                required:
                  - success
                properties:
                  success:
                    type: boolean
                    description: Indicates the request was successful.
                    enum:
                      - true
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        description: The unique identifier for the created secret.
                    description: Response data containing the secret ID.
              example:
                success: true
                data:
                  id: '4657'
components:
  parameters:
    X-AUTH-TOKEN:
      name: X-AUTH-TOKEN
      in: header
      description: Prophecy authentication token. Required for all API requests.
      required: true
      schema:
        type: string

````