# PulpcoreClient::GroupsRolesApi All URIs are relative to *https://pulp* Method | HTTP request | Description ------------- | ------------- | ------------- [**create**](GroupsRolesApi.md#create) | **POST** {group_href}roles/ | Create a group role [**delete**](GroupsRolesApi.md#delete) | **DELETE** {groups_group_role_href} | Delete a group role [**list**](GroupsRolesApi.md#list) | **GET** {group_href}roles/ | List group roles [**read**](GroupsRolesApi.md#read) | **GET** {groups_group_role_href} | Inspect a group role ## create > GroupRoleResponse create(group_href, group_role) Create a group role ViewSet for GroupRole. NOTE: This API endpoint is in \"tech preview\" and subject to change ### Example ```ruby # load the gem require 'pulpcore_client' # setup authorization PulpcoreClient.configure do |config| # Configure HTTP basic authorization: basicAuth config.username = 'YOUR USERNAME' config.password = 'YOUR PASSWORD' end api_instance = PulpcoreClient::GroupsRolesApi.new group_href = 'group_href_example' # String | group_role = PulpcoreClient::GroupRole.new # GroupRole | begin #Create a group role result = api_instance.create(group_href, group_role) p result rescue PulpcoreClient::ApiError => e puts "Exception when calling GroupsRolesApi->create: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **group_href** | **String**| | **group_role** | [**GroupRole**](GroupRole.md)| | ### Return type [**GroupRoleResponse**](GroupRoleResponse.md) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: application/json, application/x-www-form-urlencoded, multipart/form-data - **Accept**: application/json ## delete > delete(groups_group_role_href) Delete a group role ViewSet for GroupRole. NOTE: This API endpoint is in \"tech preview\" and subject to change ### Example ```ruby # load the gem require 'pulpcore_client' # setup authorization PulpcoreClient.configure do |config| # Configure HTTP basic authorization: basicAuth config.username = 'YOUR USERNAME' config.password = 'YOUR PASSWORD' end api_instance = PulpcoreClient::GroupsRolesApi.new groups_group_role_href = 'groups_group_role_href_example' # String | begin #Delete a group role api_instance.delete(groups_group_role_href) rescue PulpcoreClient::ApiError => e puts "Exception when calling GroupsRolesApi->delete: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **groups_group_role_href** | **String**| | ### Return type nil (empty response body) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: Not defined ## list > PaginatedGroupRoleResponseList list(group_href, opts) List group roles ViewSet for GroupRole. NOTE: This API endpoint is in \"tech preview\" and subject to change ### Example ```ruby # load the gem require 'pulpcore_client' # setup authorization PulpcoreClient.configure do |config| # Configure HTTP basic authorization: basicAuth config.username = 'YOUR USERNAME' config.password = 'YOUR PASSWORD' end api_instance = PulpcoreClient::GroupsRolesApi.new group_href = 'group_href_example' # String | opts = { content_object: 'content_object_example', # String | content_object limit: 56, # Integer | Number of results to return per page. offset: 56, # Integer | The initial index from which to return the results. ordering: ['ordering_example'], # Array | Ordering role: 'role_example', # String | role__contains: 'role__contains_example', # String | role__icontains: 'role__icontains_example', # String | role__in: ['role__in_example'], # Array | Multiple values may be separated by commas. role__startswith: 'role__startswith_example', # String | fields: ['fields_example'], # Array | A list of fields to include in the response. exclude_fields: ['exclude_fields_example'] # Array | A list of fields to exclude from the response. } begin #List group roles result = api_instance.list(group_href, opts) p result rescue PulpcoreClient::ApiError => e puts "Exception when calling GroupsRolesApi->list: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **group_href** | **String**| | **content_object** | **String**| content_object | [optional] **limit** | **Integer**| Number of results to return per page. | [optional] **offset** | **Integer**| The initial index from which to return the results. | [optional] **ordering** | [**Array<String>**](String.md)| Ordering | [optional] **role** | **String**| | [optional] **role__contains** | **String**| | [optional] **role__icontains** | **String**| | [optional] **role__in** | [**Array<String>**](String.md)| Multiple values may be separated by commas. | [optional] **role__startswith** | **String**| | [optional] **fields** | [**Array<String>**](String.md)| A list of fields to include in the response. | [optional] **exclude_fields** | [**Array<String>**](String.md)| A list of fields to exclude from the response. | [optional] ### Return type [**PaginatedGroupRoleResponseList**](PaginatedGroupRoleResponseList.md) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json ## read > GroupRoleResponse read(groups_group_role_href, opts) Inspect a group role ViewSet for GroupRole. NOTE: This API endpoint is in \"tech preview\" and subject to change ### Example ```ruby # load the gem require 'pulpcore_client' # setup authorization PulpcoreClient.configure do |config| # Configure HTTP basic authorization: basicAuth config.username = 'YOUR USERNAME' config.password = 'YOUR PASSWORD' end api_instance = PulpcoreClient::GroupsRolesApi.new groups_group_role_href = 'groups_group_role_href_example' # String | opts = { fields: ['fields_example'], # Array | A list of fields to include in the response. exclude_fields: ['exclude_fields_example'] # Array | A list of fields to exclude from the response. } begin #Inspect a group role result = api_instance.read(groups_group_role_href, opts) p result rescue PulpcoreClient::ApiError => e puts "Exception when calling GroupsRolesApi->read: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **groups_group_role_href** | **String**| | **fields** | [**Array<String>**](String.md)| A list of fields to include in the response. | [optional] **exclude_fields** | [**Array<String>**](String.md)| A list of fields to exclude from the response. | [optional] ### Return type [**GroupRoleResponse**](GroupRoleResponse.md) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json