Entities Data Dictionary¶
This document describes the fields available in the Entities API endpoints (/api/entities/). For filtering, ordering, and pagination, see the Entities API Reference.
Overview¶
Entities represent vendors and recipients in federal contracting and assistance. The canonical identifier is UEI (Unique Entity ID). Data is sourced from SAM.gov, with supplemental data from DSBS and Tango-calculated obligation metrics.
Identifiers¶
uei(canonical): Public identifier for entities and the API lookup key:GET /api/entities/{uei}/.uuid(internal): Tango's internal UUID primary key for the entity record. This is not intended as a public lookup key; other tables typically reference entities byuei.
Note: The full set of fields is available via the shape query parameter. The base response includes a subset of commonly-used fields. See Response Shaping for details.
Update Frequency¶
Entity data is updated from SAM.gov on a regular sync cadence (typically within 20–60 minutes of SAM changes). Federal obligation rollups are derived from award data.
Fields¶
| Field | Type | Description | Source |
|---|---|---|---|
uei | String | Unique Entity Identifier. Canonical identifier for the entity; use for API lookups and cross-referencing. | SAM.gov |
uuid | UUID | Internal primary key. Not intended as a public lookup key. | Tango |
display_name | String | Display name for the entity (e.g., legal name or DBA when useful). | Tango (derived) |
legal_business_name | String | Official legal business name as registered in SAM. | SAM.gov |
dba_name | String | "Doing business as" name, when different from legal name. | SAM.gov |
description | String | Entity description, when available (e.g., from DSBS). | DSBS |
cage_code | String | Commercial and Government Entity (CAGE) code. 5-character code used in defense and federal contracting. | SAM.gov |
dodaac | String | Department of Defense Activity Address Code. | SAM.gov |
registered | String | Whether the entity is registered in SAM (e.g., "Y"/"N"). | SAM.gov |
registration_status | String | Current SAM registration status (e.g., "Active"). | SAM.gov |
purpose_of_registration_code | String | Code indicating the primary purpose of SAM registration. | SAM.gov |
purpose_of_registration_desc | String | Description of the purpose of registration. | SAM.gov |
sam_registration_date | Date | Date the entity was registered in SAM. | SAM.gov |
sam_expiration_date | Date | Date the entity's SAM registration expires. | SAM.gov |
sam_activation_date | Date | Date the entity's SAM registration was activated. | SAM.gov |
last_update_date | Date | Date the entity record was last updated. | SAM.gov |
email_address | String | Primary email address on file. | SAM.gov |
entity_url | String | Entity website or profile URL, when available. | SAM.gov / DSBS |
physical_address | Object | Physical address. Expand with physical_address(*) for normalized subfields: address_line1, address_line2, city, state_or_province_code, zip_code, zip_code_plus4, country_code, country_name. Keys are always snake_case regardless of data source. | SAM.gov |
mailing_address | Object | Mailing address. Same normalized subfields as physical_address. | SAM.gov |
congressional_district | String | Congressional district (e.g., for physical location). | SAM.gov |
primary_naics | String | Primary NAICS code (6-digit). | SAM.gov |
naics_codes | Array of Objects | NAICS codes. Expand with naics_codes(*) → [{code, sba_small_business}]. Plain string arrays from legacy data are auto-normalized. | SAM.gov |
psc_codes | Array of Strings | Product/Service Codes associated with the entity. | SAM.gov |
business_types | Array of Objects | Business type classifications. Expand with business_types(*) → [{code, description}]. Dict-format data from DSBS is auto-normalized. | SAM.gov / DSBS |
sba_business_types | Array of Objects | SBA certifications. Expand with sba_business_types(*) → [{code, description, entry_date, exit_date}]. | DSBS / SAM.gov |
keywords | String | Keywords or capability text, when available. | DSBS |
capabilities | String | Capability narrative, when available. | DSBS |
federal_obligations | Object (expand-only) | Federal contract obligations. Use federal_obligations(*) → {total, active} or federal_obligations(total). Each sub-object contains awards_obligated, awards_count, idv_count, and (for total) subawards_obligated, subawards_count. | Tango (derived) |
highest_owner | Object | Highest-level corporate owner. Expand with highest_owner(*) → {cage_code, legal_business_name, uei}. | SAM.gov |
immediate_owner | Object | Immediate parent entity. Expand with immediate_owner(*) → {cage_code, legal_business_name, uei}. | SAM.gov |
relationships | Array | Related entities (parent/subsidiary). Expand with relationships(*) → [{relation, type, uei, display_name}]. | SAM.gov / Tango |
evs_source | String | Entity validation source (e.g., "E&Y"). | SAM.gov |
uei_status | String | UEI status (e.g., "Active"). | SAM.gov |
uei_expiration_date | Date | UEI expiration date, if applicable. | SAM.gov |
uei_creation_date | Date | UEI creation date, if applicable. | SAM.gov |
public_display_flag | String | Whether the entity record is publicly visible ("Y"/"N"). | SAM.gov |
exclusion_status_flag | String | Whether the entity has an active exclusion ("Y"/"N"). | SAM.gov |
exclusion_url | String | URL for exclusion details, if applicable. | SAM.gov |
entity_division_name | String | Entity division name. | SAM.gov |
entity_division_number | String | Entity division number. | SAM.gov |
entity_start_date | String | Date the entity was started/established. | SAM.gov |
fiscal_year_end_close_date | String | Fiscal year end close date (e.g., "12/31"). | SAM.gov |
submission_date | Date | Registration submission date. | SAM.gov |
entity_structure | Object (expand) | Entity structure. Expand with entity_structure(*) → {code, description}. Description falls back to ENTITY_STRUCTURE_MAP when missing on the model. | SAM.gov |
entity_type | Object (expand) | Entity type. Expand with entity_type(*) → {code, description}. | SAM.gov |
profit_structure | Object (expand) | Profit structure. Expand with profit_structure(*) → {code, description}. | SAM.gov |
organization_structure | Object (expand) | Organization structure. Expand with organization_structure(*) → {code, description}. | SAM.gov |
state_of_incorporation | Object (expand) | State of incorporation. Expand with state_of_incorporation(*) → {code, description}. | SAM.gov |
country_of_incorporation | Object (expand) | Country of incorporation. Expand with country_of_incorporation(*) → {code, description}. | SAM.gov |
purpose_of_registration | Object (expand) | Purpose of registration. Expand with purpose_of_registration(*) → {code, description}. Description falls back to PURPOSE_OF_REGISTRATION_MAP when missing. | SAM.gov |
Common code values¶
purpose_of_registration_code (SAM.gov)¶
From src/entities/loaders/maps.py:
| Code | Meaning |
|---|---|
Z1 | Federal Assistance Awards |
Z2 | All Awards |
Z3 | IGT-Only |
Z4 | Federal Assistance Awards & IGT |
Z5 | All Awards & IGT |
sba_business_types (DSBS / SAM.gov)¶
These are SBA program classifications you'll commonly see (non-exhaustive). From SBA_BUSINESS_TYPE_MAP:
| Code | Meaning |
|---|---|
A0 | SBA-Certified Economically Disadvantaged Women-Owned Small Business |
A4 | SBA Certified Small Disadvantaged Business |
A6 | SBA Certified 8A Program Participant |
A9 | SBA Certified Woman Owned Small Business |
JT | SBA Certified 8A Joint Venture |
XX | SBA Certified Hub Zone Firm |
business_types (SAM.gov)¶
Entities store business types as 2-character codes (e.g., A6, 2R, QF). The canonical list (including certifier) is exposed at /api/business_types/ (see Business Types Data Dictionary).
Expansions (via shape)¶
physical_address / mailing_address¶
Returns the address as an object with normalized snake_case keys:
address_line1,address_line2,city,state_or_province_code,zip_code,zip_code_plus4,country_code,country_name
Address data from different sources (SAM uses snake_case, DSBS uses camelCase) is automatically normalized to the canonical snake_case format above.
business_types¶
Returns a normalized array of {code, description} objects. Raw data may be stored as:
[{code, description}](SAM format — passed through){"2X": true, "F": true}(DSBS format — normalized with description lookups)
sba_business_types¶
Returns a normalized array of {code, description, entry_date, exit_date} objects. Same normalization as business_types.
naics_codes¶
Returns a normalized array of {code, sba_small_business} objects. Plain string arrays (e.g., ["541512", "541511"]) are normalized to [{code: "541512", sba_small_business: null}, ...].
federal_obligations¶
Expand-only field (not available as a leaf). Returns obligation rollups with child fields total and active.
# Both total and active
/api/entities/{uei}/?shape=uei,federal_obligations(*)
# Only total obligations
/api/entities/{uei}/?shape=uei,federal_obligations(total)
Each sub-object structure:
total:{awards_obligated, awards_count, subawards_obligated, subawards_count, idv_count}active:{awards_obligated, awards_count, idv_count}
highest_owner / immediate_owner¶
Returns the corporate owner as {cage_code, legal_business_name, uei}. Supports child field selection.
relationships¶
Returns the list of related entities. Each item can include:
relation,type,uei,display_name
Code/description pair expands¶
The following fields are structured {code, description} expands. When the model's description is missing or empty, the system falls back to a lookup map (where available).
entity_structure(code, description)— falls back toENTITY_STRUCTURE_MAPentity_type(code, description)— falls back toBUSINESS_TYPE_MAPprofit_structure(code, description)— falls back toBUSINESS_TYPE_MAPorganization_structure(code, description)— falls back toBUSINESS_TYPE_MAPstate_of_incorporation(code, description)— uses model descriptioncountry_of_incorporation(code, description)— falls back todjango-genc(GENC country names)purpose_of_registration(code, description)— falls back toPURPOSE_OF_REGISTRATION_MAP
Returns null when the code is null.
# Get entity structure as structured object
/api/entities/{uei}/?shape=uei,entity_structure(*)
# Just the code
/api/entities/{uei}/?shape=uei,entity_structure(code)
Data Sources¶
- SAM.gov – Registration, UEI, legal name, addresses, NAICS/PSC/business types, dates, status, corporate ownership.
- DSBS – Description, capabilities, keywords, SBA business types (when available).
- Tango –
display_name,federal_obligations(derived from award data),relationships.
Usage Notes¶
- Use
ueifor lookups – All entity endpoints accept UEI; it is case-insensitive. - Use
shapefor large responses – Request only the fields you need to reduce payload size. - Scoped award endpoints – Use
/api/entities/{uei}/contracts/,.../idvs/, etc., for awards tied to an entity; see Entities API Reference. - Address key normalization – Address subfields are always returned in snake_case (
address_line1,state_or_province_code,zip_code), regardless of how the data was originally stored. - Business type normalization –
business_types(*)andsba_business_types(*)always return[{code, description, ...}]arrays, even when the source data uses dict format.