Class: Rubygpt::Requester::BaseRequester
- Inherits:
-
Object
- Object
- Rubygpt::Requester::BaseRequester
- Defined in:
- lib/rubygpt/requester.rb
Overview
Base module for all requester modules
Direct Known Subclasses
Instance Attribute Summary collapse
-
#api_endpoint ⇒ Object
readonly
The API endpoint for the request.
-
#client ⇒ Object
readonly
The client object that will be used to make the request.
Instance Method Summary collapse
-
#create ⇒ Object
Performs a POST request to the API endpoint.
-
#initialize(client) ⇒ BaseRequester
constructor
Initializes new Rubygpt::Requester object.
Constructor Details
#initialize(client) ⇒ BaseRequester
Initializes new Rubygpt::Requester object
16 17 18 |
# File 'lib/rubygpt/requester.rb', line 16 def initialize(client) @client = client end |
Instance Attribute Details
#api_endpoint ⇒ Object (readonly)
The API endpoint for the request
11 12 13 |
# File 'lib/rubygpt/requester.rb', line 11 def api_endpoint @api_endpoint end |
#client ⇒ Object (readonly)
The client object that will be used to make the request
8 9 10 |
# File 'lib/rubygpt/requester.rb', line 8 def client @client end |
Instance Method Details
#create ⇒ Object
Performs a POST request to the API endpoint
21 22 23 |
# File 'lib/rubygpt/requester.rb', line 21 def create raise NotImplementedError end |