@apideck/unify 0.19.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/docs/sdks/customers/README.md +2 -0
  2. package/jsr.json +1 -1
  3. package/lib/config.d.ts +4 -4
  4. package/lib/config.js +4 -4
  5. package/lib/sdks.d.ts.map +1 -1
  6. package/lib/sdks.js +2 -8
  7. package/lib/sdks.js.map +1 -1
  8. package/models/components/balancesheetfilter.d.ts +2 -0
  9. package/models/components/balancesheetfilter.d.ts.map +1 -1
  10. package/models/components/balancesheetfilter.js.map +1 -1
  11. package/models/components/bill.d.ts +10 -0
  12. package/models/components/bill.d.ts.map +1 -1
  13. package/models/components/bill.js +8 -0
  14. package/models/components/bill.js.map +1 -1
  15. package/models/components/billpayment.d.ts +2 -2
  16. package/models/components/customersfilter.d.ts +5 -0
  17. package/models/components/customersfilter.d.ts.map +1 -1
  18. package/models/components/customersfilter.js +4 -0
  19. package/models/components/customersfilter.js.map +1 -1
  20. package/models/components/index.d.ts +2 -0
  21. package/models/components/index.d.ts.map +1 -1
  22. package/models/components/index.js +2 -0
  23. package/models/components/index.js.map +1 -1
  24. package/models/components/payment.d.ts +1 -1
  25. package/models/components/paymentinput.d.ts +1 -1
  26. package/models/components/profitandloss.d.ts +256 -56
  27. package/models/components/profitandloss.d.ts.map +1 -1
  28. package/models/components/profitandloss.js +158 -62
  29. package/models/components/profitandloss.js.map +1 -1
  30. package/models/components/profitandlossindicator.d.ts +32 -0
  31. package/models/components/profitandlossindicator.d.ts.map +1 -0
  32. package/models/components/profitandlossindicator.js +59 -0
  33. package/models/components/profitandlossindicator.js.map +1 -0
  34. package/models/components/profitandlosstype.d.ts +34 -0
  35. package/models/components/profitandlosstype.d.ts.map +1 -0
  36. package/models/components/profitandlosstype.js +53 -0
  37. package/models/components/profitandlosstype.js.map +1 -0
  38. package/package.json +1 -1
  39. package/src/lib/config.ts +4 -4
  40. package/src/lib/sdks.ts +2 -7
  41. package/src/models/components/balancesheetfilter.ts +2 -0
  42. package/src/models/components/bill.ts +18 -0
  43. package/src/models/components/billpayment.ts +2 -2
  44. package/src/models/components/customersfilter.ts +9 -0
  45. package/src/models/components/index.ts +2 -0
  46. package/src/models/components/payment.ts +1 -1
  47. package/src/models/components/paymentinput.ts +1 -1
  48. package/src/models/components/profitandloss.ts +407 -101
  49. package/src/models/components/profitandlossindicator.ts +69 -0
  50. package/src/models/components/profitandlosstype.ts +39 -0
@@ -206,6 +206,10 @@ export type Bill = {
206
206
  * Discount percentage applied to this transaction.
207
207
  */
208
208
  discountPercentage?: number | null | undefined;
209
+ /**
210
+ * URL link to a source document - shown as 'Go to [appName]' in the downstream app. Currently only supported for Xero.
211
+ */
212
+ sourceDocumentUrl?: string | null | undefined;
209
213
  /**
210
214
  * A list of linked tracking categories.
211
215
  */
@@ -346,6 +350,10 @@ export type BillInput = {
346
350
  * Discount percentage applied to this transaction.
347
351
  */
348
352
  discountPercentage?: number | null | undefined;
353
+ /**
354
+ * URL link to a source document - shown as 'Go to [appName]' in the downstream app. Currently only supported for Xero.
355
+ */
356
+ sourceDocumentUrl?: string | null | undefined;
349
357
  /**
350
358
  * A list of linked tracking categories.
351
359
  */
@@ -417,6 +425,7 @@ export const Bill$inboundSchema: z.ZodType<Bill, z.ZodTypeDef, unknown> = z
417
425
  accounting_by_row: z.nullable(z.boolean()).optional(),
418
426
  bank_account: BankAccount$inboundSchema.optional(),
419
427
  discount_percentage: z.nullable(z.number()).optional(),
428
+ source_document_url: z.nullable(z.string()).optional(),
420
429
  tracking_categories: z.nullable(
421
430
  z.array(z.nullable(LinkedTrackingCategory$inboundSchema)),
422
431
  ).optional(),
@@ -453,6 +462,7 @@ export const Bill$inboundSchema: z.ZodType<Bill, z.ZodTypeDef, unknown> = z
453
462
  "accounting_by_row": "accountingByRow",
454
463
  "bank_account": "bankAccount",
455
464
  "discount_percentage": "discountPercentage",
465
+ "source_document_url": "sourceDocumentUrl",
456
466
  "tracking_categories": "trackingCategories",
457
467
  "updated_by": "updatedBy",
458
468
  "created_by": "createdBy",
@@ -498,6 +508,7 @@ export type Bill$Outbound = {
498
508
  accounting_by_row?: boolean | null | undefined;
499
509
  bank_account?: BankAccount$Outbound | undefined;
500
510
  discount_percentage?: number | null | undefined;
511
+ source_document_url?: string | null | undefined;
501
512
  tracking_categories?:
502
513
  | Array<LinkedTrackingCategory$Outbound | null>
503
514
  | null
@@ -549,6 +560,7 @@ export const Bill$outboundSchema: z.ZodType<Bill$Outbound, z.ZodTypeDef, Bill> =
549
560
  accountingByRow: z.nullable(z.boolean()).optional(),
550
561
  bankAccount: BankAccount$outboundSchema.optional(),
551
562
  discountPercentage: z.nullable(z.number()).optional(),
563
+ sourceDocumentUrl: z.nullable(z.string()).optional(),
552
564
  trackingCategories: z.nullable(
553
565
  z.array(z.nullable(LinkedTrackingCategory$outboundSchema)),
554
566
  ).optional(),
@@ -581,6 +593,7 @@ export const Bill$outboundSchema: z.ZodType<Bill$Outbound, z.ZodTypeDef, Bill> =
581
593
  accountingByRow: "accounting_by_row",
582
594
  bankAccount: "bank_account",
583
595
  discountPercentage: "discount_percentage",
596
+ sourceDocumentUrl: "source_document_url",
584
597
  trackingCategories: "tracking_categories",
585
598
  updatedBy: "updated_by",
586
599
  createdBy: "created_by",
@@ -655,6 +668,7 @@ export const BillInput$inboundSchema: z.ZodType<
655
668
  accounting_by_row: z.nullable(z.boolean()).optional(),
656
669
  bank_account: BankAccount$inboundSchema.optional(),
657
670
  discount_percentage: z.nullable(z.number()).optional(),
671
+ source_document_url: z.nullable(z.string()).optional(),
658
672
  tracking_categories: z.nullable(
659
673
  z.array(z.nullable(LinkedTrackingCategory$inboundSchema)),
660
674
  ).optional(),
@@ -681,6 +695,7 @@ export const BillInput$inboundSchema: z.ZodType<
681
695
  "accounting_by_row": "accountingByRow",
682
696
  "bank_account": "bankAccount",
683
697
  "discount_percentage": "discountPercentage",
698
+ "source_document_url": "sourceDocumentUrl",
684
699
  "tracking_categories": "trackingCategories",
685
700
  "row_version": "rowVersion",
686
701
  "custom_fields": "customFields",
@@ -719,6 +734,7 @@ export type BillInput$Outbound = {
719
734
  accounting_by_row?: boolean | null | undefined;
720
735
  bank_account?: BankAccount$Outbound | undefined;
721
736
  discount_percentage?: number | null | undefined;
737
+ source_document_url?: string | null | undefined;
722
738
  tracking_categories?:
723
739
  | Array<LinkedTrackingCategory$Outbound | null>
724
740
  | null
@@ -766,6 +782,7 @@ export const BillInput$outboundSchema: z.ZodType<
766
782
  accountingByRow: z.nullable(z.boolean()).optional(),
767
783
  bankAccount: BankAccount$outboundSchema.optional(),
768
784
  discountPercentage: z.nullable(z.number()).optional(),
785
+ sourceDocumentUrl: z.nullable(z.string()).optional(),
769
786
  trackingCategories: z.nullable(
770
787
  z.array(z.nullable(LinkedTrackingCategory$outboundSchema)),
771
788
  ).optional(),
@@ -792,6 +809,7 @@ export const BillInput$outboundSchema: z.ZodType<
792
809
  accountingByRow: "accounting_by_row",
793
810
  bankAccount: "bank_account",
794
811
  discountPercentage: "discount_percentage",
812
+ sourceDocumentUrl: "source_document_url",
795
813
  trackingCategories: "tracking_categories",
796
814
  rowVersion: "row_version",
797
815
  customFields: "custom_fields",
@@ -138,7 +138,7 @@ export type BillPayment = {
138
138
  */
139
139
  currencyRate?: number | null | undefined;
140
140
  /**
141
- * The total amount of the transaction
141
+ * The total amount of the transaction or record
142
142
  */
143
143
  totalAmount: number | null;
144
144
  /**
@@ -259,7 +259,7 @@ export type BillPaymentInput = {
259
259
  */
260
260
  currencyRate?: number | null | undefined;
261
261
  /**
262
- * The total amount of the transaction
262
+ * The total amount of the transaction or record
263
263
  */
264
264
  totalAmount: number | null;
265
265
  /**
@@ -49,6 +49,10 @@ export type CustomersFilter = {
49
49
  */
50
50
  status?: CustomersFilterStatus | null | undefined;
51
51
  updatedSince?: Date | undefined;
52
+ /**
53
+ * Supplier ID of customer to search for
54
+ */
55
+ supplierId?: string | undefined;
52
56
  };
53
57
 
54
58
  /** @internal */
@@ -87,6 +91,7 @@ export const CustomersFilter$inboundSchema: z.ZodType<
87
91
  updated_since: z.string().datetime({ offset: true }).transform(v =>
88
92
  new Date(v)
89
93
  ).optional(),
94
+ supplier_id: z.string().optional(),
90
95
  }).transform((v) => {
91
96
  return remap$(v, {
92
97
  "company_name": "companyName",
@@ -94,6 +99,7 @@ export const CustomersFilter$inboundSchema: z.ZodType<
94
99
  "first_name": "firstName",
95
100
  "last_name": "lastName",
96
101
  "updated_since": "updatedSince",
102
+ "supplier_id": "supplierId",
97
103
  });
98
104
  });
99
105
 
@@ -106,6 +112,7 @@ export type CustomersFilter$Outbound = {
106
112
  email?: string | undefined;
107
113
  status?: string | null | undefined;
108
114
  updated_since?: string | undefined;
115
+ supplier_id?: string | undefined;
109
116
  };
110
117
 
111
118
  /** @internal */
@@ -121,6 +128,7 @@ export const CustomersFilter$outboundSchema: z.ZodType<
121
128
  email: z.string().optional(),
122
129
  status: z.nullable(CustomersFilterStatus$outboundSchema).optional(),
123
130
  updatedSince: z.date().transform(v => v.toISOString()).optional(),
131
+ supplierId: z.string().optional(),
124
132
  }).transform((v) => {
125
133
  return remap$(v, {
126
134
  companyName: "company_name",
@@ -128,6 +136,7 @@ export const CustomersFilter$outboundSchema: z.ZodType<
128
136
  firstName: "first_name",
129
137
  lastName: "last_name",
130
138
  updatedSince: "updated_since",
139
+ supplierId: "supplier_id",
131
140
  });
132
141
  });
133
142
 
@@ -411,6 +411,8 @@ export * from "./phonenumber.js";
411
411
  export * from "./pipeline.js";
412
412
  export * from "./profitandloss.js";
413
413
  export * from "./profitandlossfilter.js";
414
+ export * from "./profitandlossindicator.js";
415
+ export * from "./profitandlosstype.js";
414
416
  export * from "./purchaseorder.js";
415
417
  export * from "./purchaseordersfilter.js";
416
418
  export * from "./purchaseorderssort.js";
@@ -89,7 +89,7 @@ export type Payment = {
89
89
  */
90
90
  currencyRate?: number | null | undefined;
91
91
  /**
92
- * The total amount of the transaction
92
+ * The total amount of the transaction or record
93
93
  */
94
94
  totalAmount: number | null;
95
95
  /**
@@ -75,7 +75,7 @@ export type PaymentInput = {
75
75
  */
76
76
  currencyRate?: number | null | undefined;
77
77
  /**
78
- * The total amount of the transaction
78
+ * The total amount of the transaction or record
79
79
  */
80
80
  totalAmount: number | null;
81
81
  /**