Server base URL up to but excluding the version segment, e.g.
https://example.com/bcf. Run user input through
normalizeApiBaseUrl first to tolerate trailing slashes and
pasted version suffixes.
OptionalerrorName used in the fallback "{errorLabel} request failed (HTTP …) at …" message when a non-2xx response carries no server-supplied detail. Defaults to 'OpenCDE'; a concrete client (BCF, Documents, ...) names itself so the message reads like the rest of that client's errors.
OptionalerrorPrefix of thrown errors' name (see FoundationApiError); defaults to 'Foundation'.
OptionalfetchInjectable fetch, for tests and non-browser hosts.
OptionalgetSupplies the Bearer token per request; omit for anonymous servers.
OptionalversionOpenCDE API version segment; defaults to '1.1' (the Foundation API's own version).
@ifc-lite/opencde-foundation — client for the buildingSMART OpenCDE Foundation API (https://github.com/buildingSMART/foundation-API): the services and conventions every OpenCDE API (BCF, Documents, ...) shares —
/foundation/versionsdiscovery, OAuth2/authdiscovery and token flows, and/current-user.@ifc-lite/bcf-apiand@ifc-lite/documents-apiboth build their clients on top of this package.