Skip to content

HttpServerCapabilities

Defined in: src/client/capabilities.ts:27

HTTP server capability discovery.

Mirrors Python’s http_capabilities(): probes OPTIONS {prefix}/health and reads three response headers:

  • VGI-Max-Request-Bytes — server-enforced inline request cap
  • VGI-Upload-URL-Support — “true” when the server vends upload URLs
  • VGI-Max-Upload-Bytes — cap on out-of-band upload size
  • VGI-Max-Response-Bytes — server-side response cap
  • VGI-Accept-Max-Response-Bytes-Support — negotiated client cap support

Honours Cache-Control: max-age=N for refresh scheduling.

acceptMaxResponseBytesSupport: boolean;

Defined in: src/client/capabilities.ts:37

Whether the server honors VGI-Accept-Max-Response-Bytes.


cacheExpiresAt: number | null;

Defined in: src/client/capabilities.ts:39

Monotonic-time-ish epoch (ms) at which this snapshot should be re-probed.


maxRequestBytes: number | null;

Defined in: src/client/capabilities.ts:29

Server’s advertised max inline request body size (bytes).


maxResponseBytes: number | null;

Defined in: src/client/capabilities.ts:35

Server/hosting maximum response bytes, when advertised.


maxUploadBytes: number | null;

Defined in: src/client/capabilities.ts:33

Cap on the size of an externalized upload (bytes).


uploadUrlSupport: boolean;

Defined in: src/client/capabilities.ts:31

Whether the server vends upload URLs via __upload_url__/init.