# 2s Gov Entity Lookup (SAM.gov)

> 2s Gov Entity Lookup (SAM.gov) is a paid API for AI agents from 2s.io, paid per call via x402, $0.0018/call, status unknown (last checked 2026-09-16).

Looks up US government contractor entity records from SAM.gov by UEI, CAGE code, or legal business name

## Facts

- Endpoint: GET https://2s.io/api/gov/entity
- Price: $0.0018/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/2s-gov-entity-lookup-sam-gov-3cc6ed44
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_8mYpSH9RLtl5lV_KiqxUx

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 2s-gov-entity-lookup-sam-gov-3cc6ed44
```

Example prompt: Can you look up the SAM.gov registration for 'Booz Allen Hamilton' — I need their UEI SAM number, CAGE code, registration status, and whether they have any active exclusions?

## When to prefer this

Use this endpoint when you need authoritative, ground-truth US government contractor entity data directly from SAM.gov without setting up API keys or signing up for a developer account. Ideal for verifying vendor SAM registration status, checking active exclusions before contract award, or enriching procurement workflows with official entity data. Prefer this over scraping SAM.gov directly or using stale third-party databases when freshness and official provenance matter.

## Known failure modes

- No matching entities found for the given query parameters — returns empty items array
- Invalid UEI SAM format (must be exactly 12 characters) — schema validation error
- Invalid CAGE code length (must be 3–10 characters) — schema validation error
- Payment failure via x402 protocol — 402 response returned
- Rate limiting or upstream SAM.gov API unavailability — upstream error propagated
- Query too broad returning truncated results — use limit parameter to control

## How this service works

Look up entities registered to do business with the US federal government in SAM.gov. Search by ueiSAM (12-char Unique Entity ID), cageCode, or legalBusinessName (provide at least one); page with limit (1-100). Returns each entity with its UEI, CAGE code, legal and DBA name, SAM registration status and dates (registration, expiration, last update), purpose of registration, an active-exclusion flag, physical address, and business types — plus a total match count. Data: SAM.gov entity management, free and public-domain (registration core data; sensitive FOUO sections are not returned). The canonical federal counterparty identity key — pair with /api/gov/exclusions (debarment) and /api/law/sanctions-check (OFAC) for full counterparty due diligence.

## Output

Returns an array of matching government entity records from SAM.gov, each containing the UEI SAM identifier, CAGE code, legal business name, DBA name, SAM registration status, registration and expiration dates, last update date, purpose of registration, active exclusion flag, physical address (city, state, zip, country), and business type classifications. Also includes total match count and data source/license information.

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "limit": 10,
   "legalBusinessName": "Booz Allen Hamilton"
  }
 }
}
```

## 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",
    "queryParams"
   ],
   "properties": {
    "type": {
     "const": "http"
    },
    "method": {
     "const": "GET"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "limit": {
       "type": "integer",
       "default": 10,
       "maximum": 100,
       "minimum": 1
      },
      "ueiSAM": {
       "type": "string",
       "maxLength": 12,
       "minLength": 12
      },
      "cageCode": {
       "type": "string",
       "maxLength": 10,
       "minLength": 3
      },
      "legalBusinessName": {
       "type": "string",
       "maxLength": 200,
       "minLength": 2
      }
     },
     "additionalProperties": false
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/2s-gov-entity-lookup-sam-gov-3cc6ed44/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 2s.io](https://www.zero.xyz/host/2s.io/llms.txt)
