Last updated 2 years ago
GET https://api.oxylabs.io/v1/whitelisted_ips
curl -u username:password "https://api.oxylabs.io/v1/whitelisted_ips"
<?php $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, "https://api.oxylabs.io/v1/whitelisted_ips"); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curl, CURLOPT_USERPWD, 'username:password'); $result = curl_exec($curl); ?>
import requests requests.get('https://api.oxylabs.io/v1/whitelisted_ips', auth=('username', 'password'))
{ "data": [ { "id": 9765, "address": "127.0.0.1" }, { "id": 9766, "address": "127.0.0.2" } ] }
200
成功。响应正文包含所有当前列入白名单的 IP 和其 ID。