* Refactor bookkeeping error handling and introduce new error classes - Introduced new error classes for better error categorization: - JournalEntryNotBalancedError - FiscalPeriodNotFoundError - EntryDateOutsideFiscalPeriodError - JournalEntryNotFoundError - CannotReverseNonPostedError - CannotCorrectNonPostedError - EntryAlreadyReversedError - CurrencyRevaluationAlreadyExistsError - InvalidMappingResultError - BookkeepingDatabaseError - Updated existing functions in engine.ts and transaction-entries.ts to throw specific errors instead of generic ones. - Enhanced error response handling in get-error-message.ts to provide localized messages for new error types. - Added unit tests for new error classes and error handling functions to ensure correctness and coverage. * feat(ai): implement AI proposal application and persistence - Add apply.ts to handle the application of AI proposals, including match and booking steps. - Introduce persist.ts for inserting and managing AI requests and proposals, ensuring unique constraints. - Create re-validate.ts for validating proposals before acceptance, checking for stale conditions. - Define database migrations for ai_requests and ai_proposals tables, including constraints and indexes. - Enhance journal_entries with AI provenance tracking, linking entries to AI proposals. - Update categorization_templates to distinguish AI-corrected templates. - Add company settings for toggling AI flow and managing backfill processes. - Extend processing_history to include AI-related events for better tracking. * feat: add uncategorized transactions API and UI for transaction selection - Implemented a new API endpoint for fetching uncategorized transactions with pagination and filtering options. - Created ChangeTransactionDialog component for selecting alternative transactions based on AI proposals. - Developed ReceiptDetailDialog to display detailed information about receipts, including upload functionality. - Added TransactionDetailDialog for viewing transaction details with links to the transaction list. - Introduced receipt quality assessment logic to evaluate extracted receipt data. - Implemented feature flagging for the AI bookkeeping agent to control availability in different environments. * feat: add manual receipt extraction dialog and integrate AWS Textract for expense analysis - Added ManualExtractDialog component for user input when AI fails to extract receipt data. - Implemented ReceiptsList component to manage and display uploaded receipts, including upload and rescan functionalities. - Introduced Textract integration for analyzing expenses, extracting fields like total, vendor, and date. - Updated package.json to include @aws-sdk/client-textract dependency. * fix(ai): handle livsmedel VAT transition (12% → 6%) in booking prompt and re-validate guard Add date-aware guidance to BOOKING_SYSTEM_PROMPT for the temporary livsmedel VAT cut (Prop. 2025/26:55, 2026-04-01 to 2027-12-31), with restaurang/servering carve-out at 12%. Add a re-validate safety net that rejects clearly-stale rate labels for grocery-chain merchants relative to the entry date. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
118 lines
5.6 KiB
TypeScript
118 lines
5.6 KiB
TypeScript
// AUTO-GENERATED — do not edit. Run `npm run setup:extensions` to regenerate.
|
|
import type { ExtensionDefinition } from '../types'
|
|
|
|
export const EXTENSION_DEFINITIONS: Record<string, ExtensionDefinition[]> = {
|
|
'general': [
|
|
{
|
|
"slug": "enable-banking",
|
|
"name": "Bankintegration (PSD2)",
|
|
"sector": "general",
|
|
"category": "import",
|
|
"icon": "Landmark",
|
|
"dataPattern": "manual",
|
|
"description": "Automatisk banktransaktionssynk via PSD2",
|
|
"longDescription": "Koppla ditt bankkonto direkt och synka transaktioner automatiskt via säker PSD2-bankintegration. Stöder de flesta svenska banker.",
|
|
"hasOwnData": true,
|
|
"subscriptionNotice": "Denna integration kräver ett aktivt Enable Banking-abonnemang. Utan abonnemang kommer bankintegration inte att fungera."
|
|
},
|
|
{
|
|
"slug": "email",
|
|
"name": "E-post (Resend)",
|
|
"sector": "general",
|
|
"category": "operations",
|
|
"icon": "Mail",
|
|
"dataPattern": "core",
|
|
"description": "Skicka fakturor och påminnelser via e-post",
|
|
"longDescription": "Aktiverar e-postfunktioner: skicka fakturor till kunder, automatiska betalningspåminnelser (15/30/45 dagar), och e-postmeddelanden. Kräver ett Resend-konto med verifierad domän.",
|
|
"readsCoreTables": [
|
|
"invoices",
|
|
"customers",
|
|
"company_settings"
|
|
]
|
|
},
|
|
{
|
|
"slug": "arcim-migration",
|
|
"name": "Systemmigration",
|
|
"sector": "general",
|
|
"category": "import",
|
|
"icon": "ArrowRightLeft",
|
|
"dataPattern": "manual",
|
|
"description": "Migrera bokföring från Fortnox, Visma, Bokio, Björn Lundén eller Briox",
|
|
"longDescription": "Flytta all bokföringsdata från ditt gamla system till gnubok. Importerar kontoplan, verifikationer, kunder, leverantörer och öppna fakturor automatiskt via säker API-integration direkt med leverantören."
|
|
},
|
|
{
|
|
"slug": "tic",
|
|
"name": "Bolagsuppgifter",
|
|
"sector": "general",
|
|
"category": "import",
|
|
"icon": "Building2",
|
|
"dataPattern": "manual",
|
|
"description": "Hämta företagsinformation automatiskt vid registrering",
|
|
"longDescription": "Fyll i företagsuppgifter automatiskt genom att ange organisationsnummer. Hämtar adress, momsregistrering, F-skattestatus och bankuppgifter från offentliga register via TIC.",
|
|
"hasOwnData": true,
|
|
"quickAction": {
|
|
"label": "Företagsprofil",
|
|
"description": "Visa offentliga uppgifter",
|
|
"icon": "Building2",
|
|
"href": "/e/general/tic",
|
|
"order": 10
|
|
}
|
|
},
|
|
{
|
|
"slug": "mcp-server",
|
|
"name": "MCP-server (API)",
|
|
"sector": "general",
|
|
"category": "operations",
|
|
"icon": "Terminal",
|
|
"dataPattern": "manual",
|
|
"description": "Gör bokföring via Claude, Cursor eller annan MCP-klient",
|
|
"longDescription": "Exponerar gnuboks bokföringsmotor som MCP-verktyg (Model Context Protocol). Koppla din MCP-klient med en API-nyckel och gör bokföring genom konversation: visa okategoriserade transaktioner, bokför dem, skapa fakturor."
|
|
},
|
|
{
|
|
"slug": "cloud-backup",
|
|
"name": "Molnsynkronisering",
|
|
"sector": "general",
|
|
"category": "operations",
|
|
"icon": "Cloud",
|
|
"dataPattern": "manual",
|
|
"description": "Synka säkerhetsbackup till din egen molnlagring",
|
|
"longDescription": "Koppla ditt Google Drive-konto och ladda upp en fullständig säkerhetsbackup med ett klick. Gnubok skapar en ZIP med SIE-filer, kvitton och behandlingshistorik och laddar upp till en egen mapp i din Drive. Perfekt för att uppfylla egna krav på redundans.",
|
|
"hasOwnData": true,
|
|
"subscriptionNotice": "Kräver ett Google-konto. Uppladdningar sker direkt till din Drive — ingen data lagras hos tredje part utöver Google."
|
|
},
|
|
{
|
|
"slug": "invoice-inbox",
|
|
"name": "Dokumentinkorg",
|
|
"sector": "general",
|
|
"category": "import",
|
|
"icon": "Inbox",
|
|
"dataPattern": "both",
|
|
"description": "AI-klassificering och extraktion av leverantörsfakturor och kvitton",
|
|
"longDescription": "Varje bolag får en unik fakturainkorg-adress. Fakturor som skickas dit fångas automatiskt, klassificeras med AI (leverantör, belopp, moms) och matchas mot transaktioner. Kräver AWS Bedrock och Resend.",
|
|
"readsCoreTables": [
|
|
"document_attachments",
|
|
"suppliers",
|
|
"transactions"
|
|
],
|
|
"hasOwnData": true
|
|
},
|
|
{
|
|
"slug": "ai-agent",
|
|
"name": "AI-agent (beta)",
|
|
"sector": "general",
|
|
"category": "operations",
|
|
"icon": "Sparkles",
|
|
"dataPattern": "core",
|
|
"description": "Autonom bokföring — AI föreslår match + bokföring, du godkänner.",
|
|
"longDescription": "När ett kvitto kommer in föreslår AI-agenten först vilken banktransaktion som matchar, sedan hur det ska bokföras. Du granskar och godkänner varje steg — inget bokförs automatiskt. Om AI:n inte kan producera ett förslag (oläslig bild, ingen matchande transaktion, osäker moms) frågar den dig specifikt vad som behövs.",
|
|
"readsCoreTables": [
|
|
"invoice_inbox_items",
|
|
"transactions",
|
|
"ai_proposals",
|
|
"ai_requests",
|
|
"processing_history"
|
|
]
|
|
},
|
|
],
|
|
}
|