Skip to content
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

Pre request scripts for all requests in collection and workspace #117

Open
jakob-lj opened this issue Oct 17, 2024 · 0 comments
Open

Pre request scripts for all requests in collection and workspace #117

jakob-lj opened this issue Oct 17, 2024 · 0 comments

Comments

@jakob-lj
Copy link

Thank you for an excellent tool!

We're utilizing the pre-request script feature in our Postman collection to run the same script for all requests within the collection.

Since many of our requests share the same authentication mechanism, it’s essential to refresh tokens as needed without duplicating code in each request. By applying the DRY principle, we've streamlined this process in Postman. The pre-request script updates variables, which are then used for authentication across the collection.

The requests inherit the authentication and variables from the collection, making the implementation both efficient and maintainable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant