We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1f34b32 commit 7eb87bbCopy full SHA for 7eb87bb
nodejs/examples/basic-example.ts
@@ -32,11 +32,13 @@ session.on((event) => {
32
33
// Send a simple message
34
console.log("💬 Sending message...");
35
-await session.sendAndWait({ prompt: "Tell me 2+2" });
+const result1 = await session.sendAndWait({ prompt: "Tell me 2+2" });
36
+console.log("📝 Response:", result1?.data.content);
37
38
// Send another message that uses the tool
39
console.log("💬 Sending follow-up message...");
-await session.sendAndWait({ prompt: "Now use lookup_fact to tell me something about Node.js." });
40
+const result2 = await session.sendAndWait({ prompt: "Use lookup_fact to tell me about 'node'" });
41
+console.log("📝 Response:", result2?.data.content);
42
43
// Clean up
44
await session.destroy();
0 commit comments