Manage your taxes.
- Switch to the correct version of Node.js:
nvm use $(cat .node-version)- Install dependencies:
yarn install- Create
.envfile:
cp .env.template .env- Run setup:
If you want to create new local database, run:
yarn local:setupIn case you already have a database, you can set the database variables in your .env file, then
run:
yarn setup- Run client and server:
yarn build
yarn client:dev
yarn server:dev
# Also helpful while developing:
yarn generate:watchOr use the VSCode Terminals extension: fabiospampinato.vscode-terminals to run all this for you in
different terminals.
-
Visit http://localhost:3001/ and sign in. The credentials to log in are in your
.envfile underAUTHORIZED_USERS. Set the hashed password in the.envfile. e.g. replaceSECRETwith$2b$10$SuqbDX5r6qZidiMbAcGnFOPloNQSRQrLEPShZjplabtfdN.QzS4ba. And then use the passwordSECRETto log in. -
Seed the database with your business details. Edit
scripts/seed.tswith your info, then runyarn seed. -
Load your data into the database (first set correct env vars):
yarn scrape- Generate businesses by visiting http://localhost:4000/graphql
Set your headers at the bottom:
{
"authorization": "Basic [YOUR_TOKEN]"
}You can find YOUR_TOKEN by in the GraphQL request headers in your browser's Network tab.
Then run this mutation:
mutation {
batchGenerateBusinessesOutOfTransactions {
id
name
}
}The test suite is organized into three projects for efficiency:
- Unit tests (
yarn test): Fast, isolated tests with no external dependencies - Integration tests (
yarn test:integration): DB-backed tests requiring PostgreSQL and migrations - Demo seed E2E (
yarn test:demo-seed): Full seed-and-validate pipeline (slow, ~10-30s)
# Fast unit tests only (default, no DB required)
yarn test
# Unit + integration tests (requires DB + migrations)
yarn test:integration
# Demo seed E2E (requires DB + migrations + ALLOW_DEMO_SEED=1)
ALLOW_DEMO_SEED=1 yarn test:demo-seedIntegration and demo-seed tests require:
- PostgreSQL running: Start with
docker compose -f docker/docker-compose.dev.yml up -d postgres - Migrations applied: Run
yarn workspace @accounter/migrations migration:run - Demo seed only: Set
ALLOW_DEMO_SEED=1environment variable
If migrations are stale, demo-seed tests fail gracefully with instructions to run migrations.
See packages/server/README.md for detailed test harness
documentation.
For Poalim Bank and Discount Bank accounts, your account may appear under multiple branch numbers:
- Your account number and bank number remain the same
- The same account might be associated with 2-3 different branch numbers
- You can configure all relevant branch numbers in the
scripts/seed.tsfile
- Go to Google Cloud Console
- Create a project or select existing one
- Enable Google Drive API:
- Navigate to "APIs & Services" > "Library"
- Search for and enable "Google Drive API"
- Create API key:
- Go to "APIs & Services" > "Credentials"
- Click "Create Credentials" > "API Key"
- Restrict the key to Google Drive API only
- Add to your
.env:GOOGLE_DRIVE_API_KEY=your_api_key_here
- Sign up for an Anthropic API key at https://console.anthropic.com/settings/keys
- Add to your
.env:ANTHROPIC_API_KEY=your_api_key_here - OCR functionality will now be available for processing images and documents