Skip to content

Latest commit

 

History

History
135 lines (105 loc) · 3.69 KB

File metadata and controls

135 lines (105 loc) · 3.69 KB

Chainlink Fixer External Adapter

Version: 1.3.26

This adapter is for Fixer.io and supports the convert endpoint.

This document was generated automatically. Please see README Generator for more info.

Environment Variables

Required? Name Description Type Options Default
API_KEY string
API_ENDPOINT string https://data.fixer.io

Input Parameters

Required? Name Description Type Options Default
endpoint The endpoint to use string convert, forex, latest, price convert

Convert Endpoint

convert is the only supported name for this endpoint.

Input Params

Required? Name Aliases Description Type Options Default Depends On Not Valid With
base coin, from The symbol of the currency to query string
quote market, to The symbol of the currency to convert to string
amount The amount of base currency number 1

Example

Request:

{
  "id": "1",
  "data": {
    "base": "EUR",
    "quote": "USD"
  }
}

Response:

{
  "jobRunID": "1",
  "data": {
    "success": true,
    "query": {
      "from": "USD",
      "to": "EUR",
      "amount": 1
    },
    "info": {
      "timestamp": 1636390923,
      "rate": 0.862805
    },
    "date": "2021-11-08",
    "result": 0.862805
  },
  "result": 0.862805,
  "statusCode": 200,
  "providerStatusCode": 200
}

Latest Endpoint

Returns a batched price comparison from one currency to a list of other currencies.

Supported names for this endpoint are: forex, latest, price.

Input Params

Required? Name Aliases Description Type Options Default Depends On Not Valid With
base coin, from The symbol of the currency to query string
quote market, to The symbol of the currency to convert to string

Example

Request:

{
  "id": "1",
  "data": {
    "endpoint": "latest",
    "base": "EUR",
    "quote": "USD"
  }
}

Response:

{
  "jobRunID": "1",
  "data": {
    "success": true,
    "timestamp": 1646446742,
    "base": "EUR",
    "date": "2022-03-05",
    "rates": {
      "USD": 1.094769
    },
    "result": 1.094769
  },
  "result": 1.094769,
  "statusCode": 200,
  "debug": {
    "batchablePropertyPath": [
      {
        "name": "quote"
      }
    ]
  },
  "providerStatusCode": 200
}