# PulpcoreClient::WorkersApi All URIs are relative to *http://pulp* Method | HTTP request | Description ------------- | ------------- | ------------- [**list**](WorkersApi.md#list) | **GET** /pulp/api/v3/workers/ | List workers [**read**](WorkersApi.md#read) | **GET** {worker_href} | Inspect a worker ## list > InlineResponse20014 list(opts) List workers A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset. ### 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::WorkersApi.new opts = { last_heartbeat: 'last_heartbeat_example', # String | last_heartbeat last_heartbeat__gt: 'last_heartbeat__gt_example', # String | last_heartbeat__gt last_heartbeat__gte: 'last_heartbeat__gte_example', # String | last_heartbeat__gte last_heartbeat__lt: 'last_heartbeat__lt_example', # String | last_heartbeat__lt last_heartbeat__lte: 'last_heartbeat__lte_example', # String | last_heartbeat__lte last_heartbeat__range: 'last_heartbeat__range_example', # String | last_heartbeat__range limit: 56, # Integer | Number of results to return per page. missing: 'missing_example', # String | missing name: 'name_example', # String | name name__in: 'name__in_example', # String | name__in offset: 56, # Integer | The initial index from which to return the results. online: 'online_example', # String | online ordering: 'ordering_example', # String | Which field to use when ordering the results. fields: 'fields_example', # String | A list of fields to include in the response. exclude_fields: 'exclude_fields_example' # String | A list of fields to exclude from the response. } begin #List workers result = api_instance.list(opts) p result rescue PulpcoreClient::ApiError => e puts "Exception when calling WorkersApi->list: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **last_heartbeat** | **String**| last_heartbeat | [optional] **last_heartbeat__gt** | **String**| last_heartbeat__gt | [optional] **last_heartbeat__gte** | **String**| last_heartbeat__gte | [optional] **last_heartbeat__lt** | **String**| last_heartbeat__lt | [optional] **last_heartbeat__lte** | **String**| last_heartbeat__lte | [optional] **last_heartbeat__range** | **String**| last_heartbeat__range | [optional] **limit** | **Integer**| Number of results to return per page. | [optional] **missing** | **String**| missing | [optional] **name** | **String**| name | [optional] **name__in** | **String**| name__in | [optional] **offset** | **Integer**| The initial index from which to return the results. | [optional] **online** | **String**| online | [optional] **ordering** | **String**| Which field to use when ordering the results. | [optional] **fields** | **String**| A list of fields to include in the response. | [optional] **exclude_fields** | **String**| A list of fields to exclude from the response. | [optional] ### Return type [**InlineResponse20014**](InlineResponse20014.md) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json ## read > WorkerResponse read(worker_href, opts) Inspect a worker A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset. ### 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::WorkersApi.new worker_href = 'worker_href_example' # String | opts = { fields: 'fields_example', # String | A list of fields to include in the response. exclude_fields: 'exclude_fields_example' # String | A list of fields to exclude from the response. } begin #Inspect a worker result = api_instance.read(worker_href, opts) p result rescue PulpcoreClient::ApiError => e puts "Exception when calling WorkersApi->read: #{e}" end ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **worker_href** | **String**| | **fields** | **String**| A list of fields to include in the response. | [optional] **exclude_fields** | **String**| A list of fields to exclude from the response. | [optional] ### Return type [**WorkerResponse**](WorkerResponse.md) ### Authorization [basicAuth](../README.md#basicAuth) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json