Request

Response

    Get upload URLs
    GET

    spaces/{spaceId}/resources/{resourceId}/upload-urls

    Get presigned URLs to upload one or more parts of the resource to.

    Resource Information

    Method and URI
    GET
    https://developer.api.autodesk.com/flow/storage/v1/spaces/{spaceId}/resources/{resourceId}/upload-urls
    Authentication Context
    user context optional
    Required OAuth Scopes
    data:write
    Data Format
    JSON

    Request

    Headers

    Authorization*
    string
    Must be Bearer <token>, where <token> is obtained via either a two-legged or three-legged OAuth flow.
    region
    string
    The region targeted by the request. The usage of this header is recommended for faster processing. The region specified must match the region in which the targeted storage space was created or else the request will fail.
    * Required

    Request

    URI Parameters

    spaceId
    string
    The ID of the storage space.
    resourceId
    string
    The resource ID

    Request

    Query String Parameters

    expirationInMinutes
    int
    Specify the desired expiry time in minutes.
    numParts
    int
    The max number of parts to retrieve.
    partId
    int
    The ID of the first part to retrieve an upload URL for.
    uploadId
    string
    The upload ID as previously returned when an upload was created.

    Response

    HTTP Status Code Summary

    200
    OK
    OK
    400
    Bad Request
    Bad request - indicates an incorrectly structured or otherwise incorrect request.
    401
    Unauthorized
    Unauthorized - credentials are invalid or not provided in the request
    403
    Forbidden
    Forbidden - the user/entity does not have the required privileges to access this resource
    404
    Not Found
    The specified resource was not found
    429
    Too Many Requests
    Too Many Requests

    Response

    Header (429)

    Retry-After
    integer
    Specifies how many seconds to wait before making a new request.

    Response

    Body Structure (200)

    Expand all
    expiresAt
    datetime: ISO 8601
    Time of expiration for the URLs. This expiration time is approximate and may not exactly match the real expiration time.
    urls
    array: object
    An array
    partId
    int
    ID for an individual upload part
    url
    string
    Upload URL for the part.
    upload
    object
    Information about an upload operation
    expiresAt
    datetime: ISO 8601
    The time at which the upload must be completed. If the upload is not completed by this date, the upload expires.
    id
    string
    An ID for a specific upload operation
    resourceId
    string
    A unique ID for a specific resource

    Example

    This example retrieves 3 upload URLs for multipart upload on the resource inputFile.

    Request

    curl -v 'https://developer.api.autodesk.com/flow/storage/v1/spaces/scratch:@default/resources/inputFile/upload-urls?numParts=3' \
      -X 'GET' \
      -H 'Authorization: Bearer eyJhbGciOiJSU...' \
    

    Response

    {
      "urls": [
        {
          "url": "https://com-autodesk-oss-direct-upload.s3.amazonaws.com/bb..."
        },
        {
          "url": "https://com-autodesk-oss-direct-upload.s3.amazonaws.com/bb..."
        },
        {
          "url": "https://com-autodesk-oss-direct-upload.s3.amazonaws.com/bb..."
        }
      ],
      "upload": {
        "expiresAt": "2024-04-28T00:00:00Z",
        "id": "AQICAHjdZwoyNEgA8bmp66wGy6Ir33V...",
        "resourceId": "inputFile"
      }
    }
    
    Show More