Install and set up the Collibra CLI

The Collibra CLI is a unified command-line tool that packages API calls, allowing you to manage your Collibra products directly from the terminal. It allows you to manually interact with your environment and seamlessly integrate into automation workflows.

You can use the CLI to carry out the following tasks:

Product area

Task

AI Command Center Use the CLI to register AI model versions in Collibra
Data Products Create and manage data contracts through the CLI

Requirements for organizations using SSO

If your organization uses SSO to sign in to Collibra, your authentication path depends on your SSO type:

  • SAML2: Your standard SSO credentials cannot be used to log in to the CLI. You need a dedicated local account. Ask your Collibra administrator to create a dedicated user account directly in your Collibra environment (bypassing SSO/LDAP), assign it the relevant permissions, and send you an invitation to activate it. Use those local credentials to authenticate with the CLI.
  • OAuth: The CLI supports OAuth 2.0 authentication directly. Your administrator must first register an OAuth application in your Collibra environment and provide you with a client ID and client secret. For complete setup information, go to Configure an OAuth application for the CLI.

Configure an OAuth application for the CLI

Before CLI users can authenticate with OAuth 2.0, a Collibra administrator must register an OAuth application in your Collibra environment.

Prerequisites

Steps

  1. In Cogwheel iconSettings, click OAuth applications.
  2. Click + New Application.
    The Select your application type dialog box appears.
  3. In the User Application section, click Register user application.
  4. Enter the required information.

    Setting

    Description

    Application nameA unique name to identify this OAuth application in your Collibra environment.
    Redirect URI(s)

    The URI(s) to which Collibra redirects the user after authentication. The CLI uses this URI to receive the authorization code.

    Click + Add URI to specify multiple redirect URIs.

    Enable Proof Key for Code Exchange (PKCE)When enabled, adds a security layer that protects the authorization code against interception attacks. It is switched on by default. Switch it off only if your OAuth client configuration requires it.
  5. Click Register.
    The client ID and client secret are generated and shown in a dialog box. Save them and provide them to the CLI user when carrying out the following procedure.

Install and set up the CLI

  1. Download the CLI from GitHub, and extract it.
    1. Download the appropriate file for your operating system and processor:
      • Windows amd64, for most Windows units.
      • Windows arm64, for Surface and others.
      • Linux amd64, for most Linux units.
      • Linux arm64, for Linux units with ARM architecture.
      • darwin-macos all, for Mac.
    2. Open your terminal or command prompt.
    3. Navigate to the folder where you saved the CLI file you downloaded.
      For example:
      • Windows: cd C:\Users\YourUserName\Downloads
      • Linux: cd ~/Downloads
      • Mac: cd ~/Downloads
    4. Unarchive or unzip the binary file.
      For example:
      • Windows: tar -xf collibra-x.x.x-windows_xxx64.zip
      • Linux: tar -xf collibra-x.x.x-linux_xxx64.tar.gz
      • Mac: unzip collibra-x.x.x-darwin-macos_all.zip
    5. For Mac only:
      Important You may encounter a standard macOS security prompt during installation. This occurs because the current version is pending an official Apple signing key. We are working with Apple to automate this process.

      If your Mac prevents the file from running because the developer isn't verified:
      1. Open System Settings/Preferences > Security & Privacy.
      2. Look for a message about the "collibra" file being blocked and click Open Anyway.
        Tip Alternatively, run the following command to verify the file: xattr -d com.apple.quarantine <file>.
    6. Run the binary file without any arguments to confirm it's working.
      • Windows: .\collibra
      • Linux: ./collibra
      • Mac: ./collibra
      A help message is shown.
  2. Set the environment variables.
    1. Open your terminal or command prompt.
    2. Choose your authentication method and run the corresponding commands for your operating system.
      Replace the placeholder information with your own. If you use a proxy, include the variable https_proxy.

      Basic Auth

      Windows CMD

      SET COLLIBRA_URL=https://<YourCollibraEnvironment>.collibra.com

      SET COLLIBRA_USERNAME=<YourUsername>

      SET COLLIBRA_PASSWORD=<YourPassword>

      Windows Powershell

      $env:COLLIBRA_URL="https://<YourCollibraEnvironment>.collibra.com"

      $env:COLLIBRA_USERNAME="<YourUsername>"

      $env:COLLIBRA_PASSWORD="<YourPassword>"

      Mac and Linux

      export COLLIBRA_URL='https://<YourCollibraEnvironment>.collibra.com'

      export COLLIBRA_USERNAME='<YourUsername>'

      export COLLIBRA_PASSWORD='<YourPassword>'

      OAuth 2.0

      Windows CMD

      SET COLLIBRA_URL=https://<YourCollibraEnvironment>.collibra.com

      SET COLLIBRA_CLIENT_ID=<YourClientID>

      SET COLLIBRA_CLIENT_SECRET=<YourClientSecret>

      Windows Powershell

      $env:COLLIBRA_URL="https://<YourCollibraEnvironment>.collibra.com"

      $env:COLLIBRA_CLIENT_ID="<YourClientID>"

      $env:COLLIBRA_CLIENT_SECRET="<YourClientSecret>"

      Mac and Linux

      export COLLIBRA_URL='https://<YourCollibraEnvironment>.collibra.com'

      export COLLIBRA_CLIENT_ID='<YourClientID>'

      export COLLIBRA_CLIENT_SECRET='<YourClientSecret>'

      Note Optionally, set COLLIBRA_REDIRECT_URI to specify the redirect URI registered in your Collibra OAuth application.

    Tip Setting the environment variables as described here is temporary and only lasts for the duration of your current terminal session. To make them permanent, add the relevant lines to a configuration file such as ~/.bashrc, ~/.zshrc, or ~/.bash_profile, save the file, and then restart your terminal.
  3. OAuth 2.0 only: Run the following command to authenticate:
    • Windows: .\collibra login
    • Mac and Linux: ./collibra login
    Your browser opens. Sign in to your Collibra environment to complete authentication. Your token is stored securely and refreshed automatically for all subsequent CLI commands.
    Note 
    • Your token is stored securely: using the OS credential store on Mac and Linux, and DPAPI on Windows.
    • Your token is valid for up to one hour of activity. After one hour of inactivity, run collibra login again to re-authenticate.
  4. Run the following command to confirm that the CLI setup was successful:
    • Windows: .\collibra info
    • Mac and Linux: ./collibra info

What's next