File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # Helper script for testing CLI commands against local any-llm platform
3+ #
4+ # This script simplifies testing by automatically setting up credentials
5+ # for the local development environment.
6+ #
7+ # Default credentials (can be overridden via environment variables):
8+ # ANY_LLM_USERNAME=admin@example.com
9+ # ANY_LLM_PASSWORD=changethis
10+ # ANY_LLM_PLATFORM_URL=http://localhost:8100/api/v1
11+ #
12+ # Usage:
13+ # ./test_local.sh project list
14+ # ./test_local.sh key list <project-id>
15+ # ./test_local.sh --format json project list
16+ # ./test_local.sh project create "My Project" --description "Test project"
17+ # ./test_local.sh budget create <project-id> 100.0 --period monthly
18+ # ./test_local.sh client create <project-id> "My Client" --default
19+ #
20+ # Override credentials:
21+ # ANY_LLM_USERNAME=myuser@example.com ./test_local.sh project list
22+ # ANY_LLM_PASSWORD=mypassword ./test_local.sh project list
23+ # ANY_LLM_PLATFORM_URL=http://localhost:9000/api/v1 ./test_local.sh project list
24+
25+ set -e
26+
27+ # Default credentials for local testing
28+ export ANY_LLM_USERNAME=" ${ANY_LLM_USERNAME:- admin@ example.com} "
29+ export ANY_LLM_PASSWORD=" ${ANY_LLM_PASSWORD:- changethis} "
30+ export ANY_LLM_PLATFORM_URL=" ${ANY_LLM_PLATFORM_URL:- http:// localhost: 8100/ api/ v1} "
31+
32+ # Run the CLI with the provided arguments
33+ uv run any-llm " $@ "
You can’t perform that action at this time.
0 commit comments