OpenAPI Documentation
OpenAPI Documentation
Dynamic proxy workflow
A typical dynamic proxy integration includes purchasing traffic, creating a dynamic sub-account, selecting a region, and generating connection credentials.
sequenceDiagram
participant C as Caller
participant A as Open API
participant P as Proxy endpoint
C->>A: List dynamic traffic products
A-->>C: Return product codes and purchase rules
C->>A: Purchase dynamic traffic (request_no)
A-->>C: Return COMPLETED and traffic batch ID
C->>A: Create dynamic sub-account (request_no)
A-->>C: Return sub-account information
C->>A: List available regions
A-->>C: Return region codes
C->>A: Generate proxy connection credentials
A-->>C: Return host, port, username, and password
C->>P: Connect using the credentials
Integration steps
- Call List dynamic traffic products, then select a
product_codeand an allowed traffic specification. Tiered prices are accumulated according to the quantity covered by each tier. Query results are estimates only. - Optionally call Get wallet balance to confirm the available balance.
- Call Purchase dynamic traffic. The price is recalculated using the effective price at order time. This API completes synchronously and returns
COMPLETEDon success. - Call Create a dynamic sub-account. The available dynamic traffic balance must be greater than 0 before account creation.
- Call List dynamic proxy regions progressively by country, province/state, and city.
- Call Generate dynamic proxy credentials, then connect using the returned information.
During operation
- Monitor the total balance with Get dynamic traffic balance.
- View sub-account usage with Get daily dynamic traffic usage.
- View current active batches with List active traffic batches.
- Use the account-status API to pause or resume a dynamic sub-account.
Connection credentials are sensitive. Generate and use them only when establishing a proxy connection, and do not persist them in ordinary business logs.