@mediaviz/sdk 1.2.0 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/sdk.d.cts ADDED
@@ -0,0 +1,504 @@
1
+ // Auto-generated — do not edit. TypeScript declarations for the MediaViz SDK.
2
+ export interface TokenResponse {
3
+ access_token: string;
4
+ token_type: string;
5
+ expires_in: number;
6
+ refresh_token: string;
7
+ }
8
+
9
+ export interface AuthorizationUrlResult {
10
+ url: string;
11
+ state: string;
12
+ code_verifier: string;
13
+ }
14
+
15
+ export interface MediaVizConfig {
16
+ clientId?: string;
17
+ clientSecret?: string;
18
+ baseUrl?: string;
19
+ redirectUri?: string;
20
+ hosts?: Record<string, string>;
21
+ accessToken?: string;
22
+ refreshToken?: string;
23
+ onTokenRefresh?: (tokens: TokenResponse) => void;
24
+ }
25
+
26
+ export class OAuthClient {
27
+ constructor(config: { baseUrl?: string; clientId?: string; clientSecret?: string; redirectUri?: string });
28
+ }
29
+
30
+ export class OAuthError extends Error {
31
+ code: string;
32
+ }
33
+
34
+ export const OAuthErrorCode: { [key: string]: string };
35
+
36
+ export class ApiError extends Error {
37
+ status: number;
38
+ requestId: string | null;
39
+ body: any;
40
+ constructor(message: string, status: number, requestId: string | null, body: any);
41
+ }
42
+
43
+ export class ValidationError extends ApiError {
44
+ fieldErrors: Array<{ loc: (string | number)[]; msg: string; type: string }>;
45
+ constructor(body: any, status: number, requestId: string | null);
46
+ }
47
+
48
+ export class NotFoundError extends ApiError {
49
+ constructor(body: any, status: number, requestId: string | null);
50
+ }
51
+
52
+ export class RateLimitError extends ApiError {
53
+ retryAfter: number | null;
54
+ constructor(body: any, status: number, requestId: string | null, headers: Headers);
55
+ }
56
+
57
+ export class ServerError extends ApiError {
58
+ constructor(body: any, status: number, requestId: string | null);
59
+ }
60
+
61
+ export function handleResponse(response: Response): Promise<any>;
62
+
63
+ // ── response schemas ──
64
+ export interface AlbumDisplay {
65
+ name?: string;
66
+ description?: string;
67
+ id: number;
68
+ project_table_name: string;
69
+ }
70
+
71
+ export interface AnalysisStatusResponse {
72
+ project_table_name: string;
73
+ model_or_process: string;
74
+ status: string;
75
+ last_updated_at: string;
76
+ }
77
+
78
+ export interface CompanyDisplay {
79
+ name: string;
80
+ id: number;
81
+ owner_id: number;
82
+ users?: number[];
83
+ active: boolean;
84
+ payment_plan_type: string;
85
+ }
86
+
87
+ export interface CompanyKeywordListOverview {
88
+ id: number;
89
+ name: string;
90
+ active_keywords: number;
91
+ excluded_keywords: number;
92
+ project_ids?: string[];
93
+ }
94
+
95
+ export interface CreditBalanceOutput {
96
+ sufficient_credits: boolean;
97
+ current_credit_balance: number;
98
+ credit_cost: number;
99
+ required_credits: number;
100
+ }
101
+
102
+ export interface CuratedAlbumDisplay {
103
+ id: number;
104
+ project_table_name: string;
105
+ name: string;
106
+ description?: string;
107
+ confidence_value?: number;
108
+ }
109
+
110
+ export interface HealthCheck {
111
+ status?: string;
112
+ timestamp?: string;
113
+ checks?: Record<string, any>;
114
+ }
115
+
116
+ export interface KeywordListDisplayWithList {
117
+ id: number;
118
+ user_id: number;
119
+ company_id: number;
120
+ name: string;
121
+ date_created: string;
122
+ date_last_updated: string;
123
+ is_inclusion?: boolean;
124
+ gsheet_view_link?: string;
125
+ gsheet_csv_link?: string;
126
+ gsheet_xlsx_link?: string;
127
+ list_keywords_included_or_excluded?: number[];
128
+ }
129
+
130
+ export interface KeywordListDisplayWithProjects {
131
+ id: number;
132
+ user_id: number;
133
+ company_id: number;
134
+ name: string;
135
+ date_created: string;
136
+ date_last_updated: string;
137
+ is_inclusion?: boolean;
138
+ list_projects_associated?: string[];
139
+ }
140
+
141
+ export interface PhotoDisplay {
142
+ photo_s3_link: string;
143
+ client_side_id?: string;
144
+ moment_id?: number;
145
+ file_path?: string;
146
+ image_metadata?: Record<string, any>;
147
+ tags?: string[];
148
+ title?: string;
149
+ description?: string;
150
+ format?: string;
151
+ size?: string;
152
+ source_resolution_x?: number;
153
+ source_resolution_y?: number;
154
+ date_taken?: string;
155
+ date_modified?: string;
156
+ date_guessed?: string;
157
+ date_uploaded?: string;
158
+ latitude?: number;
159
+ longitude?: number;
160
+ country_code?: string;
161
+ country?: string;
162
+ state?: string;
163
+ city?: string;
164
+ average_hash?: string;
165
+ perceptual_hash?: string;
166
+ difference_hash?: string;
167
+ wavelet_hash_haar?: string;
168
+ color_hash?: string;
169
+ reference_1_average_distance?: number;
170
+ reference_2_average_distance?: number;
171
+ reference_3_average_distance?: number;
172
+ main_color_palette?: string[];
173
+ color_averages?: string[];
174
+ labels_from_classifications_model?: Record<string, any>;
175
+ ocr_output?: Record<string, any>;
176
+ bounding_boxes_from_faces_model?: Record<string, any>[];
177
+ number_of_faces?: number;
178
+ blur_value?: number;
179
+ feature_extraction_output?: number[];
180
+ similar_photo_ids_high?: number[];
181
+ similar_photo_ids_medium?: number[];
182
+ similar_photo_ids_low?: number[];
183
+ evidence_score?: number;
184
+ face_score?: number;
185
+ content_score?: number;
186
+ aesthetic_score?: number;
187
+ similarity_set_ranking?: number;
188
+ topic?: string;
189
+ rank?: number;
190
+ hue_values?: number[];
191
+ light_values?: number[];
192
+ saturation_values?: number[];
193
+ user_id: number;
194
+ company_id: number;
195
+ id: number;
196
+ project_table_name: string;
197
+ }
198
+
199
+ export interface PhotoFace {
200
+ smile_value?: boolean;
201
+ smile_confidence?: number;
202
+ eyeglasses_value?: boolean;
203
+ eyeglasses_confidence?: number;
204
+ sunglasses_value?: boolean;
205
+ sunglasses_confidence?: number;
206
+ eyes_open_value?: boolean;
207
+ eyes_open_confidence?: number;
208
+ emotion_happy_confidence?: number;
209
+ emotion_sad_confidence?: number;
210
+ landmark_eyeleft_x?: number;
211
+ landmark_eyeleft_y?: number;
212
+ landmark_eyeright_x?: number;
213
+ landmark_eyeright_y?: number;
214
+ landmark_mouthleft_x?: number;
215
+ landmark_mouthleft_y?: number;
216
+ landmark_mouthright_x?: number;
217
+ landmark_mouthright_y?: number;
218
+ landmark_nose_x?: number;
219
+ landmark_nose_y?: number;
220
+ pose_roll?: number;
221
+ pose_yaw?: number;
222
+ pose_pitch?: number;
223
+ quality_brightness?: number;
224
+ quality_sharpness?: number;
225
+ face_occluded_value?: boolean;
226
+ eye_direction_yaw?: number;
227
+ eye_direction_pitch?: number;
228
+ eye_direction_confidence?: number;
229
+ }
230
+
231
+ export interface PhotoPersonLight {
232
+ id: number;
233
+ person_id: string;
234
+ bounding_box: Record<string, any>;
235
+ confidence: number;
236
+ person_name: string;
237
+ }
238
+
239
+ export interface PhotoPersonWithS3Link {
240
+ id: number;
241
+ person_id: string;
242
+ bounding_box: Record<string, any>;
243
+ confidence: number;
244
+ person_name: string;
245
+ photo_s3_link: string;
246
+ }
247
+
248
+ export interface ProjectRunDisplay {
249
+ name: string;
250
+ private?: boolean;
251
+ type?: number;
252
+ description?: string;
253
+ directory?: string;
254
+ photo_upload_vector?: number;
255
+ thumbnail?: string;
256
+ run_name?: string;
257
+ id: string;
258
+ user_id: number;
259
+ company_id: number;
260
+ active: boolean;
261
+ project_table_name: string;
262
+ date_created: string;
263
+ number_of_photos?: number;
264
+ date_photos_uploaded?: string;
265
+ date_deleted?: string;
266
+ top_tier?: number;
267
+ tier_2?: number;
268
+ total_photos_uploaded?: number;
269
+ gsheet_view_link?: string;
270
+ gsheet_csv_link?: string;
271
+ gsheet_xlsx_link?: string;
272
+ insights_view_link?: string;
273
+ similarity_level?: string;
274
+ blur_model?: boolean;
275
+ colors_model?: boolean;
276
+ face_recognition_model?: boolean;
277
+ image_classification_model?: boolean;
278
+ image_comparison_model?: boolean;
279
+ image_describe_model?: boolean;
280
+ ocr_model?: boolean;
281
+ similarity_model?: boolean;
282
+ personhood_model?: boolean;
283
+ evidence_model?: boolean;
284
+ insights_model?: boolean;
285
+ normalize?: boolean;
286
+ }
287
+
288
+ export interface SearchDisplay {
289
+ id: number;
290
+ project_table_name: string;
291
+ search_name: string;
292
+ and_params?: string[];
293
+ and_string_params?: string[];
294
+ or_params?: string[];
295
+ or_string_params?: string[];
296
+ not_params?: string[];
297
+ not_string_params?: string[];
298
+ date_min?: string;
299
+ date_max?: string;
300
+ date_null_and?: boolean;
301
+ date_null_or?: boolean;
302
+ date_order?: string;
303
+ custom_album_id?: number;
304
+ best_of_similar_sets_only?: boolean;
305
+ curated_album_id?: number;
306
+ }
307
+
308
+ export interface UserDisplay {
309
+ id: number;
310
+ company_id: number;
311
+ name: string;
312
+ email: string;
313
+ account_type: number;
314
+ location?: string;
315
+ phone_number?: string;
316
+ birthday?: string;
317
+ profile_picture?: string;
318
+ }
319
+
320
+ export class AiModelCredits {
321
+ getModelCreditRelationship(modelName: string): Promise<Record<string, any>>;
322
+ }
323
+
324
+ export class Admin {
325
+ getCategoryLabels(category: string): Promise<Record<string, any>>;
326
+ }
327
+
328
+ export class Company {
329
+ getCompanyById(companyId: number): Promise<CompanyDisplay>;
330
+ confirmCompanyCreditBalance(companyId: number, options?: { photoCount?: number | number[], modelsList?: string[] | string[][] }): Promise<CreditBalanceOutput>;
331
+ }
332
+
333
+ export class CuratedAlbums {
334
+ createCuratedAlbum(projectTableName: string, name: string, description?: string, confidenceValue?: number): Promise<CuratedAlbumDisplay>;
335
+ getAllProjectCuratedAlbums(projectTableName: string): Promise<CuratedAlbumDisplay[]>;
336
+ getCuratedAlbumPhotos(albumId: number, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[], confidenceValue?: number | number[] }): Promise<any[]>;
337
+ getCuratedAlbumPhotosRanked(albumId: number, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[], confidenceValue?: number | number[] }): Promise<Record<string, any>>;
338
+ getCuratedAlbumById(albumId: number): Promise<CuratedAlbumDisplay>;
339
+ updateCuratedAlbum(albumId: number, body?: { name?: string, description?: string, confidenceValue?: number }): Promise<CuratedAlbumDisplay>;
340
+ deleteCuratedAlbum(albumId: number): Promise<Record<string, any>>;
341
+ convertCuratedAlbumToCustom(albumId: number): Promise<CuratedAlbumDisplay>;
342
+ }
343
+
344
+ export class CustomAlbums {
345
+ getCustomAlbumDetailById(customAlbumId: number): Promise<AlbumDisplay>;
346
+ getAllProjectCustomAlbums(projectTableName: string): Promise<AlbumDisplay[]>;
347
+ getCustomAlbumPhotosById(customAlbumId: number, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[] }): Promise<any>;
348
+ getRankedCustomAlbumById(customAlbumId: number, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[] }): Promise<Record<string, any>>;
349
+ createProjectCustomAlbum(projectTableName: string, body?: { name?: string, description?: string, photoIdInclusionList?: number[], photoIdRemovalList?: number[] }): Promise<AlbumDisplay>;
350
+ updateCustomAlbum(albumId: number, body?: { name?: string, description?: string, photoIdInclusionList?: number[], photoIdRemovalList?: number[] }): Promise<AlbumDisplay>;
351
+ deleteCustomAlbum(albumId: number): Promise<Record<string, any>>;
352
+ }
353
+
354
+ export class EmailTokens {
355
+ requestEmailVerification(options?: { email?: string | string[] }): Promise<Record<string, any>>;
356
+ verifyEmail(token: string): Promise<Record<string, any>>;
357
+ requestPasswordReset(options?: { email?: string | string[] }): Promise<Record<string, any>>;
358
+ validateToken(token: string): Promise<Record<string, any>>;
359
+ resetPassword(token: string, newPassword: string): Promise<Record<string, any>>;
360
+ deleteUserEmailTokens(userId: number): Promise<Record<string, any>>;
361
+ }
362
+
363
+ export class Health {
364
+ healthCheck(): Promise<HealthCheck>;
365
+ livenessCheck(): Promise<HealthCheck>;
366
+ readinessCheck(): Promise<HealthCheck>;
367
+ }
368
+
369
+ export class Keywords {
370
+ createKeywordFilteringList(name: string, projectList?: string[]): Promise<KeywordListDisplayWithProjects>;
371
+ getUserKeywordFilteringLists(): Promise<KeywordListDisplayWithProjects[]>;
372
+ getCompanyKeywordLists(companyId: number): Promise<CompanyKeywordListOverview[]>;
373
+ getKeywordFilteringListAndProjectsById(keywordListId: number): Promise<KeywordListDisplayWithProjects>;
374
+ getKeywordFilteringListById(keywordListId: number): Promise<KeywordListDisplayWithList>;
375
+ getExistingKeywordFilteringListByProject(projectTableName: string): Promise<Record<string, any>>;
376
+ getDefaultKeywordFilteringListByProject(projectTableName: string): Promise<Record<string, any>>;
377
+ updateKeywordFilteringListLabels(keywordListId: number, listKeywordsToInclude: number[], listKeywordsToExclude: number[]): Promise<KeywordListDisplayWithList>;
378
+ updateKeywordFilteringListDetails(keywordListId: number, body?: { name?: string, projectList?: string[] }): Promise<KeywordListDisplayWithProjects>;
379
+ addProjectsToKeywordFilteringList(keywordListId: number, options?: { projectIds?: any }): Promise<Record<string, any>>;
380
+ addCompanyToKeywordFilteringList(keywordListId: number, options?: { companyId?: number | number[] }): Promise<Record<string, any>>;
381
+ requestKeywordListExport(keywordListId: number): Promise<Record<string, any>>;
382
+ requestKeywordListExportStatus(keywordListId: number): Promise<AnalysisStatusResponse>;
383
+ getKeywordsAndIds(): Promise<any>;
384
+ removeProjectsFromKeywordFilteringList(keywordListId: number, options?: { projectIds?: any }): Promise<Record<string, any>>;
385
+ removeCompanyFromKeywordFilteringList(keywordListId: number, options?: { companyId?: number | number[] }): Promise<Record<string, any>>;
386
+ deleteKeywordFilteringListById(keywordListId: number): Promise<Record<string, any>>;
387
+ }
388
+
389
+ export class OauthAuthorization {
390
+ authorize(options?: { responseType?: string | string[], clientId?: string | string[], redirectUri?: string | string[], state?: string | string[], codeChallenge?: string | string[], codeChallengeMethod?: string | string[] }): Promise<any>;
391
+ getConsent(sessionId: string): Promise<any>;
392
+ postApproveConsent(sessionId: string, body: { restartUrl: string }): Promise<any>;
393
+ postDenyConsent(sessionId: string, body: { restartUrl: string }): Promise<any>;
394
+ getSwitchUser(sessionId: string, options?: { restartUrl?: string | string[] }): Promise<any>;
395
+ }
396
+
397
+ export class OauthToken {
398
+ token(body: { grantType: string, code: string, redirectUri: string, clientId: string, codeVerifier: string, refreshToken: string, clientSecret: string }): Promise<Record<string, any>>;
399
+ adminRevokeUserTokens(userId: number): Promise<Record<string, any>>;
400
+ revoke(body: { token: string, tokenTypeHint: string, clientId: string }): Promise<any>;
401
+ }
402
+
403
+ export class OauthLogin {
404
+ getLogin(options?: { next?: string | string[] }): Promise<any>;
405
+ postLogin(body: { email: string, password: string, next: string }): Promise<any>;
406
+ }
407
+
408
+ export class Person {
409
+ updatePerson(projectTableName: string, personId: string, options?: { personName?: string | string[] }): Promise<any>;
410
+ combinePersons(projectTableName: string, destinationPersonId: string, oldPersonId: string): Promise<PhotoPersonLight>;
411
+ splitPersons(projectTableName: string, id: number, options?: { newName?: string | string[], destinationPersonId?: string | string[] }): Promise<PhotoPersonLight>;
412
+ getAllPersonsFromProject(projectTableName: string): Promise<PhotoPersonWithS3Link[]>;
413
+ getAllPersonNamesFromProject(projectTableName: string): Promise<any>;
414
+ getPhotoIdsByPersons(projectTableName: string, options?: { personId?: string[] | string[][] }): Promise<any>;
415
+ getAllPersonsFromPhoto(projectTableName: string, photoId: number): Promise<PhotoPersonLight[]>;
416
+ }
417
+
418
+ export class Photoupload {
419
+ uploadPhotoToMediaviz(companyId: string, userId: string, projectTableName: string, title: string, body: { fileContent: string, mimetype: string, filePath: string }, headerOptions?: { clientSideId?: string, blur?: string, colors?: string, faceRecognition?: string, imageDescribe?: string, imageClassification?: string, imageComparison?: string, size?: string, sourceResolutionX?: string, sourceResolutionY?: string, dateTaken?: string, latitude?: string, longitude?: string, ocr?: string }): Promise<any>;
420
+ uploadPhoto(projectTableName: string, companyId: string, userId: string, photoIndex: number, photo: Record<string, any>): Promise<any>;
421
+ }
422
+
423
+ export class Photos {
424
+ getPhotoFromProject(tableName: string, photoId: number, options?: { keywordListId?: number | number[] }): Promise<PhotoDisplay>;
425
+ getPhotoFaceDetailsFromProject(tableName: string, photoId: number): Promise<PhotoFace[]>;
426
+ getProjectPhotoIdsByTableName(tableName: string, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[], includeAll?: boolean | boolean[], startDate?: string | string[], endDate?: string | string[], noDateTaken?: boolean | boolean[] }): Promise<any>;
427
+ getRankedProjectPhotoIdsByTableName(tableName: string, options?: { ascOrDesc?: string | string[], lastId?: number | number[], limit?: number | number[], startDate?: string | string[], endDate?: string | string[], noDateTaken?: boolean | boolean[] }): Promise<Record<string, any>>;
428
+ getProjectMonthYearsWithPhotos(tableName: string): Promise<any>;
429
+ updatePhotoInProject(options?: { tableName?: string | string[], photoId?: number | number[], photoData?: Record<string, any> | Record<string, any>[] }): Promise<PhotoDisplay>;
430
+ updatePhotoRanking(tableName: string, photoId: number, newCategory: string): Promise<Record<string, any>>;
431
+ deletePhotoFromProject(tableName: string, options?: { photoIds?: any }): Promise<Record<string, any>>;
432
+ }
433
+
434
+ export class Projects {
435
+ createProjectAndRun(name: string, private_?: boolean, type?: number, description?: string, directory?: string, photoUploadVector?: number, thumbnail?: string, runName?: string, options?: { outcomes?: any, models?: any }): Promise<ProjectRunDisplay>;
436
+ markProjectUploadComplete(projectTableName: string, options?: { skippedFileCount?: number | number[] }): Promise<any>;
437
+ checkProjectStatus(projectTableName: string): Promise<any>;
438
+ getProjectPrelimModelRequestTemplate(projectTableName: string): Promise<Record<string, any>>;
439
+ getUserProjects(): Promise<ProjectRunDisplay[]>;
440
+ getAdminProjects(): Promise<ProjectRunDisplay[]>;
441
+ getProjectById(projectId: string): Promise<ProjectRunDisplay>;
442
+ getProjectByDirectory(directory: string): Promise<ProjectRunDisplay>;
443
+ updateProject(projectId: string, body?: { private?: boolean, type?: number, description?: string, directory?: string, name?: string, thumbnail?: string }): Promise<ProjectRunDisplay>;
444
+ updateProjectPhotoCount(tableName: string, options?: { filesFailedCount?: number | number[] }): Promise<any>;
445
+ updateProjectCreateUploadReport(tableName: string, options?: { filesFailedCount?: number | number[] }): Promise<any>;
446
+ requestProjectSimilarityQueue(projectTableName: string, level: string): Promise<Record<string, any>>;
447
+ requestProjectEvidenceQueue(projectTableName: string): Promise<Record<string, any>>;
448
+ requestProjectPersonhoodQueue(projectTableName: string): Promise<Record<string, any>>;
449
+ requestInsightsQueue(analysisLevel: string, identifier: string): Promise<Record<string, any>>;
450
+ requestProjectExport(projectTableName: string): Promise<Record<string, any>>;
451
+ getProjectDataExportUploadStatus(projectTableName: string, modelName: string): Promise<AnalysisStatusResponse>;
452
+ addProjectEvent(projectTableName: string, event: string, detail?: string): Promise<Record<string, any>>;
453
+ deleteProject(projectId: string): Promise<Record<string, any>>;
454
+ }
455
+
456
+ export class Search {
457
+ searchProjectPhotos(projectTableName: string, options?: { andParams?: any, andStringParams?: any, orParams?: any, orStringParams?: any, notParams?: any, notStringParams?: any, dateMin?: string | string[], dateMax?: string | string[], dateNullAnd?: boolean | boolean[], dateNullOr?: boolean | boolean[], dateOrder?: string | string[], customAlbumId?: number | number[], bestOfSimilarSetsOnly?: boolean | boolean[], curatedAlbumId?: number | number[], splitByTier?: boolean | boolean[] }): Promise<Record<string, any>>;
458
+ searchProjectPhotosParametrized(projectTableName: string, options?: { andSearchText?: any, orSearchText?: any, notSearchText?: any, city?: any, country?: any, state?: any, albums?: any, dateMin?: string | string[], dateMax?: string | string[], dateNullAnd?: boolean | boolean[], dateNullOr?: boolean | boolean[], ascOrDesc?: string | string[], bestOfSimilarSetsOnly?: boolean | boolean[], splitByTier?: boolean | boolean[], lastId?: number | number[], limit?: number | number[] }): Promise<Record<string, any>>;
459
+ recallProjectPhotoIds(projectTableName: string, options?: { ascOrDesc?: string | string[], bestOfSimilarSetsOnly?: boolean | boolean[], lastId?: number | number[], limit?: number | number[] }): Promise<any>;
460
+ searchProjectPhotosNaturalLanguage(projectTableName: string, searchText: string, size?: number, options?: { minCosine?: number | number[], labelMinCosine?: number | number[], labelTopK?: number | number[], labelDelta?: number | number[], bestOfSimilarSetsOnly?: boolean | boolean[], splitByTier?: boolean | boolean[] }): Promise<Record<string, any>>;
461
+ getProjectSavedSearches(projectTableName: string): Promise<any>;
462
+ getSavedSearchById(searchId: number): Promise<SearchDisplay>;
463
+ saveProjectPhotosSearch(projectTableName: string, options?: { searchName?: string | string[], andParams?: any, andStringParams?: any, orParams?: any, orStringParams?: any, notParams?: any, notStringParams?: any, dateMin?: string | string[], dateMax?: string | string[], dateNullAnd?: boolean | boolean[], dateNullOr?: boolean | boolean[], dateOrder?: string | string[], customAlbumId?: number | number[], bestOfSimilarSetsOnly?: boolean | boolean[], curatedAlbumId?: number | number[], splitByTier?: boolean | boolean[] }): Promise<Record<string, any>>;
464
+ deleteSavedSearchById(searchId: number): Promise<Record<string, any>>;
465
+ }
466
+
467
+ export class Users {
468
+ createUser(name: string, email: string, accountType: number, companyId?: number, profilePicture?: string, paymentPlanType?: string): Promise<UserDisplay>;
469
+ createUserAndCompany(name: string, email: string, password: string, companyId?: number, profilePicture?: string, paymentPlanType?: string, companyName?: string, credits?: number, options?: { inviteToken?: string | string[] }): Promise<UserDisplay>;
470
+ changePassword(oldPassword: string, newPassword: string): Promise<Record<string, any>>;
471
+ getUserId(): Promise<Record<string, any>>;
472
+ getUser(userId: number): Promise<UserDisplay>;
473
+ getAllUsersByCompany(companyId: number): Promise<UserDisplay[]>;
474
+ updateUser(userId: number, body?: { name?: string, email?: string, password?: string, companyId?: number, accountType?: number, profilePicture?: string, location?: string, phoneNumber?: string, birthday?: string }): Promise<UserDisplay>;
475
+ deleteUser(userId: number, options?: { newCompanyOwnerId?: number | number[] }): Promise<Record<string, any>>;
476
+ }
477
+
478
+ export class MediaViz {
479
+ constructor(config?: MediaVizConfig);
480
+ authenticate(): Promise<TokenResponse>;
481
+ getAuthorizationUrl(state?: string): Promise<AuthorizationUrlResult>;
482
+ handleCallback(code: string, codeVerifier: string): Promise<TokenResponse>;
483
+ setTokens(accessToken: string, refreshToken: string): void;
484
+ readonly accessToken: string | null;
485
+ readonly refreshToken: string | null;
486
+ readonly aiModelCredits: AiModelCredits;
487
+ readonly admin: Admin;
488
+ readonly company: Company;
489
+ readonly curatedAlbums: CuratedAlbums;
490
+ readonly customAlbums: CustomAlbums;
491
+ readonly emailTokens: EmailTokens;
492
+ readonly health: Health;
493
+ readonly keywords: Keywords;
494
+ readonly oAuthAuthorization: OauthAuthorization;
495
+ readonly oAuthToken: OauthToken;
496
+ readonly oauthLogin: OauthLogin;
497
+ readonly person: Person;
498
+ readonly photoUpload: Photoupload;
499
+ readonly photos: Photos;
500
+ readonly projects: Projects;
501
+ readonly search: Search;
502
+ readonly users: Users;
503
+ }
504
+