@silexpert/core 1.3.98 → 1.3.99-1
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/cjs/api/resources/Qonto.d.ts +1 -11
- package/dist/cjs/api/resources/Qonto.d.ts.map +1 -1
- package/dist/cjs/api/resources/Qonto.js +0 -29
- package/dist/cjs/api/resources/Qonto.js.map +1 -1
- package/dist/cjs/types/Form/FormConnector.d.ts +1 -0
- package/dist/cjs/types/Form/FormConnector.d.ts.map +1 -1
- package/dist/cjs/types/Form/FormConnector.js +85 -0
- package/dist/cjs/types/Form/FormConnector.js.map +1 -1
- package/dist/cjs/types/Interface/api/connector/OAuthTokenRequest.d.ts +12 -0
- package/dist/cjs/types/Interface/api/connector/OAuthTokenRequest.d.ts.map +1 -0
- package/dist/cjs/types/Interface/api/connector/OAuthTokenRequest.js +3 -0
- package/dist/cjs/types/Interface/api/connector/OAuthTokenRequest.js.map +1 -0
- package/dist/cjs/types/Interface/api/qonto/Create.d.ts +0 -34
- package/dist/cjs/types/Interface/api/qonto/Create.d.ts.map +1 -1
- package/dist/cjs/types/Interface/api/qonto/Create.js +1 -155
- package/dist/cjs/types/Interface/api/qonto/Create.js.map +1 -1
- package/dist/cjs/types/Interface/api/qonto/Query.d.ts +0 -44
- package/dist/cjs/types/Interface/api/qonto/Query.d.ts.map +1 -1
- package/dist/cjs/types/Interface/api/qonto/Query.js +1 -4
- package/dist/cjs/types/Interface/api/qonto/Query.js.map +1 -1
- package/dist/cjs/types/Interface/api/sellsy/SellsyConnectionStatus.d.ts +11 -0
- package/dist/cjs/types/Interface/api/sellsy/SellsyConnectionStatus.d.ts.map +1 -0
- package/dist/cjs/types/Interface/api/sellsy/SellsyConnectionStatus.js +3 -0
- package/dist/cjs/types/Interface/api/sellsy/SellsyConnectionStatus.js.map +1 -0
- package/dist/mjs/api/resources/Qonto.d.ts +1 -11
- package/dist/mjs/api/resources/Qonto.d.ts.map +1 -1
- package/dist/mjs/api/resources/Qonto.js +0 -29
- package/dist/mjs/api/resources/Qonto.js.map +1 -1
- package/dist/mjs/types/Form/FormConnector.d.ts +1 -0
- package/dist/mjs/types/Form/FormConnector.d.ts.map +1 -1
- package/dist/mjs/types/Form/FormConnector.js +86 -11
- package/dist/mjs/types/Form/FormConnector.js.map +1 -1
- package/dist/mjs/types/Interface/api/connector/OAuthTokenRequest.d.ts +12 -0
- package/dist/mjs/types/Interface/api/connector/OAuthTokenRequest.d.ts.map +1 -0
- package/dist/mjs/types/Interface/api/connector/OAuthTokenRequest.js +2 -0
- package/dist/mjs/types/Interface/api/connector/OAuthTokenRequest.js.map +1 -0
- package/dist/mjs/types/Interface/api/qonto/Create.d.ts +0 -34
- package/dist/mjs/types/Interface/api/qonto/Create.d.ts.map +1 -1
- package/dist/mjs/types/Interface/api/qonto/Create.js +1 -178
- package/dist/mjs/types/Interface/api/qonto/Create.js.map +1 -1
- package/dist/mjs/types/Interface/api/qonto/Query.d.ts +0 -44
- package/dist/mjs/types/Interface/api/qonto/Query.d.ts.map +1 -1
- package/dist/mjs/types/Interface/api/qonto/Query.js +0 -9
- package/dist/mjs/types/Interface/api/qonto/Query.js.map +1 -1
- package/dist/mjs/types/Interface/api/sellsy/SellsyConnectionStatus.d.ts +11 -0
- package/dist/mjs/types/Interface/api/sellsy/SellsyConnectionStatus.d.ts.map +1 -0
- package/dist/mjs/types/Interface/api/sellsy/SellsyConnectionStatus.js +2 -0
- package/dist/mjs/types/Interface/api/sellsy/SellsyConnectionStatus.js.map +1 -0
- package/package.json +1 -1
- package/ts/api/resources/Qonto.ts +0 -43
- package/ts/types/Form/FormConnector.ts +41 -11
- package/ts/types/Interface/api/connector/OAuthTokenRequest.ts +12 -0
- package/ts/types/Interface/api/qonto/Create.ts +1 -128
- package/ts/types/Interface/api/qonto/Query.ts +0 -64
- package/ts/types/Interface/api/sellsy/SellsyConnectionStatus.ts +10 -0
|
@@ -5,15 +5,8 @@ import {
|
|
|
5
5
|
GetConnectionInformation,
|
|
6
6
|
GetQontoOrganization,
|
|
7
7
|
IBankAccount,
|
|
8
|
-
IBankConnection,
|
|
9
8
|
ReadCreateConnection,
|
|
10
|
-
UpdateConnection,
|
|
11
9
|
CreateImportationResult,
|
|
12
|
-
CreateQontoRegistration,
|
|
13
|
-
ReadQontoRegistration,
|
|
14
|
-
CreateRegistrationFile,
|
|
15
|
-
CreateWebhookConfig,
|
|
16
|
-
ReadQontoWebhookConfig,
|
|
17
10
|
} from '../../types';
|
|
18
11
|
import { Resource } from '../Resource';
|
|
19
12
|
|
|
@@ -37,40 +30,4 @@ export class Qonto extends Resource {
|
|
|
37
30
|
create(payload: CreateQontoConnection): Promise<ReadCreateConnection> {
|
|
38
31
|
return this.axios.$post('connectors/qonto/connections', payload);
|
|
39
32
|
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* @deprecated use create
|
|
43
|
-
*/
|
|
44
|
-
updateConnection(idBankConnection: number, payload: UpdateConnection): Promise<IBankConnection> {
|
|
45
|
-
return this.axios.$put(`connectors/qonto/connections/${idBankConnection}`, payload);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
createRegistration(params: CreateQontoRegistration): Promise<ReadQontoRegistration> {
|
|
49
|
-
return this.axios.$post('connectors/qonto/registrations', params);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
getRegistration(idRegistration: string): Promise<ReadQontoRegistration> {
|
|
53
|
-
return this.axios.$post(`connectors/qonto/registrations/${idRegistration}`);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
createRegistrationFile(idRegistration: string, params: CreateRegistrationFile): Promise<ReadQontoRegistration> {
|
|
57
|
-
return this.axios.$post(`connectors/qonto/registrations/${idRegistration}/files`, params, {
|
|
58
|
-
responseType: 'arraybuffer',
|
|
59
|
-
headers: {
|
|
60
|
-
Accept: 'application/pdf',
|
|
61
|
-
},
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
getRegistrationFileBuffer(idRegistration: string, idFile: string): Promise<Buffer> {
|
|
66
|
-
return this.axios.$get(`connectors/qonto/registrations/${idRegistration}/files/${idFile}/download`);
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
createWebhookConfig(params: CreateWebhookConfig): Promise<ReadQontoWebhookConfig> {
|
|
70
|
-
return this.axios.$post('connectors/qonto/registrations/webhooks-configs', params);
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
triggerNewMailForRegistrationLink(idRegistration: string): Promise<void> {
|
|
74
|
-
return this.axios.$post(`connectors/qonto/registrations/${idRegistration}/email`);
|
|
75
|
-
}
|
|
76
33
|
}
|
|
@@ -1,36 +1,66 @@
|
|
|
1
|
+
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
|
|
2
|
+
import { IsString, IsOptional, IsNumber, IsDate, IsEnum } from 'class-validator';
|
|
3
|
+
import { Type } from 'class-transformer';
|
|
1
4
|
import { ConnectorType } from '../Enum/ConnectorType';
|
|
2
5
|
|
|
3
6
|
export class FormConnector {
|
|
4
|
-
|
|
7
|
+
@ApiPropertyOptional()
|
|
8
|
+
@IsOptional()
|
|
9
|
+
@IsNumber()
|
|
5
10
|
id?: number;
|
|
6
11
|
|
|
7
|
-
|
|
12
|
+
@ApiPropertyOptional()
|
|
13
|
+
@IsOptional()
|
|
14
|
+
@IsString()
|
|
8
15
|
username?: string;
|
|
9
16
|
|
|
10
|
-
|
|
17
|
+
@ApiPropertyOptional()
|
|
18
|
+
@IsOptional()
|
|
19
|
+
@IsString()
|
|
11
20
|
pass?: string;
|
|
12
21
|
|
|
13
|
-
|
|
22
|
+
@ApiPropertyOptional()
|
|
23
|
+
@IsOptional()
|
|
24
|
+
@IsString()
|
|
14
25
|
url?: string;
|
|
15
26
|
|
|
16
|
-
|
|
27
|
+
@ApiPropertyOptional()
|
|
28
|
+
@IsOptional()
|
|
29
|
+
@IsString()
|
|
17
30
|
token?: string;
|
|
18
31
|
|
|
19
|
-
|
|
32
|
+
@ApiPropertyOptional()
|
|
33
|
+
@IsOptional()
|
|
34
|
+
@IsString()
|
|
20
35
|
token2?: string;
|
|
21
36
|
|
|
22
|
-
|
|
37
|
+
@ApiPropertyOptional()
|
|
38
|
+
@IsOptional()
|
|
39
|
+
@IsString()
|
|
23
40
|
token3?: string;
|
|
24
41
|
|
|
25
|
-
|
|
42
|
+
@ApiPropertyOptional()
|
|
43
|
+
@IsOptional()
|
|
44
|
+
@IsString()
|
|
26
45
|
token4?: string;
|
|
27
46
|
|
|
28
|
-
|
|
47
|
+
@ApiPropertyOptional({ type: String, format: 'date-time' })
|
|
48
|
+
@IsOptional()
|
|
49
|
+
@IsDate()
|
|
50
|
+
@Type(() => Date)
|
|
29
51
|
date?: Date;
|
|
30
52
|
|
|
31
|
-
|
|
53
|
+
@ApiProperty({ enum: ConnectorType })
|
|
54
|
+
@IsEnum(ConnectorType)
|
|
32
55
|
idTypeConnector: ConnectorType;
|
|
33
56
|
|
|
34
|
-
|
|
57
|
+
@ApiPropertyOptional()
|
|
58
|
+
@IsOptional()
|
|
59
|
+
@IsNumber()
|
|
35
60
|
idSociety?: number;
|
|
61
|
+
|
|
62
|
+
@ApiPropertyOptional()
|
|
63
|
+
@IsOptional()
|
|
64
|
+
@IsNumber()
|
|
65
|
+
expiresIn?: number;
|
|
36
66
|
}
|
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
import { IsDateString, IsOptional, IsString, IsArray
|
|
1
|
+
import { IsDateString, IsOptional, IsString, IsArray } from 'class-validator';
|
|
2
2
|
import { ApiPropertyOptional, ApiProperty } from '../../../../utils';
|
|
3
|
-
import { RegistrationFileType, ReadStakeHolders } from './Query';
|
|
4
|
-
import { TFile } from '../file/TFile';
|
|
5
|
-
import { ToBoolean } from '../../../../utils/transforms/boolean.transform';
|
|
6
3
|
|
|
7
4
|
export class CreateImportation {
|
|
8
5
|
@ApiPropertyOptional()
|
|
@@ -35,127 +32,3 @@ export class ProcessBankAccount {
|
|
|
35
32
|
@IsArray()
|
|
36
33
|
idsSlugToRemove: Array<string>;
|
|
37
34
|
}
|
|
38
|
-
|
|
39
|
-
export class CreateQontoRegistration {
|
|
40
|
-
@ApiProperty()
|
|
41
|
-
@IsString()
|
|
42
|
-
legalFlow: 'company_creation' | 'existing_company';
|
|
43
|
-
|
|
44
|
-
@ApiProperty()
|
|
45
|
-
@IsString()
|
|
46
|
-
locale: 'en' | 'fr' | 'it' | 'es' | 'de';
|
|
47
|
-
|
|
48
|
-
@ApiPropertyOptional()
|
|
49
|
-
@IsString()
|
|
50
|
-
@IsOptional()
|
|
51
|
-
firstName?: string | null;
|
|
52
|
-
|
|
53
|
-
@ApiPropertyOptional()
|
|
54
|
-
@IsString()
|
|
55
|
-
@IsOptional()
|
|
56
|
-
lastName?: string | null;
|
|
57
|
-
|
|
58
|
-
@ApiPropertyOptional()
|
|
59
|
-
@IsString()
|
|
60
|
-
@IsOptional()
|
|
61
|
-
email?: string | null;
|
|
62
|
-
|
|
63
|
-
@ApiProperty()
|
|
64
|
-
@IsString()
|
|
65
|
-
entityType: 'freelancer' | 'company';
|
|
66
|
-
|
|
67
|
-
@ApiPropertyOptional()
|
|
68
|
-
@IsString()
|
|
69
|
-
@IsOptional()
|
|
70
|
-
legalName?: string | null;
|
|
71
|
-
|
|
72
|
-
@ApiPropertyOptional()
|
|
73
|
-
@IsString()
|
|
74
|
-
@IsOptional()
|
|
75
|
-
legalForm?: string | null;
|
|
76
|
-
|
|
77
|
-
@ApiPropertyOptional()
|
|
78
|
-
@IsString()
|
|
79
|
-
@IsOptional()
|
|
80
|
-
number?: string | null;
|
|
81
|
-
|
|
82
|
-
@ApiPropertyOptional()
|
|
83
|
-
@IsString()
|
|
84
|
-
@IsOptional()
|
|
85
|
-
sector?: string | null;
|
|
86
|
-
|
|
87
|
-
@ApiPropertyOptional()
|
|
88
|
-
@IsString()
|
|
89
|
-
@IsOptional()
|
|
90
|
-
registrationDate?: string | null;
|
|
91
|
-
|
|
92
|
-
@ApiPropertyOptional()
|
|
93
|
-
@IsString()
|
|
94
|
-
@IsOptional()
|
|
95
|
-
vatNumber?: string | null;
|
|
96
|
-
|
|
97
|
-
@ApiPropertyOptional()
|
|
98
|
-
@IsString()
|
|
99
|
-
@IsOptional()
|
|
100
|
-
addressStreet?: string | null;
|
|
101
|
-
|
|
102
|
-
@ApiPropertyOptional()
|
|
103
|
-
@IsString()
|
|
104
|
-
@IsOptional()
|
|
105
|
-
addressStreet2?: string | null;
|
|
106
|
-
|
|
107
|
-
@ApiPropertyOptional()
|
|
108
|
-
@IsString()
|
|
109
|
-
@IsOptional()
|
|
110
|
-
postalCode?: string | null;
|
|
111
|
-
|
|
112
|
-
@ApiPropertyOptional()
|
|
113
|
-
@IsString()
|
|
114
|
-
@IsOptional()
|
|
115
|
-
city?: string | null;
|
|
116
|
-
|
|
117
|
-
@ApiPropertyOptional()
|
|
118
|
-
@IsString()
|
|
119
|
-
@IsOptional()
|
|
120
|
-
country?: string | null;
|
|
121
|
-
|
|
122
|
-
@ApiProperty()
|
|
123
|
-
@IsString()
|
|
124
|
-
totalCapitalAmount: string;
|
|
125
|
-
|
|
126
|
-
@ApiProperty()
|
|
127
|
-
stakeHolders: ReadStakeHolders;
|
|
128
|
-
|
|
129
|
-
@ApiProperty()
|
|
130
|
-
@IsNumber()
|
|
131
|
-
idSociety: number;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
export class CreateRegistrationFile {
|
|
135
|
-
@ApiProperty()
|
|
136
|
-
file: TFile;
|
|
137
|
-
|
|
138
|
-
@ApiProperty()
|
|
139
|
-
fileType: RegistrationFileType;
|
|
140
|
-
|
|
141
|
-
@ApiPropertyOptional()
|
|
142
|
-
@IsString()
|
|
143
|
-
@IsOptional()
|
|
144
|
-
stakeholderId?: string;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
export class CreateWebhookConfig {
|
|
148
|
-
@ApiProperty()
|
|
149
|
-
@IsString()
|
|
150
|
-
callbackUrl: string;
|
|
151
|
-
|
|
152
|
-
@ApiProperty()
|
|
153
|
-
@IsString()
|
|
154
|
-
secret: string;
|
|
155
|
-
|
|
156
|
-
@ApiPropertyOptional()
|
|
157
|
-
@IsBoolean()
|
|
158
|
-
@ToBoolean()
|
|
159
|
-
@IsOptional()
|
|
160
|
-
enabled: boolean;
|
|
161
|
-
}
|
|
@@ -79,43 +79,6 @@ export type GetQontoAttachment = {
|
|
|
79
79
|
};
|
|
80
80
|
};
|
|
81
81
|
|
|
82
|
-
export type ReadQontoRegistration = {
|
|
83
|
-
id: string;
|
|
84
|
-
legal_flow: string; // Registration type => company_creation (Company in creation), existing_company (Company already exists)
|
|
85
|
-
flow: {
|
|
86
|
-
type: 'manual' | 'seamless'; // which type of flow the user will be redirected
|
|
87
|
-
breakdown: {
|
|
88
|
-
code: string;
|
|
89
|
-
detail: string;
|
|
90
|
-
source: {
|
|
91
|
-
pointer: string;
|
|
92
|
-
};
|
|
93
|
-
} | null;
|
|
94
|
-
};
|
|
95
|
-
status:
|
|
96
|
-
| 'created'
|
|
97
|
-
| 'pending'
|
|
98
|
-
| 'user_started'
|
|
99
|
-
| 'price_plan_selected'
|
|
100
|
-
| 'contract_signed'
|
|
101
|
-
| 'submitted'
|
|
102
|
-
| 'capital_deposit_activated'
|
|
103
|
-
| 'capital_deposit_request_signed'
|
|
104
|
-
| 'capital_deposit_certificate_signed'
|
|
105
|
-
| 'completed';
|
|
106
|
-
redirection_link: string; // link where the user is redirected
|
|
107
|
-
created_at: string;
|
|
108
|
-
updated_at: string;
|
|
109
|
-
locale: string;
|
|
110
|
-
partner_user: {
|
|
111
|
-
first_name: string | null;
|
|
112
|
-
last_name: string | null;
|
|
113
|
-
email: string | null;
|
|
114
|
-
};
|
|
115
|
-
organization: ReadOrganization;
|
|
116
|
-
stakeholders: ReadStakeHolder[];
|
|
117
|
-
};
|
|
118
|
-
|
|
119
82
|
export type ReadOrganization = {
|
|
120
83
|
id?: string;
|
|
121
84
|
entity_type: 'freelancer' | 'company';
|
|
@@ -167,30 +130,3 @@ export class ReadStakeHolder {
|
|
|
167
130
|
}
|
|
168
131
|
|
|
169
132
|
export type ReadStakeHolders = ReadStakeHolder[];
|
|
170
|
-
|
|
171
|
-
export class ReadQontoRegistrationFile {
|
|
172
|
-
id: string;
|
|
173
|
-
filename: string;
|
|
174
|
-
filesize_bytes: number;
|
|
175
|
-
url: string; // TTL of 2 hours
|
|
176
|
-
created_at: string;
|
|
177
|
-
file_type: string;
|
|
178
|
-
stakeholder_id: string | null;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
export type ReadQontoWebhookConfig = {
|
|
182
|
-
id: string;
|
|
183
|
-
created_at: string;
|
|
184
|
-
updated_at: string;
|
|
185
|
-
callback_url: string;
|
|
186
|
-
enabled: boolean;
|
|
187
|
-
secret: string;
|
|
188
|
-
};
|
|
189
|
-
|
|
190
|
-
export type RegistrationFileType =
|
|
191
|
-
| 'organization-deposit-certificate'
|
|
192
|
-
| 'organization-proof-of-address'
|
|
193
|
-
| 'organization-by-laws'
|
|
194
|
-
| 'organization-kbis'
|
|
195
|
-
| 'stakeholder-proof-of-identity'
|
|
196
|
-
| 'stakeholder-residence-permit';
|