Use these APIs to query usage, retrieve audit data, and automate team administration in Tabnine Enterprise.
Authentication
All APIs return JSON and require an access token.
Only users with Admin access can generate tokens.
Go to Settings > Access Tokens.
Click Generate token.
Enter a token description.
Click Generate Token.
Copy the token before closing the dialog.
Generate a new token in the Access Tokens section
If you lose a token, revoke it and generate a new one.
USAGE METRICS
The Usage API, released with 5.18.0, provides programmatic access to usage metrics across an organization.
It is available to Enterprise SaaS and private installations.
ORGANIZATIONS
Use these endpoints to retrieve organization-wide metadata and usage.
GET CURRENT ORGANIZATION
Get current organization
get
/api/v1/organization
Get current organization ID and high-level settings
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Responses
200
Organization information
application/json
idstring · uuidRequired
namestringRequired
publicKeystringOptional
Public key in PEM format
samlEnabledbooleanOptional
smtpConfiguredbooleanOptional
usernamePasswordEnabledbooleanOptional
domainsstring[]Optional
planTypestringOptional
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization
GET LIST OF TEAMS
List teams
get
/api/v1/organization/teams
Get list of teams for the organization
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
offsetintegerOptionalDefault: 0
limitintegerOptionalDefault: 50
Responses
200
List of teams
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization/teams
GET ACCOUNT USAGE INFO
Get account utilization info
get
/api/v1/organization/account-utilizations
Get monthly account utilization (registered, deactivated, active, pending users)
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
startDatestringOptional
Start date for showing utilization (YYYY-MM). Default is last 12 months.
Example: 2025-01Pattern: ^\d{4}-\d{2}$
Responses
200
Monthly utilization data
application/json
yearinteger · min: 1970Required
monthinteger · max: 11Required
Zero-based month (0=January, 11=December)
registeredintegerRequired
deactivatedintegerRequired
activeintegerRequired
pendingintegerRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization/account-utilizations
GET ORG-LEVEL USAGE
Get organization usage
get
/api/v1/organization/usage
Returns aggregated usage metrics for an organization over a given time range.
Includes per-tool metrics for agent, chat, code completions, and instruct.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
organizationIdstring · uuidRequired
fromstring · date-timeRequired
Start of reporting interval (inclusive), ISO-8601 UTC
Example: 2025-03-23T00:00:00Z
tostring · date-timeRequired
End of reporting interval (exclusive), ISO-8601 UTC
Example: 2026-02-23T00:00:00Z
granularitystring · enumRequired
Aggregation granularity for usage data
Example: allPossible values:
Responses
200
Organization usage data
application/json
organizationIdstring · uuidRequired
fromstring · date-timeRequired
tostring · date-timeRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization/usage
GET USERS NOT ASSIGNED TO TEAMS
Get organization users
get
/api/v1/organization/users
Get users in the organization. Can filter by team membership and active status.
Use teamMember=false to get users not assigned to any team.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
limitintegerOptional
Maximum number of items to return
Default: 200
offsetintegerOptional
Number of items to skip
Default: 0
teamMemberbooleanOptional
Filter by team membership. Use false for unassigned users.
activebooleanOptional
Filter by active status. true=registered, false=deactivated.
Responses
200
Paginated list of users
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization/users
LICENSES & PERMISSIONS
Use these endpoints to validate entitlements and enabled permissions.
GET LICENSE INFO
Returns license metadata for the current Tabnine instance.
Get license info
get
/api/v1/license
Get license information including seats, features, and settings
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Responses
200
License information
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/license
GET ACCOUNT PERMISSIONS INFO
Returns the permissions enabled on this Tabnine instance.
Get account permissions
get
/api/v1/instance/permissions
Get list of users with a specific role (e.g., account admins)
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
rolestringRequiredExample: Admin
Responses
200
Users with specified role
application/json
usernamestringRequired
organizationIdstring · uuidRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/instance/permissions
TEAMS AND USERS
Use these endpoints to retrieve team-level and user-level usage data.
GET TEAM USERS
Get team users
get
/api/v1/team/{teamId}/users
Get paginated list of users in a team
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
teamIdstring · uuidRequired
Team UUID
Query parameters
offsetintegerRequired
limitintegerRequired
Responses
200
Team users
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/team/{teamId}/users
GET TEAM USAGE INFO
Get team utilization
get
/api/v1/team/account-utilizations
Get current team utilization counts (registered, deactivated, invited)
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
teamIdstring · uuidRequired
Responses
200
Team utilization counts
application/json
registeredintegerRequired
deactivatedintegerRequired
invitedintegerRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/team/account-utilizations
GET TEAM INFO BY teamId
GET TEAM-WIDE USAGE
Get team usage
get
/api/v1/team/usage
Get team-level usage metrics over a time range
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
organizationIdstring · uuidRequired
teamIdstring · uuidRequired
fromstring · date-timeRequired
Start of reporting interval (inclusive), ISO-8601 UTC
Example: 2025-03-23T00:00:00Z
tostring · date-timeRequired
End of reporting interval (exclusive), ISO-8601 UTC
Example: 2026-02-23T00:00:00Z
granularitystring · enumRequired
Aggregation granularity for usage data
Example: allPossible values:
Responses
200
Team usage data
application/json
organizationIdstring · uuidRequired
teamIdstring · uuidRequired
fromstring · date-timeRequired
tostring · date-timeRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/team/usage
Get user info by user_id
Get user usage
Get user usage
get
/api/v1/user/usage
Get user-level usage metrics over a time range
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
organizationIdstring · uuidRequired
userIdstring · uuidRequired
fromstring · date-timeRequired
Start of reporting interval (inclusive), ISO-8601 UTC
Example: 2025-03-23T00:00:00Z
tostring · date-timeRequired
End of reporting interval (exclusive), ISO-8601 UTC
Example: 2026-02-23T00:00:00Z
granularitystring · enumRequired
Aggregation granularity for usage data
Example: allPossible values:
Responses
200
User usage data
application/json
organizationIdstring · uuidRequired
userIdstring · uuidRequired
fromstring · date-timeRequired
tostring · date-timeRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/user/usage
AUDIT LOGS
The Audit Logs API, released with 5.25.0, returns audit events for user management, team management, and authentication activity.
The audit log includes:
Performing user
Affected user
Time of change
Value change for each event
You can use the same mapping from the Usage Metrics API between user_id and email, and between team_id and team name.
List audit log events
get
/api/v1/organization/audit-logs
Returns a paginated list of audit log events for the organization.
Supports filtering by time range, event type, actor, and resource.
Can return JSON or CSV format.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
fromstring · date-timeOptional
Start of time range (inclusive)
tostring · date-timeOptional
End of time range (exclusive)
eventTypestringOptional
Filter by event type (e.g., team_member.added, role.assigned)
actorIdstringOptional
Filter by actor ID
actorEmailstring · emailOptional
Filter by actor email
resourceTypestringOptional
Filter by resource type (team, user, role, organization)
resourceIdstringOptional
Filter by resource ID
sortstring · enumOptional
Sort order by timestamp
Default: descPossible values:
limitinteger · min: 1 · max: 1000Optional
Maximum number of events per page
Default: 50
offsetintegerOptional
Number of items to skip
Default: 0
formatstring · enumOptional
Output format (json or csv)
Default: jsonPossible values:
Responses
200
Paginated audit log events
totalintegerOptional
Total matching items (may be approximate)
limitintegerRequired
offsetintegerRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
429
Too Many Requests - Rate limit exceeded
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/v1/organization/audit-logs
USER MANAGEMENT
The User Management API, released with 5.27.0, automates user role management and team membership.
UPDATE USER
Update user properties
patch
/api/user/v1/{userId}
Update user role, active status, or team assignment.
Requires Admin or Manager role (with role hierarchy checks).
Cannot modify self, instance admins, or anonymized users.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Body
All fields are optional; only provided fields will be updated
rolestring · enumOptionalPossible values:
activebooleanOptional
teamIdstring · uuid · nullableOptional
Responses
200
User updated
application/json
successbooleanRequired
messagestringRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
409
Conflict - invalid user state
422
Insufficient permissions for role operation
500
Internal Server Error - Unexpected server error
application/json
patch
/api/user/v1/{userId}
Permissions
Role
Assign Team
Update Role
Activate/Deactivate
Invite
Admin
✓
✓ (all roles)
✓
✓ (all roles)
Manager
✓
✓ (Member, Team Lead, Manager)
✓
✓ (Member, Team Lead, Manager)
Team Lead
✗
✗
✗
✗
Member
✗
✗
✗
✗
To use this API, you will need user and team data from the organization and team APIs above.
TEAM REPOSITORIES
The Repository Management API, released with 5.27.0, automates repository connection management for teams.
All endpoints follow this structure:
/api/team/v1/{teamId}/connections/repositories
As of 5.27.0, only Admins have permission for this endpoint.
LIST REPOSITORIES
Get team repositories
get
/api/team/v1/{teamId}/connections/repositories
Retrieve all repository connections for a team. Requires Admin role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
teamIdstring · uuidRequired
Team UUID
Responses
200
List of repository connections
application/json
repository_linkstringRequired
The URL or path to the repository
repo_typestring · enumRequiredPossible values:
authentication_methodstring · enumOptional
Authentication method (Git only)
Possible values:
authentication_credentials_namestringOptional
Name of credentials for authentication
view_source_link_patternstringOptional
Template pattern for source code links. Use {path} and {line}.
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/team/v1/{teamId}/connections/repositories
ADD REPOSITORY
Add team repository
post
/api/team/v1/{teamId}/connections/repositories
Add a new repository connection to a team. Requires Admin role.
Git repositories can optionally include authentication.
Perforce repositories require authentication.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
teamIdstring · uuidRequired
Team UUID
Body
repository_linkstringRequired
repo_typestring · enumRequiredPossible values:
authentication_methodstring · enumOptional
Optional for Git, not applicable for Perforce
Possible values:
authentication_credentials_namestringOptional
Optional for Git, required for Perforce
view_source_link_patternstringOptional
Responses
200
Repository connection added
application/json
repository_linkstringRequired
The URL or path to the repository
repo_typestring · enumRequiredPossible values:
authentication_methodstring · enumOptional
Authentication method (Git only)
Possible values:
authentication_credentials_namestringOptional
Name of credentials for authentication
view_source_link_patternstringOptional
Template pattern for source code links. Use {path} and {line}.
Git: repository URL in SSH or HTTPS format. Perforce: depot path such as //depot/main
latest_status
string
Read-only
Current indexing status
last_indexed_successfully
string or null
Read-only
ISO 8601 timestamp of last successful indexing, or null if never indexed
Git-specific fields
Field
Type
Required
Description
authentication_method
string
Yes
"ssh" or "https"
authentication_credentials_name
string
Conditional
Required when authentication_method is "https"
view_source_link_pattern
string
No
URL pattern for viewing source code. Supports {sha}, {path}, and {line}
Perforce-specific fields
Field
Type
Required
Description
authentication_credentials_name
string
Yes
Must match an existing Perforce credential name for the team
view_source_link_pattern
string
No
Currently not used for Perforce
Status values
Status
Description
pending
Repository is queued for initial indexing
cloning
Repository is being cloned
indexing
Repository is currently being indexed
success
Repository was successfully indexed
failed
Last indexing attempt failed
Perforce depots typically skip cloning and go directly to indexing.
TEAM MANAGEMENT
Use these APIs to manage teams, users, and invitations in Tabnine Enterprise.
CREATE A TEAM
Introduced in 6.0.0.
Create a team
post
/api/team/v1
Create a new team within the organization.
Requires Admin or Manager role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Body
namestring · min: 1Required
Responses
201
Team created
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
409
Team with the same name already exists
500
Internal Server Error - Unexpected server error
application/json
post
/api/team/v1
GET TEAM BY ID
RENAME TEAM
USER MANAGEMENT
GET USER INFO
Get user info
get
/api/user/v1/{userId}
Get user details including allowed teams and primary team.
Requires Admin role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Responses
200
User information
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/user/v1/{userId}
UPDATE USER PROPERTIES
Update user properties
patch
/api/user/v1/{userId}
Update user role, active status, or team assignment.
Requires Admin or Manager role (with role hierarchy checks).
Cannot modify self, instance admins, or anonymized users.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Body
All fields are optional; only provided fields will be updated
rolestring · enumOptionalPossible values:
activebooleanOptional
teamIdstring · uuid · nullableOptional
Responses
200
User updated
application/json
successbooleanRequired
messagestringRequired
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
409
Conflict - invalid user state
422
Insufficient permissions for role operation
500
Internal Server Error - Unexpected server error
application/json
patch
/api/user/v1/{userId}
LOOK UP USER BY EMAIL
Get user by email
get
/api/user/v1/by-email/{email}
Look up a user by email address.
Requires Admin or Manager role.
Returns 404 if user not found or belongs to different organization.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
emailstring · emailRequired
URL-encoded email address
Responses
200
User found
application/json
idstring · uuidRequired
usernamestringOptional
emailstring · emailRequired
rolestring · enumRequiredPossible values:
verifiedbooleanRequired
activebooleanOptional
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/user/v1/by-email/{email}
LIST USER'S ALLOWED TEAMS
List user's allowed teams
get
/api/user/v1/{userId}/allowed-teams
List teams a user is allowed to access.
Requires Admin or Manager role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Responses
200
List of allowed teams
application/json
idstring · uuidRequired
namestringRequired
organizationIdstring · uuidRequired
syncedGroupIdstring · nullableOptional
Optional ID of synced external group
usersCountintegerOptional
isDefaultTeambooleanOptional
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/user/v1/{userId}/allowed-teams
Add teams to a user's allowed list
Add allowed teams to user
patch
/api/user/v1/{userId}/allowed-teams
Add teams to a user's allowed-teams list.
Requires Admin or Manager role.
Idempotent operation.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Body
teamIdsstring · uuid[] · min: 1Required
Responses
200
Teams added to allowed list
No content
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
patch
/api/user/v1/{userId}/allowed-teams
No content
Remove teams from a user's allowed list
Remove allowed teams from user
delete
/api/user/v1/{userId}/allowed-teams
Remove teams from a user's allowed-teams list.
Requires Admin or Manager role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Path parameters
userIdstring · uuidRequired
User UUID
Body
teamIdsstring · uuid[] · min: 1Required
Responses
200
Teams removed from allowed list
No content
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
delete
/api/user/v1/{userId}/allowed-teams
No content
INVITATION MANAGEMENT
INVITE USER BY EMAIL
Use this endpoint to invite a user to a team by email.
Invite user to team
post
/api/invitation/v1
Invite a user by email to a team with a role.
Requires Admin or Manager role (with role hierarchy checks).
Returns 201 for new invitation, 200 if user already exists.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Body
emailstring · emailRequired
teamIdstring · uuidRequired
rolestring · enumRequiredPossible values:
Responses
200
Existing user added to team
application/json
successbooleanRequired
messagestringRequired
userExistsbooleanRequired
userIdstring · uuidRequired
201
Invitation created for new user
application/json
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
409
Invitation already exists
500
Internal Server Error - Unexpected server error
application/json
post
/api/invitation/v1
LIST PENDING INVITES
List invitations
get
/api/invitation/v1
List pending invitations, optionally filtered by team.
Requires Admin or Manager role.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
offsetintegerRequired
limitinteger · min: 1Required
teamIdstring · uuidOptional
Filter invitations by team ID
Responses
200
Paginated invitations
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
500
Internal Server Error - Unexpected server error
application/json
get
/api/invitation/v1
REVOKE INVITES BY ID
Revoke invitations
delete
/api/invitation/v1
Revoke (soft-delete) invitations by IDs.
Requires Admin or Manager role (with role hierarchy checks).
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Body
invitationIdsstring · uuid[] · min: 1Required
Responses
200
Invitations revoked
application/json
revokedintegerRequired
Number of invitations revoked
400
Bad Request - Invalid or missing parameters
application/json
401
Unauthorized - Invalid or missing token
application/json
403
Forbidden - Insufficient permissions
application/json
404
Not Found - Resource not found
application/json
500
Internal Server Error - Unexpected server error
application/json
delete
/api/invitation/v1
AGENT USAGE
This API returns aggregated usage analytics for your organization, broken down by AI tools such as agent, chat, code completions, and instruct over a time range.
TOOLS USAGE
Get organization usage
get
/api/v1/organization/usage
Returns aggregated usage metrics for an organization over a given time range.
Includes per-tool metrics for agent, chat, code completions, and instruct.
Authorizations
AuthorizationstringRequired
JWT Bearer token for authentication
Query parameters
organizationIdstring · uuidRequired
fromstring · date-timeRequired
Start of reporting interval (inclusive), ISO-8601 UTC
Example: 2025-03-23T00:00:00Z
tostring · date-timeRequired
End of reporting interval (exclusive), ISO-8601 UTC