A client has one or more sites, each with its own hostnames, settings and content. Site data is a small key and value store: a value is either a scalar or JSON, and templates read it through $_siteData.
API ReferencePlatform
Sites
Sites, and site data: a store of keys and values that templates read as $_siteData.
About sites
Values
Scalar or JSON
type scalar holds one value; json holds a list or an object.
Revisions
No
Sites and site data are not versioned; a change applies at once.
Revisions, publishing and approvalList sites#
GET
/cdna-api/sites/sites
Lists the client’s sites.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Model
- Site, in the Reference
Parameters
propertiesquery- selector
- The fields and relations to return, such as
{id,name}. filtersquery- name=value
- Any stored field, or a relation with a dot, such as
parent.id=12. Prefix the name with!,>,<,%or|. Use stored field names exactly as in the model, and comparetotalCountwith the unfiltered list's to confirm a filter applied. orderByquery- string
field:ASCorfield:DESC, comma-separated. Stored fields only.limitquery- integer
- Records per response. There is no default.
offsetquery- integer
- Records to skip.
Example
List sites
GET /cdna-api/sites/sites?limit=2&properties={id,name} HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Response
200 OK
{
"result": "success",
"totalCount": 2,
"data": [
{
"id": 66,
"name": "Core dna Hub"
},
{
"id": 70,
"name": "Canadian Hosts for SSO"
}
]
}
Real response from this documentation site
Show a site#
GET
/cdna-api/sites/site/{id}
Reads one site by its id.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Model
- Site, in the Reference
Parameters
idpathrequired- integer
- The site id.
propertiesquery- selector
- The fields and relations to return, such as
{id,name}.
Example
Show a site
GET /cdna-api/sites/site/66?properties={id,name} HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Response
200 OK
{
"result": "success",
"data": {
"id": 66,
"name": "Core dna Hub"
}
}
Real response from this documentation site
Edit a site#
PUT
/cdna-api/sites/site/{id}
Changes a site. Fields left out keep their values.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Returns
- The saved site under
data.site, and amessage.
Parameters
idpathrequired- integer
- The site id.
namebody- string
- The site’s name.
Example
Edit a site
PUT /cdna-api/sites/site/1 HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Content-Type: application/json
{
"name": "Example site"
}List site data#
GET
/cdna-api/sites/site-data
Lists site data records. Without limit every match comes back.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Model
- SiteData, in the Reference
Parameters
propertiesquery- selector
- The fields and relations to return, such as
{id,key,type}. filtersquery- name=value
- Any stored field, or a relation with a dot, such as
parent.id=12. Prefix the name with!,>,<,%or|. Use stored field names exactly as in the model, and comparetotalCountwith the unfiltered list's to confirm a filter applied. orderByquery- string
field:ASCorfield:DESC, comma-separated. Stored fields only.limitquery- integer
- Records per response. There is no default.
offsetquery- integer
- Records to skip.
Example
List site data
GET /cdna-api/sites/site-data?limit=2&properties={id,key,type} HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Response
200 OK
{
"result": "success",
"totalCount": 0,
"data": []
}
Open in Postman docs Real response from this documentation site
Show a site data record#
GET
/cdna-api/sites/site-data/{id}
Reads one site data record by its id.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Model
- SiteData, in the Reference
Parameters
idpathrequired- integer
- The site data record id.
propertiesquery- selector
- The fields and relations to return, such as
{id,key,type}.
Example
Show a site data record
GET /cdna-api/sites/site-data/1 HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/jsonCreate a site data record#
POST
/cdna-api/sites/site-data
Creates a site data record.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
Parameters
keybody- string
- The name templates read it by.
typebody- string
scalarfor a single value,jsonfor a list or an object.contentbody- object
- The value: a string or number for
scalar, any JSON forjson.
Example
Create a site data record
POST /cdna-api/sites/site-data HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Content-Type: application/json
{
"key": "fruit-list",
"type": "json",
"content": {
"available": ["apple", "orange", "pear"],
"selected": "pear"
}
}
Response
200 OK
{
"result": "success",
"data": {
"siteData": {
"id": 8,
"key": "fruit-list",
"created": "2026-08-27T15:47:58+10:00",
"modified": "2026-08-27T15:47:58+10:00",
"createdBy": 34,
"client": 1,
"site": null,
"content": {
"available": [
"apple",
"orange",
"pear"
],
"selected": "pear"
},
"type": "json"
}
},
"message": "The Site Data has been added successfully."
}
Open in Postman docs Saved response from the Postman collection, with the values replaced
Edit a site data record#
PUT
/cdna-api/sites/site-data/{id}
Changes a site data record. Fields left out keep their values.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
- Returns
- The saved record under
data.siteData, and amessage.
Parameters
idpathrequired- integer
- The site data record id.
contentbody- string
- The value: a string or number for
scalar, any JSON forjson.
Example
Edit a site data record
PUT /cdna-api/sites/site-data/8 HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json
Content-Type: application/json
{
"content": "site data value"
}Delete a site data record#
DELETE
/cdna-api/sites/site-data/{id}
Deletes a site data record.
- Access
- Admin users and integrations, with an OAuth access token or an API key.
Parameters
idpathrequired- integer
- The site data record id.
Example
Delete a site data record
DELETE /cdna-api/sites/site-data/8 HTTP/1.1
Host: hub.coredna.com
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept: application/json