{"id":43961675,"url":"https://github.com/vnykmshr/gowsay","last_synced_at":"2026-02-07T05:33:35.839Z","repository":{"id":260667839,"uuid":"882000253","full_name":"vnykmshr/gowsay","owner":"vnykmshr","description":"Modern cowsay in Go: CLI tool, REST API, and web UI in a single binary with 52 cows and 8 moods. Minimal dependencies, stdlib-first.","archived":false,"fork":false,"pushed_at":"2025-11-24T23:57:23.000Z","size":147,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-11-28T10:27:55.223Z","etag":null,"topics":["ascii-art","cli-tool","cowsay","docker","golang","rest-api","single-binary","slack-integration","web-ui"],"latest_commit_sha":null,"homepage":"https://gowsay.vnykmshr.com","language":"Go","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/vnykmshr.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-11-01T17:04:55.000Z","updated_at":"2025-11-24T23:57:26.000Z","dependencies_parsed_at":"2024-11-01T18:26:35.506Z","dependency_job_id":"c3d54cb0-f345-4bca-8a10-4da57d31ff45","html_url":"https://github.com/vnykmshr/gowsay","commit_stats":null,"previous_names":["vnykmshr/gowsay"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/vnykmshr/gowsay","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vnykmshr%2Fgowsay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vnykmshr%2Fgowsay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vnykmshr%2Fgowsay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vnykmshr%2Fgowsay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vnykmshr","download_url":"https://codeload.github.com/vnykmshr/gowsay/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vnykmshr%2Fgowsay/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29187224,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-07T05:07:31.176Z","status":"ssl_error","status_checked_at":"2026-02-07T05:06:15.227Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["ascii-art","cli-tool","cowsay","docker","golang","rest-api","single-binary","slack-integration","web-ui"],"created_at":"2026-02-07T05:33:35.230Z","updated_at":"2026-02-07T05:33:35.835Z","avatar_url":"https://github.com/vnykmshr.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"## gowsay\n\nImplementation of cowsay in Go\n\n**Single binary, multiple modes:**\n- Command-line tool (like original cowsay)\n- HTTP API server for Slack integration\n- Web UI with embedded assets\n- 51 different cows\n- 8 moods (borg, dead, greedy, paranoid, stoned, tired, wired, young)\n\n**Status:** gowsay 2.0 - CLI tool, Web UI, JSON API\n\n## Usage\n\n### CLI Tool\n\n```bash\n# Basic usage\ngowsay \"Hello World\"\n\n# Use a different cow\ngowsay -c dragon \"Fire!\"\n\n# Make the cow think instead of speak\ngowsay -t \"Hmm...\"\n\n# Random cow and mood\ngowsay -r \"Surprise!\"\n\n# Use mood\ngowsay -c tux -m dead \"System crashed\"\n\n# From pipe\necho \"Hello from pipe\" | gowsay\n\n# List available cows and moods\ngowsay -l\n\n# Help\ngowsay --help\n```\n\n### Web Interface\n\nStart the server and open http://localhost:9000 in your browser:\n\n```bash\n./bin/gowsay serve\n# or with custom port\nPORT=8080 ./bin/gowsay serve\n```\n\n**Features:**\n- Modern, polished UI with dark mode\n- Choose from 51 different cows\n- Apply moods (borg, dead, greedy, etc.)\n- Random button for surprise cows\n- Copy output to clipboard\n- Mobile responsive\n\n### HTTP API\n\n**Endpoints:**\n\n```bash\n# Generate cowsay (query params)\ncurl 'http://localhost:9000/api/moo?text=Hello\u0026cow=dragon\u0026action=say'\n\n# Generate cowsay (JSON)\ncurl -X POST http://localhost:9000/api/moo \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"text\":\"Hello\",\"cow\":\"dragon\",\"mood\":\"wired\"}'\n\n# List all cows\ncurl http://localhost:9000/api/cows\n\n# List all moods\ncurl http://localhost:9000/api/moods\n\n# Health check\ncurl http://localhost:9000/health\n```\n\n**API Parameters:**\n- `text` - Message to display (required)\n- `cow` - Cow name (default: \"default\", or \"random\")\n- `mood` - Mood name (optional, or \"random\")\n- `action` - \"say\" or \"think\" (default: \"say\")\n- `columns` - Text width for wrapping (default: 40)\n\n**Error Responses:**\n```json\n{\"error\": \"text is required\"}\n{\"error\": \"cow 'invalid' not found\"}\n{\"error\": \"mood 'invalid' not found\"}\n```\n\n### Slack Command\n\nDeployed at https://gowsay.vnykmshr.com/say\n\n```\n/moo [think|surprise] [cow] [mood] message\n```\n\n### Cows\n```\n`apt`, `beavis.zen`, `bong`, `bud-frogs`, `bunny`, `calvin`, `cheese`, `cock`, `cower`,\n`daemon`, `default`, `dragon`, `dragon-and-cow`, `duck`, `elephant`, `elephant-in-snake`,\n`eyes`, `flaming-sheep`, `ghostbusters`, `gnu`, `head-in`, `hellokitty`, `kiss`, `kitty`,\n`koala`, `kosh`, `luke-koala`, `mech-and-cow`, `meow`, `milk`, `moofasa`, `moose`,\n`mutilated`, `pony`, `pony-smaller`, `ren`, `sheep`, `skeleton`, `snowman`,\n`sodomized-sheep`, `stegosaurus`, `stimpy`, `suse`, `three-eyes`, `turkey`, `turtle`,\n`tux`, `unipony`, `unipony-smaller`, `vader`, `vader-koala`, `www`\n```\n### Moods\n```\n`borg`, `dead`, `greedy`, `paranoid`, `stoned`, `tired`, `wired`, `young`\n```\n\n## Configuration\n\nConfiguration via environment variables:\n\n- `PORT` - Server port (default: `9000`)\n- `GOWSAY_TOKEN` - Authentication token (default: `devel`, allows any request - set in production)\n- `GOWSAY_COLUMNS` - Text column width (default: `40`)\n\n## Development\n\n### Build\n```bash\nmake build\n# or\ngo build -ldflags \"-X 'main.version=`git log -1 --pretty=format:\"%h\"`'\" -v\n```\n\n### Run CLI\n```bash\n./bin/gowsay \"Hello World\"\n```\n\n### Run Server\n```bash\nmake run/server\n# or\n./bin/gowsay serve\n# or with custom port\nPORT=8080 ./bin/gowsay serve\n```\n\n### Test\n```bash\nmake test\n```\n\n### Cross-compile\n\nLinux:\n```bash\nGOOS=linux GOARCH=amd64 go build -o bin/gowsay-linux\n```\n\nRaspberry Pi:\n```bash\nGOOS=linux GOARCH=arm GOARM=5 go build -o bin/gowsay-pi\n```\n\n### Docker\n\nBuild and run with Docker:\n```bash\n# Build image\ndocker build -t gowsay .\n\n# Run container\ndocker run -p 9000:9000 gowsay\n\n# Or use docker compose\ndocker compose up\n```\n\nDocker image details:\n- Multi-stage build using Go 1.23\n- Final image uses scratch base (~11MB including embedded web assets)\n- Default command runs server mode\n- Can override for CLI: `docker run gowsay --help`\n\n### Slack Integration\n\nExample request:\n```bash\ncurl -X POST 'https://gowsay.vnykmshr.com/say' \\\n  -H 'Content-Type: application/x-www-form-urlencoded' \\\n  --data-urlencode 'token=xxx' \\\n  --data-urlencode 'text=Hello World'\n```\n\n## Documentation\n\n- [Architecture Overview](docs/ARCHITECTURE.md) - System design and package structure\n- [Contributing Guide](CONTRIBUTING.md) - How to contribute\n- [Technical Blog](docs/TECHNICAL_BLOG.md) - Deep dive into design decisions\n- [Security Policy](SECURITY.md) - Reporting vulnerabilities\n\n## License\n\nMIT License - see [LICENSE](LICENSE) for details\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvnykmshr%2Fgowsay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvnykmshr%2Fgowsay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvnykmshr%2Fgowsay/lists"}