@floegence/redevplugin-ui 0.4.3 → 0.5.1
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/dist/bridge-capability.d.ts +7 -0
- package/dist/bridge-capability.js +8 -0
- package/dist/capability-client.d.ts +27 -7
- package/dist/capability-client.js +25 -19
- package/dist/contracts.gen.d.ts +84 -66
- package/dist/contracts.gen.js +87 -66
- package/dist/error-codes.gen.d.ts +4 -0
- package/dist/error-codes.gen.js +206 -0
- package/dist/errors.d.ts +22 -4
- package/dist/errors.js +42 -60
- package/dist/http.d.ts +16 -8
- package/dist/http.js +151 -15
- package/dist/local-import.d.ts +6 -11
- package/dist/local-import.js +58 -13
- package/dist/opaque-surface-policy.gen.d.ts +4 -3
- package/dist/opaque-surface-policy.gen.js +4 -2
- package/dist/openapi.gen.d.ts +3745 -0
- package/dist/openapi.gen.js +5 -0
- package/dist/platform.d.ts +148 -529
- package/dist/platform.js +250 -81
- package/dist/plugin.d.ts +2 -2
- package/dist/surface-scope.d.ts +2 -2
- package/dist/surface-scope.js +22 -6
- package/dist/surface.d.ts +64 -31
- package/dist/surface.js +1406 -202
- package/dist/trusted-parent.d.ts +3 -3
- package/dist/trusted-parent.js +1 -1
- package/dist/ui-patch-validator.d.ts +67 -0
- package/dist/ui-patch-validator.js +125 -0
- package/dist/ui-reconciler.d.ts +10 -0
- package/dist/ui-reconciler.js +283 -0
- package/package.json +1 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { PluginBridgeClient, PluginBridgeRequestOptions, PluginJSONObject } from "./surface.js";
|
|
2
|
+
export type PluginBridgeCapabilityEffect = "read" | "write" | "execute" | "delete" | "admin";
|
|
3
|
+
export declare const pluginBridgeCapabilityEffect: unique symbol;
|
|
4
|
+
export type PluginBridgeCapabilityRequestOptions = PluginBridgeRequestOptions & {
|
|
5
|
+
[pluginBridgeCapabilityEffect]: PluginBridgeCapabilityEffect;
|
|
6
|
+
};
|
|
7
|
+
export declare function callPluginBridgeCapability<T>(bridge: PluginBridgeClient, method: string, params: PluginJSONObject | undefined, effect: PluginBridgeCapabilityEffect, options?: PluginBridgeRequestOptions): Promise<T>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export const pluginBridgeCapabilityEffect = Symbol("redevplugin.capability.effect");
|
|
2
|
+
export function callPluginBridgeCapability(bridge, method, params, effect, options = {}) {
|
|
3
|
+
const capabilityOptions = {
|
|
4
|
+
signal: options.signal,
|
|
5
|
+
[pluginBridgeCapabilityEffect]: effect,
|
|
6
|
+
};
|
|
7
|
+
return bridge.call(method, params, capabilityOptions);
|
|
8
|
+
}
|
|
@@ -1,6 +1,25 @@
|
|
|
1
1
|
import { PluginBridgeError } from "./errors.js";
|
|
2
|
-
import type { PluginBridgeClient, PluginJSONObject, PluginStreamEvent as PluginRawStreamEvent, PluginStreamTerminalStatus } from "./surface.js";
|
|
2
|
+
import type { PluginBridgeClient, PluginBridgeRequestOptions, PluginJSONObject, PluginStreamEvent as PluginRawStreamEvent, PluginStreamTerminalStatus } from "./surface.js";
|
|
3
3
|
export type PluginCapabilitySchema = Readonly<Record<string, unknown>>;
|
|
4
|
+
export type PluginCapabilityEffect = "read" | "write" | "execute" | "delete" | "admin";
|
|
5
|
+
type PluginCapabilityMethodContract = {
|
|
6
|
+
method: string;
|
|
7
|
+
effect: PluginCapabilityEffect;
|
|
8
|
+
requestSchema: PluginCapabilitySchema;
|
|
9
|
+
responseSchema: PluginCapabilitySchema;
|
|
10
|
+
};
|
|
11
|
+
export type PluginCapabilitySyncContract = PluginCapabilityMethodContract & {
|
|
12
|
+
execution: "sync";
|
|
13
|
+
};
|
|
14
|
+
export type PluginCapabilityOperationContract<Cancelable extends boolean = boolean> = PluginCapabilityMethodContract & {
|
|
15
|
+
execution: "operation";
|
|
16
|
+
cancelable: Cancelable;
|
|
17
|
+
};
|
|
18
|
+
export type PluginCapabilityStreamContract = PluginCapabilityMethodContract & {
|
|
19
|
+
execution: "subscription";
|
|
20
|
+
eventTypeName: string;
|
|
21
|
+
eventSchema: PluginCapabilitySchema;
|
|
22
|
+
};
|
|
4
23
|
export type PluginCapabilityBusinessErrorSpec = {
|
|
5
24
|
detail_schema_sha256: string;
|
|
6
25
|
schema: PluginCapabilitySchema | null;
|
|
@@ -9,7 +28,7 @@ export type PluginOperation<T, Cancelable extends boolean = true> = {
|
|
|
9
28
|
data: T;
|
|
10
29
|
operation_id: string;
|
|
11
30
|
} & (Cancelable extends true ? {
|
|
12
|
-
cancel(reason?: string): Promise<void>;
|
|
31
|
+
cancel(reason?: string, options?: PluginBridgeRequestOptions): Promise<void>;
|
|
13
32
|
} : Record<never, never>);
|
|
14
33
|
export type PluginCapabilityStreamEvent<Event> = Omit<PluginRawStreamEvent, "data" | "error"> & {
|
|
15
34
|
data: Event;
|
|
@@ -28,13 +47,14 @@ export type PluginStream<Initial, Event> = {
|
|
|
28
47
|
data: Initial;
|
|
29
48
|
operation_id: string;
|
|
30
49
|
stream_handle: string;
|
|
31
|
-
read(): Promise<PluginCapabilityStreamReadResult<Event>>;
|
|
32
|
-
cancel(reason?: string): Promise<void>;
|
|
50
|
+
read(options?: PluginBridgeRequestOptions): Promise<PluginCapabilityStreamReadResult<Event>>;
|
|
51
|
+
cancel(reason?: string, options?: PluginBridgeRequestOptions): Promise<void>;
|
|
33
52
|
[Symbol.asyncIterator](): AsyncIterableIterator<PluginCapabilityStreamEvent<Event>>;
|
|
34
53
|
};
|
|
35
|
-
export declare function callCapabilitySync<Request extends object, Response>(bridge: PluginBridgeClient,
|
|
36
|
-
export declare function callCapabilityOperation<Request extends object, Response, Cancelable extends boolean = true>(bridge: PluginBridgeClient,
|
|
37
|
-
export declare function callCapabilityStream<Request extends object, Response, Event>(bridge: PluginBridgeClient,
|
|
54
|
+
export declare function callCapabilitySync<Request extends object, Response>(bridge: PluginBridgeClient, contract: PluginCapabilitySyncContract, request: Request, options?: PluginBridgeRequestOptions): Promise<Response>;
|
|
55
|
+
export declare function callCapabilityOperation<Request extends object, Response, Cancelable extends boolean = true>(bridge: PluginBridgeClient, contract: PluginCapabilityOperationContract<Cancelable>, request: Request, options?: PluginBridgeRequestOptions): Promise<PluginOperation<Response, Cancelable>>;
|
|
56
|
+
export declare function callCapabilityStream<Request extends object, Response, Event>(bridge: PluginBridgeClient, contract: PluginCapabilityStreamContract, request: Request, options?: PluginBridgeRequestOptions): Promise<PluginStream<Response, Event>>;
|
|
38
57
|
export declare function isCapabilityBusinessError(error: unknown, capabilityID: string, capabilityVersion: string, detailSchemas: Readonly<Record<string, PluginCapabilityBusinessErrorSpec>>): error is PluginBridgeError & {
|
|
39
58
|
readonly details: PluginJSONObject;
|
|
40
59
|
};
|
|
60
|
+
export {};
|
|
@@ -1,55 +1,61 @@
|
|
|
1
1
|
import { PluginBridgeError } from "./errors.js";
|
|
2
|
+
import { callPluginBridgeCapability } from "./bridge-capability.js";
|
|
2
3
|
import { decodePluginStreamText } from "./surface.js";
|
|
3
|
-
export async function callCapabilitySync(bridge,
|
|
4
|
-
const params = validateRequest(request, requestSchema);
|
|
5
|
-
const result = parseSyncResult(method, await bridge.
|
|
6
|
-
return validateResponse(method, result.data, responseSchema);
|
|
7
|
-
}
|
|
8
|
-
export async function callCapabilityOperation(bridge,
|
|
9
|
-
const params = validateRequest(request, requestSchema);
|
|
10
|
-
const result = parseOperationResult(method, await bridge.
|
|
4
|
+
export async function callCapabilitySync(bridge, contract, request, options = {}) {
|
|
5
|
+
const params = validateRequest(request, contract.requestSchema);
|
|
6
|
+
const result = parseSyncResult(contract.method, await callPluginBridgeCapability(bridge, contract.method, params, contract.effect, options));
|
|
7
|
+
return validateResponse(contract.method, result.data, contract.responseSchema);
|
|
8
|
+
}
|
|
9
|
+
export async function callCapabilityOperation(bridge, contract, request, options = {}) {
|
|
10
|
+
const params = validateRequest(request, contract.requestSchema);
|
|
11
|
+
const result = parseOperationResult(contract.method, await callPluginBridgeCapability(bridge, contract.method, params, contract.effect, options));
|
|
11
12
|
let data;
|
|
12
13
|
try {
|
|
13
|
-
data = validateResponse(method, result.data, responseSchema);
|
|
14
|
+
data = validateResponse(contract.method, result.data, contract.responseSchema);
|
|
14
15
|
}
|
|
15
16
|
catch (error) {
|
|
16
|
-
if (cancelable)
|
|
17
|
+
if (contract.cancelable)
|
|
17
18
|
await cancelAfterResponseMismatch(bridge, result.operation_id, error);
|
|
18
19
|
throw error;
|
|
19
20
|
}
|
|
20
21
|
return Object.freeze({
|
|
21
22
|
data: data,
|
|
22
23
|
operation_id: result.operation_id,
|
|
23
|
-
...(cancelable ? {
|
|
24
|
+
...(contract.cancelable ? {
|
|
25
|
+
cancel: (reason, cancelOptions) => bridge.cancelOperation(result.operation_id, reason, cancelOptions),
|
|
26
|
+
} : {}),
|
|
24
27
|
});
|
|
25
28
|
}
|
|
26
|
-
export async function callCapabilityStream(bridge,
|
|
27
|
-
const params = validateRequest(request, requestSchema);
|
|
28
|
-
const result = parseStreamResult(method, await bridge.
|
|
29
|
+
export async function callCapabilityStream(bridge, contract, request, options = {}) {
|
|
30
|
+
const params = validateRequest(request, contract.requestSchema);
|
|
31
|
+
const result = parseStreamResult(contract.method, await callPluginBridgeCapability(bridge, contract.method, params, contract.effect, options));
|
|
29
32
|
let data;
|
|
30
33
|
try {
|
|
31
|
-
data = validateResponse(method, result.data, responseSchema);
|
|
34
|
+
data = validateResponse(contract.method, result.data, contract.responseSchema);
|
|
32
35
|
}
|
|
33
36
|
catch (error) {
|
|
34
37
|
await cancelAfterResponseMismatch(bridge, result.operation_id, error);
|
|
35
38
|
}
|
|
36
39
|
let settled = false;
|
|
37
|
-
const read = async () => {
|
|
40
|
+
const read = async (options = {}) => {
|
|
38
41
|
try {
|
|
39
|
-
const batch = decodeCapabilityStreamBatch(method, await bridge.readStream(result.stream_handle), eventTypeName, eventSchema);
|
|
42
|
+
const batch = decodeCapabilityStreamBatch(contract.method, await bridge.readStream(result.stream_handle, options), contract.eventTypeName, contract.eventSchema);
|
|
40
43
|
if (batch.done)
|
|
41
44
|
settled = true;
|
|
42
45
|
return batch;
|
|
43
46
|
}
|
|
44
47
|
catch (error) {
|
|
48
|
+
if (options.signal?.aborted && error instanceof PluginBridgeError && error.errorCode === "PLUGIN_STREAM_CANCELLED") {
|
|
49
|
+
throw error;
|
|
50
|
+
}
|
|
45
51
|
settled = true;
|
|
46
52
|
return cancelAfterStreamMismatch(bridge, result.operation_id, error);
|
|
47
53
|
}
|
|
48
54
|
};
|
|
49
|
-
const cancel = async (reason) => {
|
|
55
|
+
const cancel = async (reason, cancelOptions = {}) => {
|
|
50
56
|
if (settled)
|
|
51
57
|
return;
|
|
52
|
-
await bridge.cancelOperation(result.operation_id, reason);
|
|
58
|
+
await bridge.cancelOperation(result.operation_id, reason, cancelOptions);
|
|
53
59
|
settled = true;
|
|
54
60
|
};
|
|
55
61
|
return Object.freeze({
|
package/dist/contracts.gen.d.ts
CHANGED
|
@@ -1,35 +1,38 @@
|
|
|
1
|
-
export declare const pluginUIProtocolVersion: "plugin-ui-
|
|
2
|
-
export declare const pluginHostProtocolVersion: "plugin-host-
|
|
3
|
-
export declare const bridgeSchemaVersion: "bridge-
|
|
4
|
-
export declare const tokenTicketSchemaVersion: "token-ticket-
|
|
1
|
+
export declare const pluginUIProtocolVersion: "plugin-ui-v5";
|
|
2
|
+
export declare const pluginHostProtocolVersion: "plugin-host-v4";
|
|
3
|
+
export declare const bridgeSchemaVersion: "bridge-v5";
|
|
4
|
+
export declare const tokenTicketSchemaVersion: "token-ticket-v3";
|
|
5
5
|
export declare const redevPluginContractVersions: {
|
|
6
|
-
readonly plugin_ui_protocol_version: "plugin-ui-
|
|
7
|
-
readonly plugin_host_protocol_version: "plugin-host-
|
|
8
|
-
readonly rust_ipc_version: "rust-ipc-
|
|
6
|
+
readonly plugin_ui_protocol_version: "plugin-ui-v5";
|
|
7
|
+
readonly plugin_host_protocol_version: "plugin-host-v4";
|
|
8
|
+
readonly rust_ipc_version: "rust-ipc-v4";
|
|
9
9
|
readonly wasm_abi_version: "redevplugin-wasm-worker-v2";
|
|
10
|
-
readonly manifest_schema_version: "manifest-
|
|
10
|
+
readonly manifest_schema_version: "manifest-v5";
|
|
11
11
|
readonly package_signature_schema_version: "package-signature-v1";
|
|
12
|
-
readonly release_metadata_schema_version: "release-metadata-
|
|
12
|
+
readonly release_metadata_schema_version: "release-metadata-v5";
|
|
13
13
|
readonly source_policy_schema_version: "source-policy-v1";
|
|
14
14
|
readonly source_revocations_schema_version: "source-revocations-v1";
|
|
15
|
-
readonly token_ticket_schema_version: "token-ticket-
|
|
16
|
-
readonly bridge_schema_version: "bridge-
|
|
17
|
-
readonly opaque_surface_document_schema_version: "opaque-surface-document-
|
|
18
|
-
readonly opaque_surface_transport_schema_version: "opaque-surface-transport-
|
|
19
|
-
readonly target_classifier_version: "target-classifier-
|
|
20
|
-
readonly network_grant_schema_version: "network-grant-
|
|
21
|
-
readonly
|
|
22
|
-
readonly
|
|
23
|
-
readonly
|
|
24
|
-
readonly
|
|
25
|
-
readonly
|
|
15
|
+
readonly token_ticket_schema_version: "token-ticket-v3";
|
|
16
|
+
readonly bridge_schema_version: "bridge-v5";
|
|
17
|
+
readonly opaque_surface_document_schema_version: "opaque-surface-document-v3";
|
|
18
|
+
readonly opaque_surface_transport_schema_version: "opaque-surface-transport-v4";
|
|
19
|
+
readonly target_classifier_version: "target-classifier-v2";
|
|
20
|
+
readonly network_grant_schema_version: "network-grant-v2";
|
|
21
|
+
readonly resource_scope_schema_version: "resource-scope-v1";
|
|
22
|
+
readonly plugin_platform_openapi_version: "plugin-platform-v6";
|
|
23
|
+
readonly compatibility_manifest_version: "redevplugin.compatibility.v6";
|
|
24
|
+
readonly compatibility_schema_version: "compatibility-manifest-v6";
|
|
25
|
+
readonly release_manifest_schema_version: "release-manifest-v4";
|
|
26
|
+
readonly worker_invocation_schema_version: "worker-invocation-v3";
|
|
26
27
|
readonly host_capability_contract_schema_version: "host-capability-contract-v1";
|
|
27
28
|
readonly host_capability_pin_schema_version: "host-capability-pin-v1";
|
|
28
29
|
readonly host_capability_manifest_schema_version: "host-capability-manifest-v1";
|
|
29
30
|
readonly host_capability_compatibility_schema_version: "host-capability-compatibility-v1";
|
|
30
31
|
readonly host_capability_signature_schema_version: "host-capability-signature-v1";
|
|
31
32
|
readonly host_capability_notices_schema_version: "host-capability-notices-v1";
|
|
32
|
-
readonly error_codes_schema_version: "error-codes-
|
|
33
|
+
readonly error_codes_schema_version: "error-codes-v4";
|
|
34
|
+
readonly performance_contract_version: "performance-contract-v1";
|
|
35
|
+
readonly performance_evidence_schema_version: "performance-evidence-v1";
|
|
33
36
|
readonly contract_registry_version: "contract-registry-v1";
|
|
34
37
|
};
|
|
35
38
|
export type ReDevPluginContractArtifact = {
|
|
@@ -40,14 +43,14 @@ export type ReDevPluginContractArtifact = {
|
|
|
40
43
|
};
|
|
41
44
|
export declare const redevPluginContractArtifacts: readonly [{
|
|
42
45
|
readonly id: "plugin-platform-openapi";
|
|
43
|
-
readonly path: "spec/openapi/plugin-platform-
|
|
44
|
-
readonly version: "plugin-platform-
|
|
45
|
-
readonly sha256: "
|
|
46
|
+
readonly path: "spec/openapi/plugin-platform-v6.yaml";
|
|
47
|
+
readonly version: "plugin-platform-v6";
|
|
48
|
+
readonly sha256: "7cfcf789dc6a414eb9e3a2db3fee79432c1668ad778adcff70401a0640780378";
|
|
46
49
|
}, {
|
|
47
50
|
readonly id: "manifest-schema";
|
|
48
|
-
readonly path: "spec/plugin/manifest-
|
|
49
|
-
readonly version: "manifest-
|
|
50
|
-
readonly sha256: "
|
|
51
|
+
readonly path: "spec/plugin/manifest-v5.schema.json";
|
|
52
|
+
readonly version: "manifest-v5";
|
|
53
|
+
readonly sha256: "9695f6163aa539b9e3a933367c98850257c6d7bb8d61b36fd5f83b3ab61746f7";
|
|
51
54
|
}, {
|
|
52
55
|
readonly id: "package-signature-schema";
|
|
53
56
|
readonly path: "spec/plugin/package-signature-v1.schema.json";
|
|
@@ -55,9 +58,9 @@ export declare const redevPluginContractArtifacts: readonly [{
|
|
|
55
58
|
readonly sha256: "13951c0f6831ba28647774368c76a817868aeb7984628e2cf3dc4ad1b54f8284";
|
|
56
59
|
}, {
|
|
57
60
|
readonly id: "release-metadata-schema";
|
|
58
|
-
readonly path: "spec/plugin/release-metadata-
|
|
59
|
-
readonly version: "release-metadata-
|
|
60
|
-
readonly sha256: "
|
|
61
|
+
readonly path: "spec/plugin/release-metadata-v5.schema.json";
|
|
62
|
+
readonly version: "release-metadata-v5";
|
|
63
|
+
readonly sha256: "255ef3deb7d2758a43e69e533a08aa28106f8edc2e7385ab0aec0d50c1ef3d7a";
|
|
61
64
|
}, {
|
|
62
65
|
readonly id: "source-policy-schema";
|
|
63
66
|
readonly path: "spec/plugin/source-policy-v1.schema.json";
|
|
@@ -70,44 +73,44 @@ export declare const redevPluginContractArtifacts: readonly [{
|
|
|
70
73
|
readonly sha256: "4c4132879a51b31e99775c979ca3ab43c2ee4c5c885f3ff1e7b43cd5ce8bc83d";
|
|
71
74
|
}, {
|
|
72
75
|
readonly id: "token-ticket-schema";
|
|
73
|
-
readonly path: "spec/plugin/token-ticket-
|
|
74
|
-
readonly version: "token-ticket-
|
|
75
|
-
readonly sha256: "
|
|
76
|
+
readonly path: "spec/plugin/token-ticket-v3.schema.json";
|
|
77
|
+
readonly version: "token-ticket-v3";
|
|
78
|
+
readonly sha256: "17c7f2e7c7fcaa0eb43da7ecd92e4f36a918cc8149eec031d0231191d9245f16";
|
|
76
79
|
}, {
|
|
77
80
|
readonly id: "iframe-bridge-schema";
|
|
78
|
-
readonly path: "spec/plugin/bridge-
|
|
79
|
-
readonly version: "bridge-
|
|
80
|
-
readonly sha256: "
|
|
81
|
+
readonly path: "spec/plugin/bridge-v5.schema.json";
|
|
82
|
+
readonly version: "bridge-v5";
|
|
83
|
+
readonly sha256: "b7bfeaad2eb34440881889d608297ef941e4d4a46c914c6bd19dfe4331d59729";
|
|
81
84
|
}, {
|
|
82
85
|
readonly id: "opaque-surface-document-schema";
|
|
83
|
-
readonly path: "spec/plugin/opaque-surface-document-
|
|
84
|
-
readonly version: "opaque-surface-document-
|
|
85
|
-
readonly sha256: "
|
|
86
|
+
readonly path: "spec/plugin/opaque-surface-document-v3.schema.json";
|
|
87
|
+
readonly version: "opaque-surface-document-v3";
|
|
88
|
+
readonly sha256: "63419ff5b5a8890e14f97ca29aaae175b93daff61d4567c5bdff7f6e6a9e7450";
|
|
86
89
|
}, {
|
|
87
90
|
readonly id: "opaque-surface-transport-schema";
|
|
88
|
-
readonly path: "spec/plugin/opaque-surface-transport-
|
|
89
|
-
readonly version: "opaque-surface-transport-
|
|
90
|
-
readonly sha256: "
|
|
91
|
+
readonly path: "spec/plugin/opaque-surface-transport-v4.schema.json";
|
|
92
|
+
readonly version: "opaque-surface-transport-v4";
|
|
93
|
+
readonly sha256: "70a32dc8bf281cea2c92492c466fd477070c62156a3f593d45eb460cde62dca2";
|
|
91
94
|
}, {
|
|
92
95
|
readonly id: "compatibility-manifest-schema";
|
|
93
|
-
readonly path: "spec/plugin/compatibility-manifest-
|
|
94
|
-
readonly version: "compatibility-manifest-
|
|
95
|
-
readonly sha256: "
|
|
96
|
+
readonly path: "spec/plugin/compatibility-manifest-v6.schema.json";
|
|
97
|
+
readonly version: "compatibility-manifest-v6";
|
|
98
|
+
readonly sha256: "4f9e2a42c5a4893afad4027a5f29e4fc37843f450451dc5db26ac7919166a0db";
|
|
96
99
|
}, {
|
|
97
100
|
readonly id: "release-manifest-schema";
|
|
98
|
-
readonly path: "spec/plugin/release-manifest-
|
|
99
|
-
readonly version: "release-manifest-
|
|
100
|
-
readonly sha256: "
|
|
101
|
+
readonly path: "spec/plugin/release-manifest-v4.schema.json";
|
|
102
|
+
readonly version: "release-manifest-v4";
|
|
103
|
+
readonly sha256: "b0a9e95b7bc819ee2a17a2d0bc4105b524e138945c11a19c77306a0a5351d63f";
|
|
101
104
|
}, {
|
|
102
105
|
readonly id: "worker-invocation-schema";
|
|
103
|
-
readonly path: "spec/plugin/worker-invocation-
|
|
104
|
-
readonly version: "worker-invocation-
|
|
105
|
-
readonly sha256: "
|
|
106
|
+
readonly path: "spec/plugin/worker-invocation-v3.schema.json";
|
|
107
|
+
readonly version: "worker-invocation-v3";
|
|
108
|
+
readonly sha256: "f08af491cbf5e7b71d1aeafbeac9ae581ee5fc3bcb76184daec369f94bab3927";
|
|
106
109
|
}, {
|
|
107
110
|
readonly id: "host-capability-contract-schema";
|
|
108
111
|
readonly path: "spec/plugin/host-capability-contract-v1.schema.json";
|
|
109
112
|
readonly version: "host-capability-contract-v1";
|
|
110
|
-
readonly sha256: "
|
|
113
|
+
readonly sha256: "0a653e36d44104f1d16b06ee424648086c146f23c907b176bdf470ae73025485";
|
|
111
114
|
}, {
|
|
112
115
|
readonly id: "host-capability-pin-schema";
|
|
113
116
|
readonly path: "spec/plugin/host-capability-pin-v1.schema.json";
|
|
@@ -135,32 +138,47 @@ export declare const redevPluginContractArtifacts: readonly [{
|
|
|
135
138
|
readonly sha256: "6affd5d0ae90239f6fd08cbeddae4eef393efa2838c9e4935874ba3dc0e05948";
|
|
136
139
|
}, {
|
|
137
140
|
readonly id: "error-codes-schema";
|
|
138
|
-
readonly path: "spec/plugin/error-codes-
|
|
139
|
-
readonly version: "error-codes-
|
|
140
|
-
readonly sha256: "
|
|
141
|
+
readonly path: "spec/plugin/error-codes-v4.schema.json";
|
|
142
|
+
readonly version: "error-codes-v4";
|
|
143
|
+
readonly sha256: "97149dc2f24fcd5ce337e6b4032a90edc2f0f945dc3c575b4310950372a5dd07";
|
|
144
|
+
}, {
|
|
145
|
+
readonly id: "performance-contract";
|
|
146
|
+
readonly path: "spec/plugin/performance-contract-v1.json";
|
|
147
|
+
readonly version: "performance-contract-v1";
|
|
148
|
+
readonly sha256: "93f54632e327c62a83947b30fd073ebf7640293ca9953872be1c22f2642e68d8";
|
|
149
|
+
}, {
|
|
150
|
+
readonly id: "performance-evidence-schema";
|
|
151
|
+
readonly path: "spec/plugin/performance-evidence-v1.schema.json";
|
|
152
|
+
readonly version: "performance-evidence-v1";
|
|
153
|
+
readonly sha256: "99bd635c97886f382090d4d8cac13ac499e81c7b236338b53a96dc94e9063a59";
|
|
141
154
|
}, {
|
|
142
155
|
readonly id: "rust-ipc-schema";
|
|
143
|
-
readonly path: "spec/plugin/ipc-
|
|
144
|
-
readonly version: "rust-ipc-
|
|
145
|
-
readonly sha256: "
|
|
156
|
+
readonly path: "spec/plugin/ipc-v4.schema.json";
|
|
157
|
+
readonly version: "rust-ipc-v4";
|
|
158
|
+
readonly sha256: "eb66a442f1c45b8c75a0232f68632df8fb07929addc6da5b2f79970adf77662c";
|
|
146
159
|
}, {
|
|
147
160
|
readonly id: "wasm-worker-schema";
|
|
148
161
|
readonly path: "spec/plugin/wasm-worker-v2.schema.json";
|
|
149
162
|
readonly version: "redevplugin-wasm-worker-v2";
|
|
150
|
-
readonly sha256: "
|
|
163
|
+
readonly sha256: "00bf123f3a9ed932de4b71c180e2a5c34af0f82050defb271fedec42cf217902";
|
|
151
164
|
}, {
|
|
152
165
|
readonly id: "network-grant-schema";
|
|
153
|
-
readonly path: "spec/plugin/network-grant-
|
|
154
|
-
readonly version: "network-grant-
|
|
155
|
-
readonly sha256: "
|
|
166
|
+
readonly path: "spec/plugin/network-grant-v2.schema.json";
|
|
167
|
+
readonly version: "network-grant-v2";
|
|
168
|
+
readonly sha256: "5fc1cfc3469a992e551fd392fab982abb6f95e456a1cb768ceca137f7c693abc";
|
|
169
|
+
}, {
|
|
170
|
+
readonly id: "resource-scope-schema";
|
|
171
|
+
readonly path: "spec/plugin/resource-scope-v1.schema.json";
|
|
172
|
+
readonly version: "resource-scope-v1";
|
|
173
|
+
readonly sha256: "e6021bd576c7220ad5536645a7ad8e57ee7aeb9901c31a89444fa6b695d8dc6f";
|
|
156
174
|
}, {
|
|
157
175
|
readonly id: "target-classifier-fixture";
|
|
158
|
-
readonly path: "spec/plugin/target-classifier-
|
|
159
|
-
readonly version: "target-classifier-
|
|
160
|
-
readonly sha256: "
|
|
176
|
+
readonly path: "spec/plugin/target-classifier-v2.json";
|
|
177
|
+
readonly version: "target-classifier-v2";
|
|
178
|
+
readonly sha256: "ae7336cce77a2e820f96f1cc309b93f8442c932dcebec25e3890d31cd098e2d1";
|
|
161
179
|
}, {
|
|
162
180
|
readonly id: "contract-registry";
|
|
163
181
|
readonly path: "spec/plugin/contract-registry-v1.json";
|
|
164
182
|
readonly version: "contract-registry-v1";
|
|
165
|
-
readonly sha256: "
|
|
183
|
+
readonly sha256: "86cc5ccce02ef00b6cf8b44af07ad3a82867ee039d8d82ffc704194ee2c62547";
|
|
166
184
|
}];
|
package/dist/contracts.gen.js
CHANGED
|
@@ -1,50 +1,53 @@
|
|
|
1
1
|
// Code generated by scripts/generate_contract_registry.mjs; DO NOT EDIT.
|
|
2
|
-
export const pluginUIProtocolVersion = "plugin-ui-
|
|
3
|
-
export const pluginHostProtocolVersion = "plugin-host-
|
|
4
|
-
export const bridgeSchemaVersion = "bridge-
|
|
5
|
-
export const tokenTicketSchemaVersion = "token-ticket-
|
|
2
|
+
export const pluginUIProtocolVersion = "plugin-ui-v5";
|
|
3
|
+
export const pluginHostProtocolVersion = "plugin-host-v4";
|
|
4
|
+
export const bridgeSchemaVersion = "bridge-v5";
|
|
5
|
+
export const tokenTicketSchemaVersion = "token-ticket-v3";
|
|
6
6
|
export const redevPluginContractVersions = {
|
|
7
|
-
"plugin_ui_protocol_version": "plugin-ui-
|
|
8
|
-
"plugin_host_protocol_version": "plugin-host-
|
|
9
|
-
"rust_ipc_version": "rust-ipc-
|
|
7
|
+
"plugin_ui_protocol_version": "plugin-ui-v5",
|
|
8
|
+
"plugin_host_protocol_version": "plugin-host-v4",
|
|
9
|
+
"rust_ipc_version": "rust-ipc-v4",
|
|
10
10
|
"wasm_abi_version": "redevplugin-wasm-worker-v2",
|
|
11
|
-
"manifest_schema_version": "manifest-
|
|
11
|
+
"manifest_schema_version": "manifest-v5",
|
|
12
12
|
"package_signature_schema_version": "package-signature-v1",
|
|
13
|
-
"release_metadata_schema_version": "release-metadata-
|
|
13
|
+
"release_metadata_schema_version": "release-metadata-v5",
|
|
14
14
|
"source_policy_schema_version": "source-policy-v1",
|
|
15
15
|
"source_revocations_schema_version": "source-revocations-v1",
|
|
16
|
-
"token_ticket_schema_version": "token-ticket-
|
|
17
|
-
"bridge_schema_version": "bridge-
|
|
18
|
-
"opaque_surface_document_schema_version": "opaque-surface-document-
|
|
19
|
-
"opaque_surface_transport_schema_version": "opaque-surface-transport-
|
|
20
|
-
"target_classifier_version": "target-classifier-
|
|
21
|
-
"network_grant_schema_version": "network-grant-
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
26
|
-
"
|
|
16
|
+
"token_ticket_schema_version": "token-ticket-v3",
|
|
17
|
+
"bridge_schema_version": "bridge-v5",
|
|
18
|
+
"opaque_surface_document_schema_version": "opaque-surface-document-v3",
|
|
19
|
+
"opaque_surface_transport_schema_version": "opaque-surface-transport-v4",
|
|
20
|
+
"target_classifier_version": "target-classifier-v2",
|
|
21
|
+
"network_grant_schema_version": "network-grant-v2",
|
|
22
|
+
"resource_scope_schema_version": "resource-scope-v1",
|
|
23
|
+
"plugin_platform_openapi_version": "plugin-platform-v6",
|
|
24
|
+
"compatibility_manifest_version": "redevplugin.compatibility.v6",
|
|
25
|
+
"compatibility_schema_version": "compatibility-manifest-v6",
|
|
26
|
+
"release_manifest_schema_version": "release-manifest-v4",
|
|
27
|
+
"worker_invocation_schema_version": "worker-invocation-v3",
|
|
27
28
|
"host_capability_contract_schema_version": "host-capability-contract-v1",
|
|
28
29
|
"host_capability_pin_schema_version": "host-capability-pin-v1",
|
|
29
30
|
"host_capability_manifest_schema_version": "host-capability-manifest-v1",
|
|
30
31
|
"host_capability_compatibility_schema_version": "host-capability-compatibility-v1",
|
|
31
32
|
"host_capability_signature_schema_version": "host-capability-signature-v1",
|
|
32
33
|
"host_capability_notices_schema_version": "host-capability-notices-v1",
|
|
33
|
-
"error_codes_schema_version": "error-codes-
|
|
34
|
+
"error_codes_schema_version": "error-codes-v4",
|
|
35
|
+
"performance_contract_version": "performance-contract-v1",
|
|
36
|
+
"performance_evidence_schema_version": "performance-evidence-v1",
|
|
34
37
|
"contract_registry_version": "contract-registry-v1",
|
|
35
38
|
};
|
|
36
39
|
export const redevPluginContractArtifacts = [
|
|
37
40
|
{
|
|
38
41
|
id: "plugin-platform-openapi",
|
|
39
|
-
path: "spec/openapi/plugin-platform-
|
|
40
|
-
version: "plugin-platform-
|
|
41
|
-
sha256: "
|
|
42
|
+
path: "spec/openapi/plugin-platform-v6.yaml",
|
|
43
|
+
version: "plugin-platform-v6",
|
|
44
|
+
sha256: "7cfcf789dc6a414eb9e3a2db3fee79432c1668ad778adcff70401a0640780378",
|
|
42
45
|
},
|
|
43
46
|
{
|
|
44
47
|
id: "manifest-schema",
|
|
45
|
-
path: "spec/plugin/manifest-
|
|
46
|
-
version: "manifest-
|
|
47
|
-
sha256: "
|
|
48
|
+
path: "spec/plugin/manifest-v5.schema.json",
|
|
49
|
+
version: "manifest-v5",
|
|
50
|
+
sha256: "9695f6163aa539b9e3a933367c98850257c6d7bb8d61b36fd5f83b3ab61746f7",
|
|
48
51
|
},
|
|
49
52
|
{
|
|
50
53
|
id: "package-signature-schema",
|
|
@@ -54,9 +57,9 @@ export const redevPluginContractArtifacts = [
|
|
|
54
57
|
},
|
|
55
58
|
{
|
|
56
59
|
id: "release-metadata-schema",
|
|
57
|
-
path: "spec/plugin/release-metadata-
|
|
58
|
-
version: "release-metadata-
|
|
59
|
-
sha256: "
|
|
60
|
+
path: "spec/plugin/release-metadata-v5.schema.json",
|
|
61
|
+
version: "release-metadata-v5",
|
|
62
|
+
sha256: "255ef3deb7d2758a43e69e533a08aa28106f8edc2e7385ab0aec0d50c1ef3d7a",
|
|
60
63
|
},
|
|
61
64
|
{
|
|
62
65
|
id: "source-policy-schema",
|
|
@@ -72,51 +75,51 @@ export const redevPluginContractArtifacts = [
|
|
|
72
75
|
},
|
|
73
76
|
{
|
|
74
77
|
id: "token-ticket-schema",
|
|
75
|
-
path: "spec/plugin/token-ticket-
|
|
76
|
-
version: "token-ticket-
|
|
77
|
-
sha256: "
|
|
78
|
+
path: "spec/plugin/token-ticket-v3.schema.json",
|
|
79
|
+
version: "token-ticket-v3",
|
|
80
|
+
sha256: "17c7f2e7c7fcaa0eb43da7ecd92e4f36a918cc8149eec031d0231191d9245f16",
|
|
78
81
|
},
|
|
79
82
|
{
|
|
80
83
|
id: "iframe-bridge-schema",
|
|
81
|
-
path: "spec/plugin/bridge-
|
|
82
|
-
version: "bridge-
|
|
83
|
-
sha256: "
|
|
84
|
+
path: "spec/plugin/bridge-v5.schema.json",
|
|
85
|
+
version: "bridge-v5",
|
|
86
|
+
sha256: "b7bfeaad2eb34440881889d608297ef941e4d4a46c914c6bd19dfe4331d59729",
|
|
84
87
|
},
|
|
85
88
|
{
|
|
86
89
|
id: "opaque-surface-document-schema",
|
|
87
|
-
path: "spec/plugin/opaque-surface-document-
|
|
88
|
-
version: "opaque-surface-document-
|
|
89
|
-
sha256: "
|
|
90
|
+
path: "spec/plugin/opaque-surface-document-v3.schema.json",
|
|
91
|
+
version: "opaque-surface-document-v3",
|
|
92
|
+
sha256: "63419ff5b5a8890e14f97ca29aaae175b93daff61d4567c5bdff7f6e6a9e7450",
|
|
90
93
|
},
|
|
91
94
|
{
|
|
92
95
|
id: "opaque-surface-transport-schema",
|
|
93
|
-
path: "spec/plugin/opaque-surface-transport-
|
|
94
|
-
version: "opaque-surface-transport-
|
|
95
|
-
sha256: "
|
|
96
|
+
path: "spec/plugin/opaque-surface-transport-v4.schema.json",
|
|
97
|
+
version: "opaque-surface-transport-v4",
|
|
98
|
+
sha256: "70a32dc8bf281cea2c92492c466fd477070c62156a3f593d45eb460cde62dca2",
|
|
96
99
|
},
|
|
97
100
|
{
|
|
98
101
|
id: "compatibility-manifest-schema",
|
|
99
|
-
path: "spec/plugin/compatibility-manifest-
|
|
100
|
-
version: "compatibility-manifest-
|
|
101
|
-
sha256: "
|
|
102
|
+
path: "spec/plugin/compatibility-manifest-v6.schema.json",
|
|
103
|
+
version: "compatibility-manifest-v6",
|
|
104
|
+
sha256: "4f9e2a42c5a4893afad4027a5f29e4fc37843f450451dc5db26ac7919166a0db",
|
|
102
105
|
},
|
|
103
106
|
{
|
|
104
107
|
id: "release-manifest-schema",
|
|
105
|
-
path: "spec/plugin/release-manifest-
|
|
106
|
-
version: "release-manifest-
|
|
107
|
-
sha256: "
|
|
108
|
+
path: "spec/plugin/release-manifest-v4.schema.json",
|
|
109
|
+
version: "release-manifest-v4",
|
|
110
|
+
sha256: "b0a9e95b7bc819ee2a17a2d0bc4105b524e138945c11a19c77306a0a5351d63f",
|
|
108
111
|
},
|
|
109
112
|
{
|
|
110
113
|
id: "worker-invocation-schema",
|
|
111
|
-
path: "spec/plugin/worker-invocation-
|
|
112
|
-
version: "worker-invocation-
|
|
113
|
-
sha256: "
|
|
114
|
+
path: "spec/plugin/worker-invocation-v3.schema.json",
|
|
115
|
+
version: "worker-invocation-v3",
|
|
116
|
+
sha256: "f08af491cbf5e7b71d1aeafbeac9ae581ee5fc3bcb76184daec369f94bab3927",
|
|
114
117
|
},
|
|
115
118
|
{
|
|
116
119
|
id: "host-capability-contract-schema",
|
|
117
120
|
path: "spec/plugin/host-capability-contract-v1.schema.json",
|
|
118
121
|
version: "host-capability-contract-v1",
|
|
119
|
-
sha256: "
|
|
122
|
+
sha256: "0a653e36d44104f1d16b06ee424648086c146f23c907b176bdf470ae73025485",
|
|
120
123
|
},
|
|
121
124
|
{
|
|
122
125
|
id: "host-capability-pin-schema",
|
|
@@ -150,38 +153,56 @@ export const redevPluginContractArtifacts = [
|
|
|
150
153
|
},
|
|
151
154
|
{
|
|
152
155
|
id: "error-codes-schema",
|
|
153
|
-
path: "spec/plugin/error-codes-
|
|
154
|
-
version: "error-codes-
|
|
155
|
-
sha256: "
|
|
156
|
+
path: "spec/plugin/error-codes-v4.schema.json",
|
|
157
|
+
version: "error-codes-v4",
|
|
158
|
+
sha256: "97149dc2f24fcd5ce337e6b4032a90edc2f0f945dc3c575b4310950372a5dd07",
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
id: "performance-contract",
|
|
162
|
+
path: "spec/plugin/performance-contract-v1.json",
|
|
163
|
+
version: "performance-contract-v1",
|
|
164
|
+
sha256: "93f54632e327c62a83947b30fd073ebf7640293ca9953872be1c22f2642e68d8",
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
id: "performance-evidence-schema",
|
|
168
|
+
path: "spec/plugin/performance-evidence-v1.schema.json",
|
|
169
|
+
version: "performance-evidence-v1",
|
|
170
|
+
sha256: "99bd635c97886f382090d4d8cac13ac499e81c7b236338b53a96dc94e9063a59",
|
|
156
171
|
},
|
|
157
172
|
{
|
|
158
173
|
id: "rust-ipc-schema",
|
|
159
|
-
path: "spec/plugin/ipc-
|
|
160
|
-
version: "rust-ipc-
|
|
161
|
-
sha256: "
|
|
174
|
+
path: "spec/plugin/ipc-v4.schema.json",
|
|
175
|
+
version: "rust-ipc-v4",
|
|
176
|
+
sha256: "eb66a442f1c45b8c75a0232f68632df8fb07929addc6da5b2f79970adf77662c",
|
|
162
177
|
},
|
|
163
178
|
{
|
|
164
179
|
id: "wasm-worker-schema",
|
|
165
180
|
path: "spec/plugin/wasm-worker-v2.schema.json",
|
|
166
181
|
version: "redevplugin-wasm-worker-v2",
|
|
167
|
-
sha256: "
|
|
182
|
+
sha256: "00bf123f3a9ed932de4b71c180e2a5c34af0f82050defb271fedec42cf217902",
|
|
168
183
|
},
|
|
169
184
|
{
|
|
170
185
|
id: "network-grant-schema",
|
|
171
|
-
path: "spec/plugin/network-grant-
|
|
172
|
-
version: "network-grant-
|
|
173
|
-
sha256: "
|
|
186
|
+
path: "spec/plugin/network-grant-v2.schema.json",
|
|
187
|
+
version: "network-grant-v2",
|
|
188
|
+
sha256: "5fc1cfc3469a992e551fd392fab982abb6f95e456a1cb768ceca137f7c693abc",
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
id: "resource-scope-schema",
|
|
192
|
+
path: "spec/plugin/resource-scope-v1.schema.json",
|
|
193
|
+
version: "resource-scope-v1",
|
|
194
|
+
sha256: "e6021bd576c7220ad5536645a7ad8e57ee7aeb9901c31a89444fa6b695d8dc6f",
|
|
174
195
|
},
|
|
175
196
|
{
|
|
176
197
|
id: "target-classifier-fixture",
|
|
177
|
-
path: "spec/plugin/target-classifier-
|
|
178
|
-
version: "target-classifier-
|
|
179
|
-
sha256: "
|
|
198
|
+
path: "spec/plugin/target-classifier-v2.json",
|
|
199
|
+
version: "target-classifier-v2",
|
|
200
|
+
sha256: "ae7336cce77a2e820f96f1cc309b93f8442c932dcebec25e3890d31cd098e2d1",
|
|
180
201
|
},
|
|
181
202
|
{
|
|
182
203
|
id: "contract-registry",
|
|
183
204
|
path: "spec/plugin/contract-registry-v1.json",
|
|
184
205
|
version: "contract-registry-v1",
|
|
185
|
-
sha256: "
|
|
206
|
+
sha256: "86cc5ccce02ef00b6cf8b44af07ad3a82867ee039d8d82ffc704194ee2c62547",
|
|
186
207
|
},
|
|
187
208
|
];
|