Pro Import API

pro.import_data

The pro.import_data method starts a new import task with the supplied data.

Request Example

shell
1
[ "pro.import_data", "<token>", "Project1", "<DATA>",
2
{
3
'blacklist_hosts' => '',
4
'preserve_hosts' => false
5
}
6
]

Response Example

json
1
{ "task_id" => "109" }

pro.import_file

The pro.import_file method starts a new import task with the supplied server-local path.

Request Example

shell
1
[ "pro.import_file", "<token>", "Project1", "/home/data/report.xml",
2
{
3
'blacklist_hosts' => '',
4
'preserve_hosts' => false
5
}
6
]

Response Example

json
1
{ "task_id" => "109" }

pro.validate_import_file

The pro.validate_import_file method validates a file on disk to verify that it is a support data format. This method is non-standard in that it only returns a true or false value.

Request Example

shell
1
[ "pro.import_file", "<token>", "Project1", "/home/data/report.xml",
2
{
3
'blacklist_hosts' => '',
4
'preserve_hosts' => false
5
}
6
]

Response Example

json
1
true