Commit Graph
18 Commits
Author SHA1 Message Date
Karl Ludwig Weise e0c1b55fc7 Fix unter invite process after unifying flows 2026-05-31 21:26:05 +02:00
Hendrik Belitz 4a5b77fb6f Untangle invite from user. Removed redundant data fields. 2026-05-30 20:53:45 +02:00
Karl Ludwig Weise a9ed62b57a Fix lint 2026-05-19 10:08:46 +02:00
Hendrik Belitz db72f6f042 Migration files 2026-05-19 09:53:05 +02:00
Karl Ludwig Weise 3f550af281 Added custom domains for tenants 2026-01-23 21:38:06 +01:00
fb3b880204 142 provide logic and apis to use more than one passkey with a staff member (#163)
* Basic implementation

* Syntax fixes

* Implemented PRF for passkey administration. Updated docs, renamed confusing endpoints.

* Update src/routes/api/auth/passkeys/[passkeyId]/crypto/+server.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Removed unused param

* Merge fixes, formatting fixes, database migrations

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-13 18:35:42 +01:00
a6707ef081 151 bare minimum notification system (#161)
* Extension of tenant schema

* Notification service

* Notification endpoints

* Format errors

* Update src/lib/server/db/tenant-schema.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/lib/server/services/notification-service.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Explicit where clause in delete notification

* Update tenant-migrations/0008_neat_swarm.sql

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Sort notifivcations by creation date. Do not explicitly check for existance in mark as read.

* Fixed tests

* No longer store texts in notifications

* Single source of truth for notification types

* Formatting

* Fixed linting errors

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-13 18:05:32 +01:00
HendrikGitHubhbelcopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>Copilot
b81706a8d9 Security hotfix prf (#146)
* Use PRF extension for deterministic Zero Knowledge Shards

* Webauthn validation lib

* Use attestation and validate passkeys

* Use attestation objects and cose-format keys in frontend. Added additional checks so that we don't create orphaned users when validation fails.

* Fixed type check error

* Fix PRF salt documentation to match implementation (#147)

* Initial plan

* Fix PRF salt documentation to match implementation

Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

* Use dev instead of node env

* Migration fixes

---------

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>
2026-01-02 15:08:23 +01:00
CopilotGitHubhbelcopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>Hendrik Belitz
337fc2e70b Add throttling to challenge APIs for brute force protection (#145)
* Initial plan

* Add throttling implementation for challenge APIs

Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

* Add tests for throttling and fix linting issues

Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

* Address code review feedback - improve error handling and documentation

Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

* Consolidate throttle storage to central DB per review feedback

Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>

* Fixed errors in challenge-throlle.

* Add throttling to frontend.

* incorporated Reviewer comments

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: hbel <7416029+hbel@users.noreply.github.com>
Co-authored-by: Hendrik Belitz <hendrik@innovation-through-understanding.de>
2026-01-02 13:14:40 +01:00
23941e7a5e Feat/staff (#110)
* Added basic staff functions -wip

* Fix: Use proper route for staff member creation

* Fixed errors in confirm, invite and register routes.

* Also return invited staff members when getting staff members

* Updated error handling

* Allow global admin to add other global admins

* Sort staff members by name

* Added dummy implementation of granting access to staff members

* Render tenant logo, if set

* Fix delete

* Make invited but not confirmed user entries deletable.

* Added staff onboarding with passkey -wip

* Fix delete route

* Fix passkey setup flow for staff

* Fix lint

* Fix lint

* Fix some unit tests

* Updated docs

* Refactored staff-service, fixed tests

* Setup state db migrations

---------

Co-authored-by: Karl Ludwig Weise <ludwig@ludwigweise.de>
Co-authored-by: Hendrik Belitz <hendrik@innovation-through-understanding.de>
2025-10-24 13:09:52 +02:00
Karl Ludwig Weise db67350f2d Move significant config to base tenant config 2025-10-13 15:25:28 +02:00
4572352341 Client and staff access to appointments and schedules (#90)
* Web workers for crypto functions. Crypto key storage in db.

* First prototype appointment service and api

* Basic flows für clients.

* Staff crypto

* Browser crypto functions

* Get appointments from a date range

* API docs

* Schedule API, fixed schedule errors

* Tests and bugfixes

* Formatting

* enhanced and unified Browser-Crypto-Utilities
trying to create a new tunnel when tenant has no users now results in an error.
user creation now has a confirmation state.

* Staff API, getting and updating tunnel data.

* Tests for staff endpoints
Fixed for confirmationState
Fixed tests

* Moved logic to staff service

* Moved logic to appoointment service

* calendar route for staff members. schedule route for clients.

* Fix client access to certain routes

* Update src/routes/api/tenants/[id]/staff/__tests__/staff-api.test.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/routes/api/tenants/[id]/staff/[staffId]/public-key/__tests__/public-key.test.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/routes/api/tenants/[id]/appointments/tunnels/add-staff-key-shares/+server.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Security fixes for staff-crypto key retrieval.

* LInting errors

* DB Migrations

* Removed isEncrypted property

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-05 15:49:11 +02:00
5965fada38 Make descriptions multilingual (#89)
* Make descriptions multilingual

* Format and test fixes

* Update src/lib/server/db/tenant-schema.ts

* Fix tenant-switcher to update instantly

* Fix sql migrations for description

* Add languages to tenant table

* Fix tenant schema

* Use objects for translated fields

* Fix format

* Fix lint

* Allow longer descriptions for channels

* Field Localizations are based on tenant locales not supportedLocales

* Fix agent image list preview

* Improve language tab keyboard navigation

* Fix falsy redirect after store init

---------

Co-authored-by: Karl Ludwig Weise <office@ludwigweise.de>
Co-authored-by: Karl Ludwig Weise <ludwig@ludwigweise.de>
2025-10-01 18:43:01 +02:00
Karl Ludwig WeiseandGitHub 838e724351 Feat/agents (#83) 2025-09-25 17:10:44 +02:00
e486072ffa Refactor/error and api handling (#82)
* DB migrations

* Format errors in migrations

* Implemented new error and permission handling.

* Updated and fixed tests

* Update src/routes/api/tenants/[id]/appointments/[appointmentId]/cancel/+server.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/routes/api/tenants/[id]/agents/[agentId]/absences/[absenceId]/+server.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/routes/api/tenants/[id]/channels/+server.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Fixed test

* Added error constants

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-18 15:04:06 +02:00
bf610cac2b Change prettier settings (#65)
Co-authored-by: Karl Ludwig Weise <ludwig@ludwigweise.de>
2025-09-01 17:47:46 +02:00
Hendrik Belitz 7fe00f6289 #53 Linting errors 2025-07-16 14:38:24 +02:00
Hendrik Belitz e21dad780f #53 Added drizzle migrations, fixed drizzle config 2025-07-16 14:37:24 +02:00