Skip to content

Loosen dependency on Express for openid4vc #2763

Description

@berendsliedrecht

Right now, if I understand it correctly, we have such a tight dependency on Express that we do not allow any other web application framework to be used for the required openid4vc endpoints. (if this is incorrect please close this issue :)).

My idea was to replace this strict app: Express type and just accept an object with some basic properties where credo could add some of the required endpoints. We would have to go through all the uses of the .app in the framework, but it does not seem like a lot. For instance, this whole function would need to accept a generic web framework to set all the configuration on.

We should, in the node or openid4vc package maybe?, supply an express adapter/app which will make it work exactly as how it worked before.

Maybe an interface like:

export type WebApplication = {
  setPostEndpoint(path: string, cb: (request: Request, response: Response) => unknown): void
  setGetEndpoint(...): ...
  // etc.
}

Discussion is welcome :).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions