AI-generated Key Takeaways
-
The
POSTrequest tohttps://earthengine.googleapis.com/v1/{sourceName=projects/*/assets/**}:copyis used to copy an asset. -
The
sourceNamepath parameter specifies the asset to copy, requiringearthengine.assets.getIAM permission. -
The request body requires a
destinationNameand optionally includes anoverwriteboolean. -
The
destinationNamefield in the request body specifies where the asset will be copied to, requiringearthengine.assets.createIAM permission. -
A successful response contains an
EarthEngineAssetinstance.
Copies an asset.
HTTP request
POST https://earthengine.googleapis.com/v1/{sourceName=projects/*/assets/**}:copy
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
sourceName |
The name of the asset to copy. Authorization requires the following IAM permission on the specified resource
|
Request body
The request body contains data with the following structure:
| JSON representation |
|---|
{ "destinationName": string, "overwrite": boolean } |
| Fields | |
|---|---|
destinationName |
The destination name to which to copy the asset. Authorization requires the following IAM permission on the specified resource
|
overwrite |
Whether to allow overwriting an existing asset. |
Response body
If successful, the response body contains an instance of EarthEngineAsset.
Authorization scopes
Requires one of the following OAuth scopes:
https://www.googleapis.com/auth/earthenginehttps://www.googleapis.com/auth/cloud-platform
For more information, see the OAuth 2.0 Overview.