Class: Hivehook::Resources::OutboundDeliveryService
- Inherits:
-
BaseService
- Object
- BaseService
- Hivehook::Resources::OutboundDeliveryService
- Defined in:
- lib/hivehook/resources/outbound_delivery_service.rb
Constant Summary collapse
- FRAGMENT =
"id messageId endpointId status attempts maxAttempts nextAttemptAt createdAt"
Instance Method Summary collapse
Methods inherited from BaseService
Constructor Details
This class inherits a constructor from Hivehook::Resources::BaseService
Instance Method Details
#get(id) ⇒ Object
18 19 20 21 |
# File 'lib/hivehook/resources/outbound_delivery_service.rb', line 18 def get(id) query = "query($id: UUID!) { outboundDelivery(id: $id) { #{FRAGMENT} } }" @transport.execute(query, { "id" => id })["outboundDelivery"] end |
#list(options = {}) ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/hivehook/resources/outbound_delivery_service.rb', line 8 def list( = {}) query = "query($messageId: UUID, $endpointId: UUID, $status: DeliveryStatus, $search: String, $limit: Int, $offset: Int, $after: String, $first: Int) { outboundDeliveries(messageId: $messageId, endpointId: $endpointId, status: $status, search: $search, limit: $limit, offset: $offset, after: $after, first: $first) { nodes { #{FRAGMENT} } pageInfo { total limit offset endCursor hasNextPage } } }" @transport.execute(query, build_variables(, %w[messageId endpointId status search limit offset after first]))["outboundDeliveries"] end |