You should be able to use ngx.var.arg_name , where name is the name of the query parameter that you want to access. For more information about processing query parameters, see Variables with Infinite Names . you can also check out my blog post for Lua nginx / openresty examples.
Alternatively, you can use ngx.req.get_uri_args() to retrieve all query parameters in a single table. See this section in the same tutorial for a brief comparison of these methods.
source share