Skip to content

For developers & agents

BABA determinations, callable by an agent

Estimating software or an autonomous compliance agent mid-task needs to know whether a bill of materials meets the funding agency's domestic-content standard, line by line, with a citation it can show its user. Sourceory exposes the same engine behind the site as a REST API and a hosted MCP server, so an agent calls a tool instead of guessing at a threshold.

Quickstart

No key, no signup, one call

Every endpoint works at the anonymous rate with no key. Run a bill of materials and get every line back with its verdict, the domestic-content percentage, and the source behind the rule.

request

curl -X POST https://sourceory.com/api/v1/determine \
  -H "Content-Type: application/json" \
  -d '{"agencySlug":"fhwa","lines":[{"component":"steel girder","category":"iron_steel","cost":120000,"allManufacturingInUS":true},{"component":"control panel","category":"manufactured_product","cost":40000,"manufacturedInUS":true,"domesticComponentCost":18000}]}'

response 200

{
  "data": {
    "input": {
      "agencySlug": "fhwa",
      "lines": [
        {
          "component": "steel girder",
          "category": "iron_steel",
          "cost": 120000,
          "allManufacturingInUS": true
        },
        {
          "component": "control panel",
          "category": "manufactured_product",
          "cost": 40000,
          "manufacturedInUS": true,
          "domesticComponentCost": 18000
        }
      ]
    },
    "agency": {
      "slug": "fhwa",
      "name": "FHWA",
      "program": "Federal-aid highway program"
    },
    "findings": [
      {
        "lineIndex": 0,
        "component": "steel girder",
        "category": "iron_steel",
        "verdict": "compliant",
        "domesticContentPct": null,
        "thresholdPct": null,
        "summary": "Iron & steel: all manufacturing in the US. Compliant.",
        "rule": "All iron and steel used in the project must be produced in the United States, meaning all manufacturing processes from the initial melting stage through the application of coatings occurred in the United States.",
        "remedy": "",
        "citation": {
          "source": "OMB M-24-02 government-wide baseline, applied by FHWA",
          "url": "https://www.whitehouse.gov/wp-content/uploads/2023/10/M-24-02-Buy-America-Implementation-Guidance-Update.pdf",
          "retrievedAt": "2026-07-21",
          "confidence": "verified"
        }
      },
      {
        "lineIndex": 1,
        "component": "control panel",
        "category": "manufactured_product",
        "verdict": "compliant",
        "domesticContentPct": null,
        "thresholdPct": null,
        "summary": "Manufactured product assembled in the US. Compliant: no component-cost test applies at this obligation date.",
        "rule": "A manufactured product permanently incorporated into the project must be manufactured in the United States (the final assembly requirement). The 55 percent domestic component-cost test does not apply to projects obligated before October 1, 2026.",
        "remedy": "",
        "citation": {
          "source": "FHWA Q&As on the Buy America Final Rule for Manufactured Products (89 FR, final rule published January 14, 2025)",
          "url": "https://www.fhwa.dot.gov/construction/contracts/pdfs/Manuf_Products_QA_FINAL_RULE_Doc1.pdf",
          "retrievedAt": "2026-08-02",
          "confidence": "verified"
        }
      }
    ],
    "summary": {
      "totalLines": 2,
      "compliant": 2,
      "nonCompliant": 0,
      "waiverEligible": 0,
      "insufficientData": 0,
      "totalCost": 160000,
      "projectDomesticContentPct": 100,
      "compliantOverall": true
    },
    "deMinimis": {
      "applies": false,
      "nonCompliantCost": 0,
      "excludedCost": 0,
      "applicableCost": 160000,
      "capUsd": 8000,
      "pctOfApplicableCost": 5,
      "maxUsd": 1000000,
      "note": "No non-compliant material, so the de minimis test does not arise. The cap would be $8,000.",
      "citation": {
        "source": "FHWA Buy America Construction Program Guide",
        "url": "https://www.fhwa.dot.gov/construction/cqit/buyam.cfm",
        "retrievedAt": "2026-08-02",
        "confidence": "verified"
      }
    },
    "standardsAsOf": {
      "date": "2026-08-02",
      "suppliedByCaller": false,
      "upcomingChange": {
        "category": "manufactured_product",
        "from": "2026-10-01",
        "statement": "A manufactured product must meet the final assembly requirement AND the cost of its components that are mined, produced, or manufactured in the United States must be greater than 55 percent of the total cost of all components."
      }
    },
    "coverage": {
      "agenciesLoaded": 4,
      "waiverCategoriesLoaded": 5,
      "note": "Determinations run against 4 funding agencies and 5 waiver categories currently loaded. BABA covers more than 60 federal financial-assistance programs; where an agency is not loaded, request it rather than assuming its standard matches another agency's."
    }
  },
  "request_id": "req_2f9c41a7b0e84d15",
  "disclaimer": "Sourceory provides Build America, Buy America compliance guidance based on published OMB and agency sources. It is not legal advice and not an official agency determination or waiver. BABA guidance and waivers are updated over time and are fact-specific. Always confirm against the funding agency's current guidance and your grant terms before certifying compliance or applying for a waiver."
}

Note the citation and verdict on every finding, and that an agency we do not hold returns insufficient_data rather than a silent pass. See the full API reference for the citation shape, error codes and the hosted MCP endpoint at https://sourceory.com/api/mcp.

Built for agents

What an agent actually needs from this API

One engine behind everything

The REST API, the MCP server and the free browser calculator all run the same pure, dependency-free determination engine. There is no separate ingestion path to drift, and no verdict is ever returned without the citation it came from.

A citation and a confidence on every value

Each threshold and waiver carries a source URL and a confidence flag: "verified" was read directly off the cited OMB or agency page, "verify" renders as Unverified so your agent never repeats an unconfirmed value as if it were settled fact.

Single-key auth

One key unlocks the REST API and the MCP server. Send Authorization: Bearer <your-api-key>, live or test. No OAuth dance, no per-endpoint credentials.

Machine-readable docs

A full reference and a spec at /api/openapi, so an agent can onboard itself without a human reading a page first.

Deterministic, no model in the path

Every response is a lookup against cited OMB/agency data plus deterministic arithmetic. The same bill of materials always returns the same verdict, and insufficient_data means not determined, never a pass, so an agent cannot mistake absence of guidance for a compliant project.

Free to try, safe by default

Every endpoint works with no key, throttled to 4/min and 20/day per IP. A free test key raises that to 10/min against the real engine and never bills, so an agent loop cannot run up a surprise charge while you build.

REST API

Every endpoint

Base URL https://sourceory.com/api/v1. Every endpoint (determine, thresholds, waivers, pricing) is free at the anonymous rate and needs no key to try. Send `Authorization: Bearer src_live_...` (or `x-api-key`) to lift the throttle to your plan's quota. A `src_test_...` key runs the real engine, is throttled, and never bills. No endpoint is paywalled: the recurring paid features (saved history, cross-agency compare, the audit-ready record export) live in the web app and are gated there.

GET

/api/v1

Key optional

A self-describing index of the whole API surface: every endpoint with its summary and auth requirement, plus links to the OpenAPI document, the MCP server, the docs and machine-readable pricing. Start here if you are discovering this API programmatically. Free, keyless and not rate-limited.

request

curl https://sourceory.com/api/v1
POST

/api/v1/determine

Key optional

Run a Build America, Buy America (BABA) domestic-content determination on a project bill of materials for a funding agency. Deterministic: no model, so identical input always returns an identical verdict. Each line returns one of four verdicts: compliant, non_compliant (fails the standard on the facts supplied), waiver_eligible (fails the standard AND the project-level de minimis test was computed and passed, so a de minimis waiver may cover it; it must still be applied for and granted and is NOT a pass), or insufficient_data (facts supplied cannot reach a verdict, also NOT a pass). A non_compliant line may carry waiverRoutes: qualitative waiver categories whose tests turn on facts this API does not hold, offered as leads to investigate and never as findings. Iron & steel and construction materials use an all-manufacturing-in-US test; manufactured products use the US component-cost test, which is STRICTLY GREATER THAN the threshold, so a product at exactly 55.0% fails. summary.compliantOverall is true only when every line is compliant. Send asOfDate: standards phase in by project obligation date, and the date used is reported back in standardsAsOf. An agency slug we do not hold yields agency:null and insufficient_data lines rather than a guess. Supports an `Idempotency-Key` header for keyed callers: replaying the same key with the same body returns the original result rather than a second billable call, and reusing a key with a different body returns 422 rather than another project's verdict.

request

curl -X POST https://sourceory.com/api/v1/determine \
  -H "Content-Type: application/json" \
  -d '{"agencySlug":"fhwa","asOfDate":"2026-08-03","lines":[{"component":"steel girder","category":"iron_steel","cost":120000,"allManufacturingInUS":true},{"component":"control panel","category":"manufactured_product","cost":40000,"manufacturedInUS":true,"domesticComponentCost":18000}]}'
GET

/api/v1/thresholds

Key optional

The BABA domestic-content standards. With no query, the full cross-agency matrix (every loaded agency by material category). With ?agency=<slug>, that agency's three standards with the threshold, effective date and the OMB or agency citation behind each. An unknown slug returns a not_found error listing the agencies we hold, never a fabricated threshold.

request

curl "https://sourceory.com/api/v1/thresholds?agency=fhwa"
GET

/api/v1/waivers

Key optional

The BABA waiver categories. With no query, all five (public_interest, nonavailability, unreasonable_cost, de_minimis, small_grants), each with its objective test where one exists (de minimis 5% cap, unreasonable cost 25% differential) and its citation. With ?waiver=<slug>, that one category.

request

curl "https://sourceory.com/api/v1/waivers"
GET

/api/v1/pricing

Key optional

Machine-readable pricing: every plan id, its monthly price (read live from lib/plans.ts, never hardcoded), what it includes, the included monthly API-call allowance (a hard ceiling, not a meter), rate limits, and whether it grants the determination-record export. Lets an agent self-select a plan without a human reading the pricing page. Free, keyless, not rate-limited.

request

curl https://sourceory.com/api/v1/pricing

Sourceory provides Build America, Buy America compliance guidance based on published OMB and agency sources. It is not legal advice and not an official agency determination or waiver. BABA guidance and waivers are updated over time and are fact-specific. Always confirm against the funding agency's current guidance and your grant terms before certifying compliance or applying for a waiver.

Full API reference MCP server setup

A key lifts the throttle, it does not gate the data

Every endpoint is free at the anonymous rate. A test key is free on every plan, runs the real engine, and never bills, so you can build against the whole surface before you pay. A live key raises you to your plan's quota. See /api/v1/pricing for the machine-readable version.

See plans & quotas