Skip to content

Policies

Policies control what happens when an AI agent tries to call an API operation through Airlock.

Policy Basics

Every server has a policy that defines the behavior for each operation (tool).

Actions

ActionBehavior
ALLOWExecute immediately without approval
REQUIRE_APPROVALCreate a pending request and notify approvers
DENYBlock the operation entirely (returns error to agent)

Default Policy

When you create a server, all operations default to REQUIRE_APPROVAL for maximum security. This ensures human oversight for all API calls until you explicitly allow specific operations.

Configuring Policies

From the Control Room

  1. Navigate to your server's detail page
  2. Find the Policy Configuration section listing all available operations
  3. For each tool, select the action:
    • Allow - Executes without approval
    • Require Approval - Needs human approval before executing
  4. Changes are saved automatically

Assigning Approvers

For tools set to require approval, you must assign who can approve requests:

  1. Click Add Approver next to the tool
  2. Select approvers:
    • Individual users from your organization
    • Groups for team-based approval
  3. Multiple approvers can be assigned - any one of them can approve

Policy Patterns

Read-Only Access

Allow all read operations, require approval for writes:

Tool PatternAction
list_*ALLOW
get_*ALLOW
search_*ALLOW
create_*REQUIRE_APPROVAL
update_*REQUIRE_APPROVAL
delete_*REQUIRE_APPROVAL

Full Access with Delete Protection

Allow most operations, but require approval for destructive actions:

Tool PatternAction
Most toolsALLOW
delete_*REQUIRE_APPROVAL

Maximum Security

Every operation needs human approval:

Tool PatternAction
All toolsREQUIRE_APPROVAL

Best Practices

  1. Start Restrictive: Begin with all tools requiring approval
  2. Gradually Open: Allow operations as you gain confidence in their safety
  3. Protect Destructive Actions: Always require approval for delete operations
  4. Use Groups: Assign approvers to groups rather than individuals for easier management
  5. Regular Review: Periodically audit your policies to ensure they match your security requirements

Tool Naming

Tools are named based on the operationId in your OpenAPI specification:

yaml
paths:
  /users:
    get:
      operationId: list_users  # Tool name: list_users
    post:
      operationId: create_user  # Tool name: create_user

Use consistent naming conventions to make policy management easier:

  • list_* for collection endpoints
  • get_* for single resource retrieval
  • create_* for creation
  • update_* for modifications
  • delete_* for deletion

Built with VitePress