---
title: "Lam Run Endpoint"
method: POST
path: "/lam/run"
tags: ["LAM"]
---

# Lam Run Endpoint

`POST /lam/run`

## Request

- Base URL: `https://api.raccoonai.tech`
- URL: `https://api.raccoonai.tech/lam/run`
- Auth: API key in header `raccoon-secret-key`

## Request body

- LAMRequest
  - `query` string, required: The input query string for the request. This is typically the main prompt.
  - `chat_history` object[], nullable: The history of the conversation as a list of messages or objects you might use while building a chat app to give the model context of the past conversation.
  - `app_url` string, nullable: This is the entrypoint URL for the web agent.
  - `schema` object: The expected schema for the response. This is a dictionary where the keys describe the fields and the values describe their purposes.
  - `max_count` integer, nullable: The maximum number of results to extract.
  - `stream` boolean, nullable: Whether the response should be streamed back or not.
  - `mode` 'deepsearch' | 'default', nullable: Mode of execution.
  - `raccoon_passcode` string, required: The raccoon passcode associated with the end user on behalf of which the call is being made.
  - `advanced` Advanced, nullable
    - `block_ads` boolean, nullable: Whether to block advertisements during the browser session.
    - `solve_captchas` boolean, nullable: Whether to attempt automatic CAPTCHA solving.
    - `proxy` union: Proxy details for the browser session. Automatically defaults to True if solve_captchas is on.
      - ProxySettings
        - `country` string, nullable: Target country (2-letter ISO code).
        - `city` string, nullable: Target city.
        - `state` string, nullable: Target state (2-letter code).
        - `zip` integer, nullable: Target postal code.
      - boolean
    - `extension_ids` unknown[], nullable: list of extension ids
      - unknown

## Response `200`

Successful Response

- LAMResponse
  - `task_status` 'STARTING' | 'PROCESSING' | 'DONE' | 'HUMAN_INTERACTION' | 'FAILURE', required: The current status of the extraction task. For example: 'STARTING', 'PROCESSING', 'DONE', 'HUMAN_INTERACTION', or 'FAILURE'.
  - `message` string, required: A message providing the thought summary if the status is processing currently.
  - `data` object[], required: The extracted data as a list of objects when the status is DONE. Each object represents an extracted entity.
  - `properties` object, required: Additional metadata or details related to the run task.
  - `livestream_url` string, required: The Livestream URL

## Other responses

- `422`: Validation Error

## Changes

- **2025-03-18** `cc64732da5aa`: 2 breaking, 1 warning, 6 info
  - the request property `advanced/anyOf[subschema #1: Advanced]/proxy/anyOf[subschema #2]/` became not nullable
  - the `advanced/anyOf[subschema #1: Advanced]/proxy/anyOf[subschema #2]/` request property type changed from `null` to `boolean`
  - removed the request property `advanced/anyOf[subschema #1: Advanced]/proxy/anyOf[subschema #1: ProxySettings]/enable`
  - the `advanced` request property default value changed from `{"block_ads":false,"solve_captchas":false,"proxy":{"city":"","country":"","enable":false,"state":"","zip":0},"extension_ids":[]}` to `{"block_ads":false,"solve_captchas":false,"proxy":false,"extension_ids":[]}`
  - …5 more
- **2025-03-03** `b0c1c8f44dae`: 1 breaking, 10 warning, 11 info
  - removed `subschema #1` from the `advanced/anyOf[subschema #1: Advanced]/proxy` request property `anyOf` list
  - added the new `DONE` enum value to the `task_status` response property for the response status `200` (media type: application/json)
  - added the new `DONE` enum value to the `task_status` response property for the response status `200` (media type: text/event-stream)
  - added the new `FAILURE` enum value to the `task_status` response property for the response status `200` (media type: application/json)
  - …18 more

[Operation history](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/changes/lam/run/post.md)

---

[API](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api.md) - [All operations](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/revisions/cc64732da5aa?raw)
