Skip to content

Latest commit

 

History

History
176 lines (126 loc) · 7.08 KB

protocol-specification-policies-retrieve.md

File metadata and controls

176 lines (126 loc) · 7.08 KB
title keywords tags permalink
Policies - Retrieve protocol specification
protocol, specification, retrieve, policy
protocol
protocol-specification-policies-retrieve.html

{% include note.html content="The topic path of policy commands contains no channel element. See the specification for details." %}

Retrieve a Policy

Retrieves a Policy identified by the <namespace>/<policyName> pair in the topic field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /
fields Contains a comma separated list of fields to be included in the returned JSON.

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /
value The Policy as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve a Policy

Retrieve Policy entries

Retrieves all entries of the policy identified by the <namespace>/<policyName> pair in the topic field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries
value The Policy entries as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve all Policy entries

Retrieve a Policy entry

Retrieve a Policy entry identified by the <namespace>/<policyName> pair in the topic field and the <label> in the path field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>
value The Policy entry as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve a single Policy entry

Retrieve Policy subjects

Retrieve the subjects of the policy identified by the <namespace>/<policyName> pair in the topic field and the <label> in the path field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/subjects

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/subjects
value The subjects of the Policy as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve all subjects

Retrieve a Policy subject

Retrieve specific subject of the policy identified by the <namespace>/<policyName> pair in the topic field and the <label> and <subjectId> in the path field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/subjects/<subjectId>

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/subjects/<subjectId>
value The subject of the policy as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve a single subject

Retrieve Policy resources

Retrieve all resources of the policy identified by the <namespace>/<policyName> pair in the topic field and the <label> in the path field.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/resources

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/resources
value The resources of the Policy as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve all resources

Retrieve a single Policy resources

Retrieve a resource identified by the <namespace>/<policyName> pair in the topic field and the <label> and <resource> in the pathfield.

Command

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/resources/<resource>

Response

Field Value
topic <namespace>/<policyName>/policies/commands/retrieve
path /entries/<label>/resources/<resource>
value The resource of the policy as JSON object, see Policy representation (JSON).
status code
200 Success.

Example: Retrieve a single resource