For local agent builders
Use this guide when your local agent is actively driving a browser, editor, or other app and you do not want Aion to treat that app like ordinary idle background clutter.
Developer guide
Keep Aion from auto-closing an app while your local AI or agent workflow is actively using it.
Who this is for
The point of this page is to help technically capable users and local automation builders integrate with Aion without turning internal implementation details into long-term compatibility promises.
Use this guide when your local agent is actively driving a browser, editor, or other app and you do not want Aion to treat that app like ordinary idle background clutter.
This page explains the public integration path behind Aion’s AI protection behavior. It is not required for normal use unless you are wiring your own local automation runtime.
Transport
Aion exposes a same-user Unix domain socket for AI lease traffic.
~/Library/Application Support/Aion/ipc/ai-protection.sock There is no localhost HTTP server, no dedicated XPC endpoint, no custom URL scheme, and no DistributedNotification transport for this feature.
Protocol flow
Actions
lease.beginlease.renewlease.endlease.can_close.replylease.can_close.request
Handshake and transport errors
session.hellosession.readysession.errorinvalid_handshakeunsupported_protocol_versionholder_id_mismatchunauthenticated App identity
Policy limits
Examples
{
"action": "session.hello",
"protocolVersion": 1,
"holderId": "agent.local.test",
"clientName": "Test Agent",
"pid": 42
} {
"action": "lease.begin",
"requestId": "req_123",
"holderId": "agent.local.test",
"appKey": "com.google.Chrome",
"leaseSeconds": 600
} {
"action": "lease.can_close.reply",
"requestId": "close_777",
"holderId": "agent.local.test",
"appKey": "com.google.Chrome",
"result": "extend_lease",
"leaseSeconds": 300
} Lease responses
acceptedinvalid_payloadunknown_actionunknown_appnot_entitledholder_mismatchrequest_expiredlease_conflict Boundary
Recipes
Start with the stable integration surface on this page. If your integration surface has its own practical quirks, use a recipe page like the one below rather than turning the base guide into an ever-growing troubleshooting dump.
A practical guide for local runtimes that actively drive an app and need Aion to keep treating that app as in-use instead of ordinary idle background state.
Read the runtime guideIf you are building a local agent integration and the current guide is not enough, email the use case and the exact message flow you need. For normal setup questions, the user guide is still the faster path.