importExternalFile

Import external file. Requires project.uploads.write.

Arguments

  • inputExternalStorageImportInput!required

  • input.providerString!required

    Storage provider accessed through the caller's own personal connection. A human caller is required; agent, run, and service-account credentials are refused.

  • input.projectReferenceString

    Project ID or slug. Requires project.uploads.write and destination upload edit permission; quota and plan limits apply. Uses the caller's own personal provider connection.

  • input.fileIdString!required

  • input.basePathString

  • input.folderPathString

    Destination folder inside Uploads; the Uploads root when omitted.

  • input.timestampPrefixBoolean

  • input.visibilityUploadFolderVisibility

    Visibility of the new upload; inherited from the destination when omitted. Setting it needs upload admin access on the destination, and public a paid plan. One of project, public, private.

  • input.idempotencyKeyString

    1-128 characters without whitespace. A retry with the same key and input within 24 hours returns the first import instead of importing again.

Responses

mutation ImportExternalFile($input: ExternalStorageImportInput!) {  importExternalFile(input: $input) {    upload {      id      projectId      path      name      mimeType      sizeBytes      visibility    }    source {      provider      fileId    }  }}
{  "data": {    "importExternalFile": {      "upload": {        "id": "string",        "projectId": "string",        "path": "string",        "name": "string",        "mimeType": "string",        "sizeBytes": 0,        "visibility": "string"      },      "source": {        "provider": "string",        "fileId": "string"      }    }  }}

The ExternalStorageImport! in data.importExternalFile.