> ## 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.

# Modify Model



## OpenAPI

````yaml PATCH /models/modify-model
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:
  /models/modify-model:
    patch:
      tags:
        - Endpoints
      summary: Modify Model
      operationId: modify_model
      parameters:
        - name: X-Enkrypt-Model
          in: header
          required: true
          schema:
            title: Model Name
            type: string
            description: The model saved name. E.g. Test Model
            example: Test Model
        - name: X-Enkrypt-Model-Version
          in: header
          required: true
          schema:
            title: Model Version
            type: string
            description: The model version. Default is 'v1'
            example: v1
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ModelRequestObject'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModifyModelResponseObject'
components:
  schemas:
    ModelRequestObject:
      title: ModelRequestObject
      type: object
      required:
        - model_saved_name
        - model_version
      allOf:
        - $ref: '#/components/schemas/ModelCustomRequestObject'
      properties:
        model_saved_name:
          title: Model Saved Name
          type: string
          description: Name of the saved model
          example: Test Model
        model_version:
          title: Model Version
          type: string
          description: Custom identifier for the model
          example: v1
      example:
        model_saved_name: Test Model
        model_version: v1
        testing_for: foundationModels
        model_name: mistralai/Mixtral-8x7B-Instruct-v0.1
        certifications: []
        model_config:
          model_provider: together
          hosting_type: External
          input_modalities:
            - text
          output_modalities:
            - text
          model_source: https://together.ai
          rate_per_min: 20
          system_prompt: ''
          endpoint:
            scheme: https
            host: api.together.xyz
            port: 443
            base_path: /v1
          paths:
            completions: /completions
            chat: /chat/completions
          auth_data:
            header_name: Authorization
            header_prefix: Bearer
            space_after_prefix: true
          apikeys:
            - xxxxx
          metadata: {}
          default_request_options: {}
    ModifyModelResponseObject:
      title: ModifyModelResponseObject
      type: object
      properties:
        message:
          title: Message
          type: string
          example: Model details updated successfully
        data:
          $ref: '#/components/schemas/GetModelResponseObject'
    ModelCustomRequestObject:
      title: ModelCustomRequestObject
      type: object
      required:
        - model_config
      properties:
        testing_for:
          title: Testing For
          type: string
          description: Purpose of testing
          enum:
            - foundationModels
            - chatbotsAndCopilots
            - agents
            - URL
          example: foundationModels
        model_name:
          title: Model Name
          type: string
          description: Name of the model. Required for foundationModels
          example: mistralai/Mixtral-8x7B-Instruct-v0.1
        certifications:
          title: Certifications
          type: array
          items:
            title: Certification
            type: string
          description: List of certifications
          example:
            - GDPR
            - CCPA
            - HIPAA
            - SOC 2 Type II
            - SOC 3
        model_config:
          title: Model Config
          type: object
          required:
            - model_provider
          properties:
            model_provider:
              title: Model Provider
              type: string
              description: >-
                Provider of the model which determines the request response
                format
              enum:
                - openai
                - together
                - huggingface
                - groq
                - azure_openai
                - anthropic
                - cohere
                - bedrock
                - gemini
                - ai21
                - fireworks
                - alibaba
                - portkey
                - deepseek
                - mistral
                - llama
                - openai_compatible
                - cohere_compatible
                - anthropic_compatible
                - custom
                - url
                - enkryptai
                - sierra
                - boxai
                - nutanix
                - xactly
              example: together
            hosting_type:
              title: Hosting Type
              type: string
              description: Hosting type of the model
              enum:
                - External
                - Internal
              example: External
            model_source:
              title: Model Source
              type: string
              description: Source of the model
              example: https://together.ai
            tools:
              title: Tools
              type: array
              items:
                title: Tool
                type: object
                required:
                  - name
                  - description
                properties:
                  name:
                    title: Tool Name
                    type: string
                    description: Name of the tool
                    example: web_search
                  description:
                    title: Tool Description
                    type: string
                    description: Description of what the tool does
                    example: >-
                      The tool web search is used to search the web for
                      information related to finance.
              description: Array of tools available to the model
              example:
                - name: web_search
                  description: >-
                    The tool web search is used to search the web for
                    information related to finance.
            input_modalities:
              title: Input Modalities
              type: array
              description: Types of input that the model can process
              items:
                type: string
                enum:
                  - text
                  - image
                  - audio
              example:
                - text
            output_modalities:
              title: Output Modalities
              type: array
              description: Types of output that the model can generate
              items:
                type: string
                enum:
                  - text
              example:
                - text
            rate_per_min:
              type: number
              title: Rate Per Min that the model supports.
              description: >-
                < 100 won't enable async. > 100 will enable async mode. > 200 we
                can run boosted async (all tests in parallel). Default 20.
              example: 20
            system_prompt:
              title: System Prompt
              type: string
              description: System prompt
              example: ''
            endpoint:
              title: Endpoint
              type: object
              required:
                - scheme
                - host
                - port
                - base_path
              properties:
                scheme:
                  title: Scheme
                  type: string
                  description: Scheme of the endpoint
                  example: https
                host:
                  title: Host
                  type: string
                  description: Host of the endpoint
                  example: api.together.xyz
                port:
                  title: Port
                  type: integer
                  description: Port of the endpoint
                  example: 443
                base_path:
                  title: Base Path
                  type: string
                  description: Base path of the endpoint
                  example: /v1
            paths:
              title: Paths
              type: object
              properties:
                completions:
                  title: Completions
                  type: string
                  example: /completions
                chat:
                  title: Chat
                  type: string
                  example: /chat/completions
            auth_data:
              title: Auth Data
              type: object
              properties:
                header_name:
                  title: Header Name
                  type: string
                  example: Authorization
                header_prefix:
                  title: Header Prefix
                  type: string
                  example: Bearer
                space_after_prefix:
                  title: Space After Prefix
                  type: boolean
                  example: true
                param_name:
                  title: Param Name
                  type: string
                  example: token
                azure_client_id:
                  title: Azure Client ID
                  type: string
                  example: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
                azure_client_secret:
                  title: Azure Client Secret
                  type: string
                  example: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
                azure_tenant_id:
                  title: Azure Tenant ID
                  type: string
                  example: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
                gcp_service_account_json:
                  title: GCP Service Account JSON
                  type: string
                  example: >-
                    {"type":"service_account","project_id":"xxxxxxxx","private_key_id":"xxxxxxxx","private_key":"xxxxxxxx","client_email":"xxxxxxxx","client_id":"xxxxxxxx","auth_uri":"https://accounts.google.com/o/oauth2/auth","token_uri":"https://oauth2.googleapis.com/token","auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs","client_x509_cert_url":"https://www.googleapis.com/robot/v1/metadata/x509/xxxxxxxx@xxxxxxxx.iam.gserviceaccount.com"}
                aws_access_key_id:
                  title: AWS Access Key ID
                  type: string
                  example: xxxxxxxx
                aws_secret_access_key:
                  title: AWS Secret Access Key
                  type: string
                  example: xxxxxxxx
                allow_override:
                  title: Allow Override
                  type: boolean
                  description: >-
                    If enabled, the authorization header or parameter can be
                    overridden in the request by the value configured here
                  example: false
                boxai_client_id:
                  title: BoxAI Client ID
                  type: string
                  example: BOX_CLIENT_ID
                  description: BoxAI client ID for authentication
                boxai_client_secret:
                  title: BoxAI Client Secret
                  type: string
                  example: BOX_CLIENT_SECRET
                  description: BoxAI client secret for authentication
                boxai_user_id:
                  title: BoxAI User ID
                  type: string
                  example: BOX_USER_ID
                  description: BoxAI user ID for authentication
                boxai_default_file_id:
                  title: BoxAI Default File ID
                  type: string
                  example: BOX_FILE_ID
                  description: BoxAI default file ID for operations
                nutanix_user_session_id:
                  title: Nutanix User Session ID
                  type: string
                  example: NUTANIX_USER_SESSION_ID
                  description: Nutanix user session ID for authentication
                nutanix_email_id:
                  title: Nutanix Email ID
                  type: string
                  example: NUTANIX_EMAIL_ID
                  description: Nutanix email ID for authentication
                xactly_username:
                  title: Xactly Username
                  type: string
                  example: XACTLY_USERNAME
                  description: Xactly username for authentication
                xactly_password:
                  title: Xactly Password
                  type: string
                  example: XACTLY_PASSWORD
                  description: Xactly password for authentication
            apikeys:
              title: API Keys
              type: array
              items:
                title: API Key
                type: string
              example:
                - TOGETHER_AI_API_KEY
            model_auth_type:
              title: Model Auth Type (apikey or jwt)
              type: string
              enum:
                - apikey
                - jwt
              example: apikey
            model_jwt_config:
              title: Model Custom Auth Token Config
              type: object
              properties:
                jwt_method:
                  title: Token Method
                  type: string
                  enum:
                    - POST
                    - GET
                  example: POST
                jwt_url:
                  title: Token URL
                  type: string
                  example: https://example.com/api/auth
                jwt_headers:
                  type: array
                  title: Custom Token Headers
                  description: Array of custom headers to be sent with token requests
                  items:
                    type: object
                    required:
                      - key
                      - value
                    properties:
                      key:
                        type: string
                        title: Header Key
                        description: The name/key of the custom header
                        example: x-custom-header
                      value:
                        type: string
                        title: Header Value
                        description: The value of the custom header
                        example: custom-value
                  example:
                    - key: content-type
                      value: application/x-www-form-urlencoded
                    - key: x-custom-header
                      value: custom-value
                jwt_body:
                  type: string
                  title: Token Body
                  description: The body of the token request
                  example: >-
                    grant_type=client_credentials&client_id=xxxxxxxxxx&client_secret=xxxxxxxxxx
                jwt_response_key:
                  type: string
                  title: JWT Response Key
                  description: The key of the token in the response in jq format
                  example: .access_token
            custom_curl_command:
              title: Custom Curl Command
              type: string
              example: |-
                curl --location 'https://example.com/api/chat' \
                --header 'Accept: application/json, text/plain, */*' \
                --header 'Accept-Language: en-US,en;q=0.9' \
                --header 'Authorization: {token}' \
                --header 'Connection: keep-alive' \
                --header 'Content-Type: application/json' \
                --data '{"prompt":"{prompt}"}'
            custom_headers:
              type: array
              title: Custom Headers
              description: Array of custom headers to be sent with requests
              items:
                type: object
                required:
                  - key
                  - value
                properties:
                  key:
                    type: string
                    title: Header Key
                    description: The name/key of the custom header
                    example: X-Custom-Header
                  value:
                    type: string
                    title: Header Value
                    description: The value of the custom header
                    example: custom-value
              example:
                - key: X-Custom-Header
                  value: custom-value
            custom_payload:
              type: object
              title: Custom Payload
              description: >-
                A flexible object that can contain any custom key-value pairs
                for the request payload. Only condition is to include {prompt}
                in the payload.
              additionalProperties: true
              example:
                messages:
                  - role: developer
                    content: You are a helpful assistant.
                  - role: user
                    content: '{prompt}'
            custom_response_content_type:
              type: string
              title: Custom Response Content Type
              description: >-
                Content type of the custom response. Currently only supports
                JSON.
              enum:
                - json
              example: json
            custom_response_format:
              type: string
              title: Custom Response Format
              description: >-
                Optional response format path. Jq format for json type (e.g.
                '.choices[0].message.content')
              example: .choices[0].message.content
            metadata:
              title: Metadata
              type: object
              properties:
                max_tokens:
                  title: Max Tokens
                  type: integer
                  example: 2048
                input_cost_1M_tokens:
                  title: Input Cost 1M Tokens
                  type: number
                  example: 2.5
                output_cost_1M_tokens:
                  title: Output Cost 1M Tokens
                  type: number
                  example: 10
                azure_instance:
                  title: Azure Instance
                  type: string
                  description: If Azure, it's instance type
                  example: enkrypt2024
                azure_api_version:
                  title: Azure API Version
                  type: string
                  description: If Azure, it's API version
                  example: '2024-02-01'
                azure_deployment_id:
                  title: Azure Deployment ID
                  type: string
                  description: If Azure, it's deployment ID
                  example: gpt3
                anthropic_version:
                  title: Anthropic Version
                  type: string
                  description: If Anthropic, it's version
                  example: ''
                llama2_format:
                  title: Llama2 Format
                  type: string
                  description: If Llama2, it's format
                  enum:
                    - openai
                  example: openai
                mistral_format:
                  title: Mistral Format
                  type: string
                  description: If Mistral, it's format
                  enum:
                    - openai
                    - ollama
                  example: openai
                gemini:
                  title: Gemini
                  type: object
                  properties:
                    api_endpoint:
                      title: API Endpoint
                      type: string
                      description: >-
                        If running Gemini on Vertex, specify the regional API
                        endpoint (hostname only)
                      example: ''
                    project_id:
                      title: Project ID
                      type: string
                      description: If running Gemini on Vertex, specify the project ID
                      example: ''
                    location_id:
                      title: Location ID
                      type: string
                      description: If running Gemini on Vertex, specify the location ID
                      example: ''
                bedrock:
                  title: Bedrock
                  type: object
                  properties:
                    aws_region:
                      title: AWS Region
                      type: string
                      description: >-
                        If using AWS providers (Bedrock) you can override the
                        default AWS_REGION 'us-east-1' by setting this option
                      example: ''
                enkryptai:
                  title: EnkryptAI
                  type: object
                  properties:
                    deployment_name:
                      title: Deployment Name
                      type: string
                      description: If using EnkryptAI, specify the deployment name
                      example: test-deployment-1
                xactly:
                  title: Xactly
                  type: object
                  properties:
                    assistant_id:
                      title: Assistant ID
                      type: string
                      example: XACTLY_ASSISTANT_ID
                      description: Xactly assistant ID for authentication
            default_request_options:
              title: Default Request Options
              type: object
              properties:
                temperature:
                  title: Temperature
                  type: number
                  example: 1
                top_p:
                  title: Top P
                  type: number
                  example: 1
                top_k:
                  title: Top K
                  type: integer
                  example: 0
      example:
        testing_for: foundationModels
        model_name: mistralai/Mixtral-8x7B-Instruct-v0.1
        certifications: []
        model_config:
          model_provider: together
          hosting_type: External
          input_modalities:
            - text
          output_modalities:
            - text
          model_source: https://together.ai
          rate_per_min: 20
          system_prompt: ''
          endpoint:
            scheme: https
            host: api.together.xyz
            port: 443
            base_path: /v1
          paths:
            completions: /completions
            chat: /chat/completions
          auth_data:
            header_name: Authorization
            header_prefix: Bearer
            space_after_prefix: true
          apikeys:
            - xxxxx
          metadata: {}
          default_request_options: {}
    GetModelResponseObject:
      title: GetModelResponseObject
      type: object
      allOf:
        - $ref: '#/components/schemas/ModelRequestObject'
      properties:
        model_id:
          title: Model ID
          type: integer
          example: 1234567890
        created_at:
          title: Created At
          type: string
          format: date-time
          example: '2024-10-15T17:22:47.872389+00:00'
        updated_at:
          title: Updated At
          type: string
          format: date-time
          example: '2024-10-15T17:22:47.872389+00:00'
        project_name:
          title: Project Name
          type: string
          example: default
      example:
        created_at: '2024-10-15T17:22:47.872389+00:00'
        updated_at: '2024-10-15T17:22:47.872389+00:00'
        model_id: 1234567890
        testing_for: foundationModels
        model_saved_name: Test Model
        model_version: v1
        model_provider: together
        model_name: mistralai/Mixtral-8x7B-Instruct-v0.1
        project_name: default
        hosting_type: External
        certifications: []
        model_config:
          paths:
            chat: /chat/completions
            completions: /completions
          apikeys:
            - xxxxx
          endpoint:
            host: api.together.xyz
            port: 443
            scheme: https
            base_path: /v1
          auth_data:
            header_name: Authorization
            header_prefix: Bearer
            space_after_prefix: true
          input_modalities:
            - text
          output_modalities:
            - text
          model_source: https://together.ai
          system_prompt: ''
          tools:
            - name: web_search
              description: >-
                The tool web search is used to search the web for information
                related to finance.
          metadata: {}
          default_request_options: {}
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: apikey

````