Skip to content

@pumpkin-plugins/bedrock-addon-manager API / web/response / planResponse

Function: planResponse() ​

planResponse(request, lookup): ResponsePlan

Defined in: packages/bedrock-addon-manager/src/web/response.ts:49

Decides what to send for a request. Only GET and HEAD for /packs/<name> succeed, and only for a name the lookup knows, so no request can reach any other file.

Parameters ​

request ​

HttpRequest | undefined

The parsed request, or undefined when it was malformed.

lookup ​

PackLookup

Opens a pack by file name.

Returns ​

ResponsePlan

The response head and, when there is one, the pack to stream.

Pumpkin Plugins documentation