Skip to content

Conversation

@bolg55
Copy link
Contributor

@bolg55 bolg55 commented Jan 22, 2026

Summary

Adds support for setting the invoice transaction date (TxnDate) when creating QuickBooks invoices.

Problem

The create-invoice action currently doesn't allow setting the invoice date (TxnDate). QuickBooks defaults to
today's date, which is incorrect when:

  • Billing for past service periods (e.g., creating August invoices in September)
  • Invoice dates need to match billing cycles

The txn_date field is already mapped in the output (via toInvoice), but cannot be set as input.

Changes

  • schema.zod.ts: Added txn_date: z.string().optional() to createInvoiceSchema
  • mappers/to-invoice.ts: Added mapping txn_dateTxnDate in toQuickBooksInvoice()
  • actions/create-invoice.md: Updated documentation

Backward Compatibility

Fully backward compatible - txn_date is optional, existing integrations unaffected.

@my-senior-dev-pr-review
Copy link

my-senior-dev-pr-review bot commented Jan 22, 2026

🤖 My Senior Dev — Analysis Complete

👤 For @bolg55

📁 Expert in integrations/.nango/ (1 edits) • ⚡ 1st PR this month

View your contributor analytics →


📊 13 files reviewed • 2 high risk • 2 need attention

🚨 High Risk:

  • integrations/.nango/schema.json — Critical logic issue due to lack of validation for new field.
  • integrations/quickbooks/schema.json — Critical logic issue due to lack of validation for new field.

⚠️ Needs Attention:

  • integrations/.nango/nango.json — Schema versioning changes can affect validations down the line.
  • integrations/quickbooks/mappers/to-invoice.ts — Mapping logic needs error handling to accommodate new field.

🚀 Open Interactive Review →

The full interface unlocks features not available in GitHub:

  • 💬 AI Chat — Ask questions on any file, get context-aware answers
  • 🔍 Smart Hovers — See symbol definitions and usage without leaving the diff
  • 📚 Code Archeology — Understand how files evolved over time (/archeology)
  • 🎯 Learning Insights — See how this PR compares to similar changes

💬 Chat here: @my-senior-dev explain this change — or try @chaos-monkey @security-auditor @optimizer @skeptic @junior-dev

📖 View all 12 personas & slash commands

You can interact with me by mentioning @my-senior-dev in any comment:

In PR comments or on any line of code:

  • Ask questions about the code or PR
  • Request explanations of specific changes
  • Get suggestions for improvements

Slash commands:

  • /help — Show all available commands
  • /archeology — See the history and evolution of changed files
  • /profile — Performance analysis and suggestions
  • /expertise — Find who knows this code best
  • /personas — List all available AI personas

AI Personas (mention to get their perspective):

Persona Focus
@chaos-monkey 🐵 Edge cases & failure scenarios
@skeptic 🤨 Challenge assumptions
@optimizer Performance & efficiency
@security-auditor 🔒 Security vulnerabilities
@accessibility-advocate Inclusive design
@junior-dev 🌱 Simple explanations
@tech-debt-collector 💳 Code quality & shortcuts
@ux-champion 🎨 User experience
@devops-engineer 🚀 Deployment & scaling
@documentation-nazi 📚 Documentation gaps
@legacy-whisperer 🏛️ Working with existing code
@test-driven-purist Testing & TDD

For the best experience, view this PR on myseniordev.com — includes AI chat, file annotations, and interactive reviews.

@khaliqgant khaliqgant self-requested a review January 22, 2026 09:21
bolg55 and others added 2 commits January 26, 2026 12:58
The UpdateInvoice zod schema was missing the txn_date field, causing
a type error in toQuickBooksInvoice which accepts CreateInvoice | UpdateInvoice.
Also fixes the TxnDate mapping in to-invoice.ts.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@bolg55
Copy link
Contributor Author

bolg55 commented Jan 27, 2026

@khaliqgant I've made the requested updates from our Slack messages. Thanks

Copy link
Member

@khaliqgant khaliqgant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Looks good. You just need to bump the version of the action https://github.com/NangoHQ/integration-templates/blob/main/integrations/quickbooks/actions/create-invoice.ts#L22 so this version can be upgraded to and should be all set!

@bolg55
Copy link
Contributor Author

bolg55 commented Jan 29, 2026

@khaliqgant I've updated the version now, as requested for the create and update invoices actions.

@bolg55 bolg55 requested a review from khaliqgant January 29, 2026 16:09
@bolg55
Copy link
Contributor Author

bolg55 commented Jan 29, 2026

@khaliqgant Thanks for the approval! Looks like the CI workflows are still waiting for approval to run — would you mind approving those as well so the checks can complete?

@bolg55
Copy link
Contributor Author

bolg55 commented Jan 29, 2026

@khaliqgant Thanks - are you able to merge this 🙏

@khaliqgant khaliqgant merged commit 1b4cf22 into NangoHQ:main Jan 29, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants