wulf-pulse/lib/utils
lorentz c8be128c5c feat: companies sync — add UDFs and fix all field mappings
Migration 056:
- ADD user_defined_fields JSONB (GIN indexed)
- ADD parent_company_id, web_address, create_date, company_category_id
- ADD is_client_portal_active, is_task_fire_active, is_comanaged
- ADD country_id, bill_to_country_id, bill_to_address_to_use
- ADD invoice_email_message_id, purchase_order_template_id
- ADD additional_address_information, sic_code, stock_market, etc.

entity-mapper.ts mapCompany():
- Fix broken snake_case field refs (was data.invoice_method, data.last_activity_date etc.)
- All corrected to actual Autotask camelCase API names (invoiceMethod, lastActivityDate, etc.)
- was data.webSiteURL → data.webAddress
- was data.taxExempt → data.isTaxExempt
- was data.lastTrackedModifiedDateTime (various) → data.lastTrackedModifiedDateTime
- Add UDF conversion: userDefinedFields[] array → JSONB {name: value} object
- 38 UDFs now stored: PassportalID, MimecastID, MSP Service Model, Short Name,
  Workstation Lifecycle Plan, Seats (End Users), CSProfileUID, UniFiID, etc.
2026-03-17 23:56:40 -04:00
..
api-helpers.ts Add comprehensive admin features and multi-system integration 2025-11-19 14:18:16 -05:00
db-helpers.ts Add comprehensive admin features and multi-system integration 2025-11-19 14:18:16 -05:00
device-lookup.ts Restructure: rename to Pulse and move app to root 2025-10-28 23:08:54 -04:00
entity-mapper.ts feat: companies sync — add UDFs and fix all field mappings 2026-03-17 23:56:40 -04:00
issue-type-helper.ts Add comprehensive admin features and multi-system integration 2025-11-19 14:18:16 -05:00
logger.ts Add comprehensive admin features and multi-system integration 2025-11-19 14:18:16 -05:00
openclaw-auth.ts feat: OpenClaw external agent sync API at /api/openclaw/* 2026-03-17 23:26:44 -04:00
sync-helpers.ts fix: time entries incremental sync uses lastModifiedDateTime not dateWorked 2026-03-17 23:01:18 -04:00
sync-logger.ts feat: implement structured logging for sync operations 2026-01-23 08:02:02 -05:00