@@ -5,8 +5,9 @@ Python applications. It provides useful features like parameters encoding to im
5
5
<!-- toc -->
6
6
7
7
- [ Quick Start] ( #quick-start )
8
- - [ API key ] ( #api-key )
8
+ - [ API token ] ( #api-token )
9
9
- [ API Reference] ( #api-reference )
10
+ - [ Exceptions] ( #exceptions )
10
11
- [ Examples] ( #examples )
11
12
12
13
<!-- tocstop -->
@@ -21,27 +22,25 @@ result = client.general_request('https://example.com')
21
22
print (result.content)
22
23
```
23
24
24
- ## API key
25
- In order to get API key you'll need to register at [ ScrapingAnt Service] ( https://app.scrapingant.com )
25
+ ## API token
26
+ In order to get API token you'll need to register at [ ScrapingAnt Service] ( https://app.scrapingant.com )
26
27
27
28
## API Reference
28
29
All public classes, methods and their parameters can be inspected in this API reference.
29
30
30
31
<a name =" ScrapingAntClient " ></a >
31
32
32
- #### [ ] ( #ScrapingAntClient ) ` ScrapingAntClient(token) `
33
+ #### [ ] ( #ScrapingAntClient ) ScrapingAntClient(token)
33
34
35
+ Main class of this library.
34
36
35
- | Param | Type | Default |
36
- | --- | --- | --- |
37
- | token | <code >string</code > | |
38
-
37
+ | Param | Type |
38
+ | --- | --- |
39
+ | token | <code >string</code > |
39
40
40
41
* * *
41
42
42
- <a name =" ScrapingAntClient+scrape " ></a >
43
-
44
- ### [ ] ( #ScrapingAntClient+scrape ) ` ScrapingAntClient.general_request(url, cookies, js_snippet, proxy_country, return_text) ` ⇒ Response
43
+ #### [ ] ( #ScrapingAntClient+general_request ) ` ScrapingAntClient.general_request(url, cookies, js_snippet, proxy_country, return_text) ` ⇒ Response
45
44
46
45
https://docs.scrapingant.com/request-response-format#available-parameters
47
46
@@ -57,7 +56,7 @@ https://docs.scrapingant.com/request-response-format#available-parameters
57
56
58
57
* * *
59
58
60
- ### [ ] ( #Cookie ) Cookie
59
+ #### [ ] ( #Cookie ) Cookie
61
60
Class defining cookie. Curently supports only name and value
62
61
63
62
| Param | Type |
@@ -67,25 +66,29 @@ Class defining cookie. Curently supports only name and value
67
66
68
67
* * *
69
68
70
- ### [ ] ( #ProxyCountry ) ProxyCountry
69
+ #### [ ] ( #ProxyCountry ) ProxyCountry
71
70
72
71
Enum containing all available proxy countries
73
72
74
73
* * *
75
74
76
- ### [ ] ( #Response ) Response
75
+ #### [ ] ( #Response ) Response
77
76
Class defining cookie. Curently supports only name and value
78
77
79
78
| Param | Type |
80
79
| --- | --- |
81
80
| content | <code >string</code > |
82
81
| cookies | <code >List[ Cookie] </code > |
83
82
84
- * * *
83
+ ## [ ] ( #exceptions ) Exceptions
85
84
86
- ### [ ] ( # ScrapingantClientException) ScrapingantClientException
85
+ ` ScrapingantClientException ` is base Exception class, used for all errors.
87
86
88
- ` ScrapingantClientException ` is base Exception class, used for all errors.
87
+ | Exception | Reason |
88
+ | --- | --- |
89
+ | ScrapingantInvalidTokenException | The API token is wrong or you have exceeded the API calls request limit
90
+ | ScrapingantInvalidInputException | Invalid value provided. Please, look into error message for more info |
91
+ | ScrapingantInternalException | Something went wrong with the server side code. Try again later or contact ScrapingAnt support |
89
92
90
93
* * *
91
94
0 commit comments