curl --request POST \
--url https://api.revenuebase.ai/v2/contact/company/exports/estimate \
--header 'Content-Type: application/json' \
--header 'X-Key: <api-key>' \
--data '
{
"filter": {
"type": "group",
"op": "AND",
"children": [
{
"type": "condition",
"column": "HEADQUARTERS_COUNTRY_NAME_ORG",
"operator": "eq",
"value": "United States"
}
]
},
"columns": [
"RBID_ORG",
"COMPANY_NAME_ORG",
"DOMAIN_ORG"
],
"format": "csv",
"compression": "none",
"maxRows": 100,
"filename": "us-companies"
}
'import requests
url = "https://api.revenuebase.ai/v2/contact/company/exports/estimate"
payload = {
"filter": {
"type": "group",
"op": "AND",
"children": [
{
"type": "condition",
"column": "HEADQUARTERS_COUNTRY_NAME_ORG",
"operator": "eq",
"value": "United States"
}
]
},
"columns": ["RBID_ORG", "COMPANY_NAME_ORG", "DOMAIN_ORG"],
"format": "csv",
"compression": "none",
"maxRows": 100,
"filename": "us-companies"
}
headers = {
"X-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filter: {
type: 'group',
op: 'AND',
children: [
{
type: 'condition',
column: 'HEADQUARTERS_COUNTRY_NAME_ORG',
operator: 'eq',
value: 'United States'
}
]
},
columns: ['RBID_ORG', 'COMPANY_NAME_ORG', 'DOMAIN_ORG'],
format: 'csv',
compression: 'none',
maxRows: 100,
filename: 'us-companies'
})
};
fetch('https://api.revenuebase.ai/v2/contact/company/exports/estimate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.revenuebase.ai/v2/contact/company/exports/estimate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filter' => [
'type' => 'group',
'op' => 'AND',
'children' => [
[
'type' => 'condition',
'column' => 'HEADQUARTERS_COUNTRY_NAME_ORG',
'operator' => 'eq',
'value' => 'United States'
]
]
],
'columns' => [
'RBID_ORG',
'COMPANY_NAME_ORG',
'DOMAIN_ORG'
],
'format' => 'csv',
'compression' => 'none',
'maxRows' => 100,
'filename' => 'us-companies'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.revenuebase.ai/v2/contact/company/exports/estimate"
payload := strings.NewReader("{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.revenuebase.ai/v2/contact/company/exports/estimate")
.header("X-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.revenuebase.ai/v2/contact/company/exports/estimate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}"
response = http.request(request)
puts response.read_body{
"creditsEstimate": 100
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Estimate Company Export
Forecast the credit cost of a company file before starting its export job.
curl --request POST \
--url https://api.revenuebase.ai/v2/contact/company/exports/estimate \
--header 'Content-Type: application/json' \
--header 'X-Key: <api-key>' \
--data '
{
"filter": {
"type": "group",
"op": "AND",
"children": [
{
"type": "condition",
"column": "HEADQUARTERS_COUNTRY_NAME_ORG",
"operator": "eq",
"value": "United States"
}
]
},
"columns": [
"RBID_ORG",
"COMPANY_NAME_ORG",
"DOMAIN_ORG"
],
"format": "csv",
"compression": "none",
"maxRows": 100,
"filename": "us-companies"
}
'import requests
url = "https://api.revenuebase.ai/v2/contact/company/exports/estimate"
payload = {
"filter": {
"type": "group",
"op": "AND",
"children": [
{
"type": "condition",
"column": "HEADQUARTERS_COUNTRY_NAME_ORG",
"operator": "eq",
"value": "United States"
}
]
},
"columns": ["RBID_ORG", "COMPANY_NAME_ORG", "DOMAIN_ORG"],
"format": "csv",
"compression": "none",
"maxRows": 100,
"filename": "us-companies"
}
headers = {
"X-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filter: {
type: 'group',
op: 'AND',
children: [
{
type: 'condition',
column: 'HEADQUARTERS_COUNTRY_NAME_ORG',
operator: 'eq',
value: 'United States'
}
]
},
columns: ['RBID_ORG', 'COMPANY_NAME_ORG', 'DOMAIN_ORG'],
format: 'csv',
compression: 'none',
maxRows: 100,
filename: 'us-companies'
})
};
fetch('https://api.revenuebase.ai/v2/contact/company/exports/estimate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.revenuebase.ai/v2/contact/company/exports/estimate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filter' => [
'type' => 'group',
'op' => 'AND',
'children' => [
[
'type' => 'condition',
'column' => 'HEADQUARTERS_COUNTRY_NAME_ORG',
'operator' => 'eq',
'value' => 'United States'
]
]
],
'columns' => [
'RBID_ORG',
'COMPANY_NAME_ORG',
'DOMAIN_ORG'
],
'format' => 'csv',
'compression' => 'none',
'maxRows' => 100,
'filename' => 'us-companies'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.revenuebase.ai/v2/contact/company/exports/estimate"
payload := strings.NewReader("{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.revenuebase.ai/v2/contact/company/exports/estimate")
.header("X-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.revenuebase.ai/v2/contact/company/exports/estimate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filter\": {\n \"type\": \"group\",\n \"op\": \"AND\",\n \"children\": [\n {\n \"type\": \"condition\",\n \"column\": \"HEADQUARTERS_COUNTRY_NAME_ORG\",\n \"operator\": \"eq\",\n \"value\": \"United States\"\n }\n ]\n },\n \"columns\": [\n \"RBID_ORG\",\n \"COMPANY_NAME_ORG\",\n \"DOMAIN_ORG\"\n ],\n \"format\": \"csv\",\n \"compression\": \"none\",\n \"maxRows\": 100,\n \"filename\": \"us-companies\"\n}"
response = http.request(request)
puts response.read_body{
"creditsEstimate": 100
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Credits and plans
PAYG is Pay-as-you-go. AYCE is All-you-can-eat.| Usage | PAYG | AYCE |
|---|---|---|
| Estimate; no job or hold | Free 0 credits | Free 0 credits |
When to use Company Estimate
Check a proposed company file before reserving credits. Send the same filter, columns, format, compression, and maxRows you intend to use for Company Export.Example
SetREVENUEBASE_API_KEY to your API key.
curl --request POST 'https://api.revenuebase.ai/v2/contact/company/exports/estimate' \
--header "X-Key: $REVENUEBASE_API_KEY" \
--header 'Content-Type: application/json' \
--data '{
"filter": {
"type": "group",
"op": "AND",
"children": [
{
"type": "condition",
"column": "HEADQUARTERS_COUNTRY_NAME_ORG",
"operator": "eq",
"value": "United States"
}
]
},
"columns": [
"RBID_ORG",
"COMPANY_NAME_ORG",
"DOMAIN_ORG"
],
"format": "csv",
"compression": "none",
"maxRows": 100,
"filename": "us-companies"
}'
{
"creditsEstimate": 100
}
Read the forecast
creditsEstimate is the estimated PAYG charge, based on matching companies and the row cap. It is null when export metering does not apply, including AYCE. The call creates no export job and reserves no credits.
The PAYG chart is 1 credit per company row, plus 10 per SmartSearch filter node per request. Selected company fields do not add contact email/mobile reveal charges.
Estimate, hold, and charge
With maxRows=100 and no SmartSearch nodes, the start request can require a 100-credit hold, even if fewer companies match. One SmartSearch node adds 10 credits, making that bound 110. The final charge uses the companies actually written plus any SmartSearch node fees. Use a positive explicit maxRows to cap the job. Zero uses the service maximum. A forecast can be below the hold; have enough balance for the bound before starting. Company and person/job criteria are supported for company files.Errors and retries
Correct unsupported fields or filters before retrying a 400 or 422 response. If a 429 response is returned, wait for Retry-After. Contact and company routes share the default 10 requests per second per user.Next steps
Review the budget, then call Start Company Export with the same body. Reduce maxRows if the hold is too large.Authorizations
Body
Company or contact conditions selecting distinct companies.
Show child attributes
Show child attributes
Company fields to write; omitted or empty uses company defaults. ["*"] expands to company catalog fields.
File format: csv, json, or parquet; json by default.
File compression: gz, zip, or none; gz by default.
Use a positive cap up to 1,000,000. Zero uses the maximum. PAYG holds one credit per capped row plus SmartSearch node fees.
Optional base filename, up to 150 characters. The service adds the format and compression extension.
Ignored for company files. Company fields do not add contact email or mobile reveal charges.
Response
Successful Response
The response is of type Response Estimate Company Export V1 Company Exports Estimate Post · object.
Was this page helpful?
