@k9o/extension-client 1.5.0 → 1.5.2
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/CHANGELOG.md +7 -1
- package/README.md +34 -32
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @k9o/extension-client
|
|
2
2
|
|
|
3
|
-
Official extensions client for [Kilimanjaro](#
|
|
3
|
+
Official extensions client for [Kilimanjaro](#63-about-kilimanjaro).
|
|
4
4
|
|
|
5
5
|
Typed bindings for platform extensions, resolved by slug with `k9o.extension(slug)`. The bindings define the typed contract for each extension's methods. Calls are not served yet: every method rejects with an error before any request is sent. To write an extension, use [`@k9o/extension-runtime`](https://www.npmjs.com/package/@k9o/extension-runtime).
|
|
6
6
|
|
|
@@ -10,21 +10,21 @@ Typed bindings for platform extensions, resolved by slug with `k9o.extension(slu
|
|
|
10
10
|
|
|
11
11
|
1. [Links](#1-links)
|
|
12
12
|
2. [Install](#2-install)
|
|
13
|
-
3. [
|
|
14
|
-
|
|
13
|
+
3. [Choose the right package](#3-choose-the-right-package)
|
|
14
|
+
4. [Quick start](#4-quick-start)
|
|
15
|
+
- 4.1 [When a method is not available yet](#41-when-a-method-is-not-available-yet)
|
|
15
16
|
|
|
16
17
|
**B. Use extensions**
|
|
17
18
|
|
|
18
|
-
|
|
19
|
+
5. [Using through @k9o/core](#5-using-through-k9ocore)
|
|
19
20
|
|
|
20
21
|
**C. Reference**
|
|
21
22
|
|
|
22
|
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
26
|
-
|
|
27
|
-
6. [License](#6-license)
|
|
23
|
+
6. [Appendix](#6-appendix)
|
|
24
|
+
- 6.1 [Find extensions](#61-find-extensions)
|
|
25
|
+
- 6.2 [Imports](#62-imports)
|
|
26
|
+
- 6.3 [About Kilimanjaro](#63-about-kilimanjaro)
|
|
27
|
+
7. [License](#7-license)
|
|
28
28
|
|
|
29
29
|
## A. Get started
|
|
30
30
|
|
|
@@ -32,8 +32,6 @@ Typed bindings for platform extensions, resolved by slug with `k9o.extension(slu
|
|
|
32
32
|
|
|
33
33
|
- Website: <https://kilimanjaro.dev>
|
|
34
34
|
- Documentation / Developer Hub: <https://docs.kilimanjaro.dev>
|
|
35
|
-
- API: <https://api.k9o.io>
|
|
36
|
-
- Console: <https://console.k9o.io>
|
|
37
35
|
- Open source
|
|
38
36
|
- Platform: <https://github.com/k9o-platform>
|
|
39
37
|
- Community: <https://github.com/k9o-community>
|
|
@@ -54,7 +52,15 @@ pnpm add @k9o/extension-client
|
|
|
54
52
|
|
|
55
53
|
Requires TypeScript 5.6 or newer for the bundled types.
|
|
56
54
|
|
|
57
|
-
### 3.
|
|
55
|
+
### 3. Choose the right package
|
|
56
|
+
|
|
57
|
+
| Package | Use it when you are… | Registry | Source |
|
|
58
|
+
| --- | --- | --- | --- |
|
|
59
|
+
| `@k9o/extension-client` | Calling an extension installed in your project, by its slug, through typed bindings. | [npm](https://www.npmjs.com/package/@k9o/extension-client) | [sdk-extension-client-typescript](https://github.com/k9o-platform/sdk-extension-client-typescript) |
|
|
60
|
+
| `@k9o/extension-runtime` | Writing an extension: reading and writing data, generating text and embeddings, and calling the platform services the extension's manifest grants. | [npm](https://www.npmjs.com/package/@k9o/extension-runtime) | [sdk-extension-runtime-typescript](https://github.com/k9o-platform/sdk-extension-runtime-typescript) |
|
|
61
|
+
| `@k9o/extension-manifest` | Declaring an extension's manifest: its permissions, surfaces and endpoints, checked the way the platform checks them at registration. | [npm](https://www.npmjs.com/package/@k9o/extension-manifest) | [sdk-extension-manifest-typescript](https://github.com/k9o-platform/sdk-extension-manifest-typescript) |
|
|
62
|
+
|
|
63
|
+
### 4. Quick start
|
|
58
64
|
|
|
59
65
|
Resolve a binding by slug, then call its methods. For example, sending a WhatsApp message through an installed extension (illustrative):
|
|
60
66
|
|
|
@@ -75,9 +81,9 @@ console.log(message.id);
|
|
|
75
81
|
wamid.HBgLMjU1NzAwMDAwMDAVAgARGBI5
|
|
76
82
|
```
|
|
77
83
|
|
|
78
|
-
The returned object is typed for the extension you name, and an unknown slug is a compile-time error. Calls are not served yet; see [When a method is not available yet](#
|
|
84
|
+
The returned object is typed for the extension you name, and an unknown slug is a compile-time error. Calls are not served yet; see [When a method is not available yet](#41-when-a-method-is-not-available-yet).
|
|
79
85
|
|
|
80
|
-
####
|
|
86
|
+
#### 4.1 When a method is not available yet
|
|
81
87
|
|
|
82
88
|
Every method rejects with an `Error` before any request is sent:
|
|
83
89
|
|
|
@@ -95,40 +101,34 @@ try {
|
|
|
95
101
|
Output: stripe.invalidMethod.init is not available yet: the extension runtime is not implemented in this version of @k9o/extension-client.
|
|
96
102
|
```
|
|
97
103
|
|
|
98
|
-
An unknown slug also throws an `Error` at runtime. Each extension's methods are documented in [Find extensions](#
|
|
104
|
+
An unknown slug also throws an `Error` at runtime. Each extension's methods are documented in [Find extensions](#61-find-extensions).
|
|
105
|
+
|
|
106
|
+
[↑ Back to Contents](#contents)
|
|
99
107
|
|
|
100
108
|
## B. Use extensions
|
|
101
109
|
|
|
102
|
-
###
|
|
110
|
+
### 5. Using through @k9o/core
|
|
103
111
|
|
|
104
112
|
`@k9o/core` exposes the same factory as `k9o.extensions.extension(slug)`.
|
|
105
113
|
|
|
114
|
+
[↑ Back to Contents](#contents)
|
|
115
|
+
|
|
106
116
|
## C. Reference
|
|
107
117
|
|
|
108
|
-
###
|
|
118
|
+
### 6. Appendix
|
|
109
119
|
|
|
110
|
-
####
|
|
120
|
+
#### 6.1 Find extensions
|
|
111
121
|
|
|
112
122
|
Extensions and their documentation are published in the community: <https://github.com/k9o-community/>. Each extension lists its methods there.
|
|
113
123
|
|
|
114
|
-
####
|
|
124
|
+
#### 6.2 Imports
|
|
115
125
|
|
|
116
126
|
| Import | What it gives you |
|
|
117
127
|
| --- | --- |
|
|
118
128
|
| `@k9o/extension-client` | `k9o`, plus the types `ExtensionSlug` and `Extension`. |
|
|
119
129
|
| `@k9o/extension-client/<slug>` | One extension's binding and types, for example `@k9o/extension-client/paperless`. |
|
|
120
130
|
|
|
121
|
-
####
|
|
122
|
-
|
|
123
|
-
| Package | What it does |
|
|
124
|
-
| --- | --- |
|
|
125
|
-
| `@k9o/extension-runtime` | The runtime client for writing an extension. |
|
|
126
|
-
| `@k9o/extension-manifest` | Declaring an extension's manifest. |
|
|
127
|
-
| `@k9o/core` | The full platform client. |
|
|
128
|
-
| `@k9o/gate` | End-user identity and JWT verification. |
|
|
129
|
-
| `@k9o/kibo` | Vault and key operations. |
|
|
130
|
-
|
|
131
|
-
#### 5.4 About Kilimanjaro
|
|
131
|
+
#### 6.3 About Kilimanjaro
|
|
132
132
|
|
|
133
133
|
Kilimanjaro is a modular developer platform for building secure enterprise applications. You define AI agents, functions and data pipelines
|
|
134
134
|
on the platform. The SDKs let you deploy and invoke them, read and write your data, publish to and subscribe to streams, sign users in, and
|
|
@@ -141,6 +141,8 @@ It provides four building blocks:
|
|
|
141
141
|
- **Gate**: customer identity and access management. Sign-in and sessions, and automatic data scoping so a signed-in user reaches only their own data.
|
|
142
142
|
- **Kibo**: cryptographic keys and secrets management. Client-side encryption with keys you hold, and a secrets vault.
|
|
143
143
|
|
|
144
|
-
###
|
|
144
|
+
### 7. License
|
|
145
145
|
|
|
146
146
|
Apache-2.0 © Formelo Inc. See `LICENSE` and `NOTICE`.
|
|
147
|
+
|
|
148
|
+
[↑ Back to Contents](#contents)
|
package/package.json
CHANGED