Preskoči na sadržaj

Development

Ovaj sadržaj još uvek nije dostupan na vašem jeziku.

Welcome to the AnyBiz development documentation. This section contains technical guides for developers extending or integrating with the platform.

  • DataTable Guide - How to use the generic DataTable component for server-side pagination, sorting, and filtering
  • Database migrations - How to update the database schema (generate, migrate, push) in development and production
  • Implementing Features - Complete guide on how to implement a new feature in the AnyBiz application
  • E-Faktura / SEF - SEF integration: queue, worker, rate limiting, webhook, cron subscribe, sef_settings, and external request log
  • TicketMap SDK Integration - Embed seat map + checkout on external websites with Shadow DOM isolation
  • MSU Unipay HPP - Hosted payment page flow, callbacks, and verification

AnyBiz is built with a modern tech stack:

  • Frontend: React + TypeScript + Tailwind CSS + TanStack Router/Query
  • Backend: Hono + oRPC (OpenAPI-compatible RPC)
  • Database: PostgreSQL + Drizzle ORM
  • Authentication: Better Auth
  • Job queue: pg-boss (same PostgreSQL); API enqueues jobs, worker process runs them with rate limiting and circuit breaker
  • Rate limiting: @repo/rate-limit (Bottleneck) for external APIs (SEF, future SDC); config from integration settings (e.g. sef_settings)
  • Monorepo: pnpm workspaces + Turborepo
  1. Clone the repository
  2. Run pnpm install to install dependencies
  3. Copy .env.example to .env in each app (including apps/worker if you run the worker)
  4. Run pnpm db:push (or pnpm db:migrate) to set up the database
  5. Run pnpm db:seed to seed initial data
  6. Run pnpm dev to start the API and web
  7. Required for production email / SEF / SDC: Run the worker (pnpm worker or pnpm --filter worker dev). It must use the same SERVER_POSTGRES_URL and SERVER_AUTH_SECRET as the server. Docker Swarm deploy includes a worker service in docker-stack.yml.

When adding new features, follow the Implementing Features guide to ensure proper integration with the subscription and route protection systems.