The v3 API is currently in beta. Some endpoints may change as we improve the API.
https://api.devin.ai/v3beta1/enterprise/*– endpoints that require enterprise (account-level) permissionshttps://api.devin.ai/v3beta1/organizations/*– endpoints scoped to a single organization
Some enterprise endpoints operate on specific organizations but are still guarded by
enterprise-level permissions. These use paths like
/v3beta1/enterprise/organizations/{org_id}/...
(for example, GET /v3beta1/enterprise/organizations/{org_id}/audit-logs).
Even though they include an org_id path parameter, they still require
enterprise-level permissions such as ManageEnterpriseSettings.Permissions and RBAC
The v3 API uses Role-Based Access Control (RBAC) with service users. Each endpoint requires specific permissions that are assigned to the service user’s role. Service users can be created at either the enterprise level or organization level, and their permissions determine which endpoints they can access.Permission Types
The v3 API uses the following permissions:| Permission | Description | Endpoints |
|---|---|---|
ManageAccountKnowledge | Manage knowledge notes at enterprise or organization level | Notes endpoints (GET, POST, PUT, DELETE) |
ManageAccountPlaybooks | Manage playbooks at enterprise or organization level | Playbooks endpoints (GET, POST, PUT, DELETE) |
ManageEnterpriseSettings | Manage enterprise-wide settings including organization tags | Tags endpoints, Organization management |
Service User Scopes
Enterprise Service Users have access to enterprise-wide resources and can operate across all organizations within the enterprise. They use endpoints under/v3beta1/enterprise/*.
Organization Service Users are scoped to a specific organization and can only access resources within that organization. They use endpoints under /v3beta1/organizations/{org_id}/*.
Creating Service Users
Service users can be created via:- Enterprise Settings → Service Users: Create enterprise-level or organization-level service users with custom roles
Self
Get information about the authenticated service user:Audit Logs
Access comprehensive audit trails:Enterprise Audit Logs
Get enterprise-wide audit logs
Organization Audit Logs
Get audit logs for a specific organization
Consumption
Track detailed consumption metrics:Consumption Cycles
View consumption cycle summaries
Daily Consumption
Get daily consumption breakdowns
By Organization
Track consumption by organization
By User
Track consumption by user
By Session
Track consumption by session
Organizations
Manage organizations with full RBAC:List Organizations
View all organizations
Create Organization
Create a new organization
Update Organization
Update organization settings
Delete Organization
Delete an organization
Service Users
Manage service users at enterprise and organization levels:List Enterprise Service Users
View enterprise service users
Create Enterprise Service User
Create an enterprise service user
Update Enterprise Service User
Update an enterprise service user
Delete Enterprise Service User
Delete an enterprise service user
List Org Service Users
View organization service users
Create Org Service User
Create an organization service user
Users
Manage users at enterprise and organization levels:List Enterprise Users
View enterprise users
Add Enterprise User
Add a user to the enterprise
Update Enterprise User
Update an enterprise user
Remove Enterprise User
Remove a user from the enterprise
List Org Users
View organization users
Add Org User
Add a user to an organization
IDP Groups
Manage IdP groups at enterprise and organization levels:List Enterprise Groups
View enterprise IdP groups
Add Enterprise Group
Add an IdP group to the enterprise
List Org Groups
View organization IdP groups
Add Org Group
Add an IdP group to an organization
Git Permissions
Manage repository access:List Permissions
View git permissions for an organization
Add Permission
Add a git permission
Remove Permission
Remove a git permission
Notes
Manage knowledge notes at enterprise and organization levels:List Enterprise Notes
View enterprise knowledge notes
Create Enterprise Note
Create a new enterprise note
List Org Notes
View organization knowledge notes
Create Org Note
Create a new organization note
Playbooks
Manage playbooks at enterprise and organization levels:List Enterprise Playbooks
View enterprise playbooks
Create Enterprise Playbook
Create a new enterprise playbook
List Org Playbooks
View organization playbooks
Create Org Playbook
Create a new organization playbook
Sessions
Manage organization sessions:List Sessions
View sessions for an organization
Create Session
Create a new session
Terminate Session
Terminate an active session
Archive Session
Archive a session for future reference
Tags
Manage organization tags (requires session tags feature):Get Tags
View tags for an organization
Add Tags
Append tags to an organization
Replace Tags
Replace all tags for an organization
Delete Tag
Remove a specific tag
Roles & Metrics
List Roles
View available roles
Usage Metrics
Get enterprise usage metrics
Org Metrics
Get organization usage metrics
Usage Examples
View Code Examples
Check out code examples and common use cases for the v3 API
