NAV Navbar
Logo
PHP cURL

Introduction

Welcome to the GoGetProxy API! You can use our API to integrate your applications with our service and fully control your account.

GoGetProxy API is based on the REST architectural style. It means that you can manage all of the resorces in your account with standart HTTP request methods like POST, GET, PUT, and DELETE.

This API Reference describes each available endpoint and resource in the GoGetProxy API. Learn about parameters, errors, and how to format your requests.

You can use our API Playground to explore the API with your own data. See what calls are available, and how we format the data that’s returned.

Authentication

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

With our API we are using HTTP digest authentication. Enter your account email as the username and supply your API Key as the password. Your HTTP client library should have built-in support for digest authentication, but here’s a quick example on the right panel that shows how to authenticate with the –user option in curl and php-curl module.

You can create and manage your API keys in your account.

Account

Get Account Details

Retrieve your account details.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/account');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/account' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": {
        "email": "[email protected]",
        "name": "John Smith",
        "credit": 100,
        "currency_code": "USD"
    }
}

HTTP Request

GET /account

This method does not require any request parameters.

Response body parameters

Parameter Type Description
email string Account email address.
name string Account user name.
credit float The account credit.
currency_code string Three letters code of the account currency (ISO 4217).

Update Account Details

Change your account details.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/account');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT');
curl_setopt($ch, CURLOPT_POSTFIELDS, 'name=Tony Stark');
$result = curl_exec($ch);
?>
curl --request PUT \
--url 'https://gogetproxy.com/api/v1/account' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location \
--data 'name=Tony Stark'

HTTP Request

PUT /account

Request body parameters

Parameter Type Required Description
name string Yes New account user name

Response body parameters

Response returns your updated account details.

Proxy Servers

Get all servers

Get information about all proxy servers in your account.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/proxy' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": [
        {
            "id": 441,
            "country_code": "US",
            "country_name": "United States",
            "inbound_ip": "172.82.187.169",
            "outbound_ip": "2607:3f00:11:501:f5de:92a0:ec95:839b",
            "https_port": 3128,
            "socks_port": 4178,
            "username": "oijvdfhd",
            "password": "woeihhdv",
            "paid_till": 1483875086,
            "billing_option_id": 1,
            "autorenew": true,
            "status": "active"
        },
        {
            "id": 436,
            "country_code": "NL",
            "country_name": "Netherlands",
            "inbound_ip": "81.4.124.12",
            "outbound_ip": "2a00:d880:5:461:17f4:611e:f52a:83d6",
            "https_port": 3128,
            "socks_port": 4199,
            "username": "skdjfjdw",
            "password": "kjbckvfe",
            "paid_till": 1483875086,
            "billing_option_id": 2,
            "autorenew": true,
            "status": "active"
        },
        {
            "id": 431,
            "country_code": "RU",
            "country_name": "Russia",
            "inbound_ip": "185.22.172.108",
            "outbound_ip": "2a00:1838:30:54bd:0c2f:253b:b4c5:ab72",
            "https_port": 3128,
            "socks_port": 4202,
            "username": "jhvwafay",
            "password": "uyswefgh",
            "paid_till": 1483875086,
            "billing_option_id": 3,
            "autorenew": true,
            "status": "active"
        }
    ]
}

HTTP request

GET /proxy

This method does not require any request parameters.

Response body parameters

Response is an array of objects, each containing information about a specific server.

Get a specific server

Get information about a specific server by ID.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy/{server_id}');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/proxy/{server_id}' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": {
        "id": 441,
        "country_code": "US",
        "country_name": "United States",
        "inbound_ip": "172.82.187.169",
        "outbound_ip": "2607:3f00:11:501:f5de:92a0:ec95:839b",
        "https_port": 3128,
        "socks_port": 4178,
        "username": "oijvdfhd",
        "password": "woeihhdv",
        "paid_till": 1483875086,
        "billing_option_id": 1,
        "autorenew": true,
        "status": "active"
    }
}

HTTP request

GET /proxy/{server_id}

Path parameters

Parameter Description
server_id The unique id of the server.

Response body parameters

Parameter Type Description
id integer The ID of the proxy server.
country_code string Two letters country code (ISO 3166-1 alpha-2) of the proxy server location.
country_name string The name of the country of the proxy server location in English.
inbound_ip string The inbound IP of the proxy server.
outbound_ip string The outbound IP of the proxy server.
https_port integer The port for HTTP(s) connections.
socks_port integer The port for SOCKS5 connections.
username string The username to access the proxy server.
password string The password to access the proxy server.
paid_till integer The linux timestamp of the moment the proxy server is paid till.
billing_option_id integer The ID of the last billing option the server was ordered or renewed with.
autorenew boolean The boolean flag shows if the auto renew is enabled for the server.
status string The status of the proxy server. Possible values are active and suspended.

Get billing options

Get all available billing periods and prices for them. All prices already include all discounts for your account. Prices are given for a one server in your account currency.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy/billing');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/proxy/billing' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": [
        {
            "id": 1,
            "period": 1,
            "price": 0.08
        },
        {
            "id": 2,
            "period": 3,
            "price": 0.15
        },
        {
            "id": 3,
            "period": 7,
            "price": 0.25
        }
    ]
}

HTTP request

GET /proxy/billing

This method does not require any request parameters.

Response body parameters

Response is an array of objects, each containing information about a specific billing option.

Get a specific billing option

Get information about a specific billing option by ID. Price already includes all discounts for your account, it is given for a one server in your account currency.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy/billing/{billing_option_id}');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/proxy/billing/{billing_option_id}' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": {
        "id": 1,
        "period": 1,
        "price": 0.08
    }
}

HTTP request

GET /proxy/billing/{billing_option_id}

Path parameters

Parameter Description
billing_option_id The unique id of the billing option.

Response body parameters

Parameter Type Description
id integer The ID of the billing option.
period integer The billing period in days.
price float The price for the period, given for a one server in the currency of your account.

Renew a server

Renew a specific server.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy/{server_id}/renew');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT');
curl_setopt($ch, CURLOPT_POSTFIELDS, 'billing_option_id={billing_option_id}');
$result = curl_exec($ch);
?>
curl --request PUT \
--url 'https://gogetproxy.com/api/v1/proxy/{server_id}/renew' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location \
--data 'billing_option_id={billing_option_id}'

HTTP request

PUT /proxy/{server_id}/renew

Path parameters

Parameter Description
server_id The unique id for the server.

Request body parameters

Parameter Type Required Description
billing_option_id integer No The ID of the billing option for renewal. if not specified the last billing option for the server will be used.

Response body parameters

Request returns information on the renewed server.

Errors

Code Description
300 There is not enough credit in your account.

Order new servers

Add new proxy servers in your account.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/proxy');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, 'country_code={country_code}&amount={amount}&billing_option_id={billing_option_id}');
$result = curl_exec($ch);
?>
curl --request POST \
--url 'https://gogetproxy.com/api/v1/proxy' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location \
--data 'country_code={country_code}&amount={amount}&billing_option_id={billing_option_id}'

HTTP request

POST /proxy

Request body parameters

Parameter Type Required Description
country_code string Yes Two letters country code (ISO 3166-1 alpha-2) of the proxy servers’ location.
amount integer Yes Amount of the servers you want to order.
billing_option_id integer Yes The ID of the billing option for the new servers.
autorenew boolean No The boolean flag to enable or disable automatic renewal for the servers. If not specified, will be set to true.

Response body parameters

Request returns an array with the information on the ordered servers.

Errors

Code Description
300 There is not enough credit in your account.
310 There are not such amount of IPs available.

Finance

Get all transactions

Get all financial transactions in your account.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/finance/transaction');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/finance/transaction' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": [
        {
            "id": 327,
            "time": 1481283086,
            "type": "out",
            "amount": 8.1,
            "currency_code": "USD",
            "description": "Purchase of 15 proxy IP(s)"
        },
        {
            "id": 328,
            "time": 1482094478,
            "type": "out",
            "amount": 0.54,
            "currency_code": "USD",
            "description": "Account(s) renewal: #431"
        },
        {
            "id": 329,
            "time": 1482094577,
            "type": "out",
            "amount": 0.54,
            "currency_code": "USD",
            "description": "Account(s) renewal: #431"
        }
    ]
}

HTTP Request

GET /finance/transaction

This method does not require any request parameters.

Response body parameters

Response is an array of objects, each containing information about a specific transaction.

Get a specific transaction

Get information about a specific transaction by ID.

<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://gogetproxy.com/api/v1/finance/transaction/{transaction_id}');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);
curl_setopt($ch, CURLOPT_USERPWD, '{EMAIL}:{API_KEY}');
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
?>
curl --request GET \
--url 'https://gogetproxy.com/api/v1/finance/transaction/{transaction_id}' \
--user '{EMAIL}:{API_KEY}' \
--digest \
--location

Example response

{
    "result": true,
    "data": {
        "id": 327,
        "time": 1481283086,
        "type": "out",
        "amount": 8.1,
        "currency_code": "USD",
        "description": "Purchase of 15 proxy IP(s)"
    }
}

HTTP request

GET /finance/transaction/{transaction_id}

Path parameters

Parameter Description
transaction_id The unique id of the transaction.

Response body parameters

Parameter Type Description
id integer The unique ID of the transaction.
time integer The linux timestamp of the moment the transaction was processed.
type string The type of the transaction. Possible values are in and out.
amount float The amount of the transaction.
currency_code string Three letters code of the transaction currency (ISO 4217).
description string The description of the transaction.

Errors

All API methods can return any of the following general errors:

Code Description
0 Unknown error. Please, contact support.
1 Authentication required.
100 Incorrect request parameters.
110 Incorrect email and/or API key.
120 The resource with specified ID was not found.