Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 18 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,28 @@
# mcp-server-datahub

A [Model Context Protocol](https://modelcontextprotocol.io/) server implementation for [DataHub](https://datahubproject.io/).
This enables AI agents to query DataHub for metadata and context about your data ecosystem.
A comprehensive [Model Context Protocol](https://modelcontextprotocol.io/) server implementation for [DataHub](https://datahubproject.io/).
This enables AI agents to both query and manage DataHub metadata, providing full read and write capabilities for your data ecosystem.

Supports both DataHub Core and DataHub Cloud.

## Features

- Searching across all entity types and using arbitrary filters
- Fetching metadata for any entity
- Traversing the lineage graph, both upstream and downstream
- Listing SQL queries associated with a dataset
### Read Operations
- Search across all entity types with advanced filtering
- Fetch detailed metadata for any entity
- Traverse the lineage graph, both upstream and downstream
- List SQL queries associated with datasets

### Write Operations
- Update entity and field descriptions
- Create and manage tags
- Add and remove tags from entities and fields
- Batch tag operations for multiple entities
- Create and manage business domains
- Assign entities to domains
- Create and manage glossary terms
- Link glossary terms to entities and fields
- Add owners to entities

## Demo

Expand Down
69 changes: 69 additions & 0 deletions src/mcp_server_datahub/gql/mutations.gql
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Mutation for creating tags
mutation createTag($input: CreateTagInput!) {
createTag(input: $input)
}

# Mutation for updating entity descriptions
mutation updateDescription($input: DescriptionUpdateInput!) {
updateDescription(input: $input)
}

# Mutation for adding tags to an entity
mutation addTags($input: AddTagsInput!) {
addTags(input: $input)
}

# Mutation for removing a tag from an entity
mutation removeTag($input: TagAssociationInput!) {
removeTag(input: $input)
}

# Mutation for batch adding tags to multiple entities
mutation batchAddTags($input: BatchAddTagsInput!) {
batchAddTags(input: $input)
}

# Mutation for batch removing tags from multiple entities
mutation batchRemoveTags($input: BatchRemoveTagsInput!) {
batchRemoveTags(input: $input)
}

# Mutation for setting the domain of an entity
mutation setDomain($entityUrn: String!, $domainUrn: String!) {
setDomain(entityUrn: $entityUrn, domainUrn: $domainUrn)
}

# Mutation for unsetting the domain of an entity
mutation unsetDomain($entityUrn: String!) {
unsetDomain(entityUrn: $entityUrn)
}

# Mutation for adding owners to an entity
mutation addOwners($input: AddOwnersInput!) {
addOwners(input: $input)
}

# Mutation for removing owners from an entity - not available in DataHub API
# mutation removeOwners($input: RemoveOwnersInput!) {
# removeOwners(input: $input)
# }

# Mutation for adding glossary terms to an entity
mutation addTerms($input: AddTermsInput!) {
addTerms(input: $input)
}

# Mutation for removing glossary terms from an entity - using removeTerm for single term removal
mutation removeTerm($input: TermAssociationInput!) {
removeTerm(input: $input)
}

# Mutation for creating a new domain
mutation createDomain($input: CreateDomainInput!) {
createDomain(input: $input)
}

# Mutation for creating a new glossary term
mutation createGlossaryTerm($input: CreateGlossaryEntityInput!) {
createGlossaryTerm(input: $input)
}
Loading