Elastix Health API

Liveness and readiness probes for the service.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 2

GET /health/liveliness Liveness probe #
GET /health/readiness Readiness probe #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/elastix:elastix-health-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

elastix-health-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Elastix Inference Health API
  version: 0.1.0
  termsOfService: /legal/terms
  contact:
    name: Elastix
    email: support@elastix.ai
  description: 'Run chat completions on Elastix FPGA-accelerated inference over a simple HTTP API. It is **compatible with OpenAI''s Chat API**,

    so you can reuse your existing OpenAI client libraries — just point them at our base URL. Learn more about Elastix at elastix.ai. ## OpenAI-Compatible Server


    Use the API as a drop-in replacement for OpenAI — change only `base_url` and `api_key`. You can use any of OpenAI''s official SDKs and CLIs for `chat-completions` against Elastix:


    ```python

    from openai import OpenAI


    client = OpenAI(base_url="https://api.elastix.ai/v1", api_key="$ELASTIX_API_KEY")

    resp = client.chat.completions.create(

    model="elastix-default",

    messages=[{"role": "user", "content": "Hello!"}],

    )

    print(resp.choices[0].message.content)

    ```


    ## Supported subset


    We implement a **subset** of the OpenAI Chat Completions API, with the addition of an optional session_id (experimental). All other parameters might not be supported at this point. **Unknown parameters are ignored.**


    The request fields we honor:


    ```typescript

    type ChatCompletionRequest = {

    model: string; // Model id — see GET /models

    messages: Message[]; // The conversation so far


    // Streaming

    stream?: boolean; // Stream the reply as SSE. Default: false

    stream_options?: { // Only valid with stream: true

    include_usage?: boolean; // Emit a final chunk carrying token usage

    };


    // Length & sampling

    max_tokens?: number; // Max tokens to generate. Range: [1, ∞)

    temperature?: number; // Sampling temperature. Range: [0, ∞). Default: 1

    top_p?: number; // Nucleus sampling mass. Range: (0, 1]. Default: 1

    n?: number; // Number of completions to return. Range: [1, ∞). Default: 1

    seed?: number; // Best-effort deterministic sampling

    stop?: string | string[]; // Stop sequences


    // Reasoning

    reasoning_effort?: "low" | "medium" | "high"; // Only the GPT OSS models support this; others ignore if provided. Default: medium


    // Repetition control

    frequency_penalty?: number; // Penalize tokens by frequency. Range: [-2, 2]. Default: 0

    presence_penalty?: number; // Penalize tokens already seen. Range: [-2, 2]. Default: 0

    logit_bias?: Record; // Per-token-id bias. // Output format & introspection

    response_format?: { type: "text" | "json_object" }; // Force plain text or JSON

    logprobs?: boolean; // Return log-probs for output tokens. Default: false

    top_logprobs?: number; // Top-N alternatives per position (0–20). Needs logprobs: true


    // Tool calling — see the “Tool calling” section below

    tools?: Tool[]; // Functions the model may call

    tool_choice?: "none" | "auto" | "required" // Whether/which tool to call. Default: "auto" when tools are present

    | { type: "function"; function: { name: string } };

    parallel_tool_calls?: boolean; // Allow multiple tool calls in one turn. Default: "true" if the model supports it


    // Routing (experimental — subject to change) — see the “Session stickiness” section below

    metadata?: { // Arbitrary key/value metadata attached to the request

    session_id?: string; // Stable conversation id; improves caching for multi-turn requests

    };

    };


    type Message = {

    // "developer" is an alias for "system" — both are treated identically. // A system/developer message is optional, but if present it must be first. // Use "tool" to return the result of a tool call back to the model. role: "system" | "developer" | "user" | "assistant" | "tool";

    content: string | null; // Text only (image/audio not supported yet). // May be null on an assistant message that only calls tools. tool_calls?: ToolCall[]; // Present on an assistant message that calls tools

    tool_call_id?: string; // Required on a "tool" message: which call this answers

    };


    type Tool = {

    type: "function";

    function: {

    name: string; // ^[a-zA-Z0-9_-]+$

    description: string; // Required (unlike OpenAI): what the tool does, so the model knows when to call it

    parameters?: object; // JSON Schema object; omit for no-argument functions.'
  x-scalar-sdk-installation:
  - lang: cURL
    description: "```sh\ncurl https://api.elastix.ai/v1/chat/completions \\\n  -H \"Authorization: Bearer $ELASTIX_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n        \"model\": \"elastix-default\",\n        \"messages\": [{\"role\": \"user\", \"content\": \"Hello!\"}],\n        \"metadata\": {\"session_id\": \"conv-abc-123\"}\n      }'\n```"
  - lang: Python
    description: "```sh\npip install openai\n```\n\n```python\nfrom openai import OpenAI\n\nclient = OpenAI(base_url=\"https://api.elastix.ai/v1\", api_key=\"$ELASTIX_API_KEY\")\nresp = client.chat.completions.create(\n    model=\"elastix-default\",\n    messages=[{\"role\": \"user\", \"content\": \"Hello!\"}],\n)\nprint(resp.choices[0].message.content)\n```"
  - lang: TypeScript
    description: "```sh\nnpm install openai\n```\n\n```typescript\nimport OpenAI from \"openai\";\n\nconst client = new OpenAI({ baseURL: \"https://api.elastix.ai/v1\", apiKey: process.env.ELASTIX_API_KEY });\nconst resp = await client.chat.completions.create({\n  model: \"elastix-default\",\n  messages: [{ role: \"user\", content: \"Hello!\" }],\n});\nconsole.log(resp.choices[0].message.content);\n```"
  - lang: Go
    description: "```sh\ngo get github.com/openai/openai-go\n```\n\n```go\nclient := openai.NewClient(\n    option.WithBaseURL(\"https://api.elastix.ai/v1\"),\n    option.WithAPIKey(\"$ELASTIX_API_KEY\"),\n)\nresp, _ := client.Chat.Completions.New(context.TODO(), openai.ChatCompletionNewParams{\n    Model:    \"elastix-default\",\n    Messages: []openai.ChatCompletionMessageParamUnion{openai.UserMessage(\"Hello!\")},\n})\nfmt.Println(resp.Choices[0].Message.Content)\n```"
  - lang: C#
    description: "```sh\ndotnet add package OpenAI\n```\n\n```csharp\nusing OpenAI;\nusing OpenAI.Chat;\nusing System.ClientModel;\n\nChatClient client = new(\n    \"elastix-default\",\n    new ApiKeyCredential(\"$ELASTIX_API_KEY\"),\n    new OpenAIClientOptions { Endpoint = new Uri(\"https://api.elastix.ai/v1\") });\n\nChatCompletion completion = client.CompleteChat(\"Hello!\");\nConsole.WriteLine(completion.Content[0].Text);\n```"
  - lang: Java
    description: "```kotlin\nimplementation(\"com.openai:openai-java:4.0.0\")\n```\n\n```java\nOpenAIClient client = OpenAIOkHttpClient.builder()\n    .baseUrl(\"https://api.elastix.ai/v1\")\n    .apiKey(\"$ELASTIX_API_KEY\")\n    .build();\n\nChatCompletionCreateParams params = ChatCompletionCreateParams.builder()\n    .model(\"elastix-default\")\n    .addUserMessage(\"Hello!\")\n    .build();\n\nChatCompletion completion = client.chat().completions().create(params);\nSystem.out.println(completion.choices().get(0).message().content().orElse(\"\"));\n```"
  - lang: Ruby
    description: "```sh\ngem install openai\n```\n\n```ruby\nrequire \"openai\"\n\nclient = OpenAI::Client.new(api_key: \"$ELASTIX_API_KEY\", base_url: \"https://api.elastix.ai/v1\")\nchat = client.chat.completions.create(\n  model: \"elastix-default\",\n  messages: [{ role: \"user\", content: \"Hello!\" }],\n)\nputs chat.choices.first.message.content\n```"
  - lang: CLI
    description: "```sh\nbrew install openai/tools/openai\n```\n\n```sh\nexport OPENAI_BASE_URL=\"https://api.elastix.ai/v1\"\nexport OPENAI_API_KEY=\"$ELASTIX_API_KEY\"\n\nopenai api chat.completions.create \\\n  -m elastix-default \\\n  -g user \"Hello!\"\n```"
servers:
- url: https://api.elastix.ai
  description: Production
security:
- bearerAuth: []
tags:
- name: Health
  description: Liveness and readiness probes for the service.
paths:
  /health/liveliness:
    get:
      tags:
      - Health
      operationId: healthLiveliness
      x-codeSamples:
      - lang: cURL
        label: cURL
        source: "curl https://api.elastix.ai/health/liveliness \\\n  -H \"Authorization: Bearer $ELASTIX_API_KEY\""
      summary: Liveness probe
      description: Returns `200` while the service process is alive. This endpoint lives at the host root (no `/v1` prefix) and, like every other endpoint, requires a valid API key.
      responses:
        '200':
          description: The service process is alive.
          content:
            application/json:
              schema:
                type: string
              example: I'm alive!
        '401':
          description: Missing or invalid API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error:
                  message: Missing or malformed API key.
                  type: invalid_request_error
                  code: invalid_api_key
        '503':
          description: The service is shutting down (graceful shutdown in progress) and should not receive new traffic.
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    examples:
                    - shutting_down
              example:
                status: shutting_down
  /health/readiness:
    get:
      tags:
      - Health
      operationId: healthReadiness
      x-codeSamples:
      - lang: cURL
        label: cURL
        source: "curl https://api.elastix.ai/health/readiness \\\n  -H \"Authorization: Bearer $ELASTIX_API_KEY\""
      summary: Readiness probe
      description: Returns `200` when the service is ready to serve traffic — its dependencies (such as the database) are reachable. This endpoint lives at the host root (no `/v1` prefix) and requires a valid API key.
      responses:
        '200':
          description: The service is ready to serve traffic.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ReadinessStatus'
              example:
                status: healthy
                db: connected
        '401':
          description: Missing or invalid API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error:
                  message: Missing or malformed API key.
                  type: invalid_request_error
                  code: invalid_api_key
        '503':
          description: 'The service is not ready: either a graceful shutdown is in progress (`{ "status": "shutting_down" }`) or a dependency is unreachable. **Treat the HTTP status as authoritative** — on a dependency failure the body''s top-level `status` may still read `healthy` while the affected field (e.g. `db`) reports the problem.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ReadinessStatus'
              example:
                status: healthy
                db: disconnected
components:
  schemas:
    Error:
      type: object
      required:
      - error
      description: OpenAI-compatible error envelope. The `error` object carries a human-readable `message` plus machine-readable fields for handling.
      properties:
        error:
          type: object
          required:
          - message
          properties:
            message:
              type: string
              description: A human-readable explanation of what went wrong.
            type:
              type:
              - string
              - 'null'
              description: The category of error, e.g. invalid_request_error, authentication_error, or rate_limit_error.
            param:
              type:
              - string
              - 'null'
              description: The request parameter the error relates to, or null when not tied to a specific field.
            code:
              type:
              - string
              - 'null'
              description: A short error code; mirrors the HTTP status.
    ReadinessStatus:
      type: object
      required:
      - status
      description: Readiness report for the service and its dependencies.
      properties:
        status:
          type: string
          description: Overall readiness status.
          examples:
          - healthy
        db:
          type: string
          description: Connectivity status of the backing database.
          examples:
          - connected
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your Elastix API key, sent as `Authorization: Bearer <key>`.'
externalDocs:
  description: Elastix - home
  url: https://elastix.ai