Abstract API Exchange Rates API

Currency exchange rate operations

Documentation

Specifications

Schemas & Data

📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/email-reputation-breach-info-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/phone-intelligence-phone-country-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/ip-geolocation-currency-info-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/ip-intelligence-asn-info-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/company-enrichment-company-enrichment-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/exchange-rates-convert-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/public-holidays-holiday-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/timezones-convert-time-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/vat-validation-vat-calculate-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/iban-validation-iban-validation-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/image-processing-image-processing-response-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/json-schema/web-scraping-web-scraping-response-schema.json

Other Resources

🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/email-reputation-breach-info-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/phone-intelligence-phone-country-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/ip-geolocation-currency-info-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/ip-intelligence-asn-info-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/company-enrichment-company-enrichment-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/exchange-rates-convert-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/public-holidays-holiday-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/timezones-convert-time-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/vat-validation-vat-calculate-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/iban-validation-iban-validation-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/image-processing-image-processing-response-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/abstract-api/refs/heads/main/examples/web-scraping-web-scraping-response-example.json

OpenAPI Specification

abstract-api-exchange-rates-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Abstract API Avatars Exchange Rates API
  description: Create highly customizable avatar images using a person's name or initials. Supports color, font, and size customization for user profile images.
  version: 1.0.0
  contact:
    url: https://www.abstractapi.com/
  x-generated-from: documentation
servers:
- url: https://avatars.abstractapi.com/v1
  description: Avatars API v1
security:
- apiKey: []
tags:
- name: Exchange Rates
  description: Currency exchange rate operations
paths:
  /live:
    get:
      operationId: getLiveExchangeRates
      summary: Abstract API Get Live Exchange Rates
      description: Get the latest exchange rates for one or more target currencies relative to a base currency.
      tags:
      - Exchange Rates
      parameters:
      - name: api_key
        in: query
        required: true
        description: Your unique API key for the Exchange Rates API.
        schema:
          type: string
        example: abc123def456
      - name: base
        in: query
        required: true
        description: Base currency ISO 4217 code.
        schema:
          type: string
        example: USD
      - name: target
        in: query
        required: false
        description: Target currency or comma-separated list of currencies. Returns all if omitted.
        schema:
          type: string
        example: EUR,GBP,JPY
      responses:
        '200':
          description: Live exchange rates
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LiveRatesResponse'
              examples:
                getLiveExchangeRates200Example:
                  summary: Default getLiveExchangeRates 200 response
                  x-microcks-default: true
                  value:
                    base: USD
                    last_updated: 1713518400
                    exchange_rates:
                      EUR: 0.9234
                      GBP: 0.7891
                      JPY: 154.23
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /convert:
    get:
      operationId: convertCurrency
      summary: Abstract API Convert Currency
      description: Convert an amount from one currency to another using current exchange rates.
      tags:
      - Exchange Rates
      parameters:
      - name: api_key
        in: query
        required: true
        description: Your unique API key.
        schema:
          type: string
        example: abc123def456
      - name: base
        in: query
        required: true
        description: Source currency ISO 4217 code.
        schema:
          type: string
        example: USD
      - name: target
        in: query
        required: true
        description: Target currency ISO 4217 code.
        schema:
          type: string
        example: EUR
      - name: base_amount
        in: query
        required: true
        description: Amount to convert.
        schema:
          type: number
        example: 100
      responses:
        '200':
          description: Currency conversion result
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConvertResponse'
              examples:
                convertCurrency200Example:
                  summary: Default convertCurrency 200 response
                  x-microcks-default: true
                  value:
                    base_currency: USD
                    target_currency: EUR
                    base_amount: 100
                    converted_amount: 92.34
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /historical:
    get:
      operationId: getHistoricalExchangeRates
      summary: Abstract API Get Historical Exchange Rates
      description: Retrieve historical exchange rates for a specific date.
      tags:
      - Exchange Rates
      parameters:
      - name: api_key
        in: query
        required: true
        description: Your unique API key.
        schema:
          type: string
        example: abc123def456
      - name: base
        in: query
        required: true
        description: Base currency ISO 4217 code.
        schema:
          type: string
        example: USD
      - name: target
        in: query
        required: false
        description: Target currency or comma-separated list.
        schema:
          type: string
        example: EUR,GBP
      - name: date
        in: query
        required: true
        description: Date for historical rates in YYYY-MM-DD format.
        schema:
          type: string
          format: date
        example: '2026-01-01'
      responses:
        '200':
          description: Historical exchange rates
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HistoricalRatesResponse'
              examples:
                getHistoricalExchangeRates200Example:
                  summary: Default getHistoricalExchangeRates 200 response
                  x-microcks-default: true
                  value:
                    base: USD
                    date: '2026-01-01'
                    exchange_rates:
                      EUR: 0.9198
                      GBP: 0.7844
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    ErrorResponse:
      type: object
      properties:
        message:
          type: string
          example: The provided API key is invalid
        error:
          type: string
          example: invalid_api_key
    ConvertResponse:
      type: object
      properties:
        base_currency:
          type: string
          description: Source currency code
          example: USD
        target_currency:
          type: string
          description: Target currency code
          example: EUR
        base_amount:
          type: number
          description: Original amount
          example: 100
        converted_amount:
          type: number
          description: Converted amount
          example: 92.34
    HistoricalRatesResponse:
      type: object
      properties:
        base:
          type: string
          description: Base currency code
          example: USD
        date:
          type: string
          format: date
          description: Historical date queried
          example: '2026-01-01'
        exchange_rates:
          type: object
          description: Map of currency codes to historical exchange rates
          additionalProperties:
            type: number
    LiveRatesResponse:
      type: object
      properties:
        base:
          type: string
          description: Base currency code
          example: USD
        last_updated:
          type: integer
          description: Unix timestamp of last update
          example: 1713518400
        exchange_rates:
          type: object
          description: Map of currency codes to exchange rates
          additionalProperties:
            type: number
  securitySchemes:
    apiKey:
      type: apiKey
      in: query
      name: api_key