← Code-Übersicht

WetellSourcePort.php

Pfad: src/Domain/Rechnung/WetellSourcePort.php

Ext: php

Größe: 864 Bytes

Geändert: 2026-07-16T18:16:36+02:00

Frühere Version vom 2026-07-16T18:16:36+02:00 · zur aktuellen Fassung

<?php

declare (strict_types=1);
namespace Demo\Domain\Rechnung;

/**
 * Port: Zugriff auf das externe Portal fuer Quellbelege.
 */
interface WetellSourcePort
{
    /**
     * Loggt in der Quelle ein.
     *
     * @param string $username Benutzername.
     * @param string $password Passwort.
     */
    public function login(string $username, string $password): \Demo\Domain\Rechnung\WetellSessionHandle;
    /**
     * Liefert alle aktuell sichtbaren Rechnungsobjekte.
     *
     * @return list<SourceInvoice> Die erkannten Rechnungen.
     */
    public function discoverInvoices(): array;
    /**
     * Laedt das PDF und gibt einen Pfad zur Temp-Datei mit Binärinhalt zurueck.
     *
     * @param string $downloadUrl Download-Link.
     * @return string Temporärer PDF-Pfad.
     */
    public function downloadInvoicePdf(string $downloadUrl): string;
}