Mercurial > prosody-modules
view mod_http_debug/mod_http_debug.lua @ 5651:b40750891bee
mod_pubsub_subscription: support subscribing from a bare JID
Allow subscribing from a bare JID on the component instead of only the component
host, useful for subscribing to whitelist access model nodes that want to see
a particular JID in the from.
author | Stephen Paul Weber <singpolyma@singpolyma.net> |
---|---|
date | Sat, 06 May 2023 19:42:08 -0500 |
parents | 10fcfa7e62a1 |
children | 91564b57e595 |
line wrap: on
line source
local json = require "util.json" module:depends("http") module:provides("http", { route = { GET = function(event) local request = event.request; return { status_code = 200; headers = { content_type = "application/json", }, body = json.encode { body = request.body; headers = request.headers; httpversion = request.httpversion; ip = request.ip; method = request.method; path = request.path; secure = request.secure; url = request.url; } } end; } })