@sebastianwessel/quickjs v3.1.0
@sebastianwessel/quickjs / GetFetchAdapterOptions
Type Alias: GetFetchAdapterOptions
GetFetchAdapterOptions =
object
Defined in: adapter/fetch.ts:15
Options for creating the default fetch adapter
Properties
allowedCorsOrigins?
optionalallowedCorsOrigins?:string[]
Defined in: adapter/fetch.ts:47
List of allowed CORS origins
Default
['*']allowedHosts?
optionalallowedHosts?:string[]
Defined in: adapter/fetch.ts:23
List of allowed hosts. If set, only these hosts are allowed to call
allowedProtocols?
optionalallowedProtocols?:string[]
Defined in: adapter/fetch.ts:27
List of allowed protocols. If set, only these protocols are allowed to call
corsCheck?
optionalcorsCheck?:boolean
Defined in: adapter/fetch.ts:42
Flag to enable CORS policy check
Default
falsedisallowedHosts?
optionaldisallowedHosts?:string[]
Defined in: adapter/fetch.ts:32
List of disallowed hosts. If set, these hosts are not allowed to call
Default
['localhost', '127.0.0.1']fs?
optionalfs?:IFs
Defined in: adapter/fetch.ts:19
The virtual file system of the sandbox (excludes node_modules)
rateLimitDuration?
optionalrateLimitDuration?:number
Defined in: adapter/fetch.ts:57
Duration in seconds for the rate limit
Default
1rateLimitPoints?
optionalrateLimitPoints?:number
Defined in: adapter/fetch.ts:52
Number of requests allowed in the specified duration
Default
10timeout?
optionaltimeout?:number
Defined in: adapter/fetch.ts:37
Timeout for fetch requests in milliseconds
Default
5000