-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from moe-mizrak/dev
readme is updated and full name is added to license
- Loading branch information
Showing
3 changed files
with
61 additions
and
7 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,61 @@ | ||
# laravel-openrouter | ||
Laravel package for OpenRouter (A unified interface for LLMs) | ||
|
||
Check out the official website: https://openrouter.ai/ | ||
# Laravel OpenRouter | ||
|
||
<br /> | ||
|
||
# 🚧 Under Construction 🚧 | ||
[![Latest Version on Packagist](www.my_link_for_packagist_image)](https://packagist.org/packages/myLinkHere) | ||
[![](https://dcbadge.vercel.app/api/server/KBPhAPEJNj?style=flat)](https://discord.gg/KBPhAPEJNj) | ||
<br /> | ||
|
||
This Laravel package provides an easy-to-use interface for integrating **[OpenRouter](https://openrouter.ai/)** into your Laravel applications. OpenRouter is a unified interface for Large Language Models (LLMs) that allows you to interact with various **[AI models](https://openrouter.ai/docs#models)** through a single API. | ||
|
||
## Table of Contents | ||
|
||
- [🤖 Requirements](#-requirements) | ||
- [🏁 Get Started](#-get-started) | ||
- [⚙️ Configuration](#-configuration) | ||
- [🎨 Usage](#-usage) | ||
- [📜 License](#-license) | ||
|
||
## 🤖 Requirements | ||
|
||
- **PHP 8.1** or **higher** | ||
|
||
## 🏁 Get Started | ||
|
||
You can **install** the package via composer: | ||
|
||
```bash | ||
composer require moe-mizrak/laravel-openrouter | ||
``` | ||
You can **publish** the **config file** with: | ||
|
||
```bash | ||
php artisan vendor:publish --provider="MoeMizrak\LaravelOpenRouter\OpenRouterServiceProvider" | ||
``` | ||
This is the contents of the **published config file**: | ||
|
||
```php | ||
return [ | ||
'api_endpoint' => env('OPENROUTER_API_ENDPOINT', 'https://openrouter.ai/api/v1/'), | ||
'api_key' => env('OPENROUTER_API_KEY'), | ||
]; | ||
``` | ||
|
||
## ⚙️ Configuration | ||
After publishing the package configuration file, you'll need to add the following environment variables to your **.env** file: | ||
|
||
```env | ||
OPENROUTER_API_ENDPOINT=https://openrouter.ai/api/v1/ | ||
OPENROUTER_API_KEY=your_api_key | ||
``` | ||
|
||
- OPENROUTER_API_ENDPOINT: The endpoint URL for the **OpenRouter API** (default: https://openrouter.ai/api/v1/). | ||
- OPENROUTER_API_KEY: Your **API key** for accessing the OpenRouter API. You can obtain this key from the [OpenRouter dashboard](https://openrouter.ai/keys). | ||
|
||
## 🎨 Usage | ||
|
||
// TODO: Add usage instructions and examples | ||
|
||
## 📜 License | ||
Laravel OpenRouter is an open-sourced software licensed under the **[MIT license](LICENSE)**. |
This file contains 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