graphlife Docs graphlife.app

Integration API

Server settings

Environment variables of the server that change what an integration sees.

Variable Default Meaning
RATE_KEY_PER_SEC 100 calls a second for one API key or OAuth token. 0 turns the limit off
RATE_KEY_BURST 1000 how many it may send at once before that rate applies. 0 or less turns the limit off
RATE_SESSION_PER_SEC 20 the same for a signed-in account
RATE_SESSION_BURST 60
EVENTS_RETENTION_DAYS 30 days the change log is kept. A token older than that answers a reset. 0 keeps it for good
WEBHOOK_ALLOW_HTTP false true allows http:// webhook targets
WEBHOOK_ALLOW_PRIVATE false true allows loopback and private addresses
WEBHOOK_TIMEOUT_SECONDS 10 how long one delivery may take, connection to answer
WEBHOOK_MAX_FAILURES 80 failures in a row before a webhook is disabled
WEBHOOK_MAX_PER_GRAPH 10 webhooks one graph may have

Webhooks also need SECRET_KEY to be set.

The key limit shares the server out between keys; it does not protect the server from all of them together. A 4-vCPU server answers about 60 cheap calls a second, below one key's default, so where one integration does most of the traffic set RATE_KEY_PER_SEC to about half of what the server answers, and RATE_KEY_BURST to ten times that.

SHUTDOWN_GRACE_SECONDS (default 8) is how long a stopping server lets the requests already running finish. Keep it below the platform's own wait before it kills the process (10 s for docker stop).