-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
URL Path Parameters #834
Comments
Hi @sboulema, Glad you're making use of PW.
Read more on Hope issue is solved. |
Thanks for the quick response! Those parameters are added as query parameters though. I am looking for adding a parameter as part of the url path. /petstore/pet/:petId With a parameter petId defined as 42 for example. Would lead to: /petstore/pet/42 as url. The current parameters would give me: /petstore/pet?petId=42 as url. |
Yep, that's why we've Read more on We use |
Ah, missed that! Thank you very much 😃 |
Disclaimer: I'm too busy living my life I fairly have no enough time to improve the Environment flow. 😄 There'll be bugs. Let me know if you stumbled upon any bugs. |
Have a problem I am running into... I set my petId as an env variable using the prerequest script. But now I can't select an env from the list to set other variables cause it would overwrite my request specific env variable. Production environment: Request env variable: So either I end up with an environment with all path variables for all endpoints, or an environment foreach endpoint... Would be nice if the environment appends to the prerequest script instead of overwrite if there are request specific variables. Or the request variables should be saved/configured elsewhere? Thanks for all the hard work and real life is way more important! |
Do you believe overwriting current env should be the default action? It's easily possible to append vars to current env - but I suspect everybody should not be expecting that behaviour. |
That was a fun saturday! I wrote a possible solution to the problem: sboulema@25f014e It adds a type dropdown to the current parameter list. Based on the type, the parameter either gets included as a query parameter or gets added as an environment variable so it can be used in the current url path template replacement. This way the parameter gets saved with the request and does not have to be saved with the environment. Any thoughts or comments ? If you want I can submit a PR 👍 |
@sboulema implementation looks good to me. shoot the PR 🚀 |
Is your feature request related to a problem? Please describe.
I am trying to convert from Postman to Postwoman. I love that I have a proper API testing tool that I can use on my laptop and on my phone and keep everything in sync!
I do however miss the easy way of setting url path parameters as is possible in Postman.
Describe the solution you'd like
More info on how path parameters work in Postman:
https://learning.postman.com/docs/postman/sending-api-requests/requests/#sending-parameters
Describe alternatives you've considered
Either a similar solution with a special character or maybe a dropdown next to the current query parameters to indicate if it is a query or path parameter.
The text was updated successfully, but these errors were encountered: