Skip to content

Commit 46ef9f2

Browse files
committed
docs(dreamcode): copilotExtension.registerSkill()
1 parent d0e33f8 commit 46ef9f2

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

dreamcode.md

+13
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,19 @@ copilotExtension.on(
6666
}
6767
);
6868

69+
copilotExtension.registerSkill({
70+
name: "sayHi",
71+
arguments: {
72+
name: {
73+
type: "string",
74+
description: "The name of the person to say hi to",
75+
},
76+
},
77+
async run({ name, octokit, log }) {
78+
return `Hello, ${name}!`;
79+
},
80+
});
81+
6982
createServer(createNodeMiddleware(copilotExtension)).listen(3000);
7083
copilotExtension.log.info("Listening on http://localhost:3000");
7184
```

0 commit comments

Comments
 (0)