adobe-firefly-sdk
    Preparing search index...

    Hierarchy

    • HeyApiClient
      • CloudStorageSdk
    Index

    Constructors

    Properties

    client: Client
    __registry: HeyApiRegistry<CloudStorageSdk> = ...

    Methods

    • Finalize a block based file replacement job

      This endpoint finalizes the block replacement process by initiating an asynchronous job that will merge all uploaded blocks and replace the existing file's content. The file's assetId, permissions, and metadata are preserved.


      NOTE:

      The following rules govern how the server interprets the finalization request for a block-based replacement:

      • The size provided during the initiate request is treated as an estimate, not a strict validation boundary.
      • Clients are not penalized if the actual uploaded content size differs from the declared size.
      • In future, clients will be able to extend block sets if their initial estimate is too low (see Future Enhancements).
      • Clients are allowed to skip any block from the original transferLinks list, as long as part numbers remain ordered and are accurately reported in the usedTransferLinks array during finalize.
      • Skipped parts should simply be omitted from usedTransferLinks.
      • The used part numbers explicitly listed in the usedTransferLinks array.
      • The server will stitch together content in the order of these part numbers.
      • Any parts not listed will be ignored even if data was uploaded to them.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          FinalizeBlockBasedFileReplacementResponses,
          FinalizeBlockBasedFileReplacementErrors,
          ThrowOnError,
          "fields",
      >

    • Finalize a block based file upload job

      This endpoint finalizes the block upload process by initiating an asynchronous job that will merge all uploaded blocks and creates the final file asset. In case of asynchronous operation success, the asset field will contain the newly created file's metadata as defined by File Schema.


      NOTE:

      The following rules govern how the server interprets the finalization request for a block-based upload:

      • The size provided during the initiate request is treated as an estimate, not a strict validation boundary.
      • Clients are not penalized if the actual uploaded content size differs from the declared size.
      • In future, clients will be able to extend block sets if their initial estimate is too low (see Future Enhancements).
      • Clients are allowed to skip any block from the original transferLinks list, as long as part numbers remain ordered and are accurately reported in the usedTransferLinks array during finalize.
      • Skipped parts should simply be omitted from usedTransferLinks.
      • The used part numbers explicitly listed in the usedTransferLinks array.
      • The server will stitch together content in the order of these part numbers.
      • Any parts not listed will be ignored even if data was uploaded to them.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          FinalizeBlockBasedFileUploadResponses,
          FinalizeBlockBasedFileUploadErrors,
          ThrowOnError,
          "fields",
      >

    • Get a file by ID

      This endpoint retrieves full metadata for a specific File identified by its assetId. This includes file attributes such as name, type, creation details, and permissions.


      NOTE:

      • The file must exist and the requester must have at least read-level access.
      • If the file is not found or access is denied, appropriate error responses will be returned.
      • Discarded files can be retrieved using this endpoint.
      • If the file exists, but the requester does not have the requisite permissions:
        • The API will behave as if the file does not exist.
        • It will return a 404 Not Found response, even though the asset technically exists in the system.

      Type Parameters

      • ThrowOnError extends boolean = false

      Parameters

      Returns RequestResult<GetFileResponses, GetFileErrors, ThrowOnError, "fields">

    • Get All roles for a File

      This endpoint is deprecated and will be removed on 3/31/2025. Please use the /files/{assetId}/roles endpoint instead.

      The endpoint retrieves the explicit roles assigned to all users and groups for a specific file, identified by its assetId. This includes only the direct access control entries defined on the file itself and does not include any roles that are inherited from parent folders or the containing project.


      NOTE:

      • The response lists all users and groups that have direct access to the file, along with their respective roles (e.g., comment, edit).
      • This data is useful for auditing and role management but does not represent the full effective access unless inheritance is also considered.
      • The file must exist and the requester must have at least read-level access. If the file is not found or access is denied, appropriate error responses will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          GetFilePermissionsResponses,
          GetFilePermissionsErrors,
          ThrowOnError,
          "fields",
      >

    • Get All roles for a File

      The endpoint retrieves the explicit roles assigned to all users and groups for a specific file, identified by its assetId. This includes only the direct access control entries defined on the file itself and does not include any roles that are inherited from parent folders or the containing project.


      NOTE:

      • The response lists all users and groups that have direct access to the file, along with their respective roles (e.g., comment, edit).
      • This data is useful for auditing and role management but does not represent the full effective access unless inheritance is also considered.
      • The file must exist and the requester must have at least read-level access. If the file is not found or access is denied, appropriate error responses will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<GetFileRolesResponses, GetFileRolesErrors, ThrowOnError, "fields">

    • Get a folder by ID

      This endpoint retrieves full metadata for a specific Folder identified by its assetId. This includes folder attributes such as name, type, creation details, and permissions.


      NOTE:

      • The folder must exist and the requester must have at least read-level access.
      • If the folder is not found or access is denied, appropriate error responses will be returned.
      • Discarded folders can be retrieved using this endpoint.
      • If the folder exists, but the requester does not have the requisite permissions:
        • The API will behave as if the folder does not exist.
        • It will return a 404 Not Found response, even though the asset technically exists in the system.

      Type Parameters

      • ThrowOnError extends boolean = false

      Parameters

      Returns RequestResult<GetFolderResponses, GetFolderErrors, ThrowOnError, "fields">

    • Get Paginated List of Children of a Folder

      This endpoint retrieves a paginated list of top-level assets (folders, files, or other resources) contained within a specified folder, identified by its assetId. This allows clients to explore the immediate children of the folder, supporting use cases like folder browsing and navigation.

      The response includes all assets that the requester is authorized to view — regardless of asset type — excluding any that are hidden or discarded. Each item in the list contains basic metadata about the asset such as name, type, path, and identifiers.


      NOTE:

      • The response supports cursor-based pagination and includes a nextUrl field when additional pages are available.
      • If there are no further results, the nextUrl field is omitted.
      • The requester must have at least read-level access to the folder.
      • Assets are returned with basic metadata such as name, type, and hierarchy position.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          GetFolderChildrenResponses,
          GetFolderChildrenErrors,
          ThrowOnError,
          "fields",
      >

    • Get a project by ID

      This endpoint retrieves full metadata for a specific Project identified by its assetId. This includes project attributes such as name, type, creation details, and permissions.


      NOTE:

      • The project must exist and the requester must have at least read-level access.
      • If the project is not found or access is denied, appropriate error responses will be returned.
      • Discarded projects can be retrieved using this endpoint.
      • If the project exists, but the requester does not have the requisite permissions:
        • The API will behave as if the project does not exist.
        • It will return a 404 Not Found response, even though the asset technically exists in the system.

      Type Parameters

      • ThrowOnError extends boolean = false

      Parameters

      Returns RequestResult<GetProjectResponses, GetProjectErrors, ThrowOnError, "fields">

    • Get Paginated List of Children of a Project

      This endpoint retrieves a paginated list of top-level assets (folders, files, or other resources) contained within a specified project, identified by its assetId. This allows clients to explore the immediate children of the project, supporting use cases like project browsing and navigation.

      The response includes all assets that the requester is authorized to view — regardless of asset type — excluding any that are hidden or discarded. Each item in the list contains basic metadata about the asset such as name, type, path, and identifiers.


      NOTE:

      • The response supports cursor-based pagination and includes a nextUrl field when additional pages are available.
      • If there are no further results, the nextUrl field is omitted.
      • The requester must have at least read-level access to the project.
      • Assets are returned with basic metadata such as name, type, and hierarchy position.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          GetProjectChildrenResponses,
          GetProjectChildrenErrors,
          ThrowOnError,
          "fields",
      >

    • Get All roles for a Project

      This endpoint is deprecated and will be removed on 3/31/2025. Please use the /projects/{assetId}/roles endpoint instead.

      The endpoint retrieves the explicit roles assigned to all users and groups for a specific project, identified by its assetId. This includes only the direct access control entries defined on the project itself and does not include any roles that are inherited from parent folders or collections.


      NOTE:

      • The response lists all users and groups that have direct access to the project, along with their respective roles (e.g., comment, edit).
      • This data is useful for auditing and role management but does not represent the full effective access unless inheritance is also considered.
      • The project must exist and the requester must have at least read-level access. If the project is not found or access is denied, appropriate error responses will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          GetProjectPermissionsResponses,
          GetProjectPermissionsErrors,
          ThrowOnError,
          "fields",
      >

    • Get All roles for a Project

      The endpoint retrieves the explicit roles assigned to all users and groups for a specific project, identified by its assetId. This includes only the direct access control entries defined on the project itself and does not include any roles that are inherited from parent folders or collections.


      NOTE:

      • The response lists all users and groups that have direct access to the project, along with their respective roles (e.g., comment, edit).
      • This data is useful for auditing and role management but does not represent the full effective access unless inheritance is also considered.
      • The project must exist and the requester must have at least read-level access. If the project is not found or access is denied, appropriate error responses will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          GetProjectRolesResponses,
          GetProjectRolesErrors,
          ThrowOnError,
          "fields",
      >

    • Initialize a block based file replacement job

      Initializes a block based replacement job for an existing file. The init response provides a set of pre-signed URLs for uploading individual blocks, transferred over separate requests. Once the replacement file content is uploaded, the finalize endpoint is called to finalize the replacement.

      The file's assetId, permissions, and metadata are preserved while the content is replaced.


      NOTE: For files 10 MB or larger, direct replacement is not supported. Clients must use this block-based replacement workflow. block-based transfer is allowed for any size


      Client sends a POST request to initiate the block replacement and receives a response with URLs for uploading individual blocks and finalizing the transfer.

      Client issues PUT requests to the provided Block Transfer URLs, sending file data in chunks. These can be uploaded in parallel.


      NOTE: ####Uploading File Blocks After receiving transferLinks, clients can use them to upload individual blocks: PUT

      • Authorization Header: Must NOT be included in the request.
      • Success Response: 200 OK indicates successful block upload.
      • Expiration Handling: Each upload session is time-bound. If blocks are not uploaded within the specified expiration window (urlExpirationDate field from the initiation response), the operation may fail.
        • Always check and respect the urlExpirationDate timestamp in the response from the Block Upload Init endpoint.

      After all blocks are uploaded, the client calls the Block Finalize URL to trigger the replacement.

      Finalize operation's response includes a Monitor URL to check the final status.

      Initialize the Block-Based Replacement

      This endpoint allows clients to initiate the replacement of an existing file's content using block-based transfer.


      NOTE:

      • The expiration duration of transfer URLs is explicitly provided to the client in the response
      • The Content-Type must match the existing file's media type. Attempting to change the content type will result in a 415 Unsupported Media Type error.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          InitBlockBasedFileReplacementResponses,
          InitBlockBasedFileReplacementErrors,
          ThrowOnError,
          "fields",
      >

    • Initialize a block based file upload job

      This, along with the set of related APIs enables the upload of large files by splitting the content into multiple blocks, transferred over separate requests. This method is ideal for files larger than 10 MB, offering parallelism, resumability, and efficient error recovery.


      NOTE: For files 10 MB or larger, direct upload is not supported. Clients must use this block-based upload workflow. block-based transfer is allowed for any size


      Client sends a POST request to initiate the block upload and receives a response with URLs for uploading individual blocks and finalizing the transfer.

      Client issues PUT requests to the provided Block Transfer URLs, sending file data in chunks. These can be uploaded in parallel.


      NOTE: ####Uploading File Blocks After receiving transferLinks, clients can use them to upload individual blocks: PUT

      • Authorization Header: Must NOT be included in the request.
      • Success Response: 200 OK indicates successful block upload.
      • Expiration Handling: Each upload session is time-bound. If blocks are not uploaded within the specified expiration window (urlExpirationDate field from the initiation response), the operation may fail.
        • Always check and respect the urlExpirationDate timestamp in the response from the Block Upload Init endpoint.

      After all blocks are uploaded, the client calls the Block Finalize URL to trigger the upload to the destination location.

      Finalize operation's response includes a Monitor URL to check the final status.

      Initialize the Block-Based Upload

      This endpoint allows clients to initiate the creation of a new file using block-based transfer.


      NOTE: The expiration duration of transfer URLs is explicitly provided to the client in the response


      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          InitBlockBasedFileUploadResponses,
          InitBlockBasedFileUploadErrors,
          ThrowOnError,
          "fields",
      >

    • Patch Roles for a File

      This endpoint is deprecated and will be removed on 3/31/2025. Please use the /files/{assetId}/roles endpoint instead.

      This endpoint is used to manage the direct roles of a specific file, identified by its assetId. It allows clients to perform multiple types of role changes in a single request, including:

      • Addition of new users or groups to the access control list.
      • Update of roles for existing users or groups.
      • Removal of users or groups from the access control list.

      NOTE:

      • The request body supports three arrays: additions, updates, and deletions.
      • Multiple principals can be included across each action type.
      • Each principal must be mentioned only once across the entire request body.
      • Role changes apply directly to the file.
      Action Behavior
      additions Must include users/groups that do not already exist in the current ACL.
      updates Must target users/groups that already exist in the current ACL.
      deletions Must target users/groups that already exist in the current ACL.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          PatchFilePermissionsResponses,
          PatchFilePermissionsErrors,
          ThrowOnError,
          "fields",
      >

    • Patch Roles for a File

      This endpoint is used to manage the direct roles of a specific file, identified by its assetId. It allows clients to perform multiple types of role changes in a single request, including:

      • Addition of new users or groups to the access control list.
      • Update of roles for existing users or groups.
      • Removal of users or groups from the access control list.

      NOTE:

      • The request body supports three arrays: additions, updates, and deletions.
      • Multiple principals can be included across each action type.
      • Each principal must be mentioned only once across the entire request body.
      • Role changes apply directly to the file.
      Action Behavior
      additions Must include users/groups that do not already exist in the current ACL.
      updates Must target users/groups that already exist in the current ACL.
      deletions Must target users/groups that already exist in the current ACL.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          PatchFileRolesResponses,
          PatchFileRolesErrors,
          ThrowOnError,
          "fields",
      >

    • Patch Roles for a Project

      This endpoint is deprecated and will be removed on 3/31/2025. Please use the /projects/{assetId}/roles endpoint instead.

      This endpoint is used to manage the direct roles of a specific project, identified by its assetId. It allows clients to perform multiple types of role changes in a single request, including:

      • Addition of new users or groups to the access control list.
      • Update of roles for existing users or groups.
      • Removal of users or groups from the access control list.

      NOTE:

      • The request body supports three arrays: additions, updates, and deletions.
      • Multiple principals can be included across each action type.
      • Each principal must be mentioned only once across the entire request body.
      • Role changes are deeply inherited — they apply to the project and all of its descendant assets.
      Action Behavior
      additions Must include users/groups that do not already exist in the current ACL.
      updates Must target users/groups that already exist in the current ACL.
      deletions Must target users/groups that already exist in the current ACL.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          PatchProjectPermissionsResponses,
          PatchProjectPermissionsErrors,
          ThrowOnError,
          "fields",
      >

    • Patch Roles for a Project

      This endpoint is used to manage the direct roles of a specific project, identified by its assetId. It allows clients to perform multiple types of role changes in a single request, including:

      • Addition of new users or groups to the access control list.
      • Update of roles for existing users or groups.
      • Removal of users or groups from the access control list.

      NOTE:

      • The request body supports three arrays: additions, updates, and deletions.
      • Multiple principals can be included across each action type.
      • Each principal must be mentioned only once across the entire request body.
      • Role changes are deeply inherited — they apply to the project and all of its descendant assets.
      Action Behavior
      additions Must include users/groups that do not already exist in the current ACL.
      updates Must target users/groups that already exist in the current ACL.
      deletions Must target users/groups that already exist in the current ACL.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          PatchProjectRolesResponses,
          PatchProjectRolesErrors,
          ThrowOnError,
          "fields",
      >

    • Restore a soft-deleted file.

      This endpoint restores an existing file, identified by its assetId, within the organization's ESM shared storage to an ACTIVE state. This operation is only permitted if the requester has appropriate write-level permissions on the file.


      NOTE:

      • Files already in an ACTIVE state will remain ACTIVE and return 200 OK.
      • Restore calls made on assets in a DELETED_PARENT state will return a 409 Conflict error.
      • Hard-deleted files will return a 404 Not Found error.
      • If an asset with the same path already exists, the restored file will be renamed automatically.
      • If the requester lacks the required permissions or the file does not exist, an appropriate error response will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Parameters

      Returns RequestResult<RestoreFileResponses, RestoreFileErrors, ThrowOnError, "fields">

    • Restore a soft-deleted folder.

      This endpoint restores an existing folder, identified by its assetId, within the organization's ESM shared storage to an ACTIVE state. Descendants of the folder will have their states recomputed to their previous state. This operation is only permitted if the requester has appropriate write-level permissions on the folder.


      NOTE:

      • Folders already in an ACTIVE state will remain ACTIVE and return 200 OK.
      • Restore operations can only be invoked on roots of DELETED trees. Restore calls made on assets in a DELETED_PARENT state will return a 409 Conflict error.
      • Descendants of this folder that were in a DELETED state prior its deletion will remain DELETED. Their respective descendants will also remain in a DELETED_PARENT or DELETED state as before.
      • Hard-deleted folders will return a 404 Not Found error.
      • If an asset with the same path already exists, the restored folder will be renamed automatically.
      • If the requester lacks the required permissions or the folder does not exist, an appropriate error response will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          RestoreFolderResponses,
          RestoreFolderErrors,
          ThrowOnError,
          "fields",
      >

    • Restore a soft-deleted project.

      This endpoint restores an existing project, identified by its assetId, within the organization's ESM shared storage to an ACTIVE state. Descendants of the project will have their states recomputed to their previous state. This operation is only permitted if the requester has appropriate write-level permissions on the project.


      NOTE:

      • Projects already in an ACTIVE state will remain ACTIVE and return 200 OK.
      • Descendants that were in a DELETED state prior to the deletion of this project will remain DELETED. Their respective descendants will also remain in the DELETED_PARENT or DELETED state as before.
      • Hard-deleted projects will return a 404 Not Found error.
      • If the requester lacks the required permissions or the project does not exist, an appropriate error response will be returned.

      Type Parameters

      • ThrowOnError extends boolean = false

      Returns RequestResult<
          RestoreProjectResponses,
          RestoreProjectErrors,
          ThrowOnError,
          "fields",
      >