Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API to list credentials #4854

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

johncant
Copy link

@johncant johncant commented Dec 7, 2022

Hi,

I'm hoping to add a GET /credentials endpoint to the public API. My use case for this is populating a dropdown box in a 3rd party app that needs to create workflows that use credentials. I don't see any advantage in returning data via the public API that outweighs any security considerations, so this isn't returned. nodesAccess also isn't returned.

Link to feature request: https://community.n8n.io/t/n8n-api-add-functions-for-credentials/18522 . Luckily I had some free time, so I started implementing it.

Please can you take a look at my first attempt and let me know what you think?

It isn't fully ready and shouldn't yet be merged - specifically, all credentials are returned, regardless of whether the user is an owner or member. It's ready.

Thanks a lot,

John

  - This is a first attempt
  - All credentials are listed, when they should be filtered
  - Need to add an extra assertionto make sure no extra properties are
    returned
@CLAassistant
Copy link

CLAassistant commented Dec 7, 2022

CLA assistant check
All committers have signed the CLA.

@n8n-assistant n8n-assistant bot added community Authored by a community member core Enhancement outside /nodes-base and /editor-ui labels Dec 7, 2022
@johncant
Copy link
Author

This PR is now working for members and is ready to be merged.

@johncant johncant marked this pull request as ready for review December 26, 2022 21:08
@johncant
Copy link
Author

I notice the Enterprise Edition supports sharing of credentials between users. I also notice the Public API doesn't have any references to the EE at all, so I haven't supported shared credentials via EECredentialsService.

@johncant johncant changed the title [DNM] API to list credentials API to list credentials Dec 26, 2022
@johncant
Copy link
Author

johncant commented Jun 6, 2023

Hi - please can someone from n8n take a look at this PR?

@Joffcom
Copy link
Member

Joffcom commented Jul 31, 2023

Adding the internal ticket id for the review... N8N-6544

@Joffcom Joffcom added the in linear Issue or PR has been created in Linear for internal review label Jul 31, 2023
@netroy
Copy link
Member

netroy commented Jun 20, 2024

@johncant Sorry for such a long delay. Do you still need this endpoint?

@johncant
Copy link
Author

Yes please!

@johncant
Copy link
Author

Given that it's taken a year and a half for anyone to even look at this pull request, I hope you understand if I don't take the time to update it. I cannot be sure that this is a good use of my time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community Authored by a community member core Enhancement outside /nodes-base and /editor-ui in linear Issue or PR has been created in Linear for internal review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants