japronto icon indicating copy to clipboard operation
japronto copied to clipboard

how to get url parameters?? like if a url is 127.0.0.1:8000/api/books?query=jason, how to get the query param in japronto?

Open spawn08 opened this issue 6 years ago • 4 comments

spawn08 avatar Apr 16 '18 07:04 spawn08

GitHub issues generally aren't for general "how to" questions, but rather for actual "issues" causing problems with the product.

With that being said, taking a look at the examples and doing some research on your own can yield great results. I'll help you get started. Take a look at this line in particular. The top of this example states how to handle the query params, so you should be able to work from there.

If you have any further questions, you should consider posting the question in a more suitable place like Stack Overflow.

ATLUSio avatar Apr 18 '18 14:04 ATLUSio

def getQueryString(request):

              url_params = request.query_string

vadim-shadrin avatar May 12 '18 10:05 vadim-shadrin

@ATLUSio There is currently no stack overflow question and answers about this library. There doesn't seem to be a critical mass of users there.

See search link here: https://stackoverflow.com/search?q=japronto

geyang avatar Jul 09 '18 22:07 geyang

That's true, but this is still GitHub issues and should be treated seriously for triaging issues. Even if there doesn't seem to be a critical mass of users with Japronto questions, there's still very many people very willing to answer Python-related questions.

Furthermore, the how-to request of this GitHub is covered in this example (which is why I suggested looking through the examples): https://github.com/squeaky-pl/japronto/blob/master/examples/4_request/request.py

ATLUSio avatar Jul 12 '18 19:07 ATLUSio