@mestra-dev/contract 0.0.305 → 0.0.307

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 (2) hide show
  1. package/dist/index.d.ts +148 -14
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -2076,6 +2076,52 @@ declare const routes: import("hono/hono-base").HonoBase<{
2076
2076
  status: 201;
2077
2077
  };
2078
2078
  };
2079
+ } & {
2080
+ "/member/history/:workspace": {
2081
+ $get: {
2082
+ input: {
2083
+ query: {
2084
+ collaboratorId: string;
2085
+ };
2086
+ } & {
2087
+ param: {
2088
+ workspace: string;
2089
+ };
2090
+ };
2091
+ output: {
2092
+ success: true;
2093
+ history: {
2094
+ tasks: {
2095
+ failureReasons: {
2096
+ id: string;
2097
+ title: string;
2098
+ count: number;
2099
+ }[];
2100
+ assigned: number;
2101
+ completed: number;
2102
+ failed: number;
2103
+ open: number;
2104
+ overdue: number;
2105
+ successRate: number | null;
2106
+ months: {
2107
+ month: string;
2108
+ completed: number;
2109
+ failed: number;
2110
+ }[];
2111
+ };
2112
+ earnings: {
2113
+ currency: string;
2114
+ paidMinor: number;
2115
+ unpaidMinor: number;
2116
+ invoiceCount: number;
2117
+ paidInvoiceCount: number;
2118
+ }[];
2119
+ };
2120
+ };
2121
+ outputFormat: "json";
2122
+ status: 200;
2123
+ };
2124
+ };
2079
2125
  } & {
2080
2126
  "/member/documents/:workspace": {
2081
2127
  $get: {
@@ -3562,6 +3608,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
3562
3608
  verified_at: string | null;
3563
3609
  suspended_at: string | null;
3564
3610
  active: boolean | null;
3611
+ currency: string | null;
3565
3612
  price: number | null;
3566
3613
  created_by: string | null;
3567
3614
  renovation: string | null;
@@ -3576,7 +3623,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
3576
3623
  housingType: string | null;
3577
3624
  commercialType: string | null;
3578
3625
  landType: string | null;
3579
- currency: string | null;
3580
3626
  propertyStatus: string | null;
3581
3627
  dealType: string | null;
3582
3628
  listingStatus: string | null;
@@ -3635,10 +3681,10 @@ declare const routes: import("hono/hono-base").HonoBase<{
3635
3681
  suspended_at: string | null;
3636
3682
  name: string;
3637
3683
  active: boolean | null;
3684
+ currency: string | null;
3638
3685
  price: number | null;
3639
3686
  created_by: string | null;
3640
3687
  stock: number | null;
3641
- currency: string | null;
3642
3688
  qrCode: string | null;
3643
3689
  }[];
3644
3690
  };
@@ -5091,6 +5137,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
5091
5137
  status: string;
5092
5138
  date: string;
5093
5139
  customerId: string;
5140
+ currency: string;
5094
5141
  created_by: string;
5095
5142
  branchId: string | null;
5096
5143
  responsibleId: string | null;
@@ -5098,7 +5145,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
5098
5145
  installment: boolean | null;
5099
5146
  notes: string | null;
5100
5147
  subscriptionEndDate: string | null;
5101
- currency: string;
5102
5148
  serviceId: string | null;
5103
5149
  invoiceDiscount: number;
5104
5150
  discount: number;
@@ -5229,8 +5275,8 @@ declare const routes: import("hono/hono-base").HonoBase<{
5229
5275
  updated_at: string | null;
5230
5276
  name: string;
5231
5277
  active: boolean;
5232
- companyName: string | null;
5233
5278
  currency: FinanceCurrency;
5279
+ companyName: string | null;
5234
5280
  vatRate: number | null;
5235
5281
  order: number;
5236
5282
  cardColor: string;
@@ -5239,6 +5285,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
5239
5285
  companyInn: string | null;
5240
5286
  companyKpp: string | null;
5241
5287
  companyOgrn: string | null;
5288
+ legalAddress: string | null;
5242
5289
  bankName: string | null;
5243
5290
  bankBik: string | null;
5244
5291
  bankKc: string | null;
@@ -5302,6 +5349,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
5302
5349
  status: string;
5303
5350
  date: string;
5304
5351
  customerId: string;
5352
+ currency: string;
5305
5353
  created_by: string;
5306
5354
  branchId: string | null;
5307
5355
  responsibleId: string | null;
@@ -5309,7 +5357,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
5309
5357
  installment: boolean | null;
5310
5358
  notes: string | null;
5311
5359
  subscriptionEndDate: string | null;
5312
- currency: string;
5313
5360
  serviceId: string | null;
5314
5361
  invoiceDiscount: number;
5315
5362
  discount: number;
@@ -5699,6 +5746,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
5699
5746
  status: string;
5700
5747
  date: string;
5701
5748
  customerId: string;
5749
+ currency: string;
5702
5750
  created_by: string;
5703
5751
  branchId: string | null;
5704
5752
  responsibleId: string | null;
@@ -5706,7 +5754,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
5706
5754
  installment: boolean | null;
5707
5755
  notes: string | null;
5708
5756
  subscriptionEndDate: string | null;
5709
- currency: string;
5710
5757
  serviceId: string | null;
5711
5758
  invoiceDiscount: number;
5712
5759
  discount: number;
@@ -6252,6 +6299,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
6252
6299
  status: string;
6253
6300
  date: string;
6254
6301
  customerId: string;
6302
+ currency: string;
6255
6303
  created_by: string;
6256
6304
  branchId: string | null;
6257
6305
  responsibleId: string | null;
@@ -6259,7 +6307,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
6259
6307
  installment: boolean | null;
6260
6308
  notes: string | null;
6261
6309
  subscriptionEndDate: string | null;
6262
- currency: string;
6263
6310
  serviceId: string | null;
6264
6311
  invoiceDiscount: number;
6265
6312
  discount: number;
@@ -6424,6 +6471,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
6424
6471
  status: string;
6425
6472
  date: string;
6426
6473
  customerId: string;
6474
+ currency: string;
6427
6475
  created_by: string;
6428
6476
  branchId: string | null;
6429
6477
  responsibleId: string | null;
@@ -6431,7 +6479,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
6431
6479
  installment: boolean | null;
6432
6480
  notes: string | null;
6433
6481
  subscriptionEndDate: string | null;
6434
- currency: string;
6435
6482
  serviceId: string | null;
6436
6483
  invoiceDiscount: number;
6437
6484
  discount: number;
@@ -11081,6 +11128,9 @@ declare const routes: import("hono/hono-base").HonoBase<{
11081
11128
  turnoverMinor: number;
11082
11129
  transitMinor: number;
11083
11130
  refundsMinor: number;
11131
+ outputVatMinor: number;
11132
+ advancesDeferredMinor: number;
11133
+ advancesRecognizedMinor: number;
11084
11134
  revenueMinor: number;
11085
11135
  cogsMinor: number;
11086
11136
  grossProfitMinor: number;
@@ -11088,8 +11138,9 @@ declare const routes: import("hono/hono-base").HonoBase<{
11088
11138
  netProfitMinor: number;
11089
11139
  transitPayoutsMinor: number;
11090
11140
  transitHeldMinor: number;
11091
- outputVatMinor: number;
11092
11141
  inputVatMinor: number;
11142
+ vatPayableMinor: number;
11143
+ deferredRevenueMinor: number;
11093
11144
  incomeCount: number;
11094
11145
  expenseCount: number;
11095
11146
  refundCount: number;
@@ -11592,6 +11643,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11592
11643
  companyInn: string | null;
11593
11644
  companyKpp: string | null;
11594
11645
  companyOgrn: string | null;
11646
+ legalAddress: string | null;
11595
11647
  bankName: string | null;
11596
11648
  bankBik: string | null;
11597
11649
  bankKc: string | null;
@@ -11647,6 +11699,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11647
11699
  companyInn: string | null;
11648
11700
  companyKpp: string | null;
11649
11701
  companyOgrn: string | null;
11702
+ legalAddress: string | null;
11650
11703
  bankName: string | null;
11651
11704
  bankBik: string | null;
11652
11705
  bankKc: string | null;
@@ -11674,6 +11727,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11674
11727
  companyInn?: string | undefined;
11675
11728
  companyKpp?: string | undefined;
11676
11729
  companyOgrn?: string | undefined;
11730
+ legalAddress?: string | undefined;
11677
11731
  bankName?: string | undefined;
11678
11732
  bankBik?: string | undefined;
11679
11733
  bankKc?: string | undefined;
@@ -11703,6 +11757,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11703
11757
  companyInn: string | null;
11704
11758
  companyKpp: string | null;
11705
11759
  companyOgrn: string | null;
11760
+ legalAddress: string | null;
11706
11761
  bankName: string | null;
11707
11762
  bankBik: string | null;
11708
11763
  bankKc: string | null;
@@ -11729,6 +11784,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11729
11784
  companyInn?: string | undefined;
11730
11785
  companyKpp?: string | undefined;
11731
11786
  companyOgrn?: string | undefined;
11787
+ legalAddress?: string | undefined;
11732
11788
  bankName?: string | undefined;
11733
11789
  bankBik?: string | undefined;
11734
11790
  bankKc?: string | undefined;
@@ -11759,6 +11815,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11759
11815
  companyInn?: string | undefined;
11760
11816
  companyKpp?: string | undefined;
11761
11817
  companyOgrn?: string | undefined;
11818
+ legalAddress?: string | undefined;
11762
11819
  bankName?: string | undefined;
11763
11820
  bankBik?: string | undefined;
11764
11821
  bankKc?: string | undefined;
@@ -11790,6 +11847,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11790
11847
  companyInn: string | null;
11791
11848
  companyKpp: string | null;
11792
11849
  companyOgrn: string | null;
11850
+ legalAddress: string | null;
11793
11851
  bankName: string | null;
11794
11852
  bankBik: string | null;
11795
11853
  bankKc: string | null;
@@ -11843,6 +11901,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11843
11901
  companyInn: string | null;
11844
11902
  companyKpp: string | null;
11845
11903
  companyOgrn: string | null;
11904
+ legalAddress: string | null;
11846
11905
  bankName: string | null;
11847
11906
  bankBik: string | null;
11848
11907
  bankKc: string | null;
@@ -11926,11 +11985,14 @@ declare const routes: import("hono/hono-base").HonoBase<{
11926
11985
  destinationAccountId: string | null;
11927
11986
  paymentMethod: string | null;
11928
11987
  amount: number;
11988
+ destinationAmount: number | null;
11929
11989
  description: string | null;
11930
11990
  date: string;
11931
11991
  vat: number | null;
11992
+ vatAmount: number;
11932
11993
  reason: string | null;
11933
11994
  cinvoiceId: string | null;
11995
+ invoiceEntry: string | null;
11934
11996
  currency: string | null;
11935
11997
  amountType: FinanceAmountType | null;
11936
11998
  expenseType: FinanceExpenseType | null;
@@ -11939,8 +12001,10 @@ declare const routes: import("hono/hono-base").HonoBase<{
11939
12001
  category: string | null;
11940
12002
  collaboratorId: string | null;
11941
12003
  taskId: string | null;
12004
+ branchId: string | null;
11942
12005
  created_at: string;
11943
12006
  updated_at: string | null;
12007
+ responsibleId: string | null;
11944
12008
  }[];
11945
12009
  };
11946
12010
  outputFormat: "json";
@@ -11983,11 +12047,14 @@ declare const routes: import("hono/hono-base").HonoBase<{
11983
12047
  destinationAccountId: string | null;
11984
12048
  paymentMethod: string | null;
11985
12049
  amount: number;
12050
+ destinationAmount: number | null;
11986
12051
  description: string | null;
11987
12052
  date: string;
11988
12053
  vat: number | null;
12054
+ vatAmount: number;
11989
12055
  reason: string | null;
11990
12056
  cinvoiceId: string | null;
12057
+ invoiceEntry: string | null;
11991
12058
  currency: string | null;
11992
12059
  amountType: FinanceAmountType | null;
11993
12060
  expenseType: FinanceExpenseType | null;
@@ -11996,6 +12063,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
11996
12063
  category: string | null;
11997
12064
  collaboratorId: string | null;
11998
12065
  taskId: string | null;
12066
+ branchId: string | null;
11999
12067
  created_at: string;
12000
12068
  updated_at: string | null;
12001
12069
  };
@@ -12020,10 +12088,12 @@ declare const routes: import("hono/hono-base").HonoBase<{
12020
12088
  type: "transfer" | "refund" | "income" | "expense";
12021
12089
  customerId?: string | undefined;
12022
12090
  serviceId?: string | undefined;
12091
+ branchId?: string | null | undefined;
12023
12092
  accountId?: string | undefined;
12024
12093
  destinationAccountId?: string | undefined;
12025
12094
  paymentMethod?: string | undefined;
12026
12095
  amount: unknown;
12096
+ destinationAmount?: unknown;
12027
12097
  description?: string | undefined;
12028
12098
  date?: string | number | undefined;
12029
12099
  vat?: number | undefined;
@@ -12050,10 +12120,12 @@ declare const routes: import("hono/hono-base").HonoBase<{
12050
12120
  type: "transfer" | "refund" | "income" | "expense";
12051
12121
  customerId?: string | undefined;
12052
12122
  serviceId?: string | undefined;
12123
+ branchId?: string | null | undefined;
12053
12124
  accountId?: string | undefined;
12054
12125
  destinationAccountId?: string | undefined;
12055
12126
  paymentMethod?: string | undefined;
12056
12127
  amount: unknown;
12128
+ destinationAmount?: unknown;
12057
12129
  description?: string | undefined;
12058
12130
  date?: string | number | undefined;
12059
12131
  vat?: number | undefined;
@@ -12072,11 +12144,14 @@ declare const routes: import("hono/hono-base").HonoBase<{
12072
12144
  destinationAccountId: string | null;
12073
12145
  paymentMethod: string | null;
12074
12146
  amount: number;
12147
+ destinationAmount: number | null;
12075
12148
  description: string | null;
12076
12149
  date: string;
12077
12150
  vat: number | null;
12151
+ vatAmount: number;
12078
12152
  reason: string | null;
12079
12153
  cinvoiceId: string | null;
12154
+ invoiceEntry: string | null;
12080
12155
  currency: string | null;
12081
12156
  amountType: FinanceAmountType | null;
12082
12157
  expenseType: FinanceExpenseType | null;
@@ -12085,6 +12160,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
12085
12160
  category: string | null;
12086
12161
  collaboratorId: string | null;
12087
12162
  taskId: string | null;
12163
+ branchId: string | null;
12088
12164
  created_at: string;
12089
12165
  updated_at: string | null;
12090
12166
  };
@@ -12108,12 +12184,47 @@ declare const routes: import("hono/hono-base").HonoBase<{
12108
12184
  transactionId: string;
12109
12185
  workspace: string;
12110
12186
  type?: "transfer" | "refund" | "income" | "expense" | undefined;
12111
- customerId?: string | undefined;
12112
- serviceId?: string | undefined;
12187
+ customerId?: string | null | undefined;
12188
+ serviceId?: string | null | undefined;
12189
+ branchId?: string | null | undefined;
12113
12190
  accountId?: string | undefined;
12114
12191
  destinationAccountId?: string | undefined;
12115
12192
  paymentMethod?: string | undefined;
12116
12193
  amount?: unknown;
12194
+ destinationAmount?: unknown;
12195
+ description?: string | undefined;
12196
+ date?: string | number | undefined;
12197
+ vat?: number | undefined;
12198
+ reason?: string | undefined;
12199
+ };
12200
+ };
12201
+ output: {
12202
+ success: false;
12203
+ error: string;
12204
+ };
12205
+ outputFormat: "json";
12206
+ status: 409;
12207
+ } | {
12208
+ input: {
12209
+ json: {
12210
+ amountType?: "transit" | "revenue" | undefined;
12211
+ expenseType?: "cogs" | "operating" | "transit_payout" | undefined;
12212
+ refundDirection?: "to_customer" | "from_supplier" | undefined;
12213
+ refundedTransactionId?: string | null | undefined;
12214
+ category?: string | null | undefined;
12215
+ collaboratorId?: string | null | undefined;
12216
+ taskId?: string | null | undefined;
12217
+ transactionId: string;
12218
+ workspace: string;
12219
+ type?: "transfer" | "refund" | "income" | "expense" | undefined;
12220
+ customerId?: string | null | undefined;
12221
+ serviceId?: string | null | undefined;
12222
+ branchId?: string | null | undefined;
12223
+ accountId?: string | undefined;
12224
+ destinationAccountId?: string | undefined;
12225
+ paymentMethod?: string | undefined;
12226
+ amount?: unknown;
12227
+ destinationAmount?: unknown;
12117
12228
  description?: string | undefined;
12118
12229
  date?: string | number | undefined;
12119
12230
  vat?: number | undefined;
@@ -12139,12 +12250,14 @@ declare const routes: import("hono/hono-base").HonoBase<{
12139
12250
  transactionId: string;
12140
12251
  workspace: string;
12141
12252
  type?: "transfer" | "refund" | "income" | "expense" | undefined;
12142
- customerId?: string | undefined;
12143
- serviceId?: string | undefined;
12253
+ customerId?: string | null | undefined;
12254
+ serviceId?: string | null | undefined;
12255
+ branchId?: string | null | undefined;
12144
12256
  accountId?: string | undefined;
12145
12257
  destinationAccountId?: string | undefined;
12146
12258
  paymentMethod?: string | undefined;
12147
12259
  amount?: unknown;
12260
+ destinationAmount?: unknown;
12148
12261
  description?: string | undefined;
12149
12262
  date?: string | number | undefined;
12150
12263
  vat?: number | undefined;
@@ -12163,11 +12276,14 @@ declare const routes: import("hono/hono-base").HonoBase<{
12163
12276
  destinationAccountId: string | null;
12164
12277
  paymentMethod: string | null;
12165
12278
  amount: number;
12279
+ destinationAmount: number | null;
12166
12280
  description: string | null;
12167
12281
  date: string;
12168
12282
  vat: number | null;
12283
+ vatAmount: number;
12169
12284
  reason: string | null;
12170
12285
  cinvoiceId: string | null;
12286
+ invoiceEntry: string | null;
12171
12287
  currency: string | null;
12172
12288
  amountType: FinanceAmountType | null;
12173
12289
  expenseType: FinanceExpenseType | null;
@@ -12176,6 +12292,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
12176
12292
  category: string | null;
12177
12293
  collaboratorId: string | null;
12178
12294
  taskId: string | null;
12295
+ branchId: string | null;
12179
12296
  created_at: string;
12180
12297
  updated_at: string | null;
12181
12298
  };
@@ -12199,6 +12316,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
12199
12316
  };
12200
12317
  outputFormat: "json";
12201
12318
  status: 404;
12319
+ } | {
12320
+ input: {
12321
+ json: {
12322
+ transactionId: string;
12323
+ workspace: string;
12324
+ };
12325
+ };
12326
+ output: {
12327
+ success: false;
12328
+ error: string;
12329
+ };
12330
+ outputFormat: "json";
12331
+ status: 409;
12202
12332
  } | {
12203
12333
  input: {
12204
12334
  json: {
@@ -12265,6 +12395,9 @@ declare const routes: import("hono/hono-base").HonoBase<{
12265
12395
  turnoverMinor: number;
12266
12396
  transitMinor: number;
12267
12397
  refundsMinor: number;
12398
+ outputVatMinor: number;
12399
+ advancesDeferredMinor: number;
12400
+ advancesRecognizedMinor: number;
12268
12401
  revenueMinor: number;
12269
12402
  cogsMinor: number;
12270
12403
  grossProfitMinor: number;
@@ -12272,8 +12405,9 @@ declare const routes: import("hono/hono-base").HonoBase<{
12272
12405
  netProfitMinor: number;
12273
12406
  transitPayoutsMinor: number;
12274
12407
  transitHeldMinor: number;
12275
- outputVatMinor: number;
12276
12408
  inputVatMinor: number;
12409
+ vatPayableMinor: number;
12410
+ deferredRevenueMinor: number;
12277
12411
  incomeCount: number;
12278
12412
  expenseCount: number;
12279
12413
  refundCount: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mestra-dev/contract",
3
- "version": "0.0.305",
3
+ "version": "0.0.307",
4
4
  "description": "Types-only Hono AppType contract for the Mestra auth API",
5
5
  "type": "module",
6
6
  "sideEffects": false,