Tasks v1

Retrieve Task Run Input

Retrieves the input of a run by run_id.

get/v1/tasks/runs/{run_id}/input

Path parameters

run_idstring required

Response

Successful Response

metadataobject nullable

User-provided metadata stored with the run. Keys and values must be strings with a maximum length of 16 and 512 characters respectively.

previous_interaction_idstring nullable

Interaction ID to use as context for this request.

processorstring required

Processor to use for the task.

Example response

{
  "processor": "base",
  "source_policy": {
    "after_date": "2024-01-01",
    "exclude_domains": [
      "reddit.com",
      "x.com",
      ".ai"
    ],
    "include_domains": [
      "wikipedia.org",
      "usa.gov",
      ".edu"
    ]
  },
  "task_spec": {
    "input_schema": {
      "json_schema": {
        "additionalProperties": false,
        "properties": {
          "gdp": {
            "description": "GDP in USD for the year, formatted like '$3.1 trillion (2023)'",
            "type": "string"
          }
        },
        "required": [
          "gdp"
        ],
        "type": "object"
      }
    },
    "output_schema": {
      "json_schema": {
        "additionalProperties": false,
        "properties": {
          "gdp": {
            "description": "GDP in USD for the year, formatted like '$3.1 trillion (2023)'",
            "type": "string"
          }
        },
        "required": [
          "gdp"
        ],
        "type": "object"
      }
    }
  }
}

Changes