{"id":15026827,"url":"https://github.com/llm-agents-php/openai-client","last_synced_at":"2025-10-06T19:46:59.894Z","repository":{"id":255071336,"uuid":"848444814","full_name":"llm-agents-php/openai-client","owner":"llm-agents-php","description":"OpenAI API client for LLM Agents","archived":false,"fork":false,"pushed_at":"2024-09-10T15:23:02.000Z","size":30,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-23T22:13:33.312Z","etag":null,"topics":["client","llm","llm-agents","llm-tools","openai","php","php8"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/llm-agents-php.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-27T19:14:57.000Z","updated_at":"2025-03-17T11:18:50.000Z","dependencies_parsed_at":"2025-02-15T20:33:24.447Z","dependency_job_id":"06cf5bcb-a8a2-4823-bdea-08e804acdbae","html_url":"https://github.com/llm-agents-php/openai-client","commit_stats":null,"previous_names":["llm-agents-php/openai-client"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llm-agents-php%2Fopenai-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llm-agents-php%2Fopenai-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llm-agents-php%2Fopenai-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llm-agents-php%2Fopenai-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/llm-agents-php","download_url":"https://codeload.github.com/llm-agents-php/openai-client/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248104462,"owners_count":21048342,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["client","llm","llm-agents","llm-tools","openai","php","php8"],"created_at":"2024-09-24T20:05:12.542Z","updated_at":"2025-10-06T19:46:54.848Z","avatar_url":"https://github.com/llm-agents-php.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LLM Agents OpenAI Client\n\n[![PHP](https://img.shields.io/packagist/php-v/llm-agents/openai-client.svg?style=flat-square)](https://packagist.org/packages/llm-agents/openai-client)\n[![Latest Version on Packagist](https://img.shields.io/packagist/v/llm-agents/openai-client.svg?style=flat-square)](https://packagist.org/packages/llm-agents/openai-client)\n[![Total Downloads](https://img.shields.io/packagist/dt/llm-agents/openai-client.svg?style=flat-square)](https://packagist.org/packages/llm-agents/openai-client)\n\nThis package is your go-to solution for integrating OpenAI's powerful API into your LLM Agents projects.\n\n## What's in the box?\n\n- Easy setup with Spiral framework\n- Smooth integration with OpenAI's API\n- Built to work hand-in-hand with LLM Agents\n\n## Installation 🛠️\n\n1. Run this command to add the package to your project:\n\n```bash\ncomposer require llm-agents/openai-client\n```\n\n2. That's it! You're ready to roll.\n\n### Setting it up in Spiral\n\nTo get the OpenAI client up and running in your Spiral app, you need to register the bootloader.\n\n**Here's how:**\n\n1. Open up your `app/src/Application/Kernel.php` file.\n\n2. In your `Kernel` class add the `LLM\\Agents\\OpenAI\\Client\\Integration\\Spiral\\OpenAIClientBootloader` bootloader:\n\n```php\nclass Kernel extends \\Spiral\\Framework\\Kernel\n{\n   public function defineBootloaders(): array\n   {\n       return [\n           // ... other bootloaders ...\n           \\LLM\\Agents\\OpenAI\\Client\\Integration\\Spiral\\OpenAIClientBootloader::class,\n       ];\n   }\n}\n```\n\nThe package uses your OpenAI API key and organization (if you have one) to authenticate.\n\nSet these up in your `.env` file:\n\n```\nOPENAI_KEY=your_api_key_here\n```\n\n### Setting it up in Laravel\n\nIf you're using the Laravel framework, you'll need to install the `openai-php/laravel` package register the Service\nprovider.\n\n**Here's how:**\n\n1. Install the `openai-php/laravel` package:\n\n```bash\ncomposer require openai-php/laravel\n```\n\n2. Next, execute the install command:\n\n```bash\nphp artisan openai:install\n```\n\n3. Finally, add your OpenAI API key to your `.env` file:\n\n```\nOPENAI_API_KEY=sk-...\nOPENAI_ORGANIZATION=org-...\n```\n\n4. And register the `LLM\\Agents\\OpenAI\\Client\\Integration\\Laravel\\OpenAIClientServiceProvider`\n\nAnd that's it! The service provider will take care of registering the `LLMInterface` for you.\n\n## Contributing\n\nWe're always happy to get help making this package even better! Here's how you can chip in:\n\n1. Fork the repo\n2. Make your changes\n3. Create a new Pull Request\n\nPlease make sure your code follows PSR-12 coding standards and include tests for any new features.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n---\n\nThat's all, folks! If you run into any issues or have questions, feel free to open an issue on GitHub.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllm-agents-php%2Fopenai-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fllm-agents-php%2Fopenai-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllm-agents-php%2Fopenai-client/lists"}