Skip to content

sidratulmuntahasara/AI-api-connect-w-Nextjs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

OpenAI API Key Alternatives

There are plenty of alternatives incase your Open AI API is out of the free credits :

  • Together AI : Run OpenSource models, fine tune them or use custom AI model architectures

  • Hugging Face : Find All kinds of Open Source AI Models right here!

  • OpenRouter : A unified interface for LLMs

Featured Alternatives in this Repo

Here I've given an example on how to use Together AI API Key / OpenRouter API Key in Next.js App

To get started with the simple 5 steps:

  1. Fork/Download this repository
  2. Put the api/chat/route.js folder in your app directory in your Next.js project folder (as shown here)
  3. Remember: Your .env.local file should be in the main project directory (as shown here)
  4. I have commented accordingly, remove the extra code and keep for whichever api key you're using
  5. That's it! Your AI Model is ready to use... 🎉


For Clarifications or Suggestions, Contact ME:

Releases

No releases published

Packages

No packages published