Share via


Datasets - Start Pending Upload Version

Start a new or get an existing pending upload of a dataset for a specific version.

POST {endpoint}/datasets/{name}/versions/{version}/startPendingUpload?api-version=v1

URI Parameters

Name In Required Type Description
endpoint
path True

string (uri)

Project endpoint. In the form "https://your-ai-services-account-name.services.ai.azure.com/api/projects/_project" if your Foundry Hub has only one Project, or to use the default Project in your Hub. Or in the form "https://your-ai-services-account-name.services.ai.azure.com/api/projects/your-project-name" if you want to explicitly specify the Foundry Project name.

name
path True

string

The name of the resource

version
path True

string

The specific version id of the DatasetVersion to operate on.

api-version
query True

string

minLength: 1

The API version to use for this operation.

Request Body

Name Required Type Description
pendingUploadType True enum:

BlobReference

BlobReference is the only supported type.

connectionName

string

Azure Storage Account connection name to use for generating temporary SAS token

pendingUploadId

string

If PendingUploadId is not provided, a random GUID will be used.

Responses

Name Type Description
200 OK

PendingUploadResponse

The request has succeeded.

Other Status Codes

Azure.Core.Foundations.ErrorResponse

An unexpected error response.

Headers

x-ms-error-code: string

Security

OAuth2Auth

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/v2.0/authorize

Scopes

Name Description
https://ai.azure.com/.default

Examples

Datasets_StartPendingUploadVersion_MaximumSet
Datasets_StartPendingUploadVersion_MinimumSet

Datasets_StartPendingUploadVersion_MaximumSet

Sample request

POST {endpoint}/datasets/cncrcmiaksswirlujwcptxeaef/versions/jkqqzmj/startPendingUpload?api-version=v1

{
  "pendingUploadId": "gxuutkdhlygsmsbtszqzx",
  "connectionName": "hsgskbhwucytwglwlm",
  "pendingUploadType": "BlobReference"
}

Sample response

{
  "blobReference": {
    "blobUri": "kbodccbnhdznekrtu",
    "storageAccountArmId": "gcsdeid",
    "credential": {
      "sasUri": "mzmtfelripgmz",
      "type": "SAS"
    }
  },
  "pendingUploadId": "qdxymiww",
  "version": "bofnujdjvnnhjtzzu",
  "pendingUploadType": "BlobReference"
}

Datasets_StartPendingUploadVersion_MinimumSet

Sample request

POST {endpoint}/datasets/atopkjwxsjtforndczju/versions/yftpnjxwjylhixypopcytxd/startPendingUpload?api-version=v1

{
  "pendingUploadType": "BlobReference"
}

Sample response

{
  "blobReference": {
    "blobUri": "kbodccbnhdznekrtu",
    "storageAccountArmId": "gcsdeid",
    "credential": {
      "sasUri": "mzmtfelripgmz",
      "type": "SAS"
    }
  },
  "pendingUploadId": "qdxymiww",
  "pendingUploadType": "BlobReference"
}

Definitions

Name Description
Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Azure REST API guidelines - https://aka.ms/AzureRestApiGuidelines#handling-errors.

BlobReference

Blob reference details.

PendingUploadRequest

Represents a request for a pending upload.

PendingUploadResponse

Represents the response for a pending upload request

SasCredential

SAS Credential definition

Azure.Core.Foundations.Error

The error object.

Name Type Description
code

string

One of a server-defined set of error codes.

details

Azure.Core.Foundations.Error[]

An array of details about specific errors that led to this reported error.

innererror

Azure.Core.Foundations.InnerError

An object containing more specific information than the current object about the error.

message

string

A human-readable representation of the error.

target

string

The target of the error.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Name Type Description
error

Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Azure REST API guidelines - https://aka.ms/AzureRestApiGuidelines#handling-errors.

Name Type Description
code

string

One of a server-defined set of error codes.

innererror

Azure.Core.Foundations.InnerError

Inner error.

BlobReference

Blob reference details.

Name Type Description
blobUri

string

Blob URI path for client to upload data. Example: https://blob.windows.core.net/Container/Path

credential

SasCredential

Credential info to access the storage account.

storageAccountArmId

string

ARM ID of the storage account to use.

PendingUploadRequest

Represents a request for a pending upload.

Name Type Description
connectionName

string

Azure Storage Account connection name to use for generating temporary SAS token

pendingUploadId

string

If PendingUploadId is not provided, a random GUID will be used.

pendingUploadType enum:

BlobReference

BlobReference is the only supported type.

PendingUploadResponse

Represents the response for a pending upload request

Name Type Description
blobReference

BlobReference

Container-level read, write, list SAS.

pendingUploadId

string

ID for this upload request.

pendingUploadType enum:

BlobReference

BlobReference is the only supported type

version

string

Version of asset to be created if user did not specify version when initially creating upload

SasCredential

SAS Credential definition

Name Type Description
sasUri

string

SAS uri

type enum:

SAS

Type of credential