bimplus-websdk 1.0.63 → 1.0.64

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.
@@ -1,532 +1,532 @@
1
- declare module 'bimplus-websdk' {
2
-
3
- export type HTML = string;
4
- export type Guid = string;
5
- export type ProjectId = Guid;
6
- export type ModelId = Guid;
7
- export type LayerId = Guid;
8
- export type DivisionTopologyId = Guid;
9
- export type RevisionId = string;
10
- export type VisualObjectId = string;
11
-
12
- export type TeamSlug = string;
13
- export type AccessToken = string;
14
- export type AccessTokenType = string;
15
-
16
- export function createDefaultConfig(env?: string): ApiConfig;
17
-
18
- export interface ApiConfig {
19
- protocol: string;
20
- host: string;
21
- version?: string;
22
- cache?: boolean;
23
- }
24
-
25
- export interface AuthorizeData {
26
- access_token: string;
27
- }
28
-
29
- export class Authorize {
30
- constructor(api: Api);
31
-
32
- // Define methods and properties of the Teams class here
33
-
34
- post(username: string, password: string, applicationId: string): Promise<AuthorizeData>;
35
- }
36
-
37
- export interface TeamData {
38
- slug: string;
39
- id: string;
40
- name: string;
41
- }
42
-
43
- export interface Subscription {
44
- settingName?: string;
45
- expirationDate?: string;
46
- id?: string;
47
- teamId?: string;
48
- value?: string;
49
- status?: string;
50
- }
51
-
52
- export class Teams {
53
- constructor(api: Api);
54
-
55
- slug: string;
56
-
57
- // Define methods and properties of the Teams class here
58
-
59
- get(teamId?: string, filterEmpty?: boolean): Promise<TeamData[]>;
60
- getAccountSettings(teamId?: string): Promise<Array<Subscription>>;
61
- }
62
-
63
- export interface UserData {
64
- id: string;
65
- name: string;
66
- preferedLanguage: string;
67
- }
68
-
69
- export class User {
70
- constructor(api: Api);
71
-
72
- // Define methods and properties of the Teams class here
73
-
74
- get(token: AccessToken | null): Promise<UserData>;
75
- put(userdata: string): Promise<UserData>;
76
- getSubscriptions(): Promise<Array<Subscription>>;
77
- }
78
-
79
- type AdditionalParams = {
80
- [key: string]: string; // This allows key-value pairs as in json string
81
- }
82
-
83
- export interface Project {
84
- id: ProjectId;
85
- name: string;
86
- teamSlug: TeamSlug;
87
- teamName: string | undefined;
88
- rights: object;
89
- }
90
-
91
- export class Projects {
92
- constructor(api: Api);
93
- get(id?: ProjectId, noDisciplines?: boolean, teamSlug?: TeamSlug, alsoRecycleBin?: boolean, additionalParams?: AdditionalParams): Promise<Project | Project[]>;
94
- }
95
-
96
- export interface ConnexisData {
97
- projectId: ProjectId,
98
- modelId: ModelId,
99
- elements: Guid[];
100
- settings: {
101
- connectionMethod: string;
102
- createRevision?: boolean;
103
- designCode: string;
104
- replace: string;
105
- }
106
- }
107
-
108
- export interface Sds2ConnexisData {
109
- SDS2: ConnexisData;
110
- }
111
- // export interface IdeaStaticaConnexisData {
112
- // IdeaStatica: ConnexisData;
113
- // }
114
-
115
- export class Connexis {
116
- constructor(api: Api);
117
- post(data: Sds2ConnexisData /* | IdeaStaticaConnexisData */) : Promise<void>;
118
- }
119
-
120
- export interface ObjectFilter {
121
- id?: string
122
- module: string
123
- category: string
124
- disciplineID: string
125
- name: string
126
- filterString: string
127
- isDefault: boolean
128
- disableSortByModels: boolean
129
- readableValues?: Record<string, string>
130
- }
131
-
132
- export type ObjectFiltersResponse = Array<ObjectFilter>;
133
-
134
- export class ObjectFilters {
135
- constructor(api: Api);
136
- get(layerId: Guid | undefined, projectId: Guid | undefined): Promise<ObjectFiltersResponse>
137
- getSelectionFilteredObjects(selectionId: Guid, filterId: Guid, properties: boolean | undefined, topology: boolean | undefined): Promise<ObjectFilterStructureResponse>
138
- post(data: string, projectId: string): Promise<ObjectFilter>;
139
- delete(id: string) : void;
140
- }
141
-
142
- export interface ObjectsTopologyNode { }
143
-
144
- export interface ObjectTopologyResponse {
145
- id: string;
146
- children?: ObjectsTopologyNode[];
147
- ifcType?: string;
148
- ifcId?: string;
149
- elementTypeId?: string;
150
- isChild?: boolean;
151
- parent: string;
152
- name: string;
153
- type: string;
154
- layerid?: string;
155
- number: number;
156
- level: number;
157
- }
158
-
159
- export type ObjectComplexPropertyTopologyResponse = ObjectTopologyResponse;
160
-
161
- interface Hyperlink {
162
- id: string;
163
- objectId: string;
164
- orderNumber: number;
165
- name: string;
166
- url: string;
167
- }
168
-
169
- export interface Attachment {
170
- id: string;
171
- fileName: string;
172
- size: number;
173
- }
174
-
175
- export type Rights = {
176
- update: boolean;
177
- share: boolean;
178
- delete: boolean;
179
- download: boolean;
180
- }
181
-
182
- export type GetAttachmentResponse = {
183
- id: string;
184
- objectIds: string[];
185
- name: string;
186
- fileName: string;
187
- type: string;
188
- size: number;
189
- createdAt: string;
190
- changed: string;
191
- changedFile: string;
192
- changedBy: ChangedBy;
193
- hash: string;
194
- attachmentType: string;
195
- classification: string;
196
- tag: string;
197
- sizeMB: string;
198
- version: number;
199
- relatedId: string;
200
- rights: Rights;
201
- release: boolean;
202
- }
203
-
204
- type HyperlinksResponse = Hyperlink[];
205
- type AttachmentLinksResponse = AttachmentLink[];
206
- type AttachmentResponse = Attachment[];
207
-
208
- export type PostAttachmentResponse = {
209
- id: string;
210
- objectIds: string[];
211
- name: string;
212
- fileName: string;
213
- type: string;
214
- size: number;
215
- createdAt: string,
216
- creator: Author;
217
- changedFile: string,
218
- hash: string,
219
- attachmentType: string;
220
- classification: string;
221
- tag: string;
222
- sizeMB: string;
223
- version: number;
224
- relatedId: string;
225
- release: boolean;
226
- }
227
-
228
- type CommentsResponse = CommentResponse[];
229
-
230
- export interface CommentResponse {
231
- id: string;
232
- issueId?: string;
233
- status?: string | null;
234
- verbalStatus?: string | null;
235
- parentId?: string;
236
- text?: string;
237
- createdAt?: string;
238
- modifiedAt?: string;
239
- author?: Author;
240
- hyperlinks?: Hyperlink[];
241
- attachments?: Attachment[];
242
- attachmentLinks?: AttachmentLink[];
243
- }
244
-
245
- export interface Author {
246
- id?: string;
247
- email?: string;
248
- status?: string | null;
249
- firstname?: string;
250
- lastname?: string;
251
- company?: string;
252
- fullname?: string;
253
- displayname?: string;
254
- shortdisplayname?: string;
255
- preferedLanguage?: string | null;
256
- updated?: string;
257
- tokensInvalidated?: string;
258
- }
259
-
260
- export interface Attachment {
261
- id: string;
262
- objectIds: string[];
263
- name: string;
264
- fileName: string;
265
- type: string;
266
- size: number;
267
- createdAt: string;
268
- creator: Author;
269
- changed: string;
270
- changedFile: string;
271
- changedBy: ChangedBy;
272
- attachmentType: string;
273
- sizeMB: string;
274
- version: number;
275
- relatedId: string;
276
- release: boolean;
277
- recycleBin: boolean;
278
- }
279
-
280
- export interface ChangedBy {
281
- id: string;
282
- email: string;
283
- firstname: string;
284
- lastname: string;
285
- }
286
-
287
- export interface ObjectData {
288
- id: string;
289
- elementtyp?: string;
290
- type?: string;
291
- layerid?: string;
292
- attributes?: Attributes;
293
- parent?: string;
294
- localizedAttributeGroups?: LocalizedAttributeGroups;
295
- [key: string]: unknown;
296
- }
297
-
298
- export interface LocalizedAttributeGroups {
299
- [key: string]: unknown;
300
- }
301
-
302
- export interface Attributes {
303
- [key: string]: unknown;
304
- slide?: Slide;
305
- }
306
-
307
- export interface Slide {
308
- scene: Scene | SceneResponse;
309
- }
310
-
311
- export interface Scene {
312
- viewMode?: string;
313
- thumbnail?: string;
314
- viewBox?: ViewBox;
315
- camera?: Camera;
316
- objects?: SceneObjects;
317
- rotationCenter?: number[];
318
- version?: [number, number, number]; // Tuple type for version (major, minor, patch)
319
- topology?: Topology[];
320
- layers?: SelectionObjectLayer[];
321
- [key: string]: unknown;
322
- }
323
-
324
- export type SceneResponse = string;
325
-
326
- export interface Camera {
327
- [key: string]: unknown;
328
- }
329
-
330
- export interface Topology {
331
- id: string;
332
- divisionTopologyId: string;
333
- visible: boolean;
334
- revision: number;
335
- [key: string]: unknown;
336
- }
337
-
338
- export interface SceneObjects {
339
- selected?: string[];
340
- coloring?: Coloring;
341
- selectedInfo?: SelectedInfo[];
342
- }
343
-
344
- export interface SelectedObject {
345
- id: string;
346
- node: string;
347
- revision: number;
348
- }
349
-
350
- export class Objects {
351
- constructor(api: Api);
352
- get(objectId: string, revision: number | undefined, properties: string | undefined, projectId: string | undefined, shortInfo: boolean | undefined, type: string | undefined): Promise<ObjectProperties>;
353
- getTopology(objectId: string, revision: number | undefined, hideElements: boolean, shortInfo: boolean, batch: string | undefined): Promise<ObjectTopologyResponse>;
354
- getComplexPropertiesTopology(objectId: string, revision: number | undefined): Promise<ObjectComplexPropertyTopologyResponse>;
355
- getHyperlinks(objectId: string): Promise<HyperlinksResponse>;
356
- postHyperlink(objectId: string, data: string): Promise<Hyperlink>;
357
- getAttachmentLinks(objectId: string): Promise<AttachmentLinksResponse>;
358
- postAttachmentLink(objectId: string, data: string): Promise<AttachmentLink>;
359
- deleteAttachmentLink(objectId: string,AttachmentLinkId:string): Promise<void>;
360
- postComment(objectId: string, data: string): Promise<CommentResponse>;
361
- getComments(objectId: string): Promise<CommentsResponse>;
362
- postAttachment(objectId: string, data: FormData, uploadProgress?: () => void, documentFolderId?: string): Promise<PostAttachmentResponse>;
363
- getAttachments(objectId: string): Promise<AttachmentResponse>;
364
- put(objectId: string, data: string, projectId?: string): Promise<ObjectData>;
365
- getInternal(objectId: string, revision?: number): Promise<ObjectData>;
366
- }
367
-
368
- export class Attachments {
369
- constructor(api: Api);
370
- delete(id:string, version?: number): Promise<void>;
371
- get(id: string): Promise<GetAttachmentResponse>;
372
- }
373
-
374
- export interface SelectionObjectTopologyNode {
375
- id: string;
376
- visible: boolean;
377
- opaque: boolean;
378
- opacity: number;
379
- }
380
-
381
- export interface SelectionObjectLayer {
382
- revision: number;
383
- id: string;
384
- name?: string;
385
- divisionId: string;
386
- divisionName?: string;
387
- visible?: boolean;
388
- opaque?: boolean;
389
- opacity?: number;
390
- valid?: boolean;
391
- divisionTopologyId?: string;
392
- revisions?: Array<number>;
393
- [key: string]: unknown;
394
- }
395
-
396
- export interface SelectionObjectTopology {
397
- topology: SelectionObjectTopologyNode[];
398
- layers: SelectionObjectLayer[];
399
- }
400
-
401
- export interface SelectionObjectTopologyStructure {
402
- layers: SelectionObjectLayer[];
403
- structures: Topology[] | string[];
404
- }
405
-
406
- export interface SelectionObject {
407
- id?: string;
408
- projectid: string;
409
- divisionid?: string;
410
- singleuse: boolean;
411
- revisionnr?: string;
412
- type: string;
413
- elements?: string[];
414
- revisionelements?: string[];
415
- filter?: string;
416
- topology?: SelectionObjectTopology;
417
- topologyStructure?: SelectionObjectTopologyStructure
418
- }
419
-
420
- export interface ExportObject {
421
- description: string;
422
- id?: string;
423
- name: string;
424
- projectId: string;
425
- singleUse: boolean;
426
- selection: SelectionObject;
427
- [key: string]: unknown;
428
- }
429
-
430
- export class ExportService {
431
- constructor(api: Api);
432
- createExportSelection(projectId: Guid, data: string): Promise<ExportObject>;
433
- }
434
-
435
- export interface StructureNode {
436
- id: string;
437
- parent?: string;
438
- name: string;
439
- type: string;
440
- children?: StructureNode[];
441
- lastTopologyId?: string;
442
- count: number;
443
- level: number;
444
- nodeInfo: string;
445
- hasGeometry?: boolean;
446
- }
447
-
448
- export interface ObjectFilterStructureResponse {
449
- structure: StructureNode;
450
- structureDepth: number;
451
- }
452
-
453
- export class PrivacyTexts {
454
- constructor(api: Api);
455
- get(lang: string | undefined, type: string | undefined): Promise<HTML>;
456
- }
457
-
458
- export interface IDBCache {
459
- data: string;
460
-
461
- clear(): void;
462
- }
463
-
464
- export class Hyperlinks {
465
- constructor(api: Api);
466
- delete(id: string): Promise<void>;
467
- }
468
-
469
- export class AttachmentLink {
470
- id: string;
471
- name: string;
472
- fileName:string
473
- size:number;
474
- link:string;
475
- version:number;
476
- fileNameShort:string;
477
- extension:string;
478
- objectIds:string[];
479
- sizeMB: string
480
- }
481
-
482
- export class Comments {
483
- constructor(api: Api);
484
- delete(id: string): Promise<void>;
485
- }
486
-
487
- export interface Coloring {
488
- }
489
-
490
- export interface SelectedInfo {
491
- }
492
-
493
- export interface ViewBox {
494
- }
495
-
496
- export interface ObjectProperties {
497
- }
498
-
499
- export class Api {
500
- constructor(config: ApiConfig);
501
-
502
- // Define methods and properties of the Teams class here
503
-
504
- authorize: Authorize;
505
- teams: Teams;
506
- user: User;
507
- projects: Projects;
508
- connexis: Connexis;
509
- objectFilters: ObjectFilters;
510
- objects: Objects;
511
- attachments: Attachments;
512
- exportService: ExportService;
513
- terms: PrivacyTexts;
514
- imprints: PrivacyTexts;
515
- dataProtection: PrivacyTexts;
516
- hyperlinks: Hyperlinks;
517
- comments: Comments;
518
-
519
- setAccessToken(token: AccessToken): void;
520
- getAccessToken(): AccessToken | null;
521
-
522
- setTokenType(tokenType: AccessTokenType): void;
523
- getTokenType(): AccessTokenType | null;
524
-
525
- setAccessTokenAndType(token: AccessToken, tokenType: AccessTokenType): void;
526
- getAccessTokenAndType(): { token: AccessToken | null, tokenType: AccessTokenType | null }
527
-
528
- setTeamSlug(slug: TeamSlug): void;
529
- getCache(): IDBCache;
530
- getApiTeamUrl(): string;
531
- }
532
- }
1
+ declare module 'bimplus-websdk' {
2
+
3
+ export type HTML = string;
4
+ export type Guid = string;
5
+ export type ProjectId = Guid;
6
+ export type ModelId = Guid;
7
+ export type LayerId = Guid;
8
+ export type DivisionTopologyId = Guid;
9
+ export type RevisionId = string;
10
+ export type VisualObjectId = string;
11
+
12
+ export type TeamSlug = string;
13
+ export type AccessToken = string;
14
+ export type AccessTokenType = string;
15
+
16
+ export function createDefaultConfig(env?: string): ApiConfig;
17
+
18
+ export interface ApiConfig {
19
+ protocol: string;
20
+ host: string;
21
+ version?: string;
22
+ cache?: boolean;
23
+ }
24
+
25
+ export interface AuthorizeData {
26
+ access_token: string;
27
+ }
28
+
29
+ export class Authorize {
30
+ constructor(api: Api);
31
+
32
+ // Define methods and properties of the Teams class here
33
+
34
+ post(username: string, password: string, applicationId: string): Promise<AuthorizeData>;
35
+ }
36
+
37
+ export interface TeamData {
38
+ slug: string;
39
+ id: string;
40
+ name: string;
41
+ }
42
+
43
+ export interface Subscription {
44
+ settingName?: string;
45
+ expirationDate?: string;
46
+ id?: string;
47
+ teamId?: string;
48
+ value?: string;
49
+ status?: string;
50
+ }
51
+
52
+ export class Teams {
53
+ constructor(api: Api);
54
+
55
+ slug: string;
56
+
57
+ // Define methods and properties of the Teams class here
58
+
59
+ get(teamId?: string, filterEmpty?: boolean): Promise<TeamData[]>;
60
+ getAccountSettings(teamId?: string): Promise<Array<Subscription>>;
61
+ }
62
+
63
+ export interface UserData {
64
+ id: string;
65
+ name: string;
66
+ preferedLanguage: string;
67
+ }
68
+
69
+ export class User {
70
+ constructor(api: Api);
71
+
72
+ // Define methods and properties of the Teams class here
73
+
74
+ get(token: AccessToken | null): Promise<UserData>;
75
+ put(userdata: string): Promise<UserData>;
76
+ getSubscriptions(): Promise<Array<Subscription>>;
77
+ }
78
+
79
+ type AdditionalParams = {
80
+ [key: string]: string; // This allows key-value pairs as in json string
81
+ }
82
+
83
+ export interface Project {
84
+ id: ProjectId;
85
+ name: string;
86
+ teamSlug: TeamSlug;
87
+ teamName: string | undefined;
88
+ rights: object;
89
+ }
90
+
91
+ export class Projects {
92
+ constructor(api: Api);
93
+ get(id?: ProjectId, noDisciplines?: boolean, teamSlug?: TeamSlug, alsoRecycleBin?: boolean, additionalParams?: AdditionalParams): Promise<Project | Project[]>;
94
+ }
95
+
96
+ export interface ConnexisData {
97
+ projectId: ProjectId,
98
+ modelId: ModelId,
99
+ elements: Guid[];
100
+ settings: {
101
+ connectionMethod: string;
102
+ createRevision?: boolean;
103
+ designCode: string;
104
+ replace: string;
105
+ }
106
+ }
107
+
108
+ export interface Sds2ConnexisData {
109
+ SDS2: ConnexisData;
110
+ }
111
+ // export interface IdeaStaticaConnexisData {
112
+ // IdeaStatica: ConnexisData;
113
+ // }
114
+
115
+ export class Connexis {
116
+ constructor(api: Api);
117
+ post(data: Sds2ConnexisData /* | IdeaStaticaConnexisData */) : Promise<void>;
118
+ }
119
+
120
+ export interface ObjectFilter {
121
+ id?: string
122
+ module: string
123
+ category: string
124
+ disciplineID: string
125
+ name: string
126
+ filterString: string
127
+ isDefault: boolean
128
+ disableSortByModels: boolean
129
+ readableValues?: Record<string, string>
130
+ }
131
+
132
+ export type ObjectFiltersResponse = Array<ObjectFilter>;
133
+
134
+ export class ObjectFilters {
135
+ constructor(api: Api);
136
+ get(layerId: Guid | undefined, projectId: Guid | undefined): Promise<ObjectFiltersResponse>
137
+ getSelectionFilteredObjects(selectionId: Guid, filterId: Guid, properties: boolean | undefined, topology: boolean | undefined): Promise<ObjectFilterStructureResponse>
138
+ post(data: string, projectId: string): Promise<ObjectFilter>;
139
+ delete(id: string) : void;
140
+ }
141
+
142
+ export interface ObjectsTopologyNode { }
143
+
144
+ export interface ObjectTopologyResponse {
145
+ id: string;
146
+ children?: ObjectsTopologyNode[];
147
+ ifcType?: string;
148
+ ifcId?: string;
149
+ elementTypeId?: string;
150
+ isChild?: boolean;
151
+ parent: string;
152
+ name: string;
153
+ type: string;
154
+ layerid?: string;
155
+ number: number;
156
+ level: number;
157
+ }
158
+
159
+ export type ObjectComplexPropertyTopologyResponse = ObjectTopologyResponse;
160
+
161
+ interface Hyperlink {
162
+ id: string;
163
+ objectId: string;
164
+ orderNumber: number;
165
+ name: string;
166
+ url: string;
167
+ }
168
+
169
+ export interface Attachment {
170
+ id: string;
171
+ fileName: string;
172
+ size: number;
173
+ }
174
+
175
+ export type Rights = {
176
+ update: boolean;
177
+ share: boolean;
178
+ delete: boolean;
179
+ download: boolean;
180
+ }
181
+
182
+ export type GetAttachmentResponse = {
183
+ id: string;
184
+ objectIds: string[];
185
+ name: string;
186
+ fileName: string;
187
+ type: string;
188
+ size: number;
189
+ createdAt: string;
190
+ changed: string;
191
+ changedFile: string;
192
+ changedBy: ChangedBy;
193
+ hash: string;
194
+ attachmentType: string;
195
+ classification: string;
196
+ tag: string;
197
+ sizeMB: string;
198
+ version: number;
199
+ relatedId: string;
200
+ rights: Rights;
201
+ release: boolean;
202
+ }
203
+
204
+ type HyperlinksResponse = Hyperlink[];
205
+ type AttachmentLinksResponse = AttachmentLink[];
206
+ type AttachmentResponse = Attachment[];
207
+
208
+ export type PostAttachmentResponse = {
209
+ id: string;
210
+ objectIds: string[];
211
+ name: string;
212
+ fileName: string;
213
+ type: string;
214
+ size: number;
215
+ createdAt: string,
216
+ creator: Author;
217
+ changedFile: string,
218
+ hash: string,
219
+ attachmentType: string;
220
+ classification: string;
221
+ tag: string;
222
+ sizeMB: string;
223
+ version: number;
224
+ relatedId: string;
225
+ release: boolean;
226
+ }
227
+
228
+ type CommentsResponse = CommentResponse[];
229
+
230
+ export interface CommentResponse {
231
+ id: string;
232
+ issueId?: string;
233
+ status?: string | null;
234
+ verbalStatus?: string | null;
235
+ parentId?: string;
236
+ text?: string;
237
+ createdAt?: string;
238
+ modifiedAt?: string;
239
+ author?: Author;
240
+ hyperlinks?: Hyperlink[];
241
+ attachments?: Attachment[];
242
+ attachmentLinks?: AttachmentLink[];
243
+ }
244
+
245
+ export interface Author {
246
+ id?: string;
247
+ email?: string;
248
+ status?: string | null;
249
+ firstname?: string;
250
+ lastname?: string;
251
+ company?: string;
252
+ fullname?: string;
253
+ displayname?: string;
254
+ shortdisplayname?: string;
255
+ preferedLanguage?: string | null;
256
+ updated?: string;
257
+ tokensInvalidated?: string;
258
+ }
259
+
260
+ export interface Attachment {
261
+ id: string;
262
+ objectIds: string[];
263
+ name: string;
264
+ fileName: string;
265
+ type: string;
266
+ size: number;
267
+ createdAt: string;
268
+ creator: Author;
269
+ changed: string;
270
+ changedFile: string;
271
+ changedBy: ChangedBy;
272
+ attachmentType: string;
273
+ sizeMB: string;
274
+ version: number;
275
+ relatedId: string;
276
+ release: boolean;
277
+ recycleBin: boolean;
278
+ }
279
+
280
+ export interface ChangedBy {
281
+ id: string;
282
+ email: string;
283
+ firstname: string;
284
+ lastname: string;
285
+ }
286
+
287
+ export interface ObjectData {
288
+ id: string;
289
+ elementtyp?: string;
290
+ type?: string;
291
+ layerid?: string;
292
+ attributes?: Attributes;
293
+ parent?: string;
294
+ localizedAttributeGroups?: LocalizedAttributeGroups;
295
+ [key: string]: unknown;
296
+ }
297
+
298
+ export interface LocalizedAttributeGroups {
299
+ [key: string]: unknown;
300
+ }
301
+
302
+ export interface Attributes {
303
+ [key: string]: unknown;
304
+ slide?: Slide;
305
+ }
306
+
307
+ export interface Slide {
308
+ scene: Scene | SceneResponse;
309
+ }
310
+
311
+ export interface Scene {
312
+ viewMode?: string;
313
+ thumbnail?: string;
314
+ viewBox?: ViewBox;
315
+ camera?: Camera;
316
+ objects?: SceneObjects;
317
+ rotationCenter?: number[];
318
+ version?: [number, number, number]; // Tuple type for version (major, minor, patch)
319
+ topology?: Topology[];
320
+ layers?: SelectionObjectLayer[];
321
+ [key: string]: unknown;
322
+ }
323
+
324
+ export type SceneResponse = string;
325
+
326
+ export interface Camera {
327
+ [key: string]: unknown;
328
+ }
329
+
330
+ export interface Topology {
331
+ id: string;
332
+ divisionTopologyId: string;
333
+ visible: boolean;
334
+ revision: number;
335
+ [key: string]: unknown;
336
+ }
337
+
338
+ export interface SceneObjects {
339
+ selected?: string[];
340
+ coloring?: Coloring;
341
+ selectedInfo?: SelectedInfo[];
342
+ }
343
+
344
+ export interface SelectedObject {
345
+ id: string;
346
+ node: string;
347
+ revision: number;
348
+ }
349
+
350
+ export class Objects {
351
+ constructor(api: Api);
352
+ get(objectId: string, revision: number | undefined, properties: string | undefined, projectId: string | undefined, shortInfo: boolean | undefined, type: string | undefined): Promise<ObjectProperties>;
353
+ getTopology(objectId: string, revision: number | undefined, hideElements: boolean, shortInfo: boolean, batch: string | undefined): Promise<ObjectTopologyResponse>;
354
+ getComplexPropertiesTopology(objectId: string, revision: number | undefined): Promise<ObjectComplexPropertyTopologyResponse>;
355
+ getHyperlinks(objectId: string): Promise<HyperlinksResponse>;
356
+ postHyperlink(objectId: string, data: string): Promise<Hyperlink>;
357
+ getAttachmentLinks(objectId: string): Promise<AttachmentLinksResponse>;
358
+ postAttachmentLink(objectId: string, data: string): Promise<AttachmentLink>;
359
+ deleteAttachmentLink(objectId: string,AttachmentLinkId:string): Promise<void>;
360
+ postComment(objectId: string, data: string): Promise<CommentResponse>;
361
+ getComments(objectId: string): Promise<CommentsResponse>;
362
+ postAttachment(objectId: string, data: FormData, uploadProgress?: () => void, documentFolderId?: string): Promise<PostAttachmentResponse>;
363
+ getAttachments(objectId: string): Promise<AttachmentResponse>;
364
+ put(objectId: string, data: string, projectId?: string): Promise<ObjectData>;
365
+ getInternal(objectId: string, revision?: number): Promise<ObjectData>;
366
+ }
367
+
368
+ export class Attachments {
369
+ constructor(api: Api);
370
+ delete(id:string, version?: number): Promise<void>;
371
+ get(id: string): Promise<GetAttachmentResponse>;
372
+ }
373
+
374
+ export interface SelectionObjectTopologyNode {
375
+ id: string;
376
+ visible: boolean;
377
+ opaque: boolean;
378
+ opacity: number;
379
+ }
380
+
381
+ export interface SelectionObjectLayer {
382
+ revision: number;
383
+ id: string;
384
+ name?: string;
385
+ divisionId: string;
386
+ divisionName?: string;
387
+ visible?: boolean;
388
+ opaque?: boolean;
389
+ opacity?: number;
390
+ valid?: boolean;
391
+ divisionTopologyId?: string;
392
+ revisions?: Array<number>;
393
+ [key: string]: unknown;
394
+ }
395
+
396
+ export interface SelectionObjectTopology {
397
+ topology: SelectionObjectTopologyNode[];
398
+ layers: SelectionObjectLayer[];
399
+ }
400
+
401
+ export interface SelectionObjectTopologyStructure {
402
+ layers: SelectionObjectLayer[];
403
+ structures: Topology[] | string[];
404
+ }
405
+
406
+ export interface SelectionObject {
407
+ id?: string;
408
+ projectid: string;
409
+ divisionid?: string;
410
+ singleuse: boolean;
411
+ revisionnr?: string;
412
+ type: string;
413
+ elements?: string[];
414
+ revisionelements?: string[];
415
+ filter?: string;
416
+ topology?: SelectionObjectTopology;
417
+ topologyStructure?: SelectionObjectTopologyStructure
418
+ }
419
+
420
+ export interface ExportObject {
421
+ description: string;
422
+ id?: string;
423
+ name: string;
424
+ projectId: string;
425
+ singleUse: boolean;
426
+ selection: SelectionObject;
427
+ [key: string]: unknown;
428
+ }
429
+
430
+ export class ExportService {
431
+ constructor(api: Api);
432
+ createExportSelection(projectId: Guid, data: string): Promise<ExportObject>;
433
+ }
434
+
435
+ export interface StructureNode {
436
+ id: string;
437
+ parent?: string;
438
+ name: string;
439
+ type: string;
440
+ children?: StructureNode[];
441
+ lastTopologyId?: string;
442
+ count: number;
443
+ level: number;
444
+ nodeInfo: string;
445
+ hasGeometry?: boolean;
446
+ }
447
+
448
+ export interface ObjectFilterStructureResponse {
449
+ structure: StructureNode;
450
+ structureDepth: number;
451
+ }
452
+
453
+ export class PrivacyTexts {
454
+ constructor(api: Api);
455
+ get(lang: string | undefined, type: string | undefined): Promise<HTML>;
456
+ }
457
+
458
+ export interface IDBCache {
459
+ data: string;
460
+
461
+ clear(): void;
462
+ }
463
+
464
+ export class Hyperlinks {
465
+ constructor(api: Api);
466
+ delete(id: string): Promise<void>;
467
+ }
468
+
469
+ export class AttachmentLink {
470
+ id: string;
471
+ name: string;
472
+ fileName:string
473
+ size:number;
474
+ link:string;
475
+ version:number;
476
+ fileNameShort:string;
477
+ extension:string;
478
+ objectIds:string[];
479
+ sizeMB: string
480
+ }
481
+
482
+ export class Comments {
483
+ constructor(api: Api);
484
+ delete(id: string): Promise<void>;
485
+ }
486
+
487
+ export interface Coloring {
488
+ }
489
+
490
+ export interface SelectedInfo {
491
+ }
492
+
493
+ export interface ViewBox {
494
+ }
495
+
496
+ export interface ObjectProperties {
497
+ }
498
+
499
+ export class Api {
500
+ constructor(config: ApiConfig);
501
+
502
+ // Define methods and properties of the Teams class here
503
+
504
+ authorize: Authorize;
505
+ teams: Teams;
506
+ user: User;
507
+ projects: Projects;
508
+ connexis: Connexis;
509
+ objectFilters: ObjectFilters;
510
+ objects: Objects;
511
+ attachments: Attachments;
512
+ exportService: ExportService;
513
+ terms: PrivacyTexts;
514
+ imprints: PrivacyTexts;
515
+ dataProtection: PrivacyTexts;
516
+ hyperlinks: Hyperlinks;
517
+ comments: Comments;
518
+
519
+ setAccessToken(token: AccessToken): void;
520
+ getAccessToken(): AccessToken | null;
521
+
522
+ setTokenType(tokenType: AccessTokenType): void;
523
+ getTokenType(): AccessTokenType | null;
524
+
525
+ setAccessTokenAndType(token: AccessToken, tokenType: AccessTokenType): void;
526
+ getAccessTokenAndType(): { token: AccessToken | null, tokenType: AccessTokenType | null }
527
+
528
+ setTeamSlug(slug: TeamSlug): void;
529
+ getCache(): IDBCache;
530
+ getApiTeamUrl(): string;
531
+ }
532
+ }