signify-ts
    Preparing search index...

    Class SignifyClient

    An in-memory key manager that can connect to a KERIA Agent and use it to receive messages and act as a proxy for multi-signature operations and delegation operations.

    Index

    Constructors

    • SignifyClient constructor

      Parameters

      • url: string

        KERIA admin interface URL

      • bran: string

        Base64 21 char string that is used as base material for seed of the client AID

      • tier: Tier = Tier.low

        Security tier for generating keys of the client AID (high | mewdium | low)

      • bootUrl: string = DEFAULT_BOOT_URL

        KERIA boot interface URL

      • externalModules: ExternalModule[] = []

        list of external modules to load

      Returns SignifyClient

    Properties

    agent: null | Agent
    authn: null | Authenticater
    bootUrl: string
    bran: string
    controller: Controller
    exteralModules: ExternalModule[]
    manager: null | IdentifierManagerFactory
    pidx: number
    tier: Tier
    url: string

    Accessors

    Methods

    • Approve the delegation of the client AID to the KERIA agent

      Returns Promise<Response>

      A promise to the result of the approval

    • Boot a KERIA agent

      Returns Promise<Response>

      A promise to the result of the boot

    • Create a Signed Request to fetch a resource from an external URL with headers signed by an AID

      Parameters

      • aidName: string

        Name or alias of the AID to be used for signing

      • url: string

        URL of the requested resource

      • req: RequestInit

        Request options should include: - method: HTTP method - data Data to be sent in the body of the resource. If the data is a CESR JSON string then you should also set contentType to 'application/json+cesr' If the data is a FormData object then you should not set the contentType and the browser will set it to 'multipart/form-data' If the data is an object then you should use JSON.stringify to convert it to a string and set the contentType to 'application/json' - contentType Content type of the request.

      Returns Promise<Request>

      A promise to the created Request

    • Delete a saved passcode from KERIA agent

      Returns Promise<Response>

      A promise to the result of the deletion

    • Fetch a resource from the KERIA agent

      Parameters

      • path: string

        Path to the resource

      • method: string

        HTTP method

      • data: any

        Data to be sent in the body of the resource

      • OptionalextraHeaders: Headers

        Optional extra headers to be sent with the request

      Returns Promise<Response>

      A promise to the result of the fetch

    • Rotate the client AID

      Parameters

      • nbran: string

        Base64 21 char string that is used as base material for the new seed

      • aids: string[]

        List of managed AIDs to be rotated

      Returns Promise<Response>

      A promise to the result of the rotation

    • Save old client passcode in KERIA agent

      Parameters

      • passcode: string

        Passcode to be saved

      Returns Promise<Response>

      A promise to the result of the save

    • Get state of the agent and the client

      Returns Promise<State>

      A promise to the state