Skip to Content
StoreOSv0.27.1
Core GraphQL APIReferenceQueries

Files__file

Authenticated · x-tenant · Fetch one reusable file. Requires a signed-in staff user. Needs the `files__File` `read` permission. Send the `x-tenant` header (the gateway sets it from your API key).

QUERYfiles__file(where: CommonFindDocumentDto!): File

Authenticated · x-tenant · Fetch one reusable file. Requires a signed-in staff user. Needs the files__File read permission. Send the x-tenant header (the gateway sets it from your API key).

Arguments

where*

Returns

  1. files__file
_id*ID!
alt?String
commits?
createdAt?DateTime

A date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.

createdBy?
directory?String
file*
mimeType?String
originalName?String
size?Int
tenant*String!
updatedAt?DateTime

A date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.

usageCount?Int
usages?
Example Request
query Files__file($where: CommonFindDocumentDto!) {  files__file(where: $where) {    _id    alt    commits {      action      commitedBy {        email        name        phoneNumber        referenceId      }      committedAt      note    }    createdAt    createdBy {      email      name      phoneNumber      referenceId    }    directory    mimeType    originalName    size    tenant  }}
Variables
{  "where": {    "and": [      {        "and": [          {            "and": [              {                "and": [                  {}                ],                "key": "string"              }            ],            "key": "string"          }        ],        "key": "string"      }    ],    "key": "string"  }}
Example Response
{  "data": {    "files__file": {      "_id": "1",      "alt": "string",      "commits": [        {          "action": "string",          "commitedBy": {            "email": "string",            "name": "string",            "phoneNumber": "string",            "referenceId": "1"          },          "committedAt": "<DateTime>",          "note": "string"        }      ],      "createdAt": "<DateTime>",      "createdBy": {        "email": "string",        "name": "string",        "phoneNumber": "string",        "referenceId": "1"      },      "directory": "string",      "mimeType": "string",      "originalName": "string",      "size": 10,      "tenant": "string"    }  }}