What this integration does
The Heroku recipe runs an Express server that checks Esper first and then
proxies the request onward.
Example from the recipe:
const mitigationResponse = await axios.post(
"https://api.esperr.com/api/v1/runtime/mitigation",
{
ip: clientIP,
user_agent: req.headers["user-agent"],
path: req.path,
method: req.method,
heroku_request_id: req.headers["x-request-id"],
},
{
headers: {
Authorization: `Bearer ${ESPER_API_KEY}`,
"Content-Type": "application/json",
},
},
);
Environment variables
ESPER_API_KEY
ESPER_API_URL
Deploy
cd recipes/heroku
heroku create your-app-name
heroku config:set ESPER_API_KEY=your-api-key
git push heroku main
Good First DeploymentThis is a useful first integration when the team wants a simple hosted process
and does not need edge-specific behavior yet.