API Question About addTask

scrapefun

A-Parser Enterprise License
A-Parser Enterprise
Based on the sample code given to use a preset:

Code:
{
  "password" : "pass",
  "action" : "addTask",
  "data" : {
      "queriesFrom" : "text",
      "queries" : [
        "google.com",
        "yandex.ru"
      ],
      "configPreset" : "default",
      "preset" : "Analyze Domains"
  }
}

1) If the preset already has a queries file or multiple queries files defined will the values specified using the "QueriesFrom" and "QueriesFile" options override the queries file values specified in the preset?

2) Does addTask use the information from the preset about the format and location of the results file or does that need to be specified? I assume it does use the preset values but wasn't sure.

3) To specify a queries file located in the "results" directory would this be correct?

"queriesFile": "results/some_sub_directory/queries.txt",


Thanks!
 
1) If the preset already has a queries file or multiple queries files defined will the values specified using the "QueriesFrom" and "QueriesFile" options override the queries file values specified in the preset?
When you run via addTask a saved preset, you must specify queriesFrom and queries/queriesFile. Therefore, they override the preset values.
2) Does addTask use the information from the preset about the format and location of the results file or does that need to be specified? I assume it does use the preset values but wasn't sure.
Yes, if the query does not override any other parameters (except queries), they will be taken from the preset.
3) To specify a queries file located in the "results" directory would this be correct?

"queriesFile": "results/some_sub_directory/queries.txt",
Yes, it will be correct
 
Back
Top