Live release feed
Sub-second macro releases for FX backtests
Point-in-time history
Official CPI, jobs, GDP, and central-bank events with point-in-time history.
$25/month 14-day free trial
Start Free Trial
How To Use Fxmacrodata Endpoints And Authentication image
Share headline card X LinkedIn Email
Download

Implementation

How-To Guides

How To Use Fxmacrodata Endpoints And Authentication

A practical end-to-end guide to authenticating with FXMacroData, choosing the right endpoint families, and building a production-ready macro data workflow.

इसमें भी उपलब्ध है English
Share article X LinkedIn Email

इस गाइड के अंत तक आप सही तरीके से प्रमाणित करने में सक्षम होंगे, प्रत्येक कार्य के लिए सही एंडपॉइंट परिवार चुनें, और मार्ग संरचना या संकेतक कवरेज का अनुमान लगाने के बिना FXMacroData एपीआई में उत्पादन-तैयार अनुरोध करें।

पूर्व शर्तें

  • विदेशी मुद्रा विनिमय के लिए एक FXMacroData खाता और एपीआई कुंजी
  • एक टर्मिनल के साथ curl या एक रनटाइम जैसे पायथन/नोड.जेएस
  • JSON प्रतिक्रियाओं और URL क्वेरी पैरामीटर के साथ बुनियादी परिचितता
  • पर लाइव डॉक्स तक पहुँच /दस्तावेज़/

चरण 1 - उत्पादन आधार URL से प्रारंभ करें

सभी सार्वजनिक उदाहरणों को उत्पादन एपीआई आधार से शुरू करना चाहिएः

https://fxmacrodata.com/api/v1

सबसे अधिक इस्तेमाल होने वाले अंत बिंदु परिवार हैंः

  • /announcements/{currency}/{indicator} ऐतिहासिक जारी मूल्यों के लिए सटीक announcement_datetime
  • /calendar/{currency} आगामी रिलीज के समय के लिए
  • /catalogue/{currency} समर्थित संकेतकों की खोज के लिए
  • /cot/{currency} व्यापारियों की प्रतिबद्धता के लिए पोजिशनिंग
  • /commodities/{indicator} वस्तुओं और ऊर्जा श्रृंखलाओं के लिए
  • /forex/{pair} और /market-sessions बाजार के संदर्भ के लिए

चरण 2 - क्वेरी पैरामीटर के साथ सही प्रमाणीकरण

FXMacroData सार्वजनिक उपयोग उदाहरणों में क्वेरी-पैरामीटर प्रमाणीकरण का उपयोग करता हैः

?api_key=YOUR_API_KEY

USD अंत बिंदु तक पहुँच कुंजी के बिना उपलब्ध है, जबकि गैर-USD मार्गों के लिए मान्य कुंजी की आवश्यकता होती है।

# USD endpoint (no key required)
curl "https://fxmacrodata.com/api/v1/announcements/usd/inflation"

# Non-USD endpoint (key required)
curl "https://fxmacrodata.com/api/v1/announcements/aud/policy_rate?api_key=YOUR_API_KEY"

चरण 3 - कोडिंग से पहले उपलब्ध जानकारी का पता लगाएं

जब आप निश्चित नहीं हैं कि किसी मुद्रा के लिए कौन से संकेतक मौजूद हैं तो पहले कैटलॉग मार्ग को कॉल करें। इससे हार्ड-कोडिंग धारणाओं से बचा जाता है।

curl "https://fxmacrodata.com/api/v1/catalogue/eur?api_key=YOUR_API_KEY"

फिर में सूचक पृष्ठ सूचकांक का उपयोग करें प्रलेखन सूचकांक मार्ग मार्गों और अपेक्षित क्षेत्रों की पुष्टि करने के लिए।


चरण 4 - घोषणाओं के अंत बिंदुओं से जारी किए गए डेटा को खींचें

घोषणा अंत बिंदु एक शीर्ष स्तर वस्तु प्लस एक data ऐतिहासिक प्रकाशनों की एक श्रृंखला। प्रत्येक पंक्ति में एक अवधि-अंत शामिल है date, एक val, और एक announcement_datetime समय-स्टैम्प।

curl "https://fxmacrodata.com/api/v1/announcements/gbp/unemployment?api_key=YOUR_API_KEY"
{
  "currency": "GBP",
  "indicator": "unemployment",
  "has_official_forecast": false,
  "start_date": "2025-01-31",
  "end_date": "2026-03-31",
  "data": [
    {
      "date": "2026-01-31",
      "val": 4.39,
      "announcement_datetime": 1770521400
    }
  ]
}

सटीक संकेतक अर्थशास्त्र और इकाइयों के लिए, अंत बिंदु पृष्ठों की जाँच करें जैसे कि अमरीकी डालर नीतिगत दर और यूरो मुद्रास्फीति. .


चरण 5 - घटना-संचालित कार्यप्रवाहों के लिए रिलीज कैलेंडर का उपयोग करें

रिलीज कैलेंडर आपको लगातार मतदान करने के बजाय प्रकाशन समय के आसपास बुकिंग करने में मदद करता है।

curl "https://fxmacrodata.com/api/v1/calendar/usd?indicator=non_farm_payrolls"

एक मजबूत पैटर्न हैः क्वेरी कैलेंडर -> अगला पढ़ें announcement_datetime -> रिलीज के समय मेल खाने वाली घोषणाओं मार्ग को प्राप्त करें।


चरण 6 - पूरक अंतराल बिंदु परिवार जोड़ें

एक बार जब आपके मुख्य घोषणा प्रवाह स्थिर हो जाते हैं, तो डोमेन-विशिष्ट मार्गों के साथ कवरेज का विस्तार करें:

  • सीओटी: /api/v1/cot/{currency} वायदा पोजिशनिंग संदर्भ के लिए
  • धातुः /api/v1/commodities/{indicator} सोने, चांदी, प्लेटिनम और संबंधित सुरक्षित-स्थान इनपुट के लिए
  • विदेशी मुद्राः /api/v1/forex/{pair} मैक्रो रिलीज़ के साथ स्पॉट संरेखण के लिए
  • बाजार सत्रः /api/v1/market-sessions सत्र-राज्य-जागरूक स्वचालन के लिए
curl "https://fxmacrodata.com/api/v1/cot/usd"
curl "https://fxmacrodata.com/api/v1/commodities/gold"
curl "https://fxmacrodata.com/api/v1/forex/eurusd"
curl "https://fxmacrodata.com/api/v1/market-sessions"

चरण 7 - अंत से अंत तक पायथन उदाहरण

नीचे दिए गए स्निपेट उपलब्धता की जाँच करता है, एक संकेतक श्रृंखला प्राप्त करता है और नवीनतम प्रिंट देता है।

import requests

BASE = "https://fxmacrodata.com/api/v1"
API_KEY = "YOUR_API_KEY"


def fetch_latest(currency: str, indicator: str, api_key: str | None = None) -> dict | None:
    params = {}
    if api_key:
        params["api_key"] = api_key

    catalogue = requests.get(f"{BASE}/catalogue/{currency}", params=params, timeout=10)
    catalogue.raise_for_status()

    endpoint = requests.get(
        f"{BASE}/announcements/{currency}/{indicator}",
        params=params,
        timeout=10,
    )
    endpoint.raise_for_status()

    rows = endpoint.json().get("data", [])
    return rows[-1] if rows else None


latest = fetch_latest("aud", "policy_rate", API_KEY)
print(latest)

आप आगे क्या बना सकते हैं

अब आपके पास प्रमाणीकरण, कवरेज की खोज, ऐतिहासिक रिलीज श्रृंखला का अनुरोध करने और कैलेंडर-संचालित स्वचालन में विस्तार करने का पूरा मार्ग है। एक स्वाभाविक अगला कदम इस वर्कफ़्लो को रिलीज शेड्यूलर के साथ जोड़ रहा है रिलीज़ कैलेंडर एपीआई का उपयोग कैसे करें तो आपके सिस्टम ठीक प्रतिक्रिया करता है जब नए मैक्रो डेटा प्रकाशित किया जाता है।

Blogroll

AI Answer-Ready

Key Facts

Page
How To Use FXmacrodata Endpoints And Authentication
Section
Articles
Canonical URL
https://fxmacrodata.com/hi/articles/how-to-use-fxmacrodata-endpoints-and-authentication
Source
FXMacroData editorial and official publisher references
Last Updated
2026-06-15 11:01 UTC

Provenance And Trust

Cite the canonical URL and source field above. Where available, this page maps to official publisher releases and timestamped updates.

Quick Q&A

What is this page about? This page explains How To Use FXmacrodata Endpoints And Authentication with directly usable context for trading, research, and API workflows.

What source should be cited? Use the canonical URL and the listed source field; cite official publisher references when available.

How fresh is this content? The last updated value above reflects the page metadata or latest available data timestamp.

Can this be used in AI assistants? Yes. This section is intentionally structured for retrieval and citation in chat assistants.

Prompt Packs

Use these in ChatGPT, Claude, Gemini, Mistral, Perplexity, or Grok for consistent source-aware outputs.