Show examples in:
Javascript HTTP

Content Management API > Site

Site

A site represents a specific DatoCMS administrative area

Object payload

id string

ID of site

Example: "155"
type string

Must be exactly "site".

attributes.domain string, null

Administrative area custom domain

Example: "admin.my-awesome-website.com"
attributes.favicon string, null

The upload id for the favicon

Example: "123"
attributes.global_seo object, null

Specifies default global settings

site_name string

Site name, used in social sharing

Example: "My Awesome Website"
fallback_seo object
title string
Example: "Default meta title"
description string
Example: "Default meta description"
image null, string

The id of the image

Example: "123"
twitter_card null, enum

Determines how a Twitter link preview is shown

Example: "summary_large_image"
summary

Twitter summary card

summary_large_image

Twitter summary card with large image

title_suffix null, string

Title meta tag suffix

Example: " - My Awesome Website"
facebook_page_url null, string

URL of facebook page

Example: "http://facebook.com/awesomewebsite"
twitter_account null, string

Twitter account associated to website

Example: "@awesomewebsite"
attributes.google_maps_api_token string, null

Google API Key to be used by the LatLon widget

Example: "xxxxxxxxxxxxx"
attributes.imgix_host string, null

Imgix host

Example: "www.datocms-assets.com"
attributes.internal_domain string, null

DatoCMS internal domain for the administrative area

Example: "my-website.admin.datocms.com"
attributes.last_data_change_at

Specifies the last time when a change of data occurred

Type: null, date-time
Example: "2017-03-30T09:29:14.872Z"
attributes.locales

Available locales

Type: Array<string>
Example: ["en"]
attributes.name string

Site name

Example: "My Awesome Website"
attributes.no_index boolean

Whether the website needs to be indexed by search engines or not

attributes.require_2fa boolean

Specifies whether all users of this site need to authenticate using two-factor authentication

attributes.theme object

Specifies the theme to use in administrative area

type enum

If type is monochromatic, the hue will determine the color palette. Dark color is a legacy property, and it won't be used on the interface

Example: "monochromatic"
custom

Use custom color palette

monochromatic

Use monochromatic, accessible color palette

hue integer, null

If the type is monochromatic, the value will fall between 0 and 359. If it's not, the value will be null.

Example: 16
primary_color object
red integer
Example: 128
green integer
Example: 128
blue integer
Example: 128
alpha integer
Example: 128
light_color object
red integer
Example: 128
green integer
Example: 128
blue integer
Example: 128
alpha integer
Example: 128
accent_color object
red integer
Example: 128
green integer
Example: 128
blue integer
Example: 128
alpha integer
Example: 128
dark_color object
red integer
Example: 128
green integer
Example: 128
blue integer
Example: 128
alpha integer
Example: 128
logo string, null

The upload ID that is used as the logo for the project

Example: "123"
attributes.timezone string

Site default timezone

Example: "Europe/London"
attributes.ip_tracking_enabled boolean

Specifies whether you want IPs to be tracked in the Project usages section

attributes.force_use_of_sandbox_environments boolean

If enabled, blocks schema changes of primary environment

attributes.assets_cdn_default_settings object

Allows setting default parameters for assets served through the CDN

image object

Allows setting default parameters for optimizing images served by the CDN

q integer

Controls the output quality of lossy file formats (jpg, pjpg, webp, avif, or jxr). Valid values are in the range 0 – 100 and the default is 75.

Example: 50
auto

The auto parameter helps automating a baseline level of optimization. Specify one or more settings

Type: Array<string>
Example: ["compress", "format"]
cs enum

Specifies the color space of the output image

Example: "srgb"
srgb

Uses the sRGB colorspace which is an internet standard. This is the default

adobergb1998

Refers to the Adobe RGB (1998) color space, which provides accurate color reproduction from screen to print

tinysrgb

Reduces the color space metadata but may cause a slight shift in color values

strip

Removes the colorspace for maximum size reduction. Note that colors will still be rendered, but a colorspace will not be specified

video object

Allows setting default parameters for optimizing videos served by the CDN

disable_serving_raw_videos boolean

When true, attempting to retrieve raw video files directly instead of their optimized counterparts will result in a HTTP 422 status code

meta.created_at date-time

Date of project creation

meta.improved_timezone_management boolean

Whether the Improved API Timezone Management option is active or not

meta.improved_hex_management boolean

Whether the Improved API Hex Management option is active or not

meta.improved_gql_multilocale_fields boolean

Whether the Improved GraphQL multi-locale fields option is active or not

meta.improved_gql_visibility_control boolean

Whether the Improved GraphQL visibility control option is active or not

meta.improved_boolean_fields boolean

Whether the Improved boolean fields option is active or not

meta.custom_upload_storage_settings boolean

Whether the site has custom upload storage settings

relationships.item_types.data
relationships.account.data Deprecated

Please user the owner relationship instead

Available endpoints