Sha256: c73e3235fb4fd9c2b2b063a6a28048e04f4c3afdf97ba8509bd773a2d1e741c9

Contents?: true

Size: 1.93 KB

Versions: 1

Compression:

Stored size: 1.93 KB

Contents

=begin
#Mailchimp Marketing API

#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)

OpenAPI spec version: 3.0.5
Contact: apihelp@mailchimp.com
Generated by: https://github.com/swagger-api/swagger-codegen.git
Swagger Codegen version: 2.4.12

=end

require 'uri'

module MailchimpMarketing
  class PingApi
    attr_accessor :api_client

    def initialize(api_client)
      @api_client = api_client
    end
    # Ping
    # A health check for the API that won't return any account-specific information.
    # @param [Hash] opts the optional parameters
    # @return [APIHealthStatus]
    def get(opts = {})
      data, _status_code, _headers = get_with_http_info(opts)
      data
    end

    # Ping
    # A health check for the API that won't return any account-specific information.
    # @param [Hash] opts the optional parameters
    # @return [Array<(APIHealthStatus, Fixnum, Hash)>] APIHealthStatus data, response status code and response headers
    def get_with_http_info(opts = {})
      # resource path
      local_var_path = '/ping'

      # query parameters
      query_params = {}

      # header parameters
      header_params = {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
      # HTTP header 'Content-Type'
      header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

      # form parameters
      form_params = {}

      # http body (model)
      post_body = nil
      auth_names = ['basicAuth']
      data, status_code, headers = @api_client.call_api(:GET, local_var_path,
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => 'APIHealthStatus')
      return data, status_code, headers
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
MailchimpMarketing-3.0.5 lib/MailchimpMarketing/api/ping_api.rb