Software /
code /
prosody-modules
File
mod_http_debug/mod_http_debug.lua @ 5380:822d26271d9f
mod_rest/rest.sh: Set software_id in client registration to something
Mostly just for exercising the extra fields.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 27 Apr 2023 20:56:24 +0200 |
parent | 5333:10fcfa7e62a1 |
child | 5490: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; } })