lightning icon indicating copy to clipboard operation
lightning copied to clipboard

Streamline Credentials & Adaptors

Open elias-ba opened this issue 1 year ago • 2 comments

There are few difficulties with how we get credentials and / or adaptors into Lightning. When there's a new adaptor that is built and released in Github / NPM, Lightning doesn't automatically fetch it's icon and json schema for the associated credential.

This issue is a canvas for scoping the work in that area. The most urgent thing we wanna achieve is:

  • Be able to automatically fetch adaptors icons and json schemas instead of relying on mix tasks that can only be run during build time.
  • Be able to manage (whitelist / blacklist) adaptors from the UI instead of hardcoding it
  • Detect credential type (OAuth / Non OAuth) from it's JSON Schema instead of hardcoding it (avoid things like ths
    schemas_options
    |> Enum.concat([{"Raw JSON", "raw", nil, nil}])
    # TODO: Gracefully determine which adaptors define custom credential types
    # and which adaptors use OAuth2 credential types.
    |> List.delete({"Googlesheets", "googlesheets", nil, nil})

elias-ba avatar Jan 27 '25 08:01 elias-ba

Hey @elias-ba saw this issue by accident. Couple of things!

Oh the Oauth side I'm quite interested in how adaptors should be handling this, particularly in terms of schema, and whether we should be doing anything to refresh credentials. Also whether we should be adding more CLI support (outh is awful for local dev and I'm sure we ca fix it)

On the adaptor list side I have a couple of issue about this:

  • https://github.com/OpenFn/lightning/issues/2209
  • I'd love for any solution to include https://github.com/OpenFn/lightning/issues/2208
  • https://github.com/OpenFn/lightning/issues/2844 is probably bigger than this issue but i'm keen to be talking about it more

josephjclark avatar Feb 04 '25 11:02 josephjclark

Please have a look at this issue when working on this

elias-ba avatar Apr 29 '25 12:04 elias-ba

@elias-ba , is this handled by Stu's #2209 ? Please close and/or update the issue

taylordowns2000 avatar Jun 16 '25 09:06 taylordowns2000

Yes @taylordowns2000 I think #2209 will handle this. We can close this one

elias-ba avatar Jun 26 '25 10:06 elias-ba