Skip to main content

Introduction

Ginses API is fast and friendly crypto, commodity, and FX Currency Conversion JSON API, covering over 1800+ pairs/asset.

Requirements

We’ve made it easy to be up and running. All you need to do is to visit “My Account” and locate your token. If you don’t have one yet, please subscribe and get one immediately.

Getting Started

Get ready to connect to Ginses API using few coding lines of your favorite programming language.

Definitions

DefinitionDescription
API URLThe URL which all API request endpoints and URLs are based on.
Access TokenThe access key assigned to your account and used to authenticate with the API.
SymbolThe three-letter currency code or currency pair (e.g., EUR, EURUSD).
Base CurrencyThe currency to which exchange rates are relative to. (If 1 USD = X EUR, USD is the base currency)
Target CurrencyThe currency an amount is converted to. (If 1 USD = X EUR, EUR is the target currency)
Timestamp formatAll timestamps are unix/epoch timestamps (seconds that have passed since since January 1, 1970 UTC).

API URL

Ginses API comes with a single endpoint that enables you to query one or many currency codes or pairs, with readable parameters. Depending on your subscription plan, the endpoint will return real-time exchange rate data.

https://api.ginses.com/

Authentication (Token)

Your API token is a unique access key passed into the API URL’s token parameter to authenticate with the Ginses API. The following is an example of how to append the access token for authentication:

https://api.ginses.com/markets
    ?token=ACCESS_TOKEN

Available symbols (Pairs)

To get the complete list of a specific market (e.g., Forex, Crypto, etc.) available symbols/pairs, use the following endpoint. Replace the MARKET_NAME with the targeted market (e.g. crypto, fx, etc.)

https://api.ginses.com/markets
    ?token=ACCESS_TOKEN
    &market=MARKET_NAME

Tick data endpoint

/markets endpoint provides you the ability to query a base currency (e.g., EUR) or currency pair (e.g.,EURUSD).

Query with base asset or pair

Search symbol/s

GET https://api.ginses.com/markets
    ?token=ACCESS_TOKEN
    &search=SYMBOL

Response

[
 {
  "t":"2021-04-15T03:53:00.593Z",
  "tms":"1618458780086",
  "s":"EURUSD",
  "b":1.19864,
  "bd":0,
  "a":1.19867,
  "ad":1,
  "p":5
 }
]

Get exact symbol/s

GET https://api.ginses.com/markets
    ?token=ACCESS_TOKEN
    &symbol=SYMBOL

Response

{
  "t":"2021-04-15T03:53:00.593Z",
  "tms":"1618458780086",
  "s":"EURUSD",
  "b":1.19864,
  "bd":0,
  "a":1.19867,
  "ad":1,
  "p":5
}

JSON response structure

KeyDescription
tThe last update date/time of query result.
tmsThe last update timestamp of query result.
sAsset’s symbol or currency pair (e.g., EURUSD, AAPL, BTCUSD)
bThe bid price. It is also referring to the highest price a buyer will pay for a currency.
bdThe bid price direction. It is also referring to the color code of the displayed bid price (e.g., red/green).
aThe ask price. It is also referring to the lowest price a seller will accept for a currency.
adThe ask price direction. It is also referring to the color code of the displayed ask price (e.g., red/green).
pThe symbol’s price precision
vVolume
cDaily change
cpDaily change percentage
hDaily high
lDaily Low
mMarket (e.g., FX, Crypto, Future, etc.)
nFull symbol name (e.g., EURO / U.S. DOLLAR)
ucUSD conversion
mgMargin calculation (trading aggregation support)
mgbMargin calculation base pair position (trading aggregation support). e.g., BASE/USD => “0”

Historical data endpoint

You can get the historical data of any of the available symbols by adding the historical parameter.

Response

[
  [
    1620604800,
    58336.16,
    59603,
    57399.33,
    57960
  ],
  ...
]
GET https://api.ginses.com/markets
    ?token=ACCESS_TOKEN
    &symbol=SYMBOL
    &historical=true
    &limit=LIMIT // Optional (number of candles. Default to 2000)
    &offset=OFFSET // Optional (candles offset)
    &scale=SCALE // Optional (e.g., 1, 60, 1D, 1W, 1M), default to 1D
Historical Data Response JSON Structure
indexDescription
0Timestamp.
1Open.
2High.
3Low.
4Close.