Get details of an export job

This call will return the details of an export job.

📘

When exporting a file from the CGC to an attached volume, export is possible only to a volume that is in the same location (cloud provider and region) as the project from which the file is being exported.

When you export a file from a project on the CGC into a volume, you write to your cloud storage bucket on Amazon Web Services. This call obtains the details of that job.

Learn more about using the Volumes API for Amazon S3.

https://cgc-api.sbgenomics.com/v2/storage/exports/{export_id}

Request

Example request

GET /v2/storage/exports/5AfGvYSsAgQ9BxbBWUb2vLGeLLB56wL2 HTTP/1.1
Host: cgc-api.sbgenomics.com
X-SBG-Auth-Token: 3210a98c1db9318fa9d9273156740f74
Content-type: application/json
curl -s -H "X-SBG-Auth-Token: 3210a98c1db9318fa9d9273156740f74" -H "Content-Type: application/json" -X GET "https://cgc-api.sbgenomics.com/v2/storage/exports/5AfGvYSsAgQ9BxbBWUb2vLGeLLB56wL2"

Header Fields

KeyDescription of value
X-SBG-Auth-Token
required
Your CGC authentication token.
Content-type
required
application/json

Path parameters

KeyDescription of value
export_idThe ID of the export job as returned by Start an export job.

Response

See a list of CGC-specific response codes that may be contained in the body of the response.

Response body

The response object contains information about the status of the export job. The information is structured using the following key-value pairs:

KeyData type of valueDescription of value
idStringID of this export job
stateStringThe state of this export job. Possible values are:
PENDING: the export is queued;
RUNNING: the export is running;
COMPLETED: the export has completed successfully;
FAILED: the export has failed.
sourceObjectExport source, as passed when this job was started by the call to start an export job .
fileStringID of the file that was exported.
destinationObjectExport destination, as passed when this job was started by the call to Start an export job.
volumeStringID of the volume where to export.
`locationStringLocation on the volume where the file should be exported.
started_onStringTime when the export job was started.
finished_onStringTime when the export job was finished.
propertiesObjectContains properties related to the export, including:
"sse_algorithm" - algorithm used for S3 encryption
"aws_storage_class" - storage class (STANDARD or GLACIER)
* "aws_canned_acl" - ACL which is set on the S3 bucket
overwriteBooleanWhether the file should be overwritten in the destination.

Example response body

{
  "href": "https://cgc-api.sbgenomics.com/v2/storage/exports/5AfGvYSsAgQ9BxbBWUb2vLGeLLB56wL2",
  "id": "5AfGvYSsAgQ9BxbBWUb2vLGeLLB56wL2",
  "state": "COMPLETED",
  "source": {
    "file": "576159f7f53e9e1de6ae7b5f0"
  },
  "destination": {
    "volume": "rfranklin/output",
    "location": "output.vcf"
  },
  "started_on": "2016-06-15T19:17:39Z",
  "finished_on": "2016-06-15T19:17:41Z",
  "properties": {
    "sse_algorithm": "AES256",
    "aws_storage_class": "STANDARD",
    "aws_canned_acl": "public-read"
  },
  "overwrite": false
}
{
  "href": "https://cgc-api.sbgenomics.com/v2/storage/exports/DMqdv6gRq79BkNyHZnc6rhweyJt9KSAY",
  "id": "DMqdv6gRq79BkNyHZnc6rhweyJt9KSAY",
  "state": "FAILED",
  "error": {
    "status": 409,
    "code": 9107,
    "message": "Location on volume already contains a file. Check the documentation.",
    "more_info": "http://docs.cancergenomicscloud.com/docs/api-status-codes#9107"
  },
  "source": {
    "file": "57679b78f5b039a7e7fde6a9"
  },
  "destination": {
    "volume": "rfranklin/output",
    "location": "_4_s3_file.jpg"
  },
  "started_on": "2016-06-22T13:38:57Z",
  "finished_on": "2016-06-22T13:38:57Z",
  "properties": {
    "sse_algorithm": "AES256",
    "sse_aws_kms_key_id": "1234ab56-78d9-10a1-1d23-cc391dc099b",
    "aws_canned_acl": "public-read"
  },
  "overwrite": false
}
Language