vapi metadata privilege package: get
Retrieves privilege information about the package element corresponding to
package_id
.
Request:
HTTP request
GET https://{server}/rest/com/vmware/vapi/metadata/privilege/package/id:{package_id}
Path Parameters
Name | Type | Description |
---|---|---|
Required | ||
package_id | string | Identifier of the package element. |
Response:
HTTP Status Code: 200
Representations:
{
"value": {
"privileges": [
"string",
"string"
],
"services": [
{
"key": "obj-103",
"value": {
"operations": [
{
"key": "obj-103",
"value": {
"privilege_info": [
{
"privileges": [
"string",
"string"
],
"property_path": "string"
},
{
"privileges": [
"string",
"string"
],
"property_path": "string"
}
],
"privileges": [
"string",
"string"
]
}
}
]
}
}
]
}
}
"value": {
"privileges": [
"string",
"string"
],
"services": [
{
"key": "obj-103",
"value": {
"operations": [
{
"key": "obj-103",
"value": {
"privilege_info": [
{
"privileges": [
"string",
"string"
],
"property_path": "string"
},
{
"privileges": [
"string",
"string"
],
"property_path": "string"
}
],
"privileges": [
"string",
"string"
]
}
}
]
}
}
]
}
}
<?xml version="1.0" ?>
<ns0:Get-Result xmlns:ns0="http://vmware.com/vapi/metadata/privilege/package" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<value>
<services-array>
<array-item>
<value>
<operations-array>
<array-item>
<value>
<privilege_info-array>
<array-item>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
<property_path>string</property_path>
</array-item>
<array-item>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
<property_path>string</property_path>
</array-item>
</privilege_info-array>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
</value>
<key>obj-103</key>
</array-item>
</operations-array>
</value>
<key>obj-103</key>
</array-item>
</services-array>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
</value>
</ns0:Get-Result>
<ns0:Get-Result xmlns:ns0="http://vmware.com/vapi/metadata/privilege/package" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<value>
<services-array>
<array-item>
<value>
<operations-array>
<array-item>
<value>
<privilege_info-array>
<array-item>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
<property_path>string</property_path>
</array-item>
<array-item>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
<property_path>string</property_path>
</array-item>
</privilege_info-array>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
</value>
<key>obj-103</key>
</array-item>
</operations-array>
</value>
<key>obj-103</key>
</array-item>
</services-array>
<privileges-array>
<array-item>string</array-item>
<array-item>string</array-item>
</privileges-array>
</value>
</ns0:Get-Result>
Response Type:
Name | Type | Description |
---|---|---|
bold = required | ||
value | package_info | The vapi.metadata.privilege.package_info instance that corresponds to package_id . |
value.privileges | string[] | List of default privileges to be used for all the operations present in this package. If a particular operation element has no explicit privileges defined in the privilege definition file, these privileges are used for enforcing authorization. |
value.services | list | Information about all service elements contained in this package element that contain privilege information. The key in the key/value pairs is the identifier of the service element and the value in the key/value pairs is the privilege information for the service element. For an explanation of privilege information containment within service elements, see vapi.metadata.privilege.service. When clients pass a value of this structure as a parameter, the key in the field key/value pairs must be an identifier for the resource type: com.vmware.vapi.service . When operations return a value of this structure as a result, the key in the field key/value pairs will be an identifier for the resource type: com.vmware.vapi.service .List of {"key": string, "value": service_info} |
value.services[].key | string | |
value.services[].value | service_info | |
value.services[].value.operations | list | Information about all operation elements contained in this service element that contain privilege information. The key in the key/value pairs is the identifier of the operation element and the value in the key/value pairs is the privilege information for the operation element. For an explanation of containment of privilege information within operation elements, see vapi.metadata.privilege.service.operation. When clients pass a value of this structure as a parameter, the key in the field key/value pairs must be an identifier for the resource type:com.vmware.vapi.operation . When operations return a value of this structure as a result, the key in the field key/value pairs will be an identifier for the resource type: com.vmware.vapi.operation .List of {"key": string, "value": operation_info} |
value.services[].value.operations[].key | string | |
value.services[].value.operations[].value | operation_info | |
value.services[].value.operations[].value.privileges | string[] | List of all privileges assigned to the operation element. |
value.services[].value.operations[].value.privilege_info | privilege_info[] | Privilege information of all the parameter elements of the operation element. For an explanation of containment of privilege information within parameter elements, see vapi.metadata.privilege.privilege_info. |
value.services[].value.operations[].value.privilege_info[].property_path | string | The property_path points to an entity that is used in the operation element. An entity can either be present in one of the parameter elements or if a parameter is a structure element, it could also be present in one of the field elements. If the privilege is assigned to an entity used in the parameter, |
value.services[].value.operations[].value.privilege_info[].privileges | string[] | List of privileges assigned to the entity that is being referred by vapi.metadata.privilege.privilege_info.property_path. |
Errors:
HTTP Status Code | Type | Description |
---|---|---|
404 | not_found | if the package element associated with package_id does not have any privilege information. |