> ## Documentation Index
> Fetch the complete documentation index at: https://docs.metriport.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Procedure

> Schema documentation for the Procedure table in the Metriport data model

The procedure resource is used to record the details of current and historical procedures performed on or for a patient. A procedure is an activity that is performed on, with, or for a patient as part of the provision of care.

**Reference Table:**

The `procedure_references` table contains normalized references from the procedure to other entities. It supports the following reference properties:

* **subject** (required): links to the patient who underwent the procedure
* **encounter**: links to the encounter where the procedure was performed
* **performer.actor**: links to practitioners who performed the procedure
* **location**: links to the location where the procedure was performed
* **report**: links to diagnostic reports or other documents related to the procedure

For detailed information about reference table structure and indexing, see the [Reference Tables documentation](/medical-api/handling-data/schema-v000/reference-tables).

**Procedure Table:**
The `procedure` table records medical procedures performed on patients, including surgical procedures, diagnostic tests, and other clinical interventions.

**Primary Keys:**

* procedure\_id

**Foreign Keys:**

* patient\_id

| Column                    | Data Type | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| ------------------------- | --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| procedure\_id             | varchar   | Unique identifier for the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| patient\_id               | varchar   | Unique identifier for the patient                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| status                    | varchar   | Status of the procedure. Possible values:<br />– <code>preparation</code>: The core event has not started yet, but some staging activities have begun (e.g., premedication, anesthetic, preparing the patient, etc.).<br />– <code>in-progress</code>: The event is currently occurring.<br />– <code>not-done</code>: The event was terminated prior to any activity beyond preparation.<br />– <code>on-hold</code>: The event has been temporarily stopped but is expected to resume in the future.<br />– <code>stopped</code>: The event was terminated prior to completion, after at least some activity has occurred.<br />– <code>completed</code>: The event has now concluded.<br />– <code>entered-in-error</code>: This electronic record should never have existed (e.g., wrong patient, wrong data, mistaken entry, etc.).<br />– <code>unknown</code>: The authoring or source system does not know the current state of the event. |
| performed\_date           | date      | Start date of the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| end\_date                 | date      | End date of the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| cpt\_code                 | varchar   | CPT code for the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| cpt\_display              | varchar   | Human-readable description of CPT code                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| snomed\_code              | varchar   | SNOMED CT code for the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| snomed\_display           | varchar   | Human-readable description of SNOMED CT code                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| source\_code\_code        | varchar   | Original code from source system                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| source\_code\_display     | varchar   | Original code display from source system                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| source\_code\_system      | varchar   | Original code system from source system                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| bodysite\_snomed\_code    | varchar   | SNOMED CT body site code                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| bodysite\_snomed\_display | varchar   | Human-readable description of SNOMED CT body site                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| reason\_snomed\_code      | varchar   | SNOMED CT reason code                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| reason\_snomed\_display   | varchar   | Human-readable description of SNOMED CT reason                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| note\_text                | varchar   | Additional notes about the procedure                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| meta\_source              | varchar   | Source document filename from FHIR meta.source                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| data\_source              | varchar   | **Deprecated.** Use `meta_source` instead.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| data\_source\_ext         | varchar   | Integration source of the data, derived from FHIR extension                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
