Metadata-Version: 2.5
Name: critique-api-cli
Version: 0.1.1
Summary: Official CLI for creating and running Critique API endpoints
Project-URL: Documentation, https://docs.critique-labs.ai/api-platform/agent-created-apis
Project-URL: Homepage, https://critique-labs.ai
Project-URL: Issues, https://github.com/parthh01/critique-api-cli/issues
Project-URL: Source, https://github.com/parthh01/critique-api-cli
Author-email: Critique Labs <support@critique-labs.ai>
License: MIT License
        
        Copyright (c) 2026 Starman LLC
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Internet :: WWW/HTTP
Requires-Python: >=3.10
Provides-Extra: dev
Requires-Dist: build>=1.2; extra == 'dev'
Requires-Dist: pytest>=8; extra == 'dev'
Requires-Dist: twine>=5; extra == 'dev'
Description-Content-Type: text/markdown

# Critique API CLI

The official command-line client for creating, inspecting, modifying, deleting,
and invoking private [Critique API](https://critique-labs.ai) research
endpoints.

The CLI is optional. Critique's agent skill and HTTP API work from projects in
any language without Python. Install this package as a standalone tool when a
terminal interface is convenient; do not add it to an application's runtime
dependencies unless that application directly needs it.

## Install

With `pipx`:

```bash
pipx install critique-api-cli
```

With `uv`:

```bash
uv tool install critique-api-cli
```

Set the API key in the environment:

```bash
export CRITIQUE_API_KEY="your-api-key"
```

Create a key at [Billing & API Keys](https://critique-labs.ai/en/billing).
Never paste an API key into source code, command arguments, URLs, or commits.

## Usage

```bash
# Create an endpoint
critique-api create \
  --prompt "For a company name, return its latest funding round, investors, date, amount, and primary-source citations."

# List or inspect endpoints
critique-api list
critique-api get 42

# Modify only the intended fields
critique-api update 42 \
  --stub latest-company-funding \
  --inputs '[{"name":"company","type":"string"}]' \
  --output '{"company":"string","amount":"number","investors":[{"name":"string"}]}'

# Invoke the generated endpoint
critique-api run latest-company-funding \
  --data '{"company":"OpenAI"}'

# Permanently delete an endpoint
critique-api delete 42 --yes
```

JSON arguments may be literal JSON or `@path/to/file.json`.

Use `CRITIQUE_BASE_URL` only to target a non-production deployment.

## Development

```bash
python -m venv .venv
source .venv/bin/activate
python -m pip install -e '.[dev]'
pytest
python -m build
python -m twine check dist/*
```

## Releases

Releases use PyPI Trusted Publishing and do not require a stored API token.

1. Update the version in `pyproject.toml` and
   `src/critique_api_cli/__init__.py`.
2. Merge the release commit to `main`.
3. Create and push the matching tag, such as `v0.1.1`.
4. The publish workflow builds, verifies, and uploads the distribution.

Before the first release, configure a pending GitHub Actions publisher on PyPI
with these exact values:

| Field | Value |
|---|---|
| PyPI project name | `critique-api-cli` |
| GitHub owner | `parthh01` |
| GitHub repository | `critique-api-cli` |
| Workflow filename | `publish.yml` |
| GitHub environment | `pypi` |

The pending publisher creates the PyPI project when the first release workflow
succeeds; no PyPI API token or repository secret is needed.

## License

MIT
