GraphQL Get Repository Commits

I’m trying to query the commit history of a project’s repository. Is this possible? Here is the query I have so far:

{
group(fullPath: “my/test/path”) {
projects(search: “myprojectname”) {
nodes {
name
repository {
rootRef
tree(recursive:true) {
trees(first: 100) {
pageInfo {
endCursor
startCursor
}
nodes {
name
type
}
}
}
}
}
}
}
}

1 Like

Hi Josh,
I’m looking for the same. Did you ever find a way to get commits using GraphQL, or did you have to resort to using the REST API?

BR, Espen

Im also looking for a solution to get a project commits through the Graphql API. If you want something specific the Rest Api seem to be much more viable.

1 Like