Types > File
Commerce APITypesFile
File

Description

Topic: Files

Fields

crc32: Int!

CRC32 checksum of the original file

Example: 34539485


created_at: String!

The date and time when the file was created, RFC 3339 format

Example: "2014-09-04T12:23:34Z"

Timestamp (RFC 3339)


id: String!

A unique file identifier

Example: "fi_EQzGqWoY"


image_alt: String!

Alt title of the image


image_color: String!

Average color of the image

Example: "#ffffff"


image_duration: Int!

Duration of the video in milliseconds if file is a video

Example: 0


image_fallback: String!

Base64 miniature of the image suitable for inline rendering (webp file format)

Example: "UklGRrIFAABXRUJQVlA4IKYFAADQGACdASqAAC8AAMAUJYwDDaD295z4Jt/bwTtvB4uWTO7zj5N10H8J/GN679s+W/EU+Q/fL8zxezK/x/nvprchPozaLvrH2DTI2qUzsmTZ+wSHmKgrtkTks767dPgH+xctt/1jugOVBlJNqpxI"


image_height: Int!

Height of the image if file is an image

Example: 0


image_width: Int!

Width of the image if file is an image

Example: 0


imported_from_task: ShardedTask

Task this file is/was processed by

Expandable


is_binary: Boolean!

Is file a binary? (images are always binary)

Example: false


is_image: Boolean!

Is file an image?

Example: false


is_owned: Boolean!

Whether this file is owned by something

Example: false


is_uploaded: Boolean!

Was file uploaded?

Example: true


is_video: Boolean!

Is file a video?

Example: false


md5: String!

MD5 hash of the original file

Example: "00f6f616227c8f68c76f4c01de026dbf"


mime: String!

MIME type of the file

Example: "plain/text"


name: String!

Human-friendly name of the file

Example: "abc.txt"


path: String!

Internal storage path of the file

Example: "sh_EQzGqWoY/fi_EQzGqWoY/abc.txt"


pinned: Boolean!

Whether file is pinned or not

Example: false


public_url: String!

Publically available CDN URL of a file

Example: "https://cdn.lana.dev/sh_EQzGqWoY/fi_EQzGqWoY/image.jpg"


size: String!

Size of the file in bytes (string, because graphql is limited to int32)

Example: "0"


storage: FileStorage!

File storage type

Example: "general"


temp_path: String!

Internal path of the file in temporary storage, used internally, had to be exposed

Example: "sh_EQzGqWoY/550e8400-e29b-41d4-a716-446655440000"


Used By

Mutations

filesCreate, filesModify, filesUploaded

Queries

files, filesLookup

Types

Activity, Brand, BrandingField, Category, ContentBlock, CustomFieldObjects, FileExpandableItems, FilePage, FileSearchResult, MediaFile, Product, ProductReview, ProductVariant, Return, ShardedTask, ShardedTaskCSVImportInfo, UnifiedSearchResult

Preview (typescript)

Loading module