Quick steps
You will need a Github account first, which almost every developer already has.
After that head to the Github Models page, and select the model you want to use. This is available at the top left corner of the page. I can easily count fifty models listed there - many of them are new to me.
From the dropdown select OpenAI GPT-4o. Then hit the "Use this Model" button.
A dialog opens after that. Select C# as your language, and choose the SDK as OpenAI SDK.
A lot many sample code have been given there. You can study them as per need. You will also see Github free somewhere there. Click on the button labelled Get developer key, and complete the remaining steps to get your free key.
Video Explanation (see it happen!)
Please watch the following youtube video:
Does the Key work?
Yes! it works. I have tested it against Chatting, and also against Tool discovery and execution.
Source Code
Please visit this page for Source Code - Source code here
Similar Posts
This Blog Post/Article "How to get keys for OpenAPI and a lot others using Github Models, without the need of paying even a single cent to them." by Parveen is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.