@cloudflare/workers-types 4.20230511.0 → 4.20230518.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/2021-11-03/index.d.ts +39 -1
- package/2021-11-03/index.ts +32 -1
- package/2022-01-31/index.d.ts +39 -1
- package/2022-01-31/index.ts +32 -1
- package/2022-03-21/index.d.ts +39 -1
- package/2022-03-21/index.ts +32 -1
- package/2022-08-04/index.d.ts +39 -1
- package/2022-08-04/index.ts +32 -1
- package/2022-10-31/index.d.ts +41 -3
- package/2022-10-31/index.ts +34 -3
- package/2022-11-30/index.d.ts +41 -3
- package/2022-11-30/index.ts +34 -3
- package/experimental/index.d.ts +41 -5
- package/experimental/index.ts +34 -5
- package/index.d.ts +39 -1
- package/index.ts +32 -1
- package/oldest/index.d.ts +39 -1
- package/oldest/index.ts +32 -1
- package/package.json +1 -1
package/2021-11-03/index.d.ts
CHANGED
|
@@ -462,6 +462,7 @@ declare interface DurableObjectStorage {
|
|
|
462
462
|
): Promise<void>;
|
|
463
463
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
464
464
|
sync(): Promise<void>;
|
|
465
|
+
transactionSync<T>(closure: () => T): T;
|
|
465
466
|
}
|
|
466
467
|
declare interface DurableObjectListOptions {
|
|
467
468
|
start?: string;
|
|
@@ -3025,12 +3026,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3025
3026
|
// Key Identifier of the JWK
|
|
3026
3027
|
readonly kid: string;
|
|
3027
3028
|
}
|
|
3029
|
+
declare module "cloudflare:sockets" {
|
|
3030
|
+
function _connect(
|
|
3031
|
+
address: string | SocketAddress,
|
|
3032
|
+
options?: SocketOptions
|
|
3033
|
+
): Socket;
|
|
3034
|
+
export { _connect as connect };
|
|
3035
|
+
}
|
|
3028
3036
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3037
|
+
declare interface DynamicDispatchLimits {
|
|
3038
|
+
/**
|
|
3039
|
+
* Limit CPU time in milliseconds.
|
|
3040
|
+
*/
|
|
3041
|
+
cpuMs?: number;
|
|
3042
|
+
/**
|
|
3043
|
+
* Limit number of subrequests.
|
|
3044
|
+
*/
|
|
3045
|
+
subRequests?: number;
|
|
3046
|
+
}
|
|
3047
|
+
declare interface DynamicDispatchOptions {
|
|
3048
|
+
/**
|
|
3049
|
+
* Limit resources of invoked Worker script.
|
|
3050
|
+
*/
|
|
3051
|
+
limits?: DynamicDispatchLimits;
|
|
3052
|
+
/**
|
|
3053
|
+
* Arguments for outbound Worker script, if configured.
|
|
3054
|
+
*/
|
|
3055
|
+
outbound?: {
|
|
3056
|
+
[key: string]: any;
|
|
3057
|
+
};
|
|
3058
|
+
}
|
|
3029
3059
|
declare interface DispatchNamespace {
|
|
3030
3060
|
/**
|
|
3031
3061
|
* @param name Name of the Worker script.
|
|
3062
|
+
* @param args Arguments to Worker script.
|
|
3063
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3032
3064
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3033
3065
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3034
3066
|
*/
|
|
3035
|
-
get(
|
|
3067
|
+
get(
|
|
3068
|
+
name: string,
|
|
3069
|
+
args?: {
|
|
3070
|
+
[key: string]: any;
|
|
3071
|
+
},
|
|
3072
|
+
options?: DynamicDispatchOptions
|
|
3073
|
+
): Fetcher;
|
|
3036
3074
|
}
|
package/2021-11-03/index.ts
CHANGED
|
@@ -464,6 +464,7 @@ export interface DurableObjectStorage {
|
|
|
464
464
|
): Promise<void>;
|
|
465
465
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
466
466
|
sync(): Promise<void>;
|
|
467
|
+
transactionSync<T>(closure: () => T): T;
|
|
467
468
|
}
|
|
468
469
|
export interface DurableObjectListOptions {
|
|
469
470
|
start?: string;
|
|
@@ -3021,11 +3022,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3021
3022
|
readonly kid: string;
|
|
3022
3023
|
}
|
|
3023
3024
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3025
|
+
export interface DynamicDispatchLimits {
|
|
3026
|
+
/**
|
|
3027
|
+
* Limit CPU time in milliseconds.
|
|
3028
|
+
*/
|
|
3029
|
+
cpuMs?: number;
|
|
3030
|
+
/**
|
|
3031
|
+
* Limit number of subrequests.
|
|
3032
|
+
*/
|
|
3033
|
+
subRequests?: number;
|
|
3034
|
+
}
|
|
3035
|
+
export interface DynamicDispatchOptions {
|
|
3036
|
+
/**
|
|
3037
|
+
* Limit resources of invoked Worker script.
|
|
3038
|
+
*/
|
|
3039
|
+
limits?: DynamicDispatchLimits;
|
|
3040
|
+
/**
|
|
3041
|
+
* Arguments for outbound Worker script, if configured.
|
|
3042
|
+
*/
|
|
3043
|
+
outbound?: {
|
|
3044
|
+
[key: string]: any;
|
|
3045
|
+
};
|
|
3046
|
+
}
|
|
3024
3047
|
export interface DispatchNamespace {
|
|
3025
3048
|
/**
|
|
3026
3049
|
* @param name Name of the Worker script.
|
|
3050
|
+
* @param args Arguments to Worker script.
|
|
3051
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3027
3052
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3028
3053
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3029
3054
|
*/
|
|
3030
|
-
get(
|
|
3055
|
+
get(
|
|
3056
|
+
name: string,
|
|
3057
|
+
args?: {
|
|
3058
|
+
[key: string]: any;
|
|
3059
|
+
},
|
|
3060
|
+
options?: DynamicDispatchOptions
|
|
3061
|
+
): Fetcher;
|
|
3031
3062
|
}
|
package/2022-01-31/index.d.ts
CHANGED
|
@@ -462,6 +462,7 @@ declare interface DurableObjectStorage {
|
|
|
462
462
|
): Promise<void>;
|
|
463
463
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
464
464
|
sync(): Promise<void>;
|
|
465
|
+
transactionSync<T>(closure: () => T): T;
|
|
465
466
|
}
|
|
466
467
|
declare interface DurableObjectListOptions {
|
|
467
468
|
start?: string;
|
|
@@ -3011,12 +3012,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3011
3012
|
// Key Identifier of the JWK
|
|
3012
3013
|
readonly kid: string;
|
|
3013
3014
|
}
|
|
3015
|
+
declare module "cloudflare:sockets" {
|
|
3016
|
+
function _connect(
|
|
3017
|
+
address: string | SocketAddress,
|
|
3018
|
+
options?: SocketOptions
|
|
3019
|
+
): Socket;
|
|
3020
|
+
export { _connect as connect };
|
|
3021
|
+
}
|
|
3014
3022
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3023
|
+
declare interface DynamicDispatchLimits {
|
|
3024
|
+
/**
|
|
3025
|
+
* Limit CPU time in milliseconds.
|
|
3026
|
+
*/
|
|
3027
|
+
cpuMs?: number;
|
|
3028
|
+
/**
|
|
3029
|
+
* Limit number of subrequests.
|
|
3030
|
+
*/
|
|
3031
|
+
subRequests?: number;
|
|
3032
|
+
}
|
|
3033
|
+
declare interface DynamicDispatchOptions {
|
|
3034
|
+
/**
|
|
3035
|
+
* Limit resources of invoked Worker script.
|
|
3036
|
+
*/
|
|
3037
|
+
limits?: DynamicDispatchLimits;
|
|
3038
|
+
/**
|
|
3039
|
+
* Arguments for outbound Worker script, if configured.
|
|
3040
|
+
*/
|
|
3041
|
+
outbound?: {
|
|
3042
|
+
[key: string]: any;
|
|
3043
|
+
};
|
|
3044
|
+
}
|
|
3015
3045
|
declare interface DispatchNamespace {
|
|
3016
3046
|
/**
|
|
3017
3047
|
* @param name Name of the Worker script.
|
|
3048
|
+
* @param args Arguments to Worker script.
|
|
3049
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3018
3050
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3019
3051
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3020
3052
|
*/
|
|
3021
|
-
get(
|
|
3053
|
+
get(
|
|
3054
|
+
name: string,
|
|
3055
|
+
args?: {
|
|
3056
|
+
[key: string]: any;
|
|
3057
|
+
},
|
|
3058
|
+
options?: DynamicDispatchOptions
|
|
3059
|
+
): Fetcher;
|
|
3022
3060
|
}
|
package/2022-01-31/index.ts
CHANGED
|
@@ -464,6 +464,7 @@ export interface DurableObjectStorage {
|
|
|
464
464
|
): Promise<void>;
|
|
465
465
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
466
466
|
sync(): Promise<void>;
|
|
467
|
+
transactionSync<T>(closure: () => T): T;
|
|
467
468
|
}
|
|
468
469
|
export interface DurableObjectListOptions {
|
|
469
470
|
start?: string;
|
|
@@ -3007,11 +3008,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3007
3008
|
readonly kid: string;
|
|
3008
3009
|
}
|
|
3009
3010
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3011
|
+
export interface DynamicDispatchLimits {
|
|
3012
|
+
/**
|
|
3013
|
+
* Limit CPU time in milliseconds.
|
|
3014
|
+
*/
|
|
3015
|
+
cpuMs?: number;
|
|
3016
|
+
/**
|
|
3017
|
+
* Limit number of subrequests.
|
|
3018
|
+
*/
|
|
3019
|
+
subRequests?: number;
|
|
3020
|
+
}
|
|
3021
|
+
export interface DynamicDispatchOptions {
|
|
3022
|
+
/**
|
|
3023
|
+
* Limit resources of invoked Worker script.
|
|
3024
|
+
*/
|
|
3025
|
+
limits?: DynamicDispatchLimits;
|
|
3026
|
+
/**
|
|
3027
|
+
* Arguments for outbound Worker script, if configured.
|
|
3028
|
+
*/
|
|
3029
|
+
outbound?: {
|
|
3030
|
+
[key: string]: any;
|
|
3031
|
+
};
|
|
3032
|
+
}
|
|
3010
3033
|
export interface DispatchNamespace {
|
|
3011
3034
|
/**
|
|
3012
3035
|
* @param name Name of the Worker script.
|
|
3036
|
+
* @param args Arguments to Worker script.
|
|
3037
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3013
3038
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3014
3039
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3015
3040
|
*/
|
|
3016
|
-
get(
|
|
3041
|
+
get(
|
|
3042
|
+
name: string,
|
|
3043
|
+
args?: {
|
|
3044
|
+
[key: string]: any;
|
|
3045
|
+
},
|
|
3046
|
+
options?: DynamicDispatchOptions
|
|
3047
|
+
): Fetcher;
|
|
3017
3048
|
}
|
package/2022-03-21/index.d.ts
CHANGED
|
@@ -468,6 +468,7 @@ declare interface DurableObjectStorage {
|
|
|
468
468
|
): Promise<void>;
|
|
469
469
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
470
470
|
sync(): Promise<void>;
|
|
471
|
+
transactionSync<T>(closure: () => T): T;
|
|
471
472
|
}
|
|
472
473
|
declare interface DurableObjectListOptions {
|
|
473
474
|
start?: string;
|
|
@@ -3017,12 +3018,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3017
3018
|
// Key Identifier of the JWK
|
|
3018
3019
|
readonly kid: string;
|
|
3019
3020
|
}
|
|
3021
|
+
declare module "cloudflare:sockets" {
|
|
3022
|
+
function _connect(
|
|
3023
|
+
address: string | SocketAddress,
|
|
3024
|
+
options?: SocketOptions
|
|
3025
|
+
): Socket;
|
|
3026
|
+
export { _connect as connect };
|
|
3027
|
+
}
|
|
3020
3028
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3029
|
+
declare interface DynamicDispatchLimits {
|
|
3030
|
+
/**
|
|
3031
|
+
* Limit CPU time in milliseconds.
|
|
3032
|
+
*/
|
|
3033
|
+
cpuMs?: number;
|
|
3034
|
+
/**
|
|
3035
|
+
* Limit number of subrequests.
|
|
3036
|
+
*/
|
|
3037
|
+
subRequests?: number;
|
|
3038
|
+
}
|
|
3039
|
+
declare interface DynamicDispatchOptions {
|
|
3040
|
+
/**
|
|
3041
|
+
* Limit resources of invoked Worker script.
|
|
3042
|
+
*/
|
|
3043
|
+
limits?: DynamicDispatchLimits;
|
|
3044
|
+
/**
|
|
3045
|
+
* Arguments for outbound Worker script, if configured.
|
|
3046
|
+
*/
|
|
3047
|
+
outbound?: {
|
|
3048
|
+
[key: string]: any;
|
|
3049
|
+
};
|
|
3050
|
+
}
|
|
3021
3051
|
declare interface DispatchNamespace {
|
|
3022
3052
|
/**
|
|
3023
3053
|
* @param name Name of the Worker script.
|
|
3054
|
+
* @param args Arguments to Worker script.
|
|
3055
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3024
3056
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3025
3057
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3026
3058
|
*/
|
|
3027
|
-
get(
|
|
3059
|
+
get(
|
|
3060
|
+
name: string,
|
|
3061
|
+
args?: {
|
|
3062
|
+
[key: string]: any;
|
|
3063
|
+
},
|
|
3064
|
+
options?: DynamicDispatchOptions
|
|
3065
|
+
): Fetcher;
|
|
3028
3066
|
}
|
package/2022-03-21/index.ts
CHANGED
|
@@ -470,6 +470,7 @@ export interface DurableObjectStorage {
|
|
|
470
470
|
): Promise<void>;
|
|
471
471
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
472
472
|
sync(): Promise<void>;
|
|
473
|
+
transactionSync<T>(closure: () => T): T;
|
|
473
474
|
}
|
|
474
475
|
export interface DurableObjectListOptions {
|
|
475
476
|
start?: string;
|
|
@@ -3013,11 +3014,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3013
3014
|
readonly kid: string;
|
|
3014
3015
|
}
|
|
3015
3016
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3017
|
+
export interface DynamicDispatchLimits {
|
|
3018
|
+
/**
|
|
3019
|
+
* Limit CPU time in milliseconds.
|
|
3020
|
+
*/
|
|
3021
|
+
cpuMs?: number;
|
|
3022
|
+
/**
|
|
3023
|
+
* Limit number of subrequests.
|
|
3024
|
+
*/
|
|
3025
|
+
subRequests?: number;
|
|
3026
|
+
}
|
|
3027
|
+
export interface DynamicDispatchOptions {
|
|
3028
|
+
/**
|
|
3029
|
+
* Limit resources of invoked Worker script.
|
|
3030
|
+
*/
|
|
3031
|
+
limits?: DynamicDispatchLimits;
|
|
3032
|
+
/**
|
|
3033
|
+
* Arguments for outbound Worker script, if configured.
|
|
3034
|
+
*/
|
|
3035
|
+
outbound?: {
|
|
3036
|
+
[key: string]: any;
|
|
3037
|
+
};
|
|
3038
|
+
}
|
|
3016
3039
|
export interface DispatchNamespace {
|
|
3017
3040
|
/**
|
|
3018
3041
|
* @param name Name of the Worker script.
|
|
3042
|
+
* @param args Arguments to Worker script.
|
|
3043
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3019
3044
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3020
3045
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3021
3046
|
*/
|
|
3022
|
-
get(
|
|
3047
|
+
get(
|
|
3048
|
+
name: string,
|
|
3049
|
+
args?: {
|
|
3050
|
+
[key: string]: any;
|
|
3051
|
+
},
|
|
3052
|
+
options?: DynamicDispatchOptions
|
|
3053
|
+
): Fetcher;
|
|
3023
3054
|
}
|
package/2022-08-04/index.d.ts
CHANGED
|
@@ -468,6 +468,7 @@ declare interface DurableObjectStorage {
|
|
|
468
468
|
): Promise<void>;
|
|
469
469
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
470
470
|
sync(): Promise<void>;
|
|
471
|
+
transactionSync<T>(closure: () => T): T;
|
|
471
472
|
}
|
|
472
473
|
declare interface DurableObjectListOptions {
|
|
473
474
|
start?: string;
|
|
@@ -3018,12 +3019,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3018
3019
|
// Key Identifier of the JWK
|
|
3019
3020
|
readonly kid: string;
|
|
3020
3021
|
}
|
|
3022
|
+
declare module "cloudflare:sockets" {
|
|
3023
|
+
function _connect(
|
|
3024
|
+
address: string | SocketAddress,
|
|
3025
|
+
options?: SocketOptions
|
|
3026
|
+
): Socket;
|
|
3027
|
+
export { _connect as connect };
|
|
3028
|
+
}
|
|
3021
3029
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3030
|
+
declare interface DynamicDispatchLimits {
|
|
3031
|
+
/**
|
|
3032
|
+
* Limit CPU time in milliseconds.
|
|
3033
|
+
*/
|
|
3034
|
+
cpuMs?: number;
|
|
3035
|
+
/**
|
|
3036
|
+
* Limit number of subrequests.
|
|
3037
|
+
*/
|
|
3038
|
+
subRequests?: number;
|
|
3039
|
+
}
|
|
3040
|
+
declare interface DynamicDispatchOptions {
|
|
3041
|
+
/**
|
|
3042
|
+
* Limit resources of invoked Worker script.
|
|
3043
|
+
*/
|
|
3044
|
+
limits?: DynamicDispatchLimits;
|
|
3045
|
+
/**
|
|
3046
|
+
* Arguments for outbound Worker script, if configured.
|
|
3047
|
+
*/
|
|
3048
|
+
outbound?: {
|
|
3049
|
+
[key: string]: any;
|
|
3050
|
+
};
|
|
3051
|
+
}
|
|
3022
3052
|
declare interface DispatchNamespace {
|
|
3023
3053
|
/**
|
|
3024
3054
|
* @param name Name of the Worker script.
|
|
3055
|
+
* @param args Arguments to Worker script.
|
|
3056
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3025
3057
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3026
3058
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3027
3059
|
*/
|
|
3028
|
-
get(
|
|
3060
|
+
get(
|
|
3061
|
+
name: string,
|
|
3062
|
+
args?: {
|
|
3063
|
+
[key: string]: any;
|
|
3064
|
+
},
|
|
3065
|
+
options?: DynamicDispatchOptions
|
|
3066
|
+
): Fetcher;
|
|
3029
3067
|
}
|
package/2022-08-04/index.ts
CHANGED
|
@@ -470,6 +470,7 @@ export interface DurableObjectStorage {
|
|
|
470
470
|
): Promise<void>;
|
|
471
471
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
472
472
|
sync(): Promise<void>;
|
|
473
|
+
transactionSync<T>(closure: () => T): T;
|
|
473
474
|
}
|
|
474
475
|
export interface DurableObjectListOptions {
|
|
475
476
|
start?: string;
|
|
@@ -3014,11 +3015,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3014
3015
|
readonly kid: string;
|
|
3015
3016
|
}
|
|
3016
3017
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3018
|
+
export interface DynamicDispatchLimits {
|
|
3019
|
+
/**
|
|
3020
|
+
* Limit CPU time in milliseconds.
|
|
3021
|
+
*/
|
|
3022
|
+
cpuMs?: number;
|
|
3023
|
+
/**
|
|
3024
|
+
* Limit number of subrequests.
|
|
3025
|
+
*/
|
|
3026
|
+
subRequests?: number;
|
|
3027
|
+
}
|
|
3028
|
+
export interface DynamicDispatchOptions {
|
|
3029
|
+
/**
|
|
3030
|
+
* Limit resources of invoked Worker script.
|
|
3031
|
+
*/
|
|
3032
|
+
limits?: DynamicDispatchLimits;
|
|
3033
|
+
/**
|
|
3034
|
+
* Arguments for outbound Worker script, if configured.
|
|
3035
|
+
*/
|
|
3036
|
+
outbound?: {
|
|
3037
|
+
[key: string]: any;
|
|
3038
|
+
};
|
|
3039
|
+
}
|
|
3017
3040
|
export interface DispatchNamespace {
|
|
3018
3041
|
/**
|
|
3019
3042
|
* @param name Name of the Worker script.
|
|
3043
|
+
* @param args Arguments to Worker script.
|
|
3044
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3020
3045
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3021
3046
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3022
3047
|
*/
|
|
3023
|
-
get(
|
|
3048
|
+
get(
|
|
3049
|
+
name: string,
|
|
3050
|
+
args?: {
|
|
3051
|
+
[key: string]: any;
|
|
3052
|
+
},
|
|
3053
|
+
options?: DynamicDispatchOptions
|
|
3054
|
+
): Fetcher;
|
|
3024
3055
|
}
|
package/2022-10-31/index.d.ts
CHANGED
|
@@ -468,6 +468,7 @@ declare interface DurableObjectStorage {
|
|
|
468
468
|
): Promise<void>;
|
|
469
469
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
470
470
|
sync(): Promise<void>;
|
|
471
|
+
transactionSync<T>(closure: () => T): T;
|
|
471
472
|
}
|
|
472
473
|
declare interface DurableObjectListOptions {
|
|
473
474
|
start?: string;
|
|
@@ -1743,10 +1744,10 @@ declare class URLSearchParams {
|
|
|
1743
1744
|
);
|
|
1744
1745
|
get size(): number;
|
|
1745
1746
|
append(name: string, value: string): void;
|
|
1746
|
-
delete(name: string): void;
|
|
1747
|
+
delete(name: string, value?: any): void;
|
|
1747
1748
|
get(name: string): string | null;
|
|
1748
1749
|
getAll(name: string): string[];
|
|
1749
|
-
has(name: string): boolean;
|
|
1750
|
+
has(name: string, value?: any): boolean;
|
|
1750
1751
|
set(name: string, value: string): void;
|
|
1751
1752
|
sort(): void;
|
|
1752
1753
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -3015,12 +3016,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3015
3016
|
// Key Identifier of the JWK
|
|
3016
3017
|
readonly kid: string;
|
|
3017
3018
|
}
|
|
3019
|
+
declare module "cloudflare:sockets" {
|
|
3020
|
+
function _connect(
|
|
3021
|
+
address: string | SocketAddress,
|
|
3022
|
+
options?: SocketOptions
|
|
3023
|
+
): Socket;
|
|
3024
|
+
export { _connect as connect };
|
|
3025
|
+
}
|
|
3018
3026
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3027
|
+
declare interface DynamicDispatchLimits {
|
|
3028
|
+
/**
|
|
3029
|
+
* Limit CPU time in milliseconds.
|
|
3030
|
+
*/
|
|
3031
|
+
cpuMs?: number;
|
|
3032
|
+
/**
|
|
3033
|
+
* Limit number of subrequests.
|
|
3034
|
+
*/
|
|
3035
|
+
subRequests?: number;
|
|
3036
|
+
}
|
|
3037
|
+
declare interface DynamicDispatchOptions {
|
|
3038
|
+
/**
|
|
3039
|
+
* Limit resources of invoked Worker script.
|
|
3040
|
+
*/
|
|
3041
|
+
limits?: DynamicDispatchLimits;
|
|
3042
|
+
/**
|
|
3043
|
+
* Arguments for outbound Worker script, if configured.
|
|
3044
|
+
*/
|
|
3045
|
+
outbound?: {
|
|
3046
|
+
[key: string]: any;
|
|
3047
|
+
};
|
|
3048
|
+
}
|
|
3019
3049
|
declare interface DispatchNamespace {
|
|
3020
3050
|
/**
|
|
3021
3051
|
* @param name Name of the Worker script.
|
|
3052
|
+
* @param args Arguments to Worker script.
|
|
3053
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3022
3054
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3023
3055
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3024
3056
|
*/
|
|
3025
|
-
get(
|
|
3057
|
+
get(
|
|
3058
|
+
name: string,
|
|
3059
|
+
args?: {
|
|
3060
|
+
[key: string]: any;
|
|
3061
|
+
},
|
|
3062
|
+
options?: DynamicDispatchOptions
|
|
3063
|
+
): Fetcher;
|
|
3026
3064
|
}
|
package/2022-10-31/index.ts
CHANGED
|
@@ -470,6 +470,7 @@ export interface DurableObjectStorage {
|
|
|
470
470
|
): Promise<void>;
|
|
471
471
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
472
472
|
sync(): Promise<void>;
|
|
473
|
+
transactionSync<T>(closure: () => T): T;
|
|
473
474
|
}
|
|
474
475
|
export interface DurableObjectListOptions {
|
|
475
476
|
start?: string;
|
|
@@ -1748,10 +1749,10 @@ export declare class URLSearchParams {
|
|
|
1748
1749
|
);
|
|
1749
1750
|
get size(): number;
|
|
1750
1751
|
append(name: string, value: string): void;
|
|
1751
|
-
delete(name: string): void;
|
|
1752
|
+
delete(name: string, value?: any): void;
|
|
1752
1753
|
get(name: string): string | null;
|
|
1753
1754
|
getAll(name: string): string[];
|
|
1754
|
-
has(name: string): boolean;
|
|
1755
|
+
has(name: string, value?: any): boolean;
|
|
1755
1756
|
set(name: string, value: string): void;
|
|
1756
1757
|
sort(): void;
|
|
1757
1758
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -3011,11 +3012,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3011
3012
|
readonly kid: string;
|
|
3012
3013
|
}
|
|
3013
3014
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3015
|
+
export interface DynamicDispatchLimits {
|
|
3016
|
+
/**
|
|
3017
|
+
* Limit CPU time in milliseconds.
|
|
3018
|
+
*/
|
|
3019
|
+
cpuMs?: number;
|
|
3020
|
+
/**
|
|
3021
|
+
* Limit number of subrequests.
|
|
3022
|
+
*/
|
|
3023
|
+
subRequests?: number;
|
|
3024
|
+
}
|
|
3025
|
+
export interface DynamicDispatchOptions {
|
|
3026
|
+
/**
|
|
3027
|
+
* Limit resources of invoked Worker script.
|
|
3028
|
+
*/
|
|
3029
|
+
limits?: DynamicDispatchLimits;
|
|
3030
|
+
/**
|
|
3031
|
+
* Arguments for outbound Worker script, if configured.
|
|
3032
|
+
*/
|
|
3033
|
+
outbound?: {
|
|
3034
|
+
[key: string]: any;
|
|
3035
|
+
};
|
|
3036
|
+
}
|
|
3014
3037
|
export interface DispatchNamespace {
|
|
3015
3038
|
/**
|
|
3016
3039
|
* @param name Name of the Worker script.
|
|
3040
|
+
* @param args Arguments to Worker script.
|
|
3041
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3017
3042
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3018
3043
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3019
3044
|
*/
|
|
3020
|
-
get(
|
|
3045
|
+
get(
|
|
3046
|
+
name: string,
|
|
3047
|
+
args?: {
|
|
3048
|
+
[key: string]: any;
|
|
3049
|
+
},
|
|
3050
|
+
options?: DynamicDispatchOptions
|
|
3051
|
+
): Fetcher;
|
|
3021
3052
|
}
|
package/2022-11-30/index.d.ts
CHANGED
|
@@ -472,6 +472,7 @@ declare interface DurableObjectStorage {
|
|
|
472
472
|
): Promise<void>;
|
|
473
473
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
474
474
|
sync(): Promise<void>;
|
|
475
|
+
transactionSync<T>(closure: () => T): T;
|
|
475
476
|
}
|
|
476
477
|
declare interface DurableObjectListOptions {
|
|
477
478
|
start?: string;
|
|
@@ -1746,10 +1747,10 @@ declare class URLSearchParams {
|
|
|
1746
1747
|
);
|
|
1747
1748
|
get size(): number;
|
|
1748
1749
|
append(name: string, value: string): void;
|
|
1749
|
-
delete(name: string): void;
|
|
1750
|
+
delete(name: string, value?: any): void;
|
|
1750
1751
|
get(name: string): string | null;
|
|
1751
1752
|
getAll(name: string): string[];
|
|
1752
|
-
has(name: string): boolean;
|
|
1753
|
+
has(name: string, value?: any): boolean;
|
|
1753
1754
|
set(name: string, value: string): void;
|
|
1754
1755
|
sort(): void;
|
|
1755
1756
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -3018,12 +3019,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3018
3019
|
// Key Identifier of the JWK
|
|
3019
3020
|
readonly kid: string;
|
|
3020
3021
|
}
|
|
3022
|
+
declare module "cloudflare:sockets" {
|
|
3023
|
+
function _connect(
|
|
3024
|
+
address: string | SocketAddress,
|
|
3025
|
+
options?: SocketOptions
|
|
3026
|
+
): Socket;
|
|
3027
|
+
export { _connect as connect };
|
|
3028
|
+
}
|
|
3021
3029
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3030
|
+
declare interface DynamicDispatchLimits {
|
|
3031
|
+
/**
|
|
3032
|
+
* Limit CPU time in milliseconds.
|
|
3033
|
+
*/
|
|
3034
|
+
cpuMs?: number;
|
|
3035
|
+
/**
|
|
3036
|
+
* Limit number of subrequests.
|
|
3037
|
+
*/
|
|
3038
|
+
subRequests?: number;
|
|
3039
|
+
}
|
|
3040
|
+
declare interface DynamicDispatchOptions {
|
|
3041
|
+
/**
|
|
3042
|
+
* Limit resources of invoked Worker script.
|
|
3043
|
+
*/
|
|
3044
|
+
limits?: DynamicDispatchLimits;
|
|
3045
|
+
/**
|
|
3046
|
+
* Arguments for outbound Worker script, if configured.
|
|
3047
|
+
*/
|
|
3048
|
+
outbound?: {
|
|
3049
|
+
[key: string]: any;
|
|
3050
|
+
};
|
|
3051
|
+
}
|
|
3022
3052
|
declare interface DispatchNamespace {
|
|
3023
3053
|
/**
|
|
3024
3054
|
* @param name Name of the Worker script.
|
|
3055
|
+
* @param args Arguments to Worker script.
|
|
3056
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3025
3057
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3026
3058
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3027
3059
|
*/
|
|
3028
|
-
get(
|
|
3060
|
+
get(
|
|
3061
|
+
name: string,
|
|
3062
|
+
args?: {
|
|
3063
|
+
[key: string]: any;
|
|
3064
|
+
},
|
|
3065
|
+
options?: DynamicDispatchOptions
|
|
3066
|
+
): Fetcher;
|
|
3029
3067
|
}
|
package/2022-11-30/index.ts
CHANGED
|
@@ -474,6 +474,7 @@ export interface DurableObjectStorage {
|
|
|
474
474
|
): Promise<void>;
|
|
475
475
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
476
476
|
sync(): Promise<void>;
|
|
477
|
+
transactionSync<T>(closure: () => T): T;
|
|
477
478
|
}
|
|
478
479
|
export interface DurableObjectListOptions {
|
|
479
480
|
start?: string;
|
|
@@ -1751,10 +1752,10 @@ export declare class URLSearchParams {
|
|
|
1751
1752
|
);
|
|
1752
1753
|
get size(): number;
|
|
1753
1754
|
append(name: string, value: string): void;
|
|
1754
|
-
delete(name: string): void;
|
|
1755
|
+
delete(name: string, value?: any): void;
|
|
1755
1756
|
get(name: string): string | null;
|
|
1756
1757
|
getAll(name: string): string[];
|
|
1757
|
-
has(name: string): boolean;
|
|
1758
|
+
has(name: string, value?: any): boolean;
|
|
1758
1759
|
set(name: string, value: string): void;
|
|
1759
1760
|
sort(): void;
|
|
1760
1761
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -3014,11 +3015,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3014
3015
|
readonly kid: string;
|
|
3015
3016
|
}
|
|
3016
3017
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3018
|
+
export interface DynamicDispatchLimits {
|
|
3019
|
+
/**
|
|
3020
|
+
* Limit CPU time in milliseconds.
|
|
3021
|
+
*/
|
|
3022
|
+
cpuMs?: number;
|
|
3023
|
+
/**
|
|
3024
|
+
* Limit number of subrequests.
|
|
3025
|
+
*/
|
|
3026
|
+
subRequests?: number;
|
|
3027
|
+
}
|
|
3028
|
+
export interface DynamicDispatchOptions {
|
|
3029
|
+
/**
|
|
3030
|
+
* Limit resources of invoked Worker script.
|
|
3031
|
+
*/
|
|
3032
|
+
limits?: DynamicDispatchLimits;
|
|
3033
|
+
/**
|
|
3034
|
+
* Arguments for outbound Worker script, if configured.
|
|
3035
|
+
*/
|
|
3036
|
+
outbound?: {
|
|
3037
|
+
[key: string]: any;
|
|
3038
|
+
};
|
|
3039
|
+
}
|
|
3017
3040
|
export interface DispatchNamespace {
|
|
3018
3041
|
/**
|
|
3019
3042
|
* @param name Name of the Worker script.
|
|
3043
|
+
* @param args Arguments to Worker script.
|
|
3044
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3020
3045
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3021
3046
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3022
3047
|
*/
|
|
3023
|
-
get(
|
|
3048
|
+
get(
|
|
3049
|
+
name: string,
|
|
3050
|
+
args?: {
|
|
3051
|
+
[key: string]: any;
|
|
3052
|
+
},
|
|
3053
|
+
options?: DynamicDispatchOptions
|
|
3054
|
+
): Fetcher;
|
|
3024
3055
|
}
|
package/experimental/index.d.ts
CHANGED
|
@@ -478,6 +478,7 @@ declare interface DurableObjectStorage {
|
|
|
478
478
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
479
479
|
sync(): Promise<void>;
|
|
480
480
|
sql: SqlStorage;
|
|
481
|
+
transactionSync<T>(closure: () => T): T;
|
|
481
482
|
}
|
|
482
483
|
declare interface DurableObjectListOptions {
|
|
483
484
|
start?: string;
|
|
@@ -1769,10 +1770,10 @@ declare class URLSearchParams {
|
|
|
1769
1770
|
);
|
|
1770
1771
|
get size(): number;
|
|
1771
1772
|
append(name: string, value: string): void;
|
|
1772
|
-
delete(name: string): void;
|
|
1773
|
+
delete(name: string, value?: any): void;
|
|
1773
1774
|
get(name: string): string | null;
|
|
1774
1775
|
getAll(name: string): string[];
|
|
1775
|
-
has(name: string): boolean;
|
|
1776
|
+
has(name: string, value?: any): boolean;
|
|
1776
1777
|
set(name: string, value: string): void;
|
|
1777
1778
|
sort(): void;
|
|
1778
1779
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -1893,8 +1894,6 @@ declare interface SqlStorage {
|
|
|
1893
1894
|
exec(query: string, ...bindings: any[]): SqlStorageCursor;
|
|
1894
1895
|
prepare(query: string): SqlStorageStatement;
|
|
1895
1896
|
get databaseSize(): number;
|
|
1896
|
-
get voluntarySizeLimit(): number;
|
|
1897
|
-
set voluntarySizeLimit(value: number);
|
|
1898
1897
|
Cursor: typeof SqlStorageCursor;
|
|
1899
1898
|
Statement: typeof SqlStorageStatement;
|
|
1900
1899
|
}
|
|
@@ -3057,12 +3056,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3057
3056
|
// Key Identifier of the JWK
|
|
3058
3057
|
readonly kid: string;
|
|
3059
3058
|
}
|
|
3059
|
+
declare module "cloudflare:sockets" {
|
|
3060
|
+
function _connect(
|
|
3061
|
+
address: string | SocketAddress,
|
|
3062
|
+
options?: SocketOptions
|
|
3063
|
+
): Socket;
|
|
3064
|
+
export { _connect as connect };
|
|
3065
|
+
}
|
|
3060
3066
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3067
|
+
declare interface DynamicDispatchLimits {
|
|
3068
|
+
/**
|
|
3069
|
+
* Limit CPU time in milliseconds.
|
|
3070
|
+
*/
|
|
3071
|
+
cpuMs?: number;
|
|
3072
|
+
/**
|
|
3073
|
+
* Limit number of subrequests.
|
|
3074
|
+
*/
|
|
3075
|
+
subRequests?: number;
|
|
3076
|
+
}
|
|
3077
|
+
declare interface DynamicDispatchOptions {
|
|
3078
|
+
/**
|
|
3079
|
+
* Limit resources of invoked Worker script.
|
|
3080
|
+
*/
|
|
3081
|
+
limits?: DynamicDispatchLimits;
|
|
3082
|
+
/**
|
|
3083
|
+
* Arguments for outbound Worker script, if configured.
|
|
3084
|
+
*/
|
|
3085
|
+
outbound?: {
|
|
3086
|
+
[key: string]: any;
|
|
3087
|
+
};
|
|
3088
|
+
}
|
|
3061
3089
|
declare interface DispatchNamespace {
|
|
3062
3090
|
/**
|
|
3063
3091
|
* @param name Name of the Worker script.
|
|
3092
|
+
* @param args Arguments to Worker script.
|
|
3093
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3064
3094
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3065
3095
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3066
3096
|
*/
|
|
3067
|
-
get(
|
|
3097
|
+
get(
|
|
3098
|
+
name: string,
|
|
3099
|
+
args?: {
|
|
3100
|
+
[key: string]: any;
|
|
3101
|
+
},
|
|
3102
|
+
options?: DynamicDispatchOptions
|
|
3103
|
+
): Fetcher;
|
|
3068
3104
|
}
|
package/experimental/index.ts
CHANGED
|
@@ -480,6 +480,7 @@ export interface DurableObjectStorage {
|
|
|
480
480
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
481
481
|
sync(): Promise<void>;
|
|
482
482
|
sql: SqlStorage;
|
|
483
|
+
transactionSync<T>(closure: () => T): T;
|
|
483
484
|
}
|
|
484
485
|
export interface DurableObjectListOptions {
|
|
485
486
|
start?: string;
|
|
@@ -1774,10 +1775,10 @@ export declare class URLSearchParams {
|
|
|
1774
1775
|
);
|
|
1775
1776
|
get size(): number;
|
|
1776
1777
|
append(name: string, value: string): void;
|
|
1777
|
-
delete(name: string): void;
|
|
1778
|
+
delete(name: string, value?: any): void;
|
|
1778
1779
|
get(name: string): string | null;
|
|
1779
1780
|
getAll(name: string): string[];
|
|
1780
|
-
has(name: string): boolean;
|
|
1781
|
+
has(name: string, value?: any): boolean;
|
|
1781
1782
|
set(name: string, value: string): void;
|
|
1782
1783
|
sort(): void;
|
|
1783
1784
|
entries(): IterableIterator<[key: string, value: string]>;
|
|
@@ -1898,8 +1899,6 @@ export interface SqlStorage {
|
|
|
1898
1899
|
exec(query: string, ...bindings: any[]): SqlStorageCursor;
|
|
1899
1900
|
prepare(query: string): SqlStorageStatement;
|
|
1900
1901
|
get databaseSize(): number;
|
|
1901
|
-
get voluntarySizeLimit(): number;
|
|
1902
|
-
set voluntarySizeLimit(value: number);
|
|
1903
1902
|
Cursor: typeof SqlStorageCursor;
|
|
1904
1903
|
Statement: typeof SqlStorageStatement;
|
|
1905
1904
|
}
|
|
@@ -3053,11 +3052,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3053
3052
|
readonly kid: string;
|
|
3054
3053
|
}
|
|
3055
3054
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3055
|
+
export interface DynamicDispatchLimits {
|
|
3056
|
+
/**
|
|
3057
|
+
* Limit CPU time in milliseconds.
|
|
3058
|
+
*/
|
|
3059
|
+
cpuMs?: number;
|
|
3060
|
+
/**
|
|
3061
|
+
* Limit number of subrequests.
|
|
3062
|
+
*/
|
|
3063
|
+
subRequests?: number;
|
|
3064
|
+
}
|
|
3065
|
+
export interface DynamicDispatchOptions {
|
|
3066
|
+
/**
|
|
3067
|
+
* Limit resources of invoked Worker script.
|
|
3068
|
+
*/
|
|
3069
|
+
limits?: DynamicDispatchLimits;
|
|
3070
|
+
/**
|
|
3071
|
+
* Arguments for outbound Worker script, if configured.
|
|
3072
|
+
*/
|
|
3073
|
+
outbound?: {
|
|
3074
|
+
[key: string]: any;
|
|
3075
|
+
};
|
|
3076
|
+
}
|
|
3056
3077
|
export interface DispatchNamespace {
|
|
3057
3078
|
/**
|
|
3058
3079
|
* @param name Name of the Worker script.
|
|
3080
|
+
* @param args Arguments to Worker script.
|
|
3081
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3059
3082
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3060
3083
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3061
3084
|
*/
|
|
3062
|
-
get(
|
|
3085
|
+
get(
|
|
3086
|
+
name: string,
|
|
3087
|
+
args?: {
|
|
3088
|
+
[key: string]: any;
|
|
3089
|
+
},
|
|
3090
|
+
options?: DynamicDispatchOptions
|
|
3091
|
+
): Fetcher;
|
|
3063
3092
|
}
|
package/index.d.ts
CHANGED
|
@@ -462,6 +462,7 @@ declare interface DurableObjectStorage {
|
|
|
462
462
|
): Promise<void>;
|
|
463
463
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
464
464
|
sync(): Promise<void>;
|
|
465
|
+
transactionSync<T>(closure: () => T): T;
|
|
465
466
|
}
|
|
466
467
|
declare interface DurableObjectListOptions {
|
|
467
468
|
start?: string;
|
|
@@ -3025,12 +3026,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3025
3026
|
// Key Identifier of the JWK
|
|
3026
3027
|
readonly kid: string;
|
|
3027
3028
|
}
|
|
3029
|
+
declare module "cloudflare:sockets" {
|
|
3030
|
+
function _connect(
|
|
3031
|
+
address: string | SocketAddress,
|
|
3032
|
+
options?: SocketOptions
|
|
3033
|
+
): Socket;
|
|
3034
|
+
export { _connect as connect };
|
|
3035
|
+
}
|
|
3028
3036
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3037
|
+
declare interface DynamicDispatchLimits {
|
|
3038
|
+
/**
|
|
3039
|
+
* Limit CPU time in milliseconds.
|
|
3040
|
+
*/
|
|
3041
|
+
cpuMs?: number;
|
|
3042
|
+
/**
|
|
3043
|
+
* Limit number of subrequests.
|
|
3044
|
+
*/
|
|
3045
|
+
subRequests?: number;
|
|
3046
|
+
}
|
|
3047
|
+
declare interface DynamicDispatchOptions {
|
|
3048
|
+
/**
|
|
3049
|
+
* Limit resources of invoked Worker script.
|
|
3050
|
+
*/
|
|
3051
|
+
limits?: DynamicDispatchLimits;
|
|
3052
|
+
/**
|
|
3053
|
+
* Arguments for outbound Worker script, if configured.
|
|
3054
|
+
*/
|
|
3055
|
+
outbound?: {
|
|
3056
|
+
[key: string]: any;
|
|
3057
|
+
};
|
|
3058
|
+
}
|
|
3029
3059
|
declare interface DispatchNamespace {
|
|
3030
3060
|
/**
|
|
3031
3061
|
* @param name Name of the Worker script.
|
|
3062
|
+
* @param args Arguments to Worker script.
|
|
3063
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3032
3064
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3033
3065
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3034
3066
|
*/
|
|
3035
|
-
get(
|
|
3067
|
+
get(
|
|
3068
|
+
name: string,
|
|
3069
|
+
args?: {
|
|
3070
|
+
[key: string]: any;
|
|
3071
|
+
},
|
|
3072
|
+
options?: DynamicDispatchOptions
|
|
3073
|
+
): Fetcher;
|
|
3036
3074
|
}
|
package/index.ts
CHANGED
|
@@ -464,6 +464,7 @@ export interface DurableObjectStorage {
|
|
|
464
464
|
): Promise<void>;
|
|
465
465
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
466
466
|
sync(): Promise<void>;
|
|
467
|
+
transactionSync<T>(closure: () => T): T;
|
|
467
468
|
}
|
|
468
469
|
export interface DurableObjectListOptions {
|
|
469
470
|
start?: string;
|
|
@@ -3021,11 +3022,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3021
3022
|
readonly kid: string;
|
|
3022
3023
|
}
|
|
3023
3024
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3025
|
+
export interface DynamicDispatchLimits {
|
|
3026
|
+
/**
|
|
3027
|
+
* Limit CPU time in milliseconds.
|
|
3028
|
+
*/
|
|
3029
|
+
cpuMs?: number;
|
|
3030
|
+
/**
|
|
3031
|
+
* Limit number of subrequests.
|
|
3032
|
+
*/
|
|
3033
|
+
subRequests?: number;
|
|
3034
|
+
}
|
|
3035
|
+
export interface DynamicDispatchOptions {
|
|
3036
|
+
/**
|
|
3037
|
+
* Limit resources of invoked Worker script.
|
|
3038
|
+
*/
|
|
3039
|
+
limits?: DynamicDispatchLimits;
|
|
3040
|
+
/**
|
|
3041
|
+
* Arguments for outbound Worker script, if configured.
|
|
3042
|
+
*/
|
|
3043
|
+
outbound?: {
|
|
3044
|
+
[key: string]: any;
|
|
3045
|
+
};
|
|
3046
|
+
}
|
|
3024
3047
|
export interface DispatchNamespace {
|
|
3025
3048
|
/**
|
|
3026
3049
|
* @param name Name of the Worker script.
|
|
3050
|
+
* @param args Arguments to Worker script.
|
|
3051
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3027
3052
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3028
3053
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3029
3054
|
*/
|
|
3030
|
-
get(
|
|
3055
|
+
get(
|
|
3056
|
+
name: string,
|
|
3057
|
+
args?: {
|
|
3058
|
+
[key: string]: any;
|
|
3059
|
+
},
|
|
3060
|
+
options?: DynamicDispatchOptions
|
|
3061
|
+
): Fetcher;
|
|
3031
3062
|
}
|
package/oldest/index.d.ts
CHANGED
|
@@ -462,6 +462,7 @@ declare interface DurableObjectStorage {
|
|
|
462
462
|
): Promise<void>;
|
|
463
463
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
464
464
|
sync(): Promise<void>;
|
|
465
|
+
transactionSync<T>(closure: () => T): T;
|
|
465
466
|
}
|
|
466
467
|
declare interface DurableObjectListOptions {
|
|
467
468
|
start?: string;
|
|
@@ -3025,12 +3026,49 @@ declare interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3025
3026
|
// Key Identifier of the JWK
|
|
3026
3027
|
readonly kid: string;
|
|
3027
3028
|
}
|
|
3029
|
+
declare module "cloudflare:sockets" {
|
|
3030
|
+
function _connect(
|
|
3031
|
+
address: string | SocketAddress,
|
|
3032
|
+
options?: SocketOptions
|
|
3033
|
+
): Socket;
|
|
3034
|
+
export { _connect as connect };
|
|
3035
|
+
}
|
|
3028
3036
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3037
|
+
declare interface DynamicDispatchLimits {
|
|
3038
|
+
/**
|
|
3039
|
+
* Limit CPU time in milliseconds.
|
|
3040
|
+
*/
|
|
3041
|
+
cpuMs?: number;
|
|
3042
|
+
/**
|
|
3043
|
+
* Limit number of subrequests.
|
|
3044
|
+
*/
|
|
3045
|
+
subRequests?: number;
|
|
3046
|
+
}
|
|
3047
|
+
declare interface DynamicDispatchOptions {
|
|
3048
|
+
/**
|
|
3049
|
+
* Limit resources of invoked Worker script.
|
|
3050
|
+
*/
|
|
3051
|
+
limits?: DynamicDispatchLimits;
|
|
3052
|
+
/**
|
|
3053
|
+
* Arguments for outbound Worker script, if configured.
|
|
3054
|
+
*/
|
|
3055
|
+
outbound?: {
|
|
3056
|
+
[key: string]: any;
|
|
3057
|
+
};
|
|
3058
|
+
}
|
|
3029
3059
|
declare interface DispatchNamespace {
|
|
3030
3060
|
/**
|
|
3031
3061
|
* @param name Name of the Worker script.
|
|
3062
|
+
* @param args Arguments to Worker script.
|
|
3063
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3032
3064
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3033
3065
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3034
3066
|
*/
|
|
3035
|
-
get(
|
|
3067
|
+
get(
|
|
3068
|
+
name: string,
|
|
3069
|
+
args?: {
|
|
3070
|
+
[key: string]: any;
|
|
3071
|
+
},
|
|
3072
|
+
options?: DynamicDispatchOptions
|
|
3073
|
+
): Fetcher;
|
|
3036
3074
|
}
|
package/oldest/index.ts
CHANGED
|
@@ -464,6 +464,7 @@ export interface DurableObjectStorage {
|
|
|
464
464
|
): Promise<void>;
|
|
465
465
|
deleteAlarm(options?: DurableObjectSetAlarmOptions): Promise<void>;
|
|
466
466
|
sync(): Promise<void>;
|
|
467
|
+
transactionSync<T>(closure: () => T): T;
|
|
467
468
|
}
|
|
468
469
|
export interface DurableObjectListOptions {
|
|
469
470
|
start?: string;
|
|
@@ -3021,11 +3022,41 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
3021
3022
|
readonly kid: string;
|
|
3022
3023
|
}
|
|
3023
3024
|
// https://developers.cloudflare.com/cloudflare-for-platforms/workers-for-platforms/
|
|
3025
|
+
export interface DynamicDispatchLimits {
|
|
3026
|
+
/**
|
|
3027
|
+
* Limit CPU time in milliseconds.
|
|
3028
|
+
*/
|
|
3029
|
+
cpuMs?: number;
|
|
3030
|
+
/**
|
|
3031
|
+
* Limit number of subrequests.
|
|
3032
|
+
*/
|
|
3033
|
+
subRequests?: number;
|
|
3034
|
+
}
|
|
3035
|
+
export interface DynamicDispatchOptions {
|
|
3036
|
+
/**
|
|
3037
|
+
* Limit resources of invoked Worker script.
|
|
3038
|
+
*/
|
|
3039
|
+
limits?: DynamicDispatchLimits;
|
|
3040
|
+
/**
|
|
3041
|
+
* Arguments for outbound Worker script, if configured.
|
|
3042
|
+
*/
|
|
3043
|
+
outbound?: {
|
|
3044
|
+
[key: string]: any;
|
|
3045
|
+
};
|
|
3046
|
+
}
|
|
3024
3047
|
export interface DispatchNamespace {
|
|
3025
3048
|
/**
|
|
3026
3049
|
* @param name Name of the Worker script.
|
|
3050
|
+
* @param args Arguments to Worker script.
|
|
3051
|
+
* @param options Options for Dynamic Dispatch invocation.
|
|
3027
3052
|
* @returns A Fetcher object that allows you to send requests to the Worker script.
|
|
3028
3053
|
* @throws If the Worker script does not exist in this dispatch namespace, an error will be thrown.
|
|
3029
3054
|
*/
|
|
3030
|
-
get(
|
|
3055
|
+
get(
|
|
3056
|
+
name: string,
|
|
3057
|
+
args?: {
|
|
3058
|
+
[key: string]: any;
|
|
3059
|
+
},
|
|
3060
|
+
options?: DynamicDispatchOptions
|
|
3061
|
+
): Fetcher;
|
|
3031
3062
|
}
|
package/package.json
CHANGED