asteroid-odyssey 1.3.11 → 1.6.17
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/README.md +32 -5
- package/dist/index.d.mts +1205 -1958
- package/dist/index.d.ts +1205 -1958
- package/dist/index.js +8 -2
- package/dist/index.mjs +8 -2
- package/package.json +6 -9
package/README.md
CHANGED
|
@@ -1,17 +1,44 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Asteroid Odyssey TypeScript SDK
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
TypeScript SDK for the Asteroid Agents API.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
8
|
npm install asteroid-odyssey
|
|
9
|
+
# or
|
|
10
|
+
pnpm add asteroid-odyssey
|
|
9
11
|
```
|
|
10
12
|
|
|
11
13
|
## Usage
|
|
12
14
|
|
|
13
|
-
|
|
15
|
+
```typescript
|
|
16
|
+
import { client, agentExecutePost, executionGet } from 'asteroid-odyssey';
|
|
14
17
|
|
|
15
|
-
|
|
18
|
+
// Configure the client
|
|
19
|
+
client.setConfig({
|
|
20
|
+
baseUrl: 'https://odyssey.asteroid.ai/agents/v2',
|
|
21
|
+
headers: {
|
|
22
|
+
'X-Asteroid-Agents-Api-Key': 'your-api-key',
|
|
23
|
+
},
|
|
24
|
+
});
|
|
16
25
|
|
|
17
|
-
|
|
26
|
+
// Execute an agent
|
|
27
|
+
const { data } = await agentExecutePost({
|
|
28
|
+
path: { agentId: 'your-agent-id' },
|
|
29
|
+
body: { dynamicData: { input: 'value' } },
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
console.log(`Execution ID: ${data?.executionId}`);
|
|
33
|
+
|
|
34
|
+
// Get execution status
|
|
35
|
+
const { data: execution } = await executionGet({
|
|
36
|
+
path: { executionId: data?.executionId },
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
console.log(`Status: ${execution?.status}`);
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Documentation
|
|
43
|
+
|
|
44
|
+
See [docs.asteroid.ai](https://docs.asteroid.ai) for full documentation.
|