[GH-ISSUE #3419] [feature]: additional variable scopes to be used in scripts #1148

Closed
opened 2026-03-16 18:51:44 +03:00 by kerem · 1 comment
Owner

Originally created by @DaPutzy on GitHub (Oct 4, 2023).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3419

Summary

Currently there is only one scope for variables: env (outside of the script scope itself).
To be able to use scripts to their full potential at least 2 more variable scopes are needed: "request" and "collection".

Why should this be worked on?

I do no want to pollute my environment when creating a variable that is only used in one request or collection.

Originally created by @DaPutzy on GitHub (Oct 4, 2023). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3419 ### Summary Currently there is only one scope for variables: env (outside of the script scope itself). To be able to use scripts to their full potential at least 2 more variable scopes are needed: "request" and "collection". ### Why should this be worked on? I do no want to pollute my environment when creating a variable that is only used in one request or collection.
kerem 2026-03-16 18:51:44 +03:00
  • closed this issue
  • added the
    feature
    label
Author
Owner

@JoshuaMoeckelmann commented on GitHub (Oct 16, 2023):

This is exactly what is holding me back from switching to hoppscotch... Would be an awesome feature

<!-- gh-comment-id:1764048196 --> @JoshuaMoeckelmann commented on GitHub (Oct 16, 2023): This is exactly what is holding me back from switching to hoppscotch... Would be an awesome feature
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1148
No description provided.