OKchanger API позволяет клиентам автоматически получать доступ к информации об имеющихся направлениях обмена, обменниках и платежных системах, размещенных в мониторинге. Данный функционал может быть использован для предоставления пользователям Вашего ресурса дополнительной возможности пополнения счета.
Для использования API Вам необходимо создать специальный ключ для API в настройках профиля Вашего счета OKchanger.
Перед использованием функций API необходимо создать ключ для API в настройках профиля (раздел Ключи API).
Важно! В целях безопасности Вы можете создавать несколько API ключей, и каждый ключ API может быть сконфигурирован таким образом, чтобы иметь доступ только к определенным функциям.
Для создания ключа API нажмите на соответствующую ссылку на странице Ключи API. На новой странице нужно будет указать ключ API и создать пароль. Кроме того, укажите функции, которые планируете использовать с помощью данного ключа API. Нажмите Сохранить для получения ID ключа API. Он отобразится в списке существующие ключи API под колонкой ID. Идентификатор данного ключа ID ключа API наряду с паролем пароль API ключа понядобятся позднее для вызова функций API.
Все функции API требуют специальной подписи, которая формируется из значений переменных, отправляемых к функции и сортируются по имени переменных в порядке возрастания + пароль API, разделенный двоеточиями (:).
Например, если функция вызывается со следующими параметрами:
Rating_Directions_From ( APIID = 21238, signature = ‘8bfea2057de0ddb965a8b4a7db877abf’, fromcurrencyname = ‘USD’, frompaysystemid = 10 )
В первую очередь, расположите все имена параметров функций в алфавитном порядке (Важно!):
Предполагая, что Ваш пароль для ключа API ‘AABBCC’ (в соответствии с настройками счета). После чего мы получаем md5 хэш следующей строки:
signature = md5 (‘21238:USD:10:AABBCC’)
Результат функции MD5 является:
signature = ‘8bfea2057de0ddb965a8b4a7db877abf’
Теперь, заполнив переменную signature вы готовы вызвать защищенную функцию Rating_Directions_From
как указано выше.
Для любых запросов API требуется аутентификация. Вы можете узнать больше об аутентификации в разделе выше (см. Механизм авторизации выше).
Все запросы должны быть отправлены по следующему URL адресу:
https://www.okchanger.ru/API/Rating_PaySystems?apiid=21238&signature=c0f99c53ed30b0365bc7f7888eb8db53
Где: Rating_PaySystems — имя вызываемой функции.
?apiid=21238&signature=c0f99c53ed30b0365bc7f7888eb8db53 — запрошенные параметры.
Параметры могут быть отправлены через POST или GET методы.
Пример ответа:
{ "ErrorMessage":" ... error message if occured ... ", "IsSuccess":"1", "Result":" ... some data ... " }
Название | Тип | Пример | Описание |
---|---|---|---|
ErrorMessage | String | API_Wrong_Hash | Error code |
IsSuccess | Boolean | true | Operation success |
Result | Array/Object | Result |
Наш API содержит предсказуемые ресурсо-ориентированные URL-адреса и использует коды ответов HTTP для указания ошибок API. Мы поддерживаем CORS (совместное использование ресурсов между разными источниками), что позволяет безопасно взаимодействовать с API из веб-приложения на стороне клиента. JSON возвращается на все запросы API, включая ошибки, хотя наши библиотеки API преобразовывают ответы на соответствующий язык конкретных объектов.
Список доступных функций API приведен ниже. Каждая из них используется для определенной цели.
Ниже мы разберем каждую функцию более подробно.
Эта функция предоставляет подробную информацию о платежных системах, участвующих в доступных направлениях обмена.
Параметры:
Название | Тип | Пример | Описание |
---|---|---|---|
APIID | Integer | 21238 | API Key ID |
signature | String | 8bfea2057de0ddb965a8b4a7db877abf | MD5 Request Signature |
Return value: Array of PaySystem Objects.
Пример ответа:
{ "ErrorMessage":null, "IsSuccess":true, "Result":[ { "ID":1, "Name":"Webmoney", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WEBMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WEBMONEY", "PopularityPercent":5.09, "Currencies":[ "WMB", "WME", "WMG", "WMR", "WMU", "WMX", "WMZ" ] }, { "ID":2, "Name":"Yandex", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/YANDEX.png", "InfoURL":"http://www.okchanger.ru/payment-systems/YANDEX", "PopularityPercent":1.77, "Currencies":[ "RUB" ] }, { "ID":3, "Name":"QIWI", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/QIWI.png", "InfoURL":"http://www.okchanger.ru/payment-systems/QIWI", "PopularityPercent":2.71, "Currencies":[ "KZT", "RUB", "USD" ] }, { "ID":4, "Name":"PayPal", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PAYPAL.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PAYPAL", "PopularityPercent":11.85, "Currencies":[ "EUR", "RUB", "USD" ] } ] }
Эта функция предоставляет список обменников с подробной информацией, основанный на указанной платежной системы.
Параметры:
Название | Тип | Пример | Описание |
---|---|---|---|
APIID | Integer | 21238 | API Key ID |
signature | String | 8bfea2057de0ddb965a8b4a7db877abf | MD5 Request Signature |
paySystemID | Integer | 64 | Payment system ID |
Return value: Array of Exchanger Objects.
Пример ответа:
{ "ErrorMessage":null, "IsSuccess":true, "Result":[ { "ID":1214, "Name":"v-obmen.com", "LogoURL":"http://www.okchanger.ru/exchangers/preview-file/1214", "DescriptionText":null, "ReserveUSD":30692.7500, "InfoURL":"http://www.okchanger.ru/exchangers/v-obmen-com", "PositiveVotes":0, "NegativeVotes":0, "PopularityPercent":1.37, "PaySystems":[ { "ID":1, "Name":"Webmoney", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WEBMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WEBMONEY", "PopularityPercent":5.09, "Currencies":[ "WMB", "WME", "WMG", "WMR", "WMU", "WMX", "WMZ" ] }, { "ID":2, "Name":"Yandex", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/YANDEX.png", "InfoURL":"http://www.okchanger.ru/payment-systems/YANDEX", "PopularityPercent":1.77, "Currencies":[ "RUB" ] }, { "ID":3, "Name":"QIWI", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/QIWI.png", "InfoURL":"http://www.okchanger.ru/payment-systems/QIWI", "PopularityPercent":2.71, "Currencies":[ "KZT", "RUB", "USD" ] }, { "ID":4, "Name":"PayPal", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PAYPAL.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PAYPAL", "PopularityPercent":11.85, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":5, "Name":"Perfect Money", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PERFECTMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PERFECTMONEY", "PopularityPercent":10.79, "Currencies":[ "BTC", "EUR", "USD" ] }, { "ID":6, "Name":"Skrill", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/SKRILL.png", "InfoURL":"http://www.okchanger.ru/payment-systems/SKRILL", "PopularityPercent":2.21, "Currencies":[ "EUR", "USD" ] }, { "ID":10, "Name":"OKPAY", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/OKPAY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/OKPAY", "PopularityPercent":48.74, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":12, "Name":"W1", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/W1.png", "InfoURL":"http://www.okchanger.ru/payment-systems/W1", "PopularityPercent":0.01, "Currencies":[ "RUB", "UAH", "USD" ] }, { "ID":19, "Name":"SolidTrust Pay", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/SOLIDTRUSTPAY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/SOLIDTRUSTPAY", "PopularityPercent":0.43, "Currencies":[ "USD" ] }, { "ID":20, "Name":"Payeer", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PAYEER.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PAYEER", "PopularityPercent":2.67, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":26, "Name":"Сбербанк", "PaySystemType":"OnlineBanking", "LogoURL":"http://www.okchanger.ru/assets/images/ps/SBERBANK.png", "InfoURL":"http://www.okchanger.ru/payment-systems/SBERBANK", "PopularityPercent":null, "Currencies":[ "KZT", "RUB" ] }, { "ID":27, "Name":"Альфа-Клик", "PaySystemType":"OnlineBanking", "LogoURL":"http://www.okchanger.ru/assets/images/ps/ALFA-CLICK.png", "InfoURL":"http://www.okchanger.ru/payment-systems/ALFA-CLICK", "PopularityPercent":null, "Currencies":[ "RUB", "USD" ] }, { "ID":32, "Name":"Тинькофф", "PaySystemType":"OnlineBanking", "LogoURL":"http://www.okchanger.ru/assets/images/ps/TINKOFF.png", "InfoURL":"http://www.okchanger.ru/payment-systems/TINKOFF", "PopularityPercent":null, "Currencies":[ "RUB" ] }, { "ID":36, "Name":"Приват", "PaySystemType":"OnlineBanking", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PRIVAT.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PRIVAT", "PopularityPercent":null, "Currencies":[ "UAH" ] }, { "ID":38, "Name":"Western Union", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WESTERN UNION.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WESTERN UNION", "PopularityPercent":null, "Currencies":[ "EUR", "USD" ] }, { "ID":39, "Name":"Moneygram", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/MONEYGRAM.png", "InfoURL":"http://www.okchanger.ru/payment-systems/MONEYGRAM", "PopularityPercent":null, "Currencies":[ "EUR", "USD" ] }, { "ID":40, "Name":"Contact", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/CONTACT.png", "InfoURL":"http://www.okchanger.ru/payment-systems/CONTACT", "PopularityPercent":null, "Currencies":[ "EUR", "GBP", "RUB", "USD" ] }, { "ID":41, "Name":"Золотая Корона", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/ZOLOTAYAKORONA.png", "InfoURL":"http://www.okchanger.ru/payment-systems/ZOLOTAYAKORONA", "PopularityPercent":null, "Currencies":[ "RUB", "USD" ] }, { "ID":42, "Name":"Cash", "PaySystemType":"Cash", "LogoURL":"http://www.okchanger.ru/assets/images/ps/CASH.png", "InfoURL":"http://www.okchanger.ru/payment-systems/CASH", "PopularityPercent":null, "Currencies":[ "EUR", "GBP", "INR", "KZT", "MYR", "RUB", "SGD", "UAH", "USD" ] }, { "ID":43, "Name":"Cryptocurrencies", "PaySystemType":"CryptoCurrencies", "LogoURL":"http://www.okchanger.ru/assets/images/ps/CRYPTOCURRENCIES.png", "InfoURL":"http://www.okchanger.ru/payment-systems/CRYPTOCURRENCIES", "PopularityPercent":null, "Currencies":[ "BTC", "DASH", "DOGE", "LTC" ] }, { "ID":49, "Name":"BTC-e", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/BTC-E.png", "InfoURL":"http://www.okchanger.ru/payment-systems/BTC-E", "PopularityPercent":1.91, "Currencies":[ "BTC", "EUR", "RUB", "USD" ] }, { "ID":57, "Name":"AdvCash", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/ADVCASH.png", "InfoURL":"http://www.okchanger.ru/payment-systems/ADVCASH", "PopularityPercent":0.91, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":64, "Name":"Neteller", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/NETELLER.png", "InfoURL":"http://www.okchanger.ru/payment-systems/NETELLER", "PopularityPercent":7.56, "Currencies":[ "EUR", "USD" ] } ] }, { "ID":1276, "Name":"CambioSaldo", "LogoURL":"http://www.okchanger.ru/exchangers/preview-file/1276", "DescriptionText":null, "ReserveUSD":3985.6367, "InfoURL":"http://www.okchanger.ru/exchangers/cambiosaldo", "PositiveVotes":0, "NegativeVotes":0, "PopularityPercent":1.96, "PaySystems":[ { "ID":4, "Name":"PayPal", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PAYPAL.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PAYPAL", "PopularityPercent":11.85, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":5, "Name":"Perfect Money", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/PERFECTMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/PERFECTMONEY", "PopularityPercent":10.79, "Currencies":[ "BTC", "EUR", "USD" ] }, { "ID":6, "Name":"Skrill", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/SKRILL.png", "InfoURL":"http://www.okchanger.ru/payment-systems/SKRILL", "PopularityPercent":2.21, "Currencies":[ "EUR", "USD" ] }, { "ID":10, "Name":"OKPAY", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/OKPAY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/OKPAY", "PopularityPercent":48.74, "Currencies":[ "EUR", "RUB", "USD" ] }, { "ID":38, "Name":"Western Union", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WESTERN UNION.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WESTERN UNION", "PopularityPercent":null, "Currencies":[ "EUR", "USD" ] }, { "ID":39, "Name":"Moneygram", "PaySystemType":"MoneyTransfer", "LogoURL":"http://www.okchanger.ru/assets/images/ps/MONEYGRAM.png", "InfoURL":"http://www.okchanger.ru/payment-systems/MONEYGRAM", "PopularityPercent":null, "Currencies":[ "EUR", "USD" ] }, { "ID":64, "Name":"Neteller", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/NETELLER.png", "InfoURL":"http://www.okchanger.ru/payment-systems/NETELLER", "PopularityPercent":7.56, "Currencies":[ "EUR", "USD" ] } ] } ] }
Эта функция предоставляет список обменников с обменными курсами на основе установленного направления обмена. Кроме того, рейтинг популярности для указанного направлении обмена среди пользователей OKchanger.
Параметры:
Название | Тип | Пример | Описание |
---|---|---|---|
APIID | Integer | 21238 | API Key ID |
signature | String | 8bfea2057de0ddb965a8b4a7db877abf | MD5 Request Signature |
fromPaySystemID | Integer | 10 | Payment system ID (from) |
fromCurrencyName | String | USD | Currency code (from) |
toPaySystemID | Integer | 10 | Payment system ID (to) |
toCurrencyName | String | EUR | Currency code (to) |
Return value: Array of ExchangersDirection Objects.
Пример ответа:
{ "ErrorMessage":null, "IsSuccess":true, "Result":[ { "ExchangerID":1197, "ExchangerName":"OK-Change", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1197", "DirectionRate":0.9040700000, "DirectionReserve":955.1900, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1197&from=OKUSD&to=OKEUR" }, { "ExchangerID":1239, "ExchangerName":"E-Money", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1239", "DirectionRate":0.8913768206, "DirectionReserve":114.0700, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1239&from=OKUSD&to=OKEUR" }, { "ExchangerID":1198, "ExchangerName":"F1Ex", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1198", "DirectionRate":0.9284700000, "DirectionReserve":29031.3200, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1198&from=OKUSD&to=OKEUR" }, { "ExchangerID":1281, "ExchangerName":"Changex.com", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1281", "DirectionRate":0.8910000000, "DirectionReserve":3061.4900, "MinFee":5.0000, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":8, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1281&from=OKUSD&to=OKEUR" }, { "ExchangerID":1254, "ExchangerName":"idealExchanger", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1254", "DirectionRate":0.9045830000, "DirectionReserve":850.0000, "MinFee":null, "ToFee":null, "FromFee":2.5000, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1254&from=OKUSD&to=OKEUR" }, { "ExchangerID":1217, "ExchangerName":"SuperChange.ru", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1217", "DirectionRate":0.8803591865, "DirectionReserve":73.8000, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1217&from=OKUSD&to=OKEUR" }, { "ExchangerID":1263, "ExchangerName":"Mobilexchange", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1263", "DirectionRate":0.9023804797, "DirectionReserve":1515.1600, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1263&from=OKUSD&to=OKEUR" }, { "ExchangerID":1208, "ExchangerName":"GOLDUX", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1208", "DirectionRate":0.9048320000, "DirectionReserve":850.0000, "MinFee":null, "ToFee":null, "FromFee":2.5000, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1208&from=OKUSD&to=OKEUR" }, { "ExchangerID":1499, "ExchangerName":"iGN Exchange", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1499", "DirectionRate":0.9140200000, "DirectionReserve":0.2100, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1499&from=OKUSD&to=OKEUR" } ] }
Эта функция предоставляет список доступных направлений обменна (обмен С) для заданной платежной системы.
Параметры:
Название | Тип | Пример | Описание |
---|---|---|---|
APIID | Integer | 21238 | API Key ID |
signature | String | 8bfea2057de0ddb965a8b4a7db877abf | MD5 Request Signature |
fromPaySystemID | Integer | 10 | Payment system ID (from) |
fromCurrencyName | String | USD | Currency code (from) |
Return value: Array of ExchangersDirectionInformation Objects.
Пример ответа:
{ "ErrorMessage":null, "IsSuccess":true, "Result":[ { "DirectionPaySystem":{ "ID":1, "Name":"Webmoney", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WEBMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WEBMONEY", "PopularityPercent":5.09, "Currencies":[ "WMB", "WME", "WMG", "WMR", "WMU", "WMX", "WMZ" ] }, "ExchangesByCurrency":[ { "DirectionCurrency":"WMZ", "DirectionPopularityPercent":1.0126582278481012658227848101, "Rates":[ { "PaySystemID":1, "CurrencyName":"WMZ", "ExchangerID":1209, "ExchangerName":"TechnoCashier", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1209", "DirectionRate":0.9701000000, "DirectionReserve":100000.0000, "MinFee":7.0000, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1209&from=OKUSD&to=WMZ" }, { "PaySystemID":1, "CurrencyName":"WMZ", "ExchangerID":1280, "ExchangerName":"XaltChange", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1280", "DirectionRate":0.9830000000, "DirectionReserve":14349.1200, "MinFee":4.4400, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1280&from=OKUSD&to=WMZ" } ] }, { "DirectionCurrency":"WMR", "DirectionPopularityPercent":0, "Rates":[ { "PaySystemID":1, "CurrencyName":"WMR", "ExchangerID":1280, "ExchangerName":"XaltChange", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1280", "DirectionRate":64.9462403274, "DirectionReserve":0.0100, "MinFee":4.4400, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1280&from=OKUSD&to=WMR" }, { "PaySystemID":1, "CurrencyName":"WMR", "ExchangerID":1214, "ExchangerName":"v-obmen.com", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1214", "DirectionRate":55.0000002475, "DirectionReserve":3121.0200, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1214&from=OKUSD&to=WMR" } ] } ] }, { "DirectionPaySystem":{ "ID":2, "Name":"Yandex", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/YANDEX.png", "InfoURL":"http://www.okchanger.ru/payment-systems/YANDEX", "PopularityPercent":1.77, "Currencies":[ "RUB" ] }, "ExchangesByCurrency":[ { "DirectionCurrency":"RUB", "DirectionPopularityPercent":0, "Rates":[ { "PaySystemID":2, "CurrencyName":"RUB", "ExchangerID":1334, "ExchangerName":"monetok.net", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1334", "DirectionRate":64.8522603898, "DirectionReserve":3447.8900, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1334&from=OKUSD&to=YAMRUB" }, { "PaySystemID":2, "CurrencyName":"RUB", "ExchangerID":1230, "ExchangerName":"ALFAcashier", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1230", "DirectionRate":61.2176400417, "DirectionReserve":404416.3000, "MinFee":1.0000, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1230&from=OKUSD&to=YAMRUB" } ] } ] } ] }
Эта функция предоставляет список доступных направлений обменна (обмен НА) для заданной платежной системы.
Параметры:
Название | Тип | Пример | Описание |
---|---|---|---|
APIID | Integer | 21238 | API Key ID |
signature | String | 8bfea2057de0ddb965a8b4a7db877abf | MD5 Request Signature |
toPaySystemID | Integer | 10 | Payment system ID (to) |
toCurrencyName | String | EUR | Currency code (to) |
Return value: Array of ExchangersDirectionInformation Objects.
Пример ответа:
{ "ErrorMessage":null, "IsSuccess":true, "Result":[ { "DirectionPaySystem":{ "ID":1, "Name":"Webmoney", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/WEBMONEY.png", "InfoURL":"http://www.okchanger.ru/payment-systems/WEBMONEY", "PopularityPercent":5.09, "Currencies":[ "WMB", "WME", "WMG", "WMR", "WMU", "WMX", "WMZ" ] }, "ExchangesByCurrency":[ { "DirectionCurrency":"WMZ", "DirectionPopularityPercent":1.0126582278481012658227848101, "Rates":[ { "PaySystemID":1, "CurrencyName":"WMZ", "ExchangerID":1209, "ExchangerName":"TechnoCashier", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1209", "DirectionRate":0.9701000000, "DirectionReserve":100000.0000, "MinFee":7.0000, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1209&from=OKUSD&to=WMZ" }, { "PaySystemID":1, "CurrencyName":"WMZ", "ExchangerID":1280, "ExchangerName":"XaltChange", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1280", "DirectionRate":0.9830000000, "DirectionReserve":14349.1200, "MinFee":4.4400, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1280&from=OKUSD&to=WMZ" } ] } ] }, { "DirectionPaySystem":{ "ID":2, "Name":"Yandex", "PaySystemType":"OnlinePaySystem", "LogoURL":"http://www.okchanger.ru/assets/images/ps/YANDEX.png", "InfoURL":"http://www.okchanger.ru/payment-systems/YANDEX", "PopularityPercent":1.77, "Currencies":[ "RUB" ] }, "ExchangesByCurrency":[ { "DirectionCurrency":"RUB", "DirectionPopularityPercent":0, "Rates":[ { "PaySystemID":2, "CurrencyName":"RUB", "ExchangerID":1334, "ExchangerName":"monetok.net", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1334", "DirectionRate":64.8522603898, "DirectionReserve":3447.8900, "MinFee":null, "ToFee":null, "FromFee":null, "IsManualExchange":true, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1334&from=OKUSD&to=YAMRUB" }, { "PaySystemID":2, "CurrencyName":"RUB", "ExchangerID":1230, "ExchangerName":"ALFAcashier", "ExchangerLogoURL":"http://www.okchanger.ru/exchangers/preview-file/1230", "DirectionRate":61.2176400417, "DirectionReserve":404416.3000, "MinFee":1.0000, "ToFee":null, "FromFee":null, "IsManualExchange":false, "ExchangerPositiveVotes":0, "ExchangerNegativeVotes":0, "ExchangeProcessURL":"http://www.okchanger.ru/away?sType=1&sId=1230&from=OKUSD&to=YAMRUB" } ] } ] } ] }
Код ошибки | Описание |
---|---|
API_Wrong_Hash |
Некорректная подпись запроса. Проверьте порядок параметров и числовой формат |
Parameter_Validation_Error |
Некорректный параметр (null, empty или negative) |
Название | Тип | Пример | Описание |
---|---|---|---|
ID | Integer | 10 | Payment system ID |
Name | String | "OKPAY", "Webmoney", etc. | Payment system name |
PaySystemType | String | OnlinePaySystem | Payment system type |
LogoURL | String | http://www.okchanger.ru/.../okpay.png | Payment system logo URL |
InfoURL | String | http://www.okchanger.ru/.../okpay | Payment system details URL |
PopularityPercent | Decimal | 54.99, 22.87 | Payment system popularity |
Currencies | Array(string Currency) | ["USD", "EUR", etc.] | ISO currency codes |
Название | Тип | Пример | Описание |
---|---|---|---|
ID | Integer | 10 | Exchanger ID |
Name | String | "CambioSaldo", "Magnetic Exchange", etc. | Exchanger name |
LogoURL | String | http://www.okchanger.ru/.../1198 | Exchanger logo URL |
DescriptionText | String | "Lorem ipsum dolor sit amet..." | Exchanger description |
ReserveUSD | Decimal | 1234.56, 789.10, etc. | Exchanger reserve in USD |
InfoURL | String | http://www.okchanger.ru/.../f1ex | Exchanger details URL |
PositiveVotes | Integer | 1, 10, 15, etc. | Number of positive exchanger reviews |
NegativeVotes | Integer | 1, 10, 15, etc. | Number of negative exchanger reviews |
PopularityPercent | Decimal | 2.18, 33.11, 15.00, etc. | Exchanger popularity |
PaySystems | Array(PaySystem) | Supported payment systems |
Название | Тип | Пример | Описание |
---|---|---|---|
ExchangerID | Integer | 10 | Exchanger ID |
ExchangerName | String | "F1ex", "OK-Change", etc. | Exchanger name |
ExchangerLogoURL | String | http://www.okchanger.ru/.../1197 | Payment system logo URL |
DirectionRate | Decimal | 0.9040900000 | Exchange rate for certain direction |
DirectionReserve | Decimal | 955.1800, etc. | Exchanger reserve in base currency |
MinFee | String | 5 USD | Minimal commission fee charged by the exchanger for the exchange of the given currency pair |
ToFee | String | 2 EUR | Extra commission fee that is added to the exchange rate and is deducted from the amount the exchanger transfers to the customer |
FromFee | String | 2.15 EUR | Extra commission fee that is added to the exchange rate and is deducted from the amount the customer transfers to the exchanger |
IsManualExchange | Boolean | true/false | Parameter is true for all non-automatic, non-instant exchange directions (for manual, operator-controlled, etc.). |
ExchangerPositiveVotes | Integer | 1, 10, 15, etc. | Number of positive exchanger reviews |
ExchangerNegativeVotes | Integer | 1, 10, 15, etc. | Number of negative exchanger reviews |
ExchangeProcessURL | String | http://www.okchanger.ru/away?sType=1&sId=1197&from=OKUSD&to=OKEUR | URL to perform exchange operation |
Название | Тип | Пример | Описание |
---|---|---|---|
DirectionPaySystem | PaySystem | Payment system information | |
ExchangesByCurrency | Array(ExchangeInformation) | Detailed information about exchange directions |
Название | Тип | Пример | Описание |
---|---|---|---|
DirectionCurrency | String | "USD", "EUR", etc. | Exchange direction currency code |
DirectionPopularityPercent | Decimal | 1.25, 18.90, etc. | Exchange direction popularity |
Rates | Array(Rate) | Existing rates |
Название | Тип | Пример | Описание |
---|---|---|---|
PaySystemID | Integer | 1, 10, 15, etc. | Payment system ID |
CurrencyName | String | "USD", "EUR", etc. | Currency ISO code |
ExchangerID | Integer | 10 | Exchanger ID |
ExchangerName | String | "F1ex", "OK-Change", etc. | Exchanger name |
ExchangerLogoURL | String | http://www.okchanger.ru/.../1197 | Payment system logo URL |
DirectionRate | Decimal | 0.9040900000 | Exchange rate for certain direction |
DirectionReserve | Decimal | 955.1800, etc. | Exchanger reserve in base currency |
MinFee | String | 5 USD | Minimal commission fee charged by the exchanger for the exchange of the given currency pair |
ToFee | String | 2 EUR | Extra commission fee that is added to the exchange rate and is deducted from the amount the exchanger transfers to the customer |
FromFee | String | 2.15 EUR | Extra commission fee that is added to the exchange rate and is deducted from the amount the customer transfers to the exchanger |
IsManualExchange | Boolean | true/false | Parameter is true for all non-automatic, non-instant exchange directions (for manual, operator-controlled, etc.). |
ExchangerPositiveVotes | Integer | 1, 10, 15, etc. | Number of positive exchanger reviews |
ExchangerNegativeVotes | Integer | 1, 10, 15, etc. | Number of negative exchanger reviews |
ExchangeProcessURL | String | http://www.okchanger.ru/away?sType=1&sId=1197&from=OKUSD&to=OKEUR | URL to perform exchange operation |
ID | Название | ID | Название | ID | Название |
---|---|---|---|---|---|
1 | Webmoney | 2 | ЮMoney (Яндекс) | 3 | QIWI |
4 | PayPal | 5 | Perfect Money | 6 | Skril |
7 | Payza | 8 | EasyPay | 13 | Paxum |
18 | Ukash | 19 | SolidTrust Pay | 20 | Payeer |
26 | Сбербанк | 27 | Альфа-Клик | 29 | ВТБ24 |
30 | Русский Стандарт | 31 | Авангард | 32 | Т-Банк |
34 | Открытие | 35 | Кукуруза | 36 | Приват |
38 | Western Union | 39 | Moneygram | 40 | Contact |
41 | Золотая Корона | 42 | Cash | 43 | Cryptocurrencies |
44 | Visa/Mastercard | 45 | Bank Wire | 46 | HalykBank |
47 | Казкоммерцбанк | 48 | Альянс Банк | 51 | Газпромбанк |
52 | Бинбанк | 55 | SEPA | 56 | Sofort |
57 | Volet (Advcash) | 59 | Unistream | 60 | PexPay |
61 | РНКБ | 64 | Neteller | 66 | Траст |
67 | Райффайзен | 69 | WebTransfer | 75 | ForteBank |
77 | PaySera | 78 | ПУМБ | 79 | AliPay |
80 | UnionPay | 82 | Paymer | 85 | Epay |
86 | Ощадбанк | 87 | Беларусбанк | 90 | Capitalist |
91 | Payoneer | 92 | PaySafeCard | 96 | Unicredit |
97 | Forward Bank | 99 | Уралсиб | 102 | Bank of China |
103 | Perfect Money Voucher | 104 | QIWI Voucher | 105 | Phone Balance |
124 | Revolut | 127 | Global24 | 128 | Элекснет |
130 | MonoBank | 131 | ПочтаБанк | 132 | Рокетбанк |
141 | УКРСИББАНК | 142 | РОССЕЛЬХОЗБАНК | 143 | Kaspi Bank |
168 | Мир (MIR) | 169 | Piastrix | 170 | Sberbank QR RUB |