zako
v0.1.1
Published
CLI for [zakoducthunt](https://zakoducthunt.jp).
Readme
zako
CLI for zakoducthunt.
Install
npm install -g zakoQuick Start
# Log in via browser
zako login
# Initialize config file interactively
zako init
# Publish product from config
zako publishCommands
zako login
Log in via browser (OAuth). Starts a local callback server, opens the browser for authentication, and stores the API key.
zako loginCredentials are saved to ~/.config/zakoducthunt/credentials.json (mode 0600).
zako logout
Clear stored credentials.
zako logoutzako profile
Show current user profile.
zako profile
zako profile --jsonzako search
Search products. No authentication required.
zako search --query "my app"
zako search --query "AI tool" --jsonzako init
Initialize zakoducthunt.config.json. Fetches OGP metadata from the given URL to pre-populate name and tagline.
zako initzako publish
Publish product from zakoducthunt.config.json. If a product with the same URL already exists, it will be updated; otherwise a new product is created.
zako publish
zako publish --jsonzako api-key
Manage API keys (create, list, revoke).
zako api-key create --name "CI deploy"
zako api-key list
zako api-key revoke --id <key-id>Global Options
| Option | Description | Default |
|--------|-------------|---------|
| --api-url <url> | API base URL | https://zakoducthunt.jp |
| --web-url <url> | Web app URL | https://zakoducthunt.jp |
| --api-key <key> | API key (overrides stored credentials) | - |
| --json | Output as JSON | false |
| --help, -h | Show help | - |
| --version, -v | Show version | - |
Config File
Place zakoducthunt.config.json at the project root.
{
"product": {
"url": "https://example.com",
"name": "My Product",
"tagline": "A brief description",
"description": "Detailed description of the product",
"categories": ["developer_tools", "ai"],
"platforms": ["web", "cli"],
"visibility": "active"
}
}Fields
| Field | Required | Description |
|-------|----------|-------------|
| product.url | Yes | Product URL |
| product.name | Yes | Product name (max 100 chars) |
| product.tagline | Yes | Short description (max 200 chars) |
| product.description | No | Detailed description (max 5000 chars) |
| product.categories | Yes | 1-3 categories |
| product.platforms | No | Up to 5 platforms |
| product.visibility | No | "active" or "draft" (default: "active") |
Categories
saas developer_tools ai productivity design business finance social entertainment game education health_fitness lifestyle ecommerce utility other
Platforms
web ios android windows mac linux chrome_extension firefox_extension cli api
Authentication
Authentication is resolved in the following order:
--api-keyflagZAKODUCTHUNT_API_KEYenvironment variable- Stored credentials from
zako login(~/.config/zakoducthunt/credentials.json)
The API base URL can also be set via the ZAKODUCTHUNT_API_URL environment variable.
If none of the above are available, commands that require authentication will fail with:
Not authenticated. Run `zako login` first, or pass --api-key.CI/CD
Interactive login is not available in CI environments. Use an API key via environment variable instead.
Create an API key
zako api-key create --name "GitHub Actions"Save the key — it won't be shown again. Add it as a secret in your CI provider.
GitHub Actions
steps:
- uses: actions/checkout@v4
- name: Install zako
run: npm install -g zako
- name: Publish product
run: zako publish
env:
ZAKODUCTHUNT_API_KEY: ${{ secrets.ZAKODUCTHUNT_API_KEY }}Use --json to capture structured output:
- name: Publish and capture result
run: |
result=$(zako publish --json)
echo "product_id=$(echo "$result" | jq -r '.id')" >> "$GITHUB_OUTPUT"
env:
ZAKODUCTHUNT_API_KEY: ${{ secrets.ZAKODUCTHUNT_API_KEY }}Development
# Typecheck
bun run typecheck
# Test
bun test
# Run locally
bun run cli -- <command> [options]
# Build
bun run build