A basic implementation of our MediatorHandler Interface which is mainly used to establish mediation and get new messages using the mediation and pickup didcomm v2 protocols

Hierarchy

  • BasicMediatorHandler

Implements

Constructors

Properties

mediator?: Mediator

Optional instance of the mediator so that if the mediation was already established and recorded we don't need to mediate again with the same mediator

mediatorDID: DID
mercury: Domain.Mercury

Methods

  • Asyncronously pickup unread messages from the mediator if new messages are found, because the messages from in form of attachments inside the pickup response we need to parse those and return the user a list of messages it can read and decode, this is done inside the pickup runner.

    Parameters

    • limit: number

    Returns Promise<{
        attachmentId: string;
        message: Message;
    }[]>

    Async