All Products
Search
Document Center

Cloud Backup:CreateTempFileUploadUrl

Last Updated:Aug 28, 2026

Generates the parameters and signature for uploading a file to Object Storage Service (OSS).

Operation description

  1. You can use the returned values to upload a file directly to Object Storage Service (OSS) by using a form.

  2. For more information about form-based uploads, see OSS documentation.

  3. Files uploaded to OSS are periodically deleted by the system.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

hbr:CreateTempFileUploadUrl

create

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

FileName

string

Yes

The name of the file to be uploaded.

file-list.txt

Response elements

Element

Type

Description

Example

object

Endpoint

string

The OSS endpoint for the file upload.

oss-cn-shenzhen.aliyuncs.com

RequestId

string

The request ID.

F4EEB401-DD21-588D-AE3B-1E835C7655E1

ExpireTime

integer

The expiration time of the upload signature, in UNIX timestamp format. Unit: seconds.

1654326678

Success

boolean

Indicates whether the request was successful. Valid values:

  • true: The request is successful.

  • false: The request fails.

true

Code

string

The HTTP status code. A value of 200 indicates success.

200

TempFileKey

string

The OSS object key for the file upload.

temp/1440155109798732/upload/2022-07-29/49bed34c-b430-4e7e-89b1-4be2b734f95c/iaclone.diff

Message

string

The response message. "successful" is returned on success; otherwise, an error message is returned.

successful

BucketName

string

The name of the destination OSS bucket.

hbr-temp-bucket

OssAccessKeyId

string

The AccessKey ID for the OSS upload.

LTAI****Up

Policy

string

The upload policy for the OSS form upload.

eyJleH****V19

Signature

string

The signature for the OSS form upload.

RmhI****0A=

Examples

Success response

JSON format

{
  "Endpoint": "oss-cn-shenzhen.aliyuncs.com",
  "RequestId": "F4EEB401-DD21-588D-AE3B-1E835C7655E1",
  "ExpireTime": 1654326678,
  "Success": true,
  "Code": "200",
  "TempFileKey": "temp/1440155109798732/upload/2022-07-29/49bed34c-b430-4e7e-89b1-4be2b734f95c/iaclone.diff",
  "Message": "successful",
  "BucketName": "hbr-temp-bucket",
  "OssAccessKeyId": "LTAI****Up",
  "Policy": "eyJleH****V19",
  "Signature": "RmhI****0A="
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.