Actions118
- Item Actions
- Activity Actions
- Asset Actions
- Authentication Actions
- Collection Actions
- Extension Actions
- Field Actions
- File Actions
- Folder Actions
- Permission Actions
- Preset Actions
- Relation Actions
- Revision Actions
- Role Actions
- Server Actions
- Setting Actions
- User Actions
- Utility Actions
- Webhook Actions
File → Import File
AI-generatedOverview
This node operation imports a file into the system by downloading it from a specified URL. It is useful for automating the process of fetching and storing files from external sources directly into the platform. For example, it can be used to import images, documents, or any file type from a web URL into a file management system.
Use Case Examples
- Importing an image file from a public URL to a content management system.
- Automatically downloading and storing a PDF report from a remote server.
Properties
| Name | Meaning |
|---|---|
| URL | The URL to download the file from, which is required to fetch the file. |
| Additional Fields | Optional additional properties of the file object in JSON format to customize the imported file's metadata. |
Output
JSON
file- The imported file object with its properties as returned by the system after import.
Dependencies
- Requires an API key credential or authentication token to access the file import API endpoint.
Troubleshooting
- Ensure the URL is accessible and publicly reachable; otherwise, the download will fail.
- Validate the JSON format of the additional file object properties to avoid parsing errors.
- Check for proper authentication credentials to avoid authorization errors during file import.
Links
- Directus File Object Documentation - Reference for the file object properties that can be used in the additional fields JSON.