How can we retrieve Connected Applications and its scopes

Describe your question in as much detail as possible:

How Can we retrieve connected apps/ Oauth Apps in gitlab. What is rest API endpoint for this, Also How can we return users and its sessions for these connected apps

What are you seeing, and how does it differ from what you expect to see?

Not able to find API for connected Apps

Consider including screenshots, error messages, and/or other helpful visuals

What version are you on? and are you using self-managed or

What troubleshooting steps have you already taken? Can you link to any docs or other resources so we know where you have been?
Gone through API DOC

Hi @c.gaikwwad, welcome to the forums :tada:

Please provide more information about what apps you’re trying to connect and what endpoints you’re looking for so we can help. Details about the API and endpoints are in our documentation on using the Applications API - you might find that helpful.

Hi @sugaroverflow

I am using /applications API endpoint.
Getting 403 forbidden for this API, I can see in API doc - Only administrator users can use the Applications API.

How can check if user is admin user or how can we update user as admin user.

I have few questions around applications API -

  1. Does Get /applications API returns all applications and its scopes.
  2. How can we retrieve users who authenticated using these applications. - As in when we login using any specific user and traverse to Applications tab we can se list of applications using which user has logged in, how can we get this data using API.

@sugaroverflow any suggestions?

Sorry for the delay in response @c.gaikwwad :sweat_smile: this is an interesting problem! I looked around the Applications API and the Users API as well and I can’t seem to find a direct way to get all of the applications the user has authenticated.

Have you had any luck with this?

No luck to find apps user has authenticated.
Also /applications doesn’t works for me.( getting 403 forbidden)
Can you provide me the sample response that /applications endpoint provides?