Skip to main content
Glama

Sam Get Opportunity

sam_get_opportunity
Read-onlyIdempotent

Get full details for a federal contract opportunity by solicitation number. Returns description, contact info, deadlines, attachments, NAICS codes, and set-aside status — the fields sam_search_opportunities does not carry. SAM.gov searches a posting-date range and caps it at one year: we resolve the solicitation's posting date automatically where we can and otherwise search the last year, so pass posted_from/posted_to only for an older solicitation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
_apiKeyYesSAM.gov API key — required. Free at https://sam.gov/content/entity-information; a key on an account with a SAM.gov role allows 1,000 requests/day.
posted_toNoOptional MM/DD/YYYY end of the posting-date window
posted_fromNoOptional MM/DD/YYYY start of the posting-date window; only needed for a solicitation older than a year
solicitation_numberYesThe solicitation number to look up (e.g., "N6133126R3101")

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
typeNoProcurement type
titleNoOpportunity title
activeNoActive status indicator
officeNoProcuring office name
ui_linkNoURL to opportunity details on SAM.gov
sub_tierNoSub-tier agency code
set_asideNoSmall business set-aside type if applicable
departmentNoProcuring department/agency
naics_codeNoPrimary NAICS code
descriptionNoFull opportunity description
posted_dateNoDate opportunity was posted
archive_dateNoArchive date if applicable
archive_typeNoArchive type if applicable
resource_linksNoURLs to opportunity documents and resources
point_of_contactNoList of points of contact for the opportunity
organization_typeNoType of procuring organization
response_deadlineNoProposal response deadline
classification_codeNoClassification code
solicitation_numberNoUnique solicitation identifier

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / _apiKey / description
      Previous value: -"SAM.gov API key"New value: +"SAM.gov API key — required. Free at https://sam.gov/content/entity-information; a key on an account with a SAM.gov role allows 1,000 requests/day."
  2. Changed4 schema fields changed
    • changedInput schema / examples
      Previous value: -[
      -  {
      -    "_apiKey": "your-samgov-api-key",
      -    "solicitation_number": "W912DY-24-R-0001"
      -  }
      -]New value: +[
      +  {
      +    "_apiKey": "your-samgov-api-key",
      +    "solicitation_number": "N6133126R3101"
      +  }
      +]
    • addedInput schema / properties / posted_from
      Added value: +{
      +  "description": "Optional MM/DD/YYYY start of the posting-date window; only needed for a solicitation older than a year",
      +  "type": "string"
      +}
    • addedInput schema / properties / posted_to
      Added value: +{
      +  "description": "Optional MM/DD/YYYY end of the posting-date window",
      +  "type": "string"
      +}
    • changedInput schema / properties / solicitation_number / description
      Previous value: -"The solicitation number to look up (e.g., \"W912DY-24-R-0001\")"New value: +"The solicitation number to look up (e.g., \"N6133126R3101\")"
  3. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "active": {
      +      "description": "Active status indicator",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "archive_date": {
      +      "description": "Archive date if applicable",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "archive_type": {
      +      "description": "Archive type if applicable",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "classification_code": {
      +      "description": "Classification code",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "department": {
      +      "description": "Procuring department/agency",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "description": {
      +      "description": "Full opportunity description",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "naics_code": {
      +      "description": "Primary NAICS code",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "office": {
      +      "description": "Procuring office name",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "organization_type": {
      +      "description": "Type of procuring organization",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "point_of_contact": {
      +      "description": "List of points of contact for the opportunity",
      +      "items": {
      +        "properties": {
      +          "email": {
      +            "description": "Contact email address",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "name": {
      +            "description": "Contact person full name",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "phone": {
      +            "description": "Contact phone number",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "title": {
      +            "description": "Contact person title",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "type": {
      +            "description": "Contact type designation",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "posted_date": {
      +      "description": "Date opportunity was posted",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "resource_links": {
      +      "description": "URLs to opportunity documents and resources",
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "response_deadline": {
      +      "description": "Proposal response deadline",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "set_aside": {
      +      "description": "Small business set-aside type if applicable",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "solicitation_number": {
      +      "description": "Unique solicitation identifier",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "sub_tier": {
      +      "description": "Sub-tier agency code",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "title": {
      +      "description": "Opportunity title",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "type": {
      +      "description": "Procurement type",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "ui_link": {
      +      "description": "URL to opportunity details on SAM.gov",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    }
      +  },
      +  "type": "object"
      +}
  4. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "_apiKey": "your-samgov-api-key",
      +    "solicitation_number": "W912DY-24-R-0001"
      +  }
      +]
  5. First observed

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already declare the operation read-only, idempotent, non-destructive, and open-world. The description adds meaningful behavior beyond those flags: it reveals the automatic posting-date resolution, the fallback to a one-year search window, and the full set of returned fields. This is more than a bare restatement, though the safety profile remains mostly annotation-driven.

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

Conciseness5/5

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

The description is two focused sentences: the first states what the tool does and returns, and the second explains the date-range caveat and parameter usage. Every sentence carries operational value, the critical differentiating details are front-loaded, and there is no redundant restatement of the name or schema.

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?

With a full output schema, complete parameter documentation, and annotations covering safety, the description provides the missing contextual pieces: sibling differentiation, return-field expectations, and the SAM.gov date-window workaround. Nothing an agent needs to invoke the tool correctly is left unexplained.

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

Parameters4/5

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

The input schema already documents all four parameters at 100% coverage, so the baseline is 3. The description adds value by explaining the functional relationship between posted_from/posted_to and the automatic date resolution, noting they are only needed for solicitations older than a year. That goes beyond the schema's MM/DD/YYYY placeholder and justifies slightly above baseline.

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: 'Get full details for a federal contract opportunity by solicitation number.' It enumerates the returned fields and explicitly contrasts them with 'the fields sam_search_opportunities does not carry,' which distinguishes it from its closest sibling without needing to inspect schemas.

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 names sam_search_opportunities as the alternative that lacks the detailed fields, so an agent can choose between lookup-by-number and search. It also gives explicit date-parameter guidance: SAM.gov's one-year cap, automatic posting-date resolution, and the instruction to pass posted_from/posted_to 'only for an older solicitation,' which is a clear when-not-to-use constraint.

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.