novuhq / novu

Open-Source Notification Platform. Embeddable Notification Center, E-mail, Push and Slack Integrations.
https://novu.co
Other
34.76k stars 3.56k forks source link

πŸš€ Feature: Retrieve API keys programatically for given organisation #6670

Open akshay-panchakshari opened 2 weeks ago

akshay-panchakshari commented 2 weeks ago

πŸ”– Feature description

Need API to programatically fetch API keys for given organisation.

Currently Novu provides https://api.novu.co/v1/environments/api-keys that requires API key as Authorization header but returns same API key as response which is not useful.

🎀 Why is this feature needed ?

We are working on feature where we need multiple organisations to be created and managed. We have multiple applications that are going to subscribe to our novu service in order receive customised notifications. So we will be creating an organisation for every application programatically and store the API key in out Database (Encrypted).

✌️ How do you aim to achieve this?

We are expecting something like below which would help to fetch the API key on demand

https://api.novu.co/v1/environments/{organisationId}/api-keys

πŸ”„οΈ Additional Information

I checked related issue https://github.com/novuhq/novu/issues/5556 but could not find any solutions

πŸ‘€ Have you spent some time to check if this feature request has been raised before?

🏒 Have you read the Code of Conduct?

Are you willing to submit PR?

None

linear[bot] commented 2 weeks ago

NV-4470 πŸš€ Feature: Retrieve API keys programatically for given organisation

aarifkhan7 commented 1 day ago

Hey @akshay-panchakshari

I'm a beginner interested in contributing to open source, and this issue seems like a good starting point for me. Could you please assign it to me?

Thanks!

wh1337 commented 6 hours ago

@akshay-panchakshari how would you propose this route be protected?

I suspect you would need some type of skeleton key-style api token but I personally don't see how this would work for both the cloud and the self-hosted versions.

On the other hand, you might be able to look over this file and see if you can replicate it with a custom script you guys run in your org.