Get paginated list of locations
curl --request GET \
--url https://app.hipp.health/api/v1/locations \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.hipp.health/api/v1/locations"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.hipp.health/api/v1/locations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.hipp.health/api/v1/locations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.hipp.health/api/v1/locations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.hipp.health/api/v1/locations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.hipp.health/api/v1/locations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"publicId": "loc_1234567890_abc123def",
"title": "Downtown Center",
"type": "HOUSE",
"timezone": "America/New_York",
"addressLine1": "123 Main St",
"addressLine2": "Suite 200",
"city": "New York",
"state": "NY",
"postalCode": "10001"
}
],
"pagination": {
"page": 123,
"pageSize": 123,
"totalCount": 123,
"totalPages": 123
}
}{
"message": "Validation Error",
"statusCode": 400,
"validationErrors": [
{
"code": "invalid_type",
"message": "Required",
"path": [
"email"
]
}
]
}{
"error": "API key required",
"statusCode": 401
}Locations
Get All Locations
Retrieve a paginated list of the organization’s centers/locations. Each location includes its publicId, title, type, timezone and flattened address. Patient/staff home-address records are always excluded; pass the ‘type’ parameter to return only a specific location type.
GET
/
v1
/
locations
Get paginated list of locations
curl --request GET \
--url https://app.hipp.health/api/v1/locations \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.hipp.health/api/v1/locations"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.hipp.health/api/v1/locations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.hipp.health/api/v1/locations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.hipp.health/api/v1/locations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.hipp.health/api/v1/locations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.hipp.health/api/v1/locations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"publicId": "loc_1234567890_abc123def",
"title": "Downtown Center",
"type": "HOUSE",
"timezone": "America/New_York",
"addressLine1": "123 Main St",
"addressLine2": "Suite 200",
"city": "New York",
"state": "NY",
"postalCode": "10001"
}
],
"pagination": {
"page": 123,
"pageSize": 123,
"totalCount": 123,
"totalPages": 123
}
}{
"message": "Validation Error",
"statusCode": 400,
"validationErrors": [
{
"code": "invalid_type",
"message": "Required",
"path": [
"email"
]
}
]
}{
"error": "API key required",
"statusCode": 401
}Get All Locations
Retrieve a paginated list of your organization’s centers/locations. Home-address records for patients and staff are always excluded, so only real centers and offices are returned.Headers
Authorization: Bearer <your-api-key>
Query Parameters
page(optional): Page number (1-indexed). Default:1. Minimum:1pageSize(optional): Number of items per page. Default:25. Minimum:1, Maximum:100type(optional): Filter by location type. When omitted,HOUSElocations are excluded and only real centers/offices are returned.- Available types:
HOUSE,SCHOOL,TEMPORARY_LODGING,COMMUNITY,OFFICE,PLACE_OF_EMPLOYMENT,OTHER
- Available types:
Success Response (200)
{
"data": [
{
"publicId": "loc_1234567890_abc123def",
"title": "Downtown Center",
"type": "OFFICE",
"timezone": "America/New_York",
"addressLine1": "123 Main St",
"addressLine2": "Suite 200",
"city": "New York",
"state": "NY",
"postalCode": "10001"
}
],
"pagination": {
"page": 1,
"pageSize": 25,
"totalCount": 5,
"totalPages": 1
}
}
Error Responses
400 - Validation Error
{
"message": "Validation Error",
"statusCode": 400,
"validationErrors": [
{
"code": "invalid_enum_value",
"message": "Invalid enum value",
"path": ["type"]
}
]
}
401 - Unauthorized
{
"error": "API key required",
"statusCode": 401
}
Examples
cURL Example
# Get all locations with pagination
curl -X GET "https://app.hipp.health/api/v1/locations?page=1&pageSize=25" \
-H "Authorization: Bearer your-api-key"
# Get only office locations
curl -X GET "https://app.hipp.health/api/v1/locations?type=OFFICE" \
-H "Authorization: Bearer your-api-key"
JavaScript Example
const getLocations = async (params = {}) => {
const queryParams = new URLSearchParams(params);
const response = await fetch(`/api/v1/locations?${queryParams}`, {
method: "GET",
headers: {
Authorization: "Bearer your-api-key",
},
});
if (!response.ok) {
const error = await response.json();
throw new Error(error.error || "Failed to fetch locations");
}
return response.json();
};
// Usage
try {
const result = await getLocations({ page: 1, pageSize: 25, type: "OFFICE" });
console.log("Locations:", result.data);
console.log("Pagination:", result.pagination);
} catch (error) {
console.error("Error fetching locations:", error.message);
}
Authorizations
API key authentication. Include your API key in the Authorization header as 'Bearer '
Query Parameters
Page number (1-indexed)
Required range:
x >= 1Number of items per page
Required range:
1 <= x <= 100Filter by location type. When omitted, HOUSE locations are excluded and only real centers/offices are returned. Type of location. HOUSE locations back patient/staff home addresses and are never returned by the list locations endpoint.
Available options:
HOUSE, SCHOOL, TEMPORARY_LODGING, COMMUNITY, OFFICE, PLACE_OF_EMPLOYMENT, OTHER