# List the IAM policies associated with the user - ListPoliciesForUser

## Overview

List the IAM policies associated with the user






## Definition

### Public Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Action**     | string  | Corresponding API command name, the current API is `ListPoliciesForUser`.                      | **Yes** |
| **PublicKey**  | string  | The user's public key can be obtained from [Console](https://console.dezai.com/uaccount/api_manage)                                             | **Yes** |
| **Signature**  | string  | User signature generated based on public key and API command, see [Signature Algorithm](/docs/api/summary/signature.md)  | **Yes** |

### Request Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **UserName** | string | Username |**Yes**|
| **Scope** | string | Application Scope |No|
| **ProjectID** | string | Project ID |No|
| **Limit** | string | The number of user groups to be queried |No|
| **Offset** | string | Start querying from which data entry |No|

### Response Field

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **RetCode** | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. |**Yes**|
| **Action** | string | Operation command name. |**Yes**|
| **Message** | string | Returns an error message, providing detailed description when `RetCode` is non-zero. |No|
| **TotalCount** | int | Permission Policy Questions |**Yes**|
| **Policies** | array[[*AttachedPolicy*](#attachedpolicy)] | Permission Policy List |**Yes**|

#### Data Model


#### AttachedPolicy

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **PolicyName** | string | Permission Policy Name |**Yes**|
| **PolicyURN** | string | Strategy URN |**Yes**|
| **Scope** | string | Application Scope (ScopeRequired: Project Level, ScopeEmpty: Global Level, ScopeUnrestricted: Project Level/Global Level) |**Yes**|
| **AttachedAt** | int | Unix timestamp when the policy is bound |**Yes**|
| **Description** | string | Description |No|
| **ProjectName** | string | Project Name |No|
| **ProjectID** | string | Project ID |No|

## Example

### Request Example
    
```
https://api.dezai.com/?Action=ListPoliciesForUser
&UserName=WigejYot
&Scope=wpFVoffI
&ProjectID=hKymMuzZ
&Limit=IdUIFcbA
&Offset=XDGiLmJn
```

### Response Example
    
```json
{
  "Action": "ListPoliciesForUserResponse",
  "Message": "mXttgmqS",
  "Policies": [
    {
      "AttachedAt": 4,
      "CreatedAt": 2,
      "Description": "PDmbkeZM",
      "PolicyName": "PAsWyXOe",
      "PolicyURN": "SXyEkrfh",
      "ProjectID": "nEQZMTkG",
      "Scope": "yes"
    }
  ],
  "RetCode": 0,
  "TotalCount": 4
}
```





