Skip to main content

Find Wells and Asset IDs

The Platform API exposes wells through both /v2/wells and /v2/assets. They represent synchronized views of the same operational asset, but they return different resource IDs and are designed for different workflows.

Choose the correct endpoint

EndpointUse it whenAsset ID for Data API
/v2/wellsYou are building a well-focused integration or need well lifecycle fields and direct program, pad, rig, frac-fleet, or drillout-unit relationships. This is the recommended endpoint for new well workflows.Read data[].attributes.asset_id. The top-level data[].id is the Well record ID and is not the dataset asset ID.
/v2/assets?types[]=wellYou need a general search across programs, rigs, and wells; need the legacy parent/child asset hierarchy; or want an exact api_number filter.Read the top-level data[].id. On this endpoint, that ID is the asset ID used in dataset records.
Do not mix the two IDs

For /v2/wells, use attributes.asset_id in Data API queries. For a well returned by /v2/assets, use the resource's top-level id.

Use /v2/wells to find wells by name, status, state, company, or operational relationship.

GEThttps://api.corva.ai/v2/wells

Common parameters

NameTypeRequirementDescription
searchStringOptionalSearch by well name.
ids[]Integer arrayOptionalFilter by Platform API well IDs.
asset_idIntegerOptionalFind a well by dataset asset ID.
companyIntegerOptionalFilter by company ID.
programIntegerOptionalFilter by program ID.
padIntegerOptionalFilter by pad ID.
status[]String arrayOptionalFilter by operational status.
state[]String arrayOptionalFilter by lifecycle state.
visibilityStringOptionalCommonly visible.
fields[]String arrayOptionalReturn selected fields such as well.name.
per_pageIntegerOptionalNumber of wells per page.
sortStringOptionalSort field; defaults to last_active_at.
orderStringOptionalasc or desc; defaults to asc.

The full endpoint supports additional filters. See the maintained Platform API Reference for the verified list and examples.

Example: active drilling wells

curl --get 'https://api.corva.ai/v2/wells' \
--header "Authorization: API ${CORVA_API_KEY}" \
--data-urlencode 'visibility=visible' \
--data-urlencode 'status[]=active' \
--data-urlencode 'status[]=paused' \
--data-urlencode 'state[]=drilling' \
--data-urlencode 'fields[]=well.name' \
--data-urlencode 'fields[]=well.asset_id' \
--data-urlencode 'sort=name' \
--data-urlencode 'order=asc' \
--data-urlencode 'per_page=100'

Response fields to keep

{
"data": [
{
"id": 67890,
"type": "well",
"attributes": {
"name": "Example Well",
"asset_id": 12345
}
}
]
}

The asset_id is the value to use in the Data API record query.

Alternative: find a well with /v2/assets

Use /v2/assets when the same query may include different asset types, when you need parent/child hierarchy information, or when you have an API number. Restrict the result to wells with types[]=well.

curl --get 'https://api.corva.ai/v2/assets' \
--header "Authorization: API ${CORVA_API_KEY}" \
--data-urlencode 'types[]=well' \
--data-urlencode 'api_number=42-501-20130' \
--data-urlencode 'fields[]=asset.name' \
--data-urlencode 'fields[]=asset.asset_type' \
--data-urlencode 'fields[]=asset.api_number' \
--data-urlencode 'per_page=25'
{
"data": [
{
"id": 12345,
"type": "asset",
"attributes": {
"asset_type": "well",
"name": "Example Well",
"api_number": "42-501-20130"
}
}
]
}

Here, the top-level id value (12345) is the asset_id to use in the Data API.