Skip to content

Commit

Permalink
feat: generate SDKs for Looker 23.4 (#1290)
Browse files Browse the repository at this point in the history
Release-As: 23.4.0
  • Loading branch information
jeremytchang authored Mar 31, 2023
1 parent 44974ec commit d7cd650
Show file tree
Hide file tree
Showing 35 changed files with 317 additions and 1,131 deletions.
2 changes: 1 addition & 1 deletion csharp/rtl/Constants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public struct Constants

public const string DefaultApiVersion = "4.0";
public const string AgentPrefix = "CS-SDK";
public const string LookerVersion = "23.2";
public const string LookerVersion = "23.4";

public const string Bearer = "Bearer";
public const string LookerAppiId = "x-looker-appid";
Expand Down
2 changes: 1 addition & 1 deletion csharp/sdk/3.1/methods.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// MIT License
///
/// Copyright (c) 2021 Looker Data Sciences, Inc.
/// 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
Expand Down
2 changes: 1 addition & 1 deletion csharp/sdk/3.1/models.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// MIT License
///
/// Copyright (c) 2021 Looker Data Sciences, Inc.
/// 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
Expand Down
50 changes: 19 additions & 31 deletions csharp/sdk/4.0/methods.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// MIT License
///
/// Copyright (c) 2021 Looker Data Sciences, Inc.
/// 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
Expand All @@ -21,7 +21,7 @@
/// SOFTWARE.
///

/// 460 API methods
/// 459 API methods

#nullable enable
using System;
Expand Down Expand Up @@ -725,16 +725,20 @@ public async Task<SdkResponse<EmbedUrlResponse, Exception>> create_embed_url_as_
/// ### 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 it if it does not exist,
/// otherwise it reuses it. Note that this endpoint will not update the user, user attributes or group
/// attributes if the embed user already exists. This is the same behavior as the embed SSO login.
/// 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 will NOT be extended in this scenario, in other words the session_length parameter is ignored.
/// the session is NOT extended in this scenario. In other words the session_length parameter is ignored.
///
/// If the session_reference_token has expired, it will be ignored and a new embed session will be created.
/// **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 exisiting session_reference_token, a
/// 404 will be returned.
Expand Down Expand Up @@ -2167,20 +2171,6 @@ public async Task<SdkResponse<BackupConfiguration, Exception>> update_cloud_stor
return await AuthRequest<BackupConfiguration, Exception>(HttpMethod.Patch, "/cloud_storage", null,body,options);
}

/// ### Looker Configuration Refresh
///
/// This is an endpoint for manually calling refresh on Configuration manager.
///
/// PUT /configuration_force_refresh -> object
///
/// <returns><c>object</c> Refresh Looker Configuration (application/json)</returns>
///
public async Task<SdkResponse<object, Exception>> configuration_force_refresh(
ITransportSettings? options = null)
{
return await AuthRequest<object, Exception>(HttpMethod.Put, "/configuration_force_refresh", null,null,options);
}

/// ### Get the current status and content of custom welcome emails
///
/// GET /custom_welcome_email -> CustomWelcomeEmail
Expand Down Expand Up @@ -2409,7 +2399,6 @@ public async Task<SdkResponse<MobileSettings, Exception>> mobile_settings(
/// - timezone
/// - host_url
/// - email_domain_allowlist
/// - sisu
///
/// GET /setting -> Setting
///
Expand Down Expand Up @@ -2439,7 +2428,6 @@ public async Task<SdkResponse<Setting, Exception>> get_setting(
/// - timezone
/// - host_url
/// - email_domain_allowlist
/// - sisu
///
/// See the `Setting` type for more information on the specific values that can be configured.
///
Expand Down Expand Up @@ -3747,28 +3735,28 @@ public async Task<SdkResponse<Dashboard, Exception>> move_dashboard(
/// Note that the created dashboard is not linked to any LookML Dashboard,
/// i.e. [sync_lookml_dashboard()](#!/Dashboard/sync_lookml_dashboard) will not update dashboards created by this method.
///
/// POST /dashboards/lookml -> DashboardLookml
/// POST /dashboards/lookml -> Dashboard
///
/// <returns><c>DashboardLookml</c> DashboardLookML (application/json)</returns>
/// <returns><c>Dashboard</c> dashboard (application/json)</returns>
///
public async Task<SdkResponse<DashboardLookml, Exception>> import_dashboard_from_lookml(
public async Task<SdkResponse<Dashboard, Exception>> import_dashboard_from_lookml(
WriteDashboardLookml body,
ITransportSettings? options = null)
{
return await AuthRequest<DashboardLookml, Exception>(HttpMethod.Post, "/dashboards/lookml", null,body,options);
return await AuthRequest<Dashboard, Exception>(HttpMethod.Post, "/dashboards/lookml", null,body,options);
}

/// # DEPRECATED: Use [import_dashboard_from_lookml()](#!/Dashboard/import_dashboard_from_lookml)
///
/// POST /dashboards/from_lookml -> DashboardLookml
/// POST /dashboards/from_lookml -> Dashboard
///
/// <returns><c>DashboardLookml</c> DashboardLookML (application/json)</returns>
/// <returns><c>Dashboard</c> dashboard (application/json)</returns>
///
public async Task<SdkResponse<DashboardLookml, Exception>> create_dashboard_from_lookml(
public async Task<SdkResponse<Dashboard, Exception>> create_dashboard_from_lookml(
WriteDashboardLookml body,
ITransportSettings? options = null)
{
return await AuthRequest<DashboardLookml, Exception>(HttpMethod.Post, "/dashboards/from_lookml", null,body,options);
return await AuthRequest<Dashboard, Exception>(HttpMethod.Post, "/dashboards/from_lookml", null,body,options);
}

/// ### Copy an existing dashboard
Expand Down
50 changes: 2 additions & 48 deletions csharp/sdk/4.0/models.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// MIT License
///
/// Copyright (c) 2021 Looker Data Sciences, Inc.
/// 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
Expand All @@ -21,7 +21,7 @@
/// SOFTWARE.
///

/// 328 API models: 245 Spec, 0 Request, 61 Write, 22 Enum
/// 326 API models: 244 Spec, 0 Request, 60 Write, 22 Enum

#nullable enable
using System;
Expand Down Expand Up @@ -4745,27 +4745,6 @@ public class Setting : SdkModel
public bool? override_warnings { get; set; } = null;
/// <summary>An array of Email Domain Allowlist of type string for Scheduled Content</summary>
public string[]? email_domain_allowlist { get; set; } = null;
public SisuSetting? sisu { get; set; }
}

public class SisuSetting : SdkModel
{
/// <summary>Operations the current user is able to perform on this object (read-only)</summary>
public StringDictionary<bool>? can { get; set; } = null;
/// <summary>Whether the Sisu integration is enabled</summary>
public bool? enabled { get; set; } = null;
/// <summary>The extension ID of the installed Sisu extension</summary>
public string? extension_id { get; set; } = null;
/// <summary>Whether the Looker instance has been configured with Sisu</summary>
public bool? configured { get; set; } = null;
/// <summary>The API key ID generated for use with Sisu</summary>
public string? api_key_id { get; set; } = null;
/// <summary>The user ID associated with the API key generated for use with Sisu</summary>
public string? api_user_id { get; set; } = null;
/// <summary>The marketplace installation id of the Sisu extension</summary>
public string? installation_id { get; set; } = null;
/// <summary>An alternate marketplace listing id to use for the Sisu extension.</summary>
public string? listing_id_override { get; set; } = null;
}

public class SmtpNodeStatus : SdkModel
Expand Down Expand Up @@ -6693,31 +6672,6 @@ public class WriteSetting : SdkModel
public bool? override_warnings { get; set; } = null;
/// <summary>An array of Email Domain Allowlist of type string for Scheduled Content</summary>
public string[]? email_domain_allowlist { get; set; } = null;
/// <summary>
/// Dynamic writeable type for SisuSetting removes:
/// can
/// </summary>
public WriteSisuSetting? sisu { get; set; }
}

/// Dynamic writeable type for SisuSetting removes:
/// can
public class WriteSisuSetting : SdkModel
{
/// <summary>Whether the Sisu integration is enabled</summary>
public bool? enabled { get; set; } = null;
/// <summary>The extension ID of the installed Sisu extension</summary>
public string? extension_id { get; set; } = null;
/// <summary>Whether the Looker instance has been configured with Sisu</summary>
public bool? configured { get; set; } = null;
/// <summary>The API key ID generated for use with Sisu</summary>
public string? api_key_id { get; set; } = null;
/// <summary>The user ID associated with the API key generated for use with Sisu</summary>
public string? api_user_id { get; set; } = null;
/// <summary>The marketplace installation id of the Sisu extension</summary>
public string? installation_id { get; set; } = null;
/// <summary>An alternate marketplace listing id to use for the Sisu extension.</summary>
public string? listing_id_override { get; set; } = null;
}

/// Dynamic writeable type for SshServer removes:
Expand Down
45 changes: 17 additions & 28 deletions go/sdk/v4/methods.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
MIT License
Copyright (c) 2021 Looker Data Sciences, Inc.
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
Expand All @@ -26,7 +26,7 @@ SOFTWARE.

/*
460 API methods
459 API methods
*/

// NOTE: Do not edit this file generated by Looker SDK Codegen for API v4
Expand Down Expand Up @@ -596,16 +596,20 @@ func (l *LookerSDK) CreateEmbedUrlAsMe(
// ### 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 it if it does not exist,
// otherwise it reuses it. Note that this endpoint will not update the user, user attributes or group
// attributes if the embed user already exists. This is the same behavior as the embed SSO login.
// 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 will NOT be extended in this scenario, in other words the session_length parameter is ignored.
// the session is NOT extended in this scenario. In other words the session_length parameter is ignored.
//
// If the session_reference_token has expired, it will be ignored and a new embed session will be created.
// **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 exisiting session_reference_token, a
// 404 will be returned.
Expand Down Expand Up @@ -1799,19 +1803,6 @@ func (l *LookerSDK) UpdateCloudStorageConfiguration(

}

// ### Looker Configuration Refresh
//
// This is an endpoint for manually calling refresh on Configuration manager.
//
// PUT /configuration_force_refresh -> interface{}
func (l *LookerSDK) ConfigurationForceRefresh(
options *rtl.ApiSettings) (interface{}, error) {
var result interface{}
err := l.session.Do(&result, "PUT", "/4.0", "/configuration_force_refresh", nil, nil, options)
return result, err

}

// ### Get the current status and content of custom welcome emails
//
// GET /custom_welcome_email -> CustomWelcomeEmail
Expand Down Expand Up @@ -2022,7 +2013,6 @@ func (l *LookerSDK) MobileSettings(
// - timezone
// - host_url
// - email_domain_allowlist
// - sisu
//
// GET /setting -> Setting
func (l *LookerSDK) GetSetting(
Expand All @@ -2049,7 +2039,6 @@ func (l *LookerSDK) GetSetting(
// - timezone
// - host_url
// - email_domain_allowlist
// - sisu
//
// See the `Setting` type for more information on the specific values that can be configured.
//
Expand Down Expand Up @@ -3042,23 +3031,23 @@ func (l *LookerSDK) MoveDashboard(
// Note that the created dashboard is not linked to any LookML Dashboard,
// i.e. [sync_lookml_dashboard()](#!/Dashboard/sync_lookml_dashboard) will not update dashboards created by this method.
//
// POST /dashboards/lookml -> DashboardLookml
// POST /dashboards/lookml -> Dashboard
func (l *LookerSDK) ImportDashboardFromLookml(
body WriteDashboardLookml,
options *rtl.ApiSettings) (DashboardLookml, error) {
var result DashboardLookml
options *rtl.ApiSettings) (Dashboard, error) {
var result Dashboard
err := l.session.Do(&result, "POST", "/4.0", "/dashboards/lookml", nil, body, options)
return result, err

}

// # DEPRECATED: Use [import_dashboard_from_lookml()](#!/Dashboard/import_dashboard_from_lookml)
//
// POST /dashboards/from_lookml -> DashboardLookml
// POST /dashboards/from_lookml -> Dashboard
func (l *LookerSDK) CreateDashboardFromLookml(
body WriteDashboardLookml,
options *rtl.ApiSettings) (DashboardLookml, error) {
var result DashboardLookml
options *rtl.ApiSettings) (Dashboard, error) {
var result Dashboard
err := l.session.Do(&result, "POST", "/4.0", "/dashboards/from_lookml", nil, body, options)
return result, err

Expand Down
30 changes: 2 additions & 28 deletions go/sdk/v4/models.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
MIT License
Copyright (c) 2021 Looker Data Sciences, Inc.
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
Expand All @@ -26,7 +26,7 @@ SOFTWARE.

/*
393 API models: 245 Spec, 66 Request, 60 Write, 22 Enum
391 API models: 244 Spec, 66 Request, 59 Write, 22 Enum
*/

// NOTE: Do not edit this file generated by Looker SDK Codegen for API v4
Expand Down Expand Up @@ -3366,18 +3366,6 @@ type Setting struct {
HostUrl *string `json:"host_url,omitempty"` // Change the base portion of your Looker instance URL setting
OverrideWarnings *bool `json:"override_warnings,omitempty"` // (Write-Only) If warnings are preventing a host URL change, this parameter allows for overriding warnings to force update the setting. Does not directly change any Looker settings.
EmailDomainAllowlist *[]string `json:"email_domain_allowlist,omitempty"` // An array of Email Domain Allowlist of type string for Scheduled Content
Sisu *SisuSetting `json:"sisu,omitempty"`
}

type SisuSetting struct {
Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object
Enabled *bool `json:"enabled,omitempty"` // Whether the Sisu integration is enabled
ExtensionId *string `json:"extension_id,omitempty"` // The extension ID of the installed Sisu extension
Configured *bool `json:"configured,omitempty"` // Whether the Looker instance has been configured with Sisu
ApiKeyId *string `json:"api_key_id,omitempty"` // The API key ID generated for use with Sisu
ApiUserId *string `json:"api_user_id,omitempty"` // The user ID associated with the API key generated for use with Sisu
InstallationId *string `json:"installation_id,omitempty"` // The marketplace installation id of the Sisu extension
ListingIdOverride *string `json:"listing_id_override,omitempty"` // An alternate marketplace listing id to use for the Sisu extension.
}

type SmtpNodeStatus struct {
Expand Down Expand Up @@ -4479,20 +4467,6 @@ type WriteSetting struct {
HostUrl *string `json:"host_url,omitempty"` // Change the base portion of your Looker instance URL setting
OverrideWarnings *bool `json:"override_warnings,omitempty"` // (Write-Only) If warnings are preventing a host URL change, this parameter allows for overriding warnings to force update the setting. Does not directly change any Looker settings.
EmailDomainAllowlist *[]string `json:"email_domain_allowlist,omitempty"` // An array of Email Domain Allowlist of type string for Scheduled Content
Sisu *WriteSisuSetting `json:"sisu,omitempty"` // Dynamic writeable type for SisuSetting removes:
// can
}

// Dynamic writeable type for SisuSetting removes:
// can
type WriteSisuSetting struct {
Enabled *bool `json:"enabled,omitempty"` // Whether the Sisu integration is enabled
ExtensionId *string `json:"extension_id,omitempty"` // The extension ID of the installed Sisu extension
Configured *bool `json:"configured,omitempty"` // Whether the Looker instance has been configured with Sisu
ApiKeyId *string `json:"api_key_id,omitempty"` // The API key ID generated for use with Sisu
ApiUserId *string `json:"api_user_id,omitempty"` // The user ID associated with the API key generated for use with Sisu
InstallationId *string `json:"installation_id,omitempty"` // The marketplace installation id of the Sisu extension
ListingIdOverride *string `json:"listing_id_override,omitempty"` // An alternate marketplace listing id to use for the Sisu extension.
}

// Dynamic writeable type for SshServer removes:
Expand Down
Loading

0 comments on commit d7cd650

Please sign in to comment.