# Overview

The PlainProxies API v2 provides programmatic access to manage proxy services, sub-users, subscriptions, and billing.

#### Key Features

* **Sub-User Management**: Create, update, and manage proxy credentials for datacenter, residential, ISP, and IPv6 proxies
* **Proxy Generation**: Generate rotating or sticky session proxy credentials with geo-targeting
* **Unlimited Residential**: Purchase and manage unlimited bandwidth residential proxy plans
* **Billing & Invoices**: View invoices, subscriptions, and payment history
* **Activity Logs**: Track all API and account activities
* **Webhooks**: Configure webhook endpoints to receive real-time notifications for proxy settings request changes

#### Authentication

All API requests require authentication via the `X-API-KEY` header. You can find your API key in the [Dashboard Settings](https://dashboard.plainproxies.com/account/api-keys).

#### Rate Limits

* **Standard endpoints**: 60 requests/minute
* **Write operations**: 30 requests/minute
* **Expensive operations** (proxy generation, purchases): 10 requests/minute

Rate limit headers are included in all responses:

* `X-RateLimit-Limit`: Maximum requests allowed
* `X-RateLimit-Remaining`: Requests remaining in current window
* `X-RateLimit-Reset`: Unix timestamp when the limit resets

#### Response Format

All responses follow a consistent JSON structure:

```json
{
  "success": true,
  "data": { ... },
  "message": "Optional message",
  "meta": { "pagination info if applicable" }
}
```

#### Error Handling

Errors return a structured response with an error code:

```json
{
  "success": false,
  "error": {
    "code": "ERROR_CODE",
    "message": "Human-readable message",
    "details": { "additional context if available" }
  }
}
```

#### Common Error Codes

| Code                   | HTTP Status | Description                             |
| ---------------------- | ----------- | --------------------------------------- |
| `API_KEY_MISSING`      | 401         | No API key provided in X-API-KEY header |
| `INVALID_API_KEY`      | 401         | API key is invalid or revoked           |
| `ACCOUNT_SUSPENDED`    | 403         | User account has been suspended         |
| `INSUFFICIENT_BALANCE` | 402         | Not enough balance for the operation    |
| `VALIDATION_ERROR`     | 422         | Request validation failed               |
| `NOT_FOUND`            | 404         | Requested resource does not exist       |
| `RATE_LIMITED`         | 429         | Too many requests                       |

#### Environments

| Environment    | Base URL                                    | Description                                     |
| -------------- | ------------------------------------------- | ----------------------------------------------- |
| **Production** | `https://dashboard.plainproxies.com/api/v2` | Live environment with real proxy infrastructure |
| **Sandbox**    | `https://plainproxies-sandbox.com/api/v2`   | Testing environment for integration development |

Use the server selector above to switch between environments.

#### Sandbox

The sandbox environment is a fully functional replica of the production API, designed for resellers and developers to test their integrations without affecting real services or incurring charges.

**Sandbox features:**

* Full API parity with production — all endpoints behave identically
* Separate accounts and API keys — register at [plainproxies-sandbox.com](https://plainproxies-sandbox.com)
* Proxy operations (creation, generation, settings) work end-to-end but use simulated infrastructure
* Purchases and billing use test data — no real charges

**Getting started with sandbox:**

1. Create an account at [plainproxies-sandbox.com](https://plainproxies-sandbox.com)
2. Generate your sandbox API key from the dashboard
3. Point your integration to `https://plainproxies-sandbox.com/api/v2`
4. Use the same endpoints and request format as production

> **Note:** Sandbox API keys are not valid in production, and vice versa.

#### Changelog

* **v2.0.0** (2024): Initial v2 release with improved structure and OpenAPI documentation


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.plainproxies.com/resller-api-documentation/overview.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
