Markdown Converter
Agent skill for markdown-converter
This is a Go-based Slack invite management application with a React TypeScript frontend. The application integrates with Google Sheets for data import/export and includes email notifications via SMTP2Go.
Sign in to like and favorite skills
This is a Go-based Slack invite management application with a React TypeScript frontend. The application integrates with Google Sheets for data import/export and includes email notifications via SMTP2Go.
. ├── backend/ # Backend Go application │ ├── cmd/ # Main applications │ │ ├── server/ # Main API server │ │ └── sheets/ # Google Sheets integration tool │ ├── internal/ # Private application code │ │ ├── api/ # API handlers and routes │ │ ├── config/ # Configuration management │ │ ├── logger/ # Structured logging (slog) │ │ ├── models/ # Data models │ │ └── services/ # Business logic │ ├── pkg/ # Public library code │ ├── test/ # Additional test files │ ├── Dockerfile # Backend API Dockerfile │ └── Dockerfile.sheets # Sheets service Dockerfile ├── web/ # Frontend React application │ ├── src/ # React source code │ │ ├── components/ # React components (including ErrorBoundary) │ │ └── utils/ # Utilities (including logger) │ ├── public/ # Static assets │ ├── Dockerfile # Production web Dockerfile │ └── Dockerfile.dev # Development web Dockerfile ├── .github/ # GitHub Actions workflows ├── data/ # Local data storage (SQLite) ├── docker-compose.yml # Development environment ├── docker-compose.app.yml # Production app services ├── docker-compose.sheets.yml # Production sheets service └── README.md # Project documentation
google.golang.org/api - Google Sheets API integrationgolang.org/x/oauth2 - OAuth2 authenticationlog/slog (Loki-compatible)gofmt, golint, and govet guidelinestesting package for Go testsRun tests:
# Backend tests cd backend && go test ./... # Frontend tests cd web && npm test
Prerequisites:
Environment Variables (create
.env file):
GOOGLE_CREDENTIALS_FILE="path/to/credentials.json" GOOGLE_SPREADSHEET_ID="your-spreadsheet-id" GOOGLE_SHEET_NAME="Sheet1" EMAIL_RECIPIENT="[email protected]" SMTP2GO_FROM_EMAIL="[email protected]" SMTP2GO_USERNAME="your-smtp2go-username" SMTP2GO_PASSWORD="your-smtp2go-api-key" GITHUB_USERNAME="your-github-username" LOG_LEVEL="info" # Options: debug, info, warn, error
Start Development Environment:
docker compose up
ghcr.io/<username>/slack-invite-mgr-backend - Backend APIghcr.io/<username>/slack-invite-mgr-web - Frontend webghcr.io/<username>/slack-invite-mgr-sheets - Sheets serviceStart production services:
# Main application (API + Web) docker compose -f docker-compose.app.yml up -d # Sheets service docker compose -f docker-compose.sheets.yml up -d
.env / .env.example - Environment variable templates.github/workflows/ - CI/CD pipeline definitionsdocker-compose.yml - Development environment orchestrationdocker-compose.app.yml - Production app servicesdocker-compose.sheets.yml - Production sheets servicebackend/Dockerfile - Backend API container definitionbackend/Dockerfile.sheets - Sheets service container definitionweb/Dockerfile - Frontend production containerweb/Dockerfile.dev - Frontend development containerweb/nginx.conf.template - Nginx configuration template (static file serving only)web/public/config.js - Runtime configuration template (generated at container startup with PUBLIC_URL and API_URL)backend/go.mod - Go dependenciesweb/package.json - Node.js dependenciesbackend/internal/api/handlers.gobackend/internal/api/router.gobackend/internal/services/*_test.go filesweb/src/components/backend/internal/services/sheets.gobackend/internal/config/sheets.gobackend/cmd/sheets/data/ directoryAll backend services use structured JSON logging via Go's
log/slog package, optimized for Grafana Loki:
Log Format:
{ "time": "2026-01-03T10:15:30.123Z", "level": "INFO", "app": "slack-invite-api", "msg": "request completed", "request_id": "550e8400-e29b-41d4-a716-446655440000", "method": "GET", "path": "/api/invites", "status": 200, "duration": "45.2ms" }
Configuration:
LOG_LEVEL environment variable: debug, info, warn, error (default: info)Key Files:
backend/internal/logger/logger.go - Logger initializationbackend/internal/api/middleware.go - Request logging middlewareFrontend errors are captured and sent to the backend for centralized logging in Loki.
How it works:
web/src/utils/logger.ts provides structured logging functionsPOST /api/logs endpointapp: "slack-invite-web" identifierFrontend Log Entry:
{ "level": "error", "message": "Failed to update invite statuses", "context": { "error": "Network request failed", "operation": "mark_sent", "emailCount": 5 } }
Key Files:
web/src/utils/logger.ts - Frontend logger utilityweb/src/components/ErrorBoundary.tsx - React error boundarybackend/internal/api/handlers.go - FrontendLogsHandler endpointdata/ directory)PUBLIC_URL environment variable - no rebuild requiredAPI_URL environment variable - must be browser-accessible (not internal docker hostname)README.md for detailed setup instructions.github/workflows/ for CI/CD pipeline details