---
title: "InvokeModel"
method: POST
path: "/gitpod.v1.LLMService/InvokeModel"
tags: ["gitpod.v1.LLMService"]
---

# InvokeModel

`POST /gitpod.v1.LLMService/InvokeModel`

## Request body

- GitpodV1InvokeModelRequest
  - `anthropicRequest` GitpodV1AnthropicRequest, required
    - `maxTokens` integer
    - `messages` GitpodV1AnthropicMessage[] — unresolved $ref
    - `temperature` number, double
    - `toolChoice` object
    - `tools` GitpodV1AnthropicRequestTool[]
      - `description` string
      - `inputSchema` GitpodV1AnthropicRequestToolInputSchema
        - `description` string
        - `items` GitpodV1AnthropicRequestToolInputSchema — recursive
        - `properties` object
        - `required` string[]
        - `type` 'string' | 'integer' | 'object' | 'array' | 'boolean'
      - `name` string

## Response `200`

Success

- GitpodV1InvokeModelResponse
  - `anthropicResponse` GitpodV1AnthropicResponse, required — unresolved $ref

## Other responses

- `default` — Error

## Changes

- **2025-02-18** `cd6a05ae99d2` — 1 warning
  - removed the optional property `detail` from the response with the `default` status

[Change history](https://skmtc.dev/gitpod-io/apis/gitpod-v1/changes/gitpod.v1.LLMService/InvokeModel/post.md)

---

[API](https://skmtc.dev/gitpod-io/apis/gitpod-v1.md) · [All operations](https://skmtc.dev/gitpod-io/apis/gitpod-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/gitpod-io/gitpod-v1/revisions/cd6a05ae99d2/schema)
