The HPE GreenLake for Authorization API provides a unified way to manage the authorization function for HPE GreenLake cloud.
HPE GreenLake for Authorization API (1.0.0-beta)
https://global.api.greenlake.hpe.com/
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/
Roles
Roles are created in a Workspace, typically by an IAM administrator. They may be created by a Resource Provider (RP) if the RP has been granted the required privileges in the Workspace.
Requirements
- Roles must include at least one inline permission.
- There is a max limit of 100 Roles per workspace (in addition to the global predefined roles).
Role Assignments
Role assignments are composed of three pieces (principal, role, and scope). Role assigments associate a user, group, or service (principal) with a specific role (along with its permissions) at a particular scope (a resource or group of resources) to grant them access and specify their responsibilities within HPE GreenLake.
Note: There is a maximum limit of 50 role assignments per user per workspace.
Request
A scope group is a collection of scopes that can be assigned to a role assignment. This allows a single role assignment to cover multiple scopes.
Note:
- A scope group cannot contain another scope group (no nesting). Once created, a scope group will belong to a organization/workspace based on the caller context. The returned
grnattribute will include this context and can be used as a globally unique identifier.
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X POST \
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "sg1"
}'Created
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
A short description of the scope group.
The HPE GreenLake Resource Notation (GRN) is the standardized, URI-compatible syntax used to define and specify this scope within the HPE GreenLake.
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "type": "authorization/scope-group", "name": "sg1", "description": "This group gives access to resource \"host/123\"", "grn": "grn:glp/workspaces/05f0523c-fd03-47fc-981b-9c4333a37b60/regions/default/providers/authorization/scope-groups/05f0523c-fd03-47fc-981b-9c4333a37b78", "generation": 1, "createdAt": "2023-04-06T22:45:59.759943+00:00", "updatedAt": "2023-04-06T22:45:59.759943+00:00" }
Request
Retrieves scope groups by applying OData 4.0 filters. Use the filter parameter to provide a filter string. Supports in operator on name or grn attributes.
Example Request: /authorization/v1beta1/scope-groups?filter=grn in ('grn:glp/workspaces/05f0523c-fd03-47fc-981b-9c4333a37b70/regions/default/providers/authorization/scope-groups/123')
Note:
- Supported operators: Only in operator is supported.
Total number of results to be returned. If the parameter is not provided, it will return all records found.
OData style filter for filtering scope groups. Supports in operator on name or grn attributes.
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X GET \
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'OK
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
A short description of the scope group.
The HPE GreenLake Resource Notation (GRN) is the standardized, URI-compatible syntax used to define and specify this scope within the HPE GreenLake.
{ "items": [ { … } ], "count": 1, "total": 1, "offset": 0 }
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X GET \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'OK
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
A short description of the scope group.
The HPE GreenLake Resource Notation (GRN) is the standardized, URI-compatible syntax used to define and specify this scope within the HPE GreenLake.
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "type": "authorization/scope-group", "name": "sg1", "description": "This group gives access to resource \"host/123\"", "grn": "grn:glp/workspaces/05f0523c-fd03-47fc-981b-9c4333a37b60/regions/default/providers/authorization/scope-groups/05f0523c-fd03-47fc-981b-9c4333a37b78", "generation": 1, "createdAt": "2023-04-06T22:45:59.759943+00:00", "updatedAt": "2023-04-06T22:45:59.759943+00:00" }
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X PUT \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "sg1"
}'OK
Must be unique within the context it is being created (the organization or the organization and the workspace). Most ASCII chars are allowed, except [&, <, >, |, :, ,] and leading or trailing space. Immutable.
A short description of the scope group.
The HPE GreenLake Resource Notation (GRN) is the standardized, URI-compatible syntax used to define and specify this scope within the HPE GreenLake.
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "type": "authorization/scope-group", "name": "sg1", "description": "This group gives access to resource \"host/123\"", "grn": "grn:glp/workspaces/05f0523c-fd03-47fc-981b-9c4333a37b60/regions/default/providers/authorization/scope-groups/05f0523c-fd03-47fc-981b-9c4333a37b78", "generation": 1, "createdAt": "2023-04-06T22:45:59.759943+00:00", "updatedAt": "2023-04-06T22:45:59.759943+00:00" }
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X DELETE \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}/scopes
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X GET \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'{ "items": [ { … } ], "count": 1, "total": 1, "offset": 0 }
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes/batch
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}/scopes/batch
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X POST \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes/batch' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"items": [
{
"grn": "grn:glp/workspaces/05f0523c-fd03-47fc-981b-9c4333a37b60/regions/us-east/providers/bmaas/host/123",
"description": "host 123"
}
]
}'OK
A unique machine-friendly identifier for the error from a global list of enumerated identifier strings.
A user-friendly error message
{ "successCount": 1, "errorCount": 1, "successes": [ { … } ], "errors": [ { … } ] }
https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes/bulk
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/authorization/public/openapi/authz-v1beta1/external-authz-v2-config/authorization/v1beta1/scope-groups/{id}/scopes/bulk
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X DELETE \
'https://global.api.greenlake.hpe.com/authorization/v1beta1/scope-groups/{id}/scopes/bulk' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"items": [
{
"id": "e7b8f8e1-9ad5-432d-a858-499d9f279647"
}
]
}'OK
A unique machine-friendly identifier for the error from a global list of enumerated identifier strings.
A user-friendly error message
{ "successCount": 1, "errorCount": 1, "successes": [ { … } ], "errors": [ { … } ] }