Obtain the count of budget functions for a specific agency in a single fiscal year based on whether or not that budget function has ever been submitted in File B.

Documentation for this endpoint can be found here.

GET /api/v2/agency/012/budget_function/
HTTP 200 OK
Allow: GET, HEAD, OPTIONS
Cache-Trace: no-cache
Content-Type: application/json
Vary: Accept

{
    "toptier_code": "012",
    "fiscal_year": 2022,
    "results": [
        {
            "name": "Income Security",
            "children": [
                {
                    "name": "Food and nutrition assistance",
                    "obligated_amount": 39339450762.91,
                    "gross_outlay_amount": 1529346088.3
                },
                {
                    "name": "Housing assistance",
                    "obligated_amount": 3508751019.96,
                    "gross_outlay_amount": 560496193.41
                },
                {
                    "name": "Federal employee retirement and disability",
                    "obligated_amount": 0.0,
                    "gross_outlay_amount": 65320.56
                }
            ],
            "obligated_amount": 42848201782.87,
            "gross_outlay_amount": 2089907602.27
        },
        {
            "name": "Community and Regional Development",
            "children": [
                {
                    "name": "Area and regional development",
                    "obligated_amount": 9178470114.27,
                    "gross_outlay_amount": 587304482.84
                },
                {
                    "name": "Community development",
                    "obligated_amount": 174432826.96,
                    "gross_outlay_amount": 15975506.65
                },
                {
                    "name": "Disaster relief and insurance",
                    "obligated_amount": 622407.0,
                    "gross_outlay_amount": 1033844.19
                }
            ],
            "obligated_amount": 9353525348.23,
            "gross_outlay_amount": 604313833.68
        },
        {
            "name": "Agriculture",
            "children": [
                {
                    "name": "Farm income stabilization",
                    "obligated_amount": 7048640459.62,
                    "gross_outlay_amount": 10076368776.15
                },
                {
                    "name": "Agricultural research and services",
                    "obligated_amount": 1371899434.84,
                    "gross_outlay_amount": 1430661552.63
                }
            ],
            "obligated_amount": 8420539894.46,
            "gross_outlay_amount": 11507030328.78
        },
        {
            "name": "Natural Resources and Environment",
            "children": [
                {
                    "name": "Conservation and land management",
                    "obligated_amount": 1395921089.39,
                    "gross_outlay_amount": 2601746883.09
                },
                {
                    "name": "Recreational resources",
                    "obligated_amount": 10329674.05,
                    "gross_outlay_amount": 12160567.49
                },
                {
                    "name": "Water resources",
                    "obligated_amount": 5110115.61,
                    "gross_outlay_amount": 53226861.23
                },
                {
                    "name": "Other natural resources",
                    "obligated_amount": 116985.45,
                    "gross_outlay_amount": 594835.21
                }
            ],
            "obligated_amount": 1411477864.5,
            "gross_outlay_amount": 2667729147.02
        },
        {
            "name": "Commerce and Housing Credit",
            "children": [
                {
                    "name": "Mortgage credit",
                    "obligated_amount": 434943266.41,
                    "gross_outlay_amount": 173988940.49
                }
            ],
            "obligated_amount": 434943266.41,
            "gross_outlay_amount": 173988940.49
        },
        {
            "name": "Health",
            "children": [
                {
                    "name": "Consumer and occupational health and safety",
                    "obligated_amount": 191322667.68,
                    "gross_outlay_amount": 238746453.21
                }
            ],
            "obligated_amount": 191322667.68,
            "gross_outlay_amount": 238746453.21
        },
        {
            "name": "Energy",
            "children": [
                {
                    "name": "Energy supply",
                    "obligated_amount": 88041064.63,
                    "gross_outlay_amount": 21093414.79
                }
            ],
            "obligated_amount": 88041064.63,
            "gross_outlay_amount": 21093414.79
        },
        {
            "name": "International Affairs",
            "children": [
                {
                    "name": "International development and humanitarian assistance",
                    "obligated_amount": 74577517.77,
                    "gross_outlay_amount": 360728576.06
                }
            ],
            "obligated_amount": 74577517.77,
            "gross_outlay_amount": 360728576.06
        },
        {
            "name": "General Government",
            "children": [
                {
                    "name": "General purpose fiscal assistance",
                    "obligated_amount": 600495.28,
                    "gross_outlay_amount": 1909143.03
                }
            ],
            "obligated_amount": 600495.28,
            "gross_outlay_amount": 1909143.03
        }
    ],
    "messages": [],
    "page_metadata": {
        "page": 1,
        "total": 9,
        "limit": 10,
        "next": null,
        "previous": null,
        "hasNext": false,
        "hasPrevious": false
    }
}