-
Notifications
You must be signed in to change notification settings - Fork 196
/
Copy pathmethodsInterface.ts
9270 lines (8761 loc) · 318 KB
/
methodsInterface.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
MIT License
Copyright (c) 2023 Looker Data Sciences, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
/**
* 469 API methods
*/
import type {
DelimArray,
IDictionary,
IAPIMethods,
ITransportSettings,
SDKResponse,
} from '@looker/sdk-rtl';
/**
* NOTE: Do not edit this file generated by Looker SDK Codegen for API 4.0
*
*/
import type {
IAccessToken,
IAlert,
IAlertNotifications,
IAlertPatch,
IApiSession,
IApiVersion,
IArtifact,
IArtifactNamespace,
IArtifactUsage,
IBackupConfiguration,
IBoard,
IBoardItem,
IBoardSection,
IColorCollection,
IColumnSearch,
IConnectionFeatures,
IContentFavorite,
IContentMeta,
IContentMetaGroupUser,
IContentSearch,
IContentSummary,
IContentValidation,
IContentView,
ICostEstimate,
ICreateCostEstimate,
ICreateCredentialsApi3,
ICreateEmbedUserRequest,
ICreateFolder,
ICreateOAuthApplicationUserStateRequest,
ICreateOAuthApplicationUserStateResponse,
ICredentialsApi3,
ICredentialsEmail,
ICredentialsEmailSearch,
ICredentialsEmbed,
ICredentialsGoogle,
ICredentialsLDAP,
ICredentialsLookerOpenid,
ICredentialsOIDC,
ICredentialsSaml,
ICredentialsTotp,
ICustomWelcomeEmail,
IDashboard,
IDashboardAggregateTableLookml,
IDashboardBase,
IDashboardElement,
IDashboardFilter,
IDashboardLayout,
IDashboardLayoutComponent,
IDashboardLookml,
IDataActionForm,
IDataActionRequest,
IDataActionResponse,
IDatagroup,
IDBConnection,
IDBConnectionTestResult,
IDependencyGraph,
IDialectInfo,
IDigestEmails,
IDigestEmailSend,
IEgressIpAddresses,
IEmbedCookielessSessionAcquire,
IEmbedCookielessSessionAcquireResponse,
IEmbedCookielessSessionGenerateTokens,
IEmbedCookielessSessionGenerateTokensResponse,
IEmbedParams,
IEmbedSecret,
IEmbedSsoParams,
IEmbedUrlResponse,
IError,
IExternalOauthApplication,
IFolder,
IFolderBase,
IGitBranch,
IGitConnectionTest,
IGitConnectionTestResult,
IGroup,
IGroupHierarchy,
IGroupIdForGroupInclusion,
IGroupIdForGroupUserInclusion,
IGroupSearch,
IHomepageSection,
IIntegration,
IIntegrationHub,
IIntegrationTestResult,
IInternalHelpResources,
IInternalHelpResourcesContent,
IJsonBi,
ILDAPConfig,
ILDAPConfigTestResult,
ILegacyFeature,
ILocale,
ILook,
ILookmlModel,
ILookmlModelExplore,
ILookmlTest,
ILookmlTestResult,
ILookWithQuery,
IManifest,
IMaterializePDT,
IMergeQuery,
IMobileSettings,
IMobileToken,
IModel,
IModelFieldSuggestions,
IModelSet,
IOauthClientApp,
IOIDCConfig,
IPasswordConfig,
IPermission,
IPermissionSet,
IProject,
IProjectFile,
IProjectValidation,
IProjectValidationCache,
IProjectWorkspace,
IQuery,
IQueryTask,
IRenderTask,
IReport,
IRepositoryCredential,
IRequestActiveThemes,
IRequestAlertNotifications,
IRequestAllBoardItems,
IRequestAllBoardSections,
IRequestAllExternalOauthApplications,
IRequestAllGroups,
IRequestAllGroupUsers,
IRequestAllIntegrations,
IRequestAllLookmlModels,
IRequestAllRoles,
IRequestAllScheduledPlans,
IRequestAllUserAttributes,
IRequestAllUsers,
IRequestArtifact,
IRequestArtifactNamespaces,
IRequestConnectionColumns,
IRequestConnectionSchemas,
IRequestConnectionSearchColumns,
IRequestConnectionTables,
IRequestContentSummary,
IRequestContentThumbnail,
IRequestContentValidation,
IRequestCreateDashboardElement,
IRequestCreateDashboardRenderTask,
IRequestCreateQueryTask,
IRequestCreateUserCredentialsEmailPasswordReset,
IRequestDeployRefToProduction,
IRequestFolderChildren,
IRequestFolderChildrenSearch,
IRequestGraphDerivedTablesForModel,
IRequestGraphDerivedTablesForView,
IRequestLogin,
IRequestLookmlModelExplore,
IRequestModelFieldnameSuggestions,
IRequestRoleUsers,
IRequestRunGitConnectionTest,
IRequestRunInlineQuery,
IRequestRunLook,
IRequestRunLookmlTest,
IRequestRunQuery,
IRequestScheduledPlansForDashboard,
IRequestScheduledPlansForLook,
IRequestScheduledPlansForLookmlDashboard,
IRequestSearchAlerts,
IRequestSearchArtifacts,
IRequestSearchBoards,
IRequestSearchContent,
IRequestSearchContentFavorites,
IRequestSearchContentViews,
IRequestSearchCredentialsEmail,
IRequestSearchDashboardElements,
IRequestSearchDashboards,
IRequestSearchFolders,
IRequestSearchGroups,
IRequestSearchGroupsWithHierarchy,
IRequestSearchGroupsWithRoles,
IRequestSearchLooks,
IRequestSearchModelSets,
IRequestSearchPermissionSets,
IRequestSearchReports,
IRequestSearchRoles,
IRequestSearchRolesWithUserCount,
IRequestSearchScheduledPlans,
IRequestSearchThemes,
IRequestSearchUserLoginLockouts,
IRequestSearchUsers,
IRequestSearchUsersNames,
IRequestStartPdtBuild,
IRequestTagRef,
IRequestUserAttributeUserValues,
IRequestUserRoles,
IRole,
IRoleSearch,
IRunningQueries,
ISamlConfig,
ISamlMetadataParseResult,
IScheduledPlan,
ISchema,
ISchemaColumns,
ISchemaTables,
ISession,
ISessionConfig,
ISetting,
ISmtpSettings,
ISmtpStatus,
ISqlInterfaceQuery,
ISqlInterfaceQueryMetadata,
ISqlQuery,
ISqlQueryCreate,
ISshPublicKey,
ISshServer,
ISshTunnel,
ISupportAccessAddEntries,
ISupportAccessAllowlistEntry,
ISupportAccessEnable,
ISupportAccessStatus,
ITheme,
ITimezone,
IUpdateArtifact,
IUpdateFolder,
IUser,
IUserAttribute,
IUserAttributeGroupValue,
IUserAttributeWithValue,
IUserEmailOnly,
IUserLoginLockout,
IUserPublic,
IValidationError,
IWelcomeEmailTest,
IWhitelabelConfiguration,
IWorkspace,
IWriteAlert,
IWriteApiSession,
IWriteBackupConfiguration,
IWriteBoard,
IWriteBoardItem,
IWriteBoardSection,
IWriteColorCollection,
IWriteContentFavorite,
IWriteContentMeta,
IWriteCreateDashboardFilter,
IWriteCredentialsEmail,
IWriteDashboard,
IWriteDashboardElement,
IWriteDashboardFilter,
IWriteDashboardLayout,
IWriteDashboardLayoutComponent,
IWriteDashboardLookml,
IWriteDatagroup,
IWriteDBConnection,
IWriteEmbedSecret,
IWriteExternalOauthApplication,
IWriteGitBranch,
IWriteGroup,
IWriteIntegration,
IWriteIntegrationHub,
IWriteInternalHelpResources,
IWriteInternalHelpResourcesContent,
IWriteLDAPConfig,
IWriteLegacyFeature,
IWriteLookmlModel,
IWriteLookWithQuery,
IWriteMergeQuery,
IWriteMobileToken,
IWriteModelSet,
IWriteOauthClientApp,
IWriteOIDCConfig,
IWritePasswordConfig,
IWritePermissionSet,
IWriteProject,
IWriteQuery,
IWriteRepositoryCredential,
IWriteRole,
IWriteSamlConfig,
IWriteScheduledPlan,
IWriteSessionConfig,
IWriteSetting,
IWriteSqlInterfaceQueryCreate,
IWriteSshServer,
IWriteSshTunnel,
IWriteTheme,
IWriteUser,
IWriteUserAttribute,
IWriteUserAttributeWithValue,
IWriteWhitelabelConfiguration,
} from './models';
export interface ILooker40SDK extends IAPIMethods {
//#region Alert: Alert
/**
* Follow an alert.
*
* POST /alerts/{alert_id}/follow -> void
*
* @param alert_id ID of an alert
* @param options one-time API call overrides
*
*/
follow_alert(
alert_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* Unfollow an alert.
*
* DELETE /alerts/{alert_id}/follow -> void
*
* @param alert_id ID of an alert
* @param options one-time API call overrides
*
*/
unfollow_alert(
alert_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* ### Search Alerts
*
* GET /alerts/search -> IAlert[]
*
* @param request composed interface "IRequestSearchAlerts" for complex method parameters
* @param options one-time API call overrides
*
*/
search_alerts(
request: IRequestSearchAlerts,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlert[], IError>>;
/**
* ### Get an alert by a given alert ID
*
* GET /alerts/{alert_id} -> IAlert
*
* @param alert_id ID of an alert
* @param options one-time API call overrides
*
*/
get_alert(
alert_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlert, IError>>;
/**
* ### Update an alert
* # Required fields: `owner_id`, `field`, `destinations`, `comparison_type`, `threshold`, `cron`
* #
*
* PUT /alerts/{alert_id} -> IAlert
*
* @param alert_id ID of an alert
* @param body Partial<IWriteAlert>
* @param options one-time API call overrides
*
*/
update_alert(
alert_id: string,
body: Partial<IWriteAlert>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlert, IError | IValidationError>>;
/**
* ### Update select alert fields
* # Available fields: `owner_id`, `is_disabled`, `disabled_reason`, `is_public`, `threshold`
* #
*
* PATCH /alerts/{alert_id} -> IAlert
*
* @param alert_id ID of an alert
* @param body Partial<IAlertPatch>
* @param options one-time API call overrides
*
*/
update_alert_field(
alert_id: string,
body: Partial<IAlertPatch>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlert, IError | IValidationError>>;
/**
* ### Delete an alert by a given alert ID
*
* DELETE /alerts/{alert_id} -> void
*
* @param alert_id ID of an alert
* @param options one-time API call overrides
*
*/
delete_alert(
alert_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* ### Create a new alert and return details of the newly created object
*
* Required fields: `field`, `destinations`, `comparison_type`, `threshold`, `cron`
*
* Example Request:
* Run alert on dashboard element '103' at 5am every day. Send an email to '[email protected]' if inventory for Los Angeles (using dashboard filter `Warehouse Name`) is lower than 1,000
* ```
* {
* "cron": "0 5 * * *",
* "custom_title": "Alert when LA inventory is low",
* "dashboard_element_id": 103,
* "applied_dashboard_filters": [
* {
* "filter_title": "Warehouse Name",
* "field_name": "distribution_centers.name",
* "filter_value": "Los Angeles CA",
* "filter_description": "is Los Angeles CA"
* }
* ],
* "comparison_type": "LESS_THAN",
* "destinations": [
* {
* "destination_type": "EMAIL",
* "email_address": "[email protected]"
* }
* ],
* "field": {
* "title": "Number on Hand",
* "name": "inventory_items.number_on_hand"
* },
* "is_disabled": false,
* "is_public": true,
* "threshold": 1000
* }
* ```
*
* POST /alerts -> IAlert
*
* @param body Partial<IWriteAlert>
* @param options one-time API call overrides
*
*/
create_alert(
body: Partial<IWriteAlert>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlert, IError | IValidationError>>;
/**
* ### Enqueue an Alert by ID
*
* POST /alerts/{alert_id}/enqueue -> void
*
* @param alert_id ID of an alert
* @param force Whether to enqueue an alert again if its already running.
* @param options one-time API call overrides
*
*/
enqueue_alert(
alert_id: string,
force?: boolean,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* # Alert Notifications.
* The endpoint returns all the alert notifications received by the user on email in the past 7 days. It also returns whether the notifications have been read by the user.
*
* GET /alert_notifications -> IAlertNotifications[]
*
* @param request composed interface "IRequestAlertNotifications" for complex method parameters
* @param options one-time API call overrides
*
*/
alert_notifications(
request: IRequestAlertNotifications,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlertNotifications[], IError>>;
/**
* # Reads a Notification
* The endpoint marks a given alert notification as read by the user, in case it wasn't already read. The AlertNotification model is updated for this purpose. It returns the notification as a response.
*
* PATCH /alert_notifications/{alert_notification_id} -> IAlertNotifications
*
* @param alert_notification_id ID of a notification
* @param options one-time API call overrides
*
*/
read_alert_notification(
alert_notification_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAlertNotifications, IError | IValidationError>>;
//#endregion Alert: Alert
//#region ApiAuth: API Authentication
/**
* ### Present client credentials to obtain an authorization token
*
* Looker API implements the OAuth2 [Resource Owner Password Credentials Grant](https://cloud.google.com/looker/docs/r/api/outh2_resource_owner_pc) pattern.
* The client credentials required for this login must be obtained by creating an API key on a user account
* in the Looker Admin console. The API key consists of a public `client_id` and a private `client_secret`.
*
* The access token returned by `login` must be used in the HTTP Authorization header of subsequent
* API requests, like this:
* ```
* Authorization: token 4QDkCyCtZzYgj4C2p2cj3csJH7zqS5RzKs2kTnG4
* ```
* Replace "4QDkCy..." with the `access_token` value returned by `login`.
* The word `token` is a string literal and must be included exactly as shown.
*
* This function can accept `client_id` and `client_secret` parameters as URL query params or as www-form-urlencoded params in the body of the HTTP request. Since there is a small risk that URL parameters may be visible to intermediate nodes on the network route (proxies, routers, etc), passing credentials in the body of the request is considered more secure than URL params.
*
* Example of passing credentials in the HTTP request body:
* ````
* POST HTTP /login
* Content-Type: application/x-www-form-urlencoded
*
* client_id=CGc9B7v7J48dQSJvxxx&client_secret=nNVS9cSS3xNpSC9JdsBvvvvv
* ````
*
* ### Best Practice:
* Always pass credentials in body params. Pass credentials in URL query params **only** when you cannot pass body params due to application, tool, or other limitations.
*
* For more information and detailed examples of Looker API authorization, see [How to Authenticate to Looker API](https://github.com/looker/looker-sdk-ruby/blob/master/authentication.md).
*
* POST /login -> IAccessToken
*
* @param request composed interface "IRequestLogin" for complex method parameters
* @param options one-time API call overrides
*
*/
login(
request: IRequestLogin,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAccessToken, IError>>;
/**
* ### Create an access token that runs as a given user.
*
* This can only be called by an authenticated admin user. It allows that admin to generate a new
* authentication token for the user with the given user id. That token can then be used for subsequent
* API calls - which are then performed *as* that target user.
*
* The target user does *not* need to have a pre-existing API client_id/client_secret pair. And, no such
* credentials are created by this call.
*
* This allows for building systems where api user authentication for an arbitrary number of users is done
* outside of Looker and funneled through a single 'service account' with admin permissions. Note that a
* new access token is generated on each call. If target users are going to be making numerous API
* calls in a short period then it is wise to cache this authentication token rather than call this before
* each of those API calls.
*
* See 'login' for more detail on the access token and how to use it.
*
* Calls to this endpoint may be denied by [Looker (Google Cloud core)](https://cloud.google.com/looker/docs/r/looker-core/overview).
*
* POST /login/{user_id} -> IAccessToken
*
* @param user_id Id of user.
* @param associative When true (default), API calls using the returned access_token are attributed to the admin user who created the access_token. When false, API activity is attributed to the user the access_token runs as. False requires a looker license.
* @param options one-time API call overrides
*
*/
login_user(
user_id: string,
associative?: boolean,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IAccessToken, IError>>;
/**
* ### Logout of the API and invalidate the current access token.
*
* DELETE /logout -> string
*
* @param options one-time API call overrides
*
*/
logout(
options?: Partial<ITransportSettings>
): Promise<SDKResponse<string, IError>>;
//#endregion ApiAuth: API Authentication
//#region Artifact: Artifact Storage
/**
* Get the maximum configured size of the entire artifact store, and the currently used storage in bytes.
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* GET /artifact/usage -> IArtifactUsage
*
* @param fields Comma-delimited names of fields to return in responses. Omit for all fields
* @param options one-time API call overrides
*
*/
artifact_usage(
fields?: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IArtifactUsage, IError | IValidationError>>;
/**
* Get all artifact namespaces and the count of artifacts in each namespace
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* GET /artifact/namespaces -> IArtifactNamespace[]
*
* @param request composed interface "IRequestArtifactNamespaces" for complex method parameters
* @param options one-time API call overrides
*
*/
artifact_namespaces(
request: IRequestArtifactNamespaces,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IArtifactNamespace[], IError | IValidationError>>;
/**
* ### Return the value of an artifact
*
* The MIME type for the API response is set to the `content_type` of the value
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* GET /artifact/{namespace}/value -> string
*
* @param namespace Artifact storage namespace
* @param key Artifact storage key. Namespace + Key must be unique
* @param options one-time API call overrides
*
*/
artifact_value(
namespace: string,
key?: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<string, IError | IValidationError>>;
/**
* Remove *all* artifacts from a namespace. Purged artifacts are permanently deleted
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* DELETE /artifact/{namespace}/purge -> void
*
* @param namespace Artifact storage namespace
* @param options one-time API call overrides
*
*/
purge_artifacts(
namespace: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* ### Search all key/value pairs in a namespace for matching criteria.
*
* Returns an array of artifacts matching the specified search criteria.
*
* Key search patterns use case-insensitive matching and can contain `%` and `_` as SQL LIKE pattern match wildcard expressions.
*
* The parameters `min_size` and `max_size` can be used individually or together.
*
* - `min_size` finds artifacts with sizes greater than or equal to its value
* - `max_size` finds artifacts with sizes less than or equal to its value
* - using both parameters restricts the minimum and maximum size range for artifacts
*
* **NOTE**: Artifacts are always returned in alphanumeric order by key.
*
* Get a **single artifact** by namespace and key with [`artifact`](#!/Artifact/artifact)
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* GET /artifact/{namespace}/search -> IArtifact[]
*
* @param request composed interface "IRequestSearchArtifacts" for complex method parameters
* @param options one-time API call overrides
*
*/
search_artifacts(
request: IRequestSearchArtifacts,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IArtifact[], IError | IValidationError>>;
/**
* ### Get one or more artifacts
*
* Returns an array of artifacts matching the specified key value(s).
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* GET /artifact/{namespace} -> IArtifact[]
*
* @param request composed interface "IRequestArtifact" for complex method parameters
* @param options one-time API call overrides
*
*/
artifact(
request: IRequestArtifact,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IArtifact[], IError | IValidationError>>;
/**
* ### Delete one or more artifacts
*
* To avoid rate limiting on deletion requests, multiple artifacts can be deleted at the same time by using a comma-delimited list of artifact keys.
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* DELETE /artifact/{namespace} -> void
*
* @param namespace Artifact storage namespace
* @param key Comma-delimited list of keys. Wildcards not allowed.
* @param options one-time API call overrides
*
*/
delete_artifact(
namespace: string,
key: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<void, IError>>;
/**
* ### Create or update one or more artifacts
*
* Only `key` and `value` are required to _create_ an artifact.
* To _update_ an artifact, its current `version` value must be provided.
*
* In the following example `body` payload, `one` and `two` are existing artifacts, and `three` is new:
*
* ```json
* [
* { "key": "one", "value": "[ \"updating\", \"existing\", \"one\" ]", "version": 10, "content_type": "application/json" },
* { "key": "two", "value": "updating existing two", "version": 20 },
* { "key": "three", "value": "creating new three" },
* ]
* ```
*
* Notes for this body:
*
* - The `value` for `key` **one** is a JSON payload, so a `content_type` override is needed. This override must be done **every** time a JSON value is set.
* - The `version` values for **one** and **two** mean they have been saved 10 and 20 times, respectively.
* - If `version` is **not** provided for an existing artifact, the entire request will be refused and a `Bad Request` response will be sent.
* - If `version` is provided for an artifact, it is only used for helping to prevent inadvertent data overwrites. It cannot be used to **set** the version of an artifact. The Looker server controls `version`.
* - We suggest encoding binary values as base64. Because the MIME content type for base64 is detected as plain text, also provide `content_type` to correctly indicate the value's type for retrieval and client-side processing.
*
* Because artifacts are stored encrypted, the same value can be written multiple times (provided the correct `version` number is used). Looker does not examine any values stored in the artifact store, and only decrypts when sending artifacts back in an API response.
*
* **Note**: The artifact storage API can only be used by Looker-built extensions.
*
* PUT /artifacts/{namespace} -> IArtifact[]
*
* @param namespace Artifact storage namespace
* @param body Partial<IUpdateArtifact[]>
* @param fields Comma-delimited names of fields to return in responses. Omit for all fields
* @param options one-time API call overrides
*
*/
update_artifacts(
namespace: string,
body: Partial<IUpdateArtifact[]>,
fields?: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IArtifact[], IError | IValidationError>>;
//#endregion Artifact: Artifact Storage
//#region Auth: Manage User Authentication Configuration
/**
* ### Create an embed secret using the specified information.
*
* The value of the `secret` field will be set by Looker and returned.
*
* **NOTE**: Calls to this endpoint require [Embedding](https://cloud.google.com/looker/docs/r/looker-core-feature-embed) to be enabled. Usage of this endpoint is not authorized for Looker Core Standard and Looker Core Enterprise.
*
* POST /embed_config/secrets -> IEmbedSecret
*
* @param body Partial<IWriteEmbedSecret>
* @param options one-time API call overrides
*
*/
create_embed_secret(
body?: Partial<IWriteEmbedSecret>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IEmbedSecret, IError | IValidationError>>;
/**
* ### Delete an embed secret.
*
* **NOTE**: Calls to this endpoint require [Embedding](https://cloud.google.com/looker/docs/r/looker-core-feature-embed) to be enabled. Usage of this endpoint is not authorized for Looker Core Standard and Looker Core Enterprise.
*
* DELETE /embed_config/secrets/{embed_secret_id} -> string
*
* @param embed_secret_id Id of Embed Secret
* @param options one-time API call overrides
*
*/
delete_embed_secret(
embed_secret_id: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<string, IError>>;
/**
* ### Create Signed Embed URL
*
* Creates a signed embed URL and cryptographically signs it with an embed secret.
* This signed URL can then be used to instantiate a Looker embed session in a PBL web application.
* Do not make any modifications to the returned URL - any change may invalidate the signature and
* cause the URL to fail to load a Looker embed session.
*
* A signed embed URL can only be **used once**. After the URL has been used to request a page from the
* Looker server, it is invalid. Future requests using the same URL will fail. This is to prevent
* 'replay attacks'.
*
* The `target_url` property must be a complete URL of a Looker UI page - scheme, hostname, path and query params.
* To load a dashboard with id 56 and with a filter of `Date=1 years`, the looker URL would look like `https:/myname.looker.com/dashboards/56?Date=1%20years`.
* The best way to obtain this `target_url` is to navigate to the desired Looker page in your web browser and use the "Get embed URL" menu option
* to copy it to your clipboard and paste it into the `target_url` property as a quoted string value in this API request.
*
* Permissions for the embed user are defined by the groups in which the embed user is a member (`group_ids` property)
* and the lists of models and permissions assigned to the embed user.
* At a minimum, you must provide values for either the `group_ids` property, or **both** the models and permissions properties.
* These properties are additive; an embed user can be a member of certain groups AND be granted access to models and permissions.
*
* The embed user's access is the union of permissions granted by the `group_ids`, `models`, and `permissions` properties.
*
* This function does not strictly require all group_ids, user attribute names, or model names to exist at the moment the
* embed url is created. Unknown group_id, user attribute names or model names will be passed through to the output URL.
* Because of this, **these parameters are not validated** when the API call is made.
*
* The [Get Embed Url](https://cloud.google.com/looker/docs/r/get-signed-url) dialog can be used to determine and validate the correct permissions for signing an embed url.
* This dialog also provides the SDK syntax for the API call to make. Alternatively, you can copy the signed URL into the Embed URI Validator text box
* in `<your looker instance>/admin/embed` to diagnose potential problems.
*
* The `secret_id` parameter is optional. If specified, its value must be the id of an active secret defined in the Looker instance.
* if not specified, the URL will be signed using the most recent active signing secret. If there is no active secret for signing embed urls,
* a default secret will be created. This default secret is encrypted using HMAC/SHA-256.
*
* The `embed_domain` parameter is optional. If specified and valid, the domain will be added to the embed domain allowlist if it is missing.
*
* #### Security Note
* Protect this signed URL as you would an access token or password credentials - do not write
* it to disk, do not pass it to a third party, and only pass it through a secure HTTPS
* encrypted transport.
*
*
* **NOTE**: Calls to this endpoint require [Embedding](https://cloud.google.com/looker/docs/r/looker-core-feature-embed) to be enabled. Usage of this endpoint is not authorized for Looker Core Standard and Looker Core Enterprise.
*
* POST /embed/sso_url -> IEmbedUrlResponse
*
* @param body Partial<IEmbedSsoParams>
* @param options one-time API call overrides
*
*/
create_sso_embed_url(
body: Partial<IEmbedSsoParams>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IEmbedUrlResponse, IError | IValidationError>>;
/**
* ### Create an Embed URL
*
* Creates an embed URL that runs as the Looker user making this API call. ("Embed as me")
* This embed URL can then be used to instantiate a Looker embed session in a
* "Powered by Looker" (PBL) web application.
*
* This is similar to Private Embedding (https://cloud.google.com/looker/docs/r/admin/embed/private-embed). Instead of
* logging into the Web UI to authenticate, the user has already authenticated against the API to be able to
* make this call. However, unlike Private Embed where the user has access to any other part of the Looker UI,
* the embed web session created by requesting the EmbedUrlResponse.url in a browser only has access to
* content visible under the `/embed` context.
*
* An embed URL can only be used once, and must be used within 5 minutes of being created. After it
* has been used to request a page from the Looker server, the URL is invalid. Future requests using
* the same URL will fail. This is to prevent 'replay attacks'.
*
* The `target_url` property must be a complete URL of a Looker Embedded UI page - scheme, hostname, path starting with "/embed" and query params.
* To load a dashboard with id 56 and with a filter of `Date=1 years`, the looker Embed URL would look like `https://myname.looker.com/embed/dashboards/56?Date=1%20years`.
* The best way to obtain this target_url is to navigate to the desired Looker page in your web browser,
* copy the URL shown in the browser address bar, insert "/embed" after the host/port, and paste it into the `target_url` property as a quoted string value in this API request.
*
* #### Security Note
* Protect this signed URL as you would an access token or password credentials - do not write
* it to disk, do not pass it to a third party, and only pass it through a secure HTTPS
* encrypted transport.
*
*
* **NOTE**: Calls to this endpoint require [Embedding](https://cloud.google.com/looker/docs/r/looker-core-feature-embed) to be enabled. Usage of this endpoint is not authorized for Looker Core Standard and Looker Core Enterprise.
*
* POST /embed/token_url/me -> IEmbedUrlResponse
*
* @param body Partial<IEmbedParams>
* @param options one-time API call overrides
*
*/
create_embed_url_as_me(
body: Partial<IEmbedParams>,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IEmbedUrlResponse, IError | IValidationError>>;
/**
* ### Validate a Signed Embed URL
*
* GET /embed/sso/validate -> IEmbedUrlResponse
*
* @param url URL to validate
* @param options one-time API call overrides
*
*/
validate_embed_url(
url?: string,
options?: Partial<ITransportSettings>
): Promise<SDKResponse<IEmbedUrlResponse, IError | IValidationError>>;
/**
* ### Acquire a cookieless embed session.
*
* The acquire session endpoint negates the need for signing the embed url and passing it as a parameter
* to the embed login. This endpoint accepts an embed user definition and creates or updates it. This is
* similar behavior to the embed SSO login as they both can create and update embed user data.
*
* The endpoint also accepts an optional `session_reference_token`. If present and the session has not expired
* and the credentials match the credentials for the embed session, a new authentication token will be
* generated. This allows the embed session to attach a new embedded IFRAME to the embed session. Note that
* the session is NOT extended in this scenario. In other words the session_length parameter is ignored.
*
* **IMPORTANT:** If the `session_reference_token` is provided and the session has NOT expired, the embed user
* is NOT updated. This is done for performance reasons and to support the embed SSO usecase where the
* first IFRAME created on a page uses a signed url and subsequently created IFRAMEs do not.
*
* If the `session_reference_token` is provided but the session has expired, the token will be ignored and a
* new embed session will be created. Note that the embed user definition will be updated in this scenario.
*
* If the credentials do not match the credentials associated with an existing session_reference_token, a
* 404 will be returned.
*
* The endpoint returns the following:
* - Authentication token - a token that is passed to `/embed/login` endpoint that creates or attaches to the
* embed session. This token can be used once and has a lifetime of 30 seconds.
* - Session reference token - a token that lives for the length of the session. This token is used to
* generate new api and navigation tokens OR create new embed IFRAMEs.
* - Api token - lives for 10 minutes. The Looker client will ask for this token once it is loaded into the
* iframe.
* - Navigation token - lives for 10 minutes. The Looker client will ask for this token once it is loaded into
* the iframe.
*
* **NOTE**: Calls to this endpoint require [Embedding](https://cloud.google.com/looker/docs/r/looker-core-feature-embed) to be enabled. Usage of this endpoint is not authorized for Looker Core Standard and Looker Core Enterprise.
*
* POST /embed/cookieless_session/acquire -> IEmbedCookielessSessionAcquireResponse
*
* @param body Partial<IEmbedCookielessSessionAcquire>
* @param options one-time API call overrides
*
*/
acquire_embed_cookieless_session(
body: Partial<IEmbedCookielessSessionAcquire>,
options?: Partial<ITransportSettings>
): Promise<
SDKResponse<