@astrale-os/kernel-core 0.9.0-beta.54 → 0.9.0-beta.56
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/auth/authority/admission/admission.d.ts +2 -0
- package/dist/auth/authority/admission/admission.js +4 -0
- package/dist/auth/authority/admission/index.d.ts +1 -1
- package/dist/auth/authority/admission/index.js +1 -1
- package/dist/auth/authority/index.d.ts +2 -0
- package/dist/auth/authority/index.js +2 -0
- package/dist/auth/authority/normalization/index.d.ts +1 -1
- package/dist/auth/authority/normalization/index.js +1 -1
- package/dist/auth/authority/normalization/normalize.d.ts +2 -0
- package/dist/auth/authority/normalization/normalize.js +4 -0
- package/dist/auth/authority/prepare-grant-body.d.ts +4 -0
- package/dist/auth/authority/prepare-grant-body.js +27 -0
- package/dist/callable/contract/body.d.ts +10 -0
- package/dist/callable/contract/body.js +7 -0
- package/dist/callable/contract/index.d.ts +2 -1
- package/dist/callable/contract/index.js +1 -1
- package/dist/callable/contract/output.d.ts +8 -0
- package/dist/callable/index.d.ts +2 -1
- package/dist/callable/index.js +1 -0
- package/dist/schema/callables/execution.d.ts +269 -0
- package/dist/schema/callables/execution.js +30 -0
- package/dist/schema/callables/function.d.ts +212 -212
- package/dist/schema/callables/index.d.ts +1 -0
- package/dist/schema/callables/index.js +1 -0
- package/dist/schema/callables/view.d.ts +2 -2
- package/dist/schema/domain/domain.d.ts +417 -417
- package/dist/schema/identity/identity.d.ts +14 -14
- package/dist/schema/kernel/schema.d.ts +1140 -782
- package/dist/schema/kernel/schema.js +6 -2
- package/dist/schema/kernel/syscalls/contracts/blob.d.ts +21 -0
- package/dist/schema/kernel/syscalls/contracts/blob.js +16 -0
- package/dist/schema/kernel/syscalls/contracts/delegate.d.ts +1 -1
- package/dist/schema/kernel/syscalls/contracts/delegate.js +2 -1
- package/dist/schema/kernel/syscalls/contracts/execution.d.ts +60 -0
- package/dist/schema/kernel/syscalls/contracts/execution.js +46 -0
- package/dist/schema/kernel/syscalls/contracts/index.d.ts +2 -0
- package/dist/schema/kernel/syscalls/contracts/index.js +2 -0
- package/dist/schema/kernel/syscalls/declarations/admit.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/can.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/delegate.d.ts +2 -2
- package/dist/schema/kernel/syscalls/declarations/download.d.ts +7 -0
- package/dist/schema/kernel/syscalls/declarations/download.js +10 -0
- package/dist/schema/kernel/syscalls/declarations/execution.d.ts +105 -0
- package/dist/schema/kernel/syscalls/declarations/execution.js +52 -0
- package/dist/schema/kernel/syscalls/declarations/impersonate.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/index.d.ts +165 -39
- package/dist/schema/kernel/syscalls/declarations/index.js +13 -0
- package/dist/schema/kernel/syscalls/declarations/install.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/introspect.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/journal.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/mint.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/mutate.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/query.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/register.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/uninstall.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/upload.d.ts +15 -0
- package/dist/schema/kernel/syscalls/declarations/upload.js +10 -0
- package/dist/schema/kernel/syscalls/declarations/view-resolve.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/whoami.d.ts +1 -1
- package/dist/schema/kernel/syscalls/declarations/whois.d.ts +1 -1
- package/dist/schema/kernel/syscalls/descriptors/execution.d.ts +153 -0
- package/dist/schema/kernel/syscalls/descriptors/execution.js +11 -0
- package/dist/schema/kernel/syscalls/descriptors/function.d.ts +1 -0
- package/dist/schema/kernel/syscalls/descriptors/functions.d.ts +2 -0
- package/dist/schema/kernel/syscalls/descriptors/functions.js +2 -0
- package/dist/schema/kernel/syscalls/descriptors/identity.d.ts +7 -1
- package/dist/schema/kernel/syscalls/descriptors/index.d.ts +2 -1
- package/dist/schema/kernel/syscalls/descriptors/index.js +2 -1
- package/dist/schema/kernel/syscalls/descriptors/view.d.ts +1 -0
- package/dist/schema/kernel/syscalls/index.d.ts +2 -2
- package/dist/schema/kernel/syscalls/index.js +2 -2
- package/dist/schema/kernel/syscalls/references/execution.d.ts +55 -0
- package/dist/schema/kernel/syscalls/references/execution.js +13 -0
- package/dist/schema/kernel/syscalls/references/functions.d.ts +10 -0
- package/dist/schema/kernel/syscalls/references/functions.js +2 -0
- package/dist/schema/kernel/syscalls/references/index.d.ts +2 -1
- package/dist/schema/kernel/syscalls/references/index.js +2 -1
- package/dist/schema/meta/created-by.d.ts +32 -0
- package/dist/schema/meta/created-by.js +17 -0
- package/dist/schema/meta/index.d.ts +1 -0
- package/dist/schema/meta/index.js +1 -0
- package/package.json +2 -2
|
@@ -222,7 +222,27 @@ export declare const Functions: Readonly<{
|
|
|
222
222
|
next?: string | undefined;
|
|
223
223
|
};
|
|
224
224
|
};
|
|
225
|
-
}, "authorized", false, false>>;
|
|
225
|
+
}, "authorized", false, false, undefined>>;
|
|
226
|
+
upload: builder.Function<builder.CallableProjection<import("@astrale-os/kernel-dsl/v1").BinaryInputProjection<{
|
|
227
|
+
mediaType: string;
|
|
228
|
+
}>, {
|
|
229
|
+
readonly mode: 'value';
|
|
230
|
+
readonly value: {
|
|
231
|
+
receipt: string;
|
|
232
|
+
ref: {
|
|
233
|
+
digest: string;
|
|
234
|
+
mediaType: string;
|
|
235
|
+
size: number;
|
|
236
|
+
};
|
|
237
|
+
expiresAt: string;
|
|
238
|
+
};
|
|
239
|
+
}, "authorized", false, false, undefined>>;
|
|
240
|
+
download: builder.Function<builder.CallableProjection<{
|
|
241
|
+
node: string;
|
|
242
|
+
property: string;
|
|
243
|
+
}, {
|
|
244
|
+
readonly mode: 'binary';
|
|
245
|
+
}, "authorized", false, false, undefined>>;
|
|
226
246
|
mutate: builder.Function<builder.CallableProjection<{
|
|
227
247
|
ast: {
|
|
228
248
|
format: "astrale.graph.mutation";
|
|
@@ -379,6 +399,29 @@ export declare const Functions: Readonly<{
|
|
|
379
399
|
};
|
|
380
400
|
})[];
|
|
381
401
|
operations: ({
|
|
402
|
+
op: "edge.update";
|
|
403
|
+
edge: {
|
|
404
|
+
source: string;
|
|
405
|
+
target: string;
|
|
406
|
+
class: string;
|
|
407
|
+
};
|
|
408
|
+
slug: unknown;
|
|
409
|
+
props?: {
|
|
410
|
+
set: Record<string, unknown>;
|
|
411
|
+
unset: string[];
|
|
412
|
+
} | undefined;
|
|
413
|
+
} | {
|
|
414
|
+
op: "edge.update";
|
|
415
|
+
edge: {
|
|
416
|
+
source: string;
|
|
417
|
+
target: string;
|
|
418
|
+
class: string;
|
|
419
|
+
};
|
|
420
|
+
props: {
|
|
421
|
+
set: Record<string, unknown>;
|
|
422
|
+
unset: string[];
|
|
423
|
+
};
|
|
424
|
+
} | {
|
|
382
425
|
op: "node.create";
|
|
383
426
|
as: string;
|
|
384
427
|
class: string;
|
|
@@ -406,29 +449,6 @@ export declare const Functions: Readonly<{
|
|
|
406
449
|
};
|
|
407
450
|
slug?: unknown;
|
|
408
451
|
props: Record<string, unknown>;
|
|
409
|
-
} | {
|
|
410
|
-
op: "edge.update";
|
|
411
|
-
edge: {
|
|
412
|
-
source: string;
|
|
413
|
-
target: string;
|
|
414
|
-
class: string;
|
|
415
|
-
};
|
|
416
|
-
slug: unknown;
|
|
417
|
-
props?: {
|
|
418
|
-
set: Record<string, unknown>;
|
|
419
|
-
unset: string[];
|
|
420
|
-
} | undefined;
|
|
421
|
-
} | {
|
|
422
|
-
op: "edge.update";
|
|
423
|
-
edge: {
|
|
424
|
-
source: string;
|
|
425
|
-
target: string;
|
|
426
|
-
class: string;
|
|
427
|
-
};
|
|
428
|
-
props: {
|
|
429
|
-
set: Record<string, unknown>;
|
|
430
|
-
unset: string[];
|
|
431
|
-
};
|
|
432
452
|
} | {
|
|
433
453
|
op: "edge.delete";
|
|
434
454
|
edge: {
|
|
@@ -447,7 +467,7 @@ export declare const Functions: Readonly<{
|
|
|
447
467
|
readonly value: {
|
|
448
468
|
createdNodes: Record<string, string>;
|
|
449
469
|
};
|
|
450
|
-
}, "authorized", false, false>>;
|
|
470
|
+
}, "authorized", false, false, undefined>>;
|
|
451
471
|
register: builder.Function<builder.CallableProjection<{
|
|
452
472
|
idempotencyKey: string;
|
|
453
473
|
identities: ({
|
|
@@ -469,7 +489,7 @@ export declare const Functions: Readonly<{
|
|
|
469
489
|
sub: string;
|
|
470
490
|
}[];
|
|
471
491
|
};
|
|
472
|
-
}, "authorized", false, false>>;
|
|
492
|
+
}, "authorized", false, false, undefined>>;
|
|
473
493
|
install: builder.Function<builder.CallableProjection<{
|
|
474
494
|
operation: string;
|
|
475
495
|
domains: ({
|
|
@@ -490,13 +510,13 @@ export declare const Functions: Readonly<{
|
|
|
490
510
|
})[];
|
|
491
511
|
}, {
|
|
492
512
|
readonly mode: 'binary';
|
|
493
|
-
}, "authorized", false, false>>;
|
|
513
|
+
}, "authorized", false, false, undefined>>;
|
|
494
514
|
introspect: builder.Function<builder.CallableProjection<{
|
|
495
515
|
kind: "bundle" | "dependencies" | "inspect";
|
|
496
516
|
origin: string;
|
|
497
517
|
}, {
|
|
498
518
|
readonly mode: 'binary';
|
|
499
|
-
}, "authenticated", false, false>>;
|
|
519
|
+
}, "authenticated", false, false, undefined>>;
|
|
500
520
|
uninstall: builder.Function<builder.CallableProjection<{
|
|
501
521
|
operation: string;
|
|
502
522
|
domains: string[];
|
|
@@ -537,7 +557,7 @@ export declare const Functions: Readonly<{
|
|
|
537
557
|
} | undefined;
|
|
538
558
|
}[];
|
|
539
559
|
};
|
|
540
|
-
}, "authorized", false, false>>;
|
|
560
|
+
}, "authorized", false, false, undefined>>;
|
|
541
561
|
journal: builder.Function<builder.CallableProjection<{
|
|
542
562
|
invocation?: {
|
|
543
563
|
source: string;
|
|
@@ -565,18 +585,18 @@ export declare const Functions: Readonly<{
|
|
|
565
585
|
cursor?: string | undefined;
|
|
566
586
|
gap?: unknown;
|
|
567
587
|
};
|
|
568
|
-
}, "authorized", false, false>>;
|
|
588
|
+
}, "authorized", false, false, undefined>>;
|
|
569
589
|
}>;
|
|
570
590
|
export declare const IdentityMethods: Readonly<{
|
|
571
591
|
delegate: builder.Method<builder.CallableProjection<{
|
|
572
592
|
principal: string;
|
|
573
593
|
audience: string;
|
|
574
594
|
ttlSeconds: number;
|
|
575
|
-
attenuation
|
|
595
|
+
attenuation?: unknown;
|
|
576
596
|
}, {
|
|
577
597
|
readonly mode: 'value';
|
|
578
598
|
readonly value: string;
|
|
579
|
-
}, "authenticated", true, false>>;
|
|
599
|
+
}, "authenticated", true, false, undefined>>;
|
|
580
600
|
can: builder.Method<builder.CallableProjection<{
|
|
581
601
|
policy: string;
|
|
582
602
|
object: string;
|
|
@@ -594,7 +614,7 @@ export declare const IdentityMethods: Readonly<{
|
|
|
594
614
|
allowed: boolean;
|
|
595
615
|
}[];
|
|
596
616
|
};
|
|
597
|
-
}, "authenticated", true, false>>;
|
|
617
|
+
}, "authenticated", true, false, undefined>>;
|
|
598
618
|
whoami: builder.Method<builder.CallableProjection<Record<string, never>, {
|
|
599
619
|
readonly mode: 'value';
|
|
600
620
|
readonly value: {
|
|
@@ -615,7 +635,7 @@ export declare const IdentityMethods: Readonly<{
|
|
|
615
635
|
op: "exists";
|
|
616
636
|
})[];
|
|
617
637
|
};
|
|
618
|
-
}, "authenticated", true, false>>;
|
|
638
|
+
}, "authenticated", true, false, undefined>>;
|
|
619
639
|
whois: builder.Method<builder.CallableProjection<{
|
|
620
640
|
iss: string;
|
|
621
641
|
sub: string;
|
|
@@ -639,7 +659,7 @@ export declare const IdentityMethods: Readonly<{
|
|
|
639
659
|
op: "exists";
|
|
640
660
|
})[];
|
|
641
661
|
} | null;
|
|
642
|
-
}, "authorized", true, false>>;
|
|
662
|
+
}, "authorized", true, false, undefined>>;
|
|
643
663
|
mint: builder.Method<builder.CallableProjection<{
|
|
644
664
|
audience?: string | undefined;
|
|
645
665
|
ttlSeconds: number;
|
|
@@ -647,7 +667,7 @@ export declare const IdentityMethods: Readonly<{
|
|
|
647
667
|
}, {
|
|
648
668
|
readonly mode: 'value';
|
|
649
669
|
readonly value: string;
|
|
650
|
-
}, "authenticated", true, false>>;
|
|
670
|
+
}, "authenticated", true, false, undefined>>;
|
|
651
671
|
impersonate: builder.Method<builder.CallableProjection<{
|
|
652
672
|
audience?: string | undefined;
|
|
653
673
|
ttlSeconds: number;
|
|
@@ -656,7 +676,7 @@ export declare const IdentityMethods: Readonly<{
|
|
|
656
676
|
}, {
|
|
657
677
|
readonly mode: 'value';
|
|
658
678
|
readonly value: string;
|
|
659
|
-
}, "authorized", true, false>>;
|
|
679
|
+
}, "authorized", true, false, undefined>>;
|
|
660
680
|
}>;
|
|
661
681
|
export declare const FunctionMethods: Readonly<{
|
|
662
682
|
admit: builder.Method<builder.CallableProjection<{
|
|
@@ -676,7 +696,7 @@ export declare const FunctionMethods: Readonly<{
|
|
|
676
696
|
callable: string;
|
|
677
697
|
receiver?: string | undefined;
|
|
678
698
|
};
|
|
679
|
-
}, "authenticated", true, false>>;
|
|
699
|
+
}, "authenticated", true, false, undefined>>;
|
|
680
700
|
}>;
|
|
681
701
|
export declare const ViewMethods: Readonly<{
|
|
682
702
|
resolve: builder.Method<builder.CallableProjection<{
|
|
@@ -718,6 +738,112 @@ export declare const ViewMethods: Readonly<{
|
|
|
718
738
|
revision: string;
|
|
719
739
|
}[];
|
|
720
740
|
};
|
|
721
|
-
}, "authorized", true, false>>;
|
|
741
|
+
}, "authorized", true, false, undefined>>;
|
|
742
|
+
}>;
|
|
743
|
+
export declare const ExecutionMethods: Readonly<{
|
|
744
|
+
status: builder.Method<builder.CallableProjection<Record<string, never>, {
|
|
745
|
+
readonly mode: 'value';
|
|
746
|
+
readonly value: {
|
|
747
|
+
id: string;
|
|
748
|
+
function: string;
|
|
749
|
+
version: string;
|
|
750
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
751
|
+
createdAt: string;
|
|
752
|
+
outcome?: {
|
|
753
|
+
kind: "completed";
|
|
754
|
+
value: unknown;
|
|
755
|
+
} | {
|
|
756
|
+
kind: "failed";
|
|
757
|
+
error: {
|
|
758
|
+
code: string;
|
|
759
|
+
message: string;
|
|
760
|
+
family?: string | undefined;
|
|
761
|
+
details?: unknown;
|
|
762
|
+
};
|
|
763
|
+
} | {
|
|
764
|
+
kind: "cancelled";
|
|
765
|
+
} | undefined;
|
|
766
|
+
};
|
|
767
|
+
}, "authenticated", false, false, undefined>>;
|
|
768
|
+
result: builder.Method<builder.CallableProjection<{
|
|
769
|
+
waitMs?: number | undefined;
|
|
770
|
+
}, {
|
|
771
|
+
readonly mode: 'value';
|
|
772
|
+
readonly value: {
|
|
773
|
+
kind: "completed";
|
|
774
|
+
value: unknown;
|
|
775
|
+
} | {
|
|
776
|
+
kind: "failed";
|
|
777
|
+
error: {
|
|
778
|
+
code: string;
|
|
779
|
+
message: string;
|
|
780
|
+
family?: string | undefined;
|
|
781
|
+
details?: unknown;
|
|
782
|
+
};
|
|
783
|
+
} | {
|
|
784
|
+
kind: "cancelled";
|
|
785
|
+
};
|
|
786
|
+
}, "authenticated", false, false, undefined>>;
|
|
787
|
+
cancel: builder.Method<builder.CallableProjection<{
|
|
788
|
+
force?: boolean | undefined;
|
|
789
|
+
}, {
|
|
790
|
+
readonly mode: 'value';
|
|
791
|
+
readonly value: {
|
|
792
|
+
id: string;
|
|
793
|
+
function: string;
|
|
794
|
+
version: string;
|
|
795
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
796
|
+
createdAt: string;
|
|
797
|
+
outcome?: {
|
|
798
|
+
kind: "completed";
|
|
799
|
+
value: unknown;
|
|
800
|
+
} | {
|
|
801
|
+
kind: "failed";
|
|
802
|
+
error: {
|
|
803
|
+
code: string;
|
|
804
|
+
message: string;
|
|
805
|
+
family?: string | undefined;
|
|
806
|
+
details?: unknown;
|
|
807
|
+
};
|
|
808
|
+
} | {
|
|
809
|
+
kind: "cancelled";
|
|
810
|
+
} | undefined;
|
|
811
|
+
};
|
|
812
|
+
}, "authenticated", false, false, undefined>>;
|
|
813
|
+
signal: builder.Method<builder.CallableProjection<{
|
|
814
|
+
name: string;
|
|
815
|
+
value: unknown;
|
|
816
|
+
}, {
|
|
817
|
+
readonly mode: 'value';
|
|
818
|
+
readonly value: Record<string, never>;
|
|
819
|
+
}, "authenticated", false, false, undefined>>;
|
|
820
|
+
resume: builder.Method<builder.CallableProjection<Record<string, never>, {
|
|
821
|
+
readonly mode: 'value';
|
|
822
|
+
readonly value: {
|
|
823
|
+
id: string;
|
|
824
|
+
function: string;
|
|
825
|
+
version: string;
|
|
826
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
827
|
+
createdAt: string;
|
|
828
|
+
outcome?: {
|
|
829
|
+
kind: "completed";
|
|
830
|
+
value: unknown;
|
|
831
|
+
} | {
|
|
832
|
+
kind: "failed";
|
|
833
|
+
error: {
|
|
834
|
+
code: string;
|
|
835
|
+
message: string;
|
|
836
|
+
family?: string | undefined;
|
|
837
|
+
details?: unknown;
|
|
838
|
+
};
|
|
839
|
+
} | {
|
|
840
|
+
kind: "cancelled";
|
|
841
|
+
} | undefined;
|
|
842
|
+
};
|
|
843
|
+
}, "authenticated", false, false, undefined>>;
|
|
844
|
+
delete: builder.Method<builder.CallableProjection<Record<string, never>, {
|
|
845
|
+
readonly mode: 'value';
|
|
846
|
+
readonly value: Record<string, never>;
|
|
847
|
+
}, "authenticated", false, false, undefined>>;
|
|
722
848
|
}>;
|
|
723
849
|
export { CanUseSyscall } from './use-policy.js';
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { Admit } from './admit.js';
|
|
2
2
|
import { Can } from './can.js';
|
|
3
3
|
import { Delegate } from './delegate.js';
|
|
4
|
+
import { Download } from './download.js';
|
|
5
|
+
import { ExecutionCancel, ExecutionDelete, ExecutionResult, ExecutionResume, ExecutionSignal, ExecutionStatus, } from './execution.js';
|
|
4
6
|
import { Impersonate } from './impersonate.js';
|
|
5
7
|
import { Install } from './install.js';
|
|
6
8
|
import { Introspect } from './introspect.js';
|
|
@@ -10,11 +12,14 @@ import { Mutate } from './mutate.js';
|
|
|
10
12
|
import { Query } from './query.js';
|
|
11
13
|
import { Register } from './register.js';
|
|
12
14
|
import { Uninstall } from './uninstall.js';
|
|
15
|
+
import { Upload } from './upload.js';
|
|
13
16
|
import { ViewResolve } from './view-resolve.js';
|
|
14
17
|
import { Whoami } from './whoami.js';
|
|
15
18
|
import { Whois } from './whois.js';
|
|
16
19
|
export const Functions = Object.freeze({
|
|
17
20
|
query: Query,
|
|
21
|
+
upload: Upload,
|
|
22
|
+
download: Download,
|
|
18
23
|
mutate: Mutate,
|
|
19
24
|
register: Register,
|
|
20
25
|
install: Install,
|
|
@@ -36,4 +41,12 @@ export const FunctionMethods = Object.freeze({
|
|
|
36
41
|
export const ViewMethods = Object.freeze({
|
|
37
42
|
resolve: ViewResolve,
|
|
38
43
|
});
|
|
44
|
+
export const ExecutionMethods = Object.freeze({
|
|
45
|
+
status: ExecutionStatus,
|
|
46
|
+
result: ExecutionResult,
|
|
47
|
+
cancel: ExecutionCancel,
|
|
48
|
+
signal: ExecutionSignal,
|
|
49
|
+
resume: ExecutionResume,
|
|
50
|
+
delete: ExecutionDelete,
|
|
51
|
+
});
|
|
39
52
|
export { CanUseSyscall } from './use-policy.js';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type builder } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
export declare const Upload: builder.Function<builder.CallableProjection<import("@astrale-os/kernel-dsl/v1").BinaryInputProjection<{
|
|
3
|
+
mediaType: string;
|
|
4
|
+
}>, {
|
|
5
|
+
readonly mode: 'value';
|
|
6
|
+
readonly value: {
|
|
7
|
+
receipt: string;
|
|
8
|
+
ref: {
|
|
9
|
+
digest: string;
|
|
10
|
+
mediaType: string;
|
|
11
|
+
size: number;
|
|
12
|
+
};
|
|
13
|
+
expiresAt: string;
|
|
14
|
+
};
|
|
15
|
+
}, "authorized", false, false, undefined>>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { func, input } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import { MAXIMUM_BLOB_BYTES, uploadInput, uploadOutput } from '../contracts/index.js';
|
|
3
|
+
import { usePolicy } from './use-policy.js';
|
|
4
|
+
export const Upload = func({
|
|
5
|
+
description: 'Store application bytes in an upload receipt.',
|
|
6
|
+
auth: 'authorized',
|
|
7
|
+
policy: usePolicy(() => Upload),
|
|
8
|
+
input: input.binary(uploadInput, { maximumBytes: MAXIMUM_BLOB_BYTES }),
|
|
9
|
+
output: uploadOutput,
|
|
10
|
+
});
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
export declare const status: import("./model.js").MethodSyscall<Readonly<{
|
|
2
|
+
origin: 'kernel.astrale.ai';
|
|
3
|
+
kind: 'class';
|
|
4
|
+
name: 'Execution';
|
|
5
|
+
}>, "status", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<Record<string, never>, {
|
|
6
|
+
readonly mode: 'value';
|
|
7
|
+
readonly value: {
|
|
8
|
+
id: string;
|
|
9
|
+
function: string;
|
|
10
|
+
version: string;
|
|
11
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
12
|
+
createdAt: string;
|
|
13
|
+
outcome?: {
|
|
14
|
+
kind: "completed";
|
|
15
|
+
value: unknown;
|
|
16
|
+
} | {
|
|
17
|
+
kind: "failed";
|
|
18
|
+
error: {
|
|
19
|
+
code: string;
|
|
20
|
+
message: string;
|
|
21
|
+
family?: string | undefined;
|
|
22
|
+
details?: unknown;
|
|
23
|
+
};
|
|
24
|
+
} | {
|
|
25
|
+
kind: "cancelled";
|
|
26
|
+
} | undefined;
|
|
27
|
+
};
|
|
28
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.status"> & {
|
|
29
|
+
readonly name: "status";
|
|
30
|
+
readonly executable: true;
|
|
31
|
+
readonly execution: undefined;
|
|
32
|
+
}>;
|
|
33
|
+
export declare const result: import("./model.js").MethodSyscall<Readonly<{
|
|
34
|
+
origin: 'kernel.astrale.ai';
|
|
35
|
+
kind: 'class';
|
|
36
|
+
name: 'Execution';
|
|
37
|
+
}>, "result", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<{
|
|
38
|
+
waitMs?: number | undefined;
|
|
39
|
+
}, {
|
|
40
|
+
readonly mode: 'value';
|
|
41
|
+
readonly value: {
|
|
42
|
+
kind: "completed";
|
|
43
|
+
value: unknown;
|
|
44
|
+
} | {
|
|
45
|
+
kind: "failed";
|
|
46
|
+
error: {
|
|
47
|
+
code: string;
|
|
48
|
+
message: string;
|
|
49
|
+
family?: string | undefined;
|
|
50
|
+
details?: unknown;
|
|
51
|
+
};
|
|
52
|
+
} | {
|
|
53
|
+
kind: "cancelled";
|
|
54
|
+
};
|
|
55
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.result"> & {
|
|
56
|
+
readonly name: "result";
|
|
57
|
+
readonly executable: true;
|
|
58
|
+
readonly execution: undefined;
|
|
59
|
+
}>;
|
|
60
|
+
export declare const cancel: import("./model.js").MethodSyscall<Readonly<{
|
|
61
|
+
origin: 'kernel.astrale.ai';
|
|
62
|
+
kind: 'class';
|
|
63
|
+
name: 'Execution';
|
|
64
|
+
}>, "cancel", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<{
|
|
65
|
+
force?: boolean | undefined;
|
|
66
|
+
}, {
|
|
67
|
+
readonly mode: 'value';
|
|
68
|
+
readonly value: {
|
|
69
|
+
id: string;
|
|
70
|
+
function: string;
|
|
71
|
+
version: string;
|
|
72
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
73
|
+
createdAt: string;
|
|
74
|
+
outcome?: {
|
|
75
|
+
kind: "completed";
|
|
76
|
+
value: unknown;
|
|
77
|
+
} | {
|
|
78
|
+
kind: "failed";
|
|
79
|
+
error: {
|
|
80
|
+
code: string;
|
|
81
|
+
message: string;
|
|
82
|
+
family?: string | undefined;
|
|
83
|
+
details?: unknown;
|
|
84
|
+
};
|
|
85
|
+
} | {
|
|
86
|
+
kind: "cancelled";
|
|
87
|
+
} | undefined;
|
|
88
|
+
};
|
|
89
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.cancel"> & {
|
|
90
|
+
readonly name: "cancel";
|
|
91
|
+
readonly executable: true;
|
|
92
|
+
readonly execution: undefined;
|
|
93
|
+
}>;
|
|
94
|
+
export declare const signal: import("./model.js").MethodSyscall<Readonly<{
|
|
95
|
+
origin: 'kernel.astrale.ai';
|
|
96
|
+
kind: 'class';
|
|
97
|
+
name: 'Execution';
|
|
98
|
+
}>, "signal", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<{
|
|
99
|
+
name: string;
|
|
100
|
+
value: unknown;
|
|
101
|
+
}, {
|
|
102
|
+
readonly mode: 'value';
|
|
103
|
+
readonly value: Record<string, never>;
|
|
104
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.signal"> & {
|
|
105
|
+
readonly name: "signal";
|
|
106
|
+
readonly executable: true;
|
|
107
|
+
readonly execution: undefined;
|
|
108
|
+
}>;
|
|
109
|
+
export declare const resume: import("./model.js").MethodSyscall<Readonly<{
|
|
110
|
+
origin: 'kernel.astrale.ai';
|
|
111
|
+
kind: 'class';
|
|
112
|
+
name: 'Execution';
|
|
113
|
+
}>, "resume", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<Record<string, never>, {
|
|
114
|
+
readonly mode: 'value';
|
|
115
|
+
readonly value: {
|
|
116
|
+
id: string;
|
|
117
|
+
function: string;
|
|
118
|
+
version: string;
|
|
119
|
+
state: "cancelled" | "completed" | "expired" | "failed" | "paused" | "pending" | "running" | "waiting";
|
|
120
|
+
createdAt: string;
|
|
121
|
+
outcome?: {
|
|
122
|
+
kind: "completed";
|
|
123
|
+
value: unknown;
|
|
124
|
+
} | {
|
|
125
|
+
kind: "failed";
|
|
126
|
+
error: {
|
|
127
|
+
code: string;
|
|
128
|
+
message: string;
|
|
129
|
+
family?: string | undefined;
|
|
130
|
+
details?: unknown;
|
|
131
|
+
};
|
|
132
|
+
} | {
|
|
133
|
+
kind: "cancelled";
|
|
134
|
+
} | undefined;
|
|
135
|
+
};
|
|
136
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.resume"> & {
|
|
137
|
+
readonly name: "resume";
|
|
138
|
+
readonly executable: true;
|
|
139
|
+
readonly execution: undefined;
|
|
140
|
+
}>;
|
|
141
|
+
declare const remove: import("./model.js").MethodSyscall<Readonly<{
|
|
142
|
+
origin: 'kernel.astrale.ai';
|
|
143
|
+
kind: 'class';
|
|
144
|
+
name: 'Execution';
|
|
145
|
+
}>, "delete", import("@astrale-os/kernel-dsl/v1").ResolvedMethod<Record<string, never>, {
|
|
146
|
+
readonly mode: 'value';
|
|
147
|
+
readonly value: Record<string, never>;
|
|
148
|
+
}, false, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Execution.method.delete"> & {
|
|
149
|
+
readonly name: "delete";
|
|
150
|
+
readonly executable: true;
|
|
151
|
+
readonly execution: undefined;
|
|
152
|
+
}>;
|
|
153
|
+
export { remove as delete };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { K } from '../../index.js';
|
|
2
|
+
import * as references from '../references/execution.js';
|
|
3
|
+
import { methodSyscall } from './model.js';
|
|
4
|
+
// Instance Methods: the handler receives the Execution receiver as `self`.
|
|
5
|
+
export const status = methodSyscall(references.status, K.classes.Execution.methods.status);
|
|
6
|
+
export const result = methodSyscall(references.result, K.classes.Execution.methods.result);
|
|
7
|
+
export const cancel = methodSyscall(references.cancel, K.classes.Execution.methods.cancel);
|
|
8
|
+
export const signal = methodSyscall(references.signal, K.classes.Execution.methods.signal);
|
|
9
|
+
export const resume = methodSyscall(references.resume, K.classes.Execution.methods.resume);
|
|
10
|
+
const remove = methodSyscall(references.delete, K.classes.Execution.methods.delete);
|
|
11
|
+
export { remove as delete };
|
|
@@ -20,6 +20,7 @@ declare const Admit: import("@astrale-os/kernel-dsl/v1").ResolvedMethod<{
|
|
|
20
20
|
}, true, false, "authenticated", import("@astrale-os/kernel-dsl/v1").PolicyCheckExpression<import("@astrale-os/kernel-dsl/v1").PolicyRef, import("@astrale-os/kernel-dsl/v1/language").PolicyCheckObject>, "kernel.astrale.ai:class.Function.method.admit"> & {
|
|
21
21
|
readonly name: "admit";
|
|
22
22
|
readonly executable: true;
|
|
23
|
+
readonly execution: undefined;
|
|
23
24
|
};
|
|
24
25
|
export declare const admit: MethodSyscall<ClassRef<'Function'> & {
|
|
25
26
|
readonly origin: 'kernel.astrale.ai';
|
|
@@ -7,3 +7,5 @@ export declare const install: FunctionSyscall<'kernel.astrale.ai', 'install', ty
|
|
|
7
7
|
export declare const introspect: FunctionSyscall<'kernel.astrale.ai', 'introspect', typeof K.functions.introspect>;
|
|
8
8
|
export declare const uninstall: FunctionSyscall<'kernel.astrale.ai', 'uninstall', typeof K.functions.uninstall>;
|
|
9
9
|
export declare const journal: FunctionSyscall<'kernel.astrale.ai', 'journal', typeof K.functions.journal>;
|
|
10
|
+
export declare const upload: FunctionSyscall<'kernel.astrale.ai', 'upload', typeof K.functions.upload>;
|
|
11
|
+
export declare const download: FunctionSyscall<'kernel.astrale.ai', 'download', typeof K.functions.download>;
|
|
@@ -8,3 +8,5 @@ export const install = functionSyscall(references.install, K.functions.install);
|
|
|
8
8
|
export const introspect = functionSyscall(references.introspect, K.functions.introspect);
|
|
9
9
|
export const uninstall = functionSyscall(references.uninstall, K.functions.uninstall);
|
|
10
10
|
export const journal = functionSyscall(references.journal, K.functions.journal);
|
|
11
|
+
export const upload = functionSyscall(references.upload, K.functions.upload);
|
|
12
|
+
export const download = functionSyscall(references.download, K.functions.download);
|