This will allow us to switch asterisk to the new logic before rolling out the
limits. Asterisk will then support the limits once sgx-jmp begins instructing
it about them.
@@ -49,6 +49,7 @@ class Web < Roda
use Rack::Fiber unless ENV["ENV"] == "test" # Must go first!
use Sentry::Rack::CaptureExceptions
plugin :json_parser
+ plugin :type_routing
plugin :public
plugin :render, engine: "slim"
plugin RodaCapture
@@ -279,6 +280,13 @@ class Web < Roda
customer_repo(
sgx_repo: Bwmsgsv2Repo.new
).find_by_format(from).then do |c|
+ r.json do
+ {
+ from: c.registered?.phone,
+ to: params["to"]
+ }.to_json
+ end
+
render :forward, locals: {
from: c.registered?.phone,
to: params["to"]