---
title: "Extract content from a string"
method: POST
path: "/v1/extractions/content"
tags: ["extractions"]
---

# Extract content from a string

`POST /v1/extractions/content`

Extract content from a string using the provided schema.

Args:
    params: The parameters for extracting content from a string.

Returns:
    The extracted content.

## Request body

- ExtractContentCreateParams — Parameters for extracting content using a schema.
  - `content` union, required — The content to extract from
    - string
    - string[]
    - union[]
      - union
        - TextInput — Model for text input validation. Attributes: type: Input type identifier, always "text" text: The actual text content, with length and whitespace constraints
          - `type` 'text' — Input type identifier
          - `text` string, required — Text content to process
        - ImageUrlInput — Model for image input validation.
          - `type` 'image_url' — Input type identifier
          - `image_url` ImageUrlInput, required — recursive
  - `json_schema` object, required — The JSON schema to use for extraction
  - `instructions` string, nullable — Additional instructions for the extraction

## Response `200`

The extracted content

- ExtractionResult — The result of an extraction job.
  - `data` object, required
  - `warnings` string[], required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/mixedbread/apis/mxbai-omni.md) · [All operations](https://skmtc.net/mixedbread/apis/mxbai-omni/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mixedbread/mxbai-omni/revisions/d47e1d852549/schema)
