Skip to content

Function tool use cases

These are lookups a trade desk asks for in the middle of a story. Jo calls the API, then writes from what came back. Publishing the finished piece is still an integration or a CMS connection.

Start with one tool on one template. Put the constraint in the description: the format of the argument, and what Jo should do when the API returns nothing.

Biotech and pharma desks use this when a story needs trials for a condition, a sponsor, or a phase, and the reporter should not be typing them in from memory.

ClinicalTrials.gov serves a public studies API. No key.

Method GET
Endpoint https://clinicaltrials.gov/api/v2/studies?pageSize=5
Auth None
Parameter searchTerm, string, Send as Query, Destination query.term

pageSize=5 stays on the URL so a broad search cannot dump the whole registry into the draft.

Search ClinicalTrials.gov for the condition, sponsor, or NCT number in the assignment.
Pass that text as searchTerm. Return the NCT ID, brief title, sponsor, phase, and overall status.
If nothing matches, say so. Do not invent a trial.

A follow-up tool can hit the FDA. openFDA’s drug and device enforcement endpoints are also public, with Auth set to None. The parameter is a search query. A drug-recall description can tell Jo to pass the brand or the recalling firm, and to return the recall status, classification, and reason.

Accounting, finance, REIT, and public-company manufacturing desks use this for the latest form type and filing date. The SEC company submissions API is public. It expects a 10-digit CIK in the path, zero-padded, and a User-Agent header that names your newsroom and a contact email. Add that header under Headers. It is not a secret.

Method GET
Endpoint https://data.sec.gov/submissions/CIK{cik}.json
Auth None
Parameter cik, string, Send as Path, required
Look up recent SEC filings for a public company.
Pass cik as 10 digits, zero-padded, such as 0000320193.
Return the company name, tickers, and the most recent filings with form type and filing date.
If the CIK is missing, ask for it. Do not guess a filing date.

Ticker-to-CIK can be a second small tool, or a line in the template that already knows the CIK. This endpoint does not accept a ticker in the path.

Every vertical has a docket. Regulations.gov takes an API key in the X-Api-Key header, which is the form’s API key (header) auth. Set Header name to X-Api-Key.

Point the endpoint at their documents search. Map one string parameter to the search query their current docs specify (today that destination is filter[searchTerm]). Confirm the name when you create the key. Filter names on that API do change.

Search federal dockets for proposed rules and notices that mention the chemical, device, standard, or industry term in the assignment.
Return the document title, agency, posted date, and comment deadline.
Skip closed dockets unless the assignment asks for them.

Leave Discover feeds off unless every feed in the organization should be able to run this search. Otherwise enable it on the regulatory template only.

This is the lookup readers cannot get from the public web: last year’s ranking, a salary survey figure, the plants you track, the directory entry for a private company.

Your research or data team exposes a small HTTPS endpoint. You already know the path. A typical shape:

Method GET
Endpoint https://data.yournewsroom.com/rankings/{companySlug}
Auth Bearer token, or an API key header
Parameter companySlug or companyName, string

Fields to return keeps the model on the figure you stand behind, such as revenue, rank, and year. Leave the rest of the row out.

Look up this company in our annual ranking database.
Pass the company name in companyName.
Use only the revenue, rank, and year the tool returns, and name the list and the year in the sentence.
If the company is not in the list, say it is not ranked. Do not estimate revenue.

The same pattern covers a plant directory, an event roster, or a subscriber file your organization already serves over HTTPS. It does not replace content fetching, which searches stories you have already published.

Use this when a vendor you already pay gives you three things: an HTTPS URL, a method, and a bearer token or an API-key header.

The assignment is the same shape as the in-house database.

  • A commercial real estate desk asks a listings service for recent sales in one submarket
  • An accounting desk asks a guidance product for the current interpretation of a standard
  • A manufacturing desk asks a pricing feed for a commodity or a component

Map one or two parameters (the submarket, the standard number, the commodity code). Set Fields to return to the numbers the story is allowed to cite.

If the product only offers a website login or a nightly file, this tool cannot call it. Ask the vendor for a REST endpoint. Many terminal products do not have one.

Manufacturing and healthcare trades that cover procurement use USAspending to check what a contractor received. Their award search is a POST with a nested JSON body, so the guided parameter rows are a poor fit. Turn on Advanced, paste their body template, and use {{recipientName}} where the company name goes. Auth is None. The API reference on USAspending has the current filter fields.

Look up federal awards for the company named in the assignment.
Pass the company name as recipientName.
Return the recipient, awarding agency, award amount, and period of performance.
If several recipients match, list the closest names and do not pick one.
  1. Create the function tool with the description above, edited for your beat.
  2. Read the Outbound request (preview) and confirm the URL.
  3. Turn it on for a single template.
  4. Run one assignment that should call it, and check that Jo cited the payload instead of filling the gap.