| title | List policies (for an AWS authorization system) |
|---|---|
| description | List all awsPolicy objects and their properties for a specific AWS authorization system. |
| author | mrudulahg01 |
| ms.reviewer | ciem_pm |
| ms.localizationpriority | medium |
| ms.subservice | entra-permissions-management |
| doc_type | apiPageType |
| ms.date | 04/18/2024 |
Namespace: microsoft.graph
[!INCLUDE beta-disclaimer]
[!INCLUDE permissions-management-retirement-note]
List all awsPolicy objects and their properties for a specific AWS authorization system. An AWS policy is an object in AWS that defines the permissions of the associated entity or resource. When a principal, such as a user, makes a request, the policies and their associated permissions determine whether the request is allowed or denied.
Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.
[!INCLUDE permissions-table]
GET /external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policiesThis method supports the $select, $filter, $count, $top, and $skipToken OData query parameters to help customize the response. For general information, see OData query parameters.
| Name | Description |
|---|---|
| Authorization | Bearer {token}. Required. Learn more about authentication and authorization. |
Don't supply a request body for this method.
If successful, this method returns a 200 OK response code and a collection of awsPolicy objects in the response body.
The following request lists all the policies for an AWS authorization system.
GET https://graph.microsoft.com/beta/external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies",
"value": [
{
"id": "YXJuOmF3czppYW06OmF3czpwb2xpY3kvQWRtaW5pc3RyYXRvckFjY2Vzcw==",
"externalId": "arn:aws:iam::aws:policy/AdministratorAccess",
"displayName": "AdministratorAccess",
"awsPolicyType": "system"
},
{
"id": "YXJuOmF3czppYW06OjEyMzQ1Njc4OTAxMjpwb2xpY3kvQUFBLWxpc3RQdXRHZXRBbGxCdWNrZXRz",
"externalId": "arn:aws:iam::123456789012:policy/AAA-listPutGetAllBuckets",
"displayName": "AAA-listPutGetAllBuckets",
"awsPolicyType": "custom"
}
]
}The following request lists all policies named AdministratorAccess in an AWS authorization system.
GET https://graph.microsoft.com/beta/external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies?$filter=displayName eq 'AdministratorAccess'[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies",
"value": [
{
"id": "YXJuOmF3czppYW06OmF3czpwb2xpY3kvQWRtaW5pc3RyYXRvckFjY2Vzcw==",
"externalId": "arn:aws:iam::aws:policy/AdministratorAccess",
"displayName": "AdministratorAccess",
"awsPolicyType": "system"
}
]
}The following request lists all policies in an AWS authorization system where the policy name contains the word Buckets.
GET https://graph.microsoft.com/beta/external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies?$filter=contains(displayName, 'Buckets')[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies",
"value": [
{
"id": "YXJuOmF3czppYW06OjM3NzU5NjEzMTc3NDpwb2xpY3kvQUFBLWxpc3RQdXRHZXRBbGxCdWNrZXRz",
"externalId": "arn:aws:iam::377596131774:policy/AAA-listPutGetAllBuckets",
"displayName": "AAA-listPutGetAllBuckets",
"awsPolicyType": "custom"
}
]
}The following example requests all custom policies in an AWS authorization system.
GET https://graph.microsoft.com/beta/external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies?$filter=type eq 'custom'The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#external/authorizationSystems/{id}/microsoft.graph.awsAuthorizationSystem/policies",
"value": [
{
"id": "YXJuOmF3czppYW06OjM3NzU5NjEzMTc3NDpwb2xpY3kvQUFBLWxpc3RQdXRHZXRBbGxCdWNrZXRz",
"externalId": "arn:aws:iam::377596131774:policy/AAA-listPutGetAllBuckets",
"displayName": "AAA-listPutGetAllBuckets",
"awsPolicyType": "custom"
},
{
"id": "YXJuOmF3czppb2xpY3kvQzU5NjEzMTc3NDpwb2xpY3kvQUFBLWxp",
"externalId": "arn:aws:iam::377596131774:policy/BBB-GetAllBuckets",
"displayName": "BBB-GetAllBuckets",
"awsPolicyType": "custom"
}
]
}