SDKs & Code Examples
We provide example client implementations in popular programming languages to help you integrate with the Multihub API. These are reference implementations, not official SDK packages — you can adapt them to your needs or use them as-is.All SDKs wrap a single POST endpoint at
https://api.123hub.pro/public/api/multihub/v1 using SHA-512 request signing for authentication. There are no multiple REST endpoints to manage.Available Examples
Python
Client class using
requests and hashlibNode.js
Client class using
crypto and native fetchPHP
Client class using cURL and
hash('sha512', ...)Go
Client struct using
crypto/sha512 and net/httpHow It Works
Every API call follows the same pattern regardless of the programming language:Build the request body
Construct a JSON body containing
method (the operation), an optional service_id, and a params object.Sign the request
Serialize the body to a compact JSON string (no extra whitespace), append your secret key, and compute the SHA-512 hex digest.
Send the POST request
POST to
https://api.123hub.pro/public/api/multihub/v1 with headers X-Data-Application-Id (your application ID) and X-Data-Hash (the computed hash).Authentication
All requests require two headers:| Header | Type | Description |
|---|---|---|
X-Data-Application-Id | Integer | Your application ID |
X-Data-Hash | String | sha512(compactJsonBody + secretKey) hex digest |
Environment Variables
Store your credentials securely:API Methods
Method-based routing replaces traditional REST endpoints. You specify the operation in themethod field of the request body:
| Method | Description |
|---|---|
gateway.ping | Health check / connectivity test |
payment.in | Create a deposit (pay-in) |
payment.out | Create a withdrawal (payout) |
payment.status | Check payment status by identifiers |
balance.get | Retrieve account balances |
Request Format
Every request follows this structure:Response Envelope
Every response uses a consistent envelope:Success (HTTP 200)
Error (HTTP 400)
