Skills

Update Box Skill cards on file

Changed on

Updates one or more Box Skills metadata cards to a file.

put/files/{file_id}/metadata/global/boxSkillsCards

Request

  • Base URL
    https://api.box.com/2.0
  • URL
    https://api.box.com/2.0/files/{file_id}/metadata/global/boxSkillsCards
  • Auth
    OAuth 2
    Authorization code: https://account.box.com/api/oauth2/authorize
    Token URL: https://api.box.com/oauth2/token

Path parameters

file_idstring required

The unique identifier that represents a file.

The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL https://*.app.box.com/files/123 the file_id is 123.

Request body

op'replace'

The value will always be replace.

pathstring

The JSON Path that represents the card to replace. In most cases this will be in the format /cards/{index} where index is the zero-indexed position of the card in the list of cards.

Example request

[
  {
    "op": "replace",
    "path": "/cards/0",
    "value": {
      "created_at": "2018-04-13T13:53:23-07:00",
      "type": "skill_card",
      "skill_card_type": "keyword",
      "skill_card_title": {
        "code": "labels",
        "message": "Labels"
      },
      "skill": {
        "type": "service",
        "id": "image-recognition-service"
      },
      "invocation": {
        "type": "skill_invocation",
        "id": "image-recognition-service-123"
      },
      "entries": [
        {
          "text": "keyword1"
        }
      ]
    }
  }
]

Response

Returns the updated metadata template, with the custom template data included.

$canEditboolean

Whether the user can edit this metadata.

$idstring uuid

A UUID to identify the metadata object.

$parentstring

An ID for the parent folder.

$scopestring

An ID for the scope in which this template has been applied.

$templatestring

The name of the template.

$typestring

A unique identifier for the "type" of this instance. This is an internal system property and should not be used by a client application.

$typeVersioninteger

The last-known version of the template of the object. This is an internal system property and should not be used by a client application.

$versioninteger

The version of the metadata object. Starts at 0 and increases every time a user-defined property is modified.

Example response

{
  "$canEdit": true,
  "$id": "01234500-12f1-1234-aa12-b1d234cb567e",
  "$parent": "folder_59449484661,",
  "$scope": "enterprise_27335",
  "$template": "properties",
  "$type": "properties-6bcba49f-ca6d-4d2a-a758-57fe6edf44d0",
  "$typeVersion": 2,
  "$version": 1,
  "cards": [
    {
      "created_at": "2018-04-13T13:53:23-07:00",
      "type": "skill_card",
      "skill_card_type": "keyword",
      "skill_card_title": {
        "code": "labels",
        "message": "Labels"
      },
      "skill": {
        "type": "service",
        "id": "image-recognition-service"
      },
      "invocation": {
        "type": "skill_invocation",
        "id": "image-recognition-service-123"
      },
      "entries": [
        {
          "text": "keyword1"
        }
      ]
    }
  ]
}

Changes

    • warning

      added the new unprocessable_entity enum value to the response property for the response status

    • warning

      added the new unprocessable_entity enum value to the response property for the response status