Method: PulpPythonClient::PublicationsPypiApi#read_with_http_info

Defined in:
lib/pulp_python_client/api/publications_pypi_api.rb

#read_with_http_info(python_python_publication_href, opts = {}) ⇒ Array<(PythonPythonPublicationResponse, Integer, Hash)>

Inspect a python publication

Python Publications refer to the Python Package content in a repository version, and include metadata about that content.

Parameters:

  • python_python_publication_href (String)
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :fields (String)

    A list of fields to include in the response.

  • :exclude_fields (String)

    A list of fields to exclude from the response.

Returns:



263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
# File 'lib/pulp_python_client/api/publications_pypi_api.rb', line 263

def read_with_http_info(python_python_publication_href, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: PublicationsPypiApi.read ...'
  end
  # verify the required parameter 'python_python_publication_href' is set
  if @api_client.config.client_side_validation && python_python_publication_href.nil?
    fail ArgumentError, "Missing the required parameter 'python_python_publication_href' when calling PublicationsPypiApi.read"
  end
  # resource path
  local_var_path = '{python_python_publication_href}'.sub('{' + 'python_python_publication_href' + '}', CGI.escape(python_python_publication_href.to_s).gsub('%2F', '/'))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
  query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'PythonPythonPublicationResponse' 

  # auth_names
  auth_names = opts[:auth_names] || ['basicAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PublicationsPypiApi#read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end