# Location read

`GET /Location/{id}`

This resource contains information about a place where healthcare services are provided. This could be where services are rendered to a patient or even where medical supplies are stored.

You can review or retrieve location details.

> **Supported fields and schema examples**
>
> We support any valid FHIR field. However, we only display fields we’ve defined in our schema, which are usually based on what’s included in the U.S. Core profile. We recommend relying on U.S. Core requirements. 
>
> Our schema examples show the shape and possibility of each FHIR resource; they aren’t code for real-time API calls. We don’t currently recommend copying and pasting these schema examples for your API calls. [Consider reviewing FHIR API actions](/fhir-api-actions) for realistic examples for particular use cases.

### read

Review a specific `Location` resource with details about the location of healthcare services or supplies.

> **FHIR read**
>
> To use a `read` interaction, you must know the related resource ID, which you may not have in your real workflows. A `read` is likely only a follow-up option after receiving the specific resource in a recent FHIR passthrough or data on demand exchange.
>
> Typically, you should use the more flexible `_search` with query parameters, unless you’re guaranteed to request data directly from a FHIR server using the resource ID. [Learn more about using FHIR identifiers](https://docs.redoxengine.com/permalink/3D5vEc8GfbxZ0SLhMbLfuQ).

## Request parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `id` | path | string | Yes | Location identifier |

## Request example

```bash
curl 'https://api.redoxengine.com/fhir/R4/{destinationSlug}/{environmentFlag}/Location/{id}' \
--request GET \
--header 'Authorization: Bearer $API_TOKEN'
```

## Responses

### 200

The Location

A profile on the location resource that conforms to Redox requirements.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `resourceType` | string | Yes | Identifies the type of the resource. Value: Location |
| `name` | string | No | Name of the location as used by humans. Does not need to be unique. |
| `type` | Array of object | No | Indicates the type of function performed at the location. |
| `type[].text` | string | No | A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user. |
| `telecom` | Array of object | No | The contact details of communication devices available at the location. This can include phone numbers, fax numbers, mobile numbers, email addresses and web sites. |
| `telecom[].system` | string | No | Telecommunications form for contact point - what communications system is required to make use of the contact. Possible values: phone, fax, email, pager, url, sms, other |
| `telecom[].value` | string | No | The actual contact point details, in a form that is meaningful to the designated communication system (i.e. phone number or email address). |
| `telecom[].use` | string | No | Identifies the purpose for the contact point. Possible values: home, work, temp, old, mobile |
| `address` | object | No | Physical location. |
| `address.use` | string | No | The purpose of this address. Possible values: home, work, temp, old, billing |
| `address.line` | Array of string | No | This component contains the house number, apartment number, street name, street direction,  P.O. Box number, delivery hints, and similar address information. |
| `address.city` | string | No | The name of the city, town, suburb, village or other community or delivery center. |
| `address.district` | string | No | The name of the administrative area (county). |
| `address.state` | string | No | Sub-unit of a country with limited sovereignty in a federally organized country. A code may be used if codes are in common use (e.g. US 2 letter state codes). |
| `address.postalCode` | string | No | A postal code designating a region defined by the postal service. |
| `address.country` | string | No | Country - a nation as commonly understood or generally accepted. |
| `physicalType` | object | No | Physical form of the location, e.g. building, room, vehicle, road. |
| `physicalType.coding` | Array of object | No | A reference to a code defined by a terminology system. |
| `physicalType.coding[].system` | string | No | The identification of the code system that defines the meaning of the symbol in the code. |
| `physicalType.coding[].code` | string | No | A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination). |
| `physicalType.text` | string | No | A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user. |
| `partOf` | object | No | Another Location of which this Location is physically a part of. Must be a resource of type `Location`. |
| `partOf.reference` | string | No | A reference to another resource. This is typically either a relative reference which includes the resource type and ID, or an internal reference which starts with `#` and refers to a contained resource. |

#### Vista Oaks Clinic

```json
{
  "resourceType": "Location",
  "id": "RedoxLocationExample",
  "name": "RHS Vista Oaks Clinic",
  "type": [
    {
      "coding": [
        {
          "code": "OF",
          "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode",
          "display": "Outpatient Facility"
        }
      ]
    }
  ],
  "physicalType": {
    "coding": [
      {
        "code": "bu",
        "system": "http://terminology.hl7.org/CodeSystem/location-physical-type",
        "display": "Building"
      }
    ]
  }
}
```

#### Inpatient Ward

```json
{
  "resourceType": "Location",
  "id": "RedoxLocationExampleDepartment",
  "identifier": [
    {
      "system": "urn:oid:1.2.840.114350.1.13.12345.1.7.2.696570",
      "value": "3490285621"
    }
  ],
  "name": "3N",
  "type": [
    {
      "text": "Inpatient"
    }
  ],
  "physicalType": {
    "coding": [
      {
        "code": "wa",
        "system": "http://terminology.hl7.org/CodeSystem/location-physical-type",
        "display": "Ward"
      }
    ],
    "text": "Department"
  },
  "partOf": {
    "reference": "Location/RedoxLocationExampleFacility"
  }
}
```

#### General Hospital

```json
{
  "resourceType": "Location",
  "id": "RedoxLocationExampleFacility",
  "identifier": [
    {
      "system": "urn:oid:1.2.840.114350.1.13.12345.1.7.2.696570",
      "value": "461904242"
    }
  ],
  "name": "RES General Hospital",
  "physicalType": {
    "coding": [
      {
        "code": "si",
        "system": "http://terminology.hl7.org/CodeSystem/location-physical-type",
        "display": "Site"
      }
    ],
    "text": "Facility"
  }
}
```

#### Room

```json
{
  "resourceType": "Location",
  "id": "RedoxLocationExampleRoom",
  "identifier": [
    {
      "system": "urn:oid:1.2.840.114350.1.13.12345.1.7.2.696570",
      "value": "6592045611"
    }
  ],
  "name": "136",
  "physicalType": {
    "coding": [
      {
        "code": "ro",
        "system": "http://terminology.hl7.org/CodeSystem/location-physical-type",
        "display": "Room"
      }
    ]
  },
  "partOf": {
    "reference": "Location/RedoxLocationExampleDepartment"
  }
}
```

#### a5cc27d1-5c70-39f8-a9c4-2f3696988650

```json
{
  "resourceType": "Location",
  "id": "a5cc27d1-5c70-39f8-a9c4-2f3696988650",
  "identifier": [
    {
      "system": "https://github.com/synthetichealth/synthea",
      "value": "a5cc27d1-5c70-39f8-a9c4-2f3696988650"
    }
  ],
  "status": "active",
  "name": "AGELESS WELLNESS CENTER, INC",
  "telecom": [
    {
      "system": "phone",
      "value": "4144755800"
    }
  ],
  "address": {
    "line": [
      "2745 W LAYTON AVE"
    ],
    "city": "MILWAUKEE",
    "state": "WI",
    "postalCode": "532212651",
    "country": "US"
  },
  "position": {
    "longitude": -87.9289427,
    "latitude": 42.959352
  },
  "managingOrganization": {
    "reference": "Organization/8b124b8e-ce6a-3b8a-bf2c-b8f539a4e3ce",
    "identifier": {
      "system": "https://github.com/synthetichealth/synthea",
      "value": "8b124b8e-ce6a-3b8a-bf2c-b8f539a4e3ce"
    },
    "display": "AGELESS WELLNESS CENTER, INC"
  }
}
```

### 400

Request could not be processed or failed validation

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `resourceType` | string | Yes | Identifies the type of the resource. Value: OperationOutcome |
| `issue` | Array of object | Yes | A structured respresentation of the error that occurred |
| `issue[].severity` | string | Yes | Generally `error` or `fatal` Possible values: fatal, error, warning, information |
| `issue[].code` | string | Yes | A FHIR category code that describes the general type of issue. See http://hl7.org/fhir/ValueSet/issue-type for details |
| `issue[].id` | string | No | If the error occurs in the RedoxEngine, this corresponds to an Error record in the organization. |
| `issue[].details` | object | No | Additional details about the error. This may be a text description of the error or a system code that identifies the error. |
| `issue[].details.coding` | Array of object | No | A more granular FHIR code for the specific error. Typically from http://hl7.org/fhir/ValueSet/operation-outcome |
| `issue[].details.coding[].system` | string | No | The identification of the code system that defines the meaning of the symbol in the code. |
| `issue[].details.coding[].code` | string | No | A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination). |
| `issue[].details.text` | string | No | A human-readable interpretation of the issue code |
| `issue[].diagnostics` | string | No | Additional diagnostic information about the issue. |

```json
{
  "resourceType": "OperationOutcome",
  "issue": [
    {
      "severity": "fatal",
      "code": "invalid",
      "details": {
        "coding": [
          {
            "code": "MSG_BAD_SYNTAX",
            "system": "http://terminology.hl7.org/CodeSystem/operation-outcome"
          }
        ],
        "text": "Invalid content found in request body."
      }
    }
  ]
}
```

### 401

Authorization is required

Same fields as 400.

```json
{
  "resourceType": "OperationOutcome",
  "issue": [
    {
      "severity": "fatal",
      "code": "unknown",
      "details": {
        "coding": [
          {
            "code": "MSG_AUTH_REQUIRED",
            "system": "http://terminology.hl7.org/CodeSystem/operation-outcome"
          }
        ],
        "text": "Invalid authorization token"
      }
    }
  ]
}
```

### 404

Not found or not supported

Same fields as 400.

```json
{
  "resourceType": "OperationOutcome",
  "issue": [
    {
      "severity": "fatal",
      "code": "not-found",
      "details": {
        "coding": [
          {
            "code": "MSG_NO_MODULE",
            "system": "http://terminology.hl7.org/CodeSystem/operation-outcome"
          }
        ],
        "text": "my-sandbox is not a recognized FHIR organization"
      }
    }
  ]
}
```

### 500

Internal server error

Same fields as 400.

```json
{
  "resourceType": "OperationOutcome",
  "issue": [
    {
      "severity": "fatal",
      "code": "processing",
      "details": {
        "coding": [
          {
            "code": "MSG_RESOURCE_ID_FAIL",
            "system": "http://terminology.hl7.org/CodeSystem/operation-outcome"
          }
        ],
        "text": "Unable to allocate resource id."
      }
    }
  ]
}
```

### 503

Service unavailable

Same fields as 400.

```json
{
  "resourceType": "OperationOutcome",
  "issue": [
    {
      "severity": "fatal",
      "code": "transient",
      "details": {
        "text": "System is unable to process this message at this time."
      }
    }
  ]
}
```
