@apifreaks/openapi-specs 0.4.3 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +70 -41
- package/dist/index.js +70 -41
- package/dist/specs/commodity/commodity-fluctuation.yaml +1 -1
- package/dist/specs/commodity/commodity-prices.yaml +2 -20
- package/dist/specs/commodity/commodity-symbols.yaml +1 -1
- package/dist/specs/commodity/commodity-time-series.yaml +30 -5
- package/dist/specs/commodity/historical-commodity-prices.yaml +18 -6
- package/package.json +1 -1
- package/specs/commodity/commodity-fluctuation.json +1 -1
- package/specs/commodity/commodity-prices.json +2 -23
- package/specs/commodity/commodity-symbols.json +1 -1
- package/specs/commodity/commodity-time-series.json +39 -5
- package/specs/commodity/historical-commodity-prices.json +22 -6
package/dist/index.cjs
CHANGED
|
@@ -277,7 +277,7 @@ var commodity_fluctuation_default = {
|
|
|
277
277
|
info: {
|
|
278
278
|
title: "Commodity Fluctuation API ",
|
|
279
279
|
version: "2.0.0",
|
|
280
|
-
description: "
|
|
280
|
+
description: "Price change and percentage movement for one or more commodities over a custom date range, with no limit on range length. For monthly-updated commodities the range snaps to month boundaries. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.",
|
|
281
281
|
contact: {
|
|
282
282
|
name: "APIFreaks Support",
|
|
283
283
|
url: "https://apifreaks.com/contact",
|
|
@@ -713,7 +713,7 @@ var commodity_prices_default = {
|
|
|
713
713
|
info: {
|
|
714
714
|
title: "Live Commodity Prices API - Real Time Market Insights",
|
|
715
715
|
version: "2.0.0",
|
|
716
|
-
description: "
|
|
716
|
+
description: "Real-time prices for 245+ commodities in a single request, updated on a rolling ~10 minute cadence. Optionally convert prices into a target quote currency. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.",
|
|
717
717
|
contact: {
|
|
718
718
|
name: "APIFreaks Support",
|
|
719
719
|
url: "https://apifreaks.com/contact",
|
|
@@ -754,17 +754,6 @@ var commodity_prices_default = {
|
|
|
754
754
|
type: "string"
|
|
755
755
|
}
|
|
756
756
|
},
|
|
757
|
-
{
|
|
758
|
-
name: "updates",
|
|
759
|
-
in: "query",
|
|
760
|
-
required: true,
|
|
761
|
-
description: "Update frequency. Accepted values: `10m` (default), `1m`.",
|
|
762
|
-
schema: {
|
|
763
|
-
type: "string",
|
|
764
|
-
enum: ["10m", "1m"],
|
|
765
|
-
default: "10m"
|
|
766
|
-
}
|
|
767
|
-
},
|
|
768
757
|
{
|
|
769
758
|
name: "quote",
|
|
770
759
|
in: "query",
|
|
@@ -785,7 +774,7 @@ var commodity_prices_default = {
|
|
|
785
774
|
},
|
|
786
775
|
examples: {
|
|
787
776
|
success: {
|
|
788
|
-
summary: "Successful response
|
|
777
|
+
summary: "Successful response",
|
|
789
778
|
value: {
|
|
790
779
|
success: true,
|
|
791
780
|
timestamp: 1789375397,
|
|
@@ -907,16 +896,6 @@ var commodity_prices_default = {
|
|
|
907
896
|
status: 400,
|
|
908
897
|
timestamp: "2026-09-14T08:43:43.964Z"
|
|
909
898
|
}
|
|
910
|
-
},
|
|
911
|
-
invalidUpdates: {
|
|
912
|
-
summary: "updates is not 10m or 1m",
|
|
913
|
-
value: {
|
|
914
|
-
error: "Invalid Param Exception",
|
|
915
|
-
message: "please pass correct parameters",
|
|
916
|
-
path: "/v2.0/commodity/rates/latest",
|
|
917
|
-
status: 400,
|
|
918
|
-
timestamp: "2026-09-14T08:43:44.440Z"
|
|
919
|
-
}
|
|
920
899
|
}
|
|
921
900
|
}
|
|
922
901
|
}
|
|
@@ -1208,7 +1187,7 @@ var commodity_symbols_default = {
|
|
|
1208
1187
|
info: {
|
|
1209
1188
|
title: "Commodity Symbols API Reference",
|
|
1210
1189
|
version: "2.0.0",
|
|
1211
|
-
description: '
|
|
1190
|
+
description: 'Full catalog of 245+ supported commodities across Metals, Energy, Agriculture, Industrial, Raw Materials, Oils and Meals, Textiles, Meats, Poultry, and Livestock, with pricing currency, unit, and update interval per symbol. Deprecated symbols stay listed with `status: "inactive"` and a `deprecationDate`.',
|
|
1212
1191
|
contact: {
|
|
1213
1192
|
name: "APIFreaks Support",
|
|
1214
1193
|
url: "https://apifreaks.com/contact",
|
|
@@ -1495,7 +1474,7 @@ var commodity_time_series_default = {
|
|
|
1495
1474
|
info: {
|
|
1496
1475
|
title: "Commodities Time Series API",
|
|
1497
1476
|
version: "2.0.0",
|
|
1498
|
-
description: "
|
|
1477
|
+
description: "Daily OHLC history for one or more commodities over a date range of up to 365 days, indexed by date. Non-trading days are excluded. Monthly-updated commodities only have a closing price \u2014 `open`, `high`, and `low` come back as `0`. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.",
|
|
1499
1478
|
contact: {
|
|
1500
1479
|
name: "APIFreaks Support",
|
|
1501
1480
|
url: "https://apifreaks.com/contact",
|
|
@@ -1597,6 +1576,40 @@ var commodity_time_series_default = {
|
|
|
1597
1576
|
}
|
|
1598
1577
|
}
|
|
1599
1578
|
}
|
|
1579
|
+
},
|
|
1580
|
+
monthlyCommodity: {
|
|
1581
|
+
summary: "Monthly-updated commodity (open/high/low unavailable)",
|
|
1582
|
+
value: {
|
|
1583
|
+
success: true,
|
|
1584
|
+
startDate: "2025-01-01",
|
|
1585
|
+
endDate: "2025-03-01",
|
|
1586
|
+
rates: {
|
|
1587
|
+
"2025-01-01": {
|
|
1588
|
+
"NG-EU": {
|
|
1589
|
+
open: 0,
|
|
1590
|
+
high: 0,
|
|
1591
|
+
low: 0,
|
|
1592
|
+
close: 14.66
|
|
1593
|
+
}
|
|
1594
|
+
},
|
|
1595
|
+
"2025-02-01": {
|
|
1596
|
+
"NG-EU": {
|
|
1597
|
+
open: 0,
|
|
1598
|
+
high: 0,
|
|
1599
|
+
low: 0,
|
|
1600
|
+
close: 15.34
|
|
1601
|
+
}
|
|
1602
|
+
},
|
|
1603
|
+
"2025-03-01": {
|
|
1604
|
+
"NG-EU": {
|
|
1605
|
+
open: 0,
|
|
1606
|
+
high: 0,
|
|
1607
|
+
low: 0,
|
|
1608
|
+
close: 13.24
|
|
1609
|
+
}
|
|
1610
|
+
}
|
|
1611
|
+
}
|
|
1612
|
+
}
|
|
1600
1613
|
}
|
|
1601
1614
|
}
|
|
1602
1615
|
}
|
|
@@ -1865,23 +1878,23 @@ var commodity_time_series_default = {
|
|
|
1865
1878
|
},
|
|
1866
1879
|
CommodityOhlc: {
|
|
1867
1880
|
type: "object",
|
|
1868
|
-
description: "OHLC price data for a single commodity on a single trading day.",
|
|
1881
|
+
description: "OHLC price data for a single commodity on a single trading day. For monthly-updated commodities, only `close` is meaningful \u2014 `open`, `high`, and `low` are returned as `0`.",
|
|
1869
1882
|
required: ["open", "high", "low", "close"],
|
|
1870
1883
|
properties: {
|
|
1871
1884
|
open: {
|
|
1872
1885
|
type: "number",
|
|
1873
1886
|
format: "float",
|
|
1874
|
-
description: "Opening price on the given date."
|
|
1887
|
+
description: "Opening price on the given date. `0` for monthly-updated commodities."
|
|
1875
1888
|
},
|
|
1876
1889
|
high: {
|
|
1877
1890
|
type: "number",
|
|
1878
1891
|
format: "float",
|
|
1879
|
-
description: "Highest price on the given date."
|
|
1892
|
+
description: "Highest price on the given date. `0` for monthly-updated commodities."
|
|
1880
1893
|
},
|
|
1881
1894
|
low: {
|
|
1882
1895
|
type: "number",
|
|
1883
1896
|
format: "float",
|
|
1884
|
-
description: "Lowest price on the given date."
|
|
1897
|
+
description: "Lowest price on the given date. `0` for monthly-updated commodities."
|
|
1885
1898
|
},
|
|
1886
1899
|
close: {
|
|
1887
1900
|
type: "number",
|
|
@@ -1968,7 +1981,7 @@ var historical_commodity_prices_default = {
|
|
|
1968
1981
|
info: {
|
|
1969
1982
|
title: "Historical Commodity Prices, Delivered Simply.",
|
|
1970
1983
|
version: "2.0.0",
|
|
1971
|
-
description: "
|
|
1984
|
+
description: "OHLC price data for one or more commodities on a specific date, back to January 1990. Falls back to the nearest earlier rate if none exists for the exact date. Monthly-updated commodities only have a closing price \u2014 `open`, `high`, and `low` come back as `0`. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.",
|
|
1972
1985
|
contact: {
|
|
1973
1986
|
name: "APIFreaks Support",
|
|
1974
1987
|
url: "https://apifreaks.com/contact",
|
|
@@ -2050,6 +2063,22 @@ var historical_commodity_prices_default = {
|
|
|
2050
2063
|
}
|
|
2051
2064
|
}
|
|
2052
2065
|
}
|
|
2066
|
+
},
|
|
2067
|
+
monthlyCommodity: {
|
|
2068
|
+
summary: "Monthly-updated commodity (open/high/low unavailable)",
|
|
2069
|
+
value: {
|
|
2070
|
+
success: true,
|
|
2071
|
+
date: "2025-01-10",
|
|
2072
|
+
rates: {
|
|
2073
|
+
"NG-EU": {
|
|
2074
|
+
date: "2025-01-01",
|
|
2075
|
+
open: 0,
|
|
2076
|
+
high: 0,
|
|
2077
|
+
low: 0,
|
|
2078
|
+
close: 14.66
|
|
2079
|
+
}
|
|
2080
|
+
}
|
|
2081
|
+
}
|
|
2053
2082
|
}
|
|
2054
2083
|
}
|
|
2055
2084
|
}
|
|
@@ -2284,27 +2313,27 @@ var historical_commodity_prices_default = {
|
|
|
2284
2313
|
},
|
|
2285
2314
|
HistoricalCommodityRate: {
|
|
2286
2315
|
type: "object",
|
|
2287
|
-
description: "OHLC price data for a single commodity on a specific date.",
|
|
2316
|
+
description: "OHLC price data for a single commodity on a specific date. For monthly-updated commodities, only `close` is meaningful \u2014 `open`, `high`, and `low` are returned as `0`.",
|
|
2288
2317
|
required: ["date", "open", "high", "low", "close"],
|
|
2289
2318
|
properties: {
|
|
2290
2319
|
date: {
|
|
2291
2320
|
type: "string",
|
|
2292
|
-
description: "Date for which prices were fetched (YYYY-MM-DD). May differ from the requested `date` when the API falls back to the last available rate before it."
|
|
2321
|
+
description: "Date for which prices were fetched (YYYY-MM-DD). May differ from the requested `date` when the API falls back to the last available rate before it, or snaps to the first day of the month for monthly-updated commodities."
|
|
2293
2322
|
},
|
|
2294
2323
|
open: {
|
|
2295
2324
|
type: "number",
|
|
2296
2325
|
format: "float",
|
|
2297
|
-
description: "Opening price on the given date."
|
|
2326
|
+
description: "Opening price on the given date. `0` for monthly-updated commodities."
|
|
2298
2327
|
},
|
|
2299
2328
|
high: {
|
|
2300
2329
|
type: "number",
|
|
2301
2330
|
format: "float",
|
|
2302
|
-
description: "Highest price recorded on the given date."
|
|
2331
|
+
description: "Highest price recorded on the given date. `0` for monthly-updated commodities."
|
|
2303
2332
|
},
|
|
2304
2333
|
low: {
|
|
2305
2334
|
type: "number",
|
|
2306
2335
|
format: "float",
|
|
2307
|
-
description: "Lowest price recorded on the given date."
|
|
2336
|
+
description: "Lowest price recorded on the given date. `0` for monthly-updated commodities."
|
|
2308
2337
|
},
|
|
2309
2338
|
close: {
|
|
2310
2339
|
type: "number",
|
|
@@ -50126,11 +50155,11 @@ var SPECS = {
|
|
|
50126
50155
|
var SPEC_SLUGS = ["usage-credits", "commodity-fluctuation", "commodity-prices", "commodity-symbols", "commodity-time-series", "historical-commodity-prices", "currency-converter", "currency-fluctuation", "currency-historical-data-limit", "currency-rate", "currency-supported", "currency-symbols", "currency-time-series", "geolocalized-currency-conversion", "historical-currency-converter", "historical-currency-rate", "bulk-dns-lookup", "dns-history-lookup", "dns-lookup", "reverse-dns-lookup", "bulk-domain-checker", "domain-reputation", "domain-search-with-suggestions", "domain-search", "domain-typosquatting", "subdomain-lookup", "bulk-email-validation", "email-checker", "bulk-vat-rates-country", "financial-apis-supported-countries", "iban-validation", "swift-code-finder", "swift-code-lookup", "vat-number-validation", "vat-rates-by-ip", "vat-rates-country", "forward-geocoding", "reverse-geocoding", "administrative-units-details", "administrative-units-levels", "administrative-units", "cities", "countries-details", "countries", "flags-supported", "flags", "regions", "subregions", "bulk-ip-lookup", "bulk-ip-threat-intelligence", "ip-locator", "ip-threat-intelligence", "delete-pdf-page", "linearize-pdf", "merge-pdf", "pdf-compress", "pdf-decrypt", "pdf-encrypt", "pdf-extract-pages", "pdf-file-status", "pdf-file", "pdf-files", "pdf-generator-bulk", "pdf-generator", "pdf-resource-download", "pdf-resource-upload-binary", "pdf-resource-upload", "pdf-restrict", "pdf-task-status", "pdf-to-image", "pdf-unrestrict", "rotate-pdf-pages", "split-pdf", "bulk-phone-number-validation", "phone-validation", "web-scraper", "bulk-screenshot", "website-screenshot", "ssl-certificate-chain-lookup", "ssl-certificate-lookup", "timezone-converter", "timezone-lookup", "bulk-user-agent-parser", "user-agent-parser", "air-quality", "astronomy-data", "bulk-live-weather", "flood-forecast", "historical-weather", "live-weather", "marine-weather", "time-series-weather", "weather-forecast", "asn-lookup", "bulk-whois-lookup", "domain-whois-history-lookup", "reverse-whois", "whois-domain-lookup", "whois-ip-lookup", "bulk-zip-code-lookup", "zip-code-api", "zip-code-distance-match", "zip-code-distance", "zip-codes-by-city", "zip-codes-by-region", "zip-codes-radius-search"];
|
|
50127
50156
|
var SPECS_YAML = {
|
|
50128
50157
|
"usage-credits": "openapi: 3.1.1\ninfo:\n title: Credits Usage API\n version: 1.0.0\n description: Retrieve the remaining and consumed API credit balances for the authenticated organization. Returns subscription-plan credits, subscription surcharge (overage) credits, and one-off credit purchases as separate balances, each with allowed and used counts. Only an organization admin API key can call this endpoint; all other keys receive a 403. There are no optional data modules for this endpoint \u2014 the response always includes the full credit breakdown.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v1.0\n description: Credits Usage API Server\npaths:\n /credits/usage/info:\n get:\n tags:\n - General APIs\n summary: Get remaining and consumed API credit balances for the organization\n description: Returns subscription, subscription-surcharge, and one-off credit balances for the authenticated organization's account.\n operationId: getCreditsUsage\n parameters:\n - name: format\n in: query\n required: false\n description: 'Format of the response. Possible values: json, xml.'\n schema:\n type: string\n enum:\n - json\n - xml\n default: json\n responses:\n '200':\n description: Successful response with credit balances\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CreditsUsageResponse'\n examples:\n success:\n summary: Typical response\n value:\n apiKey: demo\n userStatus: active\n subActive: true\n subStatus: active\n subAllowedCredits: 10000\n subUsedCredits: 2500\n subSurchargeStatus: none\n subSurchargeAllowedCredits: 0\n subSurchargeUsedCredits: 0\n subSurchargeAllowed: false\n oneOffCreditsActive: true\n oneOffAllowedCredits: 5000\n oneOffUsedCredits: 1000\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '403':\n description: Forbidden \u2014 Caller is not an organization admin\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n notOrgAdmin:\n summary: Not an organization admin\n value:\n timestamp: '2026-07-27T10:23:16.548Z'\n path: /v1.0/credits/usage/info\n status: 403\n error: API Access Exception\n message: You need to be organization admin to access this endpoint.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CreditsUsageResponse:\n type: object\n description: Credit balances for the organization's subscription, subscription surcharge, and one-off purchases.\n required:\n - apiKey\n - userStatus\n - oneOffCreditsActive\n - oneOffAllowedCredits\n - oneOffUsedCredits\n properties:\n apiKey:\n type: string\n description: The API key the credit balances belong to.\n userStatus:\n type: string\n enum:\n - active\n - inactive\n - deleted\n description: Status of the user account.\n subActive:\n type:\n - boolean\n - 'null'\n description: Whether a subscription plan is currently active. Null if the account has no subscription.\n subStatus:\n type:\n - string\n - 'null'\n enum:\n - active\n - overdue\n - cancelled\n - deactivated\n - null\n description: Status of the subscription credits. Null if the account has no subscription.\n subAllowedCredits:\n type:\n - integer\n - 'null'\n description: Total credits allowed under the subscription plan. Null if the account has no subscription.\n subUsedCredits:\n type:\n - integer\n - 'null'\n description: Credits consumed under the subscription plan. Null if the account has no subscription.\n subSurchargeStatus:\n type:\n - string\n - 'null'\n enum:\n - none\n - payment_added\n - payment_cleared\n - null\n description: Status of the subscription surcharge (overage) credits. Null if the account has no subscription.\n subSurchargeAllowedCredits:\n type:\n - integer\n - 'null'\n description: Total surcharge credits allowed. Null if the account has no subscription.\n subSurchargeUsedCredits:\n type:\n - integer\n - 'null'\n description: Surcharge credits consumed. Null if the account has no subscription.\n subSurchargeAllowed:\n type:\n - boolean\n - 'null'\n description: Whether surcharge (overage) usage is allowed on the subscription. Null if the account has no subscription.\n oneOffCreditsActive:\n type: boolean\n description: Whether the account has active one-off (pay-as-you-go) credits.\n oneOffAllowedCredits:\n type: integer\n description: Total one-off credits purchased.\n oneOffUsedCredits:\n type: integer\n description: One-off credits consumed.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type.\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path that produced the error.\n status:\n type: integer\n description: HTTP status code returned with the error.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50129
|
-
"commodity-fluctuation": "openapi: 3.1.1\ninfo:\n title: 'Commodity Fluctuation API '\n version: 2.0.0\n description: Calculate price change and percentage movement for any commodity over a custom date range. Returns the opening price, closing price, absolute change, and percentage change for each symbol, rounded to 2 decimal places. For monthly-updated commodities, the fluctuation is computed between the first day of the start month and the first day of the end month. There is no limit on the date range. Accepts one or more comma-separated commodity symbols with a start and end date in YYYY-MM-DD format. If some requested symbols can't be resolved, a 206 Partial Content response is returned with the resolved rates plus an `unresolved` object. Returns a 400 error for invalid dates or a date range where start is after end, and a 404 error for unsupported symbols or a date range with no available data.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Commodity Fluctuation API Server\npaths:\n /commodity/fluctuation:\n get:\n tags:\n - Commodity APIs\n summary: Get commodity price fluctuations\n description: Returns price fluctuation metrics (start, end, change, percent change) for the requested commodity symbols over a date range.\n operationId: getCommodityFluctuation\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: startDate\n in: query\n required: true\n description: Start date in `YYYY-MM-DD` format.\n schema:\n type: string\n - name: endDate\n in: query\n required: true\n description: End date in `YYYY-MM-DD` format.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityFluctuationResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n startDate: '2024-01-01'\n endDate: '2024-01-31'\n rates:\n WTIOIL-SPOT:\n startRate: 72.02\n endRate: 75.81\n change: 3.79\n changePercent: 5.26\n XAU:\n startRate: 2063.63\n endRate: 2039.83\n change: -23.8\n changePercent: -1.15\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityFluctuationResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n startDate: '2024-01-01'\n endDate: '2024-01-31'\n rates:\n XAU:\n startRate: 2063.63\n endRate: 2039.83\n change: -23.8\n changePercent: -1.15\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters or invalid dates\n content:\n application/json:\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/fluctuation\n status: 400\n timestamp: '2026-09-14T08:43:46.481Z'\n invalidDateFormat:\n summary: Date is not in YYYY-MM-DD format\n value:\n timestamp: '2026-07-27T11:37:22.687Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: Invalid Date Format (YYYY-MM-DD).\n dateNotExist:\n summary: Date does not exist on the calendar (e.g. Feb 30)\n value:\n timestamp: '2026-07-27T11:37:33.565Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided start date or end date does not exist.'\n startAfterEnd:\n summary: startDate is after endDate\n value:\n timestamp: '2026-07-27T11:37:23.206Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: Start date cannot be after end date\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:43:48.408Z'\n path: /rates/fluctuation\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or data not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:43:48.408Z'\n path: /rates/fluctuation\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n noData:\n summary: No data available for the given date range\n value:\n timestamp: '2026-09-14T08:44:31.022Z'\n path: /rates/fluctuation\n code: 404\n error: DATA_NOT_FOUND\n message: No data found for the given date range\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CommodityFluctuationResponse:\n type: object\n required:\n - success\n - startDate\n - endDate\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n startDate:\n type: string\n description: Start date of the interval (YYYY-MM-DD).\n endDate:\n type: string\n description: End date of the interval (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/CommodityFluctuationRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Commodity fluctuation response containing price change data per symbol over a date range.\n CommodityFluctuationRates:\n type: object\n description: Map of requested commodity symbols to their fluctuation metrics. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n title: CommodityFluctuationItem\n type: object\n description: Fluctuation metrics for a single commodity over a date range.\n required:\n - startRate\n - endRate\n - change\n - changePercent\n properties:\n startRate:\n type: number\n format: float\n description: Price of the commodity on the start date.\n endRate:\n type: number\n format: float\n description: Price of the commodity on the end date.\n change:\n type: number\n format: float\n description: Absolute price difference between end and start dates. May be negative.\n changePercent:\n type: number\n format: float\n description: Percentage price change from start to end date. May be negative.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/data validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, DATA_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50130
|
-
"commodity-prices": "openapi: 3.1.1\ninfo:\n title: Live Commodity Prices API - Real Time Market Insights\n version: 2.0.0\n description: Get real-time prices for 245+ commodities in a single request. Returns current market prices for each requested symbol plus unit and quote currency metadata. Supports an optional quote parameter to convert prices into a desired currency, defaulting to each commodity's native market currency. Accepts 10-minute or 1-minute update frequencies for price freshness. If some requested symbols can't be resolved, a 206 Partial Content response is returned with the resolved rates plus an `unresolved` object; if none resolve, a 404 is returned instead. An unsupported quote currency also returns a 404.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Live Commodity Prices API Server\npaths:\n /commodity/rates/latest:\n get:\n tags:\n - Commodity APIs\n summary: Get latest commodity prices\n description: Returns the current live price for the requested commodity symbols.\n operationId: getLatestCommodityPrices\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols (e.g., `XAU`, `WTIOIL-SPOT`).\n schema:\n type: string\n - name: updates\n in: query\n required: true\n description: 'Update frequency. Accepted values: `10m` (default), `1m`.'\n schema:\n type: string\n enum:\n - 10m\n - 1m\n default: 10m\n - name: quote\n in: query\n required: false\n description: Target currency for the exchange rate. Defaults to the market currency of each commodity.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/LiveCommodityPricesResponse'\n examples:\n success:\n summary: Successful response (10m update frequency)\n value:\n success: true\n timestamp: 1789375397\n rates:\n XAU: 4313.04\n WTIOIL-SPOT: 100\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n WTIOIL-SPOT:\n unit: Bbl\n quote: USD\n withQuoteConversion:\n summary: Price converted to a target quote currency\n value:\n success: true\n timestamp: 1789375426\n rates:\n XAU: 3739.023\n metadata:\n XAU:\n unit: T.oz\n quote: EUR\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/LiveCommodityPricesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n timestamp: 1789376193\n rates:\n XAU: 4311.88\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n partialWithSuggestions:\n summary: Unresolved symbol with close-match suggestions\n value:\n success: true\n timestamp: 1789376644\n rates:\n XAU: 4306.06\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n unresolved:\n ZW:\n message: Did you mean ZW-SPOT (Wheat Spot) or ZW-FUT (Wheat Futures)?\n suggestions:\n - ZW-SPOT\n - ZW-FUT\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing or invalid query parameters\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/rates/latest\n status: 400\n timestamp: '2026-09-14T08:43:43.964Z'\n invalidUpdates:\n summary: updates is not 10m or 1m\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/rates/latest\n status: 400\n timestamp: '2026-09-14T08:43:44.440Z'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityNotFoundError'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:43:44.957Z'\n path: /rates/latestRates\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or quote currency not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityNotFoundError'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:43:44.957Z'\n path: /rates/latestRates\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n symbolNotFoundWithSuggestions:\n summary: Symbol Not Found, with close-match suggestions\n value:\n timestamp: '2026-09-14T09:04:04.878Z'\n path: /rates/latestRates\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n ZW:\n message: Did you mean ZW-SPOT (Wheat Spot) or ZW-FUT (Wheat Futures)?\n suggestions:\n - ZW-SPOT\n - ZW-FUT\n quoteNotFound:\n summary: Quote Currency Not Found\n value:\n timestamp: '2026-09-14T08:43:45.461Z'\n path: /rates/latestRates\n code: 404\n error: QUOTE_NOT_FOUND\n message: The quote currency is invalid, please visit the documentation for a list of valid quote currencies\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n LiveCommodityPricesResponse:\n type: object\n required:\n - success\n - timestamp\n - rates\n - metadata\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n timestamp:\n type: integer\n description: Unix timestamp (seconds) indicating when the response was generated.\n rates:\n $ref: '#/components/schemas/CommodityRates'\n metadata:\n $ref: '#/components/schemas/CommodityMetadata'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n warning:\n type: string\n description: Present only when currency conversion for the requested `quote` is temporarily unavailable; rates are returned in each commodity's default currency instead.\n description: Live commodity prices response containing success status, timestamp, rates, and metadata.\n CommodityRates:\n type: object\n description: Map of requested commodity symbols to their current live price. Each key is a commodity symbol (e.g. XAU); the value is the current price.\n additionalProperties:\n title: CommodityPrice\n type: number\n description: Current live price for this commodity symbol.\n CommodityMetadata:\n type: object\n description: Map of requested commodity symbols to their unit and quote currency metadata. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n title: CommodityMetadataItem\n type: object\n description: Unit and currency metadata for a single commodity.\n required:\n - unit\n - quote\n properties:\n unit:\n type: string\n description: Unit of measurement for the commodity (e.g., Bbl, T.oz).\n quote:\n type: string\n description: Quote currency used for this commodity's price.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type.\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path that produced the error.\n status:\n type: integer\n description: HTTP status code returned with the error.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n CommodityNotFoundError:\n type: object\n description: Error envelope returned by the commodity pricing service specifically for unresolvable symbol/quote errors. Uses `code` instead of `status` and an ISO 8601 `timestamp`, unlike the standard ErrorResponse.\n required:\n - code\n - error\n - message\n properties:\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n path:\n type: string\n description: Internal service path that produced the error.\n code:\n type: integer\n description: HTTP status code returned with the error.\n error:\n type: string\n description: Specific error type (e.g., SYMBOL_NOT_FOUND, QUOTE_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50131
|
-
"commodity-symbols": "openapi: 3.1.1\ninfo:\n title: Commodity Symbols API Reference\n version: 2.0.0\n description: '
|
|
50132
|
-
"commodity-time-series": "openapi: 3.1.1\ninfo:\n title: Commodities Time Series API\n version: 2.0.0\n description: Retrieve daily OHLC (open, high, low, close) price data for any supported commodity over a date range of up to 365 days. Accepts one or more comma-separated commodity symbols with a start and end date in YYYY-MM-DD format. Returns a date-indexed object where each date key maps to per-symbol OHLC data. Non-trading days are automatically excluded, and only closing rates are available for monthly-updated commodities. A symbol is considered resolved if it appears on at least one date in the range; if some requested symbols can't be resolved at all, a 206 Partial Content response is returned with an `unresolved` object. Returns a 400 error for invalid dates or a range exceeding 365 days, and a 404 error for unsupported symbols or a date range with no available data.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Commodity Time Series API Server\npaths:\n /commodity/time-series:\n get:\n tags:\n - Commodity APIs\n summary: Get commodity price time series\n description: Returns day-by-day OHLC data for the requested commodity symbols within a date range.\n operationId: getCommodityTimeSeries\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: startDate\n in: query\n required: true\n description: Start date in `YYYY-MM-DD` format.\n schema:\n type: string\n - name: endDate\n in: query\n required: true\n description: End date in `YYYY-MM-DD` format. Maximum range is 365 days.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityTimeSeriesResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n startDate: '2025-01-06'\n endDate: '2025-01-08'\n rates:\n '2025-01-06':\n XAU:\n open: 2649.01\n high: 2651.33\n low: 2645.36\n close: 2646.91\n '2025-01-07':\n XAU:\n open: 2662.45\n high: 2663.06\n low: 2655.66\n close: 2658.9\n '2025-01-08':\n XAU:\n open: 2669.69\n high: 2674.68\n low: 2668.58\n close: 2671.8\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityTimeSeriesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n startDate: '2025-01-06'\n endDate: '2025-01-08'\n rates:\n '2025-01-06':\n XAU:\n open: 2649.01\n high: 2651.33\n low: 2645.36\n close: 2646.91\n '2025-01-07':\n XAU:\n open: 2662.45\n high: 2663.06\n low: 2655.66\n close: 2658.9\n '2025-01-08':\n XAU:\n open: 2669.69\n high: 2674.68\n low: 2668.58\n close: 2671.8\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters, invalid dates, or date range exceeded\n content:\n application/json:\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/time-series\n status: 400\n timestamp: '2026-09-14T08:43:58.547Z'\n invalidDate:\n summary: Date does not exist on the calendar\n value:\n timestamp: '2026-07-27T11:38:41.234Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided start date or end date does not exist.'\n startAfterEnd:\n summary: startDate is after endDate\n value:\n timestamp: '2026-07-27T11:38:41.234Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: start date cannot be after end date\n dateRangeExceeded:\n summary: Date range exceeds 365 days\n value:\n timestamp: '2026-07-27T11:38:40.699Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: Date range exceeds the allowed limit.\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:44:00.586Z'\n path: /rates/time-series\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or data not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:44:00.586Z'\n path: /rates/time-series\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n dataNotFound:\n summary: No data available for the given date range\n value:\n timestamp: '2026-09-14T08:44:31.547Z'\n path: /rates/time-series\n code: 404\n error: DATA_NOT_FOUND\n message: No data found for the specified date range\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CommodityTimeSeriesResponse:\n type: object\n required:\n - success\n - startDate\n - endDate\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n startDate:\n type: string\n description: Start date of the time series (YYYY-MM-DD).\n endDate:\n type: string\n description: End date of the time series (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/CommodityTimeSeriesRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved on any date in the range. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Commodity time series response containing date-indexed OHLC data per symbol.\n CommodityTimeSeriesRates:\n type: object\n description: Map of trading dates to per-symbol OHLC data. Each key is a trading date (YYYY-MM-DD); non-trading days are excluded.\n additionalProperties:\n title: CommodityTimeSeriesSymbolData\n type: object\n description: Map of commodity symbols to their OHLC data for a single trading date. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n $ref: '#/components/schemas/CommodityOhlc'\n CommodityOhlc:\n type: object\n description: OHLC price data for a single commodity on a single trading day.\n required:\n - open\n - high\n - low\n - close\n properties:\n open:\n type: number\n format: float\n description: Opening price on the given date.\n high:\n type: number\n format: float\n description: Highest price on the given date.\n low:\n type: number\n format: float\n description: Lowest price on the given date.\n close:\n type: number\n format: float\n description: Closing price on the given date.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/data validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, DATA_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50133
|
-
"historical-commodity-prices": "openapi: 3.1.1\ninfo:\n title: Historical Commodity Prices, Delivered Simply.\n version: 2.0.0\n description: Retrieve OHLC (open, high, low, close) price data for any supported commodity on a specific date. Data is available from January 1990 onwards for 245+ commodities, and only closing rates are available for monthly-updated commodities. If a commodity has no rate on the requested date, the API falls back to the last available rate before that date and returns it along with its actual date. Accepts one or more comma-separated commodity symbols and a date in YYYY-MM-DD format. If some requested symbols can't be resolved (unsupported, or no rate on or before the requested date), a 206 Partial Content response is returned with the resolved rates plus an `unresolved` object. Returns a 400 error for invalid dates and a 404 error for unsupported symbols or missing rates.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Historical Commodity Prices API Server\npaths:\n /commodity/rates/historical:\n get:\n tags:\n - Commodity APIs\n summary: Get historical commodity prices\n description: Returns OHLC price data for the requested commodity symbols on a specific date.\n operationId: getHistoricalCommodityPrices\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: date\n in: query\n required: true\n description: Date in `YYYY-MM-DD` format. Data available from 1990 onwards.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/HistoricalCommodityPricesResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n date: '2025-01-10'\n rates:\n WTIOIL-SPOT:\n date: '2025-01-10'\n open: 73.77\n high: 77.16\n low: 73.55\n close: 75.97\n XAU:\n date: '2025-01-10'\n open: 2669.93\n high: 2697.85\n low: 2663.61\n close: 2689.44\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/HistoricalCommodityPricesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n date: '2025-01-10'\n rates:\n XAU:\n date: '2025-01-10'\n open: 2669.93\n high: 2697.85\n low: 2663.61\n close: 2689.44\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters or invalid date\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/rates/historical\n status: 400\n timestamp: '2026-09-14T08:44:32.013Z'\n invalidDateFormat:\n summary: Invalid date format\n value:\n timestamp: '2026-09-14T08:45:13.934Z'\n path: /rates/historical\n code: 400\n error: VALIDATION_ERROR\n message: Invalid Date Format (YYYY-MM-DD).\n dateNotExist:\n summary: Date does not exist\n value:\n timestamp: '2026-09-14T08:44:01.487Z'\n path: /rates/historical\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided date does not exist.'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:44:01.978Z'\n path: /rates/historical\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or rate not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:44:01.978Z'\n path: /rates/historical\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n rateNotFound:\n summary: Rate Not Found\n value:\n timestamp: '2026-09-14T08:44:02.528Z'\n path: /rates/historical\n code: 404\n error: RATE_NOT_FOUND\n message: no rates found for the specified date\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n HistoricalCommodityPricesResponse:\n type: object\n required:\n - success\n - date\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n date:\n type: string\n description: Date for which prices were fetched (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/HistoricalCommodityRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Historical commodity prices response containing success status, date, and OHLC rate data.\n HistoricalCommodityRates:\n type: object\n description: Object of commodity symbols to their OHLC price data. Each key is a commodity symbol and the value contains date, open, high, low, and close prices.\n properties:\n symbol:\n $ref: '#/components/schemas/HistoricalCommodityRate'\n required:\n - symbol\n HistoricalCommodityRate:\n type: object\n description: OHLC price data for a single commodity on a specific date.\n required:\n - date\n - open\n - high\n - low\n - close\n properties:\n date:\n type: string\n description: Date for which prices were fetched (YYYY-MM-DD). May differ from the requested `date` when the API falls back to the last available rate before it.\n open:\n type: number\n format: float\n description: Opening price on the given date.\n high:\n type: number\n format: float\n description: Highest price recorded on the given date.\n low:\n type: number\n format: float\n description: Lowest price recorded on the given date.\n close:\n type: number\n format: float\n description: Closing price on the given date.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/rate validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, RATE_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50158
|
+
"commodity-fluctuation": "openapi: 3.1.1\ninfo:\n title: 'Commodity Fluctuation API '\n version: 2.0.0\n description: Price change and percentage movement for one or more commodities over a custom date range, with no limit on range length. For monthly-updated commodities the range snaps to month boundaries. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Commodity Fluctuation API Server\npaths:\n /commodity/fluctuation:\n get:\n tags:\n - Commodity APIs\n summary: Get commodity price fluctuations\n description: Returns price fluctuation metrics (start, end, change, percent change) for the requested commodity symbols over a date range.\n operationId: getCommodityFluctuation\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: startDate\n in: query\n required: true\n description: Start date in `YYYY-MM-DD` format.\n schema:\n type: string\n - name: endDate\n in: query\n required: true\n description: End date in `YYYY-MM-DD` format.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityFluctuationResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n startDate: '2024-01-01'\n endDate: '2024-01-31'\n rates:\n WTIOIL-SPOT:\n startRate: 72.02\n endRate: 75.81\n change: 3.79\n changePercent: 5.26\n XAU:\n startRate: 2063.63\n endRate: 2039.83\n change: -23.8\n changePercent: -1.15\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityFluctuationResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n startDate: '2024-01-01'\n endDate: '2024-01-31'\n rates:\n XAU:\n startRate: 2063.63\n endRate: 2039.83\n change: -23.8\n changePercent: -1.15\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters or invalid dates\n content:\n application/json:\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/fluctuation\n status: 400\n timestamp: '2026-09-14T08:43:46.481Z'\n invalidDateFormat:\n summary: Date is not in YYYY-MM-DD format\n value:\n timestamp: '2026-07-27T11:37:22.687Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: Invalid Date Format (YYYY-MM-DD).\n dateNotExist:\n summary: Date does not exist on the calendar (e.g. Feb 30)\n value:\n timestamp: '2026-07-27T11:37:33.565Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided start date or end date does not exist.'\n startAfterEnd:\n summary: startDate is after endDate\n value:\n timestamp: '2026-07-27T11:37:23.206Z'\n path: /rates/fluctuation\n code: 400\n error: VALIDATION_ERROR\n message: Start date cannot be after end date\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:43:48.408Z'\n path: /rates/fluctuation\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or data not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:43:48.408Z'\n path: /rates/fluctuation\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n noData:\n summary: No data available for the given date range\n value:\n timestamp: '2026-09-14T08:44:31.022Z'\n path: /rates/fluctuation\n code: 404\n error: DATA_NOT_FOUND\n message: No data found for the given date range\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CommodityFluctuationResponse:\n type: object\n required:\n - success\n - startDate\n - endDate\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n startDate:\n type: string\n description: Start date of the interval (YYYY-MM-DD).\n endDate:\n type: string\n description: End date of the interval (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/CommodityFluctuationRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Commodity fluctuation response containing price change data per symbol over a date range.\n CommodityFluctuationRates:\n type: object\n description: Map of requested commodity symbols to their fluctuation metrics. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n title: CommodityFluctuationItem\n type: object\n description: Fluctuation metrics for a single commodity over a date range.\n required:\n - startRate\n - endRate\n - change\n - changePercent\n properties:\n startRate:\n type: number\n format: float\n description: Price of the commodity on the start date.\n endRate:\n type: number\n format: float\n description: Price of the commodity on the end date.\n change:\n type: number\n format: float\n description: Absolute price difference between end and start dates. May be negative.\n changePercent:\n type: number\n format: float\n description: Percentage price change from start to end date. May be negative.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/data validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, DATA_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50159
|
+
"commodity-prices": "openapi: 3.1.1\ninfo:\n title: Live Commodity Prices API - Real Time Market Insights\n version: 2.0.0\n description: Real-time prices for 245+ commodities in a single request, updated on a rolling ~10 minute cadence. Optionally convert prices into a target quote currency. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Live Commodity Prices API Server\npaths:\n /commodity/rates/latest:\n get:\n tags:\n - Commodity APIs\n summary: Get latest commodity prices\n description: Returns the current live price for the requested commodity symbols.\n operationId: getLatestCommodityPrices\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols (e.g., `XAU`, `WTIOIL-SPOT`).\n schema:\n type: string\n - name: quote\n in: query\n required: false\n description: Target currency for the exchange rate. Defaults to the market currency of each commodity.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/LiveCommodityPricesResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n timestamp: 1789375397\n rates:\n XAU: 4313.04\n WTIOIL-SPOT: 100\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n WTIOIL-SPOT:\n unit: Bbl\n quote: USD\n withQuoteConversion:\n summary: Price converted to a target quote currency\n value:\n success: true\n timestamp: 1789375426\n rates:\n XAU: 3739.023\n metadata:\n XAU:\n unit: T.oz\n quote: EUR\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/LiveCommodityPricesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n timestamp: 1789376193\n rates:\n XAU: 4311.88\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n partialWithSuggestions:\n summary: Unresolved symbol with close-match suggestions\n value:\n success: true\n timestamp: 1789376644\n rates:\n XAU: 4306.06\n metadata:\n XAU:\n unit: T.oz\n quote: USD\n unresolved:\n ZW:\n message: Did you mean ZW-SPOT (Wheat Spot) or ZW-FUT (Wheat Futures)?\n suggestions:\n - ZW-SPOT\n - ZW-FUT\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing or invalid query parameters\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/rates/latest\n status: 400\n timestamp: '2026-09-14T08:43:43.964Z'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityNotFoundError'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:43:44.957Z'\n path: /rates/latestRates\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or quote currency not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityNotFoundError'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:43:44.957Z'\n path: /rates/latestRates\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n symbolNotFoundWithSuggestions:\n summary: Symbol Not Found, with close-match suggestions\n value:\n timestamp: '2026-09-14T09:04:04.878Z'\n path: /rates/latestRates\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n ZW:\n message: Did you mean ZW-SPOT (Wheat Spot) or ZW-FUT (Wheat Futures)?\n suggestions:\n - ZW-SPOT\n - ZW-FUT\n quoteNotFound:\n summary: Quote Currency Not Found\n value:\n timestamp: '2026-09-14T08:43:45.461Z'\n path: /rates/latestRates\n code: 404\n error: QUOTE_NOT_FOUND\n message: The quote currency is invalid, please visit the documentation for a list of valid quote currencies\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n LiveCommodityPricesResponse:\n type: object\n required:\n - success\n - timestamp\n - rates\n - metadata\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n timestamp:\n type: integer\n description: Unix timestamp (seconds) indicating when the response was generated.\n rates:\n $ref: '#/components/schemas/CommodityRates'\n metadata:\n $ref: '#/components/schemas/CommodityMetadata'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n warning:\n type: string\n description: Present only when currency conversion for the requested `quote` is temporarily unavailable; rates are returned in each commodity's default currency instead.\n description: Live commodity prices response containing success status, timestamp, rates, and metadata.\n CommodityRates:\n type: object\n description: Map of requested commodity symbols to their current live price. Each key is a commodity symbol (e.g. XAU); the value is the current price.\n additionalProperties:\n title: CommodityPrice\n type: number\n description: Current live price for this commodity symbol.\n CommodityMetadata:\n type: object\n description: Map of requested commodity symbols to their unit and quote currency metadata. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n title: CommodityMetadataItem\n type: object\n description: Unit and currency metadata for a single commodity.\n required:\n - unit\n - quote\n properties:\n unit:\n type: string\n description: Unit of measurement for the commodity (e.g., Bbl, T.oz).\n quote:\n type: string\n description: Quote currency used for this commodity's price.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type.\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path that produced the error.\n status:\n type: integer\n description: HTTP status code returned with the error.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n CommodityNotFoundError:\n type: object\n description: Error envelope returned by the commodity pricing service specifically for unresolvable symbol/quote errors. Uses `code` instead of `status` and an ISO 8601 `timestamp`, unlike the standard ErrorResponse.\n required:\n - code\n - error\n - message\n properties:\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n path:\n type: string\n description: Internal service path that produced the error.\n code:\n type: integer\n description: HTTP status code returned with the error.\n error:\n type: string\n description: Specific error type (e.g., SYMBOL_NOT_FOUND, QUOTE_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50160
|
+
"commodity-symbols": "openapi: 3.1.1\ninfo:\n title: Commodity Symbols API Reference\n version: 2.0.0\n description: 'Full catalog of 245+ supported commodities across Metals, Energy, Agriculture, Industrial, Raw Materials, Oils and Meals, Textiles, Meats, Poultry, and Livestock, with pricing currency, unit, and update interval per symbol. Deprecated symbols stay listed with `status: \"inactive\"` and a `deprecationDate`.'\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Commodity Symbols API Server\npaths:\n /commodity/symbols:\n get:\n tags:\n - Commodity APIs\n summary: Get all supported commodity symbols\n description: Returns the list of supported commodity symbols with metadata.\n operationId: getCommoditySymbols\n parameters:\n - name: format\n in: query\n required: false\n description: 'Response format. Accepted values: `json` (default) or `xml`.'\n schema:\n type: string\n enum:\n - json\n default: json\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommoditySymbolsResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n symbols:\n - symbol: XAU\n name: Gold\n category: Metals\n status: active\n updateInterval: PER_SECOND\n currency:\n code: USD\n name: US Dollar\n symbol: $\n unit:\n symbol: T.oz\n name: Troy Ounce\n - symbol: NG-FUT\n name: Natural Gas Futures\n category: Energy\n status: active\n updateInterval: PER_MINUTE\n currency:\n code: USD\n name: US Dollar\n symbol: $\n unit:\n symbol: MMBtu\n name: Million British Thermal Units\n - symbol: NG-EU\n name: Natural Gas, Europe\n category: Energy\n status: active\n updateInterval: PER_MONTH\n exchange: World Bank\n currency:\n code: USD\n name: US Dollar\n symbol: $\n unit:\n symbol: MMBtu\n name: Million British Thermal Units\n - symbol: UANEU\n name: Urea Ammonium Nitrate\n category: Industrial\n status: inactive\n updateInterval: PER_MINUTE\n deprecationDate: '2024-04-14'\n currency:\n code: USD\n name: US Dollar\n symbol: $\n unit:\n symbol: T\n name: Metric Ton\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CommoditySymbolsResponse:\n type: object\n required:\n - success\n - symbols\n properties:\n success:\n type: boolean\n description: Indicates whether the API request was successful.\n symbols:\n type: array\n description: Array of commodity symbol objects with metadata.\n items:\n $ref: '#/components/schemas/CommoditySymbolItem'\n description: Commodity symbols response containing an array of supported commodity symbol objects.\n CommoditySymbolItem:\n type: object\n description: A single commodity symbol with metadata.\n required:\n - symbol\n - name\n - category\n - status\n - updateInterval\n - currency\n - unit\n properties:\n symbol:\n type: string\n description: Unique identifier/ticker symbol for the commodity (e.g., XAU, NG-FUT). Use this value in the `symbols` parameter of the rate endpoints.\n name:\n type: string\n description: Full name of the commodity (e.g., Gold, Natural Gas Futures).\n description:\n type: string\n description: Short description of the commodity. May be an empty string for some symbols.\n category:\n type: string\n description: Category the commodity belongs to (e.g., Metals, Energy, Agriculture, Industrial, Raw Materials, Oils and Meals, Textiles, Meats, Poultry, Livestock).\n status:\n type: string\n enum:\n - active\n - inactive\n description: 'Current status of the commodity. `inactive` means the symbol is deprecated: latest rates are unavailable, but historical rates remain available up to its `deprecationDate`.'\n updateInterval:\n type: string\n enum:\n - PER_SECOND\n - PER_MINUTE\n - PER_10_MINUTES\n - PER_HOUR\n - PER_DAY\n - PER_WEEK\n - PER_MONTH\n description: Rate at which the price is updated.\n exchange:\n type: string\n description: Optional. Data source for the symbol (e.g., World Bank). Present only for some symbols.\n deprecationDate:\n type: string\n format: date\n description: Optional. Present only when `status` is `inactive`. Date the symbol was deprecated (YYYY-MM-DD).\n currency:\n $ref: '#/components/schemas/CommodityCurrency'\n unit:\n $ref: '#/components/schemas/CommodityUnit'\n CommodityCurrency:\n type: object\n description: Currency information for a commodity.\n required:\n - code\n - name\n - symbol\n properties:\n code:\n type: string\n description: ISO 4217 currency code.\n name:\n type: string\n description: Full name of the currency.\n symbol:\n type: string\n description: Symbol of the currency (e.g., $).\n CommodityUnit:\n type: object\n description: Unit of measurement for a commodity.\n required:\n - symbol\n - name\n properties:\n symbol:\n type: string\n description: Abbreviated unit symbol (e.g., T.oz, MMBtu).\n name:\n type: string\n description: Full name of the unit of measurement (e.g., Troy Ounce).\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50161
|
+
"commodity-time-series": "openapi: 3.1.1\ninfo:\n title: Commodities Time Series API\n version: 2.0.0\n description: Daily OHLC history for one or more commodities over a date range of up to 365 days, indexed by date. Non-trading days are excluded. Monthly-updated commodities only have a closing price \u2014 `open`, `high`, and `low` come back as `0`. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Commodity Time Series API Server\npaths:\n /commodity/time-series:\n get:\n tags:\n - Commodity APIs\n summary: Get commodity price time series\n description: Returns day-by-day OHLC data for the requested commodity symbols within a date range.\n operationId: getCommodityTimeSeries\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: startDate\n in: query\n required: true\n description: Start date in `YYYY-MM-DD` format.\n schema:\n type: string\n - name: endDate\n in: query\n required: true\n description: End date in `YYYY-MM-DD` format. Maximum range is 365 days.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityTimeSeriesResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n startDate: '2025-01-06'\n endDate: '2025-01-08'\n rates:\n '2025-01-06':\n XAU:\n open: 2649.01\n high: 2651.33\n low: 2645.36\n close: 2646.91\n '2025-01-07':\n XAU:\n open: 2662.45\n high: 2663.06\n low: 2655.66\n close: 2658.9\n '2025-01-08':\n XAU:\n open: 2669.69\n high: 2674.68\n low: 2668.58\n close: 2671.8\n monthlyCommodity:\n summary: Monthly-updated commodity (open/high/low unavailable)\n value:\n success: true\n startDate: '2025-01-01'\n endDate: '2025-03-01'\n rates:\n '2025-01-01':\n NG-EU:\n open: 0\n high: 0\n low: 0\n close: 14.66\n '2025-02-01':\n NG-EU:\n open: 0\n high: 0\n low: 0\n close: 15.34\n '2025-03-01':\n NG-EU:\n open: 0\n high: 0\n low: 0\n close: 13.24\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CommodityTimeSeriesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n startDate: '2025-01-06'\n endDate: '2025-01-08'\n rates:\n '2025-01-06':\n XAU:\n open: 2649.01\n high: 2651.33\n low: 2645.36\n close: 2646.91\n '2025-01-07':\n XAU:\n open: 2662.45\n high: 2663.06\n low: 2655.66\n close: 2658.9\n '2025-01-08':\n XAU:\n open: 2669.69\n high: 2674.68\n low: 2668.58\n close: 2671.8\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters, invalid dates, or date range exceeded\n content:\n application/json:\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/time-series\n status: 400\n timestamp: '2026-09-14T08:43:58.547Z'\n invalidDate:\n summary: Date does not exist on the calendar\n value:\n timestamp: '2026-07-27T11:38:41.234Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided start date or end date does not exist.'\n startAfterEnd:\n summary: startDate is after endDate\n value:\n timestamp: '2026-07-27T11:38:41.234Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: start date cannot be after end date\n dateRangeExceeded:\n summary: Date range exceeds 365 days\n value:\n timestamp: '2026-07-27T11:38:40.699Z'\n path: /rates/time-series\n code: 400\n error: VALIDATION_ERROR\n message: Date range exceeds the allowed limit.\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:44:00.586Z'\n path: /rates/time-series\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or data not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:44:00.586Z'\n path: /rates/time-series\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n dataNotFound:\n summary: No data available for the given date range\n value:\n timestamp: '2026-09-14T08:44:31.547Z'\n path: /rates/time-series\n code: 404\n error: DATA_NOT_FOUND\n message: No data found for the specified date range\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CommodityTimeSeriesResponse:\n type: object\n required:\n - success\n - startDate\n - endDate\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n startDate:\n type: string\n description: Start date of the time series (YYYY-MM-DD).\n endDate:\n type: string\n description: End date of the time series (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/CommodityTimeSeriesRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved on any date in the range. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Commodity time series response containing date-indexed OHLC data per symbol.\n CommodityTimeSeriesRates:\n type: object\n description: Map of trading dates to per-symbol OHLC data. Each key is a trading date (YYYY-MM-DD); non-trading days are excluded.\n additionalProperties:\n title: CommodityTimeSeriesSymbolData\n type: object\n description: Map of commodity symbols to their OHLC data for a single trading date. Each key is a commodity symbol (e.g. XAU).\n additionalProperties:\n $ref: '#/components/schemas/CommodityOhlc'\n CommodityOhlc:\n type: object\n description: OHLC price data for a single commodity on a single trading day. For monthly-updated commodities, only `close` is meaningful \u2014 `open`, `high`, and `low` are returned as `0`.\n required:\n - open\n - high\n - low\n - close\n properties:\n open:\n type: number\n format: float\n description: Opening price on the given date. `0` for monthly-updated commodities.\n high:\n type: number\n format: float\n description: Highest price on the given date. `0` for monthly-updated commodities.\n low:\n type: number\n format: float\n description: Lowest price on the given date. `0` for monthly-updated commodities.\n close:\n type: number\n format: float\n description: Closing price on the given date.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/data validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, DATA_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50162
|
+
"historical-commodity-prices": "openapi: 3.1.1\ninfo:\n title: Historical Commodity Prices, Delivered Simply.\n version: 2.0.0\n description: OHLC price data for one or more commodities on a specific date, back to January 1990. Falls back to the nearest earlier rate if none exists for the exact date. Monthly-updated commodities only have a closing price \u2014 `open`, `high`, and `low` come back as `0`. Unresolved symbols degrade to a 206 partial response instead of failing the whole request.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v2.0\n description: Historical Commodity Prices API Server\npaths:\n /commodity/rates/historical:\n get:\n tags:\n - Commodity APIs\n summary: Get historical commodity prices\n description: Returns OHLC price data for the requested commodity symbols on a specific date.\n operationId: getHistoricalCommodityPrices\n parameters:\n - name: format\n in: query\n required: false\n description: Response format. Currently only `json` is supported.\n schema:\n type: string\n default: json\n enum:\n - json\n - name: symbols\n in: query\n required: true\n description: Comma-separated list of commodity symbols.\n schema:\n type: string\n - name: date\n in: query\n required: true\n description: Date in `YYYY-MM-DD` format. Data available from 1990 onwards.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/HistoricalCommodityPricesResponse'\n examples:\n success:\n summary: Successful response\n value:\n success: true\n date: '2025-01-10'\n rates:\n WTIOIL-SPOT:\n date: '2025-01-10'\n open: 73.77\n high: 77.16\n low: 73.55\n close: 75.97\n XAU:\n date: '2025-01-10'\n open: 2669.93\n high: 2697.85\n low: 2663.61\n close: 2689.44\n monthlyCommodity:\n summary: Monthly-updated commodity (open/high/low unavailable)\n value:\n success: true\n date: '2025-01-10'\n rates:\n NG-EU:\n date: '2025-01-01'\n open: 0\n high: 0\n low: 0\n close: 14.66\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '206':\n description: Partial Content \u2014 Some requested symbols could not be resolved\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/HistoricalCommodityPricesResponse'\n examples:\n partial:\n summary: One valid symbol, one unresolved symbol\n value:\n success: true\n date: '2025-01-10'\n rates:\n XAU:\n date: '2025-01-10'\n open: 2669.93\n high: 2697.85\n low: 2663.61\n close: 2689.44\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad Request \u2014 Missing parameters or invalid date\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingSymbols:\n summary: Missing required symbols parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v2.0/commodity/rates/historical\n status: 400\n timestamp: '2026-09-14T08:44:32.013Z'\n invalidDateFormat:\n summary: Invalid date format\n value:\n timestamp: '2026-09-14T08:45:13.934Z'\n path: /rates/historical\n code: 400\n error: VALIDATION_ERROR\n message: Invalid Date Format (YYYY-MM-DD).\n dateNotExist:\n summary: Date does not exist\n value:\n timestamp: '2026-09-14T08:44:01.487Z'\n path: /rates/historical\n code: 400\n error: VALIDATION_ERROR\n message: 'Invalid Date: The provided date does not exist.'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '402':\n description: Payment Required \u2014 Maximum symbols per request exceeded\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n maxSymbolsExceeded:\n summary: Too many symbols requested\n value:\n timestamp: '2026-09-14T08:44:01.978Z'\n path: /rates/historical\n code: 402\n error: PAYMENT_REQUIRED\n message: Maximum symbols per request exceeded\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Symbol or rate not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n symbolNotFound:\n summary: Symbol Not Found\n value:\n timestamp: '2026-09-14T08:44:01.978Z'\n path: /rates/historical\n code: 404\n error: SYMBOL_NOT_FOUND\n message: The symbol is not supported, please visit the documentation for a list of supported symbols\n unresolved:\n FAKESYM:\n message: We don't support this symbol, please visit our symbols page to see supported symbols.\n rateNotFound:\n summary: Rate Not Found\n value:\n timestamp: '2026-09-14T08:44:02.528Z'\n path: /rates/historical\n code: 404\n error: RATE_NOT_FOUND\n message: no rates found for the specified date\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n HistoricalCommodityPricesResponse:\n type: object\n required:\n - success\n - date\n - rates\n properties:\n success:\n type: boolean\n description: '`true` for successful requests.'\n date:\n type: string\n description: Date for which prices were fetched (YYYY-MM-DD).\n rates:\n $ref: '#/components/schemas/HistoricalCommodityRates'\n unresolved:\n type: object\n description: Present only on a 206 Partial Content response, when some requested symbols could not be resolved. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n description: Historical commodity prices response containing success status, date, and OHLC rate data.\n HistoricalCommodityRates:\n type: object\n description: Object of commodity symbols to their OHLC price data. Each key is a commodity symbol and the value contains date, open, high, low, and close prices.\n properties:\n symbol:\n $ref: '#/components/schemas/HistoricalCommodityRate'\n required:\n - symbol\n HistoricalCommodityRate:\n type: object\n description: OHLC price data for a single commodity on a specific date. For monthly-updated commodities, only `close` is meaningful \u2014 `open`, `high`, and `low` are returned as `0`.\n required:\n - date\n - open\n - high\n - low\n - close\n properties:\n date:\n type: string\n description: Date for which prices were fetched (YYYY-MM-DD). May differ from the requested `date` when the API falls back to the last available rate before it, or snaps to the first day of the month for monthly-updated commodities.\n open:\n type: number\n format: float\n description: Opening price on the given date. `0` for monthly-updated commodities.\n high:\n type: number\n format: float\n description: Highest price recorded on the given date. `0` for monthly-updated commodities.\n low:\n type: number\n format: float\n description: Lowest price recorded on the given date. `0` for monthly-updated commodities.\n close:\n type: number\n format: float\n description: Closing price on the given date.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors populate status; commodity-service errors (date/symbol/rate validation) populate code instead \u2014 check whichever is present.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type (e.g., Invalid Param Exception, VALIDATION_ERROR, SYMBOL_NOT_FOUND, RATE_NOT_FOUND).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (commodity-service errors) that produced the error.\n status:\n type: integer\n description: HTTP status code. Present on gateway-level errors.\n code:\n type: integer\n description: HTTP status code. Present on commodity-service errors instead of status.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n unresolved:\n type: object\n description: Present only on SYMBOL_NOT_FOUND errors. Map of each unresolved symbol to a detail message and optional close-match suggestions.\n additionalProperties:\n type: object\n properties:\n message:\n type: string\n description: Detail message explaining why this symbol was not resolved.\n suggestions:\n type: array\n description: Optional list of supported symbols that closely match the unresolved symbol.\n items:\n type: string\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50134
50163
|
"currency-converter": "openapi: 3.1.1\ninfo:\n title: Currency Converter API - Convert 970+ Fiat & Crypto Currencies at Live or Historical Rates\n version: 1.0.0\n description: Convert an amount from one currency to another using the latest exchange rates. Supports fiat, crypto, and metals. Specify source currency, target currency, and amount to receive the current rate and converted amount with timestamp. All parameters are case-insensitive for both fiat/currency codes and crypto/symbols.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v1.0\n description: Currency Converter API Server\npaths:\n /currency/converter/latest/prices:\n get:\n tags:\n - Currency APIs\n summary: Convert currency with latest rates\n description: Converts an amount from one currency to another using the latest exchange rates.\n operationId: convertLatest\n parameters:\n - name: format\n in: query\n required: false\n description: 'Response format: `json` (default) or `xml`.'\n schema:\n type: string\n enum:\n - json\n - xml\n default: json\n - name: from\n in: query\n required: true\n description: Source currency code.\n schema:\n type: string\n - name: to\n in: query\n required: true\n description: Target currency code.\n schema:\n type: string\n - name: amount\n in: query\n required: false\n description: Amount to convert, as a decimal. Defaults to `1`. Must be numeric \u2014 non-numeric values return a 400 (negative values are accepted despite the error message's wording).\n schema:\n type: string\n default: '1'\n - name: updates\n in: query\n required: false\n description: 'Update frequency: `1m` (default), `10m`, `1h`, or `1d`.'\n schema:\n type: string\n enum:\n - 1m\n - 10m\n - 1h\n - 1d\n default: 1m\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/LatestCurrencyConverterResponse'\n examples:\n success:\n summary: Successful response\n value:\n date: '2026-07-27 12:05:00+00'\n from: USD\n to: EUR\n rate: '0.87800'\n givenAmount: '100.0'\n convertedAmount: '87.800'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad request - Invalid amount or updates parameter\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingParams:\n summary: Missing required from/to parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v1.0/currency/converter/latest/prices\n status: 400\n timestamp: '2026-07-27T12:05:29.609Z'\n invalidAmount:\n summary: amount is not numeric\n value:\n timestamp: 1785153941995\n status: 400\n error: Method Argument Type Mismatch\n message: Invalid Amount. Please provide amount in decimal format and greater than 0!\n path: /v2.0/convert/latest\n invalidUpdates:\n summary: updates is not one of 1m/10m/1h/1d\n value:\n timestamp: 1785153942533\n status: 400\n error: Invalid Param Exception\n message: Please provide valid updates parameter (1d,1h,10m,1m)\n path: /v2.0/convert/latest\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - Currency not available\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n invalidBase:\n summary: from currency not supported\n value:\n timestamp: 1785153930704\n status: 404\n error: Not Found Exception\n message: Rates of provided currency ZZZ are not available in our database!\n path: /v2.0/convert/latest\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n LatestCurrencyConverterResponse:\n type: object\n required:\n - date\n - from\n - to\n - rate\n - givenAmount\n - convertedAmount\n properties:\n date:\n type: string\n description: Date and time with timezone (UTC) when the rate was recorded.\n from:\n type: string\n description: Source currency code.\n to:\n type: string\n description: Target currency code.\n rate:\n type: string\n description: Conversion rate from source to target currency.\n givenAmount:\n type: string\n description: The amount provided for conversion.\n convertedAmount:\n type: string\n description: The converted amount in the target currency.\n description: Currency conversion response containing the exchange rate and converted amount.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors use an ISO 8601 timestamp and the public endpoint path; currency-service errors use a Unix millisecond timestamp and an internal service path instead.\n required:\n - message\n properties:\n timestamp:\n type:\n - string\n - integer\n description: Timestamp when the error occurred \u2014 ISO 8601 string for gateway errors, Unix milliseconds integer for currency-service errors.\n status:\n type: integer\n description: HTTP status code returned with the error.\n error:\n type: string\n description: Specific error type (e.g., Invalid Param Exception, Method Argument Type Mismatch, Not Found Exception).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (currency-service errors) that produced the error.\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50135
50164
|
"currency-fluctuation": "openapi: 3.1.1\ninfo:\n title: Currency Fluctuation API - Get Currency Fluctuations Over a Time Period\n version: 1.0.0\n description: Get exchange rate fluctuation data between two dates for one or more currency pairs. Returns the start rate, end rate, absolute change, and percentage change for each requested symbol. Accepts a base currency (defaults to USD) and optional comma-separated target symbols. Returns a 400 error for invalid dates and a 404 error when no data is available for the interval.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v1.0\n description: Currency Fluctuation API Server\npaths:\n /currency/fluctuation:\n get:\n tags:\n - Currency APIs\n summary: Get exchange rate fluctuations\n description: Returns exchange rate fluctuations between two dates for the requested symbols.\n operationId: getFluctuation\n parameters:\n - name: format\n in: query\n required: false\n description: 'Response format: `json` (default) or `xml`.'\n schema:\n type: string\n enum:\n - json\n - xml\n default: json\n - name: startDate\n in: query\n required: true\n description: Start date in `YYYY-MM-DD` format.\n schema:\n type: string\n - name: endDate\n in: query\n required: false\n description: End date in `YYYY-MM-DD` format. Defaults to yesterday.\n schema:\n type: string\n - name: base\n in: query\n required: false\n description: Base currency code. Defaults to `USD`.\n schema:\n type: string\n default: USD\n - name: symbols\n in: query\n required: false\n description: Comma-separated currency codes. Omit to get all available rates.\n schema:\n type: string\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/CurrencyFluctuationResponse'\n examples:\n success:\n summary: Successful response\n value:\n startDate: '2025-01-01'\n endDate: '2025-01-10'\n base: USD\n rateFluctuations:\n EUR:\n startRate: '0.96605'\n endRate: '0.97620'\n change: '-0.010150'\n percentChange: '-1.05'\n PKR:\n startRate: '278.400'\n endRate: '278.650'\n change: '-0.25'\n percentChange: '-0.09'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '400':\n description: Bad request - Invalid dates\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n missingStartDate:\n summary: Missing required startDate parameter\n value:\n error: Invalid Param Exception\n message: please pass correct parameters\n path: /v1.0/currency/fluctuation\n status: 400\n timestamp: '2026-07-27T12:09:21.348Z'\n startAfterEnd:\n summary: startDate is after endDate or the current date\n value:\n timestamp: 1785154172736\n status: 400\n error: Invalid Param Exception\n message: Starting date cannot be after current date or ending date\n path: /v2.0/fluctuation\n invalidDateFormat:\n summary: startDate/endDate not in YYYY-MM-DD format\n value:\n timestamp: 1785154172225\n status: 400\n error: Invalid Param Exception\n message: Provided Dates are in Invalid Format. Dates must be in a valid format YYYY-MM-DD!\n path: /v2.0/fluctuation\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '404':\n description: Not found - No data for interval\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n noData:\n summary: base or symbols not supported for the given interval\n value:\n timestamp: 1785154173332\n status: 404\n error: Not Found Exception\n message: Rates of provided base and symbols are not found for given intervals.\n path: /v2.0/fluctuation\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n CurrencyFluctuationResponse:\n type: object\n required:\n - startDate\n - endDate\n - base\n - rateFluctuations\n properties:\n startDate:\n type: string\n description: Start date of the interval (YYYY-MM-DD).\n endDate:\n type: string\n description: End date of the interval (YYYY-MM-DD).\n base:\n type: string\n description: Base currency used for all fluctuations.\n rateFluctuations:\n type: object\n description: Map of currency codes to their fluctuation details. Each key is a currency code and the value contains startRate, endRate, change, and percentChange.\n additionalProperties:\n title: CurrencyFluctuationItem\n $ref: '#/components/schemas/CurrencyFluctuationItem'\n description: Currency fluctuation response containing rate changes per symbol over a date interval.\n CurrencyFluctuationItem:\n type: object\n description: Fluctuation metrics for a single currency over a date interval.\n required:\n - startRate\n - endRate\n - change\n - percentChange\n properties:\n startRate:\n type: string\n description: Rate of the currency at the start of the interval.\n endRate:\n type: string\n description: Rate of the currency at the end of the interval.\n change:\n type: string\n description: Absolute change between start and end rate. Can be positive or negative.\n percentChange:\n type: string\n description: Percentage change between start and end rate. Can be positive or negative.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests. Gateway-level validation errors use an ISO 8601 timestamp and the public endpoint path; currency-service errors use a Unix millisecond timestamp and an internal service path instead.\n required:\n - message\n properties:\n timestamp:\n type:\n - string\n - integer\n description: Timestamp when the error occurred \u2014 ISO 8601 string for gateway errors, Unix milliseconds integer for currency-service errors.\n status:\n type: integer\n description: HTTP status code returned with the error.\n error:\n type: string\n description: Specific error type (e.g., Invalid Param Exception, Not Found Exception).\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path (gateway errors) or internal service path (currency-service errors) that produced the error.\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|
|
50136
50165
|
"currency-historical-data-limit": "openapi: 3.1.1\ninfo:\n title: Currency Historical Data Limits API Reference\n version: 1.0.0\n description: Retrieve the date range for which historical exchange rate data is available for each supported currency. Returns a map of currency codes to their availability period in YYYY-MM-DD to YYYY-MM-DD format. Covers fiat currencies, cryptocurrencies, and precious metals.\n contact:\n name: APIFreaks Support\n url: https://apifreaks.com/contact\n email: support@apifreaks.com\nservers:\n - url: https://api.apifreaks.com/v1.0\n description: Currency Historical Data Limits API Server\npaths:\n /currency/historical/data/limits:\n get:\n tags:\n - Currency APIs\n summary: Get historical data availability limits\n description: Returns the date range when historical data is available for each currency.\n operationId: getHistoricalDataLimits\n parameters:\n - name: format\n in: query\n required: false\n description: 'Response format: `json` (default) or `xml`.'\n schema:\n type: string\n enum:\n - json\n - xml\n default: json\n responses:\n '200':\n description: Successful operation\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/HistoricalDataLimitsResponse'\n examples:\n success:\n summary: Successful response\n value:\n availabilityPeriod:\n FJD: 1989-08-18 to 2026-07-27\n SCR: 1998-07-31 to 2026-07-27\n STPT: 2025-02-27 to 2025-05-28\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\n '406':\n description: Unsupported Media Type \u2014 format is not json or xml\n content:\n application/json:\n schema:\n $ref: '#/components/schemas/ErrorResponse'\n examples:\n badFormat:\n summary: format value not supported\n value:\n error: Unsupported Media Type\n message: The media type specified in the request is not supported. For more details, please refer to the API documentation.\n path: /v1.0/currency/historical/data/limits\n status: 406\n timestamp: '2026-07-27T12:14:01.189Z'\n headers:\n X-AF-Credits-Cost:\n $ref: '#/components/headers/X-AF-Credits-Cost'\ncomponents:\n securitySchemes:\n ApiKeyAuthHeader:\n type: apiKey\n in: header\n name: X-apiKey\n description: Pass your API key via the X-apiKey request header.\n ApiKeyAuthQuery:\n type: apiKey\n in: query\n name: apiKey\n description: Pass your API key via the apiKey query parameter.\n schemas:\n HistoricalDataLimitsResponse:\n type: object\n required:\n - availabilityPeriod\n properties:\n availabilityPeriod:\n type: object\n description: Map of currency codes to their historical data availability range. Each key is a currency code and the value is a date range string.\n additionalProperties:\n title: AvailabilityPeriodString\n type: string\n description: Historical data availability date range in YYYY-MM-DD to YYYY-MM-DD format.\n description: Historical data limits response containing the availability period map.\n ErrorResponse:\n type: object\n description: Standard error envelope returned by the API on failed requests.\n required:\n - message\n properties:\n error:\n type: string\n description: Short error category or exception type.\n message:\n type: string\n description: Human-readable error message describing the failure.\n path:\n type: string\n description: API endpoint path that produced the error.\n status:\n type: integer\n description: HTTP status code returned with the error.\n timestamp:\n type: string\n format: date-time\n description: Timestamp when the error occurred (ISO 8601).\n headers:\n X-AF-Credits-Cost:\n description: Specifies the number of credits consumed by the current request.\n schema:\n type: integer\nsecurity:\n - ApiKeyAuthHeader: []\n - ApiKeyAuthQuery: []\n",
|