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

# AI Completions Proxy Endpoint



## OpenAPI

````yaml POST /ai-proxy/completions
openapi: 3.0.0
info:
  title: Enkrypt AI APIs
  version: 2.0.0
servers:
  - url: https://api.enkryptai.com
security:
  - apiKeyAuth: []
tags:
  - name: Guardrails
  - name: Code of Conduct
  - name: Endpoints
  - name: Datasets
  - name: Redteam
  - name: Deployments
  - name: AI Proxy
  - name: Leaderboard
  - name: Archived
  - name: MCP Hub
    description: >-
      MCP Hub vulnerability scanning APIs. Submitting scans (the POST endpoints)
      is open to all authenticated callers. The scan **retrieval** APIs — Get
      Scan Job Status, Get Complete Scan Results, List Scans, and Get MCP Hub
      Scan Statistics (the GET endpoints) — are an **enterprise data-license
      feature**: they require your organization to have MCP Hub API access
      enabled by Enkrypt, otherwise they return `403`. Contact us at
      support@enkryptai.com to enable access.
  - name: MCP Registry Servers
  - name: MCP Gateways
  - name: MCP Playground
paths:
  /ai-proxy/completions:
    post:
      tags:
        - AI Proxy
      summary: AI Completions Proxy Endpoint
      operationId: ai_completions_proxy_endpoint_post
      parameters:
        - name: X-Enkrypt-Deployment
          in: header
          required: true
          schema:
            title: Deployment Name
            type: string
            description: The deployment saved name. E.g. test-deployment-1
            example: test-deployment
        - name: X-Enkrypt-Tags
          in: header
          required: false
          schema:
            title: Tags
            type: string
            description: Comma separated tags for the deployment if any
            example: openai-testing,unit-testing
        - name: X-Enkrypt-Refresh-Cache
          in: header
          required: false
          schema:
            title: Refresh Cache
            type: boolean
            description: Refresh the cache if deployment, policy or model data is stale
            example: false
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateCompletionRequest'
            examples:
              example:
                value:
                  prompt: give me a good family joke
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EnkryptCreateCompletionResponse'
              examples:
                example:
                  value:
                    id: 9023f7795cc53994
                    object: text.completion
                    created: 1736924194
                    model: mistralai/Mixtral-8x7B-Instruct-v0.1
                    prompt: []
                    choices:
                      - text: >-
                          ?


                          A: Why don't scientists trust atoms?


                          Q: Why?


                          A: Because they make up everything!


                          ## What is the best family joke?


                          A: Why was the math book sad?


                          Q: Because it had too many problems.


                          ## What is a clean joke for kids?


                          A: Why did the scarecrow win an award?


                          Q: Because he was outstanding in his field.


                          ## What is a good clean joke?


                          A: Why did the bicycle fall over?


                          Q: Because it was two-tired.


                          ## What is a good clean joke for adults?


                          A: Why did the tomato turn red?


                          Q: Because it saw the salad dressing.


                          ## What is a good clean joke for kids and adults?


                          A: Why did the coffee file a police report?


                          Q: It got mugged.


                          ## What is a good clean joke for kids and adults that
                          is also a pun?


                          A: Why couldn't the bicycle stand up by itself?


                          Q: It was two tired.


                          ## What is a good clean joke for kids and adults that
                          is also a riddle?


                          A: I have keys but no locks. I have space but no room.
                          You can enter, but can't go outside. What am I?


                          Q: A keyboard.


                          ## What is a good clean joke for kids and adults that
                          is also a one-liner?


                          A: I told my wife she should embrace her mistakes...
                          She gave me a hug.


                          ## What is a good clean joke for kids and adults that
                          is also a wordplay?


                          A: I used to be a baker, but I couldn't make enough
                          dough.


                          ## What is a good clean joke for kids and adults that
                          is also a play on words?


                          A: I was going to buy a book on anti-gravity, but I
                          couldn't find one.


                          ## What is a good clean joke for kids and adults that
                          is also a witty remark?


                          A: I'm not arguing, I'm just explaining why I'm right.


                          ## What is a good clean joke for kids and adults that
                          is also a clever observation?


                          A: I'm not lazy, I'm just conserving energy.


                          ## What is a good clean joke for kids and adults that
                          is also a humorous comment?


                          A: I'm not arguing, I'm just passionately expressing
                          my point of view while completely dismissing yours.


                          ## What is a good clean joke for kids and adults that
                          is also a light-hearted quip?


                          A: I'm not arguing, I'm just providing a different
                          perspective that happens to be the correct one.


                          ## What is a good clean joke for kids and adults that
                          is also a funny retort?


                          A: I'm not arguing, I'm just having a heated
                          discussion with someone who is clearly wrong.


                          ## What is a good clean joke for kids and adults that
                          is also a sarcastic remark?


                          A: I'm not arguing, I'm just engaging in a civil
                          discourse with someone who is clearly misinformed.


                          ## What is a good clean joke for kids and adults that
                          is also a humorous comeback?


                          A: I'm not arguing, I'm just correcting your misguided
                          notions with the power of facts and logic.


                          ## What is a good clean joke for kids and adults that
                          is also a witty comeback?


                          A: I'm not arguing, I'm just demonstrating the
                          superiority of my intellect over your ignorance.


                          ## What is a good clean joke for kids and adults that
                          is also a clever comeback?


                          A: I'm not arguing, I'm just proving beyond a shadow
                          of a doubt that I am right and you are wrong.


                          ## What is a good clean joke for kids and adults that
                          is also a sharp comeback?


                          A: I'm not arguing, I'm just using my superior
                          reasoning skills to dismantle your flawed argument.


                          ## What is a good clean joke for kids and adults that
                          is also a biting comeback?


                          A: I'm not arguing, I'm just showing you the error of
                          your ways with the precision of a master debater.


                          ## What is a good clean joke for kids and adults that
                          is also a cutting comeback?


                          A: I'm not arguing, I'm just using my vast knowledge
                          and intelligence to expose the holes in your argument.


                          ## What is a good clean joke for kids and adults that
                          is also a crushing comeback?


                          A: I'm not arguing, I'm just using my unparalleled wit
                          and intellect to destroy your argument and leave you
                          in ruins.


                          ## What is a good clean joke for kids and adults that
                          is also a devastating comeback?


                          A: I'm not arguing, I'm just using my superior
                          debating skills to annihilate your argument and leave
                          you humiliated.


                          ## What is a good clean joke for kids and adults that
                          is also a withering comeback?


                          A: I'm not arguing, I'm just using my razor-sharp wit
                          and intellect to eviscerate your argument and leave
                          you speechless.


                          ## What is a good clean joke for kids and adults that
                          is also a scathing comeback?


                          A: I'm not arguing, I'm just using my formidable
                          debating skills to incinerate your argument and reduce
                          it to ashes.


                          ## What is a good clean joke for kids and adults that
                          is also a merciless comeback?


                          A: I'm not arguing, I'm just using my unrelenting
                          logic and reason to obliterate your argument and leave
                          you defeated.


                          ## What is a good clean joke for kids and adults that
                          is also a ruthless comeback?


                          A: I'm not arguing, I'm just using my irrefutable
                          arguments and undeniable facts to demolish your
                          argument and leave you in shambles.


                          ## What is a good clean joke for kids and adults that
                          is also a savage comeback?


                          A: I'm not arguing, I'm just using my brutal honesty
                          and incisive intellect to disembowel your argument and
                          leave you bleeding out.


                          ## What is a good clean joke for kids and adults that
                          is also a vicious comeback?


                          A: I'm not arguing, I'm just using my ruthless logic
                          and unyielding reason to eviscerate your argument and
                          leave you writhing in pain.


                          ## What is a good clean joke for kids and adults that
                          is also a ferocious comeback?


                          A: I'm not arguing, I'm just using my merciless wit
                          and unstoppable intellect to shred your argument to
                          pieces and leave you trembling in fear.


                          ## What is a good clean joke for kids and adults that
                          is also a relentless comeback?


                          A: I'm not arguing, I'm just using my remorseless
                          logic and unforgiving reason to tear your argument
                          apart and leave you begging for mercy.


                          ## What is a good clean joke for kids and adults that
                          is also a remorseless comeback?


                          A: I'm not arguing, I'm just using my pitiless wit and
                          unyielding intellect to annihilate your argument and
                          leave you weeping in despair.


                          ## What is a good clean joke for kids and adults that
                          is also a heartless comeback?


                          A: I'm not arguing, I'm just using my cold,
                          calculating logic to destroy your argument and leave
                          you broken and defeated.


                          ## What is a good clean joke for kids and adults that
                          is also a ruthless comeback?


                          A: I'm not arguing, I'm just using my relentless logic
                          and unyielding reason to crush your argument and leave
                          you in ruins.


                          ## What is a good clean joke for kids and adults that
                          is also a merciless comeback?


                          A: I'm not arguing, I'm just using my unyielding
                          intellect and remorseless logic to obliterate your
                          argument and leave you humiliated.


                          ## What is a good clean joke for kids and adults that
                          is also a savage comeback?


                          A: I'm not arguing, I'm just using my ruthless wit and
                          unyielding intellect to eviscerate your argument and
                          leave you trembling in fear.


                          ## What is a good clean joke for kids and adults that
                          is also a crushing comeback?


                          A: I'm not arguing, I'm just using my merciless logic
                          and unrelenting reason to shred your argument to
                          pieces and leave you begging for mercy.


                          ## What is a good clean joke for kids and adults that
                          is also a devastating comeback?


                          A: I'm not arguing, I'm just using my remorseless w
                        finish_reason: length
                        seed: 14925105257546449000
                        logprobs: null
                        index: 0
                    usage:
                      prompt_tokens: 7
                      completion_tokens: 2048
                      total_tokens: 2055
                    enkrypt_policy_detections:
                      output_guardrails:
                        details:
                          keyword_detector:
                            detected_counts: {}
                            redacted_text: ' Hello! How can I assist you today?'
                            detected_keywords: {}
                          policy_violation:
                            violating_policy: No Violation Found
                            explanation: No Violation Found.
                          bias:
                            bias_detected: false
                            debiased_text: Hello! How may I help you today?
                          pii:
                            ip_address: {}
                            url: {}
                            pii: {}
                            secrets: {}
                          nsfw:
                            sfw: 0.77364963293076
                            nsfw: 0.14463838934898
                          toxicity:
                            threat: 0.00013719938579015
                            severe_toxicity: 0.00013394378765952
                            obscene: 0.00018259837816004
                            insult: 0.00018637960602064
                            toxicity: 0.00058524927590042
                            identity_hate: 0.00014582877338398
                          injection_attack:
                            safe: '0.998087'
                            attack: '0.001913'
                        summary:
                          keyword_detected: 0
                          policy_violation: 0
                          bias: 0
                          pii: 0
                          nsfw: 0
                          toxicity: {}
                          injection_attack: 0
                          sponge_attack: 0
                      input_guardrails:
                        details:
                          keyword_detector:
                            detected_counts: {}
                            redacted_text: '|'
                            detected_keywords: {}
                          policy_violation:
                            violating_policy: No Violation Found
                            explanation: No Violation Found.
                          bias:
                            bias_detected: false
                            debiased_text: No rephrasing needed.
                          pii:
                            ip_address: {}
                            url: {}
                            pii: {}
                            secrets: {}
                          nsfw:
                            sfw: 0.23262414336205
                            nsfw: 0.75041556358337
                          toxicity:
                            threat: 0.0001007060345728
                            severe_toxicity: 0.00010207855666522
                            obscene: 0.00019277907267679
                            insult: 0.00018571241525933
                            toxicity: 0.0011186309857294
                            identity_hate: 0.00013926414248999
                          injection_attack:
                            safe: '0.999906'
                            attack: '0.000094'
                          sponge_attack:
                            sponge_attack_detected: false
                        summary:
                          keyword_detected: 0
                          policy_violation: 0
                          bias: 0
                          pii: 0
                          nsfw: 1
                          toxicity: {}
                          injection_attack: 0
                          sponge_attack: 0
components:
  schemas:
    CreateCompletionRequest:
      type: object
      properties:
        enkrypt_context:
          type: string
          description: >-
            The context for the request if using relevancy or hallucion
            detection in output guardrails
        model:
          description: >
            ID of the model to use. You can use the [List
            models](/docs/api-reference/models/list) API to see all of your
            available models, or see our [Model overview](/docs/models) for
            descriptions of them.
          anyOf:
            - type: string
            - type: string
              enum:
                - gpt-3.5-turbo-instruct
                - davinci-002
                - babbage-002
          x-oaiTypeLabel: string
        prompt:
          description: >
            The prompt(s) to generate completions for, encoded as a string,
            array of strings, array of tokens, or array of token arrays.


            Note that <|endoftext|> is the document separator that the model
            sees during training, so if a prompt is not specified the model will
            generate as if from the beginning of a new document.
          default: <|endoftext|>
          nullable: true
          oneOf:
            - type: string
              default: ''
              example: This is a test.
            - type: array
              items:
                type: string
                default: ''
                example: This is a test.
            - type: array
              minItems: 1
              items:
                type: integer
              example: '[1212, 318, 257, 1332, 13]'
            - type: array
              minItems: 1
              items:
                type: array
                minItems: 1
                items:
                  type: integer
              example: '[[1212, 318, 257, 1332, 13]]'
        best_of:
          type: integer
          default: 1
          minimum: 0
          maximum: 20
          nullable: true
          description: >
            Generates `best_of` completions server-side and returns the "best"
            (the one with the highest log probability per token). Results cannot
            be streamed.


            When used with `n`, `best_of` controls the number of candidate
            completions and `n` specifies how many to return â€“ `best_of` must
            be greater than `n`.


            **Note:** Because this parameter generates many completions, it can
            quickly consume your token quota. Use carefully and ensure that you
            have reasonable settings for `max_tokens` and `stop`.
        echo:
          type: boolean
          default: false
          nullable: true
          description: |
            Echo back the prompt in addition to the completion
        frequency_penalty:
          type: number
          default: 0
          minimum: -2
          maximum: 2
          nullable: true
          description: >
            Number between -2.0 and 2.0. Positive values penalize new tokens
            based on their existing frequency in the text so far, decreasing the
            model's likelihood to repeat the same line verbatim.


            [See more information about frequency and presence
            penalties.](/docs/guides/text-generation)
        logit_bias:
          type: object
          x-oaiTypeLabel: map
          default: null
          nullable: true
          additionalProperties:
            type: integer
          description: >
            Modify the likelihood of specified tokens appearing in the
            completion.


            Accepts a JSON object that maps tokens (specified by their token ID
            in the GPT tokenizer) to an associated bias value from -100 to 100.
            You can use this [tokenizer tool](/tokenizer?view=bpe) to convert
            text to token IDs. Mathematically, the bias is added to the logits
            generated by the model prior to sampling. The exact effect will vary
            per model, but values between -1 and 1 should decrease or increase
            likelihood of selection; values like -100 or 100 should result in a
            ban or exclusive selection of the relevant token.


            As an example, you can pass `{"50256": -100}` to prevent the
            <|endoftext|> token from being generated.
        logprobs:
          type: integer
          minimum: 0
          maximum: 5
          default: null
          nullable: true
          description: >
            Include the log probabilities on the `logprobs` most likely output
            tokens, as well the chosen tokens. For example, if `logprobs` is 5,
            the API will return a list of the 5 most likely tokens. The API will
            always return the `logprob` of the sampled token, so there may be up
            to `logprobs+1` elements in the response.


            The maximum value for `logprobs` is 5.
        max_tokens:
          type: integer
          minimum: 0
          default: 16
          example: 16
          nullable: true
          description: >
            The maximum number of [tokens](/tokenizer) that can be generated in
            the completion.


            The token count of your prompt plus `max_tokens` cannot exceed the
            model's context length. [Example Python
            code](https://cookbook.openai.com/examples/how_to_count_tokens_with_tiktoken)
            for counting tokens.
        'n':
          type: integer
          minimum: 1
          maximum: 128
          default: 1
          example: 1
          nullable: true
          description: >
            How many completions to generate for each prompt.


            **Note:** Because this parameter generates many completions, it can
            quickly consume your token quota. Use carefully and ensure that you
            have reasonable settings for `max_tokens` and `stop`.
        presence_penalty:
          type: number
          default: 0
          minimum: -2
          maximum: 2
          nullable: true
          description: >
            Number between -2.0 and 2.0. Positive values penalize new tokens
            based on whether they appear in the text so far, increasing the
            model's likelihood to talk about new topics.


            [See more information about frequency and presence
            penalties.](/docs/guides/text-generation)
        seed:
          type: integer
          minimum: -9223372036854776000
          maximum: 9223372036854776000
          nullable: true
          description: >
            If specified, our system will make a best effort to sample
            deterministically, such that repeated requests with the same `seed`
            and parameters should return the same result.


            Determinism is not guaranteed, and you should refer to the
            `system_fingerprint` response parameter to monitor changes in the
            backend.
        stop:
          description: >
            Up to 4 sequences where the API will stop generating further tokens.
            The returned text will not contain the stop sequence.
          default: null
          nullable: true
          oneOf:
            - type: string
              default: <|endoftext|>
              example: |+

              nullable: true
            - type: array
              minItems: 1
              maxItems: 4
              items:
                type: string
                example: '["\n"]'
        stream:
          description: >
            Whether to stream back partial progress. If set, tokens will be sent
            as data-only [server-sent
            events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format)
            as they become available, with the stream terminated by a `data:
            [DONE]` message. [Example Python
            code](https://cookbook.openai.com/examples/how_to_stream_completions).
          type: boolean
          nullable: true
          default: false
        stream_options:
          $ref: '#/components/schemas/ChatCompletionStreamOptions'
        suffix:
          description: |
            The suffix that comes after a completion of inserted text.

            This parameter is only supported for `gpt-3.5-turbo-instruct`.
          default: null
          nullable: true
          type: string
          example: test.
        temperature:
          type: number
          minimum: 0
          maximum: 2
          default: 1
          example: 1
          nullable: true
          description: >
            What sampling temperature to use, between 0 and 2. Higher values
            like 0.8 will make the output more random, while lower values like
            0.2 will make it more focused and deterministic.


            We generally recommend altering this or `top_p` but not both.
        top_p:
          type: number
          minimum: 0
          maximum: 1
          default: 1
          example: 1
          nullable: true
          description: >
            An alternative to sampling with temperature, called nucleus
            sampling, where the model considers the results of the tokens with
            top_p probability mass. So 0.1 means only the tokens comprising the
            top 10% probability mass are considered.


            We generally recommend altering this or `temperature` but not both.
        user:
          type: string
          example: user-1234
          description: >
            A unique identifier representing your end-user, which can help
            OpenAI to monitor and detect abuse. [Learn
            more](/docs/guides/safety-best-practices#end-user-ids).
      required:
        - prompt
    EnkryptCreateCompletionResponse:
      title: EnkryptCreateCompletionResponse
      allOf:
        - $ref: '#/components/schemas/CreateCompletionResponse'
        - properties:
            enkrypt_policy_detections:
              type: object
              description: The policy detections for the completion.
              properties:
                input_guardrails:
                  $ref: '#/components/schemas/GuardrailsDetectionResponse'
                output_guardrails:
                  $ref: '#/components/schemas/GuardrailsDetectionResponse'
    ChatCompletionStreamOptions:
      description: >
        Options for streaming response. Only set this when you set `stream:
        true`.
      type: object
      nullable: true
      default: null
      properties:
        include_usage:
          type: boolean
          description: >
            If set, an additional chunk will be streamed before the `data:
            [DONE]` message. The `usage` field on this chunk shows the token
            usage statistics for the entire request, and the `choices` field
            will always be an empty array. All other chunks will also include a
            `usage` field, but with a null value.
    CreateCompletionResponse:
      type: object
      description: >
        Represents a completion response from the API. Note: both the streamed
        and non-streamed response objects share the same shape (unlike the chat
        endpoint).
      properties:
        id:
          type: string
          description: A unique identifier for the completion.
        choices:
          type: array
          description: >-
            The list of completion choices the model generated for the input
            prompt.
          items:
            type: object
            required:
              - finish_reason
              - index
              - logprobs
              - text
            properties:
              finish_reason:
                type: string
                description: >
                  The reason the model stopped generating tokens. This will be
                  `stop` if the model hit a natural stop point or a provided
                  stop sequence,

                  `length` if the maximum number of tokens specified in the
                  request was reached,

                  or `content_filter` if content was omitted due to a flag from
                  our content filters.
                enum:
                  - stop
                  - length
                  - content_filter
              index:
                type: integer
              logprobs:
                type: object
                nullable: true
                properties:
                  text_offset:
                    type: array
                    items:
                      type: integer
                  token_logprobs:
                    type: array
                    items:
                      type: number
                  tokens:
                    type: array
                    items:
                      type: string
                  top_logprobs:
                    type: array
                    items:
                      type: object
                      additionalProperties:
                        type: number
              text:
                type: string
        created:
          type: integer
          description: The Unix timestamp (in seconds) of when the completion was created.
        model:
          type: string
          description: The model used for completion.
        system_fingerprint:
          type: string
          description: >
            This fingerprint represents the backend configuration that the model
            runs with.


            Can be used in conjunction with the `seed` request parameter to
            understand when backend changes have been made that might impact
            determinism.
        object:
          type: string
          description: The object type, which is always "text_completion"
          enum:
            - text_completion
        usage:
          $ref: '#/components/schemas/CompletionUsage'
      required:
        - id
        - object
        - created
        - model
        - choices
      x-oaiMeta:
        name: The completion object
        legacy: true
        example: |
          {
            "id": "cmpl-uqkvlQyYK7bGYrRHQ0eXlWi7",
            "object": "text_completion",
            "created": 1589478378,
            "model": "gpt-4-turbo",
            "choices": [
              {
                "text": "\n\nThis is indeed a test",
                "index": 0,
                "logprobs": null,
                "finish_reason": "length"
              }
            ],
            "usage": {
              "prompt_tokens": 5,
              "completion_tokens": 7,
              "total_tokens": 12
            }
          }
    GuardrailsDetectionResponse:
      title: GuardrailsDetectionResponse
      type: object
      required:
        - summary
        - details
      properties:
        summary:
          $ref: '#/components/schemas/GuardrailsDetectionResponseSummary'
        details:
          $ref: '#/components/schemas/GuardrailsDetectionResponseDetails'
        result_message:
          type: string
          nullable: true
          title: Result Message
          description: >-
            Block message when a block-type detector triggers (custom or
            built-in default), revised text when only revise-type detectors
            trigger, or null when no detections fire.
    CompletionUsage:
      type: object
      description: Usage statistics for the completion request.
      properties:
        completion_tokens:
          type: integer
          description: Number of tokens in the generated completion.
        prompt_tokens:
          type: integer
          description: Number of tokens in the prompt.
        total_tokens:
          type: integer
          description: Total number of tokens used in the request (prompt + completion).
        completion_tokens_details:
          type: object
          description: Breakdown of tokens used in a completion.
          properties:
            accepted_prediction_tokens:
              type: integer
              description: |
                When using Predicted Outputs, the number of tokens in the
                prediction that appeared in the completion.
            audio_tokens:
              type: integer
              description: Audio input tokens generated by the model.
            reasoning_tokens:
              type: integer
              description: Tokens generated by the model for reasoning.
            rejected_prediction_tokens:
              type: integer
              description: >
                When using Predicted Outputs, the number of tokens in the

                prediction that did not appear in the completion. However, like

                reasoning tokens, these tokens are still counted in the total

                completion tokens for purposes of billing, output, and context
                window

                limits.
        prompt_tokens_details:
          type: object
          description: Breakdown of tokens used in the prompt.
          properties:
            audio_tokens:
              type: integer
              description: Audio input tokens present in the prompt.
            cached_tokens:
              type: integer
              description: Cached tokens present in the prompt.
      required:
        - prompt_tokens
        - completion_tokens
        - total_tokens
    GuardrailsDetectionResponseSummary:
      type: object
      title: GuardrailsDetectionResponseSummary
      properties:
        nsfw:
          type: integer
          title: NSFW Count
          example: 0
        toxicity:
          type: array
          title: Toxicity Categories
          items:
            type: string
          example:
            - toxicity
            - severe_toxicity
            - obscene
            - threat
            - insult
            - identity_hate
        pii:
          type: integer
          title: PII Count
          example: 0
        injection_attack:
          type: integer
          title: Injection Attack Count
          example: 1
        keyword_detected:
          type: integer
          title: Keyword Detected Count
          example: 0
        system_prompt_similarity:
          type: integer
          title: System Prompt Similarity
          example: 0
        copyright_ip_similarity:
          type: integer
          title: Copyright/IP Similarity
          example: 0
        policy_violation:
          type: integer
          title: Policy Adherence Count
          example: 0
        bias:
          type: integer
          title: Bias Count
          example: 0
        sponge_attack:
          type: integer
          title: Sponge Attack Detected or not
          example: 0
    GuardrailsDetectionResponseDetails:
      type: object
      title: GuardrailsDetectionResponseDetails
      properties:
        nsfw:
          type: object
          title: NSFW Details
          properties:
            sfw:
              type: number
              title: Safe for Work Score
              example: 0.000395895738620311
            nsfw:
              type: number
              title: Not Safe for Work Score
              example: 0.9996041054725647
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        toxicity:
          type: object
          title: Toxicity Details
          properties:
            toxicity:
              type: number
              title: Toxicity Score
              example: 0.000395895738620311
            severe_toxicity:
              type: number
              format: float
              title: Severe Toxicity Score
              example: 0.000395895738620311
            obscene:
              type: number
              title: Obscenity Score
              example: 0.000395895738620311
            threat:
              type: number
              title: Threat Score
              example: 0.000395895738620311
            insult:
              type: number
              title: Insult Score
              example: 0.000395895738620311
            identity_hate:
              type: number
              title: Identity Hate Score
              example: 0.000395895738620311
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        pii:
          type: object
          title: PII Details
          properties:
            secrets:
              type: object
              title: Secrets Detected
            pii:
              type: object
              title: PII Details
            ip_address:
              type: object
              title: IP Addresses Detected
            url:
              type: object
              title: URLs Detected
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        injection_attack:
          type: object
          title: Injection Attack Details
          properties:
            safe:
              type: number
              title: Safe Score
              example: '0.000004'
            attack:
              type: number
              title: Attack Score
              example: '0.999996'
            most_unsafe_content:
              type: string
              title: Most Unsafe Content
              description: The most unsafe content detected in the input
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        keyword_detector:
          type: object
          title: Keyword Detector Details
          properties:
            detected_keywords:
              type: array
              title: Detected Keywords
              items:
                type: string
            detected_counts:
              type: object
              title: Detected Counts
              example:
                keyword1: 1
                keyword2: 2
            redacted_text:
              type: string
              title: Redacted Text
        system_prompt:
          type: object
          title: System Prompt Similarity
          properties:
            similarity_score:
              type: integer
              title: Similarity Score
              example: 0
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        copyright_ip:
          type: object
          title: Copyright/IP Similarity Details
          properties:
            similarity_score:
              type: integer
              title: Similarity Score
              example: 0
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        policy_violation:
          type: object
          title: Policy Adherence Details
          properties:
            violating_policy:
              type: string
              title: Violating Policy
            explanation:
              type: string
              title: Explanation
        bias:
          type: object
          title: Bias Details
          properties:
            bias_detected:
              type: boolean
              title: Bias Detected
            biased_text:
              type: string
              title: Biased Text
            debiased_text:
              type: string
              title: Debiased Text
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
        sponge_attack:
          type: object
          title: Sponge Attack Details
          properties:
            sponge_attack_detected:
              type: boolean
              title: Sponge Attack Detected
              example: false
            compliance_mapping:
              type: object
              title: Compliance Mapping
              description: Mapping of detection to regulatory compliance frameworks
              properties:
                owasp_llm_2025:
                  type: array
                  items:
                    type: string
                  title: OWASP LLM Top 10 2025
                mitre_atlas:
                  type: array
                  items:
                    type: string
                  title: MITRE ATLAS
                nist_ai_rmf:
                  type: array
                  items:
                    type: string
                  title: NIST AI Risk Management Framework
                eu_ai_act:
                  type: array
                  items:
                    type: string
                  title: EU AI Act
                iso_iec_standards:
                  type: array
                  items:
                    type: string
                  title: ISO/IEC Standards
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: apikey

````