@mestra-dev/contract 0.0.212 → 0.0.214
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.
- package/dist/index.d.ts +456 -777
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { ApplyGlobalResponse } from 'hono/client';
|
|
2
2
|
import type { JwtVariables } from 'hono/jwt';
|
|
3
3
|
|
|
4
|
-
type GrowthDirection = "positive" | "negative" | "none";
|
|
5
4
|
type FinanceCurrency = "ruble" | "dollar" | "euro";
|
|
6
5
|
type FinanceTransactionType = "refund" | "income" | "expense" | "transfer";
|
|
6
|
+
type GrowthDirection = "positive" | "negative" | "none";
|
|
7
7
|
type Variables = JwtVariables;
|
|
8
8
|
/** Shared error body for middleware / HTTPException responses (typed into AppType). */
|
|
9
9
|
export type ApiError = {
|
|
@@ -30,7 +30,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30
30
|
readonly info: {
|
|
31
31
|
readonly title: "Auth Service API";
|
|
32
32
|
readonly version: "1.5.12";
|
|
33
|
-
readonly description: "OpenAPI specification for the Auth, Integrations, Workspace, Payments, Analytics, Tasks, Templates, Tags, Failure Reasons, Comments, Assignees, Chat, Events,
|
|
33
|
+
readonly description: "OpenAPI specification for the Auth, Integrations, Workspace, Payments, Analytics, Tasks, Templates, Tags, Failure Reasons, Comments, Assignees, Chat, Events, CInvoices, Customer History, Files, Finance, and Notifications endpoints exposed by the k3-core platform. Unhandled HTTPException and unexpected errors are normalized by the global error handler to `{ success: false, error: string }` (status preserved for HTTPException; 500 otherwise).";
|
|
34
34
|
};
|
|
35
35
|
readonly servers: readonly [
|
|
36
36
|
{
|
|
@@ -103,13 +103,9 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
103
103
|
readonly name: "Events";
|
|
104
104
|
readonly description: "Server-Sent Events (SSE) streaming endpoints";
|
|
105
105
|
},
|
|
106
|
-
{
|
|
107
|
-
readonly name: "Billings";
|
|
108
|
-
readonly description: "Billing/requisite management endpoints";
|
|
109
|
-
},
|
|
110
106
|
{
|
|
111
107
|
readonly name: "CInvoices";
|
|
112
|
-
readonly description: "Customer invoice management for real-estate workspaces. Requires workspace access and crm::customers access. Seller
|
|
108
|
+
readonly description: "Customer invoice management for real-estate workspaces. Requires workspace access and crm::customers access. Seller finance account, customer, and service must belong to the workspace. Invoice creators can list finance accounts for seller selection without crm::finance access or private account fields.";
|
|
113
109
|
},
|
|
114
110
|
{
|
|
115
111
|
readonly name: "Customer History";
|
|
@@ -129,7 +125,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
129
125
|
},
|
|
130
126
|
{
|
|
131
127
|
readonly name: "Finance";
|
|
132
|
-
readonly description: "Workspace finance accounts (ordered cards with name, color, currency, and
|
|
128
|
+
readonly description: "Workspace finance accounts (ordered cards with name, color, currency, opening balance, and optional company/bank details), ledger transactions (income, expense, refund, transfer), and a numbers-visibility toggle for the default finance view. Requires workspace access and crm::finance read or write.";
|
|
133
129
|
}
|
|
134
130
|
];
|
|
135
131
|
readonly components: {
|
|
@@ -4374,57 +4370,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
4374
4370
|
};
|
|
4375
4371
|
};
|
|
4376
4372
|
};
|
|
4377
|
-
readonly CreateBillingSuccess: {
|
|
4378
|
-
readonly type: "object";
|
|
4379
|
-
readonly required: readonly [
|
|
4380
|
-
"success",
|
|
4381
|
-
"billing"
|
|
4382
|
-
];
|
|
4383
|
-
readonly properties: {
|
|
4384
|
-
readonly success: {
|
|
4385
|
-
readonly type: "boolean";
|
|
4386
|
-
readonly const: true;
|
|
4387
|
-
};
|
|
4388
|
-
readonly billing: {
|
|
4389
|
-
readonly $ref: "#/components/schemas/Billing";
|
|
4390
|
-
};
|
|
4391
|
-
};
|
|
4392
|
-
};
|
|
4393
|
-
readonly ListBillingsSuccess: {
|
|
4394
|
-
readonly type: "object";
|
|
4395
|
-
readonly required: readonly [
|
|
4396
|
-
"success",
|
|
4397
|
-
"billings"
|
|
4398
|
-
];
|
|
4399
|
-
readonly properties: {
|
|
4400
|
-
readonly success: {
|
|
4401
|
-
readonly type: "boolean";
|
|
4402
|
-
readonly const: true;
|
|
4403
|
-
};
|
|
4404
|
-
readonly billings: {
|
|
4405
|
-
readonly type: "array";
|
|
4406
|
-
readonly items: {
|
|
4407
|
-
readonly $ref: "#/components/schemas/Billing";
|
|
4408
|
-
};
|
|
4409
|
-
};
|
|
4410
|
-
};
|
|
4411
|
-
};
|
|
4412
|
-
readonly GetBillingSuccess: {
|
|
4413
|
-
readonly type: "object";
|
|
4414
|
-
readonly required: readonly [
|
|
4415
|
-
"success",
|
|
4416
|
-
"billing"
|
|
4417
|
-
];
|
|
4418
|
-
readonly properties: {
|
|
4419
|
-
readonly success: {
|
|
4420
|
-
readonly type: "boolean";
|
|
4421
|
-
readonly const: true;
|
|
4422
|
-
};
|
|
4423
|
-
readonly billing: {
|
|
4424
|
-
readonly $ref: "#/components/schemas/Billing";
|
|
4425
|
-
};
|
|
4426
|
-
};
|
|
4427
|
-
};
|
|
4428
4373
|
readonly CInvoice: {
|
|
4429
4374
|
readonly type: "object";
|
|
4430
4375
|
readonly required: readonly [
|
|
@@ -4432,7 +4377,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
4432
4377
|
"workspaceId",
|
|
4433
4378
|
"invoiceId",
|
|
4434
4379
|
"serviceId",
|
|
4435
|
-
"
|
|
4380
|
+
"SellerFinanceAccountId",
|
|
4436
4381
|
"customerId",
|
|
4437
4382
|
"date",
|
|
4438
4383
|
"language",
|
|
@@ -4462,10 +4407,10 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
4462
4407
|
readonly format: "uuid";
|
|
4463
4408
|
readonly description: "Real-estate service identifier (service_real_estates).";
|
|
4464
4409
|
};
|
|
4465
|
-
readonly
|
|
4410
|
+
readonly SellerFinanceAccountId: {
|
|
4466
4411
|
readonly type: "string";
|
|
4467
4412
|
readonly format: "uuid";
|
|
4468
|
-
readonly description: "Seller
|
|
4413
|
+
readonly description: "Seller finance account identifier.";
|
|
4469
4414
|
};
|
|
4470
4415
|
readonly customerId: {
|
|
4471
4416
|
readonly type: "string";
|
|
@@ -4629,6 +4574,131 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
4629
4574
|
};
|
|
4630
4575
|
};
|
|
4631
4576
|
};
|
|
4577
|
+
readonly CInvoiceFinanceAccountOption: {
|
|
4578
|
+
readonly type: "object";
|
|
4579
|
+
readonly required: readonly [
|
|
4580
|
+
"id",
|
|
4581
|
+
"workspaceId",
|
|
4582
|
+
"order",
|
|
4583
|
+
"name",
|
|
4584
|
+
"cardColor",
|
|
4585
|
+
"currency",
|
|
4586
|
+
"active",
|
|
4587
|
+
"created_at"
|
|
4588
|
+
];
|
|
4589
|
+
readonly properties: {
|
|
4590
|
+
readonly id: {
|
|
4591
|
+
readonly type: "string";
|
|
4592
|
+
readonly format: "uuid";
|
|
4593
|
+
};
|
|
4594
|
+
readonly workspaceId: {
|
|
4595
|
+
readonly type: "string";
|
|
4596
|
+
readonly format: "uuid";
|
|
4597
|
+
};
|
|
4598
|
+
readonly order: {
|
|
4599
|
+
readonly type: "integer";
|
|
4600
|
+
readonly minimum: 1;
|
|
4601
|
+
readonly description: "1-based display order.";
|
|
4602
|
+
};
|
|
4603
|
+
readonly name: {
|
|
4604
|
+
readonly type: "string";
|
|
4605
|
+
};
|
|
4606
|
+
readonly cardColor: {
|
|
4607
|
+
readonly type: "string";
|
|
4608
|
+
readonly example: "#A1B2C3";
|
|
4609
|
+
readonly description: "Normalized 6-digit hex color including #.";
|
|
4610
|
+
};
|
|
4611
|
+
readonly currency: {
|
|
4612
|
+
readonly type: "string";
|
|
4613
|
+
readonly enum: readonly [
|
|
4614
|
+
"ruble",
|
|
4615
|
+
"dollar",
|
|
4616
|
+
"euro"
|
|
4617
|
+
];
|
|
4618
|
+
};
|
|
4619
|
+
readonly country: {
|
|
4620
|
+
readonly type: "string";
|
|
4621
|
+
readonly nullable: true;
|
|
4622
|
+
};
|
|
4623
|
+
readonly companyName: {
|
|
4624
|
+
readonly type: "string";
|
|
4625
|
+
readonly nullable: true;
|
|
4626
|
+
};
|
|
4627
|
+
readonly inn: {
|
|
4628
|
+
readonly type: "string";
|
|
4629
|
+
readonly nullable: true;
|
|
4630
|
+
};
|
|
4631
|
+
readonly kpp: {
|
|
4632
|
+
readonly type: "string";
|
|
4633
|
+
readonly nullable: true;
|
|
4634
|
+
};
|
|
4635
|
+
readonly ogrn: {
|
|
4636
|
+
readonly type: "string";
|
|
4637
|
+
readonly nullable: true;
|
|
4638
|
+
};
|
|
4639
|
+
readonly bankName: {
|
|
4640
|
+
readonly type: "string";
|
|
4641
|
+
readonly nullable: true;
|
|
4642
|
+
};
|
|
4643
|
+
readonly bankAccountNumber: {
|
|
4644
|
+
readonly type: "string";
|
|
4645
|
+
readonly nullable: true;
|
|
4646
|
+
};
|
|
4647
|
+
readonly bankBik: {
|
|
4648
|
+
readonly type: "string";
|
|
4649
|
+
readonly nullable: true;
|
|
4650
|
+
};
|
|
4651
|
+
readonly bankKc: {
|
|
4652
|
+
readonly type: "string";
|
|
4653
|
+
readonly nullable: true;
|
|
4654
|
+
};
|
|
4655
|
+
readonly bankInn: {
|
|
4656
|
+
readonly type: "string";
|
|
4657
|
+
readonly nullable: true;
|
|
4658
|
+
};
|
|
4659
|
+
readonly bankKpp: {
|
|
4660
|
+
readonly type: "string";
|
|
4661
|
+
readonly nullable: true;
|
|
4662
|
+
};
|
|
4663
|
+
readonly vatRate: {
|
|
4664
|
+
readonly type: "integer";
|
|
4665
|
+
readonly nullable: true;
|
|
4666
|
+
readonly minimum: 0;
|
|
4667
|
+
readonly maximum: 100;
|
|
4668
|
+
};
|
|
4669
|
+
readonly active: {
|
|
4670
|
+
readonly type: "boolean";
|
|
4671
|
+
};
|
|
4672
|
+
readonly created_at: {
|
|
4673
|
+
readonly type: "string";
|
|
4674
|
+
readonly format: "date-time";
|
|
4675
|
+
};
|
|
4676
|
+
readonly updated_at: {
|
|
4677
|
+
readonly type: "string";
|
|
4678
|
+
readonly format: "date-time";
|
|
4679
|
+
readonly nullable: true;
|
|
4680
|
+
};
|
|
4681
|
+
};
|
|
4682
|
+
};
|
|
4683
|
+
readonly ListCInvoiceFinanceAccountsSuccess: {
|
|
4684
|
+
readonly type: "object";
|
|
4685
|
+
readonly required: readonly [
|
|
4686
|
+
"success",
|
|
4687
|
+
"accounts"
|
|
4688
|
+
];
|
|
4689
|
+
readonly properties: {
|
|
4690
|
+
readonly success: {
|
|
4691
|
+
readonly type: "boolean";
|
|
4692
|
+
readonly const: true;
|
|
4693
|
+
};
|
|
4694
|
+
readonly accounts: {
|
|
4695
|
+
readonly type: "array";
|
|
4696
|
+
readonly items: {
|
|
4697
|
+
readonly $ref: "#/components/schemas/CInvoiceFinanceAccountOption";
|
|
4698
|
+
};
|
|
4699
|
+
};
|
|
4700
|
+
};
|
|
4701
|
+
};
|
|
4632
4702
|
readonly UpdateCInvoiceSuccess: {
|
|
4633
4703
|
readonly type: "object";
|
|
4634
4704
|
readonly required: readonly [
|
|
@@ -6022,6 +6092,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
6022
6092
|
"cardColor",
|
|
6023
6093
|
"currency",
|
|
6024
6094
|
"openingBalance",
|
|
6095
|
+
"active",
|
|
6025
6096
|
"created_at"
|
|
6026
6097
|
];
|
|
6027
6098
|
readonly properties: {
|
|
@@ -6058,6 +6129,59 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
6058
6129
|
readonly type: "number";
|
|
6059
6130
|
readonly description: "Opening balance in the account currency.";
|
|
6060
6131
|
};
|
|
6132
|
+
readonly country: {
|
|
6133
|
+
readonly type: "string";
|
|
6134
|
+
readonly nullable: true;
|
|
6135
|
+
};
|
|
6136
|
+
readonly companyName: {
|
|
6137
|
+
readonly type: "string";
|
|
6138
|
+
readonly nullable: true;
|
|
6139
|
+
};
|
|
6140
|
+
readonly inn: {
|
|
6141
|
+
readonly type: "string";
|
|
6142
|
+
readonly nullable: true;
|
|
6143
|
+
};
|
|
6144
|
+
readonly kpp: {
|
|
6145
|
+
readonly type: "string";
|
|
6146
|
+
readonly nullable: true;
|
|
6147
|
+
};
|
|
6148
|
+
readonly ogrn: {
|
|
6149
|
+
readonly type: "string";
|
|
6150
|
+
readonly nullable: true;
|
|
6151
|
+
};
|
|
6152
|
+
readonly bankName: {
|
|
6153
|
+
readonly type: "string";
|
|
6154
|
+
readonly nullable: true;
|
|
6155
|
+
};
|
|
6156
|
+
readonly bankAccountNumber: {
|
|
6157
|
+
readonly type: "string";
|
|
6158
|
+
readonly nullable: true;
|
|
6159
|
+
};
|
|
6160
|
+
readonly bankBik: {
|
|
6161
|
+
readonly type: "string";
|
|
6162
|
+
readonly nullable: true;
|
|
6163
|
+
};
|
|
6164
|
+
readonly bankKc: {
|
|
6165
|
+
readonly type: "string";
|
|
6166
|
+
readonly nullable: true;
|
|
6167
|
+
};
|
|
6168
|
+
readonly bankInn: {
|
|
6169
|
+
readonly type: "string";
|
|
6170
|
+
readonly nullable: true;
|
|
6171
|
+
};
|
|
6172
|
+
readonly bankKpp: {
|
|
6173
|
+
readonly type: "string";
|
|
6174
|
+
readonly nullable: true;
|
|
6175
|
+
};
|
|
6176
|
+
readonly vatRate: {
|
|
6177
|
+
readonly type: "integer";
|
|
6178
|
+
readonly nullable: true;
|
|
6179
|
+
readonly minimum: 0;
|
|
6180
|
+
readonly maximum: 100;
|
|
6181
|
+
};
|
|
6182
|
+
readonly active: {
|
|
6183
|
+
readonly type: "boolean";
|
|
6184
|
+
};
|
|
6061
6185
|
readonly created_at: {
|
|
6062
6186
|
readonly type: "string";
|
|
6063
6187
|
readonly format: "date-time";
|
|
@@ -13885,521 +14009,13 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
13885
14009
|
};
|
|
13886
14010
|
};
|
|
13887
14011
|
};
|
|
13888
|
-
readonly "/
|
|
13889
|
-
readonly
|
|
14012
|
+
readonly "/analytics/{workspace}/task-phase-funnel": {
|
|
14013
|
+
readonly get: {
|
|
13890
14014
|
readonly tags: readonly [
|
|
13891
|
-
"
|
|
14015
|
+
"Analytics"
|
|
13892
14016
|
];
|
|
13893
|
-
readonly summary: "
|
|
13894
|
-
readonly description: "
|
|
13895
|
-
readonly security: readonly [
|
|
13896
|
-
never
|
|
13897
|
-
];
|
|
13898
|
-
readonly requestBody: {
|
|
13899
|
-
readonly required: true;
|
|
13900
|
-
readonly content: {
|
|
13901
|
-
readonly "application/json": {
|
|
13902
|
-
readonly schema: {
|
|
13903
|
-
readonly type: "object";
|
|
13904
|
-
readonly required: readonly [
|
|
13905
|
-
"workspace",
|
|
13906
|
-
"country",
|
|
13907
|
-
"companyName",
|
|
13908
|
-
"inn",
|
|
13909
|
-
"kpp",
|
|
13910
|
-
"bankBranch",
|
|
13911
|
-
"bankAccountNumber",
|
|
13912
|
-
"bankBik",
|
|
13913
|
-
"bankKc",
|
|
13914
|
-
"vat",
|
|
13915
|
-
"vatRate"
|
|
13916
|
-
];
|
|
13917
|
-
readonly properties: {
|
|
13918
|
-
readonly workspace: {
|
|
13919
|
-
readonly type: "string";
|
|
13920
|
-
readonly format: "uuid";
|
|
13921
|
-
readonly description: "Workspace identifier where the billing is created.";
|
|
13922
|
-
};
|
|
13923
|
-
readonly country: {
|
|
13924
|
-
readonly type: "string";
|
|
13925
|
-
readonly enum: readonly [
|
|
13926
|
-
"RU"
|
|
13927
|
-
];
|
|
13928
|
-
readonly description: "Country code.";
|
|
13929
|
-
};
|
|
13930
|
-
readonly companyName: {
|
|
13931
|
-
readonly type: "string";
|
|
13932
|
-
readonly description: "Company name.";
|
|
13933
|
-
};
|
|
13934
|
-
readonly inn: {
|
|
13935
|
-
readonly type: "string";
|
|
13936
|
-
readonly description: "INN (tax ID).";
|
|
13937
|
-
};
|
|
13938
|
-
readonly kpp: {
|
|
13939
|
-
readonly type: "string";
|
|
13940
|
-
readonly description: "KPP.";
|
|
13941
|
-
};
|
|
13942
|
-
readonly bankBranch: {
|
|
13943
|
-
readonly type: "string";
|
|
13944
|
-
readonly description: "Bank branch.";
|
|
13945
|
-
};
|
|
13946
|
-
readonly bankAccountNumber: {
|
|
13947
|
-
readonly type: "string";
|
|
13948
|
-
readonly description: "Bank account number.";
|
|
13949
|
-
};
|
|
13950
|
-
readonly bankBik: {
|
|
13951
|
-
readonly type: "string";
|
|
13952
|
-
readonly description: "Bank BIK.";
|
|
13953
|
-
};
|
|
13954
|
-
readonly bankKc: {
|
|
13955
|
-
readonly type: "string";
|
|
13956
|
-
readonly description: "Bank correspondent account (KC).";
|
|
13957
|
-
};
|
|
13958
|
-
readonly vat: {
|
|
13959
|
-
readonly type: "boolean";
|
|
13960
|
-
readonly description: "Whether VAT applies.";
|
|
13961
|
-
};
|
|
13962
|
-
readonly vatRate: {
|
|
13963
|
-
readonly type: "number";
|
|
13964
|
-
readonly minimum: 0;
|
|
13965
|
-
readonly maximum: 100;
|
|
13966
|
-
readonly description: "VAT rate (0-100) when vat is true.";
|
|
13967
|
-
};
|
|
13968
|
-
};
|
|
13969
|
-
};
|
|
13970
|
-
};
|
|
13971
|
-
};
|
|
13972
|
-
};
|
|
13973
|
-
readonly responses: {
|
|
13974
|
-
readonly 201: {
|
|
13975
|
-
readonly description: "Billing created successfully.";
|
|
13976
|
-
readonly content: {
|
|
13977
|
-
readonly "application/json": {
|
|
13978
|
-
readonly schema: {
|
|
13979
|
-
readonly $ref: "#/components/schemas/CreateBillingSuccess";
|
|
13980
|
-
};
|
|
13981
|
-
};
|
|
13982
|
-
};
|
|
13983
|
-
};
|
|
13984
|
-
readonly 400: {
|
|
13985
|
-
readonly description: "Invalid request payload.";
|
|
13986
|
-
readonly content: {
|
|
13987
|
-
readonly "application/json": {
|
|
13988
|
-
readonly schema: {
|
|
13989
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
13990
|
-
};
|
|
13991
|
-
};
|
|
13992
|
-
};
|
|
13993
|
-
};
|
|
13994
|
-
readonly 401: {
|
|
13995
|
-
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
13996
|
-
readonly content: {
|
|
13997
|
-
readonly "application/json": {
|
|
13998
|
-
readonly schema: {
|
|
13999
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14000
|
-
};
|
|
14001
|
-
};
|
|
14002
|
-
};
|
|
14003
|
-
};
|
|
14004
|
-
readonly 403: {
|
|
14005
|
-
readonly description: "Forbidden - User lacks workspace access, or user lacks write access to crm::general resource.";
|
|
14006
|
-
readonly content: {
|
|
14007
|
-
readonly "application/json": {
|
|
14008
|
-
readonly schema: {
|
|
14009
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14010
|
-
};
|
|
14011
|
-
};
|
|
14012
|
-
};
|
|
14013
|
-
};
|
|
14014
|
-
};
|
|
14015
|
-
};
|
|
14016
|
-
};
|
|
14017
|
-
readonly "/billings/list/{workspace}": {
|
|
14018
|
-
readonly get: {
|
|
14019
|
-
readonly tags: readonly [
|
|
14020
|
-
"Billings"
|
|
14021
|
-
];
|
|
14022
|
-
readonly summary: "List billings for a workspace";
|
|
14023
|
-
readonly description: "Returns all billings in the specified workspace. Requires workspace access and read access to crm::general resource.";
|
|
14024
|
-
readonly security: readonly [
|
|
14025
|
-
never
|
|
14026
|
-
];
|
|
14027
|
-
readonly parameters: readonly [
|
|
14028
|
-
{
|
|
14029
|
-
readonly name: "workspace";
|
|
14030
|
-
readonly in: "path";
|
|
14031
|
-
readonly required: true;
|
|
14032
|
-
readonly description: "Workspace identifier to retrieve billings for.";
|
|
14033
|
-
readonly schema: {
|
|
14034
|
-
readonly type: "string";
|
|
14035
|
-
readonly format: "uuid";
|
|
14036
|
-
};
|
|
14037
|
-
}
|
|
14038
|
-
];
|
|
14039
|
-
readonly responses: {
|
|
14040
|
-
readonly 200: {
|
|
14041
|
-
readonly description: "Billings fetched successfully.";
|
|
14042
|
-
readonly content: {
|
|
14043
|
-
readonly "application/json": {
|
|
14044
|
-
readonly schema: {
|
|
14045
|
-
readonly $ref: "#/components/schemas/ListBillingsSuccess";
|
|
14046
|
-
};
|
|
14047
|
-
};
|
|
14048
|
-
};
|
|
14049
|
-
};
|
|
14050
|
-
readonly 400: {
|
|
14051
|
-
readonly description: "Invalid workspace id.";
|
|
14052
|
-
readonly content: {
|
|
14053
|
-
readonly "application/json": {
|
|
14054
|
-
readonly schema: {
|
|
14055
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14056
|
-
};
|
|
14057
|
-
};
|
|
14058
|
-
};
|
|
14059
|
-
};
|
|
14060
|
-
readonly 401: {
|
|
14061
|
-
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
14062
|
-
readonly content: {
|
|
14063
|
-
readonly "application/json": {
|
|
14064
|
-
readonly schema: {
|
|
14065
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14066
|
-
};
|
|
14067
|
-
};
|
|
14068
|
-
};
|
|
14069
|
-
};
|
|
14070
|
-
readonly 403: {
|
|
14071
|
-
readonly description: "Forbidden - User lacks workspace access, or user lacks read access to crm::general resource.";
|
|
14072
|
-
readonly content: {
|
|
14073
|
-
readonly "application/json": {
|
|
14074
|
-
readonly schema: {
|
|
14075
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14076
|
-
};
|
|
14077
|
-
};
|
|
14078
|
-
};
|
|
14079
|
-
};
|
|
14080
|
-
};
|
|
14081
|
-
};
|
|
14082
|
-
};
|
|
14083
|
-
readonly "/billings/get/{workspace}/{billingId}": {
|
|
14084
|
-
readonly get: {
|
|
14085
|
-
readonly tags: readonly [
|
|
14086
|
-
"Billings"
|
|
14087
|
-
];
|
|
14088
|
-
readonly summary: "Get a single billing";
|
|
14089
|
-
readonly description: "Returns a single billing by ID from the specified workspace. Requires workspace access and read access to crm::general resource.";
|
|
14090
|
-
readonly security: readonly [
|
|
14091
|
-
never
|
|
14092
|
-
];
|
|
14093
|
-
readonly parameters: readonly [
|
|
14094
|
-
{
|
|
14095
|
-
readonly name: "workspace";
|
|
14096
|
-
readonly in: "path";
|
|
14097
|
-
readonly required: true;
|
|
14098
|
-
readonly description: "Workspace identifier where the billing belongs.";
|
|
14099
|
-
readonly schema: {
|
|
14100
|
-
readonly type: "string";
|
|
14101
|
-
readonly format: "uuid";
|
|
14102
|
-
};
|
|
14103
|
-
},
|
|
14104
|
-
{
|
|
14105
|
-
readonly name: "billingId";
|
|
14106
|
-
readonly in: "path";
|
|
14107
|
-
readonly required: true;
|
|
14108
|
-
readonly description: "Billing identifier to retrieve.";
|
|
14109
|
-
readonly schema: {
|
|
14110
|
-
readonly type: "string";
|
|
14111
|
-
readonly format: "uuid";
|
|
14112
|
-
};
|
|
14113
|
-
}
|
|
14114
|
-
];
|
|
14115
|
-
readonly responses: {
|
|
14116
|
-
readonly 200: {
|
|
14117
|
-
readonly description: "Billing fetched successfully.";
|
|
14118
|
-
readonly content: {
|
|
14119
|
-
readonly "application/json": {
|
|
14120
|
-
readonly schema: {
|
|
14121
|
-
readonly $ref: "#/components/schemas/GetBillingSuccess";
|
|
14122
|
-
};
|
|
14123
|
-
};
|
|
14124
|
-
};
|
|
14125
|
-
};
|
|
14126
|
-
readonly 400: {
|
|
14127
|
-
readonly description: "Invalid workspace id or billing id.";
|
|
14128
|
-
readonly content: {
|
|
14129
|
-
readonly "application/json": {
|
|
14130
|
-
readonly schema: {
|
|
14131
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14132
|
-
};
|
|
14133
|
-
};
|
|
14134
|
-
};
|
|
14135
|
-
};
|
|
14136
|
-
readonly 401: {
|
|
14137
|
-
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
14138
|
-
readonly content: {
|
|
14139
|
-
readonly "application/json": {
|
|
14140
|
-
readonly schema: {
|
|
14141
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14142
|
-
};
|
|
14143
|
-
};
|
|
14144
|
-
};
|
|
14145
|
-
};
|
|
14146
|
-
readonly 403: {
|
|
14147
|
-
readonly description: "Forbidden - User lacks workspace access, or user lacks read access to crm::general resource.";
|
|
14148
|
-
readonly content: {
|
|
14149
|
-
readonly "application/json": {
|
|
14150
|
-
readonly schema: {
|
|
14151
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14152
|
-
};
|
|
14153
|
-
};
|
|
14154
|
-
};
|
|
14155
|
-
};
|
|
14156
|
-
readonly 404: {
|
|
14157
|
-
readonly description: "Billing not found.";
|
|
14158
|
-
readonly content: {
|
|
14159
|
-
readonly "application/json": {
|
|
14160
|
-
readonly schema: {
|
|
14161
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14162
|
-
};
|
|
14163
|
-
};
|
|
14164
|
-
};
|
|
14165
|
-
};
|
|
14166
|
-
};
|
|
14167
|
-
};
|
|
14168
|
-
};
|
|
14169
|
-
readonly "/billings/edit": {
|
|
14170
|
-
readonly post: {
|
|
14171
|
-
readonly tags: readonly [
|
|
14172
|
-
"Billings"
|
|
14173
|
-
];
|
|
14174
|
-
readonly summary: "Edit a billing";
|
|
14175
|
-
readonly description: "Updates a billing in the specified workspace. Requires workspace access and write access to crm::general resource.";
|
|
14176
|
-
readonly security: readonly [
|
|
14177
|
-
never
|
|
14178
|
-
];
|
|
14179
|
-
readonly requestBody: {
|
|
14180
|
-
readonly required: true;
|
|
14181
|
-
readonly content: {
|
|
14182
|
-
readonly "application/json": {
|
|
14183
|
-
readonly schema: {
|
|
14184
|
-
readonly type: "object";
|
|
14185
|
-
readonly required: readonly [
|
|
14186
|
-
"billingId",
|
|
14187
|
-
"workspace",
|
|
14188
|
-
"nds",
|
|
14189
|
-
"ndsRate"
|
|
14190
|
-
];
|
|
14191
|
-
readonly properties: {
|
|
14192
|
-
readonly billingId: {
|
|
14193
|
-
readonly type: "string";
|
|
14194
|
-
readonly format: "uuid";
|
|
14195
|
-
readonly description: "Billing identifier to edit.";
|
|
14196
|
-
};
|
|
14197
|
-
readonly workspace: {
|
|
14198
|
-
readonly type: "string";
|
|
14199
|
-
readonly format: "uuid";
|
|
14200
|
-
readonly description: "Workspace identifier where the billing belongs.";
|
|
14201
|
-
};
|
|
14202
|
-
readonly country: {
|
|
14203
|
-
readonly type: "string";
|
|
14204
|
-
readonly enum: readonly [
|
|
14205
|
-
"RU"
|
|
14206
|
-
];
|
|
14207
|
-
readonly description: "Country code.";
|
|
14208
|
-
};
|
|
14209
|
-
readonly companyName: {
|
|
14210
|
-
readonly type: "string";
|
|
14211
|
-
readonly description: "Company name.";
|
|
14212
|
-
};
|
|
14213
|
-
readonly inn: {
|
|
14214
|
-
readonly type: "string";
|
|
14215
|
-
readonly description: "INN (tax ID).";
|
|
14216
|
-
};
|
|
14217
|
-
readonly kpp: {
|
|
14218
|
-
readonly type: "string";
|
|
14219
|
-
readonly description: "KPP.";
|
|
14220
|
-
};
|
|
14221
|
-
readonly bankBranch: {
|
|
14222
|
-
readonly type: "string";
|
|
14223
|
-
readonly description: "Bank branch.";
|
|
14224
|
-
};
|
|
14225
|
-
readonly bankAccountNumber: {
|
|
14226
|
-
readonly type: "string";
|
|
14227
|
-
readonly description: "Bank account number.";
|
|
14228
|
-
};
|
|
14229
|
-
readonly bankBik: {
|
|
14230
|
-
readonly type: "string";
|
|
14231
|
-
readonly description: "Bank BIK.";
|
|
14232
|
-
};
|
|
14233
|
-
readonly bankKc: {
|
|
14234
|
-
readonly type: "string";
|
|
14235
|
-
readonly description: "Bank correspondent account (KC).";
|
|
14236
|
-
};
|
|
14237
|
-
readonly nds: {
|
|
14238
|
-
readonly type: "boolean";
|
|
14239
|
-
readonly description: "Whether VAT (NDS) applies.";
|
|
14240
|
-
};
|
|
14241
|
-
readonly ndsRate: {
|
|
14242
|
-
readonly type: "number";
|
|
14243
|
-
readonly minimum: 0;
|
|
14244
|
-
readonly maximum: 100;
|
|
14245
|
-
readonly description: "VAT rate (0-100) when nds is true.";
|
|
14246
|
-
};
|
|
14247
|
-
};
|
|
14248
|
-
};
|
|
14249
|
-
};
|
|
14250
|
-
};
|
|
14251
|
-
};
|
|
14252
|
-
readonly responses: {
|
|
14253
|
-
readonly 200: {
|
|
14254
|
-
readonly description: "Billing updated successfully.";
|
|
14255
|
-
readonly content: {
|
|
14256
|
-
readonly "application/json": {
|
|
14257
|
-
readonly schema: {
|
|
14258
|
-
readonly $ref: "#/components/schemas/SimpleSuccess";
|
|
14259
|
-
};
|
|
14260
|
-
};
|
|
14261
|
-
};
|
|
14262
|
-
};
|
|
14263
|
-
readonly 400: {
|
|
14264
|
-
readonly description: "Invalid request payload.";
|
|
14265
|
-
readonly content: {
|
|
14266
|
-
readonly "application/json": {
|
|
14267
|
-
readonly schema: {
|
|
14268
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14269
|
-
};
|
|
14270
|
-
};
|
|
14271
|
-
};
|
|
14272
|
-
};
|
|
14273
|
-
readonly 401: {
|
|
14274
|
-
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
14275
|
-
readonly content: {
|
|
14276
|
-
readonly "application/json": {
|
|
14277
|
-
readonly schema: {
|
|
14278
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14279
|
-
};
|
|
14280
|
-
};
|
|
14281
|
-
};
|
|
14282
|
-
};
|
|
14283
|
-
readonly 403: {
|
|
14284
|
-
readonly description: "Forbidden - User lacks workspace access, or user lacks write access to crm::general resource.";
|
|
14285
|
-
readonly content: {
|
|
14286
|
-
readonly "application/json": {
|
|
14287
|
-
readonly schema: {
|
|
14288
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14289
|
-
};
|
|
14290
|
-
};
|
|
14291
|
-
};
|
|
14292
|
-
};
|
|
14293
|
-
readonly 404: {
|
|
14294
|
-
readonly description: "Billing not found.";
|
|
14295
|
-
readonly content: {
|
|
14296
|
-
readonly "application/json": {
|
|
14297
|
-
readonly schema: {
|
|
14298
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14299
|
-
};
|
|
14300
|
-
};
|
|
14301
|
-
};
|
|
14302
|
-
};
|
|
14303
|
-
};
|
|
14304
|
-
};
|
|
14305
|
-
};
|
|
14306
|
-
readonly "/billings/delete": {
|
|
14307
|
-
readonly post: {
|
|
14308
|
-
readonly tags: readonly [
|
|
14309
|
-
"Billings"
|
|
14310
|
-
];
|
|
14311
|
-
readonly summary: "Delete a billing";
|
|
14312
|
-
readonly description: "Deletes a billing from the specified workspace. Requires workspace access and write access to crm::general resource.";
|
|
14313
|
-
readonly security: readonly [
|
|
14314
|
-
never
|
|
14315
|
-
];
|
|
14316
|
-
readonly requestBody: {
|
|
14317
|
-
readonly required: true;
|
|
14318
|
-
readonly content: {
|
|
14319
|
-
readonly "application/json": {
|
|
14320
|
-
readonly schema: {
|
|
14321
|
-
readonly type: "object";
|
|
14322
|
-
readonly required: readonly [
|
|
14323
|
-
"billingId",
|
|
14324
|
-
"workspace"
|
|
14325
|
-
];
|
|
14326
|
-
readonly properties: {
|
|
14327
|
-
readonly billingId: {
|
|
14328
|
-
readonly type: "string";
|
|
14329
|
-
readonly format: "uuid";
|
|
14330
|
-
readonly description: "Billing identifier to delete.";
|
|
14331
|
-
};
|
|
14332
|
-
readonly workspace: {
|
|
14333
|
-
readonly type: "string";
|
|
14334
|
-
readonly format: "uuid";
|
|
14335
|
-
readonly description: "Workspace identifier where the billing belongs.";
|
|
14336
|
-
};
|
|
14337
|
-
};
|
|
14338
|
-
};
|
|
14339
|
-
};
|
|
14340
|
-
};
|
|
14341
|
-
};
|
|
14342
|
-
readonly responses: {
|
|
14343
|
-
readonly 200: {
|
|
14344
|
-
readonly description: "Billing deleted successfully.";
|
|
14345
|
-
readonly content: {
|
|
14346
|
-
readonly "application/json": {
|
|
14347
|
-
readonly schema: {
|
|
14348
|
-
readonly $ref: "#/components/schemas/SimpleSuccess";
|
|
14349
|
-
};
|
|
14350
|
-
};
|
|
14351
|
-
};
|
|
14352
|
-
};
|
|
14353
|
-
readonly 400: {
|
|
14354
|
-
readonly description: "Invalid request payload.";
|
|
14355
|
-
readonly content: {
|
|
14356
|
-
readonly "application/json": {
|
|
14357
|
-
readonly schema: {
|
|
14358
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14359
|
-
};
|
|
14360
|
-
};
|
|
14361
|
-
};
|
|
14362
|
-
};
|
|
14363
|
-
readonly 401: {
|
|
14364
|
-
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
14365
|
-
readonly content: {
|
|
14366
|
-
readonly "application/json": {
|
|
14367
|
-
readonly schema: {
|
|
14368
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14369
|
-
};
|
|
14370
|
-
};
|
|
14371
|
-
};
|
|
14372
|
-
};
|
|
14373
|
-
readonly 403: {
|
|
14374
|
-
readonly description: "Forbidden - User lacks workspace access, or user lacks write access to crm::general resource.";
|
|
14375
|
-
readonly content: {
|
|
14376
|
-
readonly "application/json": {
|
|
14377
|
-
readonly schema: {
|
|
14378
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14379
|
-
};
|
|
14380
|
-
};
|
|
14381
|
-
};
|
|
14382
|
-
};
|
|
14383
|
-
readonly 404: {
|
|
14384
|
-
readonly description: "Billing not found.";
|
|
14385
|
-
readonly content: {
|
|
14386
|
-
readonly "application/json": {
|
|
14387
|
-
readonly schema: {
|
|
14388
|
-
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
14389
|
-
};
|
|
14390
|
-
};
|
|
14391
|
-
};
|
|
14392
|
-
};
|
|
14393
|
-
};
|
|
14394
|
-
};
|
|
14395
|
-
};
|
|
14396
|
-
readonly "/analytics/{workspace}/task-phase-funnel": {
|
|
14397
|
-
readonly get: {
|
|
14398
|
-
readonly tags: readonly [
|
|
14399
|
-
"Analytics"
|
|
14400
|
-
];
|
|
14401
|
-
readonly summary: "Get real-estate task-phase funnel and durations";
|
|
14402
|
-
readonly description: "Returns the current task funnel and time-in-phase analytics for a real-estate workspace. taskCount is the number of tasks currently in each phase; when supplied, from and to limit it to tasks created in that period. visitCount and duration averages use phase entries recorded in the period. Active phase visits are measured through now, or through to when supplied. Tracking begins when this API version is deployed, so tasks that have not changed phase since then have no duration sample. Requires workspace access and read access to crm::analytics. Other workspace categories return 400.";
|
|
14017
|
+
readonly summary: "Get real-estate task-phase funnel and durations";
|
|
14018
|
+
readonly description: "Returns the current task funnel and time-in-phase analytics for a real-estate workspace. taskCount is the number of tasks currently in each phase; when supplied, from and to limit it to tasks created in that period. visitCount and duration averages use phase entries recorded in the period. Active phase visits are measured through now, or through to when supplied. Tracking begins when this API version is deployed, so tasks that have not changed phase since then have no duration sample. Requires workspace access and read access to crm::analytics. Other workspace categories return 400.";
|
|
14403
14019
|
readonly security: readonly [
|
|
14404
14020
|
never
|
|
14405
14021
|
];
|
|
@@ -15167,7 +14783,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15167
14783
|
"CInvoices"
|
|
15168
14784
|
];
|
|
15169
14785
|
readonly summary: "Create a customer invoice";
|
|
15170
|
-
readonly description: "Creates a customer invoice in the specified workspace. Real-estate workspaces require an existing seller
|
|
14786
|
+
readonly description: "Creates a customer invoice in the specified workspace. Real-estate workspaces require an existing seller finance account, customer_real_estates lead, and service_real_estates listing in the same workspace. created_by is taken from the access token. When status is paid, an income finance transaction is recorded on the seller account for unitPrice \u00D7 unitQuantity \u2212 discount (minor units converted to major units). Requires workspace access and write access to crm::customers. Other workspace categories return 400.";
|
|
15171
14787
|
readonly security: readonly [
|
|
15172
14788
|
never
|
|
15173
14789
|
];
|
|
@@ -15181,7 +14797,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15181
14797
|
"workspace",
|
|
15182
14798
|
"invoiceId",
|
|
15183
14799
|
"serviceId",
|
|
15184
|
-
"
|
|
14800
|
+
"SellerFinanceAccountId",
|
|
15185
14801
|
"customerId",
|
|
15186
14802
|
"date",
|
|
15187
14803
|
"language",
|
|
@@ -15206,10 +14822,10 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15206
14822
|
readonly format: "uuid";
|
|
15207
14823
|
readonly description: "Real-estate service identifier.";
|
|
15208
14824
|
};
|
|
15209
|
-
readonly
|
|
14825
|
+
readonly SellerFinanceAccountId: {
|
|
15210
14826
|
readonly type: "string";
|
|
15211
14827
|
readonly format: "uuid";
|
|
15212
|
-
readonly description: "Seller
|
|
14828
|
+
readonly description: "Seller finance account identifier.";
|
|
15213
14829
|
};
|
|
15214
14830
|
readonly customerId: {
|
|
15215
14831
|
readonly type: "string";
|
|
@@ -15368,6 +14984,62 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15368
14984
|
};
|
|
15369
14985
|
};
|
|
15370
14986
|
};
|
|
14987
|
+
readonly "/cinvoices/accounts/list/{workspace}": {
|
|
14988
|
+
readonly get: {
|
|
14989
|
+
readonly tags: readonly [
|
|
14990
|
+
"CInvoices"
|
|
14991
|
+
];
|
|
14992
|
+
readonly summary: "List finance accounts for invoice seller selection";
|
|
14993
|
+
readonly description: "Returns workspace finance accounts for choosing SellerFinanceAccountId when creating or updating a customer invoice. Requires workspace access and read access to crm::customers, not crm::finance. Includes company and bank details, but omits openingBalance.";
|
|
14994
|
+
readonly security: readonly [
|
|
14995
|
+
never
|
|
14996
|
+
];
|
|
14997
|
+
readonly parameters: readonly [
|
|
14998
|
+
{
|
|
14999
|
+
readonly name: "workspace";
|
|
15000
|
+
readonly in: "path";
|
|
15001
|
+
readonly required: true;
|
|
15002
|
+
readonly schema: {
|
|
15003
|
+
readonly type: "string";
|
|
15004
|
+
readonly format: "uuid";
|
|
15005
|
+
};
|
|
15006
|
+
readonly description: "Workspace identifier.";
|
|
15007
|
+
}
|
|
15008
|
+
];
|
|
15009
|
+
readonly responses: {
|
|
15010
|
+
readonly 200: {
|
|
15011
|
+
readonly description: "Accounts fetched successfully.";
|
|
15012
|
+
readonly content: {
|
|
15013
|
+
readonly "application/json": {
|
|
15014
|
+
readonly schema: {
|
|
15015
|
+
readonly $ref: "#/components/schemas/ListCInvoiceFinanceAccountsSuccess";
|
|
15016
|
+
};
|
|
15017
|
+
};
|
|
15018
|
+
};
|
|
15019
|
+
};
|
|
15020
|
+
readonly 401: {
|
|
15021
|
+
readonly description: "Unauthorized - Missing or invalid access token.";
|
|
15022
|
+
readonly content: {
|
|
15023
|
+
readonly "application/json": {
|
|
15024
|
+
readonly schema: {
|
|
15025
|
+
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
15026
|
+
};
|
|
15027
|
+
};
|
|
15028
|
+
};
|
|
15029
|
+
};
|
|
15030
|
+
readonly 403: {
|
|
15031
|
+
readonly description: "Forbidden - User lacks workspace access, or user lacks read access to crm::customers resource.";
|
|
15032
|
+
readonly content: {
|
|
15033
|
+
readonly "application/json": {
|
|
15034
|
+
readonly schema: {
|
|
15035
|
+
readonly $ref: "#/components/schemas/ErrorResponse";
|
|
15036
|
+
};
|
|
15037
|
+
};
|
|
15038
|
+
};
|
|
15039
|
+
};
|
|
15040
|
+
};
|
|
15041
|
+
};
|
|
15042
|
+
};
|
|
15371
15043
|
readonly "/cinvoices/list/{workspace}/{customerId}": {
|
|
15372
15044
|
readonly get: {
|
|
15373
15045
|
readonly tags: readonly [
|
|
@@ -15460,7 +15132,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15460
15132
|
"CInvoices"
|
|
15461
15133
|
];
|
|
15462
15134
|
readonly summary: "Update a customer invoice";
|
|
15463
|
-
readonly description: "Updates specified fields of an invoice in a real-estate workspace. Any replacement seller
|
|
15135
|
+
readonly description: "Updates specified fields of an invoice in a real-estate workspace. Any replacement seller finance account, customer, or service must belong to the workspace. When status changes to paid, an income finance transaction is recorded on the seller account for unitPrice \u00D7 unitQuantity \u2212 discount (minor units converted to major units). Requires workspace access and write access to crm::customers.";
|
|
15464
15136
|
readonly security: readonly [
|
|
15465
15137
|
never
|
|
15466
15138
|
];
|
|
@@ -15494,10 +15166,10 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
15494
15166
|
readonly format: "uuid";
|
|
15495
15167
|
readonly description: "Replacement real-estate service identifier.";
|
|
15496
15168
|
};
|
|
15497
|
-
readonly
|
|
15169
|
+
readonly SellerFinanceAccountId: {
|
|
15498
15170
|
readonly type: "string";
|
|
15499
15171
|
readonly format: "uuid";
|
|
15500
|
-
readonly description: "Replacement seller
|
|
15172
|
+
readonly description: "Replacement seller finance account identifier.";
|
|
15501
15173
|
};
|
|
15502
15174
|
readonly customerId: {
|
|
15503
15175
|
readonly type: "string";
|
|
@@ -20489,25 +20161,67 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
20489
20161
|
readonly properties: {
|
|
20490
20162
|
readonly workspace: {
|
|
20491
20163
|
readonly type: "string";
|
|
20492
|
-
readonly format: "uuid";
|
|
20164
|
+
readonly format: "uuid";
|
|
20165
|
+
};
|
|
20166
|
+
readonly name: {
|
|
20167
|
+
readonly type: "string";
|
|
20168
|
+
};
|
|
20169
|
+
readonly cardColor: {
|
|
20170
|
+
readonly type: "string";
|
|
20171
|
+
readonly description: "6-digit hex color, with or without #.";
|
|
20172
|
+
};
|
|
20173
|
+
readonly currency: {
|
|
20174
|
+
readonly type: "string";
|
|
20175
|
+
readonly enum: readonly [
|
|
20176
|
+
"ruble",
|
|
20177
|
+
"dollar",
|
|
20178
|
+
"euro"
|
|
20179
|
+
];
|
|
20180
|
+
};
|
|
20181
|
+
readonly openingBalance: {
|
|
20182
|
+
readonly type: "number";
|
|
20183
|
+
};
|
|
20184
|
+
readonly country: {
|
|
20185
|
+
readonly type: "string";
|
|
20186
|
+
};
|
|
20187
|
+
readonly companyName: {
|
|
20188
|
+
readonly type: "string";
|
|
20189
|
+
};
|
|
20190
|
+
readonly inn: {
|
|
20191
|
+
readonly type: "string";
|
|
20493
20192
|
};
|
|
20494
|
-
readonly
|
|
20193
|
+
readonly kpp: {
|
|
20495
20194
|
readonly type: "string";
|
|
20496
20195
|
};
|
|
20497
|
-
readonly
|
|
20196
|
+
readonly ogrn: {
|
|
20498
20197
|
readonly type: "string";
|
|
20499
|
-
readonly description: "6-digit hex color, with or without #.";
|
|
20500
20198
|
};
|
|
20501
|
-
readonly
|
|
20199
|
+
readonly bankName: {
|
|
20502
20200
|
readonly type: "string";
|
|
20503
|
-
readonly enum: readonly [
|
|
20504
|
-
"ruble",
|
|
20505
|
-
"dollar",
|
|
20506
|
-
"euro"
|
|
20507
|
-
];
|
|
20508
20201
|
};
|
|
20509
|
-
readonly
|
|
20510
|
-
readonly type: "
|
|
20202
|
+
readonly bankAccountNumber: {
|
|
20203
|
+
readonly type: "string";
|
|
20204
|
+
};
|
|
20205
|
+
readonly bankBik: {
|
|
20206
|
+
readonly type: "string";
|
|
20207
|
+
};
|
|
20208
|
+
readonly bankKc: {
|
|
20209
|
+
readonly type: "string";
|
|
20210
|
+
};
|
|
20211
|
+
readonly bankInn: {
|
|
20212
|
+
readonly type: "string";
|
|
20213
|
+
};
|
|
20214
|
+
readonly bankKpp: {
|
|
20215
|
+
readonly type: "string";
|
|
20216
|
+
};
|
|
20217
|
+
readonly vatRate: {
|
|
20218
|
+
readonly type: "integer";
|
|
20219
|
+
readonly minimum: 0;
|
|
20220
|
+
readonly maximum: 100;
|
|
20221
|
+
};
|
|
20222
|
+
readonly active: {
|
|
20223
|
+
readonly type: "boolean";
|
|
20224
|
+
readonly description: "Defaults to true.";
|
|
20511
20225
|
};
|
|
20512
20226
|
};
|
|
20513
20227
|
};
|
|
@@ -20564,7 +20278,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
20564
20278
|
"Finance"
|
|
20565
20279
|
];
|
|
20566
20280
|
readonly summary: "Update a finance account";
|
|
20567
|
-
readonly description: "Updates
|
|
20281
|
+
readonly description: "Updates account card fields and optional company/bank details. Requires crm::finance write access.";
|
|
20568
20282
|
readonly security: readonly [
|
|
20569
20283
|
never
|
|
20570
20284
|
];
|
|
@@ -20604,6 +20318,47 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
20604
20318
|
readonly openingBalance: {
|
|
20605
20319
|
readonly type: "number";
|
|
20606
20320
|
};
|
|
20321
|
+
readonly country: {
|
|
20322
|
+
readonly type: "string";
|
|
20323
|
+
};
|
|
20324
|
+
readonly companyName: {
|
|
20325
|
+
readonly type: "string";
|
|
20326
|
+
};
|
|
20327
|
+
readonly inn: {
|
|
20328
|
+
readonly type: "string";
|
|
20329
|
+
};
|
|
20330
|
+
readonly kpp: {
|
|
20331
|
+
readonly type: "string";
|
|
20332
|
+
};
|
|
20333
|
+
readonly ogrn: {
|
|
20334
|
+
readonly type: "string";
|
|
20335
|
+
};
|
|
20336
|
+
readonly bankName: {
|
|
20337
|
+
readonly type: "string";
|
|
20338
|
+
};
|
|
20339
|
+
readonly bankAccountNumber: {
|
|
20340
|
+
readonly type: "string";
|
|
20341
|
+
};
|
|
20342
|
+
readonly bankBik: {
|
|
20343
|
+
readonly type: "string";
|
|
20344
|
+
};
|
|
20345
|
+
readonly bankKc: {
|
|
20346
|
+
readonly type: "string";
|
|
20347
|
+
};
|
|
20348
|
+
readonly bankInn: {
|
|
20349
|
+
readonly type: "string";
|
|
20350
|
+
};
|
|
20351
|
+
readonly bankKpp: {
|
|
20352
|
+
readonly type: "string";
|
|
20353
|
+
};
|
|
20354
|
+
readonly vatRate: {
|
|
20355
|
+
readonly type: "integer";
|
|
20356
|
+
readonly minimum: 0;
|
|
20357
|
+
readonly maximum: 100;
|
|
20358
|
+
};
|
|
20359
|
+
readonly active: {
|
|
20360
|
+
readonly type: "boolean";
|
|
20361
|
+
};
|
|
20607
20362
|
};
|
|
20608
20363
|
};
|
|
20609
20364
|
};
|
|
@@ -24245,185 +24000,6 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
24245
24000
|
};
|
|
24246
24001
|
};
|
|
24247
24002
|
}, "/customers"> | import("hono/types").MergeSchemaPath<{
|
|
24248
|
-
"/create": {
|
|
24249
|
-
$post: {
|
|
24250
|
-
input: {};
|
|
24251
|
-
output: {
|
|
24252
|
-
success: false;
|
|
24253
|
-
error: never;
|
|
24254
|
-
};
|
|
24255
|
-
outputFormat: "json";
|
|
24256
|
-
status: 400;
|
|
24257
|
-
} | {
|
|
24258
|
-
input: {};
|
|
24259
|
-
output: {
|
|
24260
|
-
success: true;
|
|
24261
|
-
billing: {
|
|
24262
|
-
id: string;
|
|
24263
|
-
created_at: string;
|
|
24264
|
-
active: boolean | null;
|
|
24265
|
-
workspaceId: string;
|
|
24266
|
-
country: string;
|
|
24267
|
-
companyName: string;
|
|
24268
|
-
inn: string;
|
|
24269
|
-
kpp: string;
|
|
24270
|
-
bankBranch: string;
|
|
24271
|
-
bankAccountNumber: string;
|
|
24272
|
-
bankBik: string;
|
|
24273
|
-
bankKc: string;
|
|
24274
|
-
vat: boolean;
|
|
24275
|
-
vatRate: number;
|
|
24276
|
-
updated_at: string | null;
|
|
24277
|
-
deleted_at: string | null;
|
|
24278
|
-
verified_at: string | null;
|
|
24279
|
-
suspended_at: string | null;
|
|
24280
|
-
}[];
|
|
24281
|
-
};
|
|
24282
|
-
outputFormat: "json";
|
|
24283
|
-
status: 201;
|
|
24284
|
-
};
|
|
24285
|
-
};
|
|
24286
|
-
} & {
|
|
24287
|
-
"/list/:workspace": {
|
|
24288
|
-
$get: {
|
|
24289
|
-
input: {
|
|
24290
|
-
param: {
|
|
24291
|
-
workspace: string;
|
|
24292
|
-
};
|
|
24293
|
-
};
|
|
24294
|
-
output: {
|
|
24295
|
-
success: true;
|
|
24296
|
-
billings: {
|
|
24297
|
-
updated_at: string | null;
|
|
24298
|
-
deleted_at: string | null;
|
|
24299
|
-
verified_at: string | null;
|
|
24300
|
-
suspended_at: string | null;
|
|
24301
|
-
created_at: string;
|
|
24302
|
-
id: string;
|
|
24303
|
-
workspaceId: string;
|
|
24304
|
-
country: string;
|
|
24305
|
-
companyName: string;
|
|
24306
|
-
inn: string;
|
|
24307
|
-
kpp: string;
|
|
24308
|
-
bankBranch: string;
|
|
24309
|
-
bankAccountNumber: string;
|
|
24310
|
-
bankBik: string;
|
|
24311
|
-
bankKc: string;
|
|
24312
|
-
vat: boolean;
|
|
24313
|
-
vatRate: number;
|
|
24314
|
-
active: boolean | null;
|
|
24315
|
-
}[];
|
|
24316
|
-
};
|
|
24317
|
-
outputFormat: "json";
|
|
24318
|
-
status: 200;
|
|
24319
|
-
};
|
|
24320
|
-
};
|
|
24321
|
-
} & {
|
|
24322
|
-
"/get/:workspace/:billingId": {
|
|
24323
|
-
$get: {
|
|
24324
|
-
input: {
|
|
24325
|
-
param: {
|
|
24326
|
-
workspace: string;
|
|
24327
|
-
} & {
|
|
24328
|
-
billingId: string;
|
|
24329
|
-
};
|
|
24330
|
-
};
|
|
24331
|
-
output: {
|
|
24332
|
-
success: false;
|
|
24333
|
-
error: string;
|
|
24334
|
-
};
|
|
24335
|
-
outputFormat: "json";
|
|
24336
|
-
status: 404;
|
|
24337
|
-
} | {
|
|
24338
|
-
input: {
|
|
24339
|
-
param: {
|
|
24340
|
-
workspace: string;
|
|
24341
|
-
} & {
|
|
24342
|
-
billingId: string;
|
|
24343
|
-
};
|
|
24344
|
-
};
|
|
24345
|
-
output: {
|
|
24346
|
-
success: true;
|
|
24347
|
-
billing: {
|
|
24348
|
-
updated_at: string | null;
|
|
24349
|
-
deleted_at: string | null;
|
|
24350
|
-
verified_at: string | null;
|
|
24351
|
-
suspended_at: string | null;
|
|
24352
|
-
created_at: string;
|
|
24353
|
-
id: string;
|
|
24354
|
-
workspaceId: string;
|
|
24355
|
-
country: string;
|
|
24356
|
-
companyName: string;
|
|
24357
|
-
inn: string;
|
|
24358
|
-
kpp: string;
|
|
24359
|
-
bankBranch: string;
|
|
24360
|
-
bankAccountNumber: string;
|
|
24361
|
-
bankBik: string;
|
|
24362
|
-
bankKc: string;
|
|
24363
|
-
vat: boolean;
|
|
24364
|
-
vatRate: number;
|
|
24365
|
-
active: boolean | null;
|
|
24366
|
-
};
|
|
24367
|
-
};
|
|
24368
|
-
outputFormat: "json";
|
|
24369
|
-
status: 200;
|
|
24370
|
-
};
|
|
24371
|
-
};
|
|
24372
|
-
} & {
|
|
24373
|
-
"/edit": {
|
|
24374
|
-
$post: {
|
|
24375
|
-
input: {};
|
|
24376
|
-
output: {
|
|
24377
|
-
success: false;
|
|
24378
|
-
error: never;
|
|
24379
|
-
};
|
|
24380
|
-
outputFormat: "json";
|
|
24381
|
-
status: 400;
|
|
24382
|
-
} | {
|
|
24383
|
-
input: {};
|
|
24384
|
-
output: {
|
|
24385
|
-
success: false;
|
|
24386
|
-
error: string;
|
|
24387
|
-
};
|
|
24388
|
-
outputFormat: "json";
|
|
24389
|
-
status: 404;
|
|
24390
|
-
} | {
|
|
24391
|
-
input: {};
|
|
24392
|
-
output: {
|
|
24393
|
-
success: true;
|
|
24394
|
-
};
|
|
24395
|
-
outputFormat: "json";
|
|
24396
|
-
status: 200;
|
|
24397
|
-
};
|
|
24398
|
-
};
|
|
24399
|
-
} & {
|
|
24400
|
-
"/delete": {
|
|
24401
|
-
$post: {
|
|
24402
|
-
input: {};
|
|
24403
|
-
output: {
|
|
24404
|
-
success: false;
|
|
24405
|
-
error: never;
|
|
24406
|
-
};
|
|
24407
|
-
outputFormat: "json";
|
|
24408
|
-
status: 400;
|
|
24409
|
-
} | {
|
|
24410
|
-
input: {};
|
|
24411
|
-
output: {
|
|
24412
|
-
success: false;
|
|
24413
|
-
error: string;
|
|
24414
|
-
};
|
|
24415
|
-
outputFormat: "json";
|
|
24416
|
-
status: 404;
|
|
24417
|
-
} | {
|
|
24418
|
-
input: {};
|
|
24419
|
-
output: {
|
|
24420
|
-
success: true;
|
|
24421
|
-
};
|
|
24422
|
-
outputFormat: "json";
|
|
24423
|
-
status: 200;
|
|
24424
|
-
};
|
|
24425
|
-
};
|
|
24426
|
-
}, "/billings"> | import("hono/types").MergeSchemaPath<{
|
|
24427
24003
|
"/create": {
|
|
24428
24004
|
$post: {
|
|
24429
24005
|
input: {};
|
|
@@ -24456,7 +24032,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
24456
24032
|
serviceId: string;
|
|
24457
24033
|
installment: boolean | null;
|
|
24458
24034
|
vatRate: number | null;
|
|
24459
|
-
|
|
24035
|
+
SellerFinanceAccountId: string;
|
|
24460
24036
|
date: string;
|
|
24461
24037
|
language: string;
|
|
24462
24038
|
currency: string;
|
|
@@ -24483,6 +24059,44 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
24483
24059
|
status: 201;
|
|
24484
24060
|
};
|
|
24485
24061
|
};
|
|
24062
|
+
} & {
|
|
24063
|
+
"/accounts/list/:workspace": {
|
|
24064
|
+
$get: {
|
|
24065
|
+
input: {
|
|
24066
|
+
param: {
|
|
24067
|
+
workspace: string;
|
|
24068
|
+
};
|
|
24069
|
+
};
|
|
24070
|
+
output: {
|
|
24071
|
+
success: true;
|
|
24072
|
+
accounts: {
|
|
24073
|
+
id: string;
|
|
24074
|
+
created_at: string;
|
|
24075
|
+
name: string;
|
|
24076
|
+
active: boolean;
|
|
24077
|
+
workspaceId: string;
|
|
24078
|
+
country: string | null;
|
|
24079
|
+
companyName: string | null;
|
|
24080
|
+
inn: string | null;
|
|
24081
|
+
kpp: string | null;
|
|
24082
|
+
bankAccountNumber: string | null;
|
|
24083
|
+
bankBik: string | null;
|
|
24084
|
+
bankKc: string | null;
|
|
24085
|
+
vatRate: number | null;
|
|
24086
|
+
currency: FinanceCurrency;
|
|
24087
|
+
order: number;
|
|
24088
|
+
cardColor: string;
|
|
24089
|
+
updated_at: string | null;
|
|
24090
|
+
ogrn: string | null;
|
|
24091
|
+
bankName: string | null;
|
|
24092
|
+
bankInn: string | null;
|
|
24093
|
+
bankKpp: string | null;
|
|
24094
|
+
}[];
|
|
24095
|
+
};
|
|
24096
|
+
outputFormat: "json";
|
|
24097
|
+
status: 200;
|
|
24098
|
+
};
|
|
24099
|
+
};
|
|
24486
24100
|
} & {
|
|
24487
24101
|
"/list/:workspace/:customerId": {
|
|
24488
24102
|
$get: {
|
|
@@ -24533,7 +24147,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
24533
24147
|
workspaceId: string;
|
|
24534
24148
|
invoiceId: string;
|
|
24535
24149
|
serviceId: string;
|
|
24536
|
-
|
|
24150
|
+
SellerFinanceAccountId: string;
|
|
24537
24151
|
customerId: string;
|
|
24538
24152
|
date: string;
|
|
24539
24153
|
language: string;
|
|
@@ -24594,7 +24208,7 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
24594
24208
|
serviceId: string;
|
|
24595
24209
|
installment: boolean | null;
|
|
24596
24210
|
vatRate: number | null;
|
|
24597
|
-
|
|
24211
|
+
SellerFinanceAccountId: string;
|
|
24598
24212
|
date: string;
|
|
24599
24213
|
language: string;
|
|
24600
24214
|
currency: string;
|
|
@@ -30563,6 +30177,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30563
30177
|
cardColor: string;
|
|
30564
30178
|
currency: FinanceCurrency;
|
|
30565
30179
|
openingBalance: number;
|
|
30180
|
+
country: string | null;
|
|
30181
|
+
companyName: string | null;
|
|
30182
|
+
inn: string | null;
|
|
30183
|
+
kpp: string | null;
|
|
30184
|
+
ogrn: string | null;
|
|
30185
|
+
bankName: string | null;
|
|
30186
|
+
bankAccountNumber: string | null;
|
|
30187
|
+
bankBik: string | null;
|
|
30188
|
+
bankKc: string | null;
|
|
30189
|
+
bankInn: string | null;
|
|
30190
|
+
bankKpp: string | null;
|
|
30191
|
+
vatRate: number | null;
|
|
30192
|
+
active: boolean;
|
|
30566
30193
|
created_at: string;
|
|
30567
30194
|
updated_at: string | null;
|
|
30568
30195
|
}[];
|
|
@@ -30605,6 +30232,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30605
30232
|
cardColor: string;
|
|
30606
30233
|
currency: FinanceCurrency;
|
|
30607
30234
|
openingBalance: number;
|
|
30235
|
+
country: string | null;
|
|
30236
|
+
companyName: string | null;
|
|
30237
|
+
inn: string | null;
|
|
30238
|
+
kpp: string | null;
|
|
30239
|
+
ogrn: string | null;
|
|
30240
|
+
bankName: string | null;
|
|
30241
|
+
bankAccountNumber: string | null;
|
|
30242
|
+
bankBik: string | null;
|
|
30243
|
+
bankKc: string | null;
|
|
30244
|
+
bankInn: string | null;
|
|
30245
|
+
bankKpp: string | null;
|
|
30246
|
+
vatRate: number | null;
|
|
30247
|
+
active: boolean;
|
|
30608
30248
|
created_at: string;
|
|
30609
30249
|
updated_at: string | null;
|
|
30610
30250
|
};
|
|
@@ -30635,6 +30275,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30635
30275
|
cardColor: string;
|
|
30636
30276
|
currency: FinanceCurrency;
|
|
30637
30277
|
openingBalance: number;
|
|
30278
|
+
country: string | null;
|
|
30279
|
+
companyName: string | null;
|
|
30280
|
+
inn: string | null;
|
|
30281
|
+
kpp: string | null;
|
|
30282
|
+
ogrn: string | null;
|
|
30283
|
+
bankName: string | null;
|
|
30284
|
+
bankAccountNumber: string | null;
|
|
30285
|
+
bankBik: string | null;
|
|
30286
|
+
bankKc: string | null;
|
|
30287
|
+
bankInn: string | null;
|
|
30288
|
+
bankKpp: string | null;
|
|
30289
|
+
vatRate: number | null;
|
|
30290
|
+
active: boolean;
|
|
30638
30291
|
created_at: string;
|
|
30639
30292
|
updated_at: string | null;
|
|
30640
30293
|
};
|
|
@@ -30673,6 +30326,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30673
30326
|
cardColor: string;
|
|
30674
30327
|
currency: FinanceCurrency;
|
|
30675
30328
|
openingBalance: number;
|
|
30329
|
+
country: string | null;
|
|
30330
|
+
companyName: string | null;
|
|
30331
|
+
inn: string | null;
|
|
30332
|
+
kpp: string | null;
|
|
30333
|
+
ogrn: string | null;
|
|
30334
|
+
bankName: string | null;
|
|
30335
|
+
bankAccountNumber: string | null;
|
|
30336
|
+
bankBik: string | null;
|
|
30337
|
+
bankKc: string | null;
|
|
30338
|
+
bankInn: string | null;
|
|
30339
|
+
bankKpp: string | null;
|
|
30340
|
+
vatRate: number | null;
|
|
30341
|
+
active: boolean;
|
|
30676
30342
|
created_at: string;
|
|
30677
30343
|
updated_at: string | null;
|
|
30678
30344
|
};
|
|
@@ -30703,6 +30369,19 @@ declare const routes: import("hono/hono-base").HonoBase<{
|
|
|
30703
30369
|
cardColor: string;
|
|
30704
30370
|
currency: FinanceCurrency;
|
|
30705
30371
|
openingBalance: number;
|
|
30372
|
+
country: string | null;
|
|
30373
|
+
companyName: string | null;
|
|
30374
|
+
inn: string | null;
|
|
30375
|
+
kpp: string | null;
|
|
30376
|
+
ogrn: string | null;
|
|
30377
|
+
bankName: string | null;
|
|
30378
|
+
bankAccountNumber: string | null;
|
|
30379
|
+
bankBik: string | null;
|
|
30380
|
+
bankKc: string | null;
|
|
30381
|
+
bankInn: string | null;
|
|
30382
|
+
bankKpp: string | null;
|
|
30383
|
+
vatRate: number | null;
|
|
30384
|
+
active: boolean;
|
|
30706
30385
|
created_at: string;
|
|
30707
30386
|
updated_at: string | null;
|
|
30708
30387
|
}[];
|