# Update a site

Updates various parameters of a site. To change the name of a site, see rename a site.

Endpoint: PATCH /api/v1/sites/{siteId}
Version: v1
Security: Bearer

## Path parameters:

  - `siteId` (string, required)
    The identifier of the site.
    Example: "497f6eca-6276-4993-bfeb-53cbbbba6f08"

## Query parameters:

  - `environmentId` (string)
    The identifier of the environment
    Example: "main"

## Request fields (application/json):

  - `displayName` (string,null)
    The display name for the site.
Example value: Skate Park Site
    Example: "Skate Park Site"

  - `description` (string,null)
    The description for the site.
Example value: New site for Brand A in English-speaking countries.
    Example: "New site for Brand A in English-speaking countries."

  - `supportedLanguages` (array,null)
    The list of languages supported by Sitecore.
Example value: [
  "en-US",
  "en-CA"
]
    Example: ["en-US","en-CA"]

  - `shared` (boolean,null)
    Whether the site should be marked as shared or not. True - site will be shared. False - site will not be marked as shared.
Example value: True
    Example: true

  - `errorPages` (object)
    An object containing the site error pages identifiers

  - `errorPages.errorPage` (string,null)
    The identifier of the site's 500 error page. You can get page identifiers by calling the /hierarchy endpoint.
Example value: c5a2fe31-46bd-34ae-91fb-d3c24b5a6e7f
    Example: "c5a2fe31-46bd-34ae-91fb-d3c24b5a6e7f"

  - `errorPages.notFoundPage` (string,null)
    The identifier of the site's 404 error page. You can get page identifiers by calling the /hierarchy endpoint.
Example value: a2fc5e31-6b4d-a43e-9f1b-c2d34b5a6e7f
    Example: "a2fc5e31-6b4d-a43e-9f1b-c2d34b5a6e7f"

  - `sortOrder` (integer,null)
    The sort order of the site.
Example value: 100
    Example: 100

  - `brandKitId` (string,null)
    The identifier of the brand kit associated with this site.
Example value: e3f1c5a2-4b6d-4a3e-9f1b-2d3c4b5a6e7f
    Example: "e3f1c5a2-4b6d-4a3e-9f1b-2d3c4b5a6e7f"

  - `resetThumbnail` (boolean,null)
    Whether the thumbnail should be reset. True - thumbnail will be reset to automatic. False - thumbnail will not be reset.
Example value: True
    Example: true

  - `editorProfiles` (array,null)
    The list of text editor profiles associated with the site.
Example value: [
  "e2102e93-424a-4a99-a066-7750dbf41b28",
  "530f7907-6eec-4b7a-9fcc-98aef2719232"
]
    Example: ["e2102e93-424a-4a99-a066-7750dbf41b28","530f7907-6eec-4b7a-9fcc-98aef2719232"]

  - `targetHostname` (string,null)
    The target hostname of the site.
Example value: skatepark.local
    Example: "skatepark.local"

## Response 200 fields (application/json):

  - `id` (string,null)
    The identifier of the site.
Example value: 497f6eca-6276-4993-bfeb-53cbbbba6f08
    Example: "497f6eca-6276-4993-bfeb-53cbbbba6f08"

  - `name` (string,null)
    The name of the site.
Example value: skate-park
    Example: "skate-park"

  - `description` (string,null)
    The description of the site.
Example value: New site for Brand A in English-speaking countries
    Example: "New site for Brand A in English-speaking countries"

  - `displayName` (string,null)
    The display name of the site.
Example value: Skate Park Website
    Example: "Skate Park Website"

  - `thumbnail` (object)
    The thumbnail response entity.

  - `thumbnail.url` (string,null)
    The URL of the image used as thumbnail.
Example value: https://xmc-customer-tenant.sitecorecloud.io/-/media/Project/sample-collection/sample-site/System/7/0/B/C/thumbnail_70BC64BDE257400E82BFDB3344797DB7.png
    Example: "https://xmc-customer-tenant.sitecorecloud.io/-/media/Project/sample-collection/sample-site/System/7/0/B/C/thumbnail_70BC64BDE257400E82BFDB3344797DB7.png"

  - `thumbnail.rootPath` (string,null)
    The path to the media folder where thumbnail images are stored.
Example value: sitecore/media library/Project/sample-collection/sample-site
    Example: "sitecore/media library/Project/sample-collection/sample-site"

  - `thumbnail.autogenerated` (boolean)
    Whether the thumbnail was autogenerated or manually uploaded.
Example value: True
    Example: true

  - `collectionId` (string,null)
    The identifier of the collection to which the site belongs.
Example value: 5aae1eeaea2440bf96f11f43da82c77b
    Example: "5aae1eeaea2440bf96f11f43da82c77b"

  - `created` (string)
    The date when the site was created.
Example value: 2019-08-24T14:15:22Z
    Example: "2019-08-24T14:15:22Z"

  - `createdBy` (string,null)
    The ID of the user who created the site.
Example value: L6kfw52ZVf
    Example: "L6kfw52ZVf"

  - `sortOrder` (integer,null)
    Sort order of the site.
Example value: 100
    Example: 100

  - `brandKitId` (string,null)
    The identifier of the brand kit associated with this site.
Example value: e3f1c5a2-4b6d-4a3e-9f1b-2d3c4b5a6e7f
    Example: "e3f1c5a2-4b6d-4a3e-9f1b-2d3c4b5a6e7f"

  - `permissions` (object)
    The access rights of the current user to the site.

  - `permissions.canAdmin` (boolean)
    Whether the current user has admin rights. Being an admin means that you control access permissions for other users, and have full read and write rights.
Example value: False

  - `permissions.canWrite` (boolean)
    Whether the current user has permissions to edit values. Users with write access also have read access.
Example value: False

  - `permissions.canCreate` (boolean)
    Whether the current user has permission to create entities.
Example value: False

  - `permissions.canDelete` (boolean)
    Whether the current user has permission to delete entities.
Example value: False

  - `permissions.canRename` (boolean)
    Whether the current user has permission to rename entities.
Example value: False

  - `permissions.canRead` (boolean)
    Whether the current user has permission to see entities, including all their parameters.
Example value: False

  - `permissions.canPublish` (boolean)
    Whether the current user has permission to publish sites in this environment.
Example value: False

  - `permissions.canDuplicate` (boolean)
    Whether the current user has permission to duplicate entities.
Example value: False

  - `permissions.canWriteLanguage` (boolean)
    Whether the current user has permission to write item language entities.
Example value: False

  - `languages` (array,null)
    The list of languages in use by the site.
Example value: [
  "en-US",
  "en-CA"
]
    Example: ["en-US","en-CA"]

  - `hosts` (array,null)
    The list of hosts that the site resolves to.

  - `hosts.id` (string,null)
    The host ID.
Example value: 5aae1eeaea2440bf96f11f43da82c77b
    Example: "5aae1eeaea2440bf96f11f43da82c77b"

  - `hosts.name` (string,null)
    The name of the site host.
Example value: skate-park
    Example: "skate-park"

  - `hosts.hostnames` (array,null)
    One or more hostnames.
Example value: [
  "dev.skate-park.com",
  "uat.skate-park.com"
]
    Example: ["dev.skate-park.com","uat.skate-park.com"]

  - `hosts.targetHostname` (string,null)
    The target hostname.
Example value: www.skate-park.com
    Example: "www.skate-park.com"

  - `hosts.homePageId` (string,null)
    The identifier of the home page.
Example value: 5aae1eeaea2440bf96f11f43da82c77b
    Example: "5aae1eeaea2440bf96f11f43da82c77b"

  - `hosts.renderingHost` (object)
    The rendering host response entity.

  - `hosts.renderingHost.id` (string,null)
    The rendering host ID.
Example value: 5aae1eeaea2440bf96f11f43da82c77b
    Example: "5aae1eeaea2440bf96f11f43da82c77b"

  - `hosts.renderingHost.name` (string,null)
    The name of the rendering host.
Example value: Default
    Example: "Default"

  - `hosts.renderingHost.appName` (string,null)
    The name of the app.
Example value: Default
    Example: "Default"

  - `hosts.renderingHost.layoutServiceConfiguration` (string,null)
    The server side rendering engine configuration URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/config
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/config"

  - `hosts.renderingHost.serverSideRenderingEngineEndpointUrl` (string,null)
    The server side rendering engine endpoint URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/render
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/render"

  - `hosts.renderingHost.serverSideRenderingEngineApplicationUrl` (string,null)
    The server side rendering engine application URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io/
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io/"

  - `hosts.editingHost` (object)
    The editing host response entity.

  - `hosts.editingHost.id` (string,null)
    The editing host ID.
Example value: 5aae1eeaea2440bf96f11f43da82c77b
    Example: "5aae1eeaea2440bf96f11f43da82c77b"

  - `hosts.editingHost.name` (string,null)
    The name of the editing host.
Example value: Default
    Example: "Default"

  - `hosts.editingHost.appName` (string,null)
    The name of the app.
Example value: Default
    Example: "Default"

  - `hosts.editingHost.layoutServiceConfiguration` (string,null)
    The server side rendering engine configuration URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/config
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/config"

  - `hosts.editingHost.serverSideRenderingEngineEndpointUrl` (string,null)
    The server side rendering engine endpoint URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/render
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io:443/api/editing/render"

  - `hosts.editingHost.serverSideRenderingEngineApplicationUrl` (string,null)
    The server side rendering engine application URL.
Example value: https://xmc-eh-uniqueid.sitecorecloud.io/
    Example: "https://xmc-eh-uniqueid.sitecorecloud.io/"

  - `hosts.permissions` (object)
    The access rights of the current user to the site.

  - `hosts.permissions.canAdmin` (boolean)
    Whether the current user has admin rights. Being an admin means that you control access permissions for other users, and have full read and write rights.
Example value: False

  - `hosts.permissions.canWrite` (boolean)
    Whether the current user has permissions to edit values. Users with write access also have read access.
Example value: False

  - `hosts.permissions.canCreate` (boolean)
    Whether the current user has permission to create entities.
Example value: False

  - `hosts.permissions.canDelete` (boolean)
    Whether the current user has permission to delete entities.
Example value: False

  - `hosts.permissions.canRename` (boolean)
    Whether the current user has permission to rename entities.
Example value: False

  - `hosts.permissions.canRead` (boolean)
    Whether the current user has permission to see entities, including all their parameters.
Example value: False

  - `hosts.permissions.canPublish` (boolean)
    Whether the current user has permission to publish sites in this environment.
Example value: False

  - `hosts.permissions.canDuplicate` (boolean)
    Whether the current user has permission to duplicate entities.
Example value: False

  - `hosts.permissions.canWriteLanguage` (boolean)
    Whether the current user has permission to write item language entities.
Example value: False

  - `hosts.settings` (object,null)
    The host settings collection.
    Example: {"isSiteThumbnailSource":"true","sxaLinkable":"false"}

  - `hosts.properties` (object,null)
    Readonly host properties collection.
    Example: {"siteDefinitionID":"{9004989A-E482-4587-B5C5-F9AECCD43565}","startItem":"/Home"}

  - `hosts.analyticsIdentifiers` (object,null)
    The list of analytics tracker identifiers mapped to the host, per language.
Example value: [
  {
    "name": "skate-park",
    "language": "en-US"
  }
]
    Example: [{"name":"skate-park","language":"en-US"}]

  - `hosts.languageSettings` (object)
    The language settings of the host.

  - `hosts.languageSettings.defaultLanguage` (string,null)
    The default language.
Example value: en
    Example: "en"

  - `hosts.languageSettings.languageEmbedding` (boolean,null)
    Whether language embedding is enabled.
Example value: False

  - `hosts.languageSettings.itemLanguageFallback` (boolean,null)
    Whether item language fallback is enabled.
Example value: False

  - `hosts.languageSettings.fieldLanguageFallback` (boolean,null)
    Whether field language fallback is enabled.
Example value: False

  - `hosts.created` (string,null)
    The date when the host was created.
Example value: 2019-08-24T14:15:22Z
    Example: "2019-08-24T14:15:22Z"

  - `hosts.createdBy` (string,null)
    The ID of the user who created the host.
Example value: L6kfw52ZVf
    Example: "L6kfw52ZVf"

  - `supportedLanguages` (array,null)
    The list of languages supported by Sitecore.
Example value: [
  "en-US",
  "en-CA"
]
    Example: ["en-US","en-CA"]

  - `errorPages` (object)
    An object containing the site error pages identifiers

  - `errorPages.errorPage` (string,null)
    The identifier of the site's 500 error page. You can get page identifiers by calling the /hierarchy endpoint.
Example value: c5a2fe31-46bd-34ae-91fb-d3c24b5a6e7f
    Example: "c5a2fe31-46bd-34ae-91fb-d3c24b5a6e7f"

  - `errorPages.notFoundPage` (string,null)
    The identifier of the site's 404 error page. You can get page identifiers by calling the /hierarchy endpoint.
Example value: a2fc5e31-6b4d-a43e-9f1b-c2d34b5a6e7f
    Example: "a2fc5e31-6b4d-a43e-9f1b-c2d34b5a6e7f"

  - `errorPagesConfiguration` (object)
    An object containing the site error pages

  - `errorPagesConfiguration.errorPage` (object)
    The error page response entity.

  - `errorPagesConfiguration.errorPage.id` (string,null)
    The identifier of the page.
Example value: 68900348a3b84eb8ac7df4d179c25727
    Example: "68900348a3b84eb8ac7df4d179c25727"

  - `errorPagesConfiguration.errorPage.path` (string,null)
    The path for the page.
Example value: Sitecore/Content/Home/Categories/Products/MyProduct
    Example: "Sitecore/Content/Home/Categories/Products/MyProduct"

  - `errorPagesConfiguration.notFoundPage` (object)
    The error page response entity.

  - `errorPagesConfiguration.notFoundPage.id` (string,null)
    The identifier of the page.
Example value: 68900348a3b84eb8ac7df4d179c25727
    Example: "68900348a3b84eb8ac7df4d179c25727"

  - `errorPagesConfiguration.notFoundPage.path` (string,null)
    The path for the page.
Example value: Sitecore/Content/Home/Categories/Products/MyProduct
    Example: "Sitecore/Content/Home/Categories/Products/MyProduct"

  - `settings` (object,null)
    The settings for the site.
    Example: {"thumbnailsRootPath":"/sitecore/media library/Project/sample-collection/sample-site","generateThumbnails":"true"}

  - `properties` (object,null)
    The read-only properties of the site.
    Example: {"SxaSiteTemplate":"{E46F3AF2-39FA-4866-A157-7017C4B2A40C}","IsSxaSite":"true"}

## Response 400 fields (application/json):

  - `type` (string,null)
    The type of the error response entity.

  - `title` (string,null)
    The title of the error response entity.

  - `status` (integer,null)
    The response status code.

  - `detail` (string,null)
    A detailed explanation, specific to this occurrence of the problem.

  - `instance` (string,null)
    If available, a URI reference that identifies the specific occurrence of the problem.

## Response 404 fields (application/json):

  - `type` (string,null)
    The type of the error response entity.

  - `title` (string,null)
    The title of the error response entity.

  - `status` (integer,null)
    The response status code.

  - `detail` (string,null)
    A detailed explanation, specific to this occurrence of the problem.

  - `instance` (string,null)
    If available, a URI reference that identifies the specific occurrence of the problem.


