SpotRates

Get spot FX price

Returns the current spot FX price containing bid, ask, and mid rates for the specified currency pair. The response includes state information (VALID/ERROR) and metadata about the price source. Prices are typically updated in real-time from market data providers.

get/api-regulated/v1/fx-spot-prices/{currencyPair}

Request

  • Base URL: https://api.currencyguard.com
  • URL: https://api.currencyguard.com/api-regulated/v1/fx-spot-prices/{currencyPair}
  • Auth: HTTP bearer

Path parameters

currencyPairstring required

Currency pair in 6-character format: 3-letter base currency code followed by 3-letter quote currency code (e.g., GBPUSD for British Pound vs US Dollar, EURUSD for Euro vs US Dollar). Case insensitive.

Response

Spot price retrieved successfully. Returns FXPriceStateDTO with current bid/ask/mid rates.

validboolean required

Whether the price data is currently valid (true) or in an error/degraded state (false). When false, the value may still be present (stale/approximate data).

errorMessagesstring[]

List of error messages explaining why the state is invalid. Empty/null when valid=true. Can contain multiple accumulated errors from different sources.

valueTimestampstring required

ISO 8601 timestamp indicating when the underlying data was produced at the source (business time). This represents the data's original timestamp.

emissionTimestampstring required

ISO 8601 timestamp indicating when our system emitted this state (system/processing time). This represents when the wrapper was created.

subscriptionSourcestring

Market data subscription channel identifier. Used for debugging and monitoring data flows.

emissionSourcestring

Identifier of the market data provider or internal pricing engine that produced this data. Diagnostic detail for internal use only — omitted from responses to non-internal callers.

infoMessagesstring[]

Informational messages providing context about the price state (e.g., validation details, reference source checks). Do not affect validity. Diagnostic detail for internal use only — omitted from responses to non-internal callers.

Example response

{
  "valid": true,
  "errorMessages": [
    "Market data feed delayed by 30 seconds",
    "Volatility surface is stale"
  ],
  "valueTimestamp": "2024-03-01T14:30:15.123Z",
  "emissionTimestamp": "2024-03-01T14:30:16.456Z",
  "subscriptionSource": "DEFAULT",
  "value": {
    "symbol": "GBPUSD",
    "timestamp": "2024-03-01T14:30:15.123Z",
    "bid": 1.09235,
    "ask": 1.09255,
    "mid": 1.09245
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.