Skip to main content
Question

How to fetch Rule and Catalog item metadata from a monitoring project using Graphql API ?


Can we fetch Rule and Catalog item metadata from a monitoring project using Graphql API ? If yes, can you share the Graphql query ? I could not find it on ONE API Documentation

Did this topic help you find an answer to your question?

2 replies

anna.spakova
Ataccamer
Forum|alt.badge.img+3

Hi,

so if you are looking for the graphQL API, you can start with something like this:

query q{
  monitoringProjects(versionSelector: {draftVersion: true}){
    edges{
      node{
        gid
        draftVersion{
          name ## project name
          configuration{
            draftVersion{
              items{ ## catalog item
                edges{
                  node{
                    gid
                    draftVersion{
                      target{  
                        gid
                        draftVersion{
                          name  ## name of the catalog items
                        }
                      }
                      dqChecks{ ## DQ rule
                        edges{
                          node{
                            draftVersion{
                              target{
                                gid
                                draftVersion{
                                  name
                                }
                              }
                              mappings{ ## mapping between attribute of table and rule
                                edges{
                                  node{
                                    draftVersion{
                                      ruleAttribute{ ##rule attribute
                                        gid
                                        draftVersion{
                                          name
                                        }
                                      }
                                      catalogItemAttribute{ ## catalog item attribute
                                        gid
                                        draftVersion{
                                          name
                                        }
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}

This will give you all projects with all their configurations (even past ones), all catalog items and the applied DQ checks. You can play with it using our Playground to add more properties, see more: https://community.ataccama.com/data%2Dquality%2Dcatalog%2D94/guide%2Dhow%2Dto%2Drun%2Dgraphql%2Drequests%2Dpart%2Di%2D1543 Or using the GraphQL plugin in your browser to discover the queries right away in the application. https://chromewebstore.google.com/detail/graphql-network-inspector/ndlbedplllcgconngcnfmkadhokfaaln

All the above can be also extracted in IDE using the ONE Metadata Reader.

Please let me know if there is anything else I can help you with.

Kind regards,

Anna


Lisa Kovalskaia
Ataccamer
Forum|alt.badge.img+3

@Apurva Kapoor hi! Assuming this question below is related to the same use case, please also have a look at the example plan in my response:

 Would you rather go for the API-based approach or use the ONE Metadata reader steps? Would love to hear your feedback on which option you prefer and why!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings