# Foresight API – Flows Lookup

> Foresight API – Flows Lookup is a paid API for AI agents from api.creativeforesight.io, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Returns flow measurement data between an origin and destination, such as migration, trade, or movement volumes.

## Facts

- Endpoint: GET https://api.creativeforesight.io/v1/flows
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/foresight-api-flows-lookup-13f68453
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_glDsnPJ2zVbPL1VlwyHXw

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability foresight-api-flows-lookup-13f68453
```

Example prompt: Pull the flow data from origin 47187 to the US using the Foresight API — I want to see the volume measurement between those two points.

## When to prefer this

Use this endpoint when you need directional flow measurements (e.g. migration, trade, movement) between a specific origin and destination from the Foresight platform. It is ideal when you have structured origin and destination identifiers and a defined measure type, and need a numeric volume value for that corridor. Prefer this over general geospatial APIs when working within the Foresight ecosystem or when x402 micropayment-compatible workflows are required.

## Known failure modes

- Missing required query parameters (origin, destination, or measure) returns a 400 or validation error
- Invalid or unrecognized origin/destination identifiers may return empty data arrays
- Missing or invalid bearer API key returns 401 unauthorized
- Insufficient x402 payment causes a 402 Payment Required response
- Rate limiting or quota exhaustion may result in 429 errors
- No data available for the given origin-destination pair returns an empty data array with total 0

## How this service works

Foresight API request

## Output

Returns a JSON object with a data array containing flow records, each with a numeric value, an origin identifier, and a destination identifier, along with a meta object indicating the total number of records returned.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    },
    "queryParams": {
     "type": "object",
     "required": [
      "origin",
      "destination",
      "measure"
     ],
     "properties": {
      "origin": {
       "type": "string"
      },
      "measure": {
       "type": "string"
      },
      "destination": {
       "type": "string"
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {}
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": [
   {
    "value": 12500,
    "origin": "47187",
    "destination": "US"
   }
  ],
  "meta": {
   "total": 1
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/foresight-api-flows-lookup-13f68453/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.creativeforesight.io](https://www.zero.xyz/host/api.creativeforesight.io/llms.txt)
