usebruno / bruno

Opensource IDE For Exploring and Testing Api's (lightweight alternative to postman/insomnia)
https://www.usebruno.com/
MIT License
28.14k stars 1.31k forks source link

Create Environment Variables as Objects and Arrays #1386

Open adel-haidar opened 10 months ago

adel-haidar commented 10 months ago

Hi, We recently started using Bruno hoping we can finally collaborate efficiently using git when it comes to API Requests. Previously we used postman, where I had environment variables, whose values were json objects and arrays and it was working just fine. Unfortunately I cannot seem to create such environment variables with Bru lang. Example:

Environment variable as object:

contactData: {
    phoneNumber: 12345678910
    emailAddress: test@test.com
    address: {
          street: 5th Avenue
          houseNumber: 12
          zipCode: 10110
          city: New York
          country: USA
   }
}

Environment variables as array:

books: [
    {
         title: any Title
         price: 25
    },
    {
         title: another title
         price: 50
    }
]

Is this possible? If not, can we have this as a new feature?

srpalwaidynamite commented 2 months ago

Would be helpful if this get fixed or if someone could provide a workaround