Portkey website screenshot

Portkey

Portkey equips AI teams with everything they need to go to production - Gateway, Observability, Guardrails, Governance, and Prompt Management, all in one platform.

3 APIs 0 Features
AI GatewaysGatewaysGovernanceGuardrailsObservabilityPrompt Management

APIs

Portkey

Portkey equips AI teams with everything they need to go to production - Gateway, Observability, Guardrails, Governance, and Prompt Management, all in one platform.

Portkey Inference API

Portkey Inference API provides a universal API for routing to 200+ LLMs across chat completions, completions, embeddings, images, audio, assistants, fine-tuning, batch processin...

Portkey Admin API

Portkey Admin API enables programmatic management of Portkey organizations and workspaces, including resource management for configs, virtual keys, and API keys, analytics and m...

Collections

Pricing Plans

Portkey Plans Pricing

4 plans

PLANS

Rate Limits

Portkey Rate Limits

5 limits

RATE LIMITS

FinOps

Resources

🔗
DomainSecurity
DomainSecurity
🔑
Authentication
Authentication
🔗
AgentSkills
AgentSkills
🔗
Website
Website
🔗
Documentation
Documentation
📄
ChangeLog
ChangeLog
📰
Blog
Blog
🟢
StatusPage
StatusPage
💰
Pricing
Pricing
📜
PrivacyPolicy
PrivacyPolicy
📜
TermsOfService
TermsOfService
🔗
Login
Login
🚀
GettingStarted
GettingStarted
🔗
APIReference
APIReference
🔗
APIReference
APIReference
🔗
OpenAPI
OpenAPI
👥
GitHubOrg
GitHubOrg
👥
GitHubOrg
GitHubOrg
👥
GitHubOrg
GitHubOrg
🔗
PythonPackage
PythonPackage
🔗
NodePackage
NodePackage
📦
SDKs
SDKs
🔗
Forums
Forums
🔗
Security
Security
🔗
Observability
Observability
🔗
Guardrails
Guardrails
🔗
Documentation
Documentation
🔗
Providers
Providers
🔗
LinkedIn
LinkedIn

Sources

Raw ↑
opencollection: 1.0.0
info:
  name: Portkey API
  version: 2.0.0
request:
  auth:
    type: apikey
    key: x-portkey-api-key
    value: '{{x-portkey-api-key}}'
    placement: header
items:
- info:
    name: Chat
    type: folder
  items:
  - info:
      name: Chat
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/chat/completions
      headers:
      - name: x-portkey-trace-id
        value: ''
      - name: x-portkey-span-id
        value: ''
      - name: x-portkey-parent-span-id
        value: ''
      - name: x-portkey-span-name
        value: ''
      - name: x-portkey-metadata
        value: ''
      - name: x-portkey-cache-namespace
        value: ''
      - name: x-portkey-cache-force-refresh
        value: ''
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Chat
- info:
    name: Realtime
    type: folder
  items:
  - info:
      name: Realtime
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/realtime
      headers:
      - name: x-portkey-trace-id
        value: ''
      - name: x-portkey-span-id
        value: ''
      - name: x-portkey-parent-span-id
        value: ''
      - name: x-portkey-span-name
        value: ''
      - name: x-portkey-metadata
        value: ''
      - name: x-portkey-cache-namespace
        value: ''
      - name: x-portkey-cache-force-refresh
        value: ''
      params:
      - name: model
        value: ''
        type: query
        description: Often required for OpenAI-style realtime; other query params pass through unchanged.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Connect to the Realtime API endpoint.
- info:
    name: Completions
    type: folder
  items:
  - info:
      name: Completions
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/completions
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Completions
- info:
    name: Collections
    type: folder
  items:
  - info:
      name: List collections
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/collections
      params:
      - name: workspace_id
        value: ''
        type: query
        description: ID or slug of the workspace
      - name: current_page
        value: ''
        type: query
        description: Page number for pagination (0-indexed)
      - name: page_size
        value: ''
        type: query
        description: Number of items per page
      - name: search
        value: ''
        type: query
        description: Search query to filter collections by name
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Lists all collections in the specified workspace
  - info:
      name: Create a new collection
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/collections
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Creates a new collection in the specified workspace
  - info:
      name: Get collection details
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/collections/:collectionId
      params:
      - name: collectionId
        value: ''
        type: path
        description: ID or slug of the collection
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Retrieves details of a specific collection
  - info:
      name: Update collection
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/collections/:collectionId
      params:
      - name: collectionId
        value: ''
        type: path
        description: ID or slug of the collection
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Updates a collection's details
  - info:
      name: Delete collection
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/collections/:collectionId
      params:
      - name: collectionId
        value: ''
        type: path
        description: ID or slug of the collection
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Deletes a collection
- info:
    name: Labels
    type: folder
  items:
  - info:
      name: List labels
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/labels
      params:
      - name: organisation_id
        value: ''
        type: query
        description: ID of the organisation
      - name: workspace_id
        value: ''
        type: query
        description: ID or slug of the workspace
      - name: search
        value: ''
        type: query
        description: Search query to filter labels by name
      - name: current_page
        value: ''
        type: query
        description: Page number for pagination
      - name: page_size
        value: ''
        type: query
        description: Number of items per page
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Returns a list of labels based on filters
  - info:
      name: Create a new label
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/labels
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Creates a new label in the system
  - info:
      name: Get a label by ID
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/labels/:labelId
      params:
      - name: labelId
        value: ''
        type: path
        description: ID of the label to retrieve
      - name: organisation_id
        value: ''
        type: query
        description: ID of the organisation
      - name: workspace_id
        value: ''
        type: query
        description: ID or slug of the workspace
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Returns a specific label by its ID
  - info:
      name: Update a label
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/labels/:labelId
      params:
      - name: labelId
        value: ''
        type: path
        description: ID of the label to update
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Updates an existing label
  - info:
      name: Delete a label
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/labels/:labelId
      params:
      - name: labelId
        value: ''
        type: path
        description: ID of the label to delete
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Deletes a label
- info:
    name: Prompts
    type: folder
  items:
  - info:
      name: List prompts
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts
      params:
      - name: collection_id
        value: ''
        type: query
      - name: workspace_id
        value: ''
        type: query
      - name: current_page
        value: ''
        type: query
      - name: page_size
        value: ''
        type: query
      - name: search
        value: ''
        type: query
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: List prompts
  - info:
      name: Create a new prompt
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/prompts
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create a new prompt
  - info:
      name: Get a prompt by ID or slug
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/:promptId
      params:
      - name: promptId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Get a prompt by ID or slug
  - info:
      name: Update a prompt
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/prompts/:promptId
      params:
      - name: promptId
        value: ''
        type: path
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Update a prompt''s metadata and/or create a new version with updated template content.


      **Partial version updates:** Set `patch: true` to perform a partial update of version fields (`string`, `parameters`,
      `model`, `virtual_key`, `version_description`, `functions`, `tools`, `tool_choice`, `is_raw_template`, `prompt_metadata`).
      When enabled, any version fields omitted from the request are backfilled from the current latest version, allowing you
      to update only the fields you need. When `patch` is o'
  - info:
      name: Delete a prompt
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/prompts/:promptId
      params:
      - name: promptId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Delete a prompt
  - info:
      name: Get all versions of a prompt
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/:promptId/versions
      params:
      - name: promptId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Get all versions of a prompt
  - info:
      name: Get a specific version of a prompt
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/:promptId/versions/:versionId
      params:
      - name: promptId
        value: ''
        type: path
      - name: versionId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Get a specific version of a prompt
  - info:
      name: Update a specific version of a prompt
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/prompts/:promptId/versions/:versionId
      params:
      - name: promptId
        value: ''
        type: path
      - name: versionId
        value: ''
        type: path
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Updates metadata for a specific prompt version. **This endpoint only supports updating the `label_id` field.**


      Prompt versions are immutable — their `string`, `parameters`, and `model` content cannot be changed after creation.
      To update prompt content, use `PUT /prompts/{promptId}` which creates a new version with the updated content.

      '
  - info:
      name: Set a version as the default for a prompt
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/prompts/:promptId/makeDefault
      params:
      - name: promptId
        value: ''
        type: path
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Set a version as the default for a prompt
  - info:
      name: Prompts Completions
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/prompts/:promptId/completions
      params:
      - name: promptId
        value: ''
        type: path
        description: The unique identifier of the prompt template to use
      body:
        type: json
        data: '{}'
    docs: 'Execute your saved prompt templates on Portkey

      '
  - info:
      name: Prompts Render
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/prompts/:promptId/render
      params:
      - name: promptId
        value: ''
        type: path
        description: The unique identifier of the prompt template to render
      body:
        type: json
        data: '{}'
    docs: 'Renders a prompt template with its variable values filled in

      '
- info:
    name: PromptPartials
    type: folder
  items:
  - info:
      name: List prompt partials
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/partials
      params:
      - name: collection_id
        value: ''
        type: query
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: List prompt partials
  - info:
      name: Create a new prompt partial
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/prompts/partials
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create a new prompt partial
  - info:
      name: Get a prompt partial by ID or slug
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/partials/:promptPartialId
      params:
      - name: promptPartialId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Get a prompt partial by ID or slug
  - info:
      name: Update a prompt partial
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/prompts/partials/:promptPartialId
      params:
      - name: promptPartialId
        value: ''
        type: path
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Update a prompt partial
  - info:
      name: Delete a prompt partial
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/prompts/partials/:promptPartialId
      params:
      - name: promptPartialId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Delete a prompt partial
  - info:
      name: Get all versions of a prompt partial
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/prompts/partials/:promptPartialId/versions
      params:
      - name: promptPartialId
        value: ''
        type: path
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Get all versions of a prompt partial
  - info:
      name: Set a version as the default for a prompt partial
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/prompts/partials/:promptPartialId/makeDefault
      params:
      - name: promptPartialId
        value: ''
        type: path
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Set a version as the default for a prompt partial
- info:
    name: Guardrails
    type: folder
  items:
  - info:
      name: List guardrails
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/guardrails
      params:
      - name: workspace_id
        value: ''
        type: query
        description: Workspace UUID to filter guardrails
      - name: organisation_id
        value: ''
        type: query
        description: Organisation UUID to filter guardrails
      - name: page_size
        value: ''
        type: query
        description: Number of items per page
      - name: current_page
        value: ''
        type: query
        description: Current page number (0-indexed)
    docs: Retrieves a paginated list of guardrails for the specified workspace or organisation
  - info:
      name: Create a new guardrail
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/guardrails
      body:
        type: json
        data: '{}'
    docs: Creates a new guardrail with specified checks and actions
  - info:
      name: Get a specific guardrail
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/guardrails/:guardrailId
      params:
      - name: guardrailId
        value: ''
        type: path
        description: Guardrail UUID or slug (with guard_ prefix)
    docs: Retrieves details of a specific guardrail by ID or slug
  - info:
      name: Update a guardrail
      type: http
    http:
      method: PUT
      url: https://api.portkey.ai/v1/guardrails/:guardrailId
      params:
      - name: guardrailId
        value: ''
        type: path
        description: Guardrail UUID or slug to update
      body:
        type: json
        data: '{}'
    docs: Updates an existing guardrail's name, checks, or actions
  - info:
      name: Delete a guardrail
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/guardrails/:guardrailId
      params:
      - name: guardrailId
        value: ''
        type: path
        description: Guardrail UUID or slug to delete
    docs: Deletes an existing guardrail
- info:
    name: Images
    type: folder
  items:
  - info:
      name: Create Image
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/images/generations
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create Image
  - info:
      name: Create Image Edit
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/images/edits
      body:
        type: multipart-form
        data: []
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create Image Edit
  - info:
      name: Creates Image Variation
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/images/variations
      body:
        type: multipart-form
        data: []
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Creates Image Variation
- info:
    name: Embeddings
    type: folder
  items:
  - info:
      name: Embeddings
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/embeddings
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Embeddings
- info:
    name: Rerank
    type: folder
  items:
  - info:
      name: Rerank
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/rerank
      headers:
      - name: x-portkey-trace-id
        value: ''
      - name: x-portkey-span-id
        value: ''
      - name: x-portkey-parent-span-id
        value: ''
      - name: x-portkey-span-name
        value: ''
      - name: x-portkey-metadata
        value: ''
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Reranks a list of documents based on their relevance to a query. This endpoint provides a unified interface to
      reranking models from multiple providers including Cohere, Voyage, Jina, Pinecone, Bedrock, and Azure AI.


      Reranking is useful for improving search results by scoring and sorting documents based on semantic relevance to a query,
      rather than just keyword matching.

      '
- info:
    name: Audio
    type: folder
  items:
  - info:
      name: Create Speech
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/audio/speech
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create Speech
  - info:
      name: Create Transcription
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/audio/transcriptions
      body:
        type: multipart-form
        data: []
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create Transcription
  - info:
      name: Create Translation
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/audio/translations
      body:
        type: multipart-form
        data: []
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Create Translation
- info:
    name: Files
    type: folder
  items:
  - info:
      name: List Files
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/files
      params:
      - name: purpose
        value: ''
        type: query
        description: Only return files with the given purpose.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: List Files
  - info:
      name: 'Upload a file to be used across various endpoints, such as Assistant (<2M tokens), Fine-Tuning, and Batch (<100
        MB). Total size of your bucket is 100 GB.

        '
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/files
      body:
        type: multipart-form
        data: []
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Upload a file to be used across various endpoints, such as Assistant (<2M tokens), Fine-Tuning, and Batch (<100
      MB). Total size of your bucket is 100 GB.

      '
  - info:
      name: Returns information about a specific file.
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/files/:file_id
      params:
      - name: file_id
        value: ''
        type: path
        description: The ID of the file to use for this request.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Returns information about a specific file.
  - info:
      name: Delete File
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/files/:file_id
      params:
      - name: file_id
        value: ''
        type: path
        description: The ID of the file to use for this request.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Delete File
  - info:
      name: Returns the contents of the specified file.
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/files/:file_id/content
      params:
      - name: file_id
        value: ''
        type: path
        description: The ID of the file to use for this request.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Returns the contents of the specified file.
- info:
    name: Fine-tuning
    type: folder
  items:
  - info:
      name: 'List your organization''s fine-tuning jobs

        '
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/fine_tuning/jobs
      params:
      - name: after
        value: ''
        type: query
        description: Identifier for the last job from the previous pagination request.
      - name: limit
        value: ''
        type: query
        description: Number of fine-tuning jobs to retrieve.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'List your organization''s fine-tuning jobs

      '
  - info:
      name: 'Get info about a fine-tuning job.


        [Learn more about fine-tuning](https://platform.openai.com/docs/guides/fine-tuning)

        '
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/fine_tuning/jobs/:fine_tuning_job_id
      params:
      - name: fine_tuning_job_id
        value: ''
        type: path
        description: 'The ID of the fine-tuning job.

          '
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Get info about a fine-tuning job.


      [Learn more about fine-tuning](https://platform.openai.com/docs/guides/fine-tuning)

      '
  - info:
      name: 'Get status updates for a fine-tuning job.

        '
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/fine_tuning/jobs/:fine_tuning_job_id/events
      params:
      - name: fine_tuning_job_id
        value: ''
        type: path
        description: 'The ID of the fine-tuning job to get events for.

          '
      - name: after
        value: ''
        type: query
        description: Identifier for the last event from the previous pagination request.
      - name: limit
        value: ''
        type: query
        description: Number of events to retrieve.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Get status updates for a fine-tuning job.

      '
  - info:
      name: 'Immediately cancel a fine-tune job.

        '
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/fine_tuning/jobs/:fine_tuning_job_id/cancel
      params:
      - name: fine_tuning_job_id
        value: ''
        type: path
        description: 'The ID of the fine-tuning job to cancel.

          '
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Immediately cancel a fine-tune job.

      '
  - info:
      name: 'List checkpoints for a fine-tuning job.

        '
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/fine_tuning/jobs/:fine_tuning_job_id/checkpoints
      params:
      - name: fine_tuning_job_id
        value: ''
        type: path
        description: 'The ID of the fine-tuning job to get checkpoints for.

          '
      - name: after
        value: ''
        type: query
        description: Identifier for the last checkpoint ID from the previous pagination request.
      - name: limit
        value: ''
        type: query
        description: Number of checkpoints to retrieve.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'List checkpoints for a fine-tuning job.

      '
- info:
    name: Finetune
    type: folder
  items:
  - info:
      name: Create a Finetune Job
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/fine_tuning/jobs
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Finetune a provider model
- info:
    name: Models
    type: folder
  items:
  - info:
      name: List Available Models
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/models
      params:
      - name: ai_service
        value: ''
        type: query
        description: Filter models by the AI service (e.g., 'openai', 'anthropic').
      - name: provider
        value: ''
        type: query
        description: Filter models by the provider.
      - name: limit
        value: ''
        type: query
        description: The maximum number of models to return.
      - name: offset
        value: ''
        type: query
        description: The number of models to skip before starting to collect the result set.
      - name: sort
        value: ''
        type: query
        description: The field to sort the results by.
      - name: order
        value: ''
        type: query
        description: The order to sort the results in.
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Lists the currently available models that can be used through Portkey, and provides basic information about each
      one.
  - info:
      name: Retrieves a model instance, providing basic information about the model such as the owner and permissioning.
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/models/:model
      params:
      - name: model
        value: ''
        type: path
        description: The ID of the model to use for this request
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Retrieves a model instance, providing basic information about the model such as the owner and permissioning.
  - info:
      name: Delete a fine-tuned model. You must have the Owner role in your organization to delete a model.
      type: http
    http:
      method: DELETE
      url: https://api.portkey.ai/v1/models/:model
      params:
      - name: model
        value: ''
        type: path
        description: The model to delete
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: Delete a fine-tuned model. You must have the Owner role in your organization to delete a model.
- info:
    name: Moderations
    type: folder
  items:
  - info:
      name: 'Identify potentially harmful content in text and images. **Only** works with [OpenAI''s Moderations endpoint](https://platform.openai.com/docs/guides/moderation)
        currently.

        '
      type: http
    http:
      method: POST
      url: https://api.portkey.ai/v1/moderations
      body:
        type: json
        data: '{}'
      auth:
        type: apikey
        key: x-portkey-api-key
        value: '{{x-portkey-api-key}}'
        placement: header
    docs: 'Identify potentially harmful content in text and images. **Only** works with [OpenAI''s Moderations endpoint](https://platform.openai.com/docs/guides/moderation)
      currently.

      '
- info:
    name: Assistants
    type: folder
  items:
  - info:
      name: Returns a list of assistants.
      type: http
    http:
      method: GET
      url: https://api.portkey.ai/v1/assistants
      params:
      - name: limit
        value: ''
        type: query
        description: 'A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default
          is 20.

          '
      - name: order
        value: ''
        type: query
        description: 'Sort order by the `created_at` timestamp of the objects. `asc` for ascending order and `desc` for descending
          order.

          '
      - name: after
        value: ''
        type: query
        description: 'A cursor for use in pagination. `after` is an object ID that defines 

# --- truncated at 32 KB (186 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/portkey/refs/heads/main/apis.yml