If you have a large amount of custom data about places that you would like to import, you can use the Imports API to load bulk files into the Boone database, with these Data Formats.
Account Setup Required
If you want to use these features, please contact your account manager or [email protected] to ensure that you have correct AWS permissions for S3 access.
/api/v2/imports/:import_id
Check the status of the import corresponding to a given import id.
Returns
status: 200
{
"data": {
"id": 8,
"started_at": "2016-12-16T13:27:52.149Z",
"completed_at": null,
"files": [
{
"file_url": "s3://bucket/data_file.csv",
"item_type": "places",
"format": "json",
"completed_at": nil,
"error_text": nil,
"completed_count": 0,
"item_count": 10
}
]
}
}
/api/v2/imports
Create a new import.
Accepts
{
"import": {
"source_id": 8,
"files": [
{
"file_url": "s3://bucket/data_file.json",
"item_type": "places",
"format": "json"
}
]
}
}
Returns
status: 200
{
"data": {
"id": 8,
"started_at": "2016-12-16T13:27:52.149Z",
"completed_at": null,
"files": [
{
"file_url": "s3://bucket/data_file.json",
"item_type": "places",
"format": "json",
"completed_at": nil,
"error_text": nil,
"completed_count": 0,
"item_count": 10
}
]
}
}
Complete documentation for import data formatting is available here.
/api/v2/imports
Return a list of your imports.
Returns
status: 200
{
"data": [
{
"id": 8,
"started_at": "2016-12-16T13:27:52.149Z",
"completed_at": null,
"files": [
{
"file_url": "s3://bucket/data_file.json",
"item_type": "places",
"format": "json",
"completed_at": nil,
"error_text": nil,
"completed_count": 0,
"item_count": 10
}
]
}
]
}
Data formats
import
import
Name | Type | Required? | Description |
---|---|---|---|
id | integer | No | Database ID of the import. |
source_id | integer | Yes | Target source ID for the import. |
started_at | string | Yes | Time that the import was started. |
completed_at | string | No | Time that the import was completed, if it has been. |
files | array of file objects | Yes | Files to be included in the import. |
file
file
Name | Type | Required? | Description |
---|---|---|---|
item_type | string | Yes | Type of data included in import. places and tags supported. |
format | string | Yes | Format of file to be imported. csv and json supported. |
file_url | strings | Yes | File to be included in the import. |
completed_at | string | No | Time that the file was completed, if it has been. |
error_text | string | No | Error information if the file resulted in error. |
completed_count | integer | Yes | Number of total places that have been processed. |
item_count | integer | Yes | Number of total places that will be processed. |
File formats
Updated 2 years ago