API DocsRESTRemote file service

UpdateRemoteFile

Updates an existing remote file using using the list of fields specified in `update_mask`.

PATCH
/api/v1/remote-files

Request Body

application/jsonRequired

The request for a call to RemoteFileService_UpdateRemoteFile to update a remote file.

remoteFile
Required
object

updateMask
Required
string

The list of fields to be updated. The fields available to be updated are description and metadata.

curl -X PATCH "<API_URL>/api/v1/remote-files" \
  -H "Authorization: Bearer <API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "remoteFile": {
      "remoteFileId": "string",
      "organizationId": "string",
      "entityId": "string",
      "entityType": "ENTITY_TYPE_UNSPECIFIED",
      "fileName": "string",
      "fileMimeType": "string",
      "fileContentEncoding": "string",
      "storageKey": "string",
      "fileSize": "string",
      "description": "string",
      "videoMetadata": {
        "height": 0,
        "width": 0,
        "durationSeconds": 0.1,
        "timestamp": "2019-08-24T14:15:22Z"
      },
      "imageMetadata": {
        "height": 0,
        "width": 0
      },
      "audioMetadata": {
        "durationSeconds": 0.1,
        "timestamp": "2019-08-24T14:15:22Z"
      },
      "createdByUserId": "string",
      "modifiedByUserId": "string",
      "createdDate": "2019-08-24T14:15:22Z",
      "modifiedDate": "2019-08-24T14:15:22Z"
    },
    "updateMask": "string"
  }'

A successful response.

{
  "remoteFile": {
    "remoteFileId": "string",
    "organizationId": "string",
    "entityId": "string",
    "entityType": "ENTITY_TYPE_UNSPECIFIED",
    "fileName": "string",
    "fileMimeType": "string",
    "fileContentEncoding": "string",
    "storageKey": "string",
    "fileSize": "string",
    "description": "string",
    "videoMetadata": {
      "height": 0,
      "width": 0,
      "durationSeconds": 0.1,
      "timestamp": "2019-08-24T14:15:22Z"
    },
    "imageMetadata": {
      "height": 0,
      "width": 0
    },
    "audioMetadata": {
      "durationSeconds": 0.1,
      "timestamp": "2019-08-24T14:15:22Z"
    },
    "createdByUserId": "string",
    "modifiedByUserId": "string",
    "createdDate": "2019-08-24T14:15:22Z",
    "modifiedDate": "2019-08-24T14:15:22Z"
  }
}