I can’t work out how you pass arguments to an http post request with trivial-http library. I can make a post but I’m not sure how to pass post variables. as a character stream.
http://common-lisp.net/project/trivial-http/user-guide.html#http-post
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You need to pass the post variables in as the content of the post request. The most common way is as
application/x-www-form-urlencoded, thoughmultipart/form-datacan be used if you need to do file uploads; see here for details on the encodings.To pass information in a POST request using
application/x-www-form-urlencoded, you need to pass that in as the content type, and a url-encoded query string as the content. Something like this should work:If you need to escape strings that will be passed in as keys or values for the POST requests, then you can use
escape-url-queryto escape them to be safe to pass in in a url-encoded body: