Search states
curl --request POST \
--url https://api.companyenrich.com/v2/geo/states \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"countryCodes": [
"<string>"
],
"query": "<string>",
"pageSize": 50,
"cursor": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
countryCodes: ['<string>'],
query: '<string>',
pageSize: 50,
cursor: '<string>'
})
};
fetch('https://api.companyenrich.com/v2/geo/states', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.companyenrich.com/v2/geo/states"
payload = {
"countryCodes": ["<string>"],
"query": "<string>",
"pageSize": 50,
"cursor": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"items": [
{
"id": 123,
"name": "<string>",
"code": "<string>",
"countryCode": "<string>",
"latitude": 123,
"longitude": 123
}
],
"nextCursor": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>",
"errors": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Geo
Search states
Searches names using a literal, case-insensitive substring. Results use cursor pagination in stable code or ID order. Cursors expire 30 minutes after the first page; keep the same filters when continuing. This endpoint does not consume credits.
POST
/
v2
/
geo
/
states
Search states
curl --request POST \
--url https://api.companyenrich.com/v2/geo/states \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"countryCodes": [
"<string>"
],
"query": "<string>",
"pageSize": 50,
"cursor": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
countryCodes: ['<string>'],
query: '<string>',
pageSize: 50,
cursor: '<string>'
})
};
fetch('https://api.companyenrich.com/v2/geo/states', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.companyenrich.com/v2/geo/states"
payload = {
"countryCodes": ["<string>"],
"query": "<string>",
"pageSize": 50,
"cursor": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"items": [
{
"id": 123,
"name": "<string>",
"code": "<string>",
"countryCode": "<string>",
"latitude": 123,
"longitude": 123
}
],
"nextCursor": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>",
"errors": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Authorizations
API Token used for authentication. Example: "Authorization: Bearer {token}"
Body
application/json
Up to 250 two-letter country codes. Results may belong to any supplied country. Codes are trimmed and case-insensitive.
Maximum array length:
250A literal, case-insensitive substring of the name. Leading and trailing whitespace is ignored.
Maximum string length:
100The maximum number of results to return. Defaults to 100.
Required range:
1 <= x <= 100The cursor from the previous response. Omit for the first page. Keep the same filters; pageSize may change.
Maximum string length:
2048