Atlan CLI¶
Limited functionality (so far)
You can use Atlan's command-line interface (CLI) to manage some metadata in Atlan. Currently data contracts and metadata for a limited set of asset types can be managed through the CLI.
Obtain the CLI¶
For now, the CLI must be downloaded as a pre-built binary:
Disclaimer — closed preview
This feature is in closed preview and therefore any download and installation from this link will be subject to the terms applicable to Product Release Stages . Contact your Atlan Customer Success Manager for your preview today.
If your organization is already part of the closed preview, your installation of the feature from this link shall become subject to the terms and scope of preview as agreed with your organization. Accordingly, any use of the feature outside the agreed scope may result in revocation of the closed preview for your organization. Please contact your system administrator before downloading.
Recommended
When installed via Homebrew, you can easily keep things up-to-date. If you do not use it already, see Homebrew's own installation documents for setting up Homebrew itself .
brew tap atlanhq/atlan
brew install atlan
curl -o atlan.tgz -L https://github.com/atlanhq/atlan-cli-releases/releases/latest/download/atlan_Darwin_arm64.tar.gz
tar xf atlan.tgz
curl -o atlan.tgz -L https://github.com/atlanhq/atlan-cli-releases/releases/latest/download/atlan_Darwin_amd64.tar.gz
tar xf atlan.tgz
curl -o atlan.tgz -L https://github.com/atlanhq/atlan-cli-releases/releases/latest/download/atlan_Linux_amd64.tar.gz
tar -zxf atlan.tgz
curl -o atlan.zip -L https://github.com/atlanhq/atlan-cli-releases/releases/latest/download/atlan_Windows_amd64.zip
unzip atlan.zip
Configure the CLI¶
You can configure the CLI using a config file or in some cases environment variables, with the following minimum settings1:
.atlan/config.yaml | |
---|---|
1 2 3 4 5 |
|
- An API token that has access to your assets.
- The base URL of your tenant (including the
https://
). - (Optional) Enable logging to produce more details on what the CLI is doing.
- When logging is enabled, specify the level of verbosity.
Environment variables | |
---|---|
1 |
|
- An API token that has access to your assets.
Define data sources¶
You should also define data sources in the config file:
.atlan/config.yaml | |
---|---|
6 7 8 9 10 11 12 |
|
-
Each data source definition must start with
data_source
, followed by a space and a unique reference name for the data source (snowflake
in this example).Reference name is your choice
The reference name you give in the configuration file is only used here and as a reference in any data contracts you define. It need not match the name of the connection or data source in Atlan itself.
-
You must indicate the type of connector for the data source (see connector types for options).
- Details of the connection must also be provided.
- You must provide the
name
of the connection, as it appears in Atlan. - You must provide the unique
qualified_name
of the connection in Atlan. - (Optional) You can also specify the database to use for this connection's assets by default, if none is specified in the data contract.
- (Optional) You can also specify the schema to use for this connection's assets by default, if none is specified in the data contract.
These ensure the CLI can map the details you specify in your data contract to the appropriate corresponding asset in Atlan.
What's next?¶
With the CLI, you can:
- Manage data contracts
- Upload and download files from Atlan's backing object store
- Sync metadata to a limited set of asset types
- Integrate data contracts with CI/CD processing
-
When both are specified, environment variables will take precedence. ↩