Download OpenAPI specification:Download
BitGo provides a simple and robust RESTful API and client SDK to integrate digital currency wallets with your application. In Platform V2, we have extended our API and SDK to allow the management of multiple digital currencies and wallets through a single, unified interface.
The BitGo SDK enables the following:
This is the latest documentation for the BitGo APIs, and is generated from OpenAPI 3.0 schema. OpenAPI technology provides improved validation of client requests, and more consistency between the API documentation and server-side implementation of API endpoints.
Legacy users may also refer to the V1 Bitcoin API, which is still available today. There is no dependency for developers to integrate with V1 or read the legacy documentation in order to take advantage of the newer version of our API.
The primary advantage of multi-signature wallets is the ability for multiple machines and people to work together to approve a given transaction. Without multiple signatures on a transaction, all credentials to approve a transaction must reside with a single person on a machine. If that person or machine is compromised by an attacker, all funds can be taken with no recourse and no ability to audit the individual that invoked the key.
BitGo's multi-signature wallets allow you to keep control of your Bitcoin or other cryptocurrency despite introducing the concept of a co-signer. This allows enterprises to set up and maintain roles, policies, and rules on the wallet, making digital currency usable for businesses.
For more information, please read the BitGo Whitepaper.
All calls to endpoints that require authentication must pass the client access
token via the Authorization
HTTP header. The format of this header is
Authorization: Bearer <TOKEN>
. Here's an example that uses
HTTPie to call the
Get session API from the command line:
$ http -v get https://app.bitgo-test.com/api/v2/user/me Authorization:"Bearer $TEST_TOKEN"
GET /api/v2/user/me HTTP/1.1
Accept: */*
Accept-Encoding: gzip, deflate
Authorization: Bearer v2x83...
Connection: keep-alive
Host: app.bitgo-test.com
User-Agent: HTTPie/1.0.0
HTTP/1.1 200 OK
...
You can create an access token in the "Developer Options" tab of the web UI, under "User Settings." An access token can limit access in several ways:
BitGo's SDK and Express App secures tokens using our Auth V2 protocol, which does not send the access token over the wire. For this reason, we recommend that API requests from 3rd party clients should be proxied through BitGo Express.
The BitGo web APIs provide developers with the capability to create and manage multi-signature wallets, manipulate their policies and interact with multiple digital currencies over a single robust interface. Several sensitive operations, such as the creation of user private keys and signing of transactions, must to be performed client-side.
For this reason, we provide and recommend the use of our Software Development Kit (SDK), which implements these client-side wallet features and interfaces with our APIs.
Currently, our SDK is available in JavaScript and runs in either Node.js or a browser. If your application does not use native JavaScript, you may refer to the BitGo Express REST API guide, which offers the same feature set via a local server daemon.
Installing the JavaScript SDK (via npm)
npm install --save bitgo
To initialize your environment and authenticate, use the following code:
const BitGoJS = require('bitgo');
// Read the user authentication section to get your API access token
const bitgo = new BitGoJS.BitGo({ env: 'test', accessToken: process.env.ACCESS_TOKEN });
const coin = bitgo.coin('tbtc');
The BitGo Express REST API is a lightweight service for developers who want to use the BitGo service, but are developing in a language other than JavaScript.
BitGo Express runs as a service in your own data center, and handles the client-side operations involving your own keys, such as partially signing transactions before submitting them to BitGo. This ensures your keys never leave your network, and are never seen by BitGo. BitGo Express can also proxy the standard BitGo REST APIs, providing a unified interface to BitGo through a single REST API.
We recommend using Docker to run BitGo Express, and we also support running from the source code directly.
To try out BitGo Express, run this command:
docker run -it -p 3080:3080 bitgosdk/express:latest
You should see this output from BitGo Express:
BitGo-Express running
Environment: test
Base URI: http://0.0.0.0:3080
Now you can send a ping request to BitGo Express using curl to make sure the service is up and running:
$ curl localhost:3080/api/v2/ping
{"status":"service is ok!","environment":"BitGo Testnet","configEnv":"testnet","configVersion":79}
For more detailed information, please see the BitGo Express README.
BitGo has two separate environments available for development and production. For security reasons, all BitGo API requests are made using TLS over HTTPS.
The BitGo test environment is used by default in our examples and the SDK. It is entirely separate from BitGo's production environment and there is no overlap in either data or accounts. You will need to create accounts at app.bitgo-test.com.
In the test environment, you can use 0000000
in place of the OTP when authenticating.
This environment is connected to the TestNet networks of various digital currencies we support. Tokens on these networks can be obtained from faucets and do not represent real money.
The BitGo production endpoint is live and used by partners and our own web application on app.bitgo.com.
To use this environment, specify { env: 'prod' }
when using the SDK or -e prod
when running BitGo Express. SSL certifications should be provided to secure traffic to and from the BitGo Express instances when operating on the Production environment.
BitGo Platform V2 supports a variety of digital currencies, with more being added every quarter.
To select the coin or token:
var bitgo = new BitGoJS.BitGo({ env: 'test', accessToken: process.env.ACCESS_TOKEN });
var coin = bitgo.coin('btc');
(replace btc with your desired coin identifier)
Identifier | Digital Currency | Family | BitGo Environment | Release status |
---|---|---|---|---|
algo | Algorand | Account | Production | Enterprise access |
btc | Bitcoin | UTXO-based | Production | General availability |
bch | Bitcoin Cash | UTXO-based | Production | General availability |
btg | Bitcoin Gold | UTXO-based | Production | General availability |
celo | CELO | Account | Production | Enterprise access |
dash | Dash | UTXO-based | Production | General availability |
eth | Ethereum | Account | Production | Enterprise access |
ltc | Litecoin | UTXO-based | Production | General availability |
rmg | Royal Mint Gold | UTXO-based | Production | Enterprise access |
trx | TRON | Account | Production | General availability |
xlm | XLM | Account | Production | General availability |
xrp | XRP | Account | Production | Enterprise access |
zec | Zcash | UTXO-based | Production | General availability |
cusd | Celo USD ERC20 Token | Account | Production | Enterprise access |
ae | Aeternity ERC20 Token | Account | Production | Enterprise access |
aergo | Aergo ERC20 Token | Account | Production | Enterprise access |
1inch | 1inch Token ERC20 token | Account | Production | Enterprise access |
1up | Uptrennd Token ERC20 token | Account | Production | Enterprise access |
abt | ArcBlock ERC20 token | Account | Production | Enterprise access |
ace | Ace Token | Account | Production | Enterprise access |
acxt | Ac Exchange Token | Account | Production | Enterprise access |
agwd | AGARWOOD ERC20 token | Account | Production | Enterprise access |
aion | AION ERC20 token | Account | Production | Enterprise access |
alpha | Alpha Finance | Account | Production | Enterprise access |
amn | Amon ERC20 token | Account | Production | Enterprise access |
amo | AMO Token ERC20 token | Account | Production | Enterprise access |
amp | AMP Token ERC20 token | Account | Production | Enterprise access |
amon | AmonD ERC20 token | Account | Production | Enterprise access |
ampx | Amplify Exchange ERC20 token | Account | Production | Enterprise access |
ana | ANA ERC20 token | Account | Production | Enterprise access |
ant | Aragon ERC20 token | Account | Production | Enterprise access |
aoa | Aurora ERC20 Token | Account | Production | Enterprise access |
appc | AppCoins ERC20 token | Account | Production | Enterprise access |
aqt | Alpha Quark Token | Account | Production | Enterprise access |
arct | ArCoin US Treasury ERC20 token | Account | Production | Enterprise access |
ast | AirSwap ERC20 token | Account | Production | Enterprise access |
audio | Audio ERC20 token | Account | Production | Enterprise access |
audx | eToro Australian Dollar ERC20 token | Account | Production | Enterprise access |
aust | Wrapped Anchor UST token | Account | Production | Enterprise access |
axpr | aXpire ERC20 token | Account | Production | Enterprise access |
axs | Axie Infinity Shards ERC20 token | Account | Production | Enterprise access |
bal | Balancer ERC20 token | Account | Production | Enterprise access |
band | Band Protocol ERC20 token | Account | Production | Enterprise access |
basic | BASIC Token ERC20 token | Account | Production | Enterprise access |
bat | Basic Attention Token ERC20 token | Account | Production | Enterprise access |
bax | BABB ERC20 token | Account | Production | Enterprise access |
bbx | BBX ERC20 token | Account | Production | Enterprise access |
bcap | BCAP ERC20 token | Account | Production | Enterprise access |
bcc | Basiscoin Cash | Account | Production | Enterprise access |
bcio | Blockchain.io ERC20 Token | Account | Production | Enterprise access |
bepro | BetProtocol ERC20 token | Account | Production | Enterprise access |
bid | Blockbid ERC20 token | Account | Production | Enterprise access |
bidl | Blockbid Liquidity ERC20 token | Account | Production | Enterprise access |
bird | BirdCoin ERC20 token | Account | Production | Enterprise access |
bnk | Bankera ERC20 token | Account | Production | Enterprise access |
bnl | BitNational ERC20 token | Account | Production | Enterprise access |
bnt | Bancor ERC20 token | Account | Production | Enterprise access |
bnty | Bounty0x ERC20 token | Account | Production | Enterprise access |
box | ContentBox ERC20 Token | Account | Production | Enterprise access |
brz | Brazilian Digital Token ERC20 token | Account | Production | Enterprise access |
bsx | Bistox Exchange Token ERC20 token | Account | Production | Enterprise access |
btt | Blocktrade ERC20 token | Account | Production | Enterprise access |
btu | BTU Protocol ERC20 token | Account | Production | Enterprise access |
brd | Bread ERC20 token | Account | Production | Enterprise access |
busd | Binance USD ERC20 token | Account | Production | Enterprise access |
buy | Buying.com ERC20 token | Account | Production | Enterprise access |
c8p | C8 Plus ERC20 token | Account | Production | Enterprise access |
cadx | eToro Canadian Dollar ERC20 token | Account | Production | Enterprise access |
cag | Change ERC20 token | Account | Production | Enterprise access |
cbat | Compound BAT ERC20 token | Account | Production | Enterprise access |
cbc | CashBet Coin ERC20 token | Account | Production | Enterprise access |
cbrl | Crypto BRL ERC20 token | Account | Production | Enterprise access |
cct | Cyber Credit Token ERC20 token | Account | Production | Enterprise access |
cdag | CannDollar ERC20 token | Account | Production | Enterprise access |
cdai | Compound DAI ERC20 token | Account | Production | Enterprise access |
cdt | Blox ERC20 token | Account | Production | Enterprise access |
cel | Celsius ERC20 token | Account | Production | Enterprise access |
ceth | Compound Ether ERC20 token | Account | Production | Enterprise access |
chfx | eToro Swiss Frank ERC20 token | Account | Production | Enterprise access |
chsb | SwissBorg ERC20 token | Account | Production | Enterprise access |
cix100 | Cryptoindex 100 ERC20 token | Account | Production | Enterprise access |
cliq | DefiCliq 100 ERC20 token | Account | Production | Enterprise access |
cln | Colu Local Network ERC20 token | Account | Production | Enterprise access |
clt | CoinLoan ERC20 token | Account | Production | Enterprise access |
cnyx | eToro Chinese Yuan ERC20 token | Account | Production | Enterprise access |
comp | Compound Token ERC20 token | Account | Production | Enterprise access |
cover | Cover ERC20 token | Account | Production | Enterprise access |
cpay | Cryptopay ERC20 token | Account | Production | Enterprise access |
cplt | Coineru Platinum ERC20 token | Account | Production | Enterprise access |
cqx | Coinquista Coin ERC20 token | Account | Production | Enterprise access |
crdt | Crypto Daily Token ERC20 token | Account | Production | Enterprise access |
cre | CarryToken ERC20 token | Account | Production | Enterprise access |
cream | Cream ERC20 token | Account | Production | Enterprise access |
crep | Compound Augur ERC20 token | Account | Production | Enterprise access |
cro | Crypto.com Chain ERC20 token | Account | Production | Enterprise access |
crv | Curve DAO ERC20 token | Account | Production | Enterprise access |
crpt | Crypterium ERC20 token | Account | Production | Enterprise access |
crpt1 | CRPT ERC20 token | Account | Production | Enterprise access |
cslv | Coineru Silver ERC20 token | Account | Production | Enterprise access |
csp | Caspian Token ERC20 token | Account | Production | Enterprise access |
cusdc | Compound USDC ERC20 token | Account | Production | Enterprise access |
cvc | Civic ERC20 token | Account | Production | Enterprise access |
cwbtc | Compound WBTC ERC20 token | Account | Production | Enterprise access |
czrx | Compound ZRX ERC20 token | Account | Production | Enterprise access |
dai | Dai ERC20 token | Account | Production | Enterprise access |
data | Streamr DATACoin ERC20 token | Account | Production | Enterprise access |
dec | Dark Energy Crystals ERC20 token | Account | Production | Enterprise access |
dent | Dent ERC20 token | Account | Production | Enterprise access |
dep | Deap Coin ERC20 token | Account | Production | Enterprise access |
dfd | DeFiDollar DAO | Account | Production | Enterprise access |
dfi | DeFiChain | Account | Production | Enterprise access |
dgcl | Dgcl ERC20 token | Account | Production | Enterprise access |
dgd | DigixDAO ERC20 token | Account | Production | Enterprise access |
dgx | Digix ERC20 token | Account | Production | Enterprise access |
dmt | DMarket ERC20 token | Account | Production | Enterprise access |
drpu | DRP Utility ERC20 token | Account | Production | Enterprise access |
drv | Drive ERC20 Token | Account | Production | Enterprise access |
dx1u | Dx1u ERC20 token | Account |