Render API - Environment Variable Limit

Hi, I’m hitting the following endpoint https://api.render.com/v1/services/{serviceId}/env-vars with more than 150 environment variables. It seems to error out and the error message from the endpoint is the following:

message:'too many env vars for service, max is 150'

Does this mean that for a given service the maximum env vars count is 150? Or does it mean I can only update 150 environment variables per call to that endpoint?
I have not been able to find any documentation about this limit apart from the error message returned for this scenario.

Hi Max,

So I’ve been hunting around to get an answer for this.

The 150 is the number per call, but each call replaces all the env vars for the service - so it’s effectively a limit on the number of env vars for the service. 150 environment variables would certainly seem a lot though?

John B

1 Like

Hi @John_B,

Makes sense! I think it would be valuable to explicitly put that limit in the documentation for the API. 150 secrets is a fine limit! I wanted to confirm if it was the case.

Thank you a lot :slight_smile: