diff --git a/dreamcode.md b/dreamcode.md index 352b848..66a623e 100644 --- a/dreamcode.md +++ b/dreamcode.md @@ -66,6 +66,19 @@ copilotExtension.on( } ); +copilotExtension.registerFunction({ + name: "sayHi", + parameters: { + name: { + type: "string", + description: "The name of the person to say hi to", + }, + }, + async run({ name }, { octokit, log }) { + return `Hello, ${name}!`; + }, +}); + createServer(createNodeMiddleware(copilotExtension)).listen(3000); copilotExtension.log.info("Listening on http://localhost:3000"); ```