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": 135177745203.06,
                    "gross_outlay_amount": 135418668456.18
                },
                {
                    "name": "Housing assistance",
                    "obligated_amount": 13501316713.32,
                    "gross_outlay_amount": 4389070985.17
                },
                {
                    "name": "Federal employee retirement and disability",
                    "obligated_amount": 0.0,
                    "gross_outlay_amount": 775578.67
                }
            ],
            "obligated_amount": 148679061916.38,
            "gross_outlay_amount": 139808515020.02
        },
        {
            "name": "Community and Regional Development",
            "children": [
                {
                    "name": "Area and regional development",
                    "obligated_amount": 34202447793.39,
                    "gross_outlay_amount": 3753455928.13
                },
                {
                    "name": "Community development",
                    "obligated_amount": 652503495.83,
                    "gross_outlay_amount": 135322314.8
                },
                {
                    "name": "Disaster relief and insurance",
                    "obligated_amount": 6799096.72,
                    "gross_outlay_amount": 7521134.52
                }
            ],
            "obligated_amount": 34861750385.94,
            "gross_outlay_amount": 3896299377.45
        },
        {
            "name": "Agriculture",
            "children": [
                {
                    "name": "Farm income stabilization",
                    "obligated_amount": 19775792485.12,
                    "gross_outlay_amount": 19510321321.57
                },
                {
                    "name": "Agricultural research and services",
                    "obligated_amount": 9346259651.5,
                    "gross_outlay_amount": 7983535053.35
                }
            ],
            "obligated_amount": 29122052136.62,
            "gross_outlay_amount": 27493856374.92
        },
        {
            "name": "Natural Resources and Environment",
            "children": [
                {
                    "name": "Conservation and land management",
                    "obligated_amount": 7094858352.29,
                    "gross_outlay_amount": 7783064914.15
                },
                {
                    "name": "Water resources",
                    "obligated_amount": 178308832.2,
                    "gross_outlay_amount": 169256441.5
                },
                {
                    "name": "Recreational resources",
                    "obligated_amount": 54638075.81,
                    "gross_outlay_amount": 53796317.23
                },
                {
                    "name": "Other natural resources",
                    "obligated_amount": 1428115.43,
                    "gross_outlay_amount": 2498584.87
                }
            ],
            "obligated_amount": 7329233375.73,
            "gross_outlay_amount": 8008616257.75
        },
        {
            "name": "Commerce and Housing Credit",
            "children": [
                {
                    "name": "Mortgage credit",
                    "obligated_amount": 2313364148.45,
                    "gross_outlay_amount": 1430704942.42
                }
            ],
            "obligated_amount": 2313364148.45,
            "gross_outlay_amount": 1430704942.42
        },
        {
            "name": "Energy",
            "children": [
                {
                    "name": "Energy supply",
                    "obligated_amount": 1875618270.13,
                    "gross_outlay_amount": 1632318862.87
                }
            ],
            "obligated_amount": 1875618270.13,
            "gross_outlay_amount": 1632318862.87
        },
        {
            "name": "Health",
            "children": [
                {
                    "name": "Consumer and occupational health and safety",
                    "obligated_amount": 961331622.08,
                    "gross_outlay_amount": 916636080.74
                }
            ],
            "obligated_amount": 961331622.08,
            "gross_outlay_amount": 916636080.74
        },
        {
            "name": "International Affairs",
            "children": [
                {
                    "name": "International development and humanitarian assistance",
                    "obligated_amount": 750769191.36,
                    "gross_outlay_amount": 1091617888.97
                }
            ],
            "obligated_amount": 750769191.36,
            "gross_outlay_amount": 1091617888.97
        },
        {
            "name": "General Government",
            "children": [
                {
                    "name": "General purpose fiscal assistance",
                    "obligated_amount": 252414004.23,
                    "gross_outlay_amount": 250627970.4
                }
            ],
            "obligated_amount": 252414004.23,
            "gross_outlay_amount": 250627970.4
        }
    ],
    "messages": [],
    "page_metadata": {
        "page": 1,
        "total": 9,
        "limit": 10,
        "next": null,
        "previous": null,
        "hasNext": false,
        "hasPrevious": false
    }
}