Class: Axn::Webhooks::Inbound::RespondContext

Inherits:
Object
  • Object
show all
Defined in:
lib/axn/webhooks/inbound/respond_context.rb

Overview

instance_exec context for a respond block: exposes ack/text/xml/json as bare calls, so a respond proc reads text("...") rather than Axn::Webhooks::Response.text("...") — mirrors how the verify custom block gets header/params/etc. as bare calls from DSL.

Instance Method Summary collapse

Instance Method Details

#ackObject



10
# File 'lib/axn/webhooks/inbound/respond_context.rb', line 10

def ack(**) = Response.ack(**)

#json(body) ⇒ Object



13
# File 'lib/axn/webhooks/inbound/respond_context.rb', line 13

def json(body, **) = Response.json(body, **)

#text(body) ⇒ Object



11
# File 'lib/axn/webhooks/inbound/respond_context.rb', line 11

def text(body, **) = Response.text(body, **)

#xml(body) ⇒ Object



12
# File 'lib/axn/webhooks/inbound/respond_context.rb', line 12

def xml(body, **) = Response.xml(body, **)