Skip to main content

Create data contracts

🧪 Preview feature! This feature is only available to select users for a limited period of time. The purpose of this private preview is to allow participating users to experiment with the feature and provide valuable feedback. If you'd like to participate in the private preview, reach out to your customer success manager for more information.

A data contract is an agreement between a data producer and consumer that specifies requirements for generating and using high-quality, reliable data. As a powerful tool for data management, data contracts can help you standardize contractual obligations between data producers and consumers, organize your assets with embeddable contract metadata, and enforce them with data quality rules.

In Atlan, you can directly add a data contract to supported assets and provide helpful context to your downstream users.

For a data contract to help build trust in your assets, it should be:

  • Templatized and easily comprehensible - use Atlan's YAML contract template to create standardized contracts and push to Atlan.
  • Version-controlled - continuously validate and monitor your data contracts either in runtime or real-time.
  • Embeddable - embed the contract as metadata for a supported asset.
  • Enforceable - enforce your contracts with data quality rules.
  • Extensible - identify new specifications, generate new versions, and then compare and contrast them.
Did you know?

You can create webhooks for data contracts and receive notifications for when a contract is added or updated to a URL of your choice.

Supported asset types​

You can create data contracts for the following asset types:

Supported asset metadata​

Atlan maps the following asset metadata properties to it contract properties:

Metadata propertyContract property
namedataset
typeNametype
userDescription or descriptiondescription
ownerUsersowner.users
ownerGroupsowners.groups
certificateStatuscertification.status
certificateStatusMessagecertification.message
announcementTypeannouncement.type
announcementTitleannouncement.title
announcementMessageannouncement.description
meaningNamesterms
classificationDef.displayNametags.name
classifications.propagatetags.propagate
classifications.restrict_propagation_through_lineagetags.restrict_propagation_through_lineage
classifications.restrict_propagation_through_hierarchytags.restrict_propagation_through_hierarchy
column.namecolumns.name
column.userDescription or column.descriptioncolumns.description
column.dataTypecolumns.data_type
column.isPrimarycolumns.primary
!column.isNullablecolumns.required
column.precisioncolumns.precision
column.numericScalecolumns.scale
tags on columncolumns.tags
column.meaningNamescolumns.terms
custom metadata (CM)custom_metadata.<CM>

Add a data contract to an asset​

Who can do this?

Any non-guest user with edit access to an asset's metadata can create, deploy, and manage data contracts. This only includes admin and member users in Atlan.

To add a data contract to an asset, you can either:

  • Create a contract directly in Atlan from the Contracts tab of the asset profile. You can create and maintain data contracts as easily as editing a word document.
  • Use Atlan CLI to import an existing contract from your local machine to Atlan directly or through a CI/CD pipeline. Atlan CLI is a command-line tool that you can download directly from Atlan to your local machine to create and push data contracts to Atlan. Once you have published the contract, you can also sync metadata from a contract to the governed asset in Atlan.

Once created, you will be able to monitor and manage your data contracts in Atlan.

To add a data contract:

  1. From the left menu of any screen in Atlan, click Assets.
  2. (Optional) From the Filters menu on the left, click Properties and then click Has contract. Click No to filter for assets without a contract.
  3. From the Assets page, select an asset to open the asset sidebar.
  4. In the left Overview sidebar, click Add contract.
  5. In the Contract tab of the asset profile, you can either:
    • Click Create contract to create a draft contract directly in Atlan based on asset metadata.
    • Click Import contract to use Atlan CLI to import an existing contract from your local environment to Atlan. You will first need to install and connect Atlan CLI and then push the contract to Atlan. Refer to our developer documentation to complete the steps.
  6. (Optional) Click the Edit button to edit the contract.

Congrats on adding a data contract in Atlan! 🎉

View a data contract​

To view a data contract:

  1. From the left menu of any screen in Atlan, click Assets.
  2. From the Assets page, select an asset to open the asset sidebar.
  3. From the left Overview sidebar, click View contract to navigate to the Contract tab in the asset profile.
  4. (Optional) In the Contract tab, you can view the contract specifications for your asset in a YAML format. You can also:
    • Click the Document icon to open a read-only, simplified view of your contract.
    • Next to Published version, click the version dropdown to view the latest version of the contract. Select an older version and then click Compare with published version to compare them side by side.
    • Click the Edit button to edit the contract.
    • Click the clipboard icon to copy the YAML code.
    • Under Timeline, view a timeline for the evolution of your contract.
    • Under Summary, view details of who last updated your contract and when.