Proxy

Lista wszystkich publicznie dostępnych metod interakcji z API.

GET

Lista proxy -/package/proxy-list/{id}

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/proxy-list/{id}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
with-hiddenNie koniecznienullableex-booleanfalse
countriesNie koniecznienullablearray{"UA": 10, "PL": 20}
searchNie koniecznienullablestring49
per-pageNie koniecznienullableinteger40
pageNie koniecznienullableinteger94
sort-byNie koniecznienullablestringapp\_validators\_ex_in_rule""
sort-orderNie koniecznienullablestringin:asc, desc"asc"
countries.*Nie konieczniedistinctstringcountry_code{"UA": 10, "PL": 20}
id1required97

Przykłady kodu

1async function getPackageProxyList() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy-list/{id}'
4      .replace("{id}", 97) + '?' + Object.entries({
5         "with-hidden": false,
6         "countries[UA]": 10,
7         "countries[PL]": 20,
8         "search": 49,
9         "per-page": 40,
10         "page": 94,
11         "sort-by": "",
12         "sort-order": "asc",
13         "countries.*[UA]": 10,
14         "countries.*[PL]": 20
15      }).map(([key, value]) => key + "=" + value).join('&'), {
16         method: 'GET',
17         headers: {
18            'Authorization': 'API-Token [YOUR TOKEN]',
19            'Content-Type': 'application/json'
20         }
21      }
22   );
23   
24   const res = await req.json();
25}

Przykłady odpowiedzi

GET

Pobierz dostępne miasta w kraju -/package/proxy/{id}/cities

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/proxy/{id}/cities

Parametry zapytania

IdentyfikatorRegulaminPrzykład
regionsNie konieczniearraydistinct[]
countrystringrequiredcountry_code""
regions.*Nie konieczniestring""
id1required93

Przykłady kodu

1async function getPackageProxyCities() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy/{id}/cities'
4      .replace("{id}", 93) + '?' + Object.entries({
5         "regions": [],
6         "country": "",
7         "regions.*": ""
8      }).map(([key, value]) => key + "=" + value).join('&'), {
9         method: 'GET',
10         headers: {
11            'Authorization': 'API-Token [YOUR TOKEN]',
12            'Content-Type': 'application/json'
13         }
14      }
15   );
16   
17   const res = await req.json();
18}

Przykłady odpowiedzi

GET

Pobierz dostępne regiony kraju -/package/proxy/{id}/regions

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/proxy/{id}/regions

Parametry zapytania

IdentyfikatorRegulaminPrzykład
countrystringrequiredcountry_code""
id1required16

Przykłady kodu

1async function getPackageProxyRegions() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy/{id}/regions'
4      .replace("{id}", 16) + '?' + Object.entries({
5         "country": ""
6      }).map(([key, value]) => key + "=" + value).join('&'), {
7         method: 'GET',
8         headers: {
9            'Authorization': 'API-Token [YOUR TOKEN]',
10            'Content-Type': 'application/json'
11         }
12      }
13   );
14   
15   const res = await req.json();
16}

Przykłady odpowiedzi

GET

Pobierz proxy -/package/proxy/{id}/{proxyIndex}

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/proxy/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
id1required56
proxyIndex1required46

Przykłady kodu

1async function getPackageProxy() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy/{id}/{proxyIndex}'
4      .replace("{id}", 56)
5      .replace("{proxyIndex}", 46), {
6         method: 'GET',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         }
11      }
12   );
13   
14   const res = await req.json();
15}

Przykłady odpowiedzi

PUT

Ukryj proxy -/package/hide/{id}/{proxyIndex}

Metoda zapytania

PUThttp://apilocal.stableproxy.com/v2/package/hide/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
id1required58
proxyIndex1required72

Przykłady kodu

1async function putPackageHide() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/hide/{id}/{proxyIndex}'
4      .replace("{id}", 58)
5      .replace("{proxyIndex}", 72), {
6         method: 'PUT',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         }
11      }
12   );
13   
14   const res = await req.json();
15}

Przykłady odpowiedzi

GET

Pobierz notatkę -/package/note/{id}/{proxyIndex}

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/note/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
noteNie koniecznienullablestring98
id1required6
proxyIndex1required95

Przykłady kodu

1async function getPackageNote() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/note/{id}/{proxyIndex}'
4      .replace("{id}", 6)
5      .replace("{proxyIndex}", 95) + '?' + Object.entries({
6         "note": 98
7      }).map(([key, value]) => key + "=" + value).join('&'), {
8         method: 'GET',
9         headers: {
10            'Authorization': 'API-Token [YOUR TOKEN]',
11            'Content-Type': 'application/json'
12         }
13      }
14   );
15   
16   const res = await req.json();
17}

Przykłady odpowiedzi

PUT

Zmień notatkę -/package/note/{id}/{proxyIndex}

Metoda zapytania

PUThttp://apilocal.stableproxy.com/v2/package/note/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
noteNie koniecznienullablestring98
id1required6
proxyIndex1required95

Przykłady kodu

1async function putPackageNote() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/note/{id}/{proxyIndex}'
4      .replace("{id}", 6)
5      .replace("{proxyIndex}", 95), {
6         method: 'PUT',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         },
11         body: JSON.stringify({
12            "note": 98
13         }),
14      }
15   );
16   
17   const res = await req.json();
18}

Przykłady odpowiedzi

GETPUT

Rotate proxy -/package/proxy-rotate/{id}/{proxyIndex}

Metoda zapytania

GEThttp://apilocal.stableproxy.com/v2/package/proxy-rotate/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
id1required82
proxyIndex1required72

Przykłady kodu

1async function getPackageProxyRotate() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy-rotate/{id}/{proxyIndex}'
4      .replace("{id}", 82)
5      .replace("{proxyIndex}", 72), {
6         method: 'GET',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         }
11      }
12   );
13   
14   const res = await req.json();
15}

Przykłady odpowiedzi

POST

Dodaj proxy -/package/proxy/{id}

Metoda zapytania

POSThttp://apilocal.stableproxy.com/v2/package/proxy/{id}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
fixedrequiredex-booleanfalse
intervalrequiredinteger49
countrequiredinteger30
countriesNie koniecznienullablearray{"UA": 10, "PL": 20}
countries.*Nie konieczniedistinctstringcountry_code{"UA": 10, "PL": 20}
id1required99

Przykłady kodu

1async function postPackageProxy() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy/{id}'
4      .replace("{id}", 99), {
5         method: 'POST',
6         headers: {
7            'Authorization': 'API-Token [YOUR TOKEN]',
8            'Content-Type': 'application/json'
9         },
10         body: JSON.stringify({
11            "fixed": false,
12            "interval": 49,
13            "count": 30,
14            "countries": {"UA": 10, "PL": 20},
15            "countries.*": {"UA": 10, "PL": 20}
16         }),
17      }
18   );
19   
20   const res = await req.json();
21}

Przykłady odpowiedzi

DELETE

Usuwanie serwera proxy -/package/proxy/{id}/{proxyIndex}

Metoda zapytania

DELETEhttp://apilocal.stableproxy.com/v2/package/proxy/{id}/{proxyIndex}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
id1required56
proxyIndex1required46

Przykłady kodu

1async function deletePackageProxy() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/proxy/{id}/{proxyIndex}'
4      .replace("{id}", 56)
5      .replace("{proxyIndex}", 46), {
6         method: 'DELETE',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         }
11      }
12   );
13   
14   const res = await req.json();
15}

Przykłady odpowiedzi

PUT

Zastępowanie proxy -/package/replace/{id}/{type}

Metoda zapytania

PUThttp://apilocal.stableproxy.com/v2/package/replace/{id}/{type}

Parametry zapytania

IdentyfikatorRegulaminPrzykład
type1in:non-workingrequired"non-working"
id1required56

Przykłady kodu

1async function putPackageReplace() {
2   const baseUrl = 'http://apilocal.stableproxy.com/v2';
3   const req = await fetch(baseUrl + '/package/replace/{id}/{type}'
4      .replace("{id}", 56)
5      .replace("{type}", "non-working"), {
6         method: 'PUT',
7         headers: {
8            'Authorization': 'API-Token [YOUR TOKEN]',
9            'Content-Type': 'application/json'
10         }
11      }
12   );
13   
14   const res = await req.json();
15}

Przykłady odpowiedzi