Exception: RubyCoded::Chat::CodexAPIError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/ruby_coded/chat/codex_bridge.rb

Overview

Raised when the Codex HTTP API returns a non-2xx response.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(status, detail) ⇒ CodexAPIError

Returns a new instance of CodexAPIError.



25
26
27
28
# File 'lib/ruby_coded/chat/codex_bridge.rb', line 25

def initialize(status, detail)
  @status = status
  super("HTTP #{status}: #{detail}")
end

Instance Attribute Details

#statusObject (readonly)

Returns the value of attribute status.



23
24
25
# File 'lib/ruby_coded/chat/codex_bridge.rb', line 23

def status
  @status
end