Querying for user types

To query Edgware for the list of user types, a JSON message of the following form is sent to the local Edgware node:

Field Value Description
op query:user-types Identifies a user type query message.
correl <correlation-id> Client-defined correlation ID to identify the response.

The query:user-types message may also include the following optional fields:

Field Value Description
type <user-type> Query for a specific user type.
attr <user-type-attributes> Query for specific user type attributes; will match any platform type containing these attributes exactly as specified.

If no optional fields are specified then the full list of available user types will be returned. Each optional field can contain a wildcard character (“*”) matching any string. Wildcards can be used alone or with partial text. Omitting an optional field is be equivalent to giving it the value “*”.

Matching user types are returned in a JSON message of the form:

Field Nested Field Value Description
op query-result:user-types Identifies a user type query result.
correl <correlation-id> Client-defined correlation ID to identify the response.
For each matching platform type the following information will be returned:
user-types Identifies the list of user types.
type <user-type> The user type.
desc <user-type-description> The free text description of the user type.
attr <user-type-attributes> The set of attributes associated with the user type.

Example

{
	"op" : "query:user-types",
	"correl" : "<correlation-id>",
}

Will generate a response in the form:

{
	"op" : "query-result:user-types",
	"correl" : "<correlation-id>",
	"user-types" : [
		{
			"type" "<user-type>",
			"desc" : "<user-type-description>",
			"attr" : "<user-type-attributes>"
		}
	]
}