Add ability to add ENV variable across all API routes #6842
Labels
🛠️ compiler
Compiler
✨ enhancement
New feature or request
needs-discussion
Further discussion is needed prior to impl
Use Case
When defining a Cloud.API we can configure a few props (cors and corsOptions).
When we define routes on the API resource we can also add
env
to them (see example of GET)This is a proposal to allow the
cloud.Api
resource to define these at a high level (when we define the resource itself) through it's (ApiProps). Settingenv
values here would apply to all routes configured in the API.Proposed Solution
Allow user to define env variables when creating a new API.
Implementation Notes
No response
Component
No response
Community Notes
The text was updated successfully, but these errors were encountered: