Module: Strava::Web::Request Private

Included in:
Client
Defined in:
lib/strava/web/request.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

HTTP request methods for Strava web clients.

This module provides GET, POST, PUT, and DELETE HTTP methods for making requests to Strava APIs. All methods return a wrapped response object that provides easy access to response data and metadata.

Instance Method Summary collapse

Instance Method Details

#delete(path, options = {}) ⇒ Strava::Web::Response

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Perform an HTTP DELETE request.

Parameters:

  • path (String)

    The API path (relative to endpoint)

  • options (Hash) (defaults to: {})

    Query parameters and options

Returns:



59
60
61
# File 'lib/strava/web/request.rb', line 59

def delete(path, options = {})
  request(:delete, path, options)
end

#get(path, options = {}) ⇒ Strava::Web::Response

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Perform an HTTP GET request.

Parameters:

  • path (String)

    The API path (relative to endpoint)

  • options (Hash) (defaults to: {})

    Query parameters and options

Returns:



23
24
25
# File 'lib/strava/web/request.rb', line 23

def get(path, options = {})
  request(:get, path, options)
end

#post(path, options = {}) ⇒ Strava::Web::Response

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Perform an HTTP POST request.

Parameters:

  • path (String)

    The API path (relative to endpoint)

  • options (Hash) (defaults to: {})

    Request body parameters and options

Returns:



35
36
37
# File 'lib/strava/web/request.rb', line 35

def post(path, options = {})
  request(:post, path, options)
end

#put(path, options = {}) ⇒ Strava::Web::Response

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Perform an HTTP PUT request.

Parameters:

  • path (String)

    The API path (relative to endpoint)

  • options (Hash) (defaults to: {})

    Request body parameters and options

Returns:



47
48
49
# File 'lib/strava/web/request.rb', line 47

def put(path, options = {})
  request(:put, path, options)
end