Permissions
The SDK enforces the same AgentPermissions model described in Concepts: Permissions on the client. This page covers the two ways to set them from @appilots/sdk and how to reason about the defaults.
Recap: the permissions shape
interface AgentPermissions {
canNavigate: boolean;
canFillForms: boolean;
canInteractUI: boolean;
canSubmitForms: boolean;
allowedScreens?: string[];
blockedScreens?: string[];
allowedActions?: AgentActionType[];
}
See Concepts: Permissions for what each field gates and how allow/block lists are evaluated.
Option 1: inline in AppilotsProvider
Pass a permissions object in the config prop:
<AppilotsProvider
config={{
projectId: 'proj_xxxxxxxx',
apiKey: 'ak_xxxxxxxxxxxx',
permissions: {
canNavigate: true,
canFillForms: true,
canInteractUI: true,
canSubmitForms: false,
},
}}
>
<App />
</AppilotsProvider>
Option 2: via .appilotsrc
If your app uses the Metro plugin + auto-config, set permissions (a Partial<AgentPermissions>) in .appilotsrc:
{
"projectId": "proj_xxxxxxxx",
"apiKey": "ak_xxxxxxxxxxxx",
"permissions": {
"canNavigate": true,
"canFillForms": true,
"canInteractUI": true,
"canSubmitForms": false
}
}
See CLI: Configuration for the full .appilotsrc file format.
Defaults
If permissions isn't set in either place, the SDK defaults to fully open: canNavigate, canFillForms, canInteractUI, and canSubmitForms are all true, with no allowedScreens, blockedScreens, or allowedActions restrictions.
Dashboard permissions
The Appilots dashboard can also configure permissions at the project level — see Dashboard: Permissions, Budget & Personalization. The dashboard config applies project-wide across every build; the SDK config above is a client-side setting scoped to this particular app build. Both exist for different reasons — use the dashboard for organization-wide policy, and the SDK config when a specific build (e.g. a demo, or a build shipped to a specific audience) needs different behavior than the rest of your fleet.
Example: read-only demo vs. full-access production
A demo build that lets the agent look around and fill forms, but never actually submits anything:
const demoPermissions = {
canNavigate: true,
canFillForms: true,
canInteractUI: true,
canSubmitForms: false,
};
A production build with full access:
const productionPermissions = {
canNavigate: true,
canFillForms: true,
canInteractUI: true,
canSubmitForms: true,
};
Pass either as config.permissions on AppilotsProvider, and swap between them per build (environment variable, build flavor, etc.) however your app already manages config.
Next steps
- Concepts: Permissions — the full permission model and how allow/block lists are evaluated.
- Dashboard: Permissions, Budget & Personalization — project-level configuration.
- Hooks —
useAppilotsActionsis where confirmation gating (including a local safety-net for destructive actions) is enforced.