1KEY Developers
Guides

Sites

A site is a building your organization manages. Every hub is at one of your sites, so create the site before you add its hubs.

Creating a site

curl
curl -X POST https://api.1keyplatform.dev/v1/sites \
  -H "Authorization: Bearer $ONEKEY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name": "120 Harbour St"}'
json
{
  "id": "6f1c2a9e-4b7d-4e0a-9c3f-2d8e5a1b7c40",
  "name": "120 Harbour St",
  "hub_count": 0,
  "created_at": "2026-09-12T15:20:00Z"
}

Needs sites:write. Keep the id: you add hubs to a site by it.

Listing sites

curl
curl https://api.1keyplatform.dev/v1/sites \
  -H "Authorization: Bearer $ONEKEY_API_KEY"

Sites come oldest first, 50 to a page. When has_more is true, pass the last site's id as starting_after for the next page. Needs sites:read.

Renaming a site

curl
curl -X PATCH https://api.1keyplatform.dev/v1/sites/6f1c2a9e-4b7d-4e0a-9c3f-2d8e5a1b7c40 \
  -H "Authorization: Bearer $ONEKEY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name": "Harbour Tower"}'

Needs sites:write.