@maschinenlesbar.org/bundesrat-cli
    Preparing search index...

    Class RequestEngine

    Index
    • GET a feed path and parse the XML reply. The Bundesrat feeds require the view=renderXml render parameter; without it the server returns its HTML shell, which we detect and reject with a helpful BundesratParseError.

      NOTE: the response Content-Type is intentionally ignored. The Government Site Builder CMS is inconsistent about it (feeds have been seen as text/plain, application/xml, text/html), so we sniff the body — an <!doctype html> / <html> prefix is the HTML-shell guard — rather than trust the header. Don't "harden" this by validating Content-Type; it would reject valid feeds.

      Parameters

      Returns Promise<XmlValue>

    • Perform a GET with Accept negotiation and transient-error retries. Redirects are NOT followed — a 3xx surfaces as an error (the canonical host answers directly).

      Parameters

      • path: string
      • Optionalquery: QueryParams
      • accept: string = "application/xml"

      Returns Promise<RawResponse>