Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Copilot Lvl 3
Message 1 of 2

GraphQL audit queries return partial data

Solved! Go to Solution.

Hello,

 

I'm trying to use GraphQL API to monitor audit logs in my organization.

For most of the queries it works great, but there are some actions that appear in the organization's audit log page and are not retreivied via GraphQL API.

 

For example, all protected_branch and hook related actions can be seen via the audit log organization page, but retreive no results when searching for them using the GraphQL API.

They return nothing when using a query:"action:protected_branch" or when simply trying to retreive all entries without any filter whatsoever.

 

Is there a list of specific audit entries that are not accessible via GraphQL?
Is there a plan of supporting them?

 

Thanks

1 Reply
Highlighted
Solution
Copilot Lvl 3
Message 2 of 2

Re: GraphQL audit queries return partial data

For anyone that is interested, I am attaching the answer from a Github support:

 

As you've found, the audit log search query action:protected_branch is not yet supported by our GraphQL API. The GraphQL AuditEntry interface reference lists the currently supported audit log entry types.

Although this search query is likely to be supported by our GraphQL API at some point, I don't have firm details at this time. If it's added, there'll be an announcement in our developer blog, so it's worth keeping an eye on that.

 

 

After specifiying that this is an important functionality, I also received the following reply:

 

I agree - this functionality would be extremely useful. As such, I've opened an internal feature request to add support for all audit log search queries to our GraphQL API.

Let me know if I can be of further help!