Portal (Obsoleted)

Connect your app. Easily buying and selling through our platform.

Portal is a new Satang Pro platform API where you can connect your application to us through your existing OAuth API and let your users and our users be connected. Your application user then could buy or sell through our exchange platform (now only buying cryptocurrency is supported) and get the crypto/fiat back to your application in seconds or up to minutes.

Please contact support@satang.com with the title "API Request: Portal OAuth Connect" in case you're interested to provide your platform OAuth API. We will whitelist and let your user be connectable to our exchange platform.

In order for Portal and your application to correctly work together, you will need to provide your OAuth API:

GET https://your-oauth-api-url/get-deposit-address?access_token=cf60766c0a3f4929a44985b7a3eb536a
&coin=BTC

200 OK
Content-Type: application/json
{
  "coin": "BTC",
  "address": "32ovuktGjD8CQs4e6G2nCkEGGrKvXQQgtf",
  "tag": null
}

We will use this API (access_token is your application OAuth access token, we will get this automatically after your user has logged in through your OAuth API, coin is an upper-cased standard cryptocurrency unit name) to get your user deposit address. If your path is not /get-deposit-address please provide us with the info in the contact above.

The returning JSON of the API should be obvious except for the tag field. This field is for the cryptocurrency with optional tag or memo, such as XRP or XLM. For example:

GET https://your-oauth-api-url/get-deposit-address?access_token=cf60766c0a3f4929a44985b7a3eb536a
&coin=XLM

200 OK
Content-Type: application/json
{
  "coin": "XLM",
  "address": "GDHISAMF43GJN3Q2F2WEOFASN4HHM5S435X4GQL62FBMZCY7IHWPEQ5X",
  "tag": "100"
}

Estimated Price

GET https://api.satang.pro/api/estimated-price/?pair&amount&side

Get current estimated price of the pair provided that you want to execute the order with the amount parameter. If side is buy, then the amount refers to the amount of fiat currency you want to pay, if side is sell then the amount refers to the amount of cryptocurrency you want to sell.

Query Parameters

{
  "price": "222239.50"
}

Create new Portal order

POST https://satangcorp.com/api/portal-orders/

Create a new Portal order. This order is an immediate-or-cancel order, meaning if it does not match immediately after execution, if will get cancelled. After the order is matched, the amount matched (minus standard trading and withdrawal fees) will be sent through your. If side is buy, then the amount refers to the amount of fiat currency you want to pay, if side is sell then the amount refers to the amount of cryptocurrency you want to sell.

Headers

Request Body

// The withdrawal is queued/sent to your application user deposit address.
{
  "value": "0.35", // amount matched.
  "withdrawal_status": "success"
}

// OR we can't withdraw to your application user deposit address
// due to the amount matched may be below our minimum withdrawal amount.
{
  "value": "0.00015", // amount matched.
  "withdrawal_status": "error",
  "withdrawal_error_code": "NOT_ENOUGH_FUNDS_TO_WITHDRAW",
  "withdrawal_error_message": "not enough funds to withdraw"
}

Last updated