Export properties as CSV or NDJSON
curl --request POST \
--url https://api.westkite.com/v1/exports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "properties",
"where": [
"<string>"
],
"in": "<string>",
"within": {
"coordinates": "<array>"
},
"format": "csv",
"max_rows": 123,
"max_cost_usd": 123
}
'import requests
url = "https://api.westkite.com/v1/exports"
payload = {
"type": "properties",
"where": ["<string>"],
"in": "<string>",
"within": { "coordinates": "<array>" },
"format": "csv",
"max_rows": 123,
"max_cost_usd": 123
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'properties',
where: ['<string>'],
in: '<string>',
within: {coordinates: '<array>'},
format: 'csv',
max_rows: 123,
max_cost_usd: 123
})
};
fetch('https://api.westkite.com/v1/exports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"status": "ready",
"total": 123,
"scope": "<string>",
"resolved_scope": {
"input": "<string>",
"kind": "city",
"label": "<string>",
"county_fips": [
"<string>"
],
"includes_neighboring_places": true,
"basis": "city_records",
"radius_m": 123,
"note": "<string>"
},
"file": {
"url": "<string>",
"format": "csv",
"rows": 123,
"columns": [
"<string>"
],
"expires_at": "2023-11-07T05:31:56Z"
},
"rows_left_out": 123,
"limit_note": "<string>",
"sources": [
{}
],
"preview": [
{}
]
},
"missing": [
{
"field": "<string>",
"reason": "not_covered",
"note": "<string>"
}
],
"billing": {
"operation_id": "<string>",
"operation": "<string>",
"charged_usd": 123,
"balance_usd": 123,
"replayed": true
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}Records
Export a market
Every matching property in a market, up to 100,000 rows, as one CSV or NDJSON file. $1 per 1,000 rows.
POST
/
exports
Export properties as CSV or NDJSON
curl --request POST \
--url https://api.westkite.com/v1/exports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "properties",
"where": [
"<string>"
],
"in": "<string>",
"within": {
"coordinates": "<array>"
},
"format": "csv",
"max_rows": 123,
"max_cost_usd": 123
}
'import requests
url = "https://api.westkite.com/v1/exports"
payload = {
"type": "properties",
"where": ["<string>"],
"in": "<string>",
"within": { "coordinates": "<array>" },
"format": "csv",
"max_rows": 123,
"max_cost_usd": 123
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'properties',
where: ['<string>'],
in: '<string>',
within: {coordinates: '<array>'},
format: 'csv',
max_rows: 123,
max_cost_usd: 123
})
};
fetch('https://api.westkite.com/v1/exports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"status": "ready",
"total": 123,
"scope": "<string>",
"resolved_scope": {
"input": "<string>",
"kind": "city",
"label": "<string>",
"county_fips": [
"<string>"
],
"includes_neighboring_places": true,
"basis": "city_records",
"radius_m": 123,
"note": "<string>"
},
"file": {
"url": "<string>",
"format": "csv",
"rows": 123,
"columns": [
"<string>"
],
"expires_at": "2023-11-07T05:31:56Z"
},
"rows_left_out": 123,
"limit_note": "<string>",
"sources": [
{}
],
"preview": [
{}
]
},
"missing": [
{
"field": "<string>",
"reason": "not_covered",
"note": "<string>"
}
],
"billing": {
"operation_id": "<string>",
"operation": "<string>",
"charged_usd": 123,
"balance_usd": 123,
"replayed": true
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"retryable": true,
"docs_url": "<string>",
"reason": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"quoted_usd": 123,
"concurrent": 123,
"balance_usd": 123,
"available_usd": 123,
"spend_cap_usd": 123,
"spent_usd": 123
},
"request_id": "<string>"
}The Exports guide explains this endpoint in full.
Body
application/json
Send in (a market by name) or within (a GeoJSON polygon), not both.