Data API: Time
Table of Endpoints
Name | Method | Endpoint | Scope |
---|---|---|---|
Get Current Time | GET | /v2/time | N/A |
Get Current Time
Get the API server time.
This endpoint doesn't require authentication.
HTTP Request
GET https://api.coinbase.com/v2/time
Scopes
- No permission required
Examples
Request
- Shell
- Ruby
- Python
- JavaScript
curl https://api.coinbase.com/v2/time
require 'coinbase/wallet'
client = Coinbase::Wallet::Client.new(api_key: <api key>, api_secret: <api secret>)
time = client.time
from coinbase.wallet.client import Client
client = Client(<api_key>, <api_secret>)
time = client.get_time()
var Client = require('coinbase').Client;
var client = new Client({'apiKey': 'API KEY',
'apiSecret': 'API SECRET'});
client.getTime(function(err, time) {
console.log(time);
});
Response
{
"data": {
"iso": "2015-06-23T18:02:51Z",
"epoch": 1435082571
}
}