Proxy Sale
  • Introduction
  • Getting Started
  • API Reference
    • Balance
      • Get Balance
      • Add Balance
      • Pay Methods
    • Proxies
      • List Proxies
      • Download Proxies
      • Set Proxy Comments
    • Order
      • Reference List
      • Calculate Order
      • Create Order
    • Renewal
      • Calculate Renewal
      • Create Renewal Order
    • Residential Proxies
      • Package Info
      • Download Geo
      • Get IP Lists
      • Create IP List
      • Rename IP List
      • Delete IP List
      • API-TOOL
  • Users Links
    • FAQ
    • Blog
  • Support
    • support@proxy-sale.com
    • Telegram
Powered by GitBook
On this page
  1. API Reference
  2. Residential Proxies

Package Info

GET https://proxy-sale.com/personal/api/v1/{apiKey}/resident/package

This endpoint retrieves information about your current residential proxy package, including/resident/package details like traffic usage and package expiry. It's essential for monitoring your existing subscription and planning for future needs.

Headers

Name
Value

Accept

application/json

Path parameters

Name
Type
Description

apiKey*

string

API key to authorize requests

Request examples

curl -X 'GET' \
  'https://proxy-sale.com/personal/api/v1/YOUR_API_KEY_HERE/resident/package' \
  -H 'accept: application/json'
<?php

$apiKey = "YOUR_API_KEY_HERE";
$url = 'https://proxy-sale.com/personal/api/v1/' . $apiKey . '/resident/package';

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
    'accept: application/json'
));

$result = curl_exec($ch);

if (curl_errno($ch)) {
    echo 'Error: ' . curl_error($ch);
}

curl_close($ch);

echo $result;

?>
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;

public class GetPackageInfoExample {
    public static void main(String[] args) {
        String apiKey = "YOUR_API_KEY_HERE";
        try {
            URL url = new URL("https://proxy-sale.com/personal/api/v1/" + apiKey + "/resident/package");
            HttpURLConnection conn = (HttpURLConnection) url.openConnection();
            conn.setRequestMethod("GET");
            conn.setRequestProperty("Accept", "application/json");

            BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
            String inputLine;
            StringBuilder response = new StringBuilder();

            while ((inputLine = in.readLine()) != null) {
                response.append(inputLine);
            }
            in.close();

            // Print the response
            System.out.println(response.toString());

        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}

Response examples

{
  "status": "success",
  "data": {
    "is_active": true,
    "rotation": 60,
    "tarif_id": 2,
    "traffic_limit": 7516192768,
    "traffic_usage": 10,
    "expired_at": "d.m.Y H:i:s",
    "auto_renew": false
  },
  "errors": []
}
{
  "status": "error",
  "data": null,
  "errors": [
    {
      "message": "Make order with resident first",
      "code": 0,
      "customData": null
    }
  ]
}
PreviousResidential ProxiesNextDownload Geo

Last updated 1 year ago