Class: Sink::Resources::PaginationTests::FakePages
- Inherits:
-
Object
- Object
- Sink::Resources::PaginationTests::FakePages
- Defined in:
- lib/sink/resources/pagination_tests/fake_pages.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ FakePages
constructor
A new instance of FakePages.
-
#list(params = {}, opts = {}) ⇒ Sink::FakePage<Sink::Models::SimpleObject>
Endpoint that returns a top-level array that is transformed into a fake_page.
Constructor Details
#initialize(client:) ⇒ FakePages
Returns a new instance of FakePages.
8 9 10 |
# File 'lib/sink/resources/pagination_tests/fake_pages.rb', line 8 def initialize(client:) @client = client end |
Instance Method Details
#list(params = {}, opts = {}) ⇒ Sink::FakePage<Sink::Models::SimpleObject>
Endpoint that returns a top-level array that is transformed into a fake_page.
20 21 22 23 24 25 26 27 28 29 |
# File 'lib/sink/resources/pagination_tests/fake_pages.rb', line 20 def list(params = {}, opts = {}) req = { method: :get, path: "/paginated/fake_page", query: params, page: Sink::FakePage, model: Sink::Models::SimpleObject } @client.request(req, opts) end |