class SquashMatrixAPI::DefaultApi
Attributes
Public Class Methods
# File lib/squash_matrix_api/api/default_api.rb, line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end
Public Instance Methods
Get page of clubs
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of clubs @option opts [Integer] :page_size The size of page @return [InlineResponse200]
# File lib/squash_matrix_api/api/default_api.rb, line 29 def clubs_get(opts = {}) data, _status_code, _headers = clubs_get_with_http_info(opts) return data end
Get page of clubs
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of clubs @option opts [Integer] :page_size The size of page @return [Array<(InlineResponse200
, Fixnum, Hash)>] InlineResponse200
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 40 def clubs_get_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.clubs_get ..." end # resource path local_var_path = "/clubs" # query parameters query_params = {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse200') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#clubs_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get club by Squash Matrix ID
@param squash_matrix_id Squash Matrix ID of club @param [Hash] opts the optional parameters @return [InlineResponse2001]
# File lib/squash_matrix_api/api/default_api.rb, line 83 def clubs_squash_matrix_id_get(squash_matrix_id, opts = {}) data, _status_code, _headers = clubs_squash_matrix_id_get_with_http_info(squash_matrix_id, opts) return data end
Get club by Squash Matrix ID
@param squash_matrix_id Squash Matrix ID of club @param [Hash] opts the optional parameters @return [Array<(InlineResponse2001
, Fixnum, Hash)>] InlineResponse2001
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 93 def clubs_squash_matrix_id_get_with_http_info(squash_matrix_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.clubs_squash_matrix_id_get ..." end # verify the required parameter 'squash_matrix_id' is set if @api_client.config.client_side_validation && squash_matrix_id.nil? fail ArgumentError, "Missing the required parameter 'squash_matrix_id' when calling DefaultApi.clubs_squash_matrix_id_get" end # resource path local_var_path = "/clubs/{squashMatrixId}".sub('{' + 'squashMatrixId' + '}', squash_matrix_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse2001') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#clubs_squash_matrix_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get game by ID
@param game_id Numeric ID of game @param [Hash] opts the optional parameters @return [InlineResponse2005]
# File lib/squash_matrix_api/api/default_api.rb, line 138 def games_game_id_get(game_id, opts = {}) data, _status_code, _headers = games_game_id_get_with_http_info(game_id, opts) return data end
Get game by ID
@param game_id Numeric ID of game @param [Hash] opts the optional parameters @return [Array<(InlineResponse2005
, Fixnum, Hash)>] InlineResponse2005
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 148 def games_game_id_get_with_http_info(game_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.games_game_id_get ..." end # verify the required parameter 'game_id' is set if @api_client.config.client_side_validation && game_id.nil? fail ArgumentError, "Missing the required parameter 'game_id' when calling DefaultApi.games_game_id_get" end # resource path local_var_path = "/games/{gameId}".sub('{' + 'gameId' + '}', game_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse2005') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#games_game_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get page of games
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of games @option opts [Integer] :page_size The size of page @return [InlineResponse2004]
# File lib/squash_matrix_api/api/default_api.rb, line 194 def games_get(opts = {}) data, _status_code, _headers = games_get_with_http_info(opts) return data end
Get page of games
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of games @option opts [Integer] :page_size The size of page @return [Array<(InlineResponse2004
, Fixnum, Hash)>] InlineResponse2004
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 205 def games_get_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.games_get ..." end # resource path local_var_path = "/games" # query parameters query_params = {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse2004') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#games_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get page of players
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of players @option opts [Integer] :page_size The size of page @return [InlineResponse2002]
# File lib/squash_matrix_api/api/default_api.rb, line 249 def players_get(opts = {}) data, _status_code, _headers = players_get_with_http_info(opts) return data end
Get page of players
@param [Hash] opts the optional parameters @option opts [Integer] :page The page of players @option opts [Integer] :page_size The size of page @return [Array<(InlineResponse2002
, Fixnum, Hash)>] InlineResponse2002
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 260 def players_get_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.players_get ..." end # resource path local_var_path = "/players" # query parameters query_params = {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse2002') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#players_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get player by Squash Matrix ID
@param squash_matrix_id Squash Matrix ID of player @param [Hash] opts the optional parameters @return [InlineResponse2003]
# File lib/squash_matrix_api/api/default_api.rb, line 303 def players_squash_matrix_id_get(squash_matrix_id, opts = {}) data, _status_code, _headers = players_squash_matrix_id_get_with_http_info(squash_matrix_id, opts) return data end
Get player by Squash Matrix ID
@param squash_matrix_id Squash Matrix ID of player @param [Hash] opts the optional parameters @return [Array<(InlineResponse2003
, Fixnum, Hash)>] InlineResponse2003
data, response status code and response headers
# File lib/squash_matrix_api/api/default_api.rb, line 313 def players_squash_matrix_id_get_with_http_info(squash_matrix_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: DefaultApi.players_squash_matrix_id_get ..." end # verify the required parameter 'squash_matrix_id' is set if @api_client.config.client_side_validation && squash_matrix_id.nil? fail ArgumentError, "Missing the required parameter 'squash_matrix_id' when calling DefaultApi.players_squash_matrix_id_get" end # resource path local_var_path = "/players/{squashMatrixId}".sub('{' + 'squashMatrixId' + '}', squash_matrix_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/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 = [] 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 => 'InlineResponse2003') if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#players_squash_matrix_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end