Sha256: 910b4ceb153bea45f3cc3b2a838aef7ff13b313f166ac7db1659a9b66d89c1ea
Contents?: true
Size: 536 Bytes
Versions: 7
Compression:
Stored size: 536 Bytes
Contents
# frozen_string_literal: true module RDStation class Events include HTTParty include ::RDStation::RetryableRequest def initialize(authorization:) @authorization = authorization end def create(payload) retryable_request(@authorization) do |authorization| response = self.class.post(base_url, headers: authorization.headers, body: payload.to_json) ApiResponse.build(response) end end private def base_url "#{RDStation.host}/platform/events" end end end
Version data entries
7 entries across 7 versions & 1 rubygems