Class: HubSpotSDK::Resources::WebhooksJournal::Journal
- Inherits:
-
Object
- Object
- HubSpotSDK::Resources::WebhooksJournal::Journal
- Defined in:
- lib/hubspot_sdk/resources/webhooks_journal/journal.rb,
lib/hubspot_sdk/resources/webhooks_journal/journal/batch.rb
Defined Under Namespace
Classes: Batch
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#get_earliest(install_portal_id: nil, request_options: {}) ⇒ StringIO
Some parameter documentations has been truncated, see Models::WebhooksJournal::JournalGetEarliestParams for more details.
-
#get_next_from_offset(offset, install_portal_id: nil, request_options: {}) ⇒ StringIO
Some parameter documentations has been truncated, see Models::WebhooksJournal::JournalGetNextFromOffsetParams for more details.
-
#get_status(status_id, request_options: {}) ⇒ HubSpotSDK::Models::SnapshotStatusResponse
Retrieve the status of a specific webhook journal entry using its unique status ID.
-
#initialize(client:) ⇒ Journal
constructor
private
A new instance of Journal.
Constructor Details
#initialize(client:) ⇒ Journal
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Journal.
98 99 100 101 |
# File 'lib/hubspot_sdk/resources/webhooks_journal/journal.rb', line 98 def initialize(client:) @client = client @batch = HubSpotSDK::Resources::WebhooksJournal::Journal::Batch.new(client: client) end |
Instance Attribute Details
#batch ⇒ HubSpotSDK::Resources::WebhooksJournal::Journal::Batch (readonly)
8 9 10 |
# File 'lib/hubspot_sdk/resources/webhooks_journal/journal.rb', line 8 def batch @batch end |
Instance Method Details
#get_earliest(install_portal_id: nil, request_options: {}) ⇒ StringIO
Some parameter documentations has been truncated, see Models::WebhooksJournal::JournalGetEarliestParams for more details.
Retrieve the earliest entry from the webhooks journal for the specified portal. This endpoint is useful for accessing the first recorded webhook event in the journal, which can be helpful for auditing or debugging purposes.
27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/hubspot_sdk/resources/webhooks_journal/journal.rb', line 27 def get_earliest(params = {}) parsed, = HubSpotSDK::WebhooksJournal::JournalGetEarliestParams.dump_request(params) query = HubSpotSDK::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "webhooks-journal/journal/2026-03/earliest", query: query.transform_keys(install_portal_id: "installPortalId"), headers: {"accept" => "*/*"}, model: StringIO, options: ) end |
#get_next_from_offset(offset, install_portal_id: nil, request_options: {}) ⇒ StringIO
Some parameter documentations has been truncated, see Models::WebhooksJournal::JournalGetNextFromOffsetParams for more details.
Retrieve the next set of entries from the webhooks journal starting from a specified offset. This endpoint is useful for paginating through journal entries to process or analyze webhook events sequentially.
59 60 61 62 63 64 65 66 67 68 69 70 |
# File 'lib/hubspot_sdk/resources/webhooks_journal/journal.rb', line 59 def get_next_from_offset(offset, params = {}) parsed, = HubSpotSDK::WebhooksJournal::JournalGetNextFromOffsetParams.dump_request(params) query = HubSpotSDK::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: ["webhooks-journal/journal/2026-03/offset/%1$s/next", offset], query: query.transform_keys(install_portal_id: "installPortalId"), headers: {"accept" => "*/*"}, model: StringIO, options: ) end |
#get_status(status_id, request_options: {}) ⇒ HubSpotSDK::Models::SnapshotStatusResponse
Retrieve the status of a specific webhook journal entry using its unique status ID. This endpoint provides detailed information about the status, including whether it is pending, in progress, completed, failed, or expired. It is useful for monitoring and managing the state of webhook journal entries.
86 87 88 89 90 91 92 93 |
# File 'lib/hubspot_sdk/resources/webhooks_journal/journal.rb', line 86 def get_status(status_id, params = {}) @client.request( method: :get, path: ["webhooks-journal/journal/2026-03/status/%1$s", status_id], model: HubSpotSDK::SnapshotStatusResponse, options: params[:request_options] ) end |