@yoshteq/ti365-ts-sdk
    Preparing search index...

    Class KiMClient

    The main client class for interacting with the KIM (Kommunikation im Medizinwesen) service.

    Provides methods for sending, receiving, and managing KIM mails, as well as handling account state, certificate management, and integration with the underlying card and session.

    Index

    Properties

    pop3Client: Pop3Client
    accountDetails?: KimAccountState
    listener?: KiMClientListener

    Accessors

    • get isActive(): boolean

      Returns boolean

    Methods

    • Resynchronizes the account state from the server and updates local settings.

      This method fetches the account details and VZD entry, updates the local settings if necessary, and triggers a state change notification.

      Returns Promise<void>

    • Retrieves the email address associated with the KIM account.

      Returns string

      The email address configured for the KIM account

    • Fetches new KIM mails from the server and processes them.

      This method connects to the POP3 server, retrieves the list of UIDs, filters out already stored mails, and processes the new ones.

      Parameters

      Returns Promise<KimMailFetchResponse>

      A response containing the processed mails and any errors that occurred

    • Searches for VZD entries matching a given query.

      This method performs an LDAP search for VZD entries containing the specified query.

      Parameters

      • query: string

        The search query string

      • limit: number = 20

        Optional maximum number of entries to return (default: 20)

      Returns Promise<VzdEntry[]>

      An array of VZD entries matching the search query

    • Lists all stored mail information.

      This method fetches all mail information from the storage and returns an array of KimMailInfo objects.

      Returns Promise<KimMailInfo[]>

      An array of KimMailInfo objects representing all stored mail information

    • Retrieves the content of a stored KIM mail.

      This method fetches the mail content from the storage and returns a KimMail object.

      Parameters

      • id: string

        The unique identifier of the mail to retrieve

      Returns Promise<KimMail>

      A KimMail object containing the mail content

    • Retrieves the content of an attachment from a stored KIM mail.

      This method fetches the attachment content from the storage and returns an ArrayBuffer containing the attachment data.

      Parameters

      • mailStorageId: string

        The unique identifier of the mail containing the attachment

      • attachmentStorageId: string

        The unique identifier of the attachment to retrieve

      Returns Promise<ArrayBuffer>

      An ArrayBuffer containing the attachment data

    • Deletes a stored KIM mail.

      This method removes the specified mail from the storage.

      Parameters

      • mailStorageId: string

        The unique identifier of the mail to delete

      Returns Promise<void>

    • Returns the name that is normally set as plaintext sender of an Kim Mail.

      Returns string

    • Sends a new Kim Mail Attention the From header of the mail will be set automatically. If a From header is already present the display name of the sender will be reused, when the new header is set.

      Parameters

      • mail: Mail

        The mail to be send.

      • Optionaloptions: Partial<SendMailOptions>

        Detailed options how they mail wil bee send.

      Returns Promise<void>

    • Checks if the provided password matches the current KIM account password.

      Parameters

      • password: string

        The password to check

      Returns boolean

      True if the password matches, false otherwise

    • Updates the password for the KIM account.

      This method updates the password in the account manager and storage.

      Parameters

      • newPassword: string

        The new password to set

      Returns Promise<void>

    • Deregisters the KIM account from the server.

      This method removes the account from the server and updates local settings.

      Returns Promise<void>

    • Sets an out-of-office notice for the KIM account.

      This method updates the out-of-office notice in the account manager.

      Parameters

      • outOfOfficeNotice: OutOfOfficeNotification

        The out-of-office notice to set

      Returns Promise<void>

    • Retrieves the current out-of-office notice for the KIM account.

      This method fetches the out-of-office notice from the account manager.

      Returns Promise<undefined | OutOfOfficeNotification>

      The current out-of-office notice, or undefined if none is set

    • Creates a transfer password for the KIM account.

      This method generates a transfer password for the account.

      Returns Promise<undefined | string>

      The transfer password, or undefined if none is set

    • Sets the acceptance of KAS messages for the KIM account.

      This method updates the account settings to accept or reject KAS messages.

      Parameters

      • accept: boolean

        True to accept KAS messages, false to reject them

      Returns Promise<void>

    • Reactivates the KIM account.

      This method revokes the deregistration of the account and updates the local settings.

      Returns Promise<void>