@terminal3/t3n-sdk 0.4.0 → 0.5.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.
Files changed (29) hide show
  1. package/README.md +2 -2
  2. package/dist/index.d.ts +29 -15
  3. package/dist/index.esm.js +1 -1
  4. package/dist/index.js +1 -1
  5. package/dist/src/client/handlers.d.ts +10 -1
  6. package/dist/src/client/transport.d.ts +4 -4
  7. package/dist/src/types/index.d.ts +9 -2
  8. package/dist/src/utils/logger.d.ts +4 -4
  9. package/dist/src/utils/redaction.d.ts +1 -1
  10. package/dist/src/wasm/interface.d.ts +1 -2
  11. package/dist/src/wasm/loader.d.ts +1 -1
  12. package/dist/wasm/generated/interfaces/component-session-cookie.d.ts +8 -0
  13. package/dist/wasm/generated/interfaces/component-session-session.d.ts +1 -2
  14. package/dist/wasm/generated/interfaces/wasi-cli-environment.d.ts +1 -1
  15. package/dist/wasm/generated/interfaces/wasi-cli-exit.d.ts +1 -1
  16. package/dist/wasm/generated/interfaces/wasi-cli-stderr.d.ts +1 -1
  17. package/dist/wasm/generated/interfaces/wasi-io-error.d.ts +2 -1
  18. package/dist/wasm/generated/interfaces/wasi-io-streams.d.ts +1 -11
  19. package/dist/wasm/generated/interfaces/wasi-random-random.d.ts +2 -0
  20. package/dist/wasm/generated/session.core.wasm +0 -0
  21. package/dist/wasm/generated/session.d.ts +7 -10
  22. package/dist/wasm/generated/session.js +239 -1674
  23. package/package.json +1 -1
  24. package/dist/wasm/generated/interfaces/wasi-cli-stdin.d.ts +0 -3
  25. package/dist/wasm/generated/interfaces/wasi-cli-stdout.d.ts +0 -3
  26. package/dist/wasm/generated/interfaces/wasi-clocks-wall-clock.d.ts +0 -5
  27. package/dist/wasm/generated/interfaces/wasi-filesystem-preopens.d.ts +0 -3
  28. package/dist/wasm/generated/interfaces/wasi-filesystem-types.d.ts +0 -124
  29. package/dist/wasm/generated/session.core2.wasm +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@terminal3/t3n-sdk",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "type": "module",
5
5
  "description": "T3n TypeScript SDK - A minimal SDK that mirrors the server's RPC handler approach",
6
6
  "main": "dist/index.js",
@@ -1,3 +0,0 @@
1
- /** @module Interface wasi:cli/stdin@0.2.4 **/
2
- export function getStdin(): InputStream;
3
- export type InputStream = import('./wasi-io-streams.js').InputStream;
@@ -1,3 +0,0 @@
1
- /** @module Interface wasi:cli/stdout@0.2.4 **/
2
- export function getStdout(): OutputStream;
3
- export type OutputStream = import('./wasi-io-streams.js').OutputStream;
@@ -1,5 +0,0 @@
1
- /** @module Interface wasi:clocks/wall-clock@0.2.4 **/
2
- export interface Datetime {
3
- seconds: bigint,
4
- nanoseconds: number,
5
- }
@@ -1,3 +0,0 @@
1
- /** @module Interface wasi:filesystem/preopens@0.2.4 **/
2
- export function getDirectories(): Array<[Descriptor, string]>;
3
- export type Descriptor = import('./wasi-filesystem-types.js').Descriptor;
@@ -1,124 +0,0 @@
1
- /** @module Interface wasi:filesystem/types@0.2.4 **/
2
- export function filesystemErrorCode(err: Error): ErrorCode | undefined;
3
- export type Error = import('./wasi-io-streams.js').Error;
4
- /**
5
- * # Variants
6
- *
7
- * ## `"access"`
8
- *
9
- * ## `"would-block"`
10
- *
11
- * ## `"already"`
12
- *
13
- * ## `"bad-descriptor"`
14
- *
15
- * ## `"busy"`
16
- *
17
- * ## `"deadlock"`
18
- *
19
- * ## `"quota"`
20
- *
21
- * ## `"exist"`
22
- *
23
- * ## `"file-too-large"`
24
- *
25
- * ## `"illegal-byte-sequence"`
26
- *
27
- * ## `"in-progress"`
28
- *
29
- * ## `"interrupted"`
30
- *
31
- * ## `"invalid"`
32
- *
33
- * ## `"io"`
34
- *
35
- * ## `"is-directory"`
36
- *
37
- * ## `"loop"`
38
- *
39
- * ## `"too-many-links"`
40
- *
41
- * ## `"message-size"`
42
- *
43
- * ## `"name-too-long"`
44
- *
45
- * ## `"no-device"`
46
- *
47
- * ## `"no-entry"`
48
- *
49
- * ## `"no-lock"`
50
- *
51
- * ## `"insufficient-memory"`
52
- *
53
- * ## `"insufficient-space"`
54
- *
55
- * ## `"not-directory"`
56
- *
57
- * ## `"not-empty"`
58
- *
59
- * ## `"not-recoverable"`
60
- *
61
- * ## `"unsupported"`
62
- *
63
- * ## `"no-tty"`
64
- *
65
- * ## `"no-such-device"`
66
- *
67
- * ## `"overflow"`
68
- *
69
- * ## `"not-permitted"`
70
- *
71
- * ## `"pipe"`
72
- *
73
- * ## `"read-only"`
74
- *
75
- * ## `"invalid-seek"`
76
- *
77
- * ## `"text-file-busy"`
78
- *
79
- * ## `"cross-device"`
80
- */
81
- export type ErrorCode = 'access' | 'would-block' | 'already' | 'bad-descriptor' | 'busy' | 'deadlock' | 'quota' | 'exist' | 'file-too-large' | 'illegal-byte-sequence' | 'in-progress' | 'interrupted' | 'invalid' | 'io' | 'is-directory' | 'loop' | 'too-many-links' | 'message-size' | 'name-too-long' | 'no-device' | 'no-entry' | 'no-lock' | 'insufficient-memory' | 'insufficient-space' | 'not-directory' | 'not-empty' | 'not-recoverable' | 'unsupported' | 'no-tty' | 'no-such-device' | 'overflow' | 'not-permitted' | 'pipe' | 'read-only' | 'invalid-seek' | 'text-file-busy' | 'cross-device';
82
- export type Filesize = bigint;
83
- export type OutputStream = import('./wasi-io-streams.js').OutputStream;
84
- /**
85
- * # Variants
86
- *
87
- * ## `"unknown"`
88
- *
89
- * ## `"block-device"`
90
- *
91
- * ## `"character-device"`
92
- *
93
- * ## `"directory"`
94
- *
95
- * ## `"fifo"`
96
- *
97
- * ## `"symbolic-link"`
98
- *
99
- * ## `"regular-file"`
100
- *
101
- * ## `"socket"`
102
- */
103
- export type DescriptorType = 'unknown' | 'block-device' | 'character-device' | 'directory' | 'fifo' | 'symbolic-link' | 'regular-file' | 'socket';
104
- export type LinkCount = bigint;
105
- export type Datetime = import('./wasi-clocks-wall-clock.js').Datetime;
106
- export interface DescriptorStat {
107
- type: DescriptorType,
108
- linkCount: LinkCount,
109
- size: Filesize,
110
- dataAccessTimestamp?: Datetime,
111
- dataModificationTimestamp?: Datetime,
112
- statusChangeTimestamp?: Datetime,
113
- }
114
-
115
- export class Descriptor {
116
- /**
117
- * This type does not have a public constructor.
118
- */
119
- private constructor();
120
- writeViaStream(offset: Filesize): OutputStream;
121
- appendViaStream(): OutputStream;
122
- getType(): DescriptorType;
123
- stat(): DescriptorStat;
124
- }