Tabnine APIs

The Usage API provides programmatic access to usage metrics across an organization

Usage API

The Usage API (released with 5.18.0) provides programmatic access to usage metrics across an organization. It complements existing enterprise reporting options—UI-based usage reports and CSV exports—by enabling integration into internal dashboards and tools via API.

The Usage API is available to all Enterprise customers on both SaaS (console.tabnine.com) and Private installations.

The APIs return JSON with parameter details and example responses.

Audit Logs API

The Audit Logs API (released with 5.25.0), allows for user access to audit logs that track key user management, team management, and user logging events.

The audit log includes the following information:

  • Performing user

  • Affected user

  • Time of change

  • Value change for each event

Tabnine allows for self-serve access via the Audit Logs API with a token. Users can download these logs either as a CSV file or a JSON HTTP response.

To set the number of parameters, use this URL:

/organization/audit_logs?limit=50&offset=0

To download as a CSV, use the URL:

/organization/audit-logs?csv-format

Only users with Admin access to Tabnine can access the Audit Logs API.

You can use the same mapping from the Usage API between user_id to email and team_id to team name.

API Categories

The Usage API can retrieve the following information:

  • Organization & Teams

    • Get organization and team IDs

    • List organization teams

    • List users from each team

  • Usage Metrics

    • Active users

    • Account utilization

    • Productivity factor

    • Automation factor

    • Usage volumes for:

      • Code Completions

      • Chat Interactions

List of Implemented APIs

APIs return JSON with parameter details and example responses:

Organization-Level Info APIs and Usage APIs

  1. Get current organization ID and high-level settings

  2. Get list of teams for given organization

  3. Get license info

  4. Get account utilization info

  5. Get account permissions info

  6. Get organization-level usage

Team-Level Info APIs

  1. Get users of a given team

  2. Get users that aren't assigned to a team

  3. Get current utilization info

  4. Get team name

  5. Team Level Usage API

Organization-Level APIs

Get current organization ID and high-level settings

Endpoint:

GET /api/v1/organization

Parameters:

Parameter
Type
Required?
Description

-

-

-

-

Response Codes:

  • 200 OK – Successful response with usage data

  • 400 Bad Request – Invalid or missing parameters

  • 401 Unauthorized – Invalid token

  • 404 Not Found – Organization or team not found

  • 500 Internal Server Error – Unexpected server error

Response (JSON):

{
    "publicKey": "-----BEGIN PUBLIC KEY-----\nMIICIXXXXXXAAQ==\n-----END PUBLIC KEY-----\n",
    "samlEnabled": false,
    "smtpConfigured": true,
    "usernamePasswordEnabled": true,
    "name": "Yagel",
    "domains": [
        "tabnine.com"
    ],
    "planType": "Enterprise",
    "id": "9a3895ca-1c27-4231-8978-85ae00267d02"
}

Team-Level APIs

Get Users for a Given Team

This returns all registered and deactivated users from a team.

Endpoint:

GET api/v1/team/{:teamId}/users?offset=0&limit=0

Parameters:

Parameter

Type

Required?

Description

limit

string (non-negative integer)

Specifies the maximum number of items to return. (Example: limit=10 returns only 10 items)

offset

string

Skips a number of items before starting to return results.(Example: offset=20 skips the first 20 items and starts from item 21)

Response Codes:

  • 200 OK – Successful response with usage data

  • 400 Bad Request – Invalid or missing parameters

  • 401 Unauthorized – Invalid token

  • 404 Not Found – Organization or team not found

  • 500 Internal Server Error – Unexpected server error

Response (JSON):

{
    "data": [
        {
            "id": "xxxxxxxxxxxxxxxxxx",
            "username": "Taylor",
            "email": "[email protected]",
            "role": "Admin",
            "verified": true
        },
        {
            "id": "yyyyyyyyyyyyyyy",
            "username": "Matt",
            "email": "[email protected]",
            "role": "Manager",
            "verified": true
        },
        {
            "id": "ZZZZZZZZZZZZZZZZZZZZ",
            "username": "Ben",
            "email": "[email protected]",
            "role": "Member",
            "verified": true
        }
    ],
    "meta": {
        "count": 3,
        "total": 3,
        "next": {
            "limit": 0,
            "offset": 0
        }
    }
}

User-Level APIs

This returns all user-level information: organization ID, user ID, and token.

Endpoint:

GET /api/v1/user/{user_id}

Parameters:

Parameter
Type
Required
Description

user_id

string

The unique identifier of the user

Response Codes:

  • 200 OK – Successful response with user info.

  • 400 Bad Request – Invalid or missing parameters.

  • 401 Unauthorized – Invalid token.

  • 403 Forbidden – User lacks permission to access this user's info.

  • 404 Not Found – Organization or user not found.

  • 500 Internal Server Error – Unexpected server error.

Response (JSON):

{
    "user": {
        "organization_id": "zzzz-ab43-4422-ttt-8c2a273e04a1",
        "user_id": "xxx-705e-yyy-ad27-82cfdebe51b3",
        "email": "[email protected]",
        "role": "Member",
        "createdAt": "2025-08-26T15:16:16.557Z",
        "updatedAt": "2025-08-26T15:16:16.557Z"
    },
    "teams": {
        "team_id": "b027d7e4-f925-49ca-9a43-56c868580635",
        "team_name": "Default Team"
    }
}

Last updated

Was this helpful?