/v1/deficit
Federal budget deficit/surplus by month (current fiscal year)
Essayez-le en direct
10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.
Ça marche. Récupérez une clé API et utilisez-la dans votre projet.
Obtenez une clé APIExtraits de code
curl "https://api.oanor.com/usfiscal-api/v1/deficit" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/usfiscal-api/v1/deficit", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/usfiscal-api/v1/deficit");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/usfiscal-api/v1/deficit",
headers={"x-oanor-key": "oanor_test_..."}
)
Exemple de réponse
Une réponse réelle de ce endpoint, capturée lors du dernier contrôle de santé.
{
"data": {
"note": "Deficit positive = the US spent more than it took in (negative = surplus); USD. FYTD from the Year-to-Date line of the Monthly Treasury Statement.",
"months": [
{
"month": "October",
"deficit": 284332743998.37,
"outlays": 688704092972.07,
"receipts": 404371348973.7
},
{
"month": "November",
"deficit": 173277175122.92,
"outlays": 509278895279.9,
"receipts": 336001720156.98
},
{
"month": "December",
"deficit": 144752110766.43,
"outlays": 629136126305.68,
"receipts": 484384015539.25
},
{
"month": "January",
"deficit": 94615162369.21,
"outlays": 654667062952.38,
"receipts": 560051900583.17
},
{
"month": "February",
"deficit": 307501433426.17,
"outlays": 620623118673.01,
"receipts": 313121685246.84
},
{
"month": "March",
"deficit": 164100313817.86,
"outlays": 548962915853.65,
"receipts": 384862602035.79
},
{
"month": "April",
"deficit": -215024135197.77,
"outlays": 622318555795.74,
"receipts": 837342690993.51
},
{
"month": "May",
"deficit": 292648462083.74,
"outlays": 628160645311.16,
"receipts": 335512183227.42
}
],
"source": "US Treasury MTS table 1 (FiscalData)",
"fiscal_year": "2026",
"record_date": "2026-05-31",
"fytd_deficit": 1246203266386.93,
"fytd_outlays": 4901851413143.59,
"fytd_receipts": 3655648146756.66
},
"meta": {
"timestamp": "2026-06-10T22:56:36.125Z",
"request_id": "211dfb43-2c78-4370-8684-b9091df67f68"
},
"status": "ok",
"message": "Deficit retrieved successfully",
"success": true
}