Python module for working with A-Parser API. Compatible with Python version 2.7.* and >=3.8.
Usage
# example
from a_parser import AParser
aparser = AParser('http://127.0.0.1:9091/API', 'your pass')
print(aparser.ping())
# output
# { 'success': 1, 'data': 'pong' }
taskId = aparser.addTask(
[['SE::Google', 'default',
{
'type': 'override',
'id': 'formatresult',
'value': '$serp.format("$anchor\\n")'
}, {
'type': 'override',
'id': 'pagecount',
'value': 1
}, {
'type': 'override',
'id': 'useproxy',
'value': False
}
]],
'default',
'text',
'diamond',
resultsFormat= '$p1.preset',
uniqueQueries= False,
queryFormat= ['$query'],
resultsUnique= 'no',
resultsSaveTo= 'file',
resultsFileName= '$datefile.format().txt',
doLog= 'no',
keepUnique= 'No',
moreOptions= False,
resultsPrepend= '',
resultsAppend= '',
configOverrides= [],
queryBuilders= []
)['data']
aparser.waitForTask(taskId)
print(aparser.getTaskResultsFile(taskId))
# output
# {'success': 1, 'data': 'http://127.0.0.1:9091/downloadResults?fileName=Jul-29_17-33-37.txt&token=utmxidbc'}
print(aparser.oneRequest('SE::Yahoo::Suggest', 'default', 'spider'))
# output
# {'success': 1, 'data': {'resultString': 'spider - spider:\nspider solitaire\nspiderman\nspider bites\nspider bite pictures\nspider solitaire two suits\nspider plant\nspider-man\nspider solitaire free\nspider bites pictures and symptoms\nspider monkey\n', 'logs': [[0, 1596033005, 'Parser SE::Yahoo::Suggest::0 parse query spider'], [0, 1596033005, 'Use proxy http://51.255.55.144:28466'], [0, 1596033006, 'GET(1): http://sugg.search.yahoo.com/gossip-us-fp/?nresults=10&output=yjson&version=&command=spider - 200 OK (0.3 KB)'], [3, 1596033006, 1], [0, 1596033006, 'Thread complete work']]}}
Documentation
Metadata
Release files for a-parser 3.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| a_parser-3.0.1.tar.gz | 3.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| a_parser-3.0.1-py2-none-any.whl | Python 2 | none | any | Details |
Total release size: 6.9 kB
Release files / a_parser-3.0.1.tar.gz
| Download URL | a_parser-3.0.1.tar.gz |
|---|---|
| Size | 3.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
264879081c8fb654ed5c7b9fff81cc2372efaa25587f14a19eb438012d8e9569
|
|
BLAKE2b-256 checksum How to use checksums |
bd4760a1f5d4d6963a98d9ff536e4c75a4fc53a2a1f3778cc60ed298c27ef609
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.8.3
|
Release files / a_parser-3.0.1-py2-none-any.whl
| Download URL | a_parser-3.0.1-py2-none-any.whl |
|---|---|
| Size | 4.0 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
6ff42e5c79f0b144b86a44dfb08c5e690d6c5eb31badc9b827323d07f593ab5e
|
|
BLAKE2b-256 checksum How to use checksums |
ca12ebf8cab861a76747ce7d36c6fb40e5d50266f22af6cbb3662a17ce8570a2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.8.3
|
Security for a-parser 3.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.