API Documentation

Use our public API to access real-time Syrian Pound exchange rate data

Base URL

https://lirascope.syria-cloud.sy/api/v1
🆓

Free API Access

Public endpoints are freely accessible without any account or API key. Up to 300 requests/month per IP address.

Authentication

The API is public and does not require authentication for public endpoints

No AuthPublic Endpoints
  • /rates/*
  • /crypto/*
  • /gold/*
  • /pricing

300 requests/month per IP — completely free

API Key RequiredPrivate Endpoints
  • /client/*

Subscribe for higher limits and advanced features

Endpoints

Get Latest Rates

Retrieve the latest exchange rates from Central Bank and black market sources

GET/rates/latest

Query Parameters

currencies(Optional)

Comma-separated list of currencies (e.g., USD,EUR)

lang(Optional)

Language code (ar, en, de) - Default: ar

Example Request

curl "https://lirascope.syria-cloud.sy/api/v1/rates/latest?currencies=USD,EUR&lang=en"

Example Response

{
  "disclaimer": "...",
  "timestampUtc": "2026-01-29T02:00:00Z",
  "cbsRates": [
    {
      "currency": "USD",
      "buy": 110.00,
      "sell": 111.00,
      "mid": 110.50,
      "timestampUtc": "2026-01-29T01:59:47Z",
      "isManualOverride": false
    }
  ],
  "marketRates": [
    {
      "currency": "USD",
      "buy": 116.80,
      "sell": 117.50,
      "mid": 117.15,
      "timestampUtc": "2026-01-29T01:54:46Z",
      "isManualOverride": false
    },
    {
      "currency": "EUR",
      "buy": 138.40,
      "sell": 140.30,
      "mid": 139.35,
      "timestampUtc": "2026-01-29T01:54:46Z",
      "isManualOverride": false
    }
  ],
  "effectiveRates": [...]
}

Get USD-Based Rates

Retrieve the latest exchange rates with USD as the base currency

GET/rates/usd-based

Query Parameters

lang(Optional)

Language code (ar, en, de) - Default: ar

Example Request

curl "https://lirascope.syria-cloud.sy/api/v1/rates/usd-based?lang=en"

Example Response

{
  "disclaimer": "...",
  "base": "USD",
  "date": "2026-03-10",
  "timestampUtc": "2026-03-10T12:00:00Z",
  "rates": [
    { "currency": "AED", "buy": 3.6594, "sell": 3.6814, "mid": 3.6704 },
    { "currency": "CHF", "buy": 0.8798, "sell": 0.8851, "mid": 0.8824 },
    { "currency": "EGP", "buy": 49.721, "sell": 50.019, "mid": 49.870 },
    { "currency": "EUR", "buy": 0.9174, "sell": 0.9229, "mid": 0.9201 },
    { "currency": "GBP", "buy": 0.7820, "sell": 0.7867, "mid": 0.7843 },
    { "currency": "KWD", "buy": 0.3066, "sell": 0.3085, "mid": 0.3075 },
    { "currency": "SAR", "buy": 3.7477, "sell": 3.7702, "mid": 3.7590 },
    { "currency": "TRY", "buy": 43.945, "sell": 44.209, "mid": 44.077 }
  ]
}

Response Fields

baseBase currency (USD)
dateDate of the last rate update
rates[].currencyISO 4217 currency code (e.g. EUR, GBP)
rates[].midMid (reference) rate — 1 USD = X units
rates[].buyBuy rate derived from market data
rates[].sellSell rate derived from market data

Latest Crypto Prices

Get the latest cryptocurrency prices in USD with 24h change data.

GET/crypto/latest

Query Parameters

lang(Optional)

Response language (ar, en, de)

Example Request

curl "https://lirascope.syria-cloud.sy/api/v1/crypto/latest?lang=en"

Latest Gold Prices

Get the latest gold prices in USD with 24h change data.

GET/gold/latest

Query Parameters

lang(Optional)

Response language (ar, en, de)

Example Request

curl "https://lirascope.syria-cloud.sy/api/v1/gold/latest?lang=en"

Response Fields

disclaimerDisclaimer message (localized)
timestampUtcUTC Timestamp
cbsRatesCentral Bank rates
marketRatesMarket rates
effectiveRatesEffective rates (manual overrides or market)
currencyCurrency code
buyBuy rate
sellSell rate
midMid rate
timestampUtcUpdate time
isManualOverrideWhether it's a manual rate

Rate Limits

To protect the API from abuse, the following rate limits are applied to all public endpoints.

TierAuthMonthlyPer MinutePer Hour
Free (by IP)No Auth3005100
StarterAPI Key Required10,0001001,000
ProfessionalAPI Key Required500,00050020,000
EnterpriseAPI Key RequiredUnlimitedUnlimitedUnlimited

Upgrade to a paid plan for higher limits. View Plans

Rate Limit Headers

All API responses include rate limit information:

X-Rate-Limit-Limit: 5
X-Rate-Limit-Remaining: 3
X-Rate-Limit-Reset: 2026-02-04T10:15:00Z

HTTP 429 Response

When rate limit is exceeded:

{
  "error": "Rate limit exceeded. Please retry after 45 seconds.",
  "retryAfter": 45
}

Private API & Webhooks

The Private API lets you build integrations with signed webhook alerts for exchange rate conditions.

Private API Authentication

All /client/* endpoints require a public key and a private key sent in the request headers.

X-Api-KeyYour public key (lsp_pub_...)
X-Api-SecretYour private key (lsp_prv_...)

Example Request

curl -X GET https://lirascope.syria-cloud.sy/api/v1/client/me \
  -H "X-Api-Key: lsp_pub_a1b2c3..." \
  -H "X-Api-Secret: lsp_prv_d4e5f6..."

⚠️ The private key is shown only once at creation time. Save it immediately in a secure location.

Client Profile

View your account information and registered webhook count.

GET/client/me

Example Response

{
  "id": "3fa85f64-...",
  "name": "My Integration",
  "publicKey": "lsp_pub_a1b2c3...",
  "isActive": true,
  "createdUtc": "2026-03-08T00:00:00Z",
  "lastUsedUtc": "2026-03-08T12:00:00Z",
  "webhookCount": 2
}

Webhooks

Register URLs to receive automatic alerts when rate conditions are met.

GET/client/webhooksList all webhooks
POST/client/webhooksCreate a new webhook

Example Request

curl -X POST https://lirascope.syria-cloud.sy/api/v1/client/webhooks \
  -H "X-Api-Key: lsp_pub_a1b2c3..." \
  -H "X-Api-Secret: lsp_prv_d4e5f6..." \
  -H "Content-Type: application/json" \
  -d '{
    "webhookUrl": "https://my-server.com/hooks/rate-alert",
    "currency": "USD",
    "source": "MARKET",
    "alertType": 0,
    "thresholdValue": 15000.0,
    "label": "USD high alert"
  }'

Alert Types

0 — ABOVETrigger when rate ≥ threshold
1 — BELOWTrigger when rate ≤ threshold
2 — CHANGE_INCREASETrigger when rate increases by threshold %
3 — CHANGE_DECREASETrigger when rate decreases by threshold %
PUT/client/webhooks/{id}Update a webhook
DELETE/client/webhooks/{id}Delete a webhook

Webhook Payload

When an alert condition is met, LiraScope sends a POST request to your configured webhook URL.

Headers

Content-Type: application/json
X-LiraScope-Signature: sha256=<hex-digest>
X-LiraScope-Event: rate_alert

Example Response

{
  "event": "rate_alert",
  "currency": "USD",
  "source": "MARKET",
  "alertType": "ABOVE",
  "threshold": 15000.0,
  "currentRate": 15250.0,
  "previousRate": 14800.0,
  "label": "USD high alert",
  "webhookId": "7c9e6679-...",
  "timestampUtc": "2026-03-08T12:30:00Z"
}

Signature Verification

Verify the payload authenticity using HMAC-SHA256 with your public key as the secret.

// JavaScript / Node.js
const crypto = require('crypto');

function verifySignature(body, publicKey, signatureHeader) {
  const expected = crypto.createHmac('sha256', publicKey)
    .update(body).digest('hex');
  const received = signatureHeader.replace('sha256=', '');
  return crypto.timingSafeEqual(
    Buffer.from(expected), Buffer.from(received)
  );
}

Webhook Reliability

  • Webhooks that fail 10 consecutive times are automatically disabled.
  • Re-enable via the dashboard or the PUT /client/webhooks/{id} endpoint.
  • The lastDeliveryStatusCode and consecutiveFailures fields show delivery health.

Support

For support or to report issues, please contact info@omarino.de