Skip to Content
StoreOSv0.27.1
Core GraphQL APIReferenceMutations

Files__update

Authenticated · x-tenant · Update file library metadata (alt text). Requires a signed-in staff user. Needs the `files__File` `update` permission. Send the `x-tenant` header (the gateway sets it from your API key).

MUTATIONfiles__update(body: UpdateFileInput!): File!

Authenticated · x-tenant · Update file library metadata (alt text). Requires a signed-in staff user. Needs the files__File update permission. Send the x-tenant header (the gateway sets it from your API key).

Arguments

body*

Returns

  1. files__update
_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
mutation Files__update($body: UpdateFileInput!) {  files__update(body: $body) {    _id    alt    commits {      action      commitedBy {        email        name        phoneNumber        referenceId      }      committedAt      note    }    createdAt    createdBy {      email      name      phoneNumber      referenceId    }    directory    mimeType    originalName    size    tenant  }}
Variables
{  "body": {    "id": "1"  }}
Example Response
{  "data": {    "files__update": {      "_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"    }  }}