Skip to content

Commit 1d72127

Browse files
feat: generate SDKs for Looker 24.14 (#1490)
Release-As: 24.14.0
1 parent aee5bf3 commit 1d72127

File tree

26 files changed

+1307
-185
lines changed

26 files changed

+1307
-185
lines changed

csharp/rtl/Constants.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ public struct Constants
6161

6262
public const string DefaultApiVersion = "4.0";
6363
public const string AgentPrefix = "CS-SDK";
64-
public const string LookerVersion = "24.12";
64+
public const string LookerVersion = "24.14";
6565

6666
public const string Bearer = "Bearer";
6767
public const string LookerAppiId = "x-looker-appid";

csharp/sdk/4.0/methods.cs

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
/// SOFTWARE.
2222
///
2323

24-
/// 464 API methods
24+
/// 465 API methods
2525

2626
#nullable enable
2727
using System;
@@ -2499,6 +2499,8 @@ public async Task<SdkResponse<MobileSettings, Exception>> mobile_settings(
24992499
/// - allow_user_timezones
25002500
/// - custom_welcome_email
25012501
/// - data_connector_default_enabled
2502+
/// - dashboard_auto_refresh_restriction
2503+
/// - dashboard_auto_refresh_minimum_interval
25022504
/// - extension_framework_enabled
25032505
/// - extension_load_url_enabled
25042506
/// - instance_config
@@ -2535,6 +2537,8 @@ public async Task<SdkResponse<Setting, Exception>> get_setting(
25352537
/// - allow_user_timezones
25362538
/// - custom_welcome_email
25372539
/// - data_connector_default_enabled
2540+
/// - dashboard_auto_refresh_restriction
2541+
/// - dashboard_auto_refresh_minimum_interval
25382542
/// - extension_framework_enabled
25392543
/// - extension_load_url_enabled
25402544
/// - instance_config
@@ -2880,6 +2884,24 @@ public async Task<SdkResponse<ExternalOauthApplication, Exception>> create_exter
28802884
return await AuthRequest<ExternalOauthApplication, Exception>(HttpMethod.Post, "/external_oauth_applications", null,body,options);
28812885
}
28822886

2887+
/// ### Update an OAuth Application's client secret.
2888+
///
2889+
/// This is an OAuth Application which Looker uses to access external systems.
2890+
///
2891+
/// PATCH /external_oauth_applications/{client_id} -> ExternalOauthApplication
2892+
///
2893+
/// <returns><c>ExternalOauthApplication</c> External OAuth Application (application/json)</returns>
2894+
///
2895+
/// <param name="client_id">The client ID of the OAuth App to update</param>
2896+
public async Task<SdkResponse<ExternalOauthApplication, Exception>> update_external_oauth_application(
2897+
string client_id,
2898+
WriteExternalOauthApplication body,
2899+
ITransportSettings? options = null)
2900+
{
2901+
client_id = SdkUtils.EncodeParam(client_id);
2902+
return await AuthRequest<ExternalOauthApplication, Exception>(HttpMethod.Patch, $"/external_oauth_applications/{client_id}", null,body,options);
2903+
}
2904+
28832905
/// ### Create OAuth User state.
28842906
///
28852907
/// POST /external_oauth_applications/user_state -> CreateOAuthApplicationUserStateResponse

csharp/sdk/4.0/models.cs

Lines changed: 48 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -994,6 +994,10 @@ public class CredentialsEmail : SdkModel
994994
public string? password_reset_url { get; set; } = null;
995995
/// <summary>Url with one-time use secret token that the user can use to setup account (read-only)</summary>
996996
public string? account_setup_url { get; set; } = null;
997+
/// <summary>Is password_reset_url expired or not present? (read-only)</summary>
998+
public bool? password_reset_url_expired { get; set; } = null;
999+
/// <summary>Is account_setup_url expired or not present? (read-only)</summary>
1000+
public bool? account_setup_url_expired { get; set; } = null;
9971001
/// <summary>Short name for the type of this kind of credential (read-only)</summary>
9981002
public string? type { get; set; } = null;
9991003
/// <summary>Link to get this item (read-only)</summary>
@@ -1022,6 +1026,10 @@ public class CredentialsEmailSearch : SdkModel
10221026
public string? password_reset_url { get; set; } = null;
10231027
/// <summary>Url with one-time use secret token that the user can use to setup account (read-only)</summary>
10241028
public string? account_setup_url { get; set; } = null;
1029+
/// <summary>Is password_reset_url expired or not present? (read-only)</summary>
1030+
public bool? password_reset_url_expired { get; set; } = null;
1031+
/// <summary>Is account_setup_url expired or not present? (read-only)</summary>
1032+
public bool? account_setup_url_expired { get; set; } = null;
10251033
/// <summary>Short name for the type of this kind of credential (read-only)</summary>
10261034
public string? type { get; set; } = null;
10271035
/// <summary>Link to get this item (read-only)</summary>
@@ -1616,6 +1624,8 @@ public class DBConnection : SdkModel
16161624
public string? password { get; set; } = null;
16171625
/// <summary>Whether the connection uses OAuth for authentication. (read-only)</summary>
16181626
public bool? uses_oauth { get; set; } = null;
1627+
/// <summary>Whether the integration uses the oauth instance account. (read-only)</summary>
1628+
public bool? uses_instance_oauth { get; set; } = null;
16191629
/// <summary>(Write-Only) Base64 encoded Certificate body for server authentication (when appropriate for dialect).</summary>
16201630
public string? certificate { get; set; } = null;
16211631
/// <summary>(Write-Only) Certificate keyfile type - .json or .p12</summary>
@@ -1630,6 +1640,10 @@ public class DBConnection : SdkModel
16301640
public string? schema { get; set; } = null;
16311641
/// <summary>Maximum number of concurrent connection to use</summary>
16321642
public long? max_connections { get; set; } = null;
1643+
/// <summary>Maximum number of concurrent queries to begin on this connection</summary>
1644+
public long? max_queries { get; set; } = null;
1645+
/// <summary>Maximum number of concurrent queries per user to begin on this connection</summary>
1646+
public long? max_queries_per_user { get; set; } = null;
16331647
/// <summary>Maximum size of query in GBs (BigQuery only, can be a user_attribute name)</summary>
16341648
public string? max_billing_gigabytes { get; set; } = null;
16351649
/// <summary>Use SSL/TLS when connecting to server</summary>
@@ -1685,12 +1699,22 @@ public class DBConnection : SdkModel
16851699
public string? oauth_application_id { get; set; } = null;
16861700
/// <summary>When true, error PDTs will be retried every regenerator cycle</summary>
16871701
public bool? always_retry_failed_builds { get; set; } = null;
1702+
/// <summary>Whether the connection should authenticate with the Application Default Credentials of the host environment (limited to GCP and certain dialects).</summary>
1703+
public bool? uses_application_default_credentials { get; set; } = null;
1704+
/// <summary>An alternative Service Account to use for querying datasets (used primarily with `uses_application_default_credentials`) (limited to GCP and certain dialects).</summary>
1705+
public string? impersonated_service_account { get; set; } = null;
16881706
/// <summary>When true, query cost estimate will be displayed in explore.</summary>
16891707
public bool? cost_estimate_enabled { get; set; } = null;
16901708
/// <summary>PDT builds on this connection can be kicked off and cancelled via API.</summary>
16911709
public bool? pdt_api_control_enabled { get; set; } = null;
16921710
/// <summary>Enable database connection pooling.</summary>
16931711
public bool? connection_pooling { get; set; } = null;
1712+
/// <summary>When true, represents that this connection is the default BQ connection. (read-only)</summary>
1713+
public bool? default_bq_connection { get; set; } = null;
1714+
/// <summary>The project id of the default BigQuery storage project.</summary>
1715+
public string? bq_storage_project_id { get; set; } = null;
1716+
/// <summary>When true, represents that all project roles have been verified. (read-only)</summary>
1717+
public bool? bq_roles_verified { get; set; } = null;
16941718
}
16951719

16961720
public class DBConnectionBase : SdkModel
@@ -4547,6 +4571,8 @@ public class RunningQueries : SdkModel
45474571
public double? runtime { get; set; } = null;
45484572
/// <summary>SQL text of the query as run (read-only)</summary>
45494573
public string? sql { get; set; } = null;
4574+
/// <summary>SQL text of the SQL Interface query as run (read-only)</summary>
4575+
public string? sql_interface_sql { get; set; } = null;
45504576
}
45514577

45524578
public class SamlConfig : SdkModel
@@ -4962,6 +4988,10 @@ public class Setting : SdkModel
49624988
public bool? login_notification_enabled { get; set; } = null;
49634989
/// <summary>Login notification text (read-only)</summary>
49644990
public string? login_notification_text { get; set; } = null;
4991+
/// <summary>Toggle Dashboard Auto Refresh restriction</summary>
4992+
public bool? dashboard_auto_refresh_restriction { get; set; } = null;
4993+
/// <summary>Minimum time interval for dashboard element automatic refresh. Examples: (30 seconds, 1 minute)</summary>
4994+
public string? dashboard_auto_refresh_minimum_interval { get; set; } = null;
49654995
}
49664996

49674997
public class SmtpNodeStatus : SdkModel
@@ -5443,7 +5473,7 @@ public class User : SdkModel
54435473
public bool? models_dir_validated { get; set; } = null;
54445474
/// <summary>ID of user's personal folder (read-only)</summary>
54455475
public string? personal_folder_id { get; set; } = null;
5446-
/// <summary>User is identified as an employee of Looker (read-only)</summary>
5476+
/// <summary>(DEPRECATED) User is identified as an employee of Looker (read-only)</summary>
54475477
public bool? presumed_looker_employee { get; set; } = null;
54485478
/// <summary>Array of ids of the roles for this user (read-only)</summary>
54495479
public string[]? role_ids { get; set; } = null;
@@ -5940,7 +5970,7 @@ public class WriteCreateQueryTask : SdkModel
59405970
}
59415971

59425972
/// Dynamic writeable type for CredentialsEmail removes:
5943-
/// can, created_at, user_id, is_disabled, logged_in_at, password_reset_url, account_setup_url, type, url, user_url
5973+
/// can, created_at, user_id, is_disabled, logged_in_at, password_reset_url, account_setup_url, password_reset_url_expired, account_setup_url_expired, type, url, user_url
59445974
public class WriteCredentialsEmail : SdkModel
59455975
{
59465976
/// <summary>EMail address used for user login</summary>
@@ -6158,7 +6188,7 @@ public class WriteDatagroup : SdkModel
61586188
}
61596189

61606190
/// Dynamic writeable type for DBConnection removes:
6161-
/// can, dialect, snippets, pdts_enabled, uses_oauth, supports_data_studio_link, created_at, user_id, example, last_regen_at, last_reap_at, managed
6191+
/// can, dialect, snippets, pdts_enabled, uses_oauth, uses_instance_oauth, supports_data_studio_link, created_at, user_id, example, last_regen_at, last_reap_at, managed, default_bq_connection, bq_roles_verified
61626192
public class WriteDBConnection : SdkModel
61636193
{
61646194
/// <summary>Name of the connection. Also used as the unique identifier</summary>
@@ -6185,6 +6215,10 @@ public class WriteDBConnection : SdkModel
61856215
public string? schema { get; set; } = null;
61866216
/// <summary>Maximum number of concurrent connection to use</summary>
61876217
public long? max_connections { get; set; } = null;
6218+
/// <summary>Maximum number of concurrent queries to begin on this connection</summary>
6219+
public long? max_queries { get; set; } = null;
6220+
/// <summary>Maximum number of concurrent queries per user to begin on this connection</summary>
6221+
public long? max_queries_per_user { get; set; } = null;
61886222
/// <summary>Maximum size of query in GBs (BigQuery only, can be a user_attribute name)</summary>
61896223
public string? max_billing_gigabytes { get; set; } = null;
61906224
/// <summary>Use SSL/TLS when connecting to server</summary>
@@ -6230,12 +6264,18 @@ public class WriteDBConnection : SdkModel
62306264
public string? oauth_application_id { get; set; } = null;
62316265
/// <summary>When true, error PDTs will be retried every regenerator cycle</summary>
62326266
public bool? always_retry_failed_builds { get; set; } = null;
6267+
/// <summary>Whether the connection should authenticate with the Application Default Credentials of the host environment (limited to GCP and certain dialects).</summary>
6268+
public bool? uses_application_default_credentials { get; set; } = null;
6269+
/// <summary>An alternative Service Account to use for querying datasets (used primarily with `uses_application_default_credentials`) (limited to GCP and certain dialects).</summary>
6270+
public string? impersonated_service_account { get; set; } = null;
62336271
/// <summary>When true, query cost estimate will be displayed in explore.</summary>
62346272
public bool? cost_estimate_enabled { get; set; } = null;
62356273
/// <summary>PDT builds on this connection can be kicked off and cancelled via API.</summary>
62366274
public bool? pdt_api_control_enabled { get; set; } = null;
62376275
/// <summary>Enable database connection pooling.</summary>
62386276
public bool? connection_pooling { get; set; } = null;
6277+
/// <summary>The project id of the default BigQuery storage project.</summary>
6278+
public string? bq_storage_project_id { get; set; } = null;
62396279
}
62406280

62416281
/// Dynamic writeable type for DBConnectionOverride removes:
@@ -6972,6 +7012,10 @@ public class WriteSetting : SdkModel
69727012
/// <summary>(DEPRECATED) Use embed_config.embed_cookieless_v2 instead. If embed_config.embed_cookieless_v2 is specified, it overrides this value.</summary>
69737013
public bool? embed_cookieless_v2 { get; set; } = null;
69747014
public EmbedConfig? embed_config { get; set; }
7015+
/// <summary>Toggle Dashboard Auto Refresh restriction</summary>
7016+
public bool? dashboard_auto_refresh_restriction { get; set; } = null;
7017+
/// <summary>Minimum time interval for dashboard element automatic refresh. Examples: (30 seconds, 1 minute)</summary>
7018+
public string? dashboard_auto_refresh_minimum_interval { get; set; } = null;
69757019
}
69767020

69777021
/// Dynamic writeable type for SqlInterfaceQueryCreate removes:
@@ -7031,7 +7075,7 @@ public class WriteUser : SdkModel
70317075
{
70327076
/// <summary>
70337077
/// Dynamic writeable type for CredentialsEmail removes:
7034-
/// can, created_at, user_id, is_disabled, logged_in_at, password_reset_url, account_setup_url, type, url, user_url
7078+
/// can, created_at, user_id, is_disabled, logged_in_at, password_reset_url, account_setup_url, password_reset_url_expired, account_setup_url_expired, type, url, user_url
70357079
/// </summary>
70367080
public WriteCredentialsEmail? credentials_email { get; set; }
70377081
/// <summary>First name</summary>

go/sdk/v4/methods.go

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ SOFTWARE.
2626

2727
/*
2828
29-
464 API methods
29+
465 API methods
3030
*/
3131

3232
// NOTE: Do not edit this file generated by Looker SDK Codegen for API v4
@@ -40,11 +40,15 @@ import (
4040
"time"
4141
)
4242

43+
type authSessionDoer interface {
44+
Do(result interface{}, method, ver, path string, reqPars map[string]interface{}, body interface{}, options *rtl.ApiSettings) error
45+
}
46+
4347
type LookerSDK struct {
44-
session *rtl.AuthSession
48+
session authSessionDoer
4549
}
4650

47-
func NewLookerSDK(session *rtl.AuthSession) *LookerSDK {
51+
func NewLookerSDK(session authSessionDoer) *LookerSDK {
4852
return &LookerSDK{
4953
session: session,
5054
}
@@ -2108,6 +2112,8 @@ func (l *LookerSDK) MobileSettings(
21082112
// - allow_user_timezones
21092113
// - custom_welcome_email
21102114
// - data_connector_default_enabled
2115+
// - dashboard_auto_refresh_restriction
2116+
// - dashboard_auto_refresh_minimum_interval
21112117
// - extension_framework_enabled
21122118
// - extension_load_url_enabled
21132119
// - instance_config
@@ -2141,6 +2147,8 @@ func (l *LookerSDK) GetSetting(
21412147
// - allow_user_timezones
21422148
// - custom_welcome_email
21432149
// - data_connector_default_enabled
2150+
// - dashboard_auto_refresh_restriction
2151+
// - dashboard_auto_refresh_minimum_interval
21442152
// - extension_framework_enabled
21452153
// - extension_load_url_enabled
21462154
// - instance_config
@@ -2437,6 +2445,22 @@ func (l *LookerSDK) CreateExternalOauthApplication(
24372445

24382446
}
24392447

2448+
// ### Update an OAuth Application's client secret.
2449+
//
2450+
// This is an OAuth Application which Looker uses to access external systems.
2451+
//
2452+
// PATCH /external_oauth_applications/{client_id} -> ExternalOauthApplication
2453+
func (l *LookerSDK) UpdateExternalOauthApplication(
2454+
clientId string,
2455+
body WriteExternalOauthApplication,
2456+
options *rtl.ApiSettings) (ExternalOauthApplication, error) {
2457+
clientId = url.PathEscape(clientId)
2458+
var result ExternalOauthApplication
2459+
err := l.session.Do(&result, "PATCH", "/4.0", fmt.Sprintf("/external_oauth_applications/%v", clientId), nil, body, options)
2460+
return result, err
2461+
2462+
}
2463+
24402464
// ### Create OAuth User state.
24412465
//
24422466
// POST /external_oauth_applications/user_state -> CreateOAuthApplicationUserStateResponse

0 commit comments

Comments
 (0)