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

# Create sensitive trace endpoint

> Add a new sensitive trace endpoint.



## OpenAPI

````yaml /generated/openapi-generated-2023-12-01.json post /sensitive-trace-endpoints
openapi: 3.1.0
info:
  title: Prequel Data Export
  description: Data Export API spec
  version: '2023-12-01'
servers:
  - url: https://api.prequel.co
    description: Cloud-hosted server (US)
  - url: https://eu-api.prequel.co
    description: Cloud-hosted server (EU)
  - url: https://{custom_host}/
    description: Cloud-prem or shared-cloud server
security:
  - ApiKeyAuth: []
paths:
  /sensitive-trace-endpoints:
    post:
      tags:
        - Sensitive Trace Endpoints
      summary: Create sensitive trace endpoint
      description: Add a new sensitive trace endpoint.
      operationId: create-sensitive-trace-endpoint
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateSensitiveTraceEndpointRequest'
              $schema: https://json-schema.org/draft/2020-12/schema
              $id: >-
                https://github.com/prequel-co/datafeed/internal/shared/api/models/create-sensitive-trace-endpoint-request
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                properties:
                  status:
                    type: string
                    const: success
                  data:
                    $ref: '#/components/schemas/CreateSensitiveTraceEndpointResponse'
                    $schema: https://json-schema.org/draft/2020-12/schema
                    $id: >-
                      https://github.com/prequel-co/datafeed/internal/shared/api/models/create-sensitive-trace-endpoint-response
                  message:
                    type: string
                type: object
                required:
                  - status
                  - data
                  - message
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/InternalServerError'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    CreateSensitiveTraceEndpointRequest:
      properties:
        sensitive_trace_endpoint:
          $ref: '#/components/schemas/SensitiveTraceEndpointOptions'
      additionalProperties: false
      type: object
      required:
        - sensitive_trace_endpoint
    CreateSensitiveTraceEndpointResponse:
      properties:
        sensitive_trace_endpoint:
          $ref: '#/components/schemas/SensitiveTraceEndpointResource'
      additionalProperties: false
      type: object
      required:
        - sensitive_trace_endpoint
    SensitiveTraceEndpointOptions:
      properties:
        name:
          type: string
          description: The name of the sensitive trace endpoint.
        description:
          type: string
          description: Optional description of the sensitive trace endpoint.
        url:
          type: string
          pattern: ^https?://.+$
          description: The URL to send the sensitive trace to.
        header_template:
          type: string
          description: >-
            Optional template for the headers to send with the sensitive trace.
            If left empty default headers will be sent.
        secret:
          type: string
          description: Optional secret to authenticate the sensitive trace endpoint.
        body_template:
          type: string
          description: >-
            Optional template for the body to send with the sensitive trace. If
            left empty default body will be sent.
      additionalProperties: false
      type: object
      required:
        - name
        - url
    SensitiveTraceEndpointResource:
      properties:
        id:
          type: string
        name:
          type: string
        description:
          type: string
        url:
          type: string
        header_template:
          type: string
        body_template:
          type: string
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
      additionalProperties: false
      type: object
      required:
        - id
        - name
        - url
        - created_at
        - updated_at
    ErrorResponse:
      properties:
        status:
          type: string
          const: error
        message:
          type: string
        data:
          type: 'null'
      type: object
      required:
        - status
        - message
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    NotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    InternalServerError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY

````