Class: Knockapi::Models::Message::Channel

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/knockapi/models/message.rb

Overview

See Also:

Defined Under Namespace

Modules: Type

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id:, created_at:, provider:, type:, updated_at:, key: nil, name: nil) ⇒ Object

A configured channel, which is a way to route messages to a provider.

Parameters:

  • id (String)

    The unique identifier for the channel.

  • created_at (Time)

    The timestamp of when the channel was created.

  • provider (String)

    The ID of the provider that this channel uses to deliver messages.

  • type (Symbol, Knockapi::Models::Message::Channel::Type)

    The type of channel, determining what kind of messages it can send.

  • updated_at (Time)

    The timestamp of when the channel was last updated.

  • key (String, nil) (defaults to: nil)

    Unique identifier for the channel within a project (immutable once created).

  • name (String, nil) (defaults to: nil)

    The human-readable name of the channel.



# File 'lib/knockapi/models/message.rb', line 368

Instance Attribute Details

#created_atTime

The timestamp of when the channel was created.

Returns:

  • (Time)


336
# File 'lib/knockapi/models/message.rb', line 336

required :created_at, Time

#idString

The unique identifier for the channel.

Returns:

  • (String)


330
# File 'lib/knockapi/models/message.rb', line 330

required :id, String

#keyString?

Unique identifier for the channel within a project (immutable once created).

Returns:

  • (String, nil)


360
# File 'lib/knockapi/models/message.rb', line 360

optional :key, String, nil?: true

#nameString?

The human-readable name of the channel.

Returns:

  • (String, nil)


366
# File 'lib/knockapi/models/message.rb', line 366

optional :name, String, nil?: true

#providerString

The ID of the provider that this channel uses to deliver messages.

Returns:

  • (String)


342
# File 'lib/knockapi/models/message.rb', line 342

required :provider, String

#typeSymbol, Knockapi::Models::Message::Channel::Type

The type of channel, determining what kind of messages it can send.



348
# File 'lib/knockapi/models/message.rb', line 348

required :type, enum: -> { Knockapi::Message::Channel::Type }

#updated_atTime

The timestamp of when the channel was last updated.

Returns:

  • (Time)


354
# File 'lib/knockapi/models/message.rb', line 354

required :updated_at, Time