Skip to content

Clone Dataset

POST
/v2/datasets/copy
curl --request POST \
--url http://localhost:3000/v2/datasets/copy \
--header 'Content-Type: application/json' \
--data '{ "id": "api.datasets.copy", "ver": "v2", "ts": "2024-05-21T14:30:00Z", "params": { "msgid": "127384e4a-a051-4a9f-9b3f-a64a8034fad7" }, "request": { "source": { "datasetId": "dataset-telemetry", "isLive": true }, "destination": { "datasetId": "bew-copy-live2" } } }'
Media type application/json
object
Example
{
"id": "api.datasets.copy",
"ver": "v2",
"ts": "2024-05-21T14:30:00Z",
"params": {
"msgid": "127384e4a-a051-4a9f-9b3f-a64a8034fad7"
},
"request": {
"source": {
"datasetId": "dataset-telemetry",
"isLive": true
},
"destination": {
"datasetId": "bew-copy-live2"
}
}
}

OK

Media type application/json
object
Example
{
"id": "api.datasets.copy",
"ver": "v2",
"ts": "2024-11-19T12:56:12+05:30",
"params": {
"status": "SUCCESS",
"msgid": "127384e4a-a051-4a9f-9b3f-a64a8034fad7",
"resmsgid": "28072631-8e80-45eb-906f-d933a90646d0"
},
"responseCode": "OK",
"result": {
"dataset_id": "new-copy-live2",
"message": "Dataset clone successful"
}
}
X-Powered-By
string
Example
Express
Content-Length
integer
Example
296
ETag
string
Example
W/"128-bi4wSfgkyMP13qFE8VPTmgDdgLA"
Date
string
Example
Tue, 19 Nov 2024 07:26:12 GMT
Connection
string
Example
keep-alive
Keep-Alive
string
Example
timeout=5

Not Found

Media type application/json
object
Example
{
"id": "api.datasets.copy",
"ver": "v2",
"ts": "2024-11-19T12:52:41+05:30",
"params": {
"status": "FAILED",
"msgid": "127384e4a-a051-4a9f-9b3f-a64a8034fad7",
"resmsgid": "f2fd51bb-fc18-4278-a229-47fa25398e69"
},
"responseCode": "NOT_FOUND",
"result": {},
"error": {
"code": "DATASET_NOT_EXISTS",
"message": "Dataset dataset-telemetry does not exists"
}
}
X-Powered-By
string
Example
Express
Content-Length
integer
Example
328
ETag
string
Example
W/"148-jUDshghYf/jOhmmVkvtHlfJT864"
Date
string
Example
Tue, 19 Nov 2024 07:22:41 GMT
Connection
string
Example
keep-alive
Keep-Alive
string
Example
timeout=5