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

# Chat completion on a dedicated GPU deployment

> OpenAI-compatible chat completions on your organization's own dedicated HuggingFace vLLM deployment, with your ordinary AI Reserve API key — the HuggingFace credential stays server-side. `deploymentId` is the deployment's id from **Admin → GPUs → How to call endpoint**; a key from another organization gets the same `404` as an unknown deployment. `model` is optional and, when sent, must name the repository actually deployed. `stream: true` answers server-sent events with usage on the final chunk. Inference is not billed per token — the deployment's GPU time is billed from the organization wallet — so wallet-balance and budget-cap gates do not apply here, while key status, IP allowlists and rate limits do. A scale-to-zero deployment that is asleep is woken by the request (the first call can take minutes); a paused, failed or provisioning deployment answers `409`, and a deployment of an adult-only model answers `403` once the organization's adult-content access is turned off.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/gpu/{deploymentId}/chat/completions
openapi: 3.0.3
info:
  title: AI Reserve Gateway API
  description: >-
    The AI Reserve API surface — inference, durable environments, workspaces,
    sandboxes, executions, agent runs, GPU infrastructure, and fine-tuning — all
    behind one endpoint and one API key.
  version: 1.0.0
servers:
  - url: https://api.aireserve.com
security:
  - bearerAuth: []
tags:
  - name: Customers
    description: >-
      Per-end-customer usage, cost, and billable amounts for organizations that
      tag requests with their own customers.
  - name: Dedicated GPU endpoints
    description: >-
      OpenAI-compatible inference on your organization's own dedicated
      HuggingFace vLLM deployments, called with an ordinary AI Reserve API key.
      GPU time is billed from the wallet; requests add no per-token charge.
  - name: GPU Infrastructure
    description: >-
      Provision and manage provider-hidden GPU instances. The recommended
      Instances API accepts workload requirements and an hourly price ceiling;
      AI Reserve handles provider placement internally. Every mutation is
      asynchronous and returns an operation to poll.
  - name: Environments
    description: Immutable, versioned runtime definitions.
  - name: Workspaces
    description: Durable project storage pinned to one environment version.
  - name: Sandboxes
    description: >-
      Ephemeral provider-disclosed compute allocated from sealed quotes.
      Requests remain provider-neutral.
  - name: Executions
    description: Durable asynchronous operations and command, service, or agent executions.
  - name: Agent Runs
    description: Durable Agent SDK runs with replayable events and external artifacts.
  - name: Customer keys
    description: >-
      Mint, list, and revoke API keys pinned to your own end customers (and
      their organizations), so spend splits per customer without per-request
      tagging.
  - name: AWS CLI login
    description: >-
      Browser-authorization endpoints consumed by `aws login --profile …` (AWS
      CLI v2.32.0+). All three routes are unauthenticated — the caller has no
      credential until `/v1/token` succeeds.
  - name: Fine-tuning
    description: >-
      Fine-tune open models on your own data. Data lives in an S3 bucket inside
      your organization's AWS hub account; you name a base, LoRA or full, a
      price ceiling and how the result must be servable, and AI Reserve places
      the run on a backend internally. The result is a model in your bucket you
      can deploy or download.
  - name: 'Admin: Catalog'
    description: Discover the operations available to this token.
  - name: 'Admin: Analytics'
    description: Usage, spend and attribution reads.
  - name: 'Admin: API Keys'
    description: Organization and team inference keys.
  - name: 'Admin: Billing'
    description: Wallet, ledger and invoice reads.
  - name: 'Admin: Compute'
    description: GPU machines and persistent storage (quote, launch, inspect, stop).
  - name: 'Admin: Compute Runtime'
    description: >-
      Portable environments, workspaces, sandboxes, executions, operations and
      durable agent runs.
  - name: 'Admin: Containers'
    description: The organization's AWS account, ECS services, logs and secrets.
  - name: 'Admin: Files'
    description: Organization shared files.
  - name: 'Admin: Members'
    description: 'People in the organization: invite, profile, team, access, role.'
  - name: 'Admin: Models & Routing'
    description: Model availability, defaults, fallbacks and routing.
  - name: 'Admin: Organization'
    description: Retention, logging, branding, sign-in domains, classification.
  - name: 'Admin: Personal'
    description: The caller's own usage, budget, API keys and preferences.
  - name: 'Admin: Teams & Budgets'
    description: Teams, spend caps and allocations.
  - name: 'Admin: Training'
    description: Fine-tuning datasets, runs, models and deployments.
paths:
  /v1/gpu/{deploymentId}/chat/completions:
    post:
      tags:
        - Dedicated GPU endpoints
      summary: Chat completion on a dedicated GPU deployment
      description: >-
        OpenAI-compatible chat completions on your organization's own dedicated
        HuggingFace vLLM deployment, with your ordinary AI Reserve API key — the
        HuggingFace credential stays server-side. `deploymentId` is the
        deployment's id from **Admin → GPUs → How to call endpoint**; a key from
        another organization gets the same `404` as an unknown deployment.
        `model` is optional and, when sent, must name the repository actually
        deployed. `stream: true` answers server-sent events with usage on the
        final chunk. Inference is not billed per token — the deployment's GPU
        time is billed from the organization wallet — so wallet-balance and
        budget-cap gates do not apply here, while key status, IP allowlists and
        rate limits do. A scale-to-zero deployment that is asleep is woken by
        the request (the first call can take minutes); a paused, failed or
        provisioning deployment answers `409`, and a deployment of an adult-only
        model answers `403` once the organization's adult-content access is
        turned off.
      parameters:
        - name: deploymentId
          in: path
          required: true
          schema:
            format: uuid
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              additionalProperties: true
            example:
              model: Qwen/Qwen2.5-7B-Instruct
              messages:
                - role: user
                  content: Hello!
      responses:
        '200':
          description: Default Response
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Your AI Reserve API key (aireserve_api_…) from the API Keys page in the
        portal (https://portal.aireserve.com/keys).

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.