{
  "$id": "https://curveballjs.org/schemas/a12nserver/user-app-permissions.json",
  "$schema": "https://json-schema.org/draft/2019-09/schema",
  "additionalProperties": false,
  "description": "This object contains the list of permissions/scopes that the user has granted to an app. The app may act on behalf of the user for these scopes.",
  "name": "User App Permissions",
  "properties": {
    "_links": {
      "description": "HAL Links"
    },
    "createdAt": {
      "description": "The date/time when the user first granted privileges to the app.",
      "format": "date-time",
      "type": "string"
    },
    "lastUsedAt": {
      "description": "The last time an access token was generated or refreshed by this app, for this user.",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "modifiedAt": {
      "description": "The date/time when the list of scopes was last updated.",
      "format": "date-time",
      "type": "string"
    },
    "scope": {
      "description": "List of scopes that were granted to the app",
      "items": {
        "type": "string"
      },
      "type": "array"
    }
  },
  "required": [
    "scope",
    "createdAt",
    "modifiedAt",
    "lastUsedAt"
  ],
  "type": "object"
}