# BNM Data Shop – USDA FAS GAIN Attaché Reports

> BNM Data Shop – USDA FAS GAIN Attaché Reports is a paid API for AI agents from ticks.bnm.farm, paid per call via x402, $0.05/call, status unknown (last checked 2026-10-12).

Returns USDA Foreign Agricultural Service GAIN (Global Agricultural Information Network) attaché report records and card summaries as JSON

## Facts

- Endpoint: GET https://ticks.bnm.farm/gain?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/bnm-data-shop-usda-fas-gain-attach-reports-98951b49
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_TLk2zxGSgyOfpq0a74seQ

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability bnm-data-shop-usda-fas-gain-attach-reports-98951b49
```

Example prompt: Can you pull the latest USDA FAS GAIN attaché reports as structured JSON — I want the records and card summaries including report IDs, countries, categories, and source URLs?

## When to prefer this

Choose this endpoint when you need structured, machine-readable JSON access to USDA FAS GAIN attaché reports without scraping the USDA website directly. It is the right choice for agents that need agricultural intelligence data (livestock, commodities, country-level reports) with consistent schema, card summaries, and direct PDF source links, all delivered for a flat $0.05 per call via x402 micropayment.

## Known failure modes

- HTTP 402 if payment not included — endpoint requires $0.05 USDC via x402 protocol
- Empty records array if no new reports are available for the queried period
- Stale data if upstream USDA FAS GAIN source is delayed or unavailable
- Network timeout if upstream GAIN API is slow to respond
- Malformed response if upstream source structure changes

## How this service works

Official public data as JSON. Unpaid paid routes return HTTP 402.

## Output

A JSON object with ok status, product name ('gain-attache-report-bodies'), asOf date, fetchedAt timestamp, source URL, total recordCount, an array of records (each with id, url, date, firm/country, type), and an array of cards (each with id, body excerpt, date, post, country, category, sourceUrl, reportNumber).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    },
    "queryParams": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "properties": {
    "type": {
     "type": "string"
    },
    "schema": {
     "type": "object"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "schema": {
  "type": "object",
  "required": [
   "ok",
   "product",
   "status",
   "fetchedAt",
   "asOf",
   "source",
   "recordCount",
   "records",
   "cards"
  ],
  "properties": {
   "ok": {
    "type": "boolean"
   },
   "asOf": {
    "type": "string"
   },
   "cards": {
    "type": "array",
    "items": {
     "type": "object"
    }
   },
   "source": {
    "type": "string"
   },
   "status": {
    "type": "string"
   },
   "product": {
    "type": "string"
   },
   "records": {
    "type": "array",
    "items": {
     "type": "object"
    }
   },
   "fetchedAt": {
    "type": "string"
   },
   "recordCount": {
    "type": "integer"
   }
  }
 },
 "example": {
  "ok": true,
  "asOf": "2026-08-24",
  "cards": [
   {
    "id": "MX2026-0040",
    "body": "This teaser is not an official attaché body. USDA FAS GAIN MX2026-0040 excerpt.",
    "date": "2026-08-24",
    "post": "Mexico City",
    "country": "Mexico",
    "category": "Livestock and Products",
    "sourceUrl": "https://apps.fas.usda.gov/newgainapi/api/Report/DownloadReportByFileName?fileName=Livestock%20and%20Products%20Annual_Mexico%20City_Mexico_MX2026-0040.pdf",
    "reportNumber": "MX2026-0040"
   }
  ],
  "source": "https://gain.fas.usda.gov/",
  "status": "ok",
  "product": "gain-attache-report-bodies",
  "records": [
   {
    "id": "MX2026-0040",
    "url": "https://apps.fas.usda.gov/newgainapi/api/Report/DownloadReportByFileName?fileName=Livestock%20and%20Products%20Annual_Mexico%20City_Mexico_MX2026-0040.pdf",
    "date": "2026-08-24",
    "firm": "Mexico",
    "type": "gain"
   }
  ],
  "fetchedAt": "2026-08-27T21:37:10.176Z",
  "recordCount": 1
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/bnm-data-shop-usda-fas-gain-attach-reports-98951b49/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from ticks.bnm.farm](https://www.zero.xyz/host/ticks.bnm.farm/llms.txt)
