Bitcoin RESTful API

We are opened to create new special API interfaces for you.
Please contact us via email: support@bitaps.com or skype:
Bitaps support

Overview

The Bitaps Bitcoin REST API uses HTTP methods and a RESTful endpoint structure. You have to format requests in JSON and the APIs return JSON-formatted responses. All requests over secure HTTPS protocol only.

 

To construct a REST call, combine:

The REST API endpoint URL: https://bitaps.com

Errors

Bitaps uses standard HTTP status codes when returning errors. Additionally, we provide details about errors in the body of the response in the following format:

{
  "error_code": {error code},
  "message": "{error description}",
  "details": "{additional details if available}"
}

HTTP status codes:

200 Request successfully executed
400 Bad request
401 Unauthorized request
402 Failed request
403 Forbidden
404 Resource was not found
50x Server error

Query example:

Execute

Conditions

Using Bitaps API is opened for everyone, no registration, no restrictions, no any keys. All application interfaces are opened to use.

Each customer have to observe and bear the law responsibility at the local, federal and global level, the legislation does not violate ethical principles and practices. We fully disclaim liability for the content and the work of connected resources to us. These resources are not controlled by us and our services opened for public use.

We will not share or disclose information about customers, because we do not have the registration of users and their data. All transactions are transparent and available for a detailed view in any Bitcoin explorer with complete node. Bitcoin blockchain database is distributed worldwide.

Architecture of Bitcoin blockchain network is not able to block, cancel, return or roll back transactions on the network.

Please refer to the Privacy policy page.

Fee

We take fee from two interfaces only:

Bitaps takes fixed commission for each processed payment 0.0002 BTC.

We not take fee from amounts less then 100000 Satoshi. All fees will be sent to 1TipsnxGEhPwNxhAwKouhHgTUnmmuYg9P.

 

 

Payments

Work with Redeem code

Create Redeem Code

Redeem code is like a Bitcoin wallet. You can receive payments to generated Redeem Code Address and transfer money by query.

Use Get query to create Redeem Code:

GET https://bitaps.com/api/create/redeemcode[?confirmations=1-10]

Parameters:

[confirmations] number of accepted confirmations (optional field, default 1)

Range from 1 up to 6.

Response:

As a response generated 3 values: receiving Address, Redeem Code and Invoice.

Address is a Bitcoin address to receive payments.

Invoice could be sent to customer and also used for payment form. Invoice is used to view payments and transactions.

Redeem Code is used to send Bitcoin whole or part of money from this code to any other Bitcoin addresses by query.

Response example:

{
  "address": "1CZgyfDsA5Bob2wVyTbCxSGXwSAEur4LYB",
  "redeem_code": "BTCvNqa8knrVkGyYmrfMTRtU77xrnPWiiH8n8accdEm9W1EHsRbCz",
  "invoice": "invPvfHny5QnffugyKgwYvUeXjCUgz4ywhxzANDcTHa7amWLKbjnb"
}
Store all three values and keep "redeem_code" in safe place ! Because it's an important code to control your money.
Please do not send amount less then 5000 Satoshi to redeem code, otherwise transaction miners fee will take almost full amount.

Query example:

Variables Required Experiment with a value
Confirmations

Number of accepted confirmations. Range 1-10, default 3.

Optional
   
Execute

Get Redeem Code info

Request:

POST https://bitaps.com/api/get/redeemcode/info

Parameters:

{redeemcode} Redeem Code

Response:

Function returns next fields: receiver address, current balance, pending balance(unconfirmed), paid out amount.

Response:

{
  "address": "{address}",
  "balance": {amount},
  "pending_balance": {amount},
  "paid_out": {amount}
}

Query example:

Variables Required Experiment with a value
Redeem Code

Your Redeem Code

Required
   
Execute

Sending Bitcoins from Redeem code

Redeem Code is like a Bitcoin wallet. Pay specified amount or transfer "All available" from balance to customers or spend money as you wish. Server response

return transfer transaction hash.

Use POST query to Redeem Code:

POST https://bitaps.com/api/use/redeemcode

Parameters:

{redeemcode} Redeem Code
{address} Bitcoin receiver address
{amount} "amount" or "All available". Amount in Satoshi. In case if amount = "All available", the remaining balance will be sent to specified address.
{fee_level} "high", "medium", "low" miner fee level, optional, default = "low"
{custom_fee} Custom fee Satoshi per byte. If choose it, fee_level will be ignored.

 

Response:

{
  "tx_hash": "{transaction hash}",
}

Query example:

Variables Required Experiment with a value
Redeem Code

Your Redeem Code

Required
Receiver address

Bitcoin address where confirmed payments will be transferred

Required
Amount

"amount" or "All available".
Amount in Satoshi. In case if amount = "All available", the remaining balance will be sent to specified address.

Required
   
Execute

Mass payment from Redeem code

With Redeem Code you can pay up to 250 receivers. Also you can addmessage to this transaction with maximum length 80 bytes. This function supplied with BIP 70 and BIP74.

Limits:

 

Use POST query to Redeem Code:

POST https://bitaps.com/api/use/redeemcode/list

Parameters:

{
  "redeemcode": {code},
  "data": {data},
  "fee_level": {fee_level},
  "payment_list":  [
    {"address": {address},
     "amount": {amount}},
    ... # up to 250 addresses
    ]
}

 

{redeemcode} Redeem Code
{address} Bitcoin receiver address
{amount} Amount in Satoshi
{data} OP_Return message in transaction, max length 80 bytes, optional field, default empty
{fee_level} "high", "medium", "low" miner fee level, optional field, default = "low"

 

Response:

{
  "tx_hash": "{transaction hash}",
}

Query example:

Variables Required Experiment with a value
Redeem Code

Your Redeem Code

Required
Receiver address 1

Bitcoin receiver address

Required
Amount 1

Amount in Satoshi

Required
Receiver address 2

Bitcoin receiver address

Optional
Amount 2

Amount in Satoshi

Optional
Receiver address 3

Bitcoin receiver address

Optional
Amount 3

Amount in Satoshi

Optional
Data

Transaction message (OP_Return)

Optional
   
Execute

Accept payments

Create payment address

Main task in processing bitcoin payments is generate and monitoring an unique address for each new user or invoice. Once payment received and confirmed, API server forward bitcoins to main merchant address, cold storage or exchange to foreign currency on markets. Bitaps takes fixed commission for each processed payment 0.0002 BTC. Bitaps fee will be sent to 1TipsnxGEhPwNxhAwKouhHgTUnmmuYg9P. Minimal amount for processing 30 000 Satoshi. You can use this interface for each order separately or as an constant Bitcoin address attached to customers account.

Create an address by type: Many payments at any amount.

Bitcoin merchant schema

Simple requests:

GET https://bitaps.com/api/create/payment/{payout_address}/{callback}[?confirmations=0-10&fee_level={high | medium | low}]

Parameters:

{payout_address} Merchant's Bitcoin address where confirmed payments will be transferred
{callback} Urlencoded callback URL
[confirmations] Number of accepted confirmations (optional field, default 3)
[fee_level] Network fee level (optional field, default low)

Response:

Query returns: Address, Payment Code and Invoice.
Address is a Bitcoin address to receive payments.
Payment Code is a private information and merchant should keep it in secret. This Code need for verification of callbacks.
Invoice could be sent to customer and also used for payment form.

Response example:

{
  "address": "14aT7ELki1pVWtryd5brMGqsFySWgjy8je",
  "payment_code": "PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu",
  "invoice": "invNfFnca2Vg49dDg77exiQmqrVKCMBWsBBrB95HNZGbAwqQpNY2b"
}

All three response parametrs you can find in our Block Explorer via search field or open as URL:

https://bitaps.com/14aT7ELki1pVWtryd5brMGqsFySWgjy8je

https://bitaps.com/PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu

Query example:

Variables Required Experiment with a value
Payout address

Your Bitcoin address where confirmed payments will be transferred

Required
Callback URL

Your website URL with specified receiver page and optional extra GET parametrs

Required
Confirmations

Number of accepted confirmations. Range 1-10, default 3.

Optional
Fee level

Network fee level (optional field, default low).

Optional
   
Execute

Create smartcontract - payment to recipients list

That interface works like a "Create payment address", but received payment will be paid to list of addresses and rules. Amount can be splitted up to 20 addresses by exact amount in Satoshi or by percent (quota). Each calculation is made of the remaining amount by cascade.

If one of the rules is needed more than the remaining amount, then this rule will be skipped and proceeds to the next on the list. For example If you want to transfer 100000000 (1 BTC) to address A and rest amount 100% to address B, but sender sent 50000000 (0.5 BTC). First rule will be skipped, because 0.5 BTC is less then 1BTC and this rule does not work. As a result - full amount will be transferred to address B.

We strongly recommend always add last rule to transfer 100%!

Be careful: In case you not specify last item in list with quota 100% rest amount will be added to transaction miner fee.

Bitaps take 0.0002 BTC processing fee one time and execute it firstly.

 

Examples of rules:

If you want to pay 50% to address A, 1 Bitcoin of rest amount to address B, 25% to address C and 100% of rest amount to address D, use next construction: [{"address":A,"quota":50}, {"address":B,"amount":100000000}, {"address":C,"quota":25}, {"address":D,"quota":100}].


Bitcoin smart contract

Request:

POST https://bitaps.com/api/create/payment/smartcontract/{callback}[?confirmations=0-10&fee_level={high | medium | low}]

GET parametrs:

{callback} Urlencoded callback URL
[confirmations] Number of accepted confirmations (optional field, default 3)
[fee_level] Miner fee level (optional field, default low)

POST parametrs:

{
  "type": "payment_list",
  "payment_list": [
    {"address": {address},
     "amount | quota": {amount} | {quota}},
    ... # up to 20 addresses
    ]
}

Response:

Query returns: Address, Payment Code and Invoice.
Address is a Bitcoin address to receive payments.
Payment Code is a private information and merchant should keep it in secret. This Code need for verification of callbacks.
Invoice could be sent to customer and also used for payment form.

 

Every transaction confirmation response doing callback to link as described in section Processing the callback.

Response example:

{
  "address": "14aT7ELki1pVWtryd5brMGqsFySWgjy8je",
  "payment_code": "PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu",
  "invoice": "invNfFnca2Vg49dDg77exiQmqrVKCMBWsBBrB95HNZGbAwqQpNY2b"
}

All three response parametrs you can find in our Block Explorer via search field or open as URL:

https://bitaps.com/14aT7ELki1pVWtryd5brMGqsFySWgjy8je

https://bitaps.com/PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu

Query example:

Variables Required Experiment with a value
Hot wallet

Bitcoin address where confirmed payments will be transferred

Required


Cold storage

Bitcoin address where confirmed payments will be transferred

Required


Payout address №3

Bitcoin address where confirmed payments will be transferred

Required


Callback URL

Your website URL with specified receiver page and optional extra GET parametrs

Required
Confirmations

Number of accepted confirmations. Range 1-10, default 3.

Optional
Fee level

Network fee level (optional field, default low).

Optional
   
Execute

Create smartcontract - Hot wallet

That interface works like a "Create payment address", but received payment will be separated to hot wallet and cold storage of bitcoins.

For example, you need quick pay in your project and supply hot wallet balance for fast payout. Remained amount will be transferred to treasure, cold storage or trade account.

Hot wallet balance regulated by quota or specified amount. Quota is a percent between hot and cold wallets balances. We check balances on both wallets and distribute payment with same proportion.

Bitaps take 0.0002 BTC processing fee one time and execute it firstly.

Bitcoin smart contract

Example 1

Your smrartcontract supply hot wallet balance 10 BTC, rest amount will be transferred to cold storage.

Currently Hot wallet have 5 BTC only.
Customer sent 3 BTC.
As a result, all these money will be transafered to Hot wallet, becausse 5+3 less then required 10 BTC.

 

Example 2

Same situation, but customer sending 7 BTC.
Smartcontract will distribute 5 BTC up to 10 BTC to Hot wallet, and will transfer remained 2 BTC to cold storage.

 

Example 3

Smart contract have to supply Hot wallet balance 10 BTC.

Currently Hot wallet is full and have 10 BTC balance.

Customer send 8 BTC.
Smartcontract will check Hot wallet balance and will transfer all 8 BTC to cold storage.

 

Request:

POST https://bitaps.com/api/create/payment/smartcontract/{callback}[?confirmations=0-10&fee_level={high | medium | low}]

GET parametrs:

{callback} Urlencoded callback URL
[confirmations] Number of accepted confirmations (optional field, default 3)
[fee_level] Miner fee level (optional field, default low)

POST parametrs:

{
  "type": "hot_wallet",
  "hot_wallet": {address_1},
  "cold_storage": {address_2},
  "hot_wallet_quota | hot_wallet_amount": {quota} | {amount}
}

Response:

Query returns: Address, Payment Code and Invoice.
Address is a Bitcoin address to receive payments.
Payment Code is a private information and merchant should keep it in secret. This Code need for verification of callbacks.
Invoice could be sent to customer and also used for payment form.

 

Every transaction confirmation response doing callback to link as described in section Processing the callback.

Response example:

{
  "address": "14aT7ELki1pVWtryd5brMGqsFySWgjy8je",
  "payment_code": "PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu",
  "invoice": "invNfFnca2Vg49dDg77exiQmqrVKCMBWsBBrB95HNZGbAwqQpNY2b"
}

All three response parametrs you can find in our Block Explorer via search field or open as URL:

https://bitaps.com/14aT7ELki1pVWtryd5brMGqsFySWgjy8je

https://bitaps.com/PMTvvdRdFBPvY1KrDeRxSuwr4nDcMVBenbX2rB2zRYHBHbGRYK5Lu

Query example:

Variables Required Experiment with a value
Hot wallet

Bitcoin address where confirmed payments will be transferred

Required


Quota or amount

Choose quota or specified amount for hot wallet

Required


Cold storage

Bitcoin address where confirmed payments will be transferred

Required


Callback URL

Your website URL with specified receiver page and optional extra GET parametrs

Required
Confirmations

Number of accepted confirmations. Range 1-10, default 3.

Optional
Fee level

Network fee level (optional field, default low).

Optional
   
Execute

Processing the callback

When a payment is received, Bitaps REST API will notify your's specified callback URL. In order to acknowledge successful processing of the callback, your server should respond with invoice number inside response body.

Our service starts doing callbacks from zero confirmation (unconfirmed transaction in network) before got Invoice in response from merchant.

If you choose 3 confirmations on payment interface, you will get 0-1-2-3 (totally four times) confirmations.

In case server response incorrect or server not answering, call back will be resent again for every new block within 3 days.

Callbacks with not expected response may be blocked from the service.

Bitcoin payment callback
POST your_callback_url

Call back sent POST variables (not JSON):

  tx_hash={transaction hash}
  address={address}
  invoice={invoice}
  code={payment code}
  amount={amount} # Satoshi
  confirmations={confirmations}
  payout_tx_hash={transaction hash} # payout transaction hash
  payout_miner_fee={amount}
  payout_service_fee={amount}

Callback handler example:

Blockchain ledger API

Blocks

Get block

Request

GET https://bitaps.com/api/block/{block_height | block_hash}

Parameters:

{block_height | block_hash}block height or block hash

Response:

{
  "height": {block height},
  "hash": {"block hash"},
  "previous_block_hash": {"block hash"},
  "next_block_hash": {"block hash"},
  "merkleroot": {"merkleroot"},
  "coinbase": {"coinbase message hex"},
  "miner": {"miner name"},
  "timestamp": {timestamp},
  "version": {version},
  "transactions": {count},
  "size": {size in bytes},
  "bits": {bits},
  "nonce": {nonce}
}

Query example:

Variables Required Experiment with a value
Block height or Block hash

Number of block or hash of block in blockchain network.

Required
   
Execute

Get latest block

Request

GET https://bitaps.com/api/block/latest

Response:

{
  "height": {block height},
  "hash": {"block hash"},
  "previous_block_hash": {"block hash"},
  "next_block_hash": {"block hash"},
  "merkleroot": {"merkleroot"},
  "coinbase": {"coinbase message hex"},
  "miner": {"miner name"},
  "timestamp": {timestamp},
  "version": {version},
  "transactions": {count},
  "size": {size in bytes},
  "bits": {bits},
  "nonce": {nonce}
}

Query example:

Execute

Get block transactions

Request

GET https://bitaps.com/api/block/transactions/{block_height | block_hash}

Parameters:

{block_height | block_hash}block height or block hash

Response:

[
  ["{transaction}", "{block_data_hex} | null", {amount}],
  ...
]

Query example:

Variables Required Experiment with a value
Block height or Block hash

Number of block or hash of block in blockchain network.

Required
   
Execute

Transactions

Get transaction info

GET https://bitaps.com/api/transaction/{tx_hash}

Parameters:

{tx_hash}transaction hash

Response:

{
  "hash": "{transaction hash}",
  "data": "{transaction data hex}",
  "coinbase": {true | false},
  "block": {block_height} | null,
  "version": {version},
  "size": {size in bytes},
  "timestamp": {received timestamp},
  "inputs":
    [
      {
      "input_index": {input number},
      "sequence": {sequence},
      "hash": "{input transaction hash}",
      "out_index": {input transaction output index},
      "amount": {amount in Satoshi},
      "address": ["{address}",...],
      "script": null | {
        "type": "{output script type}",
        "hex": "{output script hex}",
        "asm": "{output script asm}",
        "pattern": "{output script pattern}",
        },
      "sig_script": {
        "type": "SIGSCRIPT",
        "hex": "{signature script hex}",
        "asm": "{signature script asm}",
        "pattern": "{signature script pattern}",
        },
      "reedem_script": null | {
        "type": "{redeem script hex}" | null,
        "hex": "{redeem script hex}" | null,
        "asm": "{redeem script hex}" | null,
        "pattern": "{redeem script hex}" | null,
        }
      },
      ...
    ]
  "outputs":
    [
      {
      "output_index": {output index},
      "amount": {output amount},
      "address": ["{address}",...],
      "script": {
        "type": "{script type}",
        "hex": "{script hex}",
        "asm": "{script asm}",
        "pattern": "{script pattern}",
        }
      },
      ...
    ]
}

Query example:

Variables Required Experiment with a value
tx_hash

Transaction hash

Required
   
Execute

Get raw transaction

Request

GET https://bitaps.com/api/raw/transaction/{tx_hash}

Parameters:

{tx_hash}transaction hash

Response:

{
  "hash": "{transaction hash}",
  "hex": "{raw transaction in hex representation}"
}

Query example:

Variables Required Experiment with a value
tx_hash

Transaction hash

Required
   
Execute

Addresses

Get address info

Request

GET https://bitaps.com/api/address/{address}

Parameters:

{address}address

Response:

{
  "balance":{balance},
  "confirmed_balance":{only confirmed balance},
  "received":{total amount received},
  "sent":{total amount sent},
  "pending":{pending amount},
  "multisig_received":{count},
  "multisig_sent":{count},
  "tx_received":{count},
  "tx_sent":{count},
  "tx_multisig_received":{count},
  "tx_multisig_sent":{count},
  "tx_unconfirmed":{count},
  "tx_invalid":{count}
}

Query example:

Variables Required Experiment with a value
address

Address compressed or uncompressed. Mainchain only.

Required
   
Execute

Get address transactions

Request:

GET https://bitaps.com/api/address/transactions/{address}[/{offset}[/{all | sent | received | multisig}[/{all | confirmed | unconfirmed | invalid }]]]

Parameters:

{address}address
{offset} optional, offset list, response records limit 100, default 0
{all | sent | received | multisig}optional, transactions type, default all
{all | confirmed | unconfirmed | invalid}optional, transactions status, default all

Response:

[
  [{timestamp}, "{hash}", "{data}", "{type}", "{status}", {confirmations}, {block}, {amount}],
  ...
]

Query example:

Variables Required Experiment with a value
address

Specified address

Required
offset

Offset list, response records limit 100.
Default: 0

Optional
transactions type

Variants: all, sent, received, multisig
Default: all

Optional
current transaction status

Variants: all, confirmed, unconfirmed, invalid.
Default: all

Optional
   
Execute

Blockchain network API

Network difficulty

Get current Bitcoin network difficulty request:

GET https://bitaps.com/api/difficulty

Response:

{
  "difficulty": {difficulty}
}

Query example:

Execute

Network hashrate

Get bitcoin network hashrate (last 24h) request:

GET https://bitaps.com/api/hashrate

Response:

{
  "hashrate": "{hashrate}"
}

Query example:

Execute

Average block time

Get bitcoin network average block time (last 24h) request:

GET https://bitaps.com/api/blocktime

Response:

{
  "blocktime": {average block time, seconds}
}

Query example:

Execute

Average block size

Get bitcoin network average block size (last 24h) request:

GET https://bitaps.com/api/blocksize

Response:

{
  "blocksize": {average block size, bytes}
}

Query example:

Execute

Transactions per second rate

Get bitcoin network transactions per second rate (last 24h) request:

GET https://bitaps.com/api/txrate

Response:

{
  "txrate": "{average transactions rate, tx per second}"
}

Query example:

Execute

Network transaction fee

Get bitcoin network fee priority, request:

Transaction fee is calculated by statistical analysis from the last 36 blocks. Satoshi per byte.

GET https://bitaps.com/api/fee

Response:

{
  "high": "{high priority}",
  "medium": "{medium priority}",
  "low": "{low priority}"
}

Query example:

Execute

Visual API

Graphical bitcoin clients should register themselves as the handler for the "bitcoin:" URI scheme by default, if no other handler is already registered. If there is already a registered handler, they MAY prompt the user to change it once when they first run the client.

This section is non-normative and does not cover all possible syntax. Please see the BNF grammar above for the normative syntax.

[foo] means optional, <bar> are placeholders

bitcoin:<address>[?amount=<amount>][?label=<label>][?message=<message>]

Characters must be URI encoded properly.

Examples

Just the address:

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W  

Address with name:

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W?label=Luke-Jr  

Request 20.30 BTC to "Luke-Jr":

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W?amount=20.3&label=Luke-Jr  

Request 50 BTC with message:

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W?amount=50&label=Luke-Jr&message=Donation%20for%20project%20xyz  

Some future version that has variables which are (currently) not understood and required and thus invalid:

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W?req-somethingyoudontunderstand=50&req-somethingelseyoudontget=999  

Some future version that has variables which are (currently) not understood but not required and thus valid:

 bitcoin:175tWpb8K1S7NmH4Zx6rewF9WQrcZv245W?somethingyoudontunderstand=50&somethingelseyoudontget=999  

 

QR code must be in black and white colors. If colors are different, then recognizing speed will be low or code will be unreadable.

QR code in SVG text format

Get QR code for message or address, request:

GET https://bitaps.com/api/qrcode/{message}

Parameters:

{message}urlencoded message, maximum 256 symbols

Response:

You will get SVG (vector graphics) text format in Base64.

{
  "message": "{message}",
  "qrcode": "{base64 encoded svg}"
}

Query example:

Variables Required Experiment with a value
QR code message

Use Bitcoin address or URL. Urlencoded message, maximum 256 symbols

Required
   
Execute

QR code image in PNG format

Get QR code for message or address, request:

GET https://bitaps.com/api/qrcode/{message}

Parameters:

{message}urlencoded message, maximum 256 symbols

Response:

As a result you will get PNG image that you can include into web page or save as image file for future.

Query example:

Variables Required Experiment with a value
QR code message

Use Bitcoin address or URL. Urlencoded message, maximum 256 symbols

 

Required
   
Execute

Market API

Exchange rate

Interface return current Bitcoin exchange rate by three main exchange markets: Bitstamp.net, Bitfinex.com, Coinbase.com or average of these rates in USD. Currencies: Euro, Russian Rubles and Chinese Yean are derived from the value of the Dollar by official Moscow Exchange (http://moex.com/).

Request:

GET https://bitaps.com/api/ticker[/{bitstamp | bitfinex | coinbase | average}]

Parameters:

{bitstamp | bitfinex | coinbase | average}optional, market name, default = average

Response:

{
  "usd": "{usd/btc rate}",
  "fx_rates":
  {
    "eur": "{eur/btc rate}",
    "rub": "{rub/btc rate}",
    "cny": "{cny/btc rate}",
  },
  "market": "{bitstamp | bitfinex | coinbase | average}",
  "timestamp": "{timestamp}"
}

Query example:

Variables Required Experiment with a value
exchange market

Variants: bitstamp, bitfinex, coinbase, average
Default: average

Optional
   
Execute

Exchange history

Get bitcoin history exchange rate request:

GET https://bitaps.com/api/price/history/{timstamp}/[{bitstamp | bitfinex | coinbase | average}]

Parameters:

{timestamp} Unix timestamp
{bitstamp | bitfinex | coinbase | average} optional, market name, default = average

Response:

{
  "usd": "{usd/btc rate}",
  "fx_rates":,
  {
    "eur": "{eur/btc rate}",
    "rub": "{rub/btc rate}",
    "cny": "{cny/btc rate}",
  },
  "market": "{bitstamp | bitfinex | coinbase | average}",
  "timestamp": "{timestamp}"
}

Query example:

Variables Required Experiment with a value
timestamp

Unix timestamp

Required
exchange market

Variants: bitstamp, bitfinex, coinbase, average
Default: average

Optional
   
Execute

© 2016 All rights reserved. Bitaps