How to Use FDA NDC drug listings in opencode
Returns NDC Directory listings with drug names, ingredients, dosage forms, routes, and packaging information. Use it to identify listed products and packages; an NDC number does not establish FDA approval.
Prompts to try with FDA NDC drug listings in opencode
Copy an example into opencode, or ask in your own words.
Use FDA NDC drug listings to look this up and give me the result as a table. Save the result in ./assets.
Pull the latest numbers from FDA NDC drug listings and tell me what changed since last week.
Check FDA NDC drug listings and summarize what you find in three bullet points.
Pull the newest data from FDA NDC drug listings and give me the result as a table.
Check FDA NDC drug listings every morning and tell me only when something changed.
How to set up FDA NDC drug listings in opencode
Pick the way that suits you. Each takes about two minutes.
Use Spiral's MCP server
- Add the server
Leave out --global to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
- Sign in
Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, /mcps starts the same sign-in.
opencode mcp auth spiral
- Check it
Spiral shows as connected.
opencode mcp list
Use the Spiral skill
- Send opencode this message
Your agent reads Spiral's skill and sets itself up.
set up https://spiral.ai/SKILL.md
- Sign in or paste a key
Approve Spiral in the browser, or give the agent a key from the console.
Use the Spiral CLI
- Install and sign in
Installs the Spiral CLI, signs you in and adds its skill to your coding agents.
npx -y spiral-cli@latest init
Call the Spiral API
- Create an API key
In the console, under API keys.
- Run FDA NDC drug listings
One request; the result comes back by polling or a webhook.
curl https://api.spiral.ai/v1/runs \ -H "Authorization: Bearer $SPIRAL_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "provider": "alexandria", "model": "fda-gov/records/drug_ndc", "input": { "skip": 0 } }'
Then paste one of the prompts above: opencode finds FDA NDC drug listings on Spiral, shows the price and runs it.
FDA NDC drug listings providers and prices
Spiral runs FDA NDC drug listings through Alexandria. Open a card for today's price, with every fee included.
Settings you can ask for
Ask opencode for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Skip | 0 to 25000 | 0 | skip |
| Limit | 1 to 10 | 5 | limit |
Every API field of FDA · Drug ndc is on its tool page: open its card above.
What can you do with FDA NDC drug listings in opencode?
Build a product research view that puts FDA decisions, submitted product information, and reported safety findings beside their source records. A coding agent can add the returned evidence to your project's tables while preserving application numbers, document links, and decision meanings.
Company regulatory due diligence
Build an evidence packet for a public drug or device company using its published application decisions, documents, listings, labeling, adverse event reports, and recall findings. Keep each record's regulatory meaning attached to the finding.
Internal FDA research digest
Prepare a recurring digest of newly available or changed FDA evidence for a company or product watchlist. Separate application decisions, submitted product information, reported reactions, and historical recall findings.
Product claim fact-checking
Check public claims about approval, labeling, product identity, reported adverse reactions, or recall findings against the relevant FDA records. Identify the exact passage or decision that supports each statement.
Drug catalog reconciliation
Compare a drug catalog's names, ingredients, dosage forms, routes, and packages with FDA listings. Add application references and labeling evidence without treating a listing as proof of approval.
Publication evidence archive
Assemble the FDA evidence behind a company profile, product explainer, or regulatory investigation. Preserve document links, source identifiers, dates, and the passages used so an editor can check the published account.
More on FDA NDC drug listings and opencode
Overview
FDA NDC drug listings in other agents
Questions about FDA NDC drug listings in opencode
Can opencode use FDA NDC drug listings?
Yes. Add Spiral to opencode as an MCP server, and opencode can find and run FDA NDC drug listings like any built-in tool.
How much does FDA NDC drug listings cost in opencode?
$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.
Do I need an Alexandria account to use FDA NDC drug listings in opencode?
No. Spiral runs FDA NDC drug listings on its own Alexandria account. You sign in to Spiral once and never paste a key.
How long does it take to set up FDA NDC drug listings in opencode?
About two minutes: add the server, then sign in, then check it.
Does opencode wait while FDA NDC drug listings runs?
FDA NDC drug listings runs in the background. opencode starts the run, checks on it and gives you the json when it's ready.
How fresh are FDA records?
FDA datasets follow different schedules. Application records update on weekdays, labeling updates weekly, 510(k) records update monthly, and FAERS updates quarterly with a possible lag of three months or more.
How far back does FDA's published history go?
Coverage depends on the record type: Drugs@FDA includes most products approved since 1939, 510(k) history begins in 1976, and the recall datasets begin in 2004. Supporting drug documents are more widely available for products approved since 1998.
Does appearing in an FDA database prove a product is approved?
An NDC number does not establish approval, and submitted labeling may differ from approved labeling. The CRL database also includes unapproved applications, while 510(k) records concern substantial equivalence decisions.
Are public FDA records complete and independently verified?
Public CRLs have confidential commercial information and trade secrets removed. NDC information is submitted by labelers, and adverse event reports do not establish that a product caused the reported reaction.
Can FDA data be reused in a commercial research product?
Unless otherwise noted, openFDA materials carry a CC0 1.0 dedication that permits commercial reuse. Some third-party material has separate restrictions, so the terms do not grant unrestricted rights to every included work.
Start using FDA NDC drug listings in opencode
One Spiral account for every tool your agent needs. No subscription; you pay per run.
Paste this into opencode:
set up https://spiral.ai/SKILL.md


