contentType: copyToDefaultContentLocation

Namespace: microsoft.graph

Copy a file to a default content location in a content type. The file can then be added as a default file or template via a POST operation.


One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.

Permission type Permissions (from least to most privileged)
Delegated (work or school account) Sites.ReadWrite.All, Sites.Manage.All, Sites.FullControl.All
Delegated (personal Microsoft account) Not supported.
Application Sites.ReadWrite.All, Sites.Manage.All, Sites.FullControl.All

HTTP request

POST /sites/{siteId}/contentTypes/{contentTypeId}/copyToDefaultContentLocation 

Request headers

Name Description
Authorization Bearer {token}. Required.
Content-Type application/json. Required.

Request body

In the request body, supply a JSON representation of the parameters.

The following table shows the parameters that can be used with this action.

Parameter Type Description
sourceFile itemReference Metadata about the source file that needs to be copied to the default content location. Required.
destinationFileName string Destination filename.


If successful, this call returns a 204 No Content response.



Content-Type: application/json



HTTP/1.1 204 No Content