Class: TRMNL::API::Endpoints::IPAddress
- Inherits:
-
Object
- Object
- TRMNL::API::Endpoints::IPAddress
- Includes:
- Pipeable
- Defined in:
- lib/trmnl/api/endpoints/ip_address.rb
Overview
Handles API request/response.
Instance Method Summary collapse
Instance Method Details
#call ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/trmnl/api/endpoints/ip_address.rb', line 20 def call pipe requester.get("ips"), try(:parse, catch: JSON::ParserError), validate(schema, as: :to_h), as(:fetch, :data), to(model, :for) end |