Created
May 8, 2026 20:21
-
-
Save wullemsb/89f80f824094e1250d970da9e63616e3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using GitHub.Copilot.SDK; | |
| await using var client = new CopilotClient(); | |
| await client.StartAsync(); | |
| var session = await client.CreateSessionAsync(new SessionConfig | |
| { | |
| Model = "gpt-4.1", | |
| OnPermissionRequest = PermissionHandler.ApproveAll, | |
| }); | |
| var response = await session.SendAndWaitAsync(new MessageOptions | |
| { | |
| Prompt = "What are three things I should know before building an agentic app?" | |
| }); | |
| Console.WriteLine(response?.Data.Content); | |
| await client.StopAsync(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment