Class: OpenAI::Resources::Webhooks::EventTypes

Inherits:
Object
  • Object
show all
Defined in:
lib/openai/resources/webhooks/event_types.rb,
sig/openai/resources/webhooks/event_types.rbs

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ EventTypes

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 EventTypes.

Parameters:



29
30
31
# File 'lib/openai/resources/webhooks/event_types.rb', line 29

def initialize(client:)
  @client = client
end

Instance Method Details

#list(request_options: {}) ⇒ OpenAI::Models::Webhooks::WebhookEventTypeList

Returns webhook event types visible to the authenticated project.

Parameters:

Returns:

See Also:



16
17
18
19
20
21
22
23
24
# File 'lib/openai/resources/webhooks/event_types.rb', line 16

def list(params = {})
  @client.request(
    method: :get,
    path: "webhook_event_types",
    model: OpenAI::Webhooks::WebhookEventTypeList,
    security: {bearer_auth: true},
    options: params[:request_options]
  )
end