List projects API call fails with missing api.management.read permissions

Hello, I wonder if anyone is able to list projects using API call. Docs says it’s possible but my cURL taken directly from the docs fails with:

You have insufficient permissions for this operation. Missing scopes: api.management.read. Check that you have the correct role in your organization, and if you’re using a restricted API key, that it has the necessary scopes.

I’m the Org owner, my API key has All permissions, but I tried several keys - if I try to restrict the key, it doesn’t have even the option for api.management.read. I tried project keys as well, I tried using python as well - all the time the same 403 error. Anyone was able to make such a call working? I would like to use this API in my pipeline to create new projects eventually if it works. Thank you!

2 Likes

You need to create an Organization API Key, the page is here: https://platform.openai.com/organization/admin-keys

I had a similar problem here:

I had an extra forward slash on the end of the URL that caused a Forbidden error.