### Pixmove API: Demo Game Endpoint Source: https://integrate.pixmove.com/index Details the GET /game/demo endpoint for obtaining a link to open a game in an iFrame. It outlines required parameters like partnerId, gameId, language, returnUrl, and hash, along with response parameters such as gameUrl. Includes request/response examples and potential error messages. ```APIDOC Url: https:// /game/demo Request type: GET Request parameters: Name | Type | Description ---|---|--- partnerId | integer | Unique partner identifier gameId | integer | Unique game identifier language* | string | Game localization language (en, ru, etc.) returnUrl* | string | Link for returning from the game back to the partner’s website hash | string | sha256 from string (“demo”+ partnerId + gameId + language + returnUrl + apiKey) Response parameters: Name | Type | Description ---|---|--- gameUrl | string | Link for opening the game in iFrame Request example: { partnerId: 1, gameId: 1, hash: '504b47948ff3efe5247b9e369502e9e20b19752eaf3c6eb7f7354e75b09c61ac' } Response example: { status: 'success', data: { gameUrl: '/pirate_dice/?token=rzcvPWua8zjMw2' } } Possible error messages: Message | Description ---|--- RequiredParamsNotFound | Incorrect number of parameters in the request InvalidParamType | Incorrect parameter type PartnerNotFound | Partner with such partnerId not found GameNotFound | Game with such gameId not found IncorrectHash | Incorrectly calculated hash ServerError | Server error ``` -------------------------------- ### Pixmove API: Game List Endpoint Source: https://integrate.pixmove.com/index Provides details for the GET /game/list endpoint, used to retrieve an up-to-date list of games. It specifies request parameters like partnerId and hash, and response parameters including game details such as id, title, class, and icon. Includes request and response examples and possible error messages. ```APIDOC Url: https:// /game/list Request type: GET Request parameters: Name | Type | Description ---|---|--- partnerId | integer | Unique partner identifier class* | string | Game class (instant, slot, table) hash | string | sha256 from string (“game_list” + partnerId + class + apiKey) Response parameters: Name | Type | Description ---|---|--- games | array | Array with games Game parameters in an array: id | integer | Unique game identifier title | string | Game’s name class | string | Game’s class (instant, slot, table) icon | string | Game icon URL Example of a request: { partnerId: 1, hash: 'f01729f278481b7934b9c859fdbf030195e924e2e17d99b925ec2bff4655dfc2' } Example of a response: { status: 'success', data: { games: [{ id: 1, title: 'Pirate dice', class: 'instant', icon: '.../icon/1.png' }] } } Possible error messages: Message | Description ---|--- RequiredParamsNotFound | Incorrect number of parameters in the request InvalidParamType | Incorrect type of parameter PartnerNotFound | Partner with such partnerId not found IncorrectHash | Incorrectly calculated hash ServerError | Sever error ``` -------------------------------- ### Get Demo Game Link Source: https://integrate.pixmove.com/ru Retrieves a link to open a game in an iframe. This request is made by the client. It requires partner and game IDs, language, return URL, and a hash for security. The response contains the game URL. ```APIDOC Endpoint: GET https:// /game/demo Request Parameters: - partnerId (integer): Unique identifier for the partner. - gameId (integer): Unique identifier for the game. - language (string, optional): Game localization language (e.g., en, ru). - returnUrl (string, optional): URL to return to the client's site after the game. - hash (string): SHA256 hash of the string "demo" + partnerId + gameId + language + returnUrl + apiKey. If optional parameters are not provided, they are excluded from the hash calculation (e.g., "demo" + partnerId + gameId + apiKey). Response Parameters: - gameUrl (string): The URL to open the game in an iframe. Error Messages: - RequiredParamsNotFound: Incorrect number of parameters in the request. - InvalidParamType: Incorrect parameter type. - PartnerNotFound: Partner with the specified partnerId not found. - GameNotFound: Game with the specified gameId not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { partnerId: 1, gameId: 1, hash: '504b47948ff3efe5247b9e369502e9e20b19752eaf3c6eb7f7354e75b09c61ac' } ``` -------------------------------- ### Initialize and Get Game Link Source: https://integrate.pixmove.com/ru Retrieves a link to open a game in an iframe. This request is made by the client. It requires currency, partner and game IDs, player ID, language, return URL, and a hash for security. The response contains the game URL. An optional sessionId can be provided. ```APIDOC Endpoint: GET https:// /game/init Request Parameters: - currency (string): The currency for the game (e.g., USD, EUR). - partnerId (integer): Unique identifier for the partner. - gameId (integer): Unique identifier for the game. - playerId (string): Unique identifier for the player in the client's system. - sessionId (string, optional): Unique identifier for the game session in the client's system. - language (string, optional): Game localization language (e.g., en, ru). - returnUrl (string, optional): URL to return to the client's site after the game. - hash (string): SHA256 hash of the string "game" + currency + partnerId + gameId + language + returnUrl + apiKey. If optional parameters are not provided, they are excluded from the hash calculation (e.g., "game" + currency + partnerId + gameId + playerId + apiKey). Response Parameters: - gameUrl (string): The URL to open the game in an iframe. Error Messages: - RequiredParamsNotFound: Incorrect number of parameters in the request. - InvalidParamType: Incorrect parameter type. - CurrencyNotFound: Currency with the specified code not found. - PartnerNotFound: Partner with the specified partnerId not found. - GameNotFound: Game with the specified gameId not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { currency: 'USD', partnerId: 1, gameId: 1, playerId: '132', sessionId: '123', hash: '5ac72c7cec4949fc3d268dee6bff0394c3378a3a0ed21727d5523d272638a430' } ``` -------------------------------- ### Get Game List API Source: https://integrate.pixmove.com/ru This API endpoint allows clients to retrieve a list of available games. It requires a partner ID and a hash generated from specific parameters. The response includes an array of game objects, each with an ID, title, class, and icon URL. ```APIDOC Url: https:// /game/list Тип запроса: GET Parameters: Название | Тип | Описание ---|---|--- partnerId | integer | Уникальный идентификатор партнера class* | string | Класс игры (instant, slot, table, fast) hash | string | sha256 от строки (“game_list” + partnerId + class + apiKey) *Необязательные поля: если они не передаются, то они не учитываются при расчете hash (“game_list” + partnerId + apiKey) Response Parameters: Название | Тип | Описание ---|---|--- games | array | Массив с играми Game Parameters in Array: Название | Тип | Описание ---|---|--- id | integer | Уникальный идентификатор игры title | string | Название игры class | string | Класс игры (instant, slot, table) icon | string | URL для иконки игры Example Request: { partnerId: 1, hash: 'f01729f278481b7934b9c859fdbf030195e924e2e17d99b925ec2bff4655dfc2' } _hash_ формируется из строки "game_list1test_key" Example Response: { status: 'success' data: { games: [{ id: 1, title: 'Pirate dice', class: 'instant', icon: '.../icon/1.png' }] } } Possible Error Messages: Сообщение | Описание ---|--- RequiredParamsNotFound | Некорректное количество параметров в запросе InvalidParamType | Некорректный тип параметра PartnerNotFound | Партнер с таким partnerId не найден IncorrectHash | Некорректно рассчитан hash ServerError | Ошибка сервера ``` -------------------------------- ### Get Player Balance Source: https://integrate.pixmove.com/ru Retrieves the current balance of a player. This request is handled by the provider. It requires player and session details, along with a calculated hash for security. ```APIDOC Endpoint: GET https:// /balance Parameters: - currency (string): The currency of the game (e.g., USD, EUR). - partnerId (integer): Unique identifier for the partner. - playerId (string): Unique identifier for the player. - sessionId (string, optional): Unique identifier for the game session. - hash (string): SHA256 hash of the security string. Response: - balance (string): The player's current balance. Error Messages: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Invalid parameter type. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { currency: 'USD', partnerId: 1, playerId: '432', sessionId: '123', hash: 'bafb050a6f04d30d6b684f024a5e38c97f8de84b7c957bbd357e6da867cf2f3c' } ``` -------------------------------- ### Generate HMAC-SHA256 Signature (Node.js) Source: https://integrate.pixmove.com/index Example code demonstrating how to generate a request signature using the HMAC-SHA256 algorithm in Node.js, as required for Pixmove API interactions. This involves concatenating request details and the API key before hashing. ```javascript const crypto = require('crypto'); const apiKey = 'test_key'; const result = 'bet10.00USD1432756212333test_key'; const cryptoHash = crypto.createHmac('sha256', apiKey); const hash = cryptoHash.update(result).digest('hex'); console.log(hash); ``` -------------------------------- ### Pixmove API General Information Source: https://integrate.pixmove.com/ru Provides general information about the Pixmove API, including transport protocol, HTTP methods, data format, and required headers. It also lists essential credentials provided after agreement. ```APIDOC Transport Protocol: HTTPS Methods: GET/POST Data Format: JSON Content-Type Header: application/json Credentials: - url: pixmove-games server URL () - partnerId: Unique partner identifier - apiKey: Secret key for hash generation ``` -------------------------------- ### Available Currencies List Source: https://integrate.pixmove.com/index This section details the mapping between currency IDs and their corresponding currency codes. It serves as a reference for understanding which currencies are supported and how they are represented in the system. ```APIDOC Currency: id: Integer Description: Unique identifier for the currency. code: String Description: ISO 4217 currency code (e.g., USD, EUR). Example: USD Available Currencies: USD: ID 1 UAH: ID 2 AZN: ID 3 TMT: ID 4 GEL: ID 5 KGS: ID 6 MDL: ID 7 KZT: ID 8 RUB: ID 9 EUR: ID 10 AMD: ID 11 TJS: ID 12 PRB: ID 13 GBP: ID 14 TRY: ID 15 MNT: ID 16 µBT: ID 17 COP: ID 18 mBT: ID 19 XAF: ID 20 XOF: ID 21 BRL: ID 22 CNY: ID 23 IRR: ID 24 CLP: ID 25 PEN: ID 26 ARS: ID 27 VEF: ID 28 MXN: ID 29 UYU: ID 30 HTG: ID 31 PLN: ID 32 CHF: ID 33 BGN: ID 34 CZK: ID 35 DKK: ID 36 HRK: ID 37 HUF: ID 38 SEK: ID 39 NOK: ID 40 RON: ID 41 RSD: ID 42 ALL: ID 43 BAM: ID 44 ISK: ID 45 MKD: ID 46 AUD: ID 47 NZD: ID 48 CAD: ID 49 BOB: ID 50 PYG: ID 51 UZS: ID 52 BDT: ID 53 VND: ID 54 KRW: ID 55 LTC: ID 56 DTC: ID 57 INR: ID 58 GMC: ID 59 ILS: ID 60 JPY: ID 61 MYR: ID 62 PHP: ID 63 SGD: ID 64 THB: ID 65 TWD: ID 66 NGN: ID 67 ETB: ID 68 EGP: ID 69 CDF: ID 70 ZAR: ID 71 TZS: ID 72 SDG: ID 73 KES: ID 74 DZD: ID 75 UGX: ID 76 MAD: ID 77 GHS: ID 78 MZN: ID 79 AOA: ID 80 AED: ID 81 HKD: ID 82 IDR: ID 83 MMK: ID 84 KWD: ID 85 SAR: ID 86 BYN: ID 87 TND: ID 88 OMR: ID 89 JOD: ID 90 BHD: ID 91 ZMW: ID 92 QAR: ID 93 ZWL: ID 94 DASH: ID 95 XMR: ID 96 IQD: ID 97 ZEC: ID 98 ETH: ID 99 GAME: ID 100 XEM: ID 101 PKR: ID 102 DMO: ID 103 RUR: ID 104 DOP: ID 105 BTC: ID 106 ``` -------------------------------- ### Obtaining a Game Link Source: https://integrate.pixmove.com/index This API endpoint allows partners to obtain a URL for launching a game within an iFrame. It requires game and player identification, along with security hashing. The response provides the game URL. ```APIDOC Endpoint: GET https:// /game/init Description: Allows obtaining a link for opening the game in iFrame. The request is executed by the partner. Request Parameters: - currency (string): The currency in which the game will be played (USD, EUR etc.). - partnerId (integer): Unique partner identifier. - gameId (integer): Unique game identifier. - playerId (string): Unique player identifier in the partner’s system. - sessionId (string, optional): Unique game session identifier in the partner’s system. If not passed, it is omitted when calculating the hash. - language (string, optional): Game localization language (en, ru, etc.). - returnUrl (string, optional): Link for returning from the game back to the partner’s website. - hash (string): sha256 from string (“game”+ partnerId + gameId + language + returnUrl + apiKey) or (“game” + currency + partnerId + gameId + playerId + apiKey) if optional fields are omitted. Response Parameters: - gameUrl (string): Link for opening the game in iFrame. Request Example: ```javascript { currency: 'USD', partnerId: 1, gameId: 1, playerId: '132', sessionId: '123', hash: '5ac72c7cec4949fc3d268dee6bff0394c3378a3a0ed21727d5523d272638a430' } ``` Hash String Example: `hash_string = 'gameUSD11132123test_key'` Response Example: ```javascript { status: 'success', data: { gameUrl: '\/pirate_dice/?token=rzcvPWua8zjMw2' } } ``` Possible Error Messages: - RequiredParamsNotFound: Incorrect number of parameters in the request. - InvalidParamType: Incorrect type of parameter. - CurrencyNotFound: Currency with such code not found. - PartnerNotFound: Partner with such partnerId not found. - GameNotFound: Game with such partnerId not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { currency: 'USD', partnerId: 1, gameId: 1, playerId: '132', sessionId: '123', hash: '5ac72c7cec4949fc3d268dee6bff0394c3378a3a0ed21727d5523d272638a430' } ``` -------------------------------- ### PixMove Player Bet API Source: https://integrate.pixmove.com/index Allows a player to place a bet. The request is executed by the provider. Requires parameters like amount, currency, partnerId, playerId, gameId, roundId, transactionId, and a calculated hash for security. ```APIDOC POST https:// /bet Request Parameters: - amount (string): Transaction amount - currency (string): The currency for the game (e.g., USD, EUR) - partnerId (integer): Unique partner identifier - playerId (string): Unique player identifier in the partner's system - gameId (integer): Unique identifier of the game - roundId (integer): Unique identifier of the betting round - sessionId (string, optional): Unique game session identifier in the partner's system - transactionId (integer): Unique identifier of the provider's betting transaction - hash (string): sha256 hash of specific parameters for security validation. Response Parameters: - balance (string): Player's current balance - transactionId (string): Unique identifier of the betting transaction in the partner's system. Possible Error Messages: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Incorrect parameter type. - PlayerLowBalance: Insufficient funds. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '10.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7665, transactionId: 35, sessionId: '123', hash: '433e73d9de350fdae70a85634de4eedb2923868ea09f8e35423b25ec2b0a3762' } ``` ```javascript { status: 'success', data: { balance: '10113.63', transactionId: '1333882828' } } ``` -------------------------------- ### Place Player Bet Source: https://integrate.pixmove.com/ru Allows a player to place a bet. This operation is performed by the provider and requires transaction details, game information, and a security hash. The response includes the updated player balance and a transaction ID. ```APIDOC Endpoint: POST https:// /bet Parameters: - amount (string): The transaction amount. - currency (string): The currency for the game (e.g., USD, EUR). - partnerId (integer): Unique identifier for the partner. - playerId (string): Unique identifier for the player. - gameId (integer): Unique identifier for the game. - roundId (integer): Unique identifier for the bet round. - sessionId (string, optional): Unique identifier for the game session. - transactionId (integer): Unique identifier for the provider's bet transaction. - hash (string): SHA256 hash of the security string. Response: - balance (string): The player's current balance. - transactionId (string): The client's transaction ID for the bet. Error Messages: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Invalid parameter type. - PlayerLowBalance: Insufficient player balance. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '10.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7665, transactionId: 35, sessionId: '123', hash: '433e73d9de350fdae70a85634de4eedb2923868ea09f8e35423b25ec2b0a3762' } ``` -------------------------------- ### Obtaining a Player's Balance Source: https://integrate.pixmove.com/index This API endpoint allows providers to retrieve a player's current balance for a specific currency. It requires partner and player identification, along with a security hash. The response includes the player's balance. ```APIDOC Endpoint: GET https:// /balance Description: Allows the provider to get the current player's balance. The request is executed by the provider. Request Parameters: - currency (string): Currency in which the game is played (USD, EUR etc.). - partnerId (integer): Unique partner identifier. - playerId (string): Unique player identifier in the partner’s system. - sessionId (string, optional): Unique game session identifier in the partner’s system. - hash (string): sha256 from string (“balance” + currency + partnerId + playerId + sessionId + apiKey) or (“balance” + currency + partnerId + playerId + apiKey) if optional fields are omitted. Response Parameters: - balance (string): Player's current balance. Request Example: ```javascript { currency: 'USD', partnerId: 1, playerId: '432', sessionId: '123', hash: 'bafb050a6f04d30d6b684f024a5e38c97f8de84b7c957bbd357e6da867cf2f3c' } ``` Response Example: ```javascript { status: 'success', data: { balance: '10103.63' } } ``` Possible Error Messages: - RequiredParamsNotFound: Incorrect number of parameters in the request. - InvalidParamType: Incorrect parameter type. - CurrencyNotFound: Currency with such code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { currency: 'USD', partnerId: 1, playerId: '432', sessionId: '123', hash: 'bafb050a6f04d30d6b684f024a5e38c97f8de84b7c957bbd357e6da867cf2f3c' } ``` -------------------------------- ### Pixmove Supported Currencies Source: https://integrate.pixmove.com/ru This section lists all the currency codes supported by the Pixmove platform. Each currency is associated with a unique ID. ```APIDOC Currency List: ID | Code ---|---- 1 | USD 2 | UAH 3 | AZN 4 | TMT 5 | GEL 6 | KGS 7 | MDL 8 | KZT 9 | RUB 10 | EUR 11 | AMD 12 | TJS 13 | PRB 14 | GBP 15 | TRY 16 | MNT 17 | µBT 18 | COP 19 | mBT 20 | XAF 21 | XOF 22 | BRL 23 | CNY 24 | IRR 25 | CLP 26 | PEN 27 | ARS 28 | VEF 29 | MXN 30 | UYU 31 | HTG 32 | PLN 33 | CHF 34 | BGN 35 | CZK 36 | DKK 37 | HRK 38 | HUF 39 | SEK 40 | NOK 41 | RON 42 | RSD 43 | ALL 44 | BAM 45 | ISK 46 | MKD 47 | AUD 48 | NZD 49 | CAD 50 | BOB 51 | PYG 52 | UZS 53 | BDT 54 | VND 55 | KRW 56 | LTC 57 | DTC 58 | INR 59 | GMC 60 | ILS 61 | JPY 62 | MYR 63 | PHP 64 | SGD 65 | THB 66 | TWD 67 | NGN 68 | ETB 69 | EGP 70 | CDF 71 | ZAR 72 | TZS 73 | SDG 74 | KES 75 | DZD 76 | UGX 77 | MAD 78 | GHS 79 | MZN 80 | AOA 81 | AED 82 | HKD 83 | IDR 84 | MMK 85 | KWD 86 | SAR 87 | BYN 88 | TND 89 | OMR 90 | JOD 91 | BHD 92 | ZMW 93 | QAR 94 | ZWL 95 | DASH 96 | XMR 97 | IQD 98 | ZEC 99 | ETH 100 | GAME 101 | XEM 102 | PKR 103 | DMO 104 | RUR 105 | DOP 106 | BTC ``` -------------------------------- ### Success and Error Response Formats Source: https://integrate.pixmove.com/ru Defines the JSON structures for successful and error responses from the Pixmove server. Successful responses include a 'data' object, while errors contain an 'error' object with a message and details. ```js { status: 'success', data: { field1: value1, field2: value2, ... fieldN: valueN } } ``` ```js { status: 'error', error: { message: 'ValueNotFound', details: { field1: value1, field2: value2, ... fieldN: valueN } } } ``` -------------------------------- ### Self-Validate Integration Source: https://integrate.pixmove.com/index Triggers various game scenarios to verify integration correctness. Returns a success or error status with detailed test case information. ```APIDOC POST https:// /test/self-validate Request Parameters: - partnerId (integer): Unique partner identifier - playerId (string): Unique player identifier in the partner's system - currency (string, optional): Currency for requests (defaults to USD) - gameId (integer, optional): Unique identifier of the game (defaults to 1) - sessionId (string, optional): Unique game session identifier in the partner's system - hash (string): sha256 hash for security verification. Response Parameters: - failedTests (array): Detailed data of failed tests. Note: A /bet request with transactionId: 999999999 is expected to return an error, allowing a /refund to be sent for testing purposes. ``` ```javascript { partnerId: 1, playerId: '1', hash: 'f01729f278481b7934b9c859fdbf030195e924e2e17d99b925ec2bff4655dfc2' } ``` -------------------------------- ### PixMove Player Winnings API Source: https://integrate.pixmove.com/index Allows crediting a player's winnings. The request is executed by the provider. Requires parameters like amount, currency, partnerId, playerId, gameId, roundId, betTransactionId, transactionId, and a calculated hash. ```APIDOC POST https:// /win Request Parameters: - amount (string): Transaction amount - currency (string): The currency for the game (e.g., USD, EUR) - partnerId (integer): Unique partner identifier - playerId (string): Unique player identifier in the partner's system - gameId (integer): Unique identifier of the game - roundId (integer): Unique identifier of the betting round - betTransactionId (string): Unique identifier of the betting transaction in the partner's system - sessionId (string, optional): Unique game session identifier in the partner's system - transactionId (integer): Unique identifier of the provider's winning transaction - hash (string): sha256 hash of specific parameters for security validation. Response Parameters: - balance (string): Player's current balance - transactionId (string): Unique identifier of the winning transaction in the partner's system. Possible Error Messages: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Incorrect parameter type. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '20.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7665, sessionId: '123', transactionId: 36, hash: 'd919a11d4cb1b0dc4cc0d5f880c6970fd160d434b3a779a66a9a7f6451d108fd' } ``` ```javascript { status: 'success', data: { balance: '10123.63', transactionId: '1333882829' } } ``` -------------------------------- ### Pixmove Self-Validation API Source: https://integrate.pixmove.com/ru This API endpoint allows partners to test the correctness of their integration with the Pixmove gaming platform. It simulates various game scenarios and returns a status indicating success or failure for each test case. A successful validation implies a correct integration. ```APIDOC Endpoint: POST https:// /test/self-validate Description: Validates the integration by running various game scenarios. Request Parameters: - partnerId (integer): Unique identifier for the partner. - playerId (string): Unique identifier for the player within the client system. - currency (string, optional): The currency for requests. Defaults to USD. - gameId (integer, optional): The unique identifier for the game. Defaults to 1. - sessionId (string, optional): The unique identifier for the game session within the client system. If not provided, it won't be passed in tests. - hash (string): SHA256 hash of the string "self_validate" + partnerId + playerId + currency + gameId + sessionId + apiKey. If optional parameters are omitted, they are not included in the hash calculation (e.g., "self_validate" + partnerId + playerId + apiKey). Response Parameters: - status (string): Overall status of the validation ('success' or 'error'). - data (object): - success (boolean): Indicates if all tests passed. - failedTests (array): An array containing details of tests that failed. - serverTime (integer): Server timestamp. - duration (integer): Duration of the request in milliseconds. Example Request: ```json { "partnerId": 1, "playerId": "1", "hash": "f01729f278481b7934b9c859fdbf030195e924e2e17d99b925ec2bff4655dfc2" } ``` Example Response: ```json { "status": "success", "data": { "success": true, "failedTests": [] }, "serverTime": 1748437219129, "duration": 334 } ``` Note: The API expects a '/bet' request with 'transactionId: 999999999' to return an error, allowing for a '/refund' to be sent for that bet. ``` -------------------------------- ### Refund Player Bet Source: https://integrate.pixmove.com/index Allows a partner to refund a player's bet. The request is executed by the provider. It requires transaction details and a security hash. ```APIDOC POST https:// /refund Request Parameters: - amount (string): Transaction amount - currency (string): The currency of the game (e.g., USD, EUR) - partnerId (integer): Unique partner identifier - playerId (string): Unique player identifier in the partner's system - gameId (integer): Unique identifier of the game - roundId (integer): Unique identifier of the betting round - betTransactionId (string): Unique identifier of the betting transaction in the partner's system - sessionId (string, optional): Unique game session identifier in the partner's system - transactionId (integer): Unique identifier of the provider's refund transaction - hash (string): sha256 hash for security verification. Response Parameters: - balance (string): Player's current balance - transactionId (string): Unique identifier of the refund transaction in the partner's system Possible Error Messages: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Incorrect parameter type. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '10.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7686, betTransactionId: '1333882828', sessionId: '123', transactionId: 37, hash: '3d304f5134260424a0777a91745565cf3e8b80226d0e1aa66bb0835ffe59839a' } ``` -------------------------------- ### Credit Player Win Source: https://integrate.pixmove.com/ru Allows crediting a player's win amount. This operation is performed by the provider. It requires transaction details, player information, and a security hash. ```APIDOC POST https:// /win Parameters: - amount (string): Transaction amount. - currency (string): Currency of the game (e.g., USD, EUR). - partnerId (integer): Unique partner identifier. - playerId (string): Unique player identifier. - gameId (integer): Unique game identifier. - roundId (integer): Unique bet round identifier. - betTransactionId (string): Unique bet transaction identifier. - sessionId (string): Unique game session identifier (optional). - transactionId (integer): Provider's win transaction identifier. - hash (string): SHA256 hash of the security string. Response: - balance (string): Player's current balance. - transactionId (string): Client's win transaction identifier. Error Codes: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Invalid parameter type. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '20.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7665, sessionId: '123', transactionId: 36, hash: 'd919a11d4cb1b0dc4cc0d5f880c6970fd160d434b3a779a66a9a7f6451d108fd' } ``` ```javascript { status: 'success', data: { balance: '10123.63', transactionId: '1333882829' } } ``` -------------------------------- ### API Response Data Formats Source: https://integrate.pixmove.com/index Defines the JSON structure for successful and error responses from the Pixmove API. Successful responses include a 'data' object, while errors contain an 'error' object with a 'message' and 'details'. ```javascript { status: 'success', data: { field1: value1, field2: value2, ... fieldN: valueN } } ``` ```javascript { status: 'error', error: { message: 'ValueNotFound', details: { field1: value1, field2: value2, ... fieldN: valueN } } } ``` -------------------------------- ### Refund Player Bet Source: https://integrate.pixmove.com/ru Allows refunding a player's bet amount. This operation is performed by the provider. It requires transaction details, player information, and a security hash. ```APIDOC POST https:// /refund Parameters: - amount (string): Transaction amount. - currency (string): Currency of the game (e.g., USD, EUR). - partnerId (integer): Unique partner identifier. - playerId (string): Unique player identifier. - gameId (integer): Unique game identifier. - roundId (integer): Unique bet round identifier. - betTransactionId (string): Unique bet transaction identifier. - sessionId (string): Unique game session identifier (optional). - transactionId (integer): Provider's refund transaction identifier. - hash (string): SHA256 hash of the security string. Response: - balance (string): Player's current balance. - transactionId (string): Client's refund transaction identifier. Error Codes: - RequiredParamsNotFound: Incorrect number of parameters. - InvalidParamType: Invalid parameter type. - CurrencyNotFound: Currency code not found. - IncorrectHash: Incorrectly calculated hash. - ServerError: Server error. ``` ```javascript { amount: '10.00', currency: 'USD', partnerId: 1, playerId: '432', gameId: 3, roundId: 7686, betTransactionId: '1333882828', sessionId: '123', transactionId: 37, hash: '3d304f5134260424a0777a91745565cf3e8b80226d0e1aa66bb0835ffe59839a' } ``` ```javascript { status: 'success', data: { balance: '10113.63', transactionId: '1333882830' } } ``` -------------------------------- ### Generate HMAC-SHA256 Signature (Node.js) Source: https://integrate.pixmove.com/ru This snippet demonstrates how to generate a HMAC-SHA256 hash for request signing using Node.js. It takes a result string and an API key to produce the signature. ```js const crypto = require('crypto'); const apiKey = 'test_key'; const result = 'bet10.00USD1432756212333test_key'; const cryptoHash = crypto.createHmac('sha256', apiKey); const hash = cryptoHash.update(result).digest('hex'); console.log(hash); ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.