JetSwap Merchant automatic interfaces allow to arrange an immediate transfer of JetSwap points and funds to the custom accounts of other members, completely freeing the process of human participation. This gives the opportunity to create a lot of sites with various formats, integrated with JetSwap Merchant service and accepting Jetswap points and funds. Gaming portals, JetSwap points exchange, online shops with multiply merchants and much more!
- Appointment of automated interfaces
Automatic API-interfaces is assigned to connect your web-site with our service and to enable the automatic performing of certain actions, related to our service. There are currently supported three interfaces: points transfer, funds transfer, balance audit. In conjunction with the payment processing service, this is quite sufficient for services such as automatic points market, auction for JetSwap points and money, all kinds of games portals, selling goods for points and money of JetSwap members etc.
- Îïèñàíèå íàñòðîéêè èíòåðôåéñîâ
Setting of automatic interfaces is performing on setup page separately for each interface.
Form settings can be obtained by clicking on the page of API-interface management or when adding new interface.
Settings form contains the following configuration options:
Option |
Required |
Description |
Interface name | Yes | Enter any interface name. This title is only a hint for you on the appointment of the interface and don't has any other mission.
|
Allowed IP-addresses | No | List of IP-addresses, from which is allowed using of the interface. IP-addresses separated by commas. For example: 1.1.1.1,2.2.2.2 If not specified, allowed to use interface with any IP-address.
|
Permitted actions | Yes | Check the checkbox of the actions that can perform this APi-interface. Must be checked at least one action.
|
Secret code | Yes | The code that is used to the formation of a control signature request (see below).
|
Enabled | No | Please tick to enable the interface. If not ticked, the interface can not be used.
|
- Automatic interfaces types
Currently supports three automatic interface: transfer points, transfer funds, balance audit. Once you've enabled automatic interfaces, you should write a program that will use this interface. You should place the site on a hosting that supports the execution of custom scripts. We recommend to use JetHosting.ru - script support is already included in the minimal tariff plan!
- Interface 1. Points transfer.
- Interface 2. Funds transfer.
To use the interface you need to create a request to the handler and send operation parameters You can get example php script in the interfaces list.
Action: http://go.jetswap.net/api
Method: POST
Fields, sending in the form:
Option |
Required |
Description |
PAY_INTERFACE | Yes | Interface, which is used for payment. It can take two values: - 1 - points transfer
- 2 - funds transfer
| PAY_API | Yes | API-interface ID, is displayed in interfaces list in the first column.
| PAY_TO | Yes | Jetswap username of the member, for which transfer is performing.
| PAY_SUMM | Yes | Transfer amount
| PAY_TIME | Yes | Time of the transaction in UNIX_TIMESTAMP format. May deviate from server time not more than 10 minutes (server time is Moscow).
| PAY_CODE | Yes | Electronic signature request (see below)
|
After processing the request, the server will respond:
Possible answer |
Description |
0 | The operation was successful
|
1 | PAY_API interface is disabled or do not exist
|
2 | Invalid PAY_CODE
|
3 | PAY_TIME does not meet the requirements
|
4 | Payee does not exist
|
5 | Variable PAY_INTERFACE is incorrect or missing
|
6 | The calling IP-address does not in the list of allowed
|
7 | Too small transfer amount
|
8 | Not enough funds for transaction
|
9 | Since the change of personal data 48 hours is not passed
|
10 | Transfer failed, phone verification needed.
|
Any other | Internal server error
|
Electronic signature of the request ( PAY_CODE Option)
To verify the authenticity of the request using an electronic signature, which is passed to the handler in variable PAY_CODE. It is formed using the md5 function:
PAY_CODE=md5("PAY_INTERFACE::PAY_USER::PAY_TIME::fnc::PAY_KEY")
where PAY_KEY - Automation code, obtained by activation of automatic interface configuration and other variables described above in this paragraph. The symbols "::" is not replaced and are separators of variables.
- Interface 3. Balance audit
To use the interface you need to create a request to the handler and send operation parameters You can get example php script in the interfaces list. This interface can be used no more than one time in five minutes!
Action: http://go.jetswap.net/api
Method: POST
Fields, transmitted in the form:
Option |
Required |
Description |
PAY_INTERFACE | Yes | Interface, which is used to check the balance. Must be set to 3
| PAY_API | Yes | API-interface, displayed in interfaces list in the first column.
| PAY_BALANCE | Yes | Type of the bill for balance
| PAY_TIME | Yes | Time of the transaction in UNIX_TIMESTAMP format. May deviate from server time not more than 10 minutes (server time is Moscow).
| PAY_CODE | Yes | Request Control signature (see below)
|
After processing the request, the server will respond:
Possible answer |
Description |
!Balance | The operation was successful, "Balance" will provide the requested amount of balance.
|
1 | PAY_API interface is disabled or do not exist
|
2 | Invalid PAY_CODE
|
3 | PAY_TIME does not meet the requirements
|
5 | Variable PAY_INTERFACE is incorrect or missing
|
6 | The calling IP-address does not in the list of allowed
|
11 | Less than 5 minutes since last interface run
|
12 | Variable PAY_BALANCE is incorrect or missing
|
Any other | Internal server error
|
Electronic signature of the request (PAY_CODE option)
To verify the authenticity of the request using an electronic signature, which is passed to the handler in variable PAY_CODE. It is formed using the md5 function:
PAY_CODE=md5("PAY_INTERFACE::PAY_USER::PAY_TIME::fnc::PAY_KEY")
where PAY_KEY - Automation code, obtained by activation of automatic interface configuration and other variables described above in this paragraph. The symbols "::" is not replaced and are separators of variables.
- Interface 4. Automatic account configuring
The interface is assigned to automatical creation and adding of new API-interfaces and acceptable payments websites, to account. It is advisable to use the installation programs for different scripts of casinos, e-exchangers, shops, etc. Simplifies the process of installing a user script, because those actions which are usually made by the screenshots and the like, now interface makes itself!
|