fastly-api 1.3.0

Fastly API client
Documentation
# IamRolesApi

All URIs are relative to *https://api.fastly.com*

Method | HTTP request | Description
------------- | ------------- | -------------
[**delete_a_role**]IamRolesApi.md#delete_a_role | **DELETE** /roles/{role_id} | Delete a role
[**get_a_role**]IamRolesApi.md#get_a_role | **GET** /roles/{role_id} | Get a role
[**list_role_permissions**]IamRolesApi.md#list_role_permissions | **GET** /roles/{role_id}/permissions | List permissions in a role
[**list_roles**]IamRolesApi.md#list_roles | **GET** /roles | List roles



## delete_a_role

Delete a role.

```rust
let cfg = &Configuration::default();
let params = DeleteARoleParams {
    // parameters
};
delete_a_role(cfg, params)
```

### Parameters


Name | Type | Description  | Required | Notes
------------- | ------------- | ------------- | ------------- | -------------
**role_id** | **String** | Alphanumeric string identifying the role. | [required] |

### Return type

 (empty response body)

### Authorization

[token](../README.md#token)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: Not defined

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


## get_a_role

Get a role.

```rust
let cfg = &Configuration::default();
let params = GetARoleParams {
    // parameters
};
get_a_role(cfg, params)
```

### Parameters


Name | Type | Description  | Required | Notes
------------- | ------------- | ------------- | ------------- | -------------
**role_id** | **String** | Alphanumeric string identifying the role. | [required] |

### Return type

[**serde_json::Value**](SerdeJsonValue.md)

### Authorization

[token](../README.md#token)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


## list_role_permissions

List all permissions in a role.

```rust
let cfg = &Configuration::default();
let params = ListRolePermissionsParams {
    // parameters
};
list_role_permissions(cfg, params)
```

### Parameters


Name | Type | Description  | Required | Notes
------------- | ------------- | ------------- | ------------- | -------------
**role_id** | **String** | Alphanumeric string identifying the role. | [required] |

### Return type

[**serde_json::Value**](SerdeJsonValue.md)

### Authorization

[token](../README.md#token)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


## list_roles

List all roles.

```rust
let cfg = &Configuration::default();
let params = ListRolesParams {
    // parameters
};
list_roles(cfg, params)
```

### Parameters


Name | Type | Description  | Required | Notes
------------- | ------------- | ------------- | ------------- | -------------
**per_page** | Option\<**i32**> | Number of records per page. |  |[default to 20]
**page** | Option\<**i32**> | Current page. |  |

### Return type

[**serde_json::Value**](SerdeJsonValue.md)

### Authorization

[token](../README.md#token)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)