---
canonical_url: "https://docs.composio.dev/toolkits/fireworks_ai"
markdown_url: "https://docs.composio.dev/toolkits/fireworks_ai.md"
product: "platform"
version: null
last_updated: null
---

# Fireworks AI

Fireworks AI provides APIs for serverless model inference, fine-tuning, deployments, datasets, evaluations, and account management.

- **Category:** artificial intelligence
- **Auth:** API_KEY
- **Composio-managed OAuth available?** N/A
- **Tools:** 9
- **Triggers:** 0
- **Slug:** `FIREWORKS_AI`
- **Version:** 00000000_00

## Tools

### Create Chat Completion

**Slug:** `FIREWORKS_AI_CREATE_CHAT_COMPLETION`

Generate one non-streaming OpenAI-compatible chat completion from role-based messages using a caller-supplied Fireworks model or deployment ID.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `seed` | integer | No | Optional seed for best-effort repeatability. |
| `stop` | string | No | One or more sequences that stop generation. |
| `model` | string | Yes | Exact Fireworks model or deployed-model identifier to invoke; discover candidates with the Fireworks AI model or deployment listing tools. |
| `tools` | array | No | Function definitions the model may call. |
| `top_p` | number | No | Nucleus-sampling probability mass; normally tune this or temperature, not both. |
| `messages` | array | Yes | Conversation messages in order; each item must contain a role and OpenAI-compatible content or tool-call data. |
| `max_tokens` | integer | No | Maximum number of tokens to generate; omit to use the model or provider default. |
| `temperature` | number | No | Sampling temperature; omit to use the provider default. |
| `tool_choice` | string | No | Whether and which supplied function tools the model may call. |
| `response_format` | object | No | Typed output format, such as JSON mode, JSON Schema, grammar, or text, when the model supports it. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Create Embeddings

**Slug:** `FIREWORKS_AI_CREATE_EMBEDDINGS`

Create embedding vectors for one or more caller-provided inputs using a caller-supplied Fireworks embedding model.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `input` | string | Yes | Text, a batch of up to 2048 texts, or arbitrary structured records whose keys are referenced by prompt_template. For example, input {'text': 'Hello', 'source': 'docs'} can use prompt_template 'Embed {text} from {source}'. |
| `model` | string | Yes | Exact embedding model identifier; Fireworks examples may use provider/model form rather than a full account resource name. |
| `normalize` | boolean | No | Whether to normalize returned vectors; omit to use the model default. |
| `dimensions` | integer | No | Requested output vector dimensions when the selected model supports dimension reduction. |
| `prompt_template` | string | No | Template that substitutes structured-input keys, for example 'Embed this text: {text}'. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Generate Model Response

**Slug:** `FIREWORKS_AI_GENERATE_MODEL_RESPONSE`

Generate one non-streaming Responses API result, optionally continuing a stored response or using function, MCP, or SSE tools; storage is off by default.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `input` | string | Yes | Text input or ordered input items. Use a plain string for simple prompts; to continue a function-tool loop, replay the model's function_call item followed by a function_call_output item carrying the tool result. |
| `model` | string | Yes | Exact Fireworks model or deployed-model identifier to invoke; no model is selected by the toolkit. |
| `store` | boolean | No | Whether Fireworks should retain the response for later continuation; defaults to false for ephemeral calls. |
| `tools` | array | No | Verified function, MCP, or SSE tool definitions available to the model. |
| `top_p` | number | No | Nucleus-sampling probability mass from 0 to 1; normally tune this or temperature, not both. |
| `truncation` | string ("auto" | "disabled") | No | Use 'auto' to truncate overlong context or 'disabled' to return an error; omit for the provider default. |
| `temperature` | number | No | Sampling temperature from 0 to 2; omit to use the provider default. |
| `tool_choice` | string | No | Whether the model must avoid tools, choose automatically, call at least one supplied tool, or call one specific named function tool. |
| `instructions` | string | No | System-level instructions that guide the model for this response. |
| `max_tool_calls` | integer | No | Maximum number of tool calls allowed for this response. |
| `max_output_tokens` | integer | No | Maximum number of output tokens across generated content; omit to use the model limit. |
| `previous_response_id` | string | No | ID of a previously stored response to continue; omit for an independent response. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Deployment

**Slug:** `FIREWORKS_AI_GET_DEPLOYMENT`

Return configuration and serving status for one Fireworks deployment without scaling or modifying it.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `read_mask` | string | No | Comma-separated deployment fields to return; omit for the provider's default projection. |
| `account_id` | string | Yes | Fireworks account ID containing the deployment. |
| `deployment_id` | string | Yes | Deployment resource ID within the account, obtainable with the Fireworks AI deployment listing tool. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Model

**Slug:** `FIREWORKS_AI_GET_MODEL`

Return metadata and status for one model resource in a Fireworks account; this does not test whether the model can serve inference.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `model_id` | string | Yes | Model resource ID within the account, obtainable with the Fireworks AI model listing tool. |
| `read_mask` | string | No | Comma-separated model fields to return; omit for the provider's default projection. |
| `account_id` | string | Yes | Fireworks account ID containing the model resource. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### List Accounts

**Slug:** `FIREWORKS_AI_LIST_ACCOUNTS`

Return one page of Fireworks accounts accessible to the API key so an agent can obtain account IDs for model and deployment discovery.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `filter` | string | No | Fireworks management API filter expression for accounts. |
| `page_size` | integer | No | Maximum accounts to return in this page (1-200). |
| `read_mask` | string | No | Comma-separated account fields to return; omit for the provider's default projection. |
| `next_cursor` | string | No | Continuation cursor returned by a previous call to this tool; omit for the first page. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### List Deployments

**Slug:** `FIREWORKS_AI_LIST_DEPLOYMENTS`

Return one page of deployment resources in a Fireworks account for deployment ID discovery and serving-capacity and status inspection.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `filter` | string | No | Fireworks management API filter expression for deployment resources. |
| `order_by` | string | No | Comma-separated deployment fields to order by; append ' desc' for descending order. |
| `page_size` | integer | No | Maximum deployment resources to return in this page (1-200). |
| `read_mask` | string | No | Comma-separated deployment fields to return; omit for the provider's default projection. |
| `account_id` | string | Yes | Fireworks account ID, obtainable with the Fireworks AI account listing tool. |
| `next_cursor` | string | No | Continuation cursor returned by a previous call to this tool; omit for the first page. |
| `show_deleted` | boolean | No | Whether to include soft-deleted deployment resources in discovery results. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### List Models

**Slug:** `FIREWORKS_AI_LIST_MODELS`

Return one page of model resources in a Fireworks account for model-ID discovery and status inspection; availability for inference is not guaranteed.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `filter` | string | No | Fireworks management API filter expression for model resources. |
| `order_by` | string | No | Comma-separated model fields to order by; append ' desc' for descending order. |
| `page_size` | integer | No | Maximum model resources to return in this page (1-200). |
| `read_mask` | string | No | Comma-separated model fields to return; omit for the provider's default projection. |
| `account_id` | string | Yes | Fireworks account ID, obtainable with the Fireworks AI account listing tool. |
| `next_cursor` | string | No | Continuation cursor returned by a previous call to this tool; omit for the first page. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Rerank Documents

**Slug:** `FIREWORKS_AI_RERANK_DOCUMENTS`

Rank a provided document list by relevance to a query using an optional caller-supplied Fireworks reranker model.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `task` | string | No | Optional task instruction supported by the selected reranker model. |
| `model` | string | No | Exact reranker model identifier; omit only when intentionally using Fireworks' documented provider default. |
| `query` | string | Yes | Search query against which document relevance is scored. |
| `top_n` | integer | No | Maximum number of highest-ranked results to return. |
| `documents` | array | Yes | Documents to score and reorder; result indices refer to this original array. |
| `return_documents` | boolean | No | Whether each result should include its document text as well as its original index and relevance score. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |
