I believe the limitation in question is an AWS limitation (Environment properties and other software settings - AWS Elastic Beanstalk search for “4,096”) - around all environment variables, when first concatenated like this:
VARNAME1=val1,VARNAME2=val2
and creating a string, which must be <4096 characters including commas, possibly after encoding. So a very long string like that will likely cause that kind of breakage, considering that all build variables are taken together and our own variables that are set (such as AWS_SECRET_KEY and the like to enable the integration and potentially some others like these that we set in build: Build configuration overview | Netlify Docs) are non-optional).