Skip to main content
Glama

lookup_piid

Read-only

Look up awards by their exact PIID, across contracts AND IDVs.

Looks for awards whose own PIID is exactly this value (the award_ids
filter), in both contracts and IDVs, and says how many share it.
match='exact' rows are the awards themselves: an IDV PIID returns the
IDV (award_type='idv'; its Award Amount is what was obligated on the IDV
record itself, usually 0, so use get_idv_amounts() for the order total).
PIIDs are not unique: task and delivery order numbers like '0001' repeat
under different parent IDVs, so check 'ambiguous' and tell matches apart
by parent_idv_piid and Awarding Agency.

Only when nothing has that exact PIID does it fall back to keyword
search, and those rows come back as match='fuzzy': keyword search
matches the award's own PIID and its description text, NOT its parent
IDV, so a vehicle PIID or prefix returns only orders whose description
happens to cite it. For the orders under a vehicle use get_idv_activity()
or get_idv_children() with the IDV's generated_internal_id; for a
contracting-office prefix (N00024, W91CRB, FA8650) use search_awards
keywords with a time window.

limit applies to contracts and to IDVs separately. Use
get_award_detail() with a returned generated_internal_id for the full
record. Handy for enriching PRISM, Contract Court, or FPDS exports where
you have a PIID but don't know whether it's a contract or IDV.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "piid": "<piid>"
    },
    "name": "lookup_piid"
  }
}

Input Schema

NameRequiredDescriptionDefault
piidYes
limitNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the read-only annotations, the description discloses important behavior: exact matches return the award itself, IDV Award Amount is usually 0 and requires get_idv_amounts(), PIIDs are not unique, ambiguous rows must be checked, and fuzzy fallback searches PIID and description text but not parent IDV PIIDs. It also states that limit applies separately to contracts and IDVs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded and every major sentence carries useful operational detail. It is somewhat dense and clause-heavy, especially around match='exact', match='fuzzy', and parent/child IDV distinctions, but the length is justified by the tool's non-obvious behavior.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the presence of an output schema, the description does not need to fully document return values, yet it still explains the critical match semantics, ambiguity handling, and IDV amount caveat. Together with the annotations, it gives an agent enough context to invoke and interpret the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must carry parameter meaning, and it does: piid is treated as an exact value first, with fuzzy fallback only when no exact match exists; limit is explicitly scoped separately to contracts and IDVs. It adds substantive semantics that the bare schema lacks.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Look up awards by their exact PIID, across contracts AND IDVs.' It distinguishes the tool from sibling search tools by emphasizing exact PIID lookup and explicitly covering both contracts and IDVs.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit when-to-use guidance for exact PIID lookup and clearly routes alternative cases to other tools: get_idv_amounts() for IDV order totals, get_idv_activity()/get_idv_children() for orders under a vehicle, and search_awards for contracting-office prefixes. It also explains the fuzzy fallback condition precisely.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.