ResourceTypes

Realm Operations

The Resource Types resource is responsible for managing resource types, which define a template for the resources that Managing Policies policies apply to, and the actions associated with those resources. Available operations are Query, Read, Create, Update, Delete

Resource path:

/resourcetypes

Resource version: 1.0

create

Create new resource type

Usage

am> create ResourceTypes --realm Realm --id id --body body

Parameters

--id

The unique identifier for the resource.

--body

The resource in JSON format, described by the following JSON schema:

{
  "$schema" : "http://json-schema.org/draft-04/schema#",
  "description" : "Resource Types Resource schema",
  "type" : "object",
  "title" : "Resource Types Resource schema",
  "properties" : {
    "uuid" : {
      "title" : "UUID",
      "description" : "Unique identifier of the record",
      "type" : "string"
    },
    "name" : {
      "title" : "Name",
      "description" : "Resource type name",
      "type" : "string"
    },
    "description" : {
      "title" : "Description",
      "description" : "Resource type description",
      "type" : "string"
    },
    "patterns" : {
      "title" : "Patterns",
      "description" : "Resource type patterns",
      "type" : "array",
      "items" : {
        "type" : "string"
      }
    },
    "actions" : {
      "title" : "Actions",
      "description" : "Resource type actions",
      "type" : "object",
      "additionalProperties" : {
        "type" : "boolean"
      }
    },
    "createdBy" : {
      "title" : "Created by",
      "description" : "A string containing the universal identifier DN of the subject created the resource type",
      "type" : "string"
    },
    "creationDate" : {
      "title" : "Creation date",
      "description" : "An integer containing the creation date and time, in ISO 8601 format",
      "type" : "number"
    },
    "lastModifiedBy" : {
      "title" : "Last modifier",
      "description" : "A string containing the universal identifier DN of the subject that most recently updated the resource type. If the resource type has not been modified since it was created, this property will have the same value as createdBy",
      "type" : "string"
    },
    "lastModifiedDate" : {
      "title" : "Last modification date",
      "description" : "A string containing the last modified date and time, in ISO 8601 format. If the resource typ has not been modified since it was created, this property will have the same value as creationDate",
      "type" : "number"
    }
  }
}

delete

Delete resource type

Usage

am> delete ResourceTypes --realm Realm --id id

Parameters

--id

The unique identifier for the resource.

query

Query the collection of resource types

Usage

am> query ResourceTypes --realm Realm --filter filter

Parameters

--filter

A CREST formatted query filter, where "true" will query all. Fields that can be queried: [*]

read

Read from the resource types collection by unique identifier

Usage

am> read ResourceTypes --realm Realm --id id

Parameters

--id

The unique identifier for the resource.

update

Update an existing resource type

Usage

am> update ResourceTypes --realm Realm --id id --body body

Parameters

--id

The unique identifier for the resource.

--body

The resource in JSON format, described by the following JSON schema:

{
  "$schema" : "http://json-schema.org/draft-04/schema#",
  "description" : "Resource Types Resource schema",
  "type" : "object",
  "title" : "Resource Types Resource schema",
  "properties" : {
    "uuid" : {
      "title" : "UUID",
      "description" : "Unique identifier of the record",
      "type" : "string"
    },
    "name" : {
      "title" : "Name",
      "description" : "Resource type name",
      "type" : "string"
    },
    "description" : {
      "title" : "Description",
      "description" : "Resource type description",
      "type" : "string"
    },
    "patterns" : {
      "title" : "Patterns",
      "description" : "Resource type patterns",
      "type" : "array",
      "items" : {
        "type" : "string"
      }
    },
    "actions" : {
      "title" : "Actions",
      "description" : "Resource type actions",
      "type" : "object",
      "additionalProperties" : {
        "type" : "boolean"
      }
    },
    "createdBy" : {
      "title" : "Created by",
      "description" : "A string containing the universal identifier DN of the subject created the resource type",
      "type" : "string"
    },
    "creationDate" : {
      "title" : "Creation date",
      "description" : "An integer containing the creation date and time, in ISO 8601 format",
      "type" : "number"
    },
    "lastModifiedBy" : {
      "title" : "Last modifier",
      "description" : "A string containing the universal identifier DN of the subject that most recently updated the resource type. If the resource type has not been modified since it was created, this property will have the same value as createdBy",
      "type" : "string"
    },
    "lastModifiedDate" : {
      "title" : "Last modification date",
      "description" : "A string containing the last modified date and time, in ISO 8601 format. If the resource typ has not been modified since it was created, this property will have the same value as creationDate",
      "type" : "number"
    }
  }
}