Discover and explore top open-source AI tools and projects—updated daily.
openaiCommand-line interface for OpenAI APIs
New!
Top 53.0% on SourcePulse
Summary
The openai-cli is the official command-line interface for interacting with the OpenAI REST API. It empowers developers and power users to programmatically access OpenAI's models and administrative features directly from their terminal, streamlining workflows and enabling automation.
How It Works
This CLI adopts a resource-based command structure, allowing users to target specific API endpoints (e.g., openai completions create). It leverages environment variables like OPENAI_API_KEY for authentication and supports flexible input methods, including passing files directly or embedding file content within JSON/YAML payloads. Advanced features include explicit file encoding options and the ability to transform output using GJSON syntax.
Quick Start & Requirements
brew install openai/tools/openaigo install 'github.com/openai/openai-cli/cmd/openai@latest' (requires Go 1.25+). Ensure $HOME/go/bin is in your PATH../scripts/run args....go install method.Highlighted Details
@filename.ext syntax, with options for explicit string (@file://) or base64 (@data://) encoding../scripts/link utility for development against specific local or remote versions of the OpenAI Go SDK.--format, --format-error) and debug logging (--debug).Maintenance & Community No specific details regarding maintainers, community channels (like Discord/Slack), or roadmap were present in the provided README.
Licensing & Compatibility The project is licensed under the Apache License 2.0. This license is generally permissive for commercial use and integration into closed-source projects.
Limitations & Caveats
The go install method requires a recent Go version (1.25+), which may be a barrier for users not already using Go or needing older versions. The README focuses on installation and usage, with limited information on broader community support or long-term maintenance signals.
4 days ago
Inactive
njerschow