Imports
The ImportsClient class provides methods to import files from a connected account into the platform as assets and to review past imports. For the end-to-end workflow, see the Data connectors page.
Methods
Import files
Description: This method imports one or more files from the connected provider account into the platform as assets. Video files can be up to 10 GB, audio files up to 4 GB, and images up to 32 MB. For each newly imported file, the platform creates an asset in the processing status and fetches the file asynchronously. If you import a file that was already imported through this account, the platform returns the existing asset with its current status, without fetching the file again. If the earlier fetch had failed, the platform fetches the file again. The response contains one entry per requested file, in request order. Use the action property of each entry to identify which files were newly imported and which were already imported.
Function signature and example:
Parameters
The ImportFilesRequestItemsItem class contains the following property:
Return value
Returns an ImportResult object. The ImportResult class contains the following properties:
The ImportItem class contains the following properties:
The ImportItemError class contains the following properties:
API Reference
List imports
Description: This method returns a list of the imports for the specified connection. The platform returns the imports sorted by creation date, with the newest at the top of the list. Each import in the list is a summary and does not include the per-file details. To see them, use the retrieve_import method.
Function signature and example:
Parameters
Return value
Returns a ListImportsResponse object. The ListImportsResponse class contains the following properties:
The Import class contains the following properties:
API Reference
Retrieve an import
Description: This method retrieves a single import. For each file, the response includes the action property, which indicates the outcome of the import operation, and the status property, which reflects the current status of the asset each time you retrieve the import.
Function signature and example:
Parameters
Return value
Returns an ImportDetail object. The ImportDetail class contains all the properties of the Import object (see List imports), plus the following: