All Products
Search
Document Center

Data Management:GetUserUploadFileJob

Last Updated:Nov 28, 2024

Obtains the information of a file upload task.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
dms:GetUserUploadFileJobget
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
JobKeystringYes

The key of the file upload task. The key is returned when you call the CreateUploadFileJob or CreateUploadOSSFileJob operation.

65254a49100e
TidlongNo

The tenant ID.

Note To view the tenant ID, move the pointer over the profile picture in the upper-right corner of the Data Management (DMS) console. For more information, see Manage DMS tenants.
-1

Response parameters

ParameterTypeDescriptionExample
object

Schema of Response

RequestIdstring

The request ID.

BDEFE9F2-B3B4-42D0-83AE-ECF9FC067DCD
Successboolean

Indicates whether the request was successful.

true
ErrorMessagestring

The error message.

UnknownError
ErrorCodestring

The error code.

UnknownError
UploadFileJobDetailobject

The details of the file upload task.

JobKeystring

The key of the file upload task.

65254a4c1614235217749100e
FileNamestring

The name of the file.

test.sql
FileSizelong

The size of the file. Unit: byte.

2968269
FileSourcestring

The purpose of the uploaded file. Valid values:

  • datacorrect: The file is uploaded to change data.
  • order_info_attachment: The file is uploaded as an attachment in a ticket.
  • big-file: The file is uploaded to import multiple data records at a time.
  • sqlreview: The file is uploaded for SQL review.
datacorrect
UploadTypestring

The method used to upload the file. Valid values:

  • URL
  • OSS
URL
UploadURLstring

The URL of the file.

Note This parameter is returned if the value of UploadType is URL.
http://xxxx/test.sql
UploadOSSParamobject

The information about the Object Storage Service (OSS) bucket from which the file is uploaded.

Note This parameter is returned if the value of UploadType is OSS.
Endpointstring

The endpoint of the OSS bucket.

http://oss-cn-hangzhou.aliyuncs.com
BucketNamestring

The name of the OSS bucket.

test_bucket
ObjectNamestring

The name of the OSS object.

test.sql
UploadedSizelong

The size of the uploaded file. Unit: byte.

2968269
JobStatusstring

The status of the file upload task. Valid values:

  • INIT: The file upload task was initialized.
  • PENDING: The file upload task waited to be run.
  • BE_SCHEDULED: The file upload task waited to be scheduled.
  • FAIL: The file upload task failed.
  • SUCCESS: The file upload task was successful.
  • RUNNING: The file upload task was being run.
SUCCESS
JobStatusDescstring

The information about the status of the file upload task.

success
AttachmentKeystring

The key of the file that is returned after the file is uploaded. You can use this key when you upload the file as an attachment in a ticket.

upload_3c7edea3-e4c3-4403-857d-737043036f69_test.sql

Examples

Sample success responses

JSONformat

{
  "RequestId": "BDEFE9F2-B3B4-42D0-83AE-ECF9FC067DCD",
  "Success": true,
  "ErrorMessage": "UnknownError",
  "ErrorCode": "UnknownError",
  "UploadFileJobDetail": {
    "JobKey": "65254a4c1614235217749100e",
    "FileName": "test.sql",
    "FileSize": 2968269,
    "FileSource": "datacorrect",
    "UploadType": "URL",
    "UploadURL": "http://xxxx/test.sql",
    "UploadOSSParam": {
      "Endpoint": "http://oss-cn-hangzhou.aliyuncs.com",
      "BucketName": "test_bucket",
      "ObjectName": "test.sql"
    },
    "UploadedSize": 2968269,
    "JobStatus": "SUCCESS",
    "JobStatusDesc": "success",
    "AttachmentKey": "upload_3c7edea3-e4c3-4403-857d-737043036f69_test.sql"
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history