Skip to main content
POST
/
v2
/
inbound
/
opportunities
/
search
Search opportunities
curl --request POST \
  --url https://enrich.octolane.com/v2/inbound/opportunities/search \
  --header 'Content-Type: <content-type>' \
  --header 'X-API-Key: <x-api-key>' \
  --data '
{
  "pipeline_id": "<string>",
  "stage_id": "<string>",
  "query": "<string>",
  "filters": [
    {}
  ],
  "sort": {},
  "cursor": "<string>",
  "limit": 123,
  "fields": [
    "<string>"
  ]
}
'
Advanced search endpoint for Opportunities. Supports filters on system and custom fields, sorting, cursor pagination, and field selection.
pipeline_id is mandatory.

Request

X-API-Key
string
required
Your Octolane API key.
Content-Type
string
required
Must be application/json.

Body parameters

pipeline_id
string
required
Pipeline UUID.
stage_id
string
Filter opportunities by stage.
query
string
Basic text search. Alias: q.
filters
array
Array of filter objects. See Filters.
sort
string | object | array
Sort configuration. Default: updated_at desc.
cursor
string
Opaque cursor from a previous response.
limit
number
default:"100"
Page size. Max 500.
fields
string[]
Fields to return.

Example request

curl -X POST "https://enrich.octolane.com/v2/inbound/opportunities/search" \
  -H "X-API-Key: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "pipeline_id": "pipeline_uuid",
    "stage_id": "stage_uuid",
    "limit": 10,
    "filters": [
      { "field": "amount", "operator": "gte", "value": 50000 },
      { "field": "deal_source", "operator": "eq", "value": "partner" }
    ],
    "sort": { "field": "updated_at", "direction": "desc" },
    "fields": [
      "id", "name", "stage_id", "stage_name", "amount",
      "account_id", "contact_id", "custom_fields"
    ]
  }'

Supported sort fields

updated_at, created_at, name, amount, probability, close_date, next_action_date, stage_id, owner_id, id

Response

Identical shape to GET /opportunities.