Request Query
Iury O. G. Figueiredo edited this page Dec 5, 2020
·
2 revisions
All request classes in Websnake accept an argument args that is meant to be a dictionary containing the request parameters or query.
from websnake import Get, ResponseHandle, core, die
args = {
'name': 'Iury',
'age' : '20
}
request = Get('some-url', args=args)
request.add_map(ResponseHandle.DONE, lambda req, resp: die('Bye!'))
core.gear.mainloop()
The parameter args is accepted in the constructors of Post, Head, Get, Put and Delete.