I want to update binary variable value with environment variable value in post req

I have a POST request with request data from binary file
“body”: { “mode”: “file”, “src”: “/path/sample.txt” }
I have few variables in sample.txt which I want to replace at runtime with environment variable value
sample.txt
{
{
“id”: {{id}}
}
}
These values are not getting updated during execution . how I can achieve this