From df854c39eb6277b72362a62d01b7cb503f23fdb0 Mon Sep 17 00:00:00 2001 From: Joel Dodge Date: Fri, 2 Jul 2021 16:29:49 +0000 Subject: [PATCH 1/8] chore: rp config for next release (#733) --- release-please-config.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/release-please-config.json b/release-please-config.json index b3f5813fb..c3d70de3a 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -12,11 +12,11 @@ "packages/hackathon": { }, "packages/run-it": { "release-as": "" }, "packages/sdk": { }, - "packages/sdk-codegen": { "release-as": "21.0.19" }, - "packages/sdk-codegen-scripts": { "release-as": "21.0.20", "changelog-sections": [{"type": "chore", "section": "Bug Fixes"}] }, - "packages/sdk-codegen-utils": { "release-as": "21.0.12"}, + "packages/sdk-codegen": { "release-as": "21.0.20" }, + "packages/sdk-codegen-scripts": { "release-as": "21.0.21" }, + "packages/sdk-codegen-utils": { "release-as": "21.0.13"}, "packages/sdk-node": { }, - "packages/sdk-rtl": { "release-as": "21.0.15" }, + "packages/sdk-rtl": { "release-as": "21.0.16" }, "packages/wholly-sheet": { "release-as": "" }, "python": { "release-type": "python", "package-name": "looker_sdk" } } From c821f2b77b99edfa2dd53aa0af82ab48081c3220 Mon Sep 17 00:00:00 2001 From: Joel Dodge Date: Fri, 2 Jul 2021 22:17:40 +0000 Subject: [PATCH 2/8] fix: python datetime [de]serialization bug (#734) --- python/looker_sdk/rtl/serialize.py | 4 +++- python/tests/rtl/test_serialize.py | 33 ++++++++++++++++++++++-------- 2 files changed, 28 insertions(+), 9 deletions(-) diff --git a/python/looker_sdk/rtl/serialize.py b/python/looker_sdk/rtl/serialize.py index b42f1e445..ff6b7505e 100644 --- a/python/looker_sdk/rtl/serialize.py +++ b/python/looker_sdk/rtl/serialize.py @@ -144,6 +144,7 @@ def unstructure_hook(api_model): return data +DATETIME_FMT = "%Y-%m-%dT%H:%M:%S.%f%z" if sys.version_info < (3, 7): from dateutil import parser @@ -158,9 +159,10 @@ def datetime_structure_hook( def datetime_structure_hook( d: str, t: Type[datetime.datetime] ) -> datetime.datetime: - return datetime.datetime.strptime(d, "%Y-%m-%dT%H:%M:%S.%f%z") + return datetime.datetime.strptime(d, DATETIME_FMT) converter31.register_structure_hook(datetime.datetime, datetime_structure_hook) converter40.register_structure_hook(datetime.datetime, datetime_structure_hook) cattr.register_unstructure_hook(model.Model, unstructure_hook) # type: ignore +cattr.register_unstructure_hook(datetime.datetime, lambda dt: dt.strftime(DATETIME_FMT)) diff --git a/python/tests/rtl/test_serialize.py b/python/tests/rtl/test_serialize.py index 30404a939..deb730cae 100644 --- a/python/tests/rtl/test_serialize.py +++ b/python/tests/rtl/test_serialize.py @@ -21,6 +21,7 @@ # THE SOFTWARE. import copy +import datetime import enum import functools import json @@ -42,8 +43,7 @@ class Enum1(enum.Enum): - """Predifined enum, used as ForwardRef. - """ + """Predifined enum, used as ForwardRef.""" entry1 = "entry1" entry2 = "entry2" @@ -99,6 +99,7 @@ class Model(ml.Model): # standard types id: Optional[int] = None name: Optional[str] = None + datetime_field: Optional[datetime.datetime] = None # testing reserved keyword translations class_: Optional[str] = None @@ -133,6 +134,7 @@ class Model(ml.Model): "opt_model_no_refs1": Optional["ModelNoRefs1"], "id": Optional[int], "name": Optional[str], + "datetime_field": Optional[datetime.datetime], "class_": Optional[str], "finally_": Optional[Sequence[int]], } @@ -154,6 +156,7 @@ def __init__( opt_model_no_refs1: Optional["ModelNoRefs1"] = None, id: Optional[int] = None, name: Optional[str] = None, + datetime_field: Optional[datetime.datetime] = None, class_: Optional[str] = None, finally_: Optional[Sequence[int]] = None, ): @@ -175,13 +178,13 @@ def __init__( self.opt_model_no_refs1 = opt_model_no_refs1 self.id = id self.name = name + self.datetime_field = datetime_field self.class_ = class_ self.finally_ = finally_ class Enum2(enum.Enum): - """Post defined enum, used as ForwardRef. - """ + """Post defined enum, used as ForwardRef.""" entry2 = "entry2" invalid_api_enum_value = "invalid_api_enum_value" @@ -218,8 +221,11 @@ def __init__(self, *, name2: str): converter.register_structure_hook(ForwardRef("ModelNoRefs1"), structure_hook) converter.register_structure_hook(ForwardRef("ModelNoRefs2"), structure_hook) converter.register_structure_hook(Model, translate_keys_structure_hook) +converter.register_structure_hook(datetime.datetime, sr.datetime_structure_hook) +DATETIME_VALUE = datetime.datetime.fromtimestamp(1625246159, datetime.timezone.utc) +DATETIME_VALUE_STR = DATETIME_VALUE.strftime("%Y-%m-%dT%H:%M:%S.%f%z") MODEL_DATA = { "enum1": "entry1", "model_no_refs1": {"name1": "model_no_refs1_name"}, @@ -231,6 +237,7 @@ def __init__(self, *, name2: str): "opt_model_no_refs1": {"name1": "model_no_refs1_name"}, "id": 1, "name": "my-name", + "datetime_field": DATETIME_VALUE_STR, "class": "model-name", "finally": [1, 2, 3], } @@ -249,6 +256,7 @@ def bm(): opt_model_no_refs1=None, id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -357,6 +365,7 @@ def test_dict_iter(bm): "opt_enum1", "id", "name", + "datetime_field", "class", "finally", ] @@ -383,6 +392,7 @@ def test_dict_keys(bm): "opt_enum1", "id", "name", + "datetime_field", "class", "finally", ] @@ -399,6 +409,7 @@ def test_dict_items(bm): ("opt_enum1", "entry1"), ("id", 1), ("name", "my-name"), + ("datetime_field", DATETIME_VALUE_STR), ("class", "model-name"), ("finally", [1, 2, 3]), ] @@ -415,6 +426,7 @@ def test_dict_values(bm): "entry1", 1, "my-name", + DATETIME_VALUE_STR, "model-name", [1, 2, 3], ] @@ -515,6 +527,7 @@ def test_deserialize_single() -> None: opt_model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -539,6 +552,7 @@ def test_deserialize_list(): opt_model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ), @@ -563,6 +577,7 @@ def test_deserialize_partial(): opt_model_no_refs1=None, id=None, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -588,6 +603,7 @@ def test_deserialize_with_null(): opt_model_no_refs1=None, id=None, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -620,6 +636,7 @@ def test_serialize_single(): opt_model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -639,6 +656,7 @@ def test_serialize_sequence(): opt_model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) @@ -647,8 +665,7 @@ def test_serialize_sequence(): def test_serialize_partial(): - """Do not send json null for model None field values. - """ + """Do not send json null for model None field values.""" model = Model( enum1=Enum1.entry1, model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), @@ -671,8 +688,7 @@ def test_serialize_partial(): def test_serialize_explict_null(): - """Send json null for model field EXPLICIT_NULL values. - """ + """Send json null for model field EXPLICIT_NULL values.""" # pass EXPLICIT_NULL into constructor model = Model( enum1=Enum1.entry1, @@ -719,6 +735,7 @@ def test_safe_enum_deserialization(): opt_model_no_refs1=ModelNoRefs1(name1="model_no_refs1_name"), id=1, name="my-name", + datetime_field=DATETIME_VALUE, class_="model-name", finally_=[1, 2, 3], ) From a93a9b1ded0acddeaf051e7a2fed5132c1cb5c0c Mon Sep 17 00:00:00 2001 From: John Kaster Date: Fri, 2 Jul 2021 16:54:19 -0700 Subject: [PATCH 3/8] fix: explain pager and pageAll sdk param better (#736) Minor code comment change to clarify the `sdk` parameter --- packages/sdk-rtl/src/paging.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/sdk-rtl/src/paging.ts b/packages/sdk-rtl/src/paging.ts index b0bbdcad9..c33161b49 100644 --- a/packages/sdk-rtl/src/paging.ts +++ b/packages/sdk-rtl/src/paging.ts @@ -173,7 +173,7 @@ export type PageObserver = ( /** * Create an API response pager for an endpoint that returns a Link header - * @param sdk implementation of IAPIMethods. Can be full SDK or functional auth session + * @param sdk implementation of IAPIMethods. Can be a full SDK or functional auth session. The active transport object is captured from this parameter, which is why it must be passed separately from the paging function. * @param pageFunc sdk call that includes a paging header * @param options transport options override to capture and use in paging requests * @@ -189,10 +189,12 @@ export async function pager( /** * Create an API response pager and iterate through all pages, calling a page event per page - * @param sdk implementation of IAPIMethods. Can be full SDK object or a functional auth session + * @param sdk implementation of IAPIMethods. Can be a full SDK or functional auth session. The active transport object is captured from this parameter, which is why it must be passed separately from the paging function. * @param pageFunc sdk call that includes a paging header * @param onPage observer of the latest page of results. Defaults to noop. * @param options transport options override to capture and use in paging requests + * + * @remarks `TSuccess` must be a collection type that supports `length` */ export async function pageAll( sdk: IAPIMethods, From 47ea87c494299376ce81da11935c728d76ee7b81 Mon Sep 17 00:00:00 2001 From: Joel Dodge Date: Wed, 7 Jul 2021 16:14:11 +0000 Subject: [PATCH 4/8] chore: shorten hack required checks sleep (#735) * chore: shorten hack required checks sleep all CI jobs seem to be finishing well within 5 minutes and failing jobs will generally finish sooner anyway * Update .github/workflows/required-checks-hack-ci.yml Co-authored-by: John Kaster Co-authored-by: John Kaster --- .github/workflows/required-checks-hack-ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/required-checks-hack-ci.yml b/.github/workflows/required-checks-hack-ci.yml index ad6e778a0..946974641 100644 --- a/.github/workflows/required-checks-hack-ci.yml +++ b/.github/workflows/required-checks-hack-ci.yml @@ -45,8 +45,8 @@ jobs: name: Codegen Tests runs-on: ubuntu-latest steps: - # using `sleep 900` as a naive solution to avoiding early approval: 99% of - # real CI jobs finish in under 15 minutes. Waiting 15 minutes here should + # using `sleep 480` as a naive solution to avoiding early approval: 99% of + # real CI jobs finish in under 8 minutes. Waiting 8 minutes here should # mostly avoid the scenario where these noop jobs meet all required checks # on a PR prior to a corresponding real CI job being able to report. # @@ -54,22 +54,22 @@ jobs: # might be to run a script with https://github.com/octokit/action.js/ # that uses either the REST or GraphQL API to figure out when all # outstanding workflows for this PR have finished and only then `exit 0` - - run: sleep 900 && exit 0 + - run: sleep 480 && exit 0 noop-typescript-results: name: Typescript Tests runs-on: ubuntu-latest steps: - - run: sleep 900 && exit 0 + - run: sleep 480 && exit 0 noop-python-results: name: Python Tests runs-on: ubuntu-latest steps: - - run: sleep 900 && exit 0 + - run: sleep 480 && exit 0 noop-apix-results: name: APIX Tests runs-on: ubuntu-latest steps: - - run: sleep 900 && exit 0 + - run: sleep 480 && exit 0 From d3129b6bcb702e232770d4b7b26324c03f9cac26 Mon Sep 17 00:00:00 2001 From: looker-open-source-automation-bot Date: Wed, 7 Jul 2021 10:13:12 -0700 Subject: [PATCH 5/8] chore: release main (#731) Co-authored-by: Joel Dodge --- .release-please-manifest.json | 30 ++++++++++---------- CHANGELOG.md | 9 ++++++ package.json | 2 +- packages/api-explorer/CHANGELOG.md | 16 +++++++++++ packages/api-explorer/package.json | 16 +++++------ packages/code-editor/CHANGELOG.md | 9 ++++++ packages/code-editor/package.json | 4 +-- packages/extension-api-explorer/CHANGELOG.md | 14 +++++++++ packages/extension-api-explorer/package.json | 14 ++++----- packages/extension-sdk-react/CHANGELOG.md | 11 +++++++ packages/extension-sdk-react/package.json | 8 +++--- packages/extension-sdk/CHANGELOG.md | 10 +++++++ packages/extension-sdk/package.json | 6 ++-- packages/hackathon/CHANGELOG.md | 13 +++++++++ packages/hackathon/package.json | 12 ++++---- packages/run-it/CHANGELOG.md | 12 ++++++++ packages/run-it/package.json | 10 +++---- packages/sdk-codegen-scripts/CHANGELOG.md | 14 ++++++++- packages/sdk-codegen-scripts/package.json | 10 +++---- packages/sdk-codegen/CHANGELOG.md | 16 ++++++++++- packages/sdk-codegen/package.json | 4 +-- packages/sdk-node/CHANGELOG.md | 10 +++++++ packages/sdk-node/package.json | 6 ++-- packages/sdk-rtl/CHANGELOG.md | 7 +++++ packages/sdk-rtl/package.json | 2 +- packages/sdk/CHANGELOG.md | 9 ++++++ packages/sdk/package.json | 4 +-- packages/wholly-sheet/CHANGELOG.md | 12 ++++++++ packages/wholly-sheet/package.json | 8 +++--- python/CHANGELOG.md | 8 ++++++ python/looker_sdk/version.py | 2 +- 31 files changed, 237 insertions(+), 71 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index ecd6473a7..245c73c1e 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,18 +1,18 @@ { - ".": "1.9.1", - "packages/api-explorer": "0.9.11", - "packages/code-editor": "0.1.4", - "packages/extension-api-explorer": "21.8.1", - "packages/extension-sdk": "21.8.2", - "packages/extension-sdk-react": "21.8.2", - "packages/hackathon": "21.8.1", - "packages/run-it": "0.9.11", - "packages/sdk": "21.8.2", - "packages/sdk-codegen": "21.0.19", - "packages/sdk-codegen-scripts": "21.0.20", + ".": "1.9.2", + "packages/api-explorer": "0.9.12", + "packages/code-editor": "0.1.5", + "packages/extension-api-explorer": "21.8.2", + "packages/extension-sdk": "21.8.3", + "packages/extension-sdk-react": "21.8.3", + "packages/hackathon": "21.8.2", + "packages/run-it": "0.9.12", + "packages/sdk": "21.8.3", + "packages/sdk-codegen": "21.0.20", + "packages/sdk-codegen-scripts": "21.0.21", "packages/sdk-codegen-utils": "21.0.11", - "packages/sdk-node": "21.8.1", - "packages/sdk-rtl": "21.0.15", - "packages/wholly-sheet": "0.5.10", - "python": "21.8.0" + "packages/sdk-node": "21.8.2", + "packages/sdk-rtl": "21.0.16", + "packages/wholly-sheet": "0.5.11", + "python": "21.8.1" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 2484f5934..3ce23b9e1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # Changelog +### [1.9.2](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-all-v1.9.1...sdk-codegen-all-v1.9.2) (2021-07-02) + + +### Bug Fixes + +* explain pager and pageAll sdk param better ([#736](https://www.github.com/looker-open-source/sdk-codegen/issues/736)) ([a93a9b1](https://www.github.com/looker-open-source/sdk-codegen/commit/a93a9b1ded0acddeaf051e7a2fed5132c1cb5c0c)) +* python datetime [de]serialization bug ([#734](https://www.github.com/looker-open-source/sdk-codegen/issues/734)) ([c821f2b](https://www.github.com/looker-open-source/sdk-codegen/commit/c821f2b77b99edfa2dd53aa0af82ab48081c3220)) +* python remove runtime asserts ([#703](https://www.github.com/looker-open-source/sdk-codegen/issues/703)) ([9b963c3](https://www.github.com/looker-open-source/sdk-codegen/commit/9b963c3367905f907e7867df1446f56e18284c3b)), closes [#695](https://www.github.com/looker-open-source/sdk-codegen/issues/695) + ### [1.9.1](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-all-v1.9.0...sdk-codegen-all-v1.9.1) (2021-07-01) diff --git a/package.json b/package.json index 5165d5cdf..0f6b80ae3 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "license": "MIT", "name": "sdk-codegen-all", - "version": "1.9.1", + "version": "1.9.2", "description": "All workspaces for SDK code generation", "author": "Looker", "private": true, diff --git a/packages/api-explorer/CHANGELOG.md b/packages/api-explorer/CHANGELOG.md index b5489a492..c0958f2e3 100644 --- a/packages/api-explorer/CHANGELOG.md +++ b/packages/api-explorer/CHANGELOG.md @@ -5,6 +5,22 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [0.9.12](https://www.github.com/looker-open-source/sdk-codegen/compare/api-explorer-v0.9.11...api-explorer-v0.9.12) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/code-editor bumped from ^0.1.4 to ^0.1.5 + * @looker/run-it bumped from ^0.9.11 to ^0.9.12 + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-codegen bumped from ^21.0.19 to ^21.0.20 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + * devDependencies + * @looker/sdk-codegen-scripts bumped from ^21.0.20 to ^21.0.21 + * @looker/sdk-node bumped from ^21.8.1 to ^21.8.2 + ### [0.9.11](https://www.github.com/looker-open-source/sdk-codegen/compare/api-explorer-v0.9.10...api-explorer-v0.9.11) (2021-07-01) diff --git a/packages/api-explorer/package.json b/packages/api-explorer/package.json index 37fa066de..c53fbb99b 100644 --- a/packages/api-explorer/package.json +++ b/packages/api-explorer/package.json @@ -1,6 +1,6 @@ { "name": "@looker/api-explorer", - "version": "0.9.11", + "version": "0.9.12", "description": "Looker API Explorer", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -31,8 +31,8 @@ }, "devDependencies": { "@looker/components-test-utils": "^1.3.1", - "@looker/sdk-codegen-scripts": "^21.0.20", - "@looker/sdk-node": "^21.8.1", + "@looker/sdk-codegen-scripts": "^21.0.21", + "@looker/sdk-node": "^21.8.2", "@styled-icons/styled-icon": "^10.6.3", "@testing-library/jest-dom": "^5.11.6", "@testing-library/react": "^11.2.2", @@ -57,14 +57,14 @@ "webpack-merge": "^5.7.3" }, "dependencies": { - "@looker/code-editor": "^0.1.4", + "@looker/code-editor": "^0.1.5", "@looker/components": "^1.4.1", "@looker/design-tokens": "^1.3.1", "@looker/icons": "^1.3.0", - "@looker/run-it": "^0.9.11", - "@looker/sdk": "^21.8.2", - "@looker/sdk-codegen": "^21.0.19", - "@looker/sdk-rtl": "^21.0.15", + "@looker/run-it": "^0.9.12", + "@looker/sdk": "^21.8.3", + "@looker/sdk-codegen": "^21.0.20", + "@looker/sdk-rtl": "^21.0.16", "@styled-icons/material": "^10.28.0", "@styled-icons/material-outlined": "^10.28.0", "@styled-icons/material-rounded": "^10.28.0", diff --git a/packages/code-editor/CHANGELOG.md b/packages/code-editor/CHANGELOG.md index a916c7066..c80ad8fc9 100644 --- a/packages/code-editor/CHANGELOG.md +++ b/packages/code-editor/CHANGELOG.md @@ -1,5 +1,14 @@ # Changelog +### [0.1.5](https://www.github.com/looker-open-source/sdk-codegen/compare/code-editor-v0.1.4...code-editor-v0.1.5) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * devDependencies + * @looker/sdk-codegen bumped from ^21.0.19 to ^21.0.20 + ### [0.1.4](https://www.github.com/looker-open-source/sdk-codegen/compare/code-editor-v0.1.3...code-editor-v0.1.4) (2021-07-01) diff --git a/packages/code-editor/package.json b/packages/code-editor/package.json index 5e1a99da7..2f412486a 100644 --- a/packages/code-editor/package.json +++ b/packages/code-editor/package.json @@ -1,6 +1,6 @@ { "name": "@looker/code-editor", - "version": "0.1.4", + "version": "0.1.5", "description": "A syntax highlighter Viewer and Editor for Looker SDK supported languages.", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -30,7 +30,7 @@ }, "devDependencies": { "@looker/components-test-utils": "^1.3.1", - "@looker/sdk-codegen": "^21.0.19", + "@looker/sdk-codegen": "^21.0.20", "@testing-library/jest-dom": "^5.11.6", "@testing-library/react": "^11.2.2", "@testing-library/user-event": "^12.6.0", diff --git a/packages/extension-api-explorer/CHANGELOG.md b/packages/extension-api-explorer/CHANGELOG.md index 2bb2ead63..b3a7b96e4 100644 --- a/packages/extension-api-explorer/CHANGELOG.md +++ b/packages/extension-api-explorer/CHANGELOG.md @@ -1,5 +1,19 @@ # Changelog +### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-api-explorer-v21.8.1...extension-api-explorer-v21.8.2) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/api-explorer bumped from ^0.9.11 to ^0.9.12 + * @looker/extension-sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/extension-sdk-react bumped from ^21.8.2 to ^21.8.3 + * @looker/run-it bumped from ^0.9.11 to ^0.9.12 + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-codegen bumped from ^21.0.19 to ^21.0.20 + ### [21.8.1](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-api-explorer-v21.8.0...extension-api-explorer-v21.8.1) (2021-07-01) diff --git a/packages/extension-api-explorer/package.json b/packages/extension-api-explorer/package.json index 5d29a9a0c..9db611b3a 100644 --- a/packages/extension-api-explorer/package.json +++ b/packages/extension-api-explorer/package.json @@ -1,6 +1,6 @@ { "name": "@looker/extension-api-explorer", - "version": "21.8.1", + "version": "21.8.2", "description": "Looker API Explorer extension version ", "main": "dist/bundle.js", "sideEffects": false, @@ -15,14 +15,14 @@ "watch": "yarn lerna exec --scope @looker/extension-api-explorer --stream 'BABEL_ENV=build babel src --root-mode upward --out-dir lib/esm --source-maps --extensions .ts,.tsx --no-comments --watch'" }, "dependencies": { - "@looker/api-explorer": "^0.9.11", + "@looker/api-explorer": "^0.9.12", "@looker/components": "^1.4.1", - "@looker/extension-sdk": "^21.8.2", - "@looker/extension-sdk-react": "^21.8.2", + "@looker/extension-sdk": "^21.8.3", + "@looker/extension-sdk-react": "^21.8.3", "@looker/icons": "1.3.0", - "@looker/run-it": "^0.9.11", - "@looker/sdk": "^21.8.2", - "@looker/sdk-codegen": "^21.0.19", + "@looker/run-it": "^0.9.12", + "@looker/sdk": "^21.8.3", + "@looker/sdk-codegen": "^21.0.20", "@styled-icons/material": "^10.28.0", "@styled-icons/material-outlined": "^10.28.0", "@styled-icons/material-rounded": "^10.28.0", diff --git a/packages/extension-sdk-react/CHANGELOG.md b/packages/extension-sdk-react/CHANGELOG.md index a5f77b63d..986b3692b 100644 --- a/packages/extension-sdk-react/CHANGELOG.md +++ b/packages/extension-sdk-react/CHANGELOG.md @@ -5,6 +5,17 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.8.3](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-react-v21.8.2...extension-sdk-react-v21.8.3) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/extension-sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-react-v21.8.1...extension-sdk-react-v21.8.2) (2021-07-01) diff --git a/packages/extension-sdk-react/package.json b/packages/extension-sdk-react/package.json index a96f714b7..fc2270475 100644 --- a/packages/extension-sdk-react/package.json +++ b/packages/extension-sdk-react/package.json @@ -1,6 +1,6 @@ { "name": "@looker/extension-sdk-react", - "version": "21.8.2", + "version": "21.8.3", "description": "Looker Extension SDK for React", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -43,9 +43,9 @@ "react-router-dom": "^5.1.2" }, "dependencies": { - "@looker/extension-sdk": "^21.8.2", - "@looker/sdk": "^21.8.2", - "@looker/sdk-rtl": "^21.0.15", + "@looker/extension-sdk": "^21.8.3", + "@looker/sdk": "^21.8.3", + "@looker/sdk-rtl": "^21.0.16", "history": "^4.9.0", "lodash": "^4.17.20" }, diff --git a/packages/extension-sdk/CHANGELOG.md b/packages/extension-sdk/CHANGELOG.md index 16055196b..412efeb41 100644 --- a/packages/extension-sdk/CHANGELOG.md +++ b/packages/extension-sdk/CHANGELOG.md @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.8.3](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.8.2...extension-sdk-v21.8.3) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.8.1...extension-sdk-v21.8.2) (2021-07-01) diff --git a/packages/extension-sdk/package.json b/packages/extension-sdk/package.json index 2a294fe33..ca924b541 100644 --- a/packages/extension-sdk/package.json +++ b/packages/extension-sdk/package.json @@ -1,6 +1,6 @@ { "name": "@looker/extension-sdk", - "version": "21.8.2", + "version": "21.8.3", "description": "Looker Extension SDK", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -40,8 +40,8 @@ }, "dependencies": { "@looker/chatty": "^2.3.0", - "@looker/sdk": "^21.8.2", - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk": "^21.8.3", + "@looker/sdk-rtl": "^21.0.16", "deepmerge": "^4.2.2", "readable-stream": "^3.4.0", "request": "^2.88.0", diff --git a/packages/hackathon/CHANGELOG.md b/packages/hackathon/CHANGELOG.md index 8d969cf72..b25dde509 100644 --- a/packages/hackathon/CHANGELOG.md +++ b/packages/hackathon/CHANGELOG.md @@ -1,5 +1,18 @@ # Changelog +### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/hackathon-v21.8.1...hackathon-v21.8.2) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/extension-sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/extension-sdk-react bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + * @looker/wholly-sheet bumped from ^0.5.10 to ^0.5.11 + ### [21.8.1](https://www.github.com/looker-open-source/sdk-codegen/compare/hackathon-v21.8.0...hackathon-v21.8.1) (2021-07-01) diff --git a/packages/hackathon/package.json b/packages/hackathon/package.json index f3571c54f..c6edce640 100644 --- a/packages/hackathon/package.json +++ b/packages/hackathon/package.json @@ -1,6 +1,6 @@ { "name": "@looker/hackathon", - "version": "21.8.1", + "version": "21.8.2", "description": "Looker Hackathon extension", "main": "lib/esm/index.js", "typings": "lib/index.d.ts", @@ -35,12 +35,12 @@ }, "dependencies": { "@looker/components": "^1.4.1", - "@looker/extension-sdk": "^21.8.2", - "@looker/extension-sdk-react": "^21.8.2", + "@looker/extension-sdk": "^21.8.3", + "@looker/extension-sdk-react": "^21.8.3", "@looker/icons": "1.3.0", - "@looker/sdk": "^21.8.2", - "@looker/sdk-rtl": "^21.0.15", - "@looker/wholly-sheet": "^0.5.10", + "@looker/sdk": "^21.8.3", + "@looker/sdk-rtl": "^21.0.16", + "@looker/wholly-sheet": "^0.5.11", "@styled-icons/material": "^10.28.0", "@styled-icons/material-outlined": "^10.28.0", "@styled-icons/material-rounded": "^10.28.0", diff --git a/packages/run-it/CHANGELOG.md b/packages/run-it/CHANGELOG.md index f5aa51ce3..84c30f5fe 100644 --- a/packages/run-it/CHANGELOG.md +++ b/packages/run-it/CHANGELOG.md @@ -1,5 +1,17 @@ # Changelog +### [0.9.12](https://www.github.com/looker-open-source/sdk-codegen/compare/run-it-v0.9.11...run-it-v0.9.12) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-codegen bumped from ^21.0.19 to ^21.0.20 + * @looker/code-editor bumped from ^0.1.4 to ^0.1.5 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [0.9.11](https://www.github.com/looker-open-source/sdk-codegen/compare/run-it-v0.9.10...run-it-v0.9.11) (2021-07-01) diff --git a/packages/run-it/package.json b/packages/run-it/package.json index b04ee1d9f..26486ca5a 100644 --- a/packages/run-it/package.json +++ b/packages/run-it/package.json @@ -1,6 +1,6 @@ { "name": "@looker/run-it", - "version": "0.9.11", + "version": "0.9.12", "description": "A dynamic REST request input form and response visualizer", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -57,11 +57,11 @@ "@styled-icons/material": "^10.28.0", "@styled-icons/material-outlined": "^10.28.0", "@styled-icons/material-rounded": "^10.28.0", - "@looker/sdk": "^21.8.2", - "@looker/sdk-codegen": "^21.0.19", + "@looker/sdk": "^21.8.3", + "@looker/sdk-codegen": "^21.0.20", "@looker/sdk-codegen-utils": "^21.0.11", - "@looker/code-editor": "^0.1.4", - "@looker/sdk-rtl": "^21.0.15", + "@looker/code-editor": "^0.1.5", + "@looker/sdk-rtl": "^21.0.16", "@types/readable-stream": "^2.3.5", "lodash": "^4.17.19", "papaparse": "^5.3.0", diff --git a/packages/sdk-codegen-scripts/CHANGELOG.md b/packages/sdk-codegen-scripts/CHANGELOG.md index f5fd3ad5f..a39ba977b 100644 --- a/packages/sdk-codegen-scripts/CHANGELOG.md +++ b/packages/sdk-codegen-scripts/CHANGELOG.md @@ -1,5 +1,17 @@ # Changelog +### [21.0.21](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-scripts-v21.0.20...sdk-codegen-scripts-v21.0.21) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-codegen bumped from ^21.0.19 to ^21.0.20 + * @looker/sdk-node bumped from ^21.8.1 to ^21.8.2 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.0.20](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-scripts-v21.0.19...sdk-codegen-scripts-v21.0.20) (2021-07-01) @@ -150,4 +162,4 @@ * @looker/sdk-codegen bumped from ^21.0.10 to ^21.0.11 * @looker/sdk-codegen-utils bumped from ^21.0.10 to ^21.0.11 * @looker/sdk-node bumped from ^21.0.10 to ^21.4.0 - * @looker/sdk-rtl bumped from ^21.0.10 to ^21.0.11 \ No newline at end of file + * @looker/sdk-rtl bumped from ^21.0.10 to ^21.0.11 diff --git a/packages/sdk-codegen-scripts/package.json b/packages/sdk-codegen-scripts/package.json index 17ab64b3f..f2bfeac12 100644 --- a/packages/sdk-codegen-scripts/package.json +++ b/packages/sdk-codegen-scripts/package.json @@ -1,6 +1,6 @@ { "name": "@looker/sdk-codegen-scripts", - "version": "21.0.20", + "version": "21.0.21", "description": "Looker SDK Codegen scripts", "main": "lib/index.js", "typings": "lib/index.d.ts", @@ -27,11 +27,11 @@ "watch:cjs": "yarn lerna exec --scope @looker/sdk-codegen-scripts --stream 'BABEL_ENV=build_cjs babel src --root-mode upward --out-dir lib --source-maps --extensions .ts,.tsx --no-comments --watch'" }, "dependencies": { - "@looker/sdk": "^21.8.2", - "@looker/sdk-codegen": "^21.0.19", + "@looker/sdk": "^21.8.3", + "@looker/sdk-codegen": "^21.0.20", "@looker/sdk-codegen-utils": "^21.0.11", - "@looker/sdk-node": "^21.8.1", - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk-node": "^21.8.2", + "@looker/sdk-rtl": "^21.0.16", "config": "^3.3.1", "cross-env": "^7.0.2" }, diff --git a/packages/sdk-codegen/CHANGELOG.md b/packages/sdk-codegen/CHANGELOG.md index 350a232c8..fe9b90526 100644 --- a/packages/sdk-codegen/CHANGELOG.md +++ b/packages/sdk-codegen/CHANGELOG.md @@ -5,6 +5,20 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.0.20](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-v21.0.19...sdk-codegen-v21.0.20) (2021-07-02) + + +### Bug Fixes + +* python remove runtime asserts ([#703](https://www.github.com/looker-open-source/sdk-codegen/issues/703)) ([9b963c3](https://www.github.com/looker-open-source/sdk-codegen/commit/9b963c3367905f907e7867df1446f56e18284c3b)), closes [#695](https://www.github.com/looker-open-source/sdk-codegen/issues/695) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.0.19](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-codegen-v21.0.18...sdk-codegen-v21.0.19) (2021-07-01) @@ -120,4 +134,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added -- [API spec diff utility](https://github.com/looker-open-source/sdk-codegen/pull/380) +- [API spec diff utility](https://github.com/looker-open-source/sdk-codegen/pull/380) \ No newline at end of file diff --git a/packages/sdk-codegen/package.json b/packages/sdk-codegen/package.json index e7be320d0..21660bbeb 100644 --- a/packages/sdk-codegen/package.json +++ b/packages/sdk-codegen/package.json @@ -1,6 +1,6 @@ { "name": "@looker/sdk-codegen", - "version": "21.0.19", + "version": "21.0.20", "description": "Looker SDK Codegen core", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -36,7 +36,7 @@ }, "dependencies": { "@looker/sdk-codegen-utils": "^21.0.11", - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk-rtl": "^21.0.16", "blueimp-md5": "^2.13.0", "openapi3-ts": "^1.3.0" }, diff --git a/packages/sdk-node/CHANGELOG.md b/packages/sdk-node/CHANGELOG.md index 576f262b0..293cb6400 100644 --- a/packages/sdk-node/CHANGELOG.md +++ b/packages/sdk-node/CHANGELOG.md @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-node-v21.8.1...sdk-node-v21.8.2) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.8.1](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-node-v21.8.0...sdk-node-v21.8.1) (2021-07-01) diff --git a/packages/sdk-node/package.json b/packages/sdk-node/package.json index 117bb6290..3cf98dcc9 100644 --- a/packages/sdk-node/package.json +++ b/packages/sdk-node/package.json @@ -1,6 +1,6 @@ { "name": "@looker/sdk-node", - "version": "21.8.1", + "version": "21.8.2", "description": "Looker SDK Runtime for Node Library", "main": "lib/index.js", "typings": "lib/index.d.ts", @@ -38,8 +38,8 @@ "dotenv": "^8.2.0" }, "dependencies": { - "@looker/sdk": "^21.8.2", - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk": "^21.8.3", + "@looker/sdk-rtl": "^21.0.16", "ini": "^1.3.8", "readable-stream": "^3.4.0", "request": "^2.88.0", diff --git a/packages/sdk-rtl/CHANGELOG.md b/packages/sdk-rtl/CHANGELOG.md index 3ec06ae6a..63a3e0aaa 100644 --- a/packages/sdk-rtl/CHANGELOG.md +++ b/packages/sdk-rtl/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.0.16](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-rtl-v21.0.15...sdk-rtl-v21.0.16) (2021-07-02) + + +### Bug Fixes + +* explain pager and pageAll sdk param better ([#736](https://www.github.com/looker-open-source/sdk-codegen/issues/736)) ([a93a9b1](https://www.github.com/looker-open-source/sdk-codegen/commit/a93a9b1ded0acddeaf051e7a2fed5132c1cb5c0c)) + ### [21.0.15](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-rtl-v21.0.14...sdk-rtl-v21.0.15) (2021-07-01) diff --git a/packages/sdk-rtl/package.json b/packages/sdk-rtl/package.json index dfd66e599..bd8a1f32a 100644 --- a/packages/sdk-rtl/package.json +++ b/packages/sdk-rtl/package.json @@ -1,6 +1,6 @@ { "name": "@looker/sdk-rtl", - "version": "21.0.15", + "version": "21.0.16", "description": "Looker SDK Runtime Library", "main": "lib/index.js", "module": "lib/esm/index.js", diff --git a/packages/sdk/CHANGELOG.md b/packages/sdk/CHANGELOG.md index 466980e35..667195e72 100644 --- a/packages/sdk/CHANGELOG.md +++ b/packages/sdk/CHANGELOG.md @@ -5,6 +5,15 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.8.3](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-v21.8.2...sdk-v21.8.3) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + ### [21.8.2](https://www.github.com/looker-open-source/sdk-codegen/compare/sdk-v21.8.1...sdk-v21.8.2) (2021-07-01) diff --git a/packages/sdk/package.json b/packages/sdk/package.json index d3600afdc..f25ec3f2d 100644 --- a/packages/sdk/package.json +++ b/packages/sdk/package.json @@ -1,6 +1,6 @@ { "name": "@looker/sdk", - "version": "21.8.2", + "version": "21.8.3", "description": "Looker SDK", "main": "lib/index.js", "module": "lib/esm/index.js", @@ -41,7 +41,7 @@ "@types/request-promise-native": "^1.0.17" }, "dependencies": { - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk-rtl": "^21.0.16", "ini": "^1.3.8", "readable-stream": "^3.4.0", "request": "^2.88.0", diff --git a/packages/wholly-sheet/CHANGELOG.md b/packages/wholly-sheet/CHANGELOG.md index 49106db57..b94bd7b80 100644 --- a/packages/wholly-sheet/CHANGELOG.md +++ b/packages/wholly-sheet/CHANGELOG.md @@ -1,5 +1,17 @@ # Changelog +### [0.5.11](https://www.github.com/looker-open-source/sdk-codegen/compare/wholly-sheet-v0.5.10...wholly-sheet-v0.5.11) (2021-07-02) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @looker/sdk bumped from ^21.8.2 to ^21.8.3 + * @looker/sdk-rtl bumped from ^21.0.15 to ^21.0.16 + * devDependencies + * @looker/sdk-node bumped from ^21.8.1 to ^21.8.2 + ### [0.5.10](https://www.github.com/looker-open-source/sdk-codegen/compare/wholly-sheet-v0.5.9...wholly-sheet-v0.5.10) (2021-07-01) diff --git a/packages/wholly-sheet/package.json b/packages/wholly-sheet/package.json index 4516842ec..4d915b2eb 100644 --- a/packages/wholly-sheet/package.json +++ b/packages/wholly-sheet/package.json @@ -1,6 +1,6 @@ { "name": "@looker/wholly-sheet", - "version": "0.5.10", + "version": "0.5.11", "description": "Google sheets API wrapper for data table mimicking", "main": "lib/esm/index.js", "typings": "lib/index.d.ts", @@ -31,13 +31,13 @@ "watch": "yarn lerna exec --scope @looker/wholly-sheet --stream 'BABEL_ENV=build babel src --root-mode upward --out-dir lib/esm --source-maps --extensions .ts,.tsx --no-comments --watch'" }, "dependencies": { - "@looker/sdk": "^21.8.2", - "@looker/sdk-rtl": "^21.0.15", + "@looker/sdk": "^21.8.3", + "@looker/sdk-rtl": "^21.0.16", "lodash": "^4.17.20", "uuid": "^8.3.1" }, "devDependencies": { - "@looker/sdk-node": "^21.8.1", + "@looker/sdk-node": "^21.8.2", "@types/uuid": "^8.3.0", "google-auth-library": "^6.1.0" } diff --git a/python/CHANGELOG.md b/python/CHANGELOG.md index 9df46e00f..4666b5cc0 100644 --- a/python/CHANGELOG.md +++ b/python/CHANGELOG.md @@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +### [21.8.1](https://www.github.com/looker-open-source/sdk-codegen/compare/looker_sdk-v21.8.0...looker_sdk-v21.8.1) (2021-07-02) + + +### Bug Fixes + +* python datetime [de]serialization bug ([#734](https://www.github.com/looker-open-source/sdk-codegen/issues/734)) ([c821f2b](https://www.github.com/looker-open-source/sdk-codegen/commit/c821f2b77b99edfa2dd53aa0af82ab48081c3220)) +* python remove runtime asserts ([#703](https://www.github.com/looker-open-source/sdk-codegen/issues/703)) ([9b963c3](https://www.github.com/looker-open-source/sdk-codegen/commit/9b963c3367905f907e7867df1446f56e18284c3b)), closes [#695](https://www.github.com/looker-open-source/sdk-codegen/issues/695) + ## [21.8.0](https://www.github.com/looker-open-source/sdk-codegen/compare/looker_sdk-v21.6.1...looker_sdk-v21.8.0) (2021-06-17) diff --git a/python/looker_sdk/version.py b/python/looker_sdk/version.py index 36abc10a2..648436fc2 100644 --- a/python/looker_sdk/version.py +++ b/python/looker_sdk/version.py @@ -20,4 +20,4 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -__version__ = "21.8.0" +__version__ = "21.8.1" From 6b3895d35e138df9ff84286b7658434292617aa8 Mon Sep 17 00:00:00 2001 From: Joel Dodge Date: Wed, 7 Jul 2021 18:38:59 +0000 Subject: [PATCH 6/8] feat: Looker 21.10 bindings (#737) --- csharp/rtl/Constants.cs | 2 +- csharp/sdk/3.1/models.cs | 8 +- csharp/sdk/4.0/methods.cs | 70 +++++++- csharp/sdk/4.0/models.cs | 40 ++++- go/sdk/v3/models.go | 141 ++++++++-------- go/sdk/v4/methods.go | 41 ++++- go/sdk/v4/models.go | 154 ++++++++++-------- kotlin/src/main/com/looker/sdk/4.0/methods.kt | 66 +++++++- kotlin/src/main/com/looker/sdk/4.0/models.kt | 45 ++++- kotlin/src/main/com/looker/sdk/4.0/streams.kt | 66 +++++++- kotlin/src/main/com/looker/sdk/Constants.kt | 2 +- packages/sdk/src/3.1/models.ts | 14 +- packages/sdk/src/4.0/funcs.ts | 63 ++++++- packages/sdk/src/4.0/methods.ts | 61 ++++++- packages/sdk/src/4.0/methodsInterface.ts | 45 ++++- packages/sdk/src/4.0/models.ts | 63 ++++++- packages/sdk/src/4.0/streams.ts | 65 +++++++- packages/sdk/src/constants.ts | 2 +- python/looker_sdk/sdk/api31/models.py | 16 ++ python/looker_sdk/sdk/api40/methods.py | 78 ++++++++- python/looker_sdk/sdk/api40/models.py | 89 +++++++++- python/looker_sdk/sdk/constants.py | 2 +- release-please-config.json | 9 +- swift/looker/rtl/constants.swift | 2 +- swift/looker/sdk/methods.swift | 75 ++++++++- swift/looker/sdk/models.swift | 87 +++++++++- swift/looker/sdk/streams.swift | 75 ++++++++- 27 files changed, 1188 insertions(+), 193 deletions(-) diff --git a/csharp/rtl/Constants.cs b/csharp/rtl/Constants.cs index 293998708..cdbdd7b9d 100644 --- a/csharp/rtl/Constants.cs +++ b/csharp/rtl/Constants.cs @@ -61,7 +61,7 @@ public struct Constants public const string DefaultApiVersion = "4.0"; public const string AgentPrefix = "CS-SDK"; - public const string LookerVersion = "21.8"; + public const string LookerVersion = "21.10"; public const string Bearer = "Bearer"; public const string LookerAppiId = "x-looker-appid"; diff --git a/csharp/sdk/3.1/models.cs b/csharp/sdk/3.1/models.cs index f77ba3dd6..6612a263f 100644 --- a/csharp/sdk/3.1/models.cs +++ b/csharp/sdk/3.1/models.cs @@ -331,6 +331,8 @@ public class ContentValidationLook : SdkModel public long? id { get; set; } = null; /// Look Title public string? title { get; set; } = null; + /// Short Url (read-only) + public string? short_url { get; set; } = null; public ContentValidationFolder? folder { get; set; } public ContentValidationSpace? space { get; set; } } @@ -738,6 +740,8 @@ public class Dashboard : SdkModel /// The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) public string? preferred_viewer { get; set; } = null; public SpaceBase? space { get; set; } + /// Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + public bool? alert_sync_with_dashboard_filter_enabled { get; set; } = null; /// Background color public string? background_color { get; set; } = null; /// Time that the Dashboard was created. (read-only) @@ -1043,7 +1047,7 @@ public class DataActionFormSelectOption : SdkModel public class DataActionRequest : SdkModel { /// The JSON describing the data action. This JSON should be considered opaque and should be passed through unmodified from the query result it came from. - public StringDictionary? action { get; set; } = null; + public StringDictionary? action { get; set; } = null; /// User input for any form values the data action might use. public StringDictionary? form_values { get; set; } = null; } @@ -4498,6 +4502,8 @@ public class WriteDashboard : SdkModel /// The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) public string? preferred_viewer { get; set; } = null; public WriteSpaceBase? space { get; set; } + /// Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + public bool? alert_sync_with_dashboard_filter_enabled { get; set; } = null; /// Background color public string? background_color { get; set; } = null; /// Enables crossfiltering in dashboards - only available in dashboards-next (beta) diff --git a/csharp/sdk/4.0/methods.cs b/csharp/sdk/4.0/methods.cs index e7fc5142a..d88747f55 100644 --- a/csharp/sdk/4.0/methods.cs +++ b/csharp/sdk/4.0/methods.cs @@ -21,7 +21,7 @@ /// SOFTWARE. /// -/// 412 API methods +/// 413 API methods #nullable enable using System; @@ -1936,9 +1936,11 @@ public async Task> all_dialect_infos( /// ### Get all External OAuth Applications. /// + /// This is an OAuth Application which Looker uses to access external systems. + /// /// GET /external_oauth_applications -> ExternalOauthApplication[] /// - /// ExternalOauthApplication[] External OAuth Application. This is an OAuth Application which Looker uses to access external systems. (application/json) + /// ExternalOauthApplication[] External OAuth Application (application/json) /// /// Application name /// Application Client ID @@ -1954,9 +1956,11 @@ public async Task> all_extern /// ### Create an OAuth Application using the specified configuration. /// + /// This is an OAuth Application which Looker uses to access external systems. + /// /// POST /external_oauth_applications -> ExternalOauthApplication /// - /// ExternalOauthApplication External OAuth Application. This is an OAuth Application which Looker uses to access external systems. (application/json) + /// ExternalOauthApplication External OAuth Application (application/json) /// public async Task> create_external_oauth_application( WriteExternalOauthApplication body, @@ -6853,6 +6857,66 @@ public async Task> search_roles( { "filter_or", filter_or }},null,options); } + /// ### Search roles include user count + /// + /// Returns all role records that match the given search criteria, and attaches + /// associated user counts. + /// + /// If multiple search params are given and `filter_or` is FALSE or not specified, + /// search params are combined in a logical AND operation. + /// Only rows that match *all* search param criteria will be returned. + /// + /// If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + /// Results will include rows that match **any** of the search criteria. + /// + /// String search params use case-insensitive matching. + /// String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + /// example="dan%" will match "danger" and "Danzig" but not "David" + /// example="D_m%" will match "Damage" and "dump" + /// + /// Integer search params can accept a single value or a comma separated list of values. The multiple + /// values will be combined under a logical OR operation - results will match at least one of + /// the given values. + /// + /// Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + /// or exclude (respectively) rows where the column is null. + /// + /// Boolean search params accept only "true" and "false" as values. + /// + /// GET /roles/search/with_user_count -> RoleSearch[] + /// + /// RoleSearch[] Role (application/json) + /// + /// Requested fields. + /// Number of results to return (used with `offset`). + /// Number of results to skip before returning any (used with `limit`). + /// Fields to sort by. + /// Match role id. + /// Match role name. + /// Match roles by built_in status. + /// Combine given search criteria in a boolean OR expression. + public async Task> search_roles_with_user_count( + string? fields = null, + long? limit = null, + long? offset = null, + string? sorts = null, + long? id = null, + string? name = null, + bool? built_in = null, + bool? filter_or = null, + ITransportSettings? options = null) +{ + return await AuthRequest(HttpMethod.Get, "/roles/search/with_user_count", new Values { + { "fields", fields }, + { "limit", limit }, + { "offset", offset }, + { "sorts", sorts }, + { "id", id }, + { "name", name }, + { "built_in", built_in }, + { "filter_or", filter_or }},null,options); + } + /// ### Get information about the role with a specific id. /// /// GET /roles/{role_id} -> Role diff --git a/csharp/sdk/4.0/models.cs b/csharp/sdk/4.0/models.cs index ff511d676..dafcbae10 100644 --- a/csharp/sdk/4.0/models.cs +++ b/csharp/sdk/4.0/models.cs @@ -21,7 +21,7 @@ /// SOFTWARE. /// -/// 283 API models: 210 Spec, 0 Request, 56 Write, 17 Enum +/// 284 API models: 211 Spec, 0 Request, 56 Write, 17 Enum #nullable enable using System; @@ -405,6 +405,8 @@ public class ContentValidationDashboard : SdkModel public ContentValidationFolder? folder { get; set; } /// Dashboard Title public string? title { get; set; } = null; + /// Relative URL of the dashboard (read-only) + public string? url { get; set; } = null; } public class ContentValidationDashboardElement : SdkModel @@ -489,6 +491,8 @@ public class ContentValidationLook : SdkModel public long? id { get; set; } = null; /// Look Title public string? title { get; set; } = null; + /// Short Url (read-only) + public string? short_url { get; set; } = null; public ContentValidationFolder? folder { get; set; } } @@ -918,6 +922,8 @@ public class Dashboard : SdkModel public string? slug { get; set; } = null; /// The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) public string? preferred_viewer { get; set; } = null; + /// Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + public bool? alert_sync_with_dashboard_filter_enabled { get; set; } = null; /// Background color public string? background_color { get; set; } = null; /// Time that the Dashboard was created. (read-only) @@ -965,6 +971,8 @@ public class Dashboard : SdkModel /// Number of times viewed in the Looker web UI (read-only) public long? view_count { get; set; } = null; public DashboardAppearance? appearance { get; set; } + /// Relative URL of the dashboard (read-only) + public string? url { get; set; } = null; } public class DashboardAggregateTableLookml : SdkModel @@ -1220,7 +1228,7 @@ public class DataActionFormSelectOption : SdkModel public class DataActionRequest : SdkModel { /// The JSON describing the data action. This JSON should be considered opaque and should be passed through unmodified from the query result it came from. - public StringDictionary? action { get; set; } = null; + public StringDictionary? action { get; set; } = null; /// User input for any form values the data action might use. public StringDictionary? form_values { get; set; } = null; } @@ -3714,7 +3722,27 @@ public class Role : SdkModel public ModelSet? model_set { get; set; } /// (Write-Only) Id of model set public long? model_set_id { get; set; } = null; - /// Count of users with this role, only returned if user_count field is requested (read-only) + /// Link to get this item (read-only) + public string? url { get; set; } = null; + /// Link to get list of users with this role (read-only) + public string? users_url { get; set; } = null; +} + +public class RoleSearch : SdkModel +{ + /// Operations the current user is able to perform on this object (read-only) + public StringDictionary? can { get; set; } = null; + /// Unique Id (read-only) + public long? id { get; set; } = null; + /// Name of Role + public string? name { get; set; } = null; + public PermissionSet? permission_set { get; set; } + /// (Write-Only) Id of permission set + public long? permission_set_id { get; set; } = null; + public ModelSet? model_set { get; set; } + /// (Write-Only) Id of model set + public long? model_set_id { get; set; } = null; + /// Count of users with this role (read-only) public long? user_count { get; set; } = null; /// Link to get this item (read-only) public string? url { get; set; } = null; @@ -4871,7 +4899,7 @@ public class WriteCustomWelcomeEmail : SdkModel } /// Dynamically generated writeable type for Dashboard removes properties: -/// can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count +/// can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url public class WriteDashboard : SdkModel { /// Description @@ -4889,6 +4917,8 @@ public class WriteDashboard : SdkModel public string? slug { get; set; } = null; /// The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) public string? preferred_viewer { get; set; } = null; + /// Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + public bool? alert_sync_with_dashboard_filter_enabled { get; set; } = null; /// Background color public string? background_color { get; set; } = null; /// Enables crossfiltering in dashboards - only available in dashboards-next (beta) @@ -5570,7 +5600,7 @@ public class WriteResultMakerWithIdVisConfigAndDynamicFields : SdkModel } /// Dynamically generated writeable type for Role removes properties: -/// can, id, user_count, url, users_url +/// can, id, url, users_url public class WriteRole : SdkModel { /// Name of Role diff --git a/go/sdk/v3/models.go b/go/sdk/v3/models.go index 5d662f0a5..0c1cd6638 100644 --- a/go/sdk/v3/models.go +++ b/go/sdk/v3/models.go @@ -222,10 +222,11 @@ type ContentValidationFolder struct { type ContentValidationLook struct { - Id *int64 `json:"id,omitempty"` // Unique Id - Title *string `json:"title,omitempty"` // Look Title - Folder *ContentValidationFolder `json:"folder,omitempty"` - Space *ContentValidationSpace `json:"space,omitempty"` + Id *int64 `json:"id,omitempty"` // Unique Id + Title *string `json:"title,omitempty"` // Look Title + ShortUrl *string `json:"short_url,omitempty"` // Short Url + Folder *ContentValidationFolder `json:"folder,omitempty"` + Space *ContentValidationSpace `json:"space,omitempty"` } @@ -463,48 +464,49 @@ type CustomWelcomeEmail struct { type Dashboard struct { - Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object - ContentFavoriteId *int64 `json:"content_favorite_id,omitempty"` // Content Favorite Id - ContentMetadataId *int64 `json:"content_metadata_id,omitempty"` // Id of content metadata - Description *string `json:"description,omitempty"` // Description - Hidden *bool `json:"hidden,omitempty"` // Is Hidden - Id *string `json:"id,omitempty"` // Unique Id - Model *LookModel `json:"model,omitempty"` - QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. - Readonly *bool `json:"readonly,omitempty"` // Is Read-only - RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. - RefreshIntervalToI *int64 `json:"refresh_interval_to_i,omitempty"` // Refresh Interval in milliseconds - Folder *FolderBase `json:"folder,omitempty"` - Title *string `json:"title,omitempty"` // Dashboard Title - UserId *int64 `json:"user_id,omitempty"` // Id of User - Slug *string `json:"slug,omitempty"` // Content Metadata Slug - PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) - Space *SpaceBase `json:"space,omitempty"` - BackgroundColor *string `json:"background_color,omitempty"` // Background color - CreatedAt *time.Time `json:"created_at,omitempty"` // Time that the Dashboard was created. - CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) - DashboardElements *[]DashboardElement `json:"dashboard_elements,omitempty"` // Elements - DashboardFilters *[]DashboardFilter `json:"dashboard_filters,omitempty"` // Filters - DashboardLayouts *[]DashboardLayout `json:"dashboard_layouts,omitempty"` // Layouts - Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. - DeletedAt *time.Time `json:"deleted_at,omitempty"` // Time that the Dashboard was 'soft' deleted. - DeleterId *int64 `json:"deleter_id,omitempty"` // Id of User that 'soft' deleted the dashboard. - EditUri *url.URL `json:"edit_uri,omitempty"` // Relative path of URI of LookML file to edit the dashboard (LookML dashboard only). - FavoriteCount *int64 `json:"favorite_count,omitempty"` // Number of times favorited - LastAccessedAt *time.Time `json:"last_accessed_at,omitempty"` // Time the dashboard was last accessed - LastViewedAt *time.Time `json:"last_viewed_at,omitempty"` // Time last viewed in the Looker web UI - LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. - LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. - ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) - ShowTitle *bool `json:"show_title,omitempty"` // Show title - SpaceId *string `json:"space_id,omitempty"` // Id of Space - FolderId *string `json:"folder_id,omitempty"` // Id of folder - TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles - TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color - TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color - TitleColor *string `json:"title_color,omitempty"` // Title color - ViewCount *int64 `json:"view_count,omitempty"` // Number of times viewed in the Looker web UI - Appearance *DashboardAppearance `json:"appearance,omitempty"` + Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object + ContentFavoriteId *int64 `json:"content_favorite_id,omitempty"` // Content Favorite Id + ContentMetadataId *int64 `json:"content_metadata_id,omitempty"` // Id of content metadata + Description *string `json:"description,omitempty"` // Description + Hidden *bool `json:"hidden,omitempty"` // Is Hidden + Id *string `json:"id,omitempty"` // Unique Id + Model *LookModel `json:"model,omitempty"` + QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. + Readonly *bool `json:"readonly,omitempty"` // Is Read-only + RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. + RefreshIntervalToI *int64 `json:"refresh_interval_to_i,omitempty"` // Refresh Interval in milliseconds + Folder *FolderBase `json:"folder,omitempty"` + Title *string `json:"title,omitempty"` // Dashboard Title + UserId *int64 `json:"user_id,omitempty"` // Id of User + Slug *string `json:"slug,omitempty"` // Content Metadata Slug + PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + Space *SpaceBase `json:"space,omitempty"` + AlertSyncWithDashboardFilterEnabled *bool `json:"alert_sync_with_dashboard_filter_enabled,omitempty"` // Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + BackgroundColor *string `json:"background_color,omitempty"` // Background color + CreatedAt *time.Time `json:"created_at,omitempty"` // Time that the Dashboard was created. + CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) + DashboardElements *[]DashboardElement `json:"dashboard_elements,omitempty"` // Elements + DashboardFilters *[]DashboardFilter `json:"dashboard_filters,omitempty"` // Filters + DashboardLayouts *[]DashboardLayout `json:"dashboard_layouts,omitempty"` // Layouts + Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` // Time that the Dashboard was 'soft' deleted. + DeleterId *int64 `json:"deleter_id,omitempty"` // Id of User that 'soft' deleted the dashboard. + EditUri *url.URL `json:"edit_uri,omitempty"` // Relative path of URI of LookML file to edit the dashboard (LookML dashboard only). + FavoriteCount *int64 `json:"favorite_count,omitempty"` // Number of times favorited + LastAccessedAt *time.Time `json:"last_accessed_at,omitempty"` // Time the dashboard was last accessed + LastViewedAt *time.Time `json:"last_viewed_at,omitempty"` // Time last viewed in the Looker web UI + LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. + LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. + ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) + ShowTitle *bool `json:"show_title,omitempty"` // Show title + SpaceId *string `json:"space_id,omitempty"` // Id of Space + FolderId *string `json:"folder_id,omitempty"` // Id of folder + TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles + TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color + TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color + TitleColor *string `json:"title_color,omitempty"` // Title color + ViewCount *int64 `json:"view_count,omitempty"` // Number of times viewed in the Looker web UI + Appearance *DashboardAppearance `json:"appearance,omitempty"` } @@ -3220,29 +3222,30 @@ type WriteCustomWelcomeEmail struct { // Dynamically generated writeable type for Dashboard removes properties: // can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count type WriteDashboard struct { - Description *string `json:"description,omitempty"` // Description - Hidden *bool `json:"hidden,omitempty"` // Is Hidden - QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. - RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. - Folder *WriteFolderBase `json:"folder,omitempty"` - Title *string `json:"title,omitempty"` // Dashboard Title - Slug *string `json:"slug,omitempty"` // Content Metadata Slug - PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) - Space *WriteSpaceBase `json:"space,omitempty"` - BackgroundColor *string `json:"background_color,omitempty"` // Background color - CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) - Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. - LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. - LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. - ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) - ShowTitle *bool `json:"show_title,omitempty"` // Show title - SpaceId *string `json:"space_id,omitempty"` // Id of Space - FolderId *string `json:"folder_id,omitempty"` // Id of folder - TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles - TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color - TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color - TitleColor *string `json:"title_color,omitempty"` // Title color - Appearance *DashboardAppearance `json:"appearance,omitempty"` + Description *string `json:"description,omitempty"` // Description + Hidden *bool `json:"hidden,omitempty"` // Is Hidden + QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. + RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. + Folder *WriteFolderBase `json:"folder,omitempty"` + Title *string `json:"title,omitempty"` // Dashboard Title + Slug *string `json:"slug,omitempty"` // Content Metadata Slug + PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + Space *WriteSpaceBase `json:"space,omitempty"` + AlertSyncWithDashboardFilterEnabled *bool `json:"alert_sync_with_dashboard_filter_enabled,omitempty"` // Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + BackgroundColor *string `json:"background_color,omitempty"` // Background color + CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) + Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. + LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. + LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. + ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) + ShowTitle *bool `json:"show_title,omitempty"` // Show title + SpaceId *string `json:"space_id,omitempty"` // Id of Space + FolderId *string `json:"folder_id,omitempty"` // Id of folder + TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles + TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color + TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color + TitleColor *string `json:"title_color,omitempty"` // Title color + Appearance *DashboardAppearance `json:"appearance,omitempty"` } // Dynamically generated writeable type for DashboardBase removes properties: diff --git a/go/sdk/v4/methods.go b/go/sdk/v4/methods.go index f774403e3..0f27e9207 100644 --- a/go/sdk/v4/methods.go +++ b/go/sdk/v4/methods.go @@ -26,7 +26,7 @@ SOFTWARE. /* -412 API methods +413 API methods */ @@ -1648,6 +1648,8 @@ func (l *LookerSDK) AllDialectInfos( // ### Get all External OAuth Applications. // +// This is an OAuth Application which Looker uses to access external systems. +// // GET /external_oauth_applications -> []ExternalOauthApplication func (l *LookerSDK) AllExternalOauthApplications(request RequestAllExternalOauthApplications, options *rtl.ApiSettings) ([]ExternalOauthApplication, error) { @@ -1659,6 +1661,8 @@ func (l *LookerSDK) AllExternalOauthApplications(request RequestAllExternalOauth // ### Create an OAuth Application using the specified configuration. // +// This is an OAuth Application which Looker uses to access external systems. +// // POST /external_oauth_applications -> ExternalOauthApplication func (l *LookerSDK) CreateExternalOauthApplication( body WriteExternalOauthApplication, @@ -5185,6 +5189,41 @@ func (l *LookerSDK) SearchRoles(request RequestSearchRoles, } +// ### Search roles include user count +// +// Returns all role records that match the given search criteria, and attaches +// associated user counts. +// +// If multiple search params are given and `filter_or` is FALSE or not specified, +// search params are combined in a logical AND operation. +// Only rows that match *all* search param criteria will be returned. +// +// If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. +// Results will include rows that match **any** of the search criteria. +// +// String search params use case-insensitive matching. +// String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. +// example="dan%" will match "danger" and "Danzig" but not "David" +// example="D_m%" will match "Damage" and "dump" +// +// Integer search params can accept a single value or a comma separated list of values. The multiple +// values will be combined under a logical OR operation - results will match at least one of +// the given values. +// +// Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match +// or exclude (respectively) rows where the column is null. +// +// Boolean search params accept only "true" and "false" as values. +// +// GET /roles/search/with_user_count -> []RoleSearch +func (l *LookerSDK) SearchRolesWithUserCount(request RequestSearchRoles, + options *rtl.ApiSettings) ([]RoleSearch, error) { + var result []RoleSearch + err := l.session.Do(&result, "GET", "/4.0", "/roles/search/with_user_count", map[string]interface{}{"fields": request.Fields, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "id": request.Id, "name": request.Name, "built_in": request.BuiltIn, "filter_or": request.FilterOr}, nil, options) + return result, err + +} + // ### Get information about the role with a specific id. // // GET /roles/{role_id} -> Role diff --git a/go/sdk/v4/models.go b/go/sdk/v4/models.go index 31e2792c6..d7c4fd424 100644 --- a/go/sdk/v4/models.go +++ b/go/sdk/v4/models.go @@ -26,7 +26,7 @@ SOFTWARE. /* -334 API models: 210 Spec, 51 Request, 56 Write, 17 Enum +335 API models: 211 Spec, 51 Request, 56 Write, 17 Enum */ @@ -262,6 +262,7 @@ type ContentValidationDashboard struct { Id *string `json:"id,omitempty"` // Unique Id Folder *ContentValidationFolder `json:"folder,omitempty"` Title *string `json:"title,omitempty"` // Dashboard Title + Url *string `json:"url,omitempty"` // Relative URL of the dashboard } @@ -312,9 +313,10 @@ type ContentValidationFolder struct { type ContentValidationLook struct { - Id *int64 `json:"id,omitempty"` // Unique Id - Title *string `json:"title,omitempty"` // Look Title - Folder *ContentValidationFolder `json:"folder,omitempty"` + Id *int64 `json:"id,omitempty"` // Unique Id + Title *string `json:"title,omitempty"` // Look Title + ShortUrl *string `json:"short_url,omitempty"` // Short Url + Folder *ContentValidationFolder `json:"folder,omitempty"` } @@ -573,46 +575,48 @@ type CustomWelcomeEmail struct { type Dashboard struct { - Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object - ContentFavoriteId *int64 `json:"content_favorite_id,omitempty"` // Content Favorite Id - ContentMetadataId *int64 `json:"content_metadata_id,omitempty"` // Id of content metadata - Description *string `json:"description,omitempty"` // Description - Hidden *bool `json:"hidden,omitempty"` // Is Hidden - Id *string `json:"id,omitempty"` // Unique Id - Model *LookModel `json:"model,omitempty"` - QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. - Readonly *bool `json:"readonly,omitempty"` // Is Read-only - RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. - RefreshIntervalToI *int64 `json:"refresh_interval_to_i,omitempty"` // Refresh Interval in milliseconds - Folder *FolderBase `json:"folder,omitempty"` - Title *string `json:"title,omitempty"` // Dashboard Title - UserId *int64 `json:"user_id,omitempty"` // Id of User - Slug *string `json:"slug,omitempty"` // Content Metadata Slug - PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) - BackgroundColor *string `json:"background_color,omitempty"` // Background color - CreatedAt *time.Time `json:"created_at,omitempty"` // Time that the Dashboard was created. - CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) - DashboardElements *[]DashboardElement `json:"dashboard_elements,omitempty"` // Elements - DashboardFilters *[]DashboardFilter `json:"dashboard_filters,omitempty"` // Filters - DashboardLayouts *[]DashboardLayout `json:"dashboard_layouts,omitempty"` // Layouts - Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. - DeletedAt *time.Time `json:"deleted_at,omitempty"` // Time that the Dashboard was 'soft' deleted. - DeleterId *int64 `json:"deleter_id,omitempty"` // Id of User that 'soft' deleted the dashboard. - EditUri *string `json:"edit_uri,omitempty"` // Relative path of URI of LookML file to edit the dashboard (LookML dashboard only). - FavoriteCount *int64 `json:"favorite_count,omitempty"` // Number of times favorited - LastAccessedAt *time.Time `json:"last_accessed_at,omitempty"` // Time the dashboard was last accessed - LastViewedAt *time.Time `json:"last_viewed_at,omitempty"` // Time last viewed in the Looker web UI - LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. - LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. - ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) - ShowTitle *bool `json:"show_title,omitempty"` // Show title - FolderId *string `json:"folder_id,omitempty"` // Id of folder - TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles - TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color - TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color - TitleColor *string `json:"title_color,omitempty"` // Title color - ViewCount *int64 `json:"view_count,omitempty"` // Number of times viewed in the Looker web UI - Appearance *DashboardAppearance `json:"appearance,omitempty"` + Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object + ContentFavoriteId *int64 `json:"content_favorite_id,omitempty"` // Content Favorite Id + ContentMetadataId *int64 `json:"content_metadata_id,omitempty"` // Id of content metadata + Description *string `json:"description,omitempty"` // Description + Hidden *bool `json:"hidden,omitempty"` // Is Hidden + Id *string `json:"id,omitempty"` // Unique Id + Model *LookModel `json:"model,omitempty"` + QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. + Readonly *bool `json:"readonly,omitempty"` // Is Read-only + RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. + RefreshIntervalToI *int64 `json:"refresh_interval_to_i,omitempty"` // Refresh Interval in milliseconds + Folder *FolderBase `json:"folder,omitempty"` + Title *string `json:"title,omitempty"` // Dashboard Title + UserId *int64 `json:"user_id,omitempty"` // Id of User + Slug *string `json:"slug,omitempty"` // Content Metadata Slug + PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + AlertSyncWithDashboardFilterEnabled *bool `json:"alert_sync_with_dashboard_filter_enabled,omitempty"` // Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + BackgroundColor *string `json:"background_color,omitempty"` // Background color + CreatedAt *time.Time `json:"created_at,omitempty"` // Time that the Dashboard was created. + CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) + DashboardElements *[]DashboardElement `json:"dashboard_elements,omitempty"` // Elements + DashboardFilters *[]DashboardFilter `json:"dashboard_filters,omitempty"` // Filters + DashboardLayouts *[]DashboardLayout `json:"dashboard_layouts,omitempty"` // Layouts + Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` // Time that the Dashboard was 'soft' deleted. + DeleterId *int64 `json:"deleter_id,omitempty"` // Id of User that 'soft' deleted the dashboard. + EditUri *string `json:"edit_uri,omitempty"` // Relative path of URI of LookML file to edit the dashboard (LookML dashboard only). + FavoriteCount *int64 `json:"favorite_count,omitempty"` // Number of times favorited + LastAccessedAt *time.Time `json:"last_accessed_at,omitempty"` // Time the dashboard was last accessed + LastViewedAt *time.Time `json:"last_viewed_at,omitempty"` // Time last viewed in the Looker web UI + LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. + LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. + ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) + ShowTitle *bool `json:"show_title,omitempty"` // Show title + FolderId *string `json:"folder_id,omitempty"` // Id of folder + TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles + TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color + TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color + TitleColor *string `json:"title_color,omitempty"` // Title color + ViewCount *int64 `json:"view_count,omitempty"` // Number of times viewed in the Looker web UI + Appearance *DashboardAppearance `json:"appearance,omitempty"` + Url *string `json:"url,omitempty"` // Relative URL of the dashboard } @@ -2802,7 +2806,20 @@ type Role struct { PermissionSetId *int64 `json:"permission_set_id,omitempty"` // (Write-Only) Id of permission set ModelSet *ModelSet `json:"model_set,omitempty"` ModelSetId *int64 `json:"model_set_id,omitempty"` // (Write-Only) Id of model set - UserCount *int64 `json:"user_count,omitempty"` // Count of users with this role, only returned if user_count field is requested + Url *string `json:"url,omitempty"` // Link to get this item + UsersUrl *string `json:"users_url,omitempty"` // Link to get list of users with this role +} + + +type RoleSearch struct { + Can *map[string]bool `json:"can,omitempty"` // Operations the current user is able to perform on this object + Id *int64 `json:"id,omitempty"` // Unique Id + Name *string `json:"name,omitempty"` // Name of Role + PermissionSet *PermissionSet `json:"permission_set,omitempty"` + PermissionSetId *int64 `json:"permission_set_id,omitempty"` // (Write-Only) Id of permission set + ModelSet *ModelSet `json:"model_set,omitempty"` + ModelSetId *int64 `json:"model_set_id,omitempty"` // (Write-Only) Id of model set + UserCount *int64 `json:"user_count,omitempty"` // Count of users with this role Url *string `json:"url,omitempty"` // Link to get this item UsersUrl *string `json:"users_url,omitempty"` // Link to get list of users with this role } @@ -3495,29 +3512,30 @@ type WriteCustomWelcomeEmail struct { } // Dynamically generated writeable type for Dashboard removes properties: -// can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count +// can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url type WriteDashboard struct { - Description *string `json:"description,omitempty"` // Description - Hidden *bool `json:"hidden,omitempty"` // Is Hidden - QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. - RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. - Folder *WriteFolderBase `json:"folder,omitempty"` - Title *string `json:"title,omitempty"` // Dashboard Title - Slug *string `json:"slug,omitempty"` // Content Metadata Slug - PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) - BackgroundColor *string `json:"background_color,omitempty"` // Background color - CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) - Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. - LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. - LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. - ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) - ShowTitle *bool `json:"show_title,omitempty"` // Show title - FolderId *string `json:"folder_id,omitempty"` // Id of folder - TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles - TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color - TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color - TitleColor *string `json:"title_color,omitempty"` // Title color - Appearance *DashboardAppearance `json:"appearance,omitempty"` + Description *string `json:"description,omitempty"` // Description + Hidden *bool `json:"hidden,omitempty"` // Is Hidden + QueryTimezone *string `json:"query_timezone,omitempty"` // Timezone in which the Dashboard will run by default. + RefreshInterval *string `json:"refresh_interval,omitempty"` // Refresh Interval, as a time duration phrase like "2 hours 30 minutes". A number with no time units will be interpreted as whole seconds. + Folder *WriteFolderBase `json:"folder,omitempty"` + Title *string `json:"title,omitempty"` // Dashboard Title + Slug *string `json:"slug,omitempty"` // Content Metadata Slug + PreferredViewer *string `json:"preferred_viewer,omitempty"` // The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + AlertSyncWithDashboardFilterEnabled *bool `json:"alert_sync_with_dashboard_filter_enabled,omitempty"` // Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + BackgroundColor *string `json:"background_color,omitempty"` // Background color + CrossfilterEnabled *bool `json:"crossfilter_enabled,omitempty"` // Enables crossfiltering in dashboards - only available in dashboards-next (beta) + Deleted *bool `json:"deleted,omitempty"` // Whether or not a dashboard is 'soft' deleted. + LoadConfiguration *string `json:"load_configuration,omitempty"` // configuration option that governs how dashboard loading will happen. + LookmlLinkId *string `json:"lookml_link_id,omitempty"` // Links this dashboard to a particular LookML dashboard such that calling a **sync** operation on that LookML dashboard will update this dashboard to match. + ShowFiltersBar *bool `json:"show_filters_bar,omitempty"` // Show filters bar. **Security Note:** This property only affects the *cosmetic* appearance of the dashboard, not a user's ability to access data. Hiding the filters bar does **NOT** prevent users from changing filters by other means. For information on how to set up secure data access control policies, see [Control User Access to Data](https://looker.com/docs/r/api/control-access) + ShowTitle *bool `json:"show_title,omitempty"` // Show title + FolderId *string `json:"folder_id,omitempty"` // Id of folder + TextTileTextColor *string `json:"text_tile_text_color,omitempty"` // Color of text on text tiles + TileBackgroundColor *string `json:"tile_background_color,omitempty"` // Tile background color + TileTextColor *string `json:"tile_text_color,omitempty"` // Tile text color + TitleColor *string `json:"title_color,omitempty"` // Title color + Appearance *DashboardAppearance `json:"appearance,omitempty"` } // Dynamically generated writeable type for DashboardBase removes properties: @@ -3914,7 +3932,7 @@ type WriteResultMakerWithIdVisConfigAndDynamicFields struct { } // Dynamically generated writeable type for Role removes properties: -// can, id, user_count, url, users_url +// can, id, url, users_url type WriteRole struct { Name *string `json:"name,omitempty"` // Name of Role PermissionSet *WritePermissionSet `json:"permission_set,omitempty"` diff --git a/kotlin/src/main/com/looker/sdk/4.0/methods.kt b/kotlin/src/main/com/looker/sdk/4.0/methods.kt index 7c05e36b6..cf7faecf1 100644 --- a/kotlin/src/main/com/looker/sdk/4.0/methods.kt +++ b/kotlin/src/main/com/looker/sdk/4.0/methods.kt @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ @@ -1987,6 +1987,8 @@ class LookerSDK(authSession: AuthSession) : APIMethods(authSession) { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * @param {String} name Application name * @param {String} client_id Application Client ID * @@ -2005,6 +2007,8 @@ class LookerSDK(authSession: AuthSession) : APIMethods(authSession) { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * @param {WriteExternalOauthApplication} body * * POST /external_oauth_applications -> ExternalOauthApplication @@ -6944,6 +6948,66 @@ class LookerSDK(authSession: AuthSession) : APIMethods(authSession) { } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * @param {String} fields Requested fields. + * @param {Long} limit Number of results to return (used with `offset`). + * @param {Long} offset Number of results to skip before returning any (used with `limit`). + * @param {String} sorts Fields to sort by. + * @param {Long} id Match role id. + * @param {String} name Match role name. + * @param {Boolean} built_in Match roles by built_in status. + * @param {Boolean} filter_or Combine given search criteria in a boolean OR expression. + * + * GET /roles/search/with_user_count -> Array + */ + @JvmOverloads fun search_roles_with_user_count( + fields: String? = null, + limit: Long? = null, + offset: Long? = null, + sorts: String? = null, + id: Long? = null, + name: String? = null, + built_in: Boolean? = null, + filter_or: Boolean? = null + ) : SDKResponse { + return this.get>("/roles/search/with_user_count", + mapOf("fields" to fields, + "limit" to limit, + "offset" to offset, + "sorts" to sorts, + "id" to id, + "name" to name, + "built_in" to built_in, + "filter_or" to filter_or)) + } + + /** * ### Get information about the role with a specific id. * diff --git a/kotlin/src/main/com/looker/sdk/4.0/models.kt b/kotlin/src/main/com/looker/sdk/4.0/models.kt index 663007ab2..9e13e9576 100644 --- a/kotlin/src/main/com/looker/sdk/4.0/models.kt +++ b/kotlin/src/main/com/looker/sdk/4.0/models.kt @@ -25,7 +25,7 @@ */ /** - * 283 API models: 210 Spec, 0 Request, 56 Write, 17 Enum + * 284 API models: 211 Spec, 0 Request, 56 Write, 17 Enum */ @@ -415,12 +415,14 @@ data class ContentValidationAlert ( * @property id Unique Id (read-only) * @property folder * @property title Dashboard Title + * @property url Relative URL of the dashboard (read-only) */ data class ContentValidationDashboard ( var description: String? = null, var id: String? = null, var folder: ContentValidationFolder? = null, - var title: String? = null + var title: String? = null, + var url: String? = null ) : Serializable /** @@ -506,11 +508,13 @@ data class ContentValidationFolder ( /** * @property id Unique Id (read-only) * @property title Look Title + * @property short_url Short Url (read-only) * @property folder */ data class ContentValidationLook ( var id: Long? = null, var title: String? = null, + var short_url: String? = null, var folder: ContentValidationFolder? = null ) : Serializable @@ -982,6 +986,7 @@ data class CustomWelcomeEmail ( * @property user_id Id of User (read-only) * @property slug Content Metadata Slug * @property preferred_viewer The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + * @property alert_sync_with_dashboard_filter_enabled Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) * @property background_color Background color * @property created_at Time that the Dashboard was created. (read-only) * @property crossfilter_enabled Enables crossfiltering in dashboards - only available in dashboards-next (beta) @@ -1006,6 +1011,7 @@ data class CustomWelcomeEmail ( * @property title_color Title color * @property view_count Number of times viewed in the Looker web UI (read-only) * @property appearance + * @property url Relative URL of the dashboard (read-only) */ data class Dashboard ( var can: Map? = null, @@ -1024,6 +1030,7 @@ data class Dashboard ( var user_id: Long? = null, var slug: String? = null, var preferred_viewer: String? = null, + var alert_sync_with_dashboard_filter_enabled: Boolean? = null, var background_color: String? = null, var created_at: Date? = null, var crossfilter_enabled: Boolean? = null, @@ -1047,7 +1054,8 @@ data class Dashboard ( var tile_text_color: String? = null, var title_color: String? = null, var view_count: Long? = null, - var appearance: DashboardAppearance? = null + var appearance: DashboardAppearance? = null, + var url: String? = null ) : Serializable /** @@ -3973,11 +3981,34 @@ data class ResultMakerWithIdVisConfigAndDynamicFields ( * @property permission_set_id (Write-Only) Id of permission set * @property model_set * @property model_set_id (Write-Only) Id of model set - * @property user_count Count of users with this role, only returned if user_count field is requested (read-only) * @property url Link to get this item (read-only) * @property users_url Link to get list of users with this role (read-only) */ data class Role ( + var can: Map? = null, + var id: Long? = null, + var name: String? = null, + var permission_set: PermissionSet? = null, + var permission_set_id: Long? = null, + var model_set: ModelSet? = null, + var model_set_id: Long? = null, + var url: String? = null, + var users_url: String? = null +) : Serializable + +/** + * @property can Operations the current user is able to perform on this object (read-only) + * @property id Unique Id (read-only) + * @property name Name of Role + * @property permission_set + * @property permission_set_id (Write-Only) Id of permission set + * @property model_set + * @property model_set_id (Write-Only) Id of model set + * @property user_count Count of users with this role (read-only) + * @property url Link to get this item (read-only) + * @property users_url Link to get list of users with this role (read-only) + */ +data class RoleSearch ( var can: Map? = null, var id: Long? = null, var name: String? = null, @@ -5204,7 +5235,7 @@ data class WriteCustomWelcomeEmail ( /** * Dynamically generated writeable type for Dashboard removes properties: - * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count + * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url * * @property description Description * @property hidden Is Hidden @@ -5214,6 +5245,7 @@ data class WriteCustomWelcomeEmail ( * @property title Dashboard Title * @property slug Content Metadata Slug * @property preferred_viewer The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + * @property alert_sync_with_dashboard_filter_enabled Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) * @property background_color Background color * @property crossfilter_enabled Enables crossfiltering in dashboards - only available in dashboards-next (beta) * @property deleted Whether or not a dashboard is 'soft' deleted. @@ -5237,6 +5269,7 @@ data class WriteDashboard ( var title: String? = null, var slug: String? = null, var preferred_viewer: String? = null, + var alert_sync_with_dashboard_filter_enabled: Boolean? = null, var background_color: String? = null, var crossfilter_enabled: Boolean? = null, var deleted: Boolean? = null, @@ -5986,7 +6019,7 @@ data class WriteResultMakerWithIdVisConfigAndDynamicFields ( /** * Dynamically generated writeable type for Role removes properties: - * can, id, user_count, url, users_url + * can, id, url, users_url * * @property name Name of Role * @property permission_set diff --git a/kotlin/src/main/com/looker/sdk/4.0/streams.kt b/kotlin/src/main/com/looker/sdk/4.0/streams.kt index 36a13593f..42bc95f6d 100644 --- a/kotlin/src/main/com/looker/sdk/4.0/streams.kt +++ b/kotlin/src/main/com/looker/sdk/4.0/streams.kt @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ @@ -1986,6 +1986,8 @@ class LookerSDKStream(authSession: AuthSession) : APIMethods(authSession) { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * @param {String} name Application name * @param {String} client_id Application Client ID * @@ -2004,6 +2006,8 @@ class LookerSDKStream(authSession: AuthSession) : APIMethods(authSession) { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * @param {WriteExternalOauthApplication} body * * POST /external_oauth_applications -> ByteArray @@ -6943,6 +6947,66 @@ class LookerSDKStream(authSession: AuthSession) : APIMethods(authSession) { } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * @param {String} fields Requested fields. + * @param {Long} limit Number of results to return (used with `offset`). + * @param {Long} offset Number of results to skip before returning any (used with `limit`). + * @param {String} sorts Fields to sort by. + * @param {Long} id Match role id. + * @param {String} name Match role name. + * @param {Boolean} built_in Match roles by built_in status. + * @param {Boolean} filter_or Combine given search criteria in a boolean OR expression. + * + * GET /roles/search/with_user_count -> ByteArray + */ + @JvmOverloads fun search_roles_with_user_count( + fields: String? = null, + limit: Long? = null, + offset: Long? = null, + sorts: String? = null, + id: Long? = null, + name: String? = null, + built_in: Boolean? = null, + filter_or: Boolean? = null + ) : SDKResponse { + return this.get("/roles/search/with_user_count", + mapOf("fields" to fields, + "limit" to limit, + "offset" to offset, + "sorts" to sorts, + "id" to id, + "name" to name, + "built_in" to built_in, + "filter_or" to filter_or)) + } + + /** * ### Get information about the role with a specific id. * diff --git a/kotlin/src/main/com/looker/sdk/Constants.kt b/kotlin/src/main/com/looker/sdk/Constants.kt index 2ed57217f..24475ad2e 100644 --- a/kotlin/src/main/com/looker/sdk/Constants.kt +++ b/kotlin/src/main/com/looker/sdk/Constants.kt @@ -28,7 +28,7 @@ package com.looker.sdk const val ENVIRONMENT_PREFIX = "LOOKERSDK" const val SDK_TAG = "KT-SDK" -const val LOOKER_VERSION = "21.8" +const val LOOKER_VERSION = "21.10" const val API_VERSION = "4.0" const val AGENT_TAG = "$SDK_TAG $LOOKER_VERSION" const val LOOKER_APPID = "x-looker-appid" diff --git a/packages/sdk/src/3.1/models.ts b/packages/sdk/src/3.1/models.ts index 961000ba2..2739eeadb 100644 --- a/packages/sdk/src/3.1/models.ts +++ b/packages/sdk/src/3.1/models.ts @@ -497,6 +497,10 @@ export interface IContentValidationLook { * Look Title */ title?: string + /** + * Short Url (read-only) + */ + short_url?: string folder?: IContentValidationFolder space?: IContentValidationSpace } @@ -1180,6 +1184,10 @@ export interface IDashboard { */ preferred_viewer?: string space?: ISpaceBase + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + alert_sync_with_dashboard_filter_enabled?: boolean /** * Background color */ @@ -1723,7 +1731,7 @@ export interface IDataActionRequest { /** * The JSON describing the data action. This JSON should be considered opaque and should be passed through unmodified from the query result it came from. */ - action?: IDictionary + action?: IDictionary /** * User input for any form values the data action might use. */ @@ -9194,6 +9202,10 @@ export interface IWriteDashboard { */ preferred_viewer?: string space?: IWriteSpaceBase + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + alert_sync_with_dashboard_filter_enabled?: boolean /** * Background color */ diff --git a/packages/sdk/src/4.0/funcs.ts b/packages/sdk/src/4.0/funcs.ts index 79c547d2f..6ed10d33c 100644 --- a/packages/sdk/src/4.0/funcs.ts +++ b/packages/sdk/src/4.0/funcs.ts @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ import type { @@ -197,6 +197,7 @@ import type { IRequestUserAttributeUserValues, IRequestUserRoles, IRole, + IRoleSearch, IRunningQueries, ISamlConfig, ISamlMetadataParseResult, @@ -2982,6 +2983,8 @@ export const all_dialect_infos = async ( /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> IExternalOauthApplication[] * * @param sdk IAPIMethods implementation @@ -3005,6 +3008,8 @@ export const all_external_oauth_applications = async ( /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> IExternalOauthApplication * * @param sdk IAPIMethods implementation @@ -9099,6 +9104,62 @@ export const search_roles = async ( ) } +/** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> IRoleSearch[] + * + * @param sdk IAPIMethods implementation + * @param request composed interface "IRequestSearchRoles" for complex method parameters + * @param options one-time API call overrides + * + */ +export const search_roles_with_user_count = async ( + sdk: IAPIMethods, + request: IRequestSearchRoles, + options?: Partial +): Promise> => { + return sdk.get( + '/roles/search/with_user_count', + { + fields: request.fields, + limit: request.limit, + offset: request.offset, + sorts: request.sorts, + id: request.id, + name: request.name, + built_in: request.built_in, + filter_or: request.filter_or, + }, + null, + options + ) +} + /** * ### Get information about the role with a specific id. * diff --git a/packages/sdk/src/4.0/methods.ts b/packages/sdk/src/4.0/methods.ts index e1c5ff13a..a345bab46 100644 --- a/packages/sdk/src/4.0/methods.ts +++ b/packages/sdk/src/4.0/methods.ts @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ import type { @@ -195,6 +195,7 @@ import type { IRequestUserAttributeUserValues, IRequestUserRoles, IRole, + IRoleSearch, IRunningQueries, ISamlConfig, ISamlMetadataParseResult, @@ -2793,6 +2794,8 @@ export class Looker40SDK extends APIMethods implements ILooker40SDK { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> IExternalOauthApplication[] * * @param request composed interface "IRequestAllExternalOauthApplications" for complex method parameters @@ -2814,6 +2817,8 @@ export class Looker40SDK extends APIMethods implements ILooker40SDK { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> IExternalOauthApplication * * @param body Partial @@ -8535,6 +8540,60 @@ export class Looker40SDK extends APIMethods implements ILooker40SDK { ) } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> IRoleSearch[] + * + * @param request composed interface "IRequestSearchRoles" for complex method parameters + * @param options one-time API call overrides + * + */ + async search_roles_with_user_count( + request: IRequestSearchRoles, + options?: Partial + ): Promise> { + return this.get( + '/roles/search/with_user_count', + { + fields: request.fields, + limit: request.limit, + offset: request.offset, + sorts: request.sorts, + id: request.id, + name: request.name, + built_in: request.built_in, + filter_or: request.filter_or, + }, + null, + options + ) + } + /** * ### Get information about the role with a specific id. * diff --git a/packages/sdk/src/4.0/methodsInterface.ts b/packages/sdk/src/4.0/methodsInterface.ts index d1f27bb8d..c54b93144 100644 --- a/packages/sdk/src/4.0/methodsInterface.ts +++ b/packages/sdk/src/4.0/methodsInterface.ts @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ import type { @@ -191,6 +191,7 @@ import type { IRequestUserAttributeUserValues, IRequestUserRoles, IRole, + IRoleSearch, IRunningQueries, ISamlConfig, ISamlMetadataParseResult, @@ -2067,6 +2068,8 @@ export interface ILooker40SDK { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> IExternalOauthApplication[] * * @param request composed interface "IRequestAllExternalOauthApplications" for complex method parameters @@ -2081,6 +2084,8 @@ export interface ILooker40SDK { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> IExternalOauthApplication * * @param body Partial @@ -6051,6 +6056,44 @@ export interface ILooker40SDK { options?: Partial ): Promise> + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> IRoleSearch[] + * + * @param request composed interface "IRequestSearchRoles" for complex method parameters + * @param options one-time API call overrides + * + */ + search_roles_with_user_count( + request: IRequestSearchRoles, + options?: Partial + ): Promise> + /** * ### Get information about the role with a specific id. * diff --git a/packages/sdk/src/4.0/models.ts b/packages/sdk/src/4.0/models.ts index 4e43f397a..f955e20f1 100644 --- a/packages/sdk/src/4.0/models.ts +++ b/packages/sdk/src/4.0/models.ts @@ -25,7 +25,7 @@ */ /** - * 334 API models: 210 Spec, 51 Request, 56 Write, 17 Enum + * 335 API models: 211 Spec, 51 Request, 56 Write, 17 Enum */ import type { IDictionary, DelimArray } from '@looker/sdk-rtl' @@ -639,6 +639,10 @@ export interface IContentValidationDashboard { * Dashboard Title */ title?: string + /** + * Relative URL of the dashboard (read-only) + */ + url?: string } export interface IContentValidationDashboardElement { @@ -782,6 +786,10 @@ export interface IContentValidationLook { * Look Title */ title?: string + /** + * Short Url (read-only) + */ + short_url?: string folder?: IContentValidationFolder } @@ -1490,6 +1498,10 @@ export interface IDashboard { * The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) */ preferred_viewer?: string + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + alert_sync_with_dashboard_filter_enabled?: boolean /** * Background color */ @@ -1583,6 +1595,10 @@ export interface IDashboard { */ view_count?: number appearance?: IDashboardAppearance + /** + * Relative URL of the dashboard (read-only) + */ + url?: string } export interface IDashboardAggregateTableLookml { @@ -2028,7 +2044,7 @@ export interface IDataActionRequest { /** * The JSON describing the data action. This JSON should be considered opaque and should be passed through unmodified from the query result it came from. */ - action?: IDictionary + action?: IDictionary /** * User input for any form values the data action might use. */ @@ -7995,7 +8011,40 @@ export interface IRole { */ model_set_id?: number /** - * Count of users with this role, only returned if user_count field is requested (read-only) + * Link to get this item (read-only) + */ + url?: string + /** + * Link to get list of users with this role (read-only) + */ + users_url?: string +} + +export interface IRoleSearch { + /** + * Operations the current user is able to perform on this object (read-only) + */ + can?: IDictionary + /** + * Unique Id (read-only) + */ + id?: number + /** + * Name of Role + */ + name?: string + permission_set?: IPermissionSet + /** + * (Write-Only) Id of permission set + */ + permission_set_id?: number + model_set?: IModelSet + /** + * (Write-Only) Id of model set + */ + model_set_id?: number + /** + * Count of users with this role (read-only) */ user_count?: number /** @@ -9888,7 +9937,7 @@ export interface IWriteCustomWelcomeEmail { /** * Dynamically generated writeable type for Dashboard removes properties: - * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count + * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url */ export interface IWriteDashboard { /** @@ -9920,6 +9969,10 @@ export interface IWriteDashboard { * The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) */ preferred_viewer?: string + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + alert_sync_with_dashboard_filter_enabled?: boolean /** * Background color */ @@ -11112,7 +11165,7 @@ export interface IWriteResultMakerWithIdVisConfigAndDynamicFields { /** * Dynamically generated writeable type for Role removes properties: - * can, id, user_count, url, users_url + * can, id, url, users_url */ export interface IWriteRole { /** diff --git a/packages/sdk/src/4.0/streams.ts b/packages/sdk/src/4.0/streams.ts index ec636f20f..8aa54656a 100644 --- a/packages/sdk/src/4.0/streams.ts +++ b/packages/sdk/src/4.0/streams.ts @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ import { Readable } from 'readable-stream' @@ -194,6 +194,7 @@ import type { IRequestUserAttributeUserValues, IRequestUserRoles, IRole, + IRoleSearch, IRunningQueries, ISamlConfig, ISamlMetadataParseResult, @@ -3224,6 +3225,8 @@ export class Looker40SDKStream extends APIMethods { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> IExternalOauthApplication[] * * @param callback streaming output function @@ -3249,6 +3252,8 @@ export class Looker40SDKStream extends APIMethods { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> IExternalOauthApplication * * @param callback streaming output function @@ -9795,6 +9800,64 @@ export class Looker40SDKStream extends APIMethods { ) } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> IRoleSearch[] + * + * @param callback streaming output function + * @param request composed interface "IRequestSearchRoles" for complex method parameters + * @param options one-time API call overrides + * + */ + async search_roles_with_user_count( + callback: (readable: Readable) => Promise, + request: IRequestSearchRoles, + options?: Partial + ) { + return this.authStream( + callback, + 'GET', + '/roles/search/with_user_count', + { + fields: request.fields, + limit: request.limit, + offset: request.offset, + sorts: request.sorts, + id: request.id, + name: request.name, + built_in: request.built_in, + filter_or: request.filter_or, + }, + null, + options + ) + } + /** * ### Get information about the role with a specific id. * diff --git a/packages/sdk/src/constants.ts b/packages/sdk/src/constants.ts index 2ff0fc8f6..48c9c06da 100644 --- a/packages/sdk/src/constants.ts +++ b/packages/sdk/src/constants.ts @@ -24,5 +24,5 @@ */ -export const sdkVersion = '21.8' +export const sdkVersion = '21.10' export const environmentPrefix = 'LOOKERSDK' diff --git a/python/looker_sdk/sdk/api31/models.py b/python/looker_sdk/sdk/api31/models.py index 3a31a455e..bcf4da9fc 100644 --- a/python/looker_sdk/sdk/api31/models.py +++ b/python/looker_sdk/sdk/api31/models.py @@ -692,12 +692,14 @@ class ContentValidationLook(model.Model): Attributes: id: Unique Id title: Look Title + short_url: Short Url folder: space: """ id: Optional[int] = None title: Optional[str] = None + short_url: Optional[str] = None folder: Optional["ContentValidationFolder"] = None space: Optional["ContentValidationSpace"] = None @@ -706,11 +708,13 @@ def __init__( *, id: Optional[int] = None, title: Optional[str] = None, + short_url: Optional[str] = None, folder: Optional["ContentValidationFolder"] = None, space: Optional["ContentValidationSpace"] = None ): self.id = id self.title = title + self.short_url = short_url self.folder = folder self.space = space @@ -1595,6 +1599,7 @@ class Dashboard(model.Model): slug: Content Metadata Slug preferred_viewer: The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) space: + alert_sync_with_dashboard_filter_enabled: Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) background_color: Background color created_at: Time that the Dashboard was created. crossfilter_enabled: Enables crossfiltering in dashboards - only available in dashboards-next (beta) @@ -1639,6 +1644,7 @@ class Dashboard(model.Model): slug: Optional[str] = None preferred_viewer: Optional[str] = None space: Optional["SpaceBase"] = None + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None background_color: Optional[str] = None created_at: Optional[datetime.datetime] = None crossfilter_enabled: Optional[bool] = None @@ -1685,6 +1691,7 @@ def __init__( slug: Optional[str] = None, preferred_viewer: Optional[str] = None, space: Optional["SpaceBase"] = None, + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None, background_color: Optional[str] = None, created_at: Optional[datetime.datetime] = None, crossfilter_enabled: Optional[bool] = None, @@ -1728,6 +1735,9 @@ def __init__( self.slug = slug self.preferred_viewer = preferred_viewer self.space = space + self.alert_sync_with_dashboard_filter_enabled = ( + alert_sync_with_dashboard_filter_enabled + ) self.background_color = background_color self.created_at = created_at self.crossfilter_enabled = crossfilter_enabled @@ -9755,6 +9765,7 @@ class WriteDashboard(model.Model): slug: Content Metadata Slug preferred_viewer: The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) space: + alert_sync_with_dashboard_filter_enabled: Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) background_color: Background color crossfilter_enabled: Enables crossfiltering in dashboards - only available in dashboards-next (beta) deleted: Whether or not a dashboard is 'soft' deleted. @@ -9780,6 +9791,7 @@ class WriteDashboard(model.Model): slug: Optional[str] = None preferred_viewer: Optional[str] = None space: Optional["WriteSpaceBase"] = None + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None background_color: Optional[str] = None crossfilter_enabled: Optional[bool] = None deleted: Optional[bool] = None @@ -9807,6 +9819,7 @@ def __init__( slug: Optional[str] = None, preferred_viewer: Optional[str] = None, space: Optional["WriteSpaceBase"] = None, + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None, background_color: Optional[str] = None, crossfilter_enabled: Optional[bool] = None, deleted: Optional[bool] = None, @@ -9831,6 +9844,9 @@ def __init__( self.slug = slug self.preferred_viewer = preferred_viewer self.space = space + self.alert_sync_with_dashboard_filter_enabled = ( + alert_sync_with_dashboard_filter_enabled + ) self.background_color = background_color self.crossfilter_enabled = crossfilter_enabled self.deleted = deleted diff --git a/python/looker_sdk/sdk/api40/methods.py b/python/looker_sdk/sdk/api40/methods.py index 989031e30..59519f1e8 100644 --- a/python/looker_sdk/sdk/api40/methods.py +++ b/python/looker_sdk/sdk/api40/methods.py @@ -21,7 +21,7 @@ # SOFTWARE. # -# 412 API methods +# 413 API methods # NOTE: Do not edit this file generated by Looker SDK Codegen for API 4.0 @@ -2547,6 +2547,8 @@ def all_dialect_infos( # ### Get all External OAuth Applications. # + # This is an OAuth Application which Looker uses to access external systems. + # # GET /external_oauth_applications -> Sequence[models.ExternalOauthApplication] def all_external_oauth_applications( self, @@ -2556,7 +2558,7 @@ def all_external_oauth_applications( client_id: Optional[str] = None, transport_options: Optional[transport.TransportOptions] = None, ) -> Sequence[models.ExternalOauthApplication]: - """Get All External OAuth Application. This is an OAuth Application which Looker uses to access external systems.s""" + """Get All External OAuth Applications""" response = cast( Sequence[models.ExternalOauthApplication], self.get( @@ -2570,13 +2572,15 @@ def all_external_oauth_applications( # ### Create an OAuth Application using the specified configuration. # + # This is an OAuth Application which Looker uses to access external systems. + # # POST /external_oauth_applications -> models.ExternalOauthApplication def create_external_oauth_application( self, body: models.WriteExternalOauthApplication, transport_options: Optional[transport.TransportOptions] = None, ) -> models.ExternalOauthApplication: - """Create External OAuth Application. This is an OAuth Application which Looker uses to access external systems.""" + """Create External OAuth Application""" response = cast( models.ExternalOauthApplication, self.post( @@ -8693,6 +8697,74 @@ def search_roles( ) return response + # ### Search roles include user count + # + # Returns all role records that match the given search criteria, and attaches + # associated user counts. + # + # If multiple search params are given and `filter_or` is FALSE or not specified, + # search params are combined in a logical AND operation. + # Only rows that match *all* search param criteria will be returned. + # + # If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + # Results will include rows that match **any** of the search criteria. + # + # String search params use case-insensitive matching. + # String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + # example="dan%" will match "danger" and "Danzig" but not "David" + # example="D_m%" will match "Damage" and "dump" + # + # Integer search params can accept a single value or a comma separated list of values. The multiple + # values will be combined under a logical OR operation - results will match at least one of + # the given values. + # + # Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + # or exclude (respectively) rows where the column is null. + # + # Boolean search params accept only "true" and "false" as values. + # + # GET /roles/search/with_user_count -> Sequence[models.RoleSearch] + def search_roles_with_user_count( + self, + # Requested fields. + fields: Optional[str] = None, + # Number of results to return (used with `offset`). + limit: Optional[int] = None, + # Number of results to skip before returning any (used with `limit`). + offset: Optional[int] = None, + # Fields to sort by. + sorts: Optional[str] = None, + # Match role id. + id: Optional[int] = None, + # Match role name. + name: Optional[str] = None, + # Match roles by built_in status. + built_in: Optional[bool] = None, + # Combine given search criteria in a boolean OR expression. + filter_or: Optional[bool] = None, + transport_options: Optional[transport.TransportOptions] = None, + ) -> Sequence[models.RoleSearch]: + """Search Roles with User Count""" + response = cast( + Sequence[models.RoleSearch], + self.get( + path="/roles/search/with_user_count", + structure=Sequence[models.RoleSearch], + query_params={ + "fields": fields, + "limit": limit, + "offset": offset, + "sorts": sorts, + "id": id, + "name": name, + "built_in": built_in, + "filter_or": filter_or, + }, + transport_options=transport_options, + ), + ) + return response + # ### Get information about the role with a specific id. # # GET /roles/{role_id} -> models.Role diff --git a/python/looker_sdk/sdk/api40/models.py b/python/looker_sdk/sdk/api40/models.py index 523e87186..32d7d2890 100644 --- a/python/looker_sdk/sdk/api40/models.py +++ b/python/looker_sdk/sdk/api40/models.py @@ -21,7 +21,7 @@ # SOFTWARE. # -# 283 API models: 210 Spec, 0 Request, 56 Write, 17 Enum +# 284 API models: 211 Spec, 0 Request, 56 Write, 17 Enum # NOTE: Do not edit this file generated by Looker SDK Codegen for API 4.0 @@ -840,12 +840,14 @@ class ContentValidationDashboard(model.Model): id: Unique Id folder: title: Dashboard Title + url: Relative URL of the dashboard """ description: Optional[str] = None id: Optional[str] = None folder: Optional["ContentValidationFolder"] = None title: Optional[str] = None + url: Optional[str] = None def __init__( self, @@ -853,12 +855,14 @@ def __init__( description: Optional[str] = None, id: Optional[str] = None, folder: Optional["ContentValidationFolder"] = None, - title: Optional[str] = None + title: Optional[str] = None, + url: Optional[str] = None ): self.description = description self.id = id self.folder = folder self.title = title + self.url = url @attr.s(auto_attribs=True, init=False) @@ -1034,11 +1038,13 @@ class ContentValidationLook(model.Model): Attributes: id: Unique Id title: Look Title + short_url: Short Url folder: """ id: Optional[int] = None title: Optional[str] = None + short_url: Optional[str] = None folder: Optional["ContentValidationFolder"] = None def __init__( @@ -1046,10 +1052,12 @@ def __init__( *, id: Optional[int] = None, title: Optional[str] = None, + short_url: Optional[str] = None, folder: Optional["ContentValidationFolder"] = None ): self.id = id self.title = title + self.short_url = short_url self.folder = folder @@ -2004,6 +2012,7 @@ class Dashboard(model.Model): user_id: Id of User slug: Content Metadata Slug preferred_viewer: The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + alert_sync_with_dashboard_filter_enabled: Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) background_color: Background color created_at: Time that the Dashboard was created. crossfilter_enabled: Enables crossfiltering in dashboards - only available in dashboards-next (beta) @@ -2028,6 +2037,7 @@ class Dashboard(model.Model): title_color: Title color view_count: Number of times viewed in the Looker web UI appearance: + url: Relative URL of the dashboard """ can: Optional[MutableMapping[str, bool]] = None @@ -2046,6 +2056,7 @@ class Dashboard(model.Model): user_id: Optional[int] = None slug: Optional[str] = None preferred_viewer: Optional[str] = None + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None background_color: Optional[str] = None created_at: Optional[datetime.datetime] = None crossfilter_enabled: Optional[bool] = None @@ -2070,6 +2081,7 @@ class Dashboard(model.Model): title_color: Optional[str] = None view_count: Optional[int] = None appearance: Optional["DashboardAppearance"] = None + url: Optional[str] = None def __init__( self, @@ -2090,6 +2102,7 @@ def __init__( user_id: Optional[int] = None, slug: Optional[str] = None, preferred_viewer: Optional[str] = None, + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None, background_color: Optional[str] = None, created_at: Optional[datetime.datetime] = None, crossfilter_enabled: Optional[bool] = None, @@ -2113,7 +2126,8 @@ def __init__( tile_text_color: Optional[str] = None, title_color: Optional[str] = None, view_count: Optional[int] = None, - appearance: Optional["DashboardAppearance"] = None + appearance: Optional["DashboardAppearance"] = None, + url: Optional[str] = None ): self.can = can self.content_favorite_id = content_favorite_id @@ -2131,6 +2145,9 @@ def __init__( self.user_id = user_id self.slug = slug self.preferred_viewer = preferred_viewer + self.alert_sync_with_dashboard_filter_enabled = ( + alert_sync_with_dashboard_filter_enabled + ) self.background_color = background_color self.created_at = created_at self.crossfilter_enabled = crossfilter_enabled @@ -2155,6 +2172,7 @@ def __init__( self.title_color = title_color self.view_count = view_count self.appearance = appearance + self.url = url @attr.s(auto_attribs=True, init=False) @@ -8125,7 +8143,56 @@ class Role(model.Model): permission_set_id: (Write-Only) Id of permission set model_set: model_set_id: (Write-Only) Id of model set - user_count: Count of users with this role, only returned if user_count field is requested + url: Link to get this item + users_url: Link to get list of users with this role + """ + + can: Optional[MutableMapping[str, bool]] = None + id: Optional[int] = None + name: Optional[str] = None + permission_set: Optional["PermissionSet"] = None + permission_set_id: Optional[int] = None + model_set: Optional["ModelSet"] = None + model_set_id: Optional[int] = None + url: Optional[str] = None + users_url: Optional[str] = None + + def __init__( + self, + *, + can: Optional[MutableMapping[str, bool]] = None, + id: Optional[int] = None, + name: Optional[str] = None, + permission_set: Optional["PermissionSet"] = None, + permission_set_id: Optional[int] = None, + model_set: Optional["ModelSet"] = None, + model_set_id: Optional[int] = None, + url: Optional[str] = None, + users_url: Optional[str] = None + ): + self.can = can + self.id = id + self.name = name + self.permission_set = permission_set + self.permission_set_id = permission_set_id + self.model_set = model_set + self.model_set_id = model_set_id + self.url = url + self.users_url = users_url + + +@attr.s(auto_attribs=True, init=False) +class RoleSearch(model.Model): + """ + Attributes: + can: Operations the current user is able to perform on this object + id: Unique Id + name: Name of Role + permission_set: + permission_set_id: (Write-Only) Id of permission set + model_set: + model_set_id: (Write-Only) Id of model set + user_count: Count of users with this role url: Link to get this item users_url: Link to get list of users with this role """ @@ -10633,7 +10700,7 @@ def __init__( class WriteDashboard(model.Model): """ Dynamically generated writeable type for Dashboard removes properties: -can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count +can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url Attributes: description: Description @@ -10644,6 +10711,7 @@ class WriteDashboard(model.Model): title: Dashboard Title slug: Content Metadata Slug preferred_viewer: The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) + alert_sync_with_dashboard_filter_enabled: Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) background_color: Background color crossfilter_enabled: Enables crossfiltering in dashboards - only available in dashboards-next (beta) deleted: Whether or not a dashboard is 'soft' deleted. @@ -10667,6 +10735,7 @@ class WriteDashboard(model.Model): title: Optional[str] = None slug: Optional[str] = None preferred_viewer: Optional[str] = None + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None background_color: Optional[str] = None crossfilter_enabled: Optional[bool] = None deleted: Optional[bool] = None @@ -10692,6 +10761,7 @@ def __init__( title: Optional[str] = None, slug: Optional[str] = None, preferred_viewer: Optional[str] = None, + alert_sync_with_dashboard_filter_enabled: Optional[bool] = None, background_color: Optional[str] = None, crossfilter_enabled: Optional[bool] = None, deleted: Optional[bool] = None, @@ -10714,6 +10784,9 @@ def __init__( self.title = title self.slug = slug self.preferred_viewer = preferred_viewer + self.alert_sync_with_dashboard_filter_enabled = ( + alert_sync_with_dashboard_filter_enabled + ) self.background_color = background_color self.crossfilter_enabled = crossfilter_enabled self.deleted = deleted @@ -12141,7 +12214,7 @@ def __init__(self, *, query: Optional["WriteQuery"] = None): class WriteRole(model.Model): """ Dynamically generated writeable type for Role removes properties: -can, id, user_count, url, users_url +can, id, url, users_url Attributes: name: Name of Role @@ -13459,6 +13532,10 @@ def __init__( ForwardRef("Role"), # type: ignore forward_ref_structure_hook, # type:ignore ) +sr.converter40.register_structure_hook( + ForwardRef("RoleSearch"), # type: ignore + forward_ref_structure_hook, # type:ignore +) sr.converter40.register_structure_hook( ForwardRef("RunningQueries"), # type: ignore forward_ref_structure_hook, # type:ignore diff --git a/python/looker_sdk/sdk/constants.py b/python/looker_sdk/sdk/constants.py index 4238dddc9..dab4b97f6 100644 --- a/python/looker_sdk/sdk/constants.py +++ b/python/looker_sdk/sdk/constants.py @@ -20,5 +20,5 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -sdk_version = "21.8" +sdk_version = "21.10" environment_prefix = "LOOKERSDK" diff --git a/release-please-config.json b/release-please-config.json index c3d70de3a..266ee766a 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -2,6 +2,7 @@ "plugins": ["node-workspace"], "bump-minor-pre-major": true, "bump-patch-for-minor-pre-major": true, + "release-as": "21.10.0", "packages": { ".": { "release-as": "" }, "packages/api-explorer": { "release-as": "" }, @@ -12,11 +13,11 @@ "packages/hackathon": { }, "packages/run-it": { "release-as": "" }, "packages/sdk": { }, - "packages/sdk-codegen": { "release-as": "21.0.20" }, - "packages/sdk-codegen-scripts": { "release-as": "21.0.21" }, - "packages/sdk-codegen-utils": { "release-as": "21.0.13"}, + "packages/sdk-codegen": { "release-as": "21.0.21" }, + "packages/sdk-codegen-scripts": { "release-as": "21.0.22" }, + "packages/sdk-codegen-utils": { "release-as": "21.0.12"}, "packages/sdk-node": { }, - "packages/sdk-rtl": { "release-as": "21.0.16" }, + "packages/sdk-rtl": { "release-as": "21.0.17" }, "packages/wholly-sheet": { "release-as": "" }, "python": { "release-type": "python", "package-name": "looker_sdk" } } diff --git a/swift/looker/rtl/constants.swift b/swift/looker/rtl/constants.swift index 3040e2330..88d0c638d 100644 --- a/swift/looker/rtl/constants.swift +++ b/swift/looker/rtl/constants.swift @@ -49,7 +49,7 @@ extension String { } public struct Constants { - public static let lookerVersion = "21.8" + public static let lookerVersion = "21.10" public static let apiVersion = "4.0" public static let defaultApiVersion = "4.0" // Swift requires API 4.0 public static let sdkVersion = #"\#(apiVersion).\#(lookerVersion)"# diff --git a/swift/looker/sdk/methods.swift b/swift/looker/sdk/methods.swift index 1bf26cb1a..65a47b22e 100644 --- a/swift/looker/sdk/methods.swift +++ b/swift/looker/sdk/methods.swift @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ @@ -2239,6 +2239,8 @@ open class LookerSDK: APIMethods { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> [ExternalOauthApplication] */ public func all_external_oauth_applications( @@ -2260,6 +2262,8 @@ open class LookerSDK: APIMethods { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> ExternalOauthApplication */ public func create_external_oauth_application( @@ -8097,6 +8101,75 @@ open class LookerSDK: APIMethods { return result } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> [RoleSearch] + */ + public func search_roles_with_user_count( + /** + * @param {String} fields Requested fields. + */ + fields: String? = nil, + /** + * @param {Int64} limit Number of results to return (used with `offset`). + */ + limit: Int64? = nil, + /** + * @param {Int64} offset Number of results to skip before returning any (used with `limit`). + */ + offset: Int64? = nil, + /** + * @param {String} sorts Fields to sort by. + */ + sorts: String? = nil, + /** + * @param {Int64} id Match role id. + */ + id: Int64? = nil, + /** + * @param {String} name Match role name. + */ + name: String? = nil, + /** + * @param {Bool} built_in Match roles by built_in status. + */ + built_in: Bool? = nil, + /** + * @param {Bool} filter_or Combine given search criteria in a boolean OR expression. + */ + filter_or: Bool? = nil, + options: ITransportSettings? = nil + ) -> SDKResponse<[RoleSearch], SDKError> { + let result: SDKResponse<[RoleSearch], SDKError> = self.get("/roles/search/with_user_count", + ["fields": fields, "limit": limit, "offset": offset, "sorts": sorts, "id": id, "name": name, "built_in": built_in as Any?, "filter_or": filter_or as Any?], nil, options) + return result + } + /** * ### Get information about the role with a specific id. * diff --git a/swift/looker/sdk/models.swift b/swift/looker/sdk/models.swift index 4d09e0eed..b41c32c37 100644 --- a/swift/looker/sdk/models.swift +++ b/swift/looker/sdk/models.swift @@ -25,7 +25,7 @@ */ /** - * 283 API models: 210 Spec, 0 Request, 56 Write, 17 Enum + * 284 API models: 211 Spec, 0 Request, 56 Write, 17 Enum */ @@ -842,12 +842,17 @@ public struct ContentValidationDashboard: SDKModel { * Dashboard Title */ public var title: String? + /** + * Relative URL of the dashboard (read-only) + */ + public var url: String? - public init(description: String? = nil, id: String? = nil, folder: ContentValidationFolder? = nil, title: String? = nil) { + public init(description: String? = nil, id: String? = nil, folder: ContentValidationFolder? = nil, title: String? = nil, url: String? = nil) { self.description = description self.id = id self.folder = folder self.title = title + self.url = url } } @@ -1043,11 +1048,16 @@ public struct ContentValidationLook: SDKModel { * Look Title */ public var title: String? + /** + * Short Url (read-only) + */ + public var short_url: String? public var folder: ContentValidationFolder? - public init(id: Int64? = nil, title: String? = nil, folder: ContentValidationFolder? = nil) { + public init(id: Int64? = nil, title: String? = nil, short_url: String? = nil, folder: ContentValidationFolder? = nil) { self.id = id self.title = title + self.short_url = short_url self.folder = folder } @@ -2036,6 +2046,10 @@ public struct Dashboard: SDKModel { * The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) */ public var preferred_viewer: String? + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + public var alert_sync_with_dashboard_filter_enabled: Bool? /** * Background color */ @@ -2129,8 +2143,12 @@ public struct Dashboard: SDKModel { */ public var view_count: Int64? public var appearance: DashboardAppearance? + /** + * Relative URL of the dashboard (read-only) + */ + public var url: String? - public init(can: StringDictionary? = nil, content_favorite_id: Int64? = nil, content_metadata_id: Int64? = nil, description: String? = nil, hidden: Bool? = nil, id: String? = nil, model: LookModel? = nil, query_timezone: String? = nil, readonly: Bool? = nil, refresh_interval: String? = nil, refresh_interval_to_i: Int64? = nil, folder: FolderBase? = nil, title: String? = nil, user_id: Int64? = nil, slug: String? = nil, preferred_viewer: String? = nil, background_color: String? = nil, created_at: Date? = nil, crossfilter_enabled: Bool? = nil, dashboard_elements: [DashboardElement]? = nil, dashboard_filters: [DashboardFilter]? = nil, dashboard_layouts: [DashboardLayout]? = nil, deleted: Bool? = nil, deleted_at: Date? = nil, deleter_id: Int64? = nil, edit_uri: String? = nil, favorite_count: Int64? = nil, last_accessed_at: Date? = nil, last_viewed_at: Date? = nil, load_configuration: String? = nil, lookml_link_id: String? = nil, show_filters_bar: Bool? = nil, show_title: Bool? = nil, folder_id: String? = nil, text_tile_text_color: String? = nil, tile_background_color: String? = nil, tile_text_color: String? = nil, title_color: String? = nil, view_count: Int64? = nil, appearance: DashboardAppearance? = nil) { + public init(can: StringDictionary? = nil, content_favorite_id: Int64? = nil, content_metadata_id: Int64? = nil, description: String? = nil, hidden: Bool? = nil, id: String? = nil, model: LookModel? = nil, query_timezone: String? = nil, readonly: Bool? = nil, refresh_interval: String? = nil, refresh_interval_to_i: Int64? = nil, folder: FolderBase? = nil, title: String? = nil, user_id: Int64? = nil, slug: String? = nil, preferred_viewer: String? = nil, alert_sync_with_dashboard_filter_enabled: Bool? = nil, background_color: String? = nil, created_at: Date? = nil, crossfilter_enabled: Bool? = nil, dashboard_elements: [DashboardElement]? = nil, dashboard_filters: [DashboardFilter]? = nil, dashboard_layouts: [DashboardLayout]? = nil, deleted: Bool? = nil, deleted_at: Date? = nil, deleter_id: Int64? = nil, edit_uri: String? = nil, favorite_count: Int64? = nil, last_accessed_at: Date? = nil, last_viewed_at: Date? = nil, load_configuration: String? = nil, lookml_link_id: String? = nil, show_filters_bar: Bool? = nil, show_title: Bool? = nil, folder_id: String? = nil, text_tile_text_color: String? = nil, tile_background_color: String? = nil, tile_text_color: String? = nil, title_color: String? = nil, view_count: Int64? = nil, appearance: DashboardAppearance? = nil, url: String? = nil) { self.can = can self.content_favorite_id = content_favorite_id self.content_metadata_id = content_metadata_id @@ -2147,6 +2165,7 @@ public struct Dashboard: SDKModel { self.user_id = user_id self.slug = slug self.preferred_viewer = preferred_viewer + self.alert_sync_with_dashboard_filter_enabled = alert_sync_with_dashboard_filter_enabled self.background_color = background_color self.created_at = created_at self.crossfilter_enabled = crossfilter_enabled @@ -2171,6 +2190,7 @@ public struct Dashboard: SDKModel { self.title_color = title_color self.view_count = view_count self.appearance = appearance + self.url = url } } @@ -8462,7 +8482,53 @@ public struct Role: SDKModel { */ public var model_set_id: Int64? /** - * Count of users with this role, only returned if user_count field is requested (read-only) + * Link to get this item (read-only) + */ + public var url: String? + /** + * Link to get list of users with this role (read-only) + */ + public var users_url: String? + + public init(can: StringDictionary? = nil, id: Int64? = nil, name: String? = nil, permission_set: PermissionSet? = nil, permission_set_id: Int64? = nil, model_set: ModelSet? = nil, model_set_id: Int64? = nil, url: String? = nil, users_url: String? = nil) { + self.can = can + self.id = id + self.name = name + self.permission_set = permission_set + self.permission_set_id = permission_set_id + self.model_set = model_set + self.model_set_id = model_set_id + self.url = url + self.users_url = users_url + } + +} + +public struct RoleSearch: SDKModel { + /** + * Operations the current user is able to perform on this object (read-only) + */ + public var can: StringDictionary? + /** + * Unique Id (read-only) + */ + public var id: Int64? + /** + * Name of Role + */ + public var name: String? + public var permission_set: PermissionSet? + /** + * (Write-Only) Id of permission set + */ + public var permission_set_id: Int64? + public var model_set: ModelSet? + /** + * (Write-Only) Id of model set + */ + public var model_set_id: Int64? + /** + * Count of users with this role (read-only) */ public var user_count: Int64? /** @@ -11004,7 +11070,7 @@ public struct WriteCustomWelcomeEmail: SDKModel { /** * Dynamically generated writeable type for Dashboard removes properties: - * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count + * can, content_favorite_id, content_metadata_id, id, model, readonly, refresh_interval_to_i, user_id, created_at, dashboard_elements, dashboard_filters, dashboard_layouts, deleted_at, deleter_id, edit_uri, favorite_count, last_accessed_at, last_viewed_at, view_count, url */ public struct WriteDashboard: SDKModel { /** @@ -11036,6 +11102,10 @@ public struct WriteDashboard: SDKModel { * The preferred route for viewing this dashboard (ie: dashboards or dashboards-next) */ public var preferred_viewer: String? + /** + * Enables alerts to keep in sync with dashboard filter changes - only available in alerts 2.0 (beta) + */ + public var alert_sync_with_dashboard_filter_enabled: Bool? /** * Background color */ @@ -11086,7 +11156,7 @@ public struct WriteDashboard: SDKModel { public var title_color: String? public var appearance: DashboardAppearance? - public init(description: String? = nil, hidden: Bool? = nil, query_timezone: String? = nil, refresh_interval: String? = nil, folder: WriteFolderBase? = nil, title: String? = nil, slug: String? = nil, preferred_viewer: String? = nil, background_color: String? = nil, crossfilter_enabled: Bool? = nil, deleted: Bool? = nil, load_configuration: String? = nil, lookml_link_id: String? = nil, show_filters_bar: Bool? = nil, show_title: Bool? = nil, folder_id: String? = nil, text_tile_text_color: String? = nil, tile_background_color: String? = nil, tile_text_color: String? = nil, title_color: String? = nil, appearance: DashboardAppearance? = nil) { + public init(description: String? = nil, hidden: Bool? = nil, query_timezone: String? = nil, refresh_interval: String? = nil, folder: WriteFolderBase? = nil, title: String? = nil, slug: String? = nil, preferred_viewer: String? = nil, alert_sync_with_dashboard_filter_enabled: Bool? = nil, background_color: String? = nil, crossfilter_enabled: Bool? = nil, deleted: Bool? = nil, load_configuration: String? = nil, lookml_link_id: String? = nil, show_filters_bar: Bool? = nil, show_title: Bool? = nil, folder_id: String? = nil, text_tile_text_color: String? = nil, tile_background_color: String? = nil, tile_text_color: String? = nil, title_color: String? = nil, appearance: DashboardAppearance? = nil) { self.description = description self.hidden = hidden self.query_timezone = query_timezone @@ -11095,6 +11165,7 @@ public struct WriteDashboard: SDKModel { self.title = title self.slug = slug self.preferred_viewer = preferred_viewer + self.alert_sync_with_dashboard_filter_enabled = alert_sync_with_dashboard_filter_enabled self.background_color = background_color self.crossfilter_enabled = crossfilter_enabled self.deleted = deleted @@ -12623,7 +12694,7 @@ public struct WriteResultMakerWithIdVisConfigAndDynamicFields: SDKModel { /** * Dynamically generated writeable type for Role removes properties: - * can, id, user_count, url, users_url + * can, id, url, users_url */ public struct WriteRole: SDKModel { /** diff --git a/swift/looker/sdk/streams.swift b/swift/looker/sdk/streams.swift index 4133dba7e..0ee09bc47 100644 --- a/swift/looker/sdk/streams.swift +++ b/swift/looker/sdk/streams.swift @@ -25,7 +25,7 @@ */ /** - * 412 API methods + * 413 API methods */ @@ -2237,6 +2237,8 @@ open class LookerSDKStream: APIMethods { /** * ### Get all External OAuth Applications. * + * This is an OAuth Application which Looker uses to access external systems. + * * GET /external_oauth_applications -> [ExternalOauthApplication] */ public func all_external_oauth_applications( @@ -2258,6 +2260,8 @@ open class LookerSDKStream: APIMethods { /** * ### Create an OAuth Application using the specified configuration. * + * This is an OAuth Application which Looker uses to access external systems. + * * POST /external_oauth_applications -> ExternalOauthApplication */ public func create_external_oauth_application( @@ -8095,6 +8099,75 @@ open class LookerSDKStream: APIMethods { return result } + /** + * ### Search roles include user count + * + * Returns all role records that match the given search criteria, and attaches + * associated user counts. + * + * If multiple search params are given and `filter_or` is FALSE or not specified, + * search params are combined in a logical AND operation. + * Only rows that match *all* search param criteria will be returned. + * + * If `filter_or` is TRUE, multiple search params are combined in a logical OR operation. + * Results will include rows that match **any** of the search criteria. + * + * String search params use case-insensitive matching. + * String search params can contain `%` and '_' as SQL LIKE pattern match wildcard expressions. + * example="dan%" will match "danger" and "Danzig" but not "David" + * example="D_m%" will match "Damage" and "dump" + * + * Integer search params can accept a single value or a comma separated list of values. The multiple + * values will be combined under a logical OR operation - results will match at least one of + * the given values. + * + * Most search params can accept "IS NULL" and "NOT NULL" as special expressions to match + * or exclude (respectively) rows where the column is null. + * + * Boolean search params accept only "true" and "false" as values. + * + * GET /roles/search/with_user_count -> [RoleSearch] + */ + public func search_roles_with_user_count( + /** + * @param {String} fields Requested fields. + */ + fields: String? = nil, + /** + * @param {Int64} limit Number of results to return (used with `offset`). + */ + limit: Int64? = nil, + /** + * @param {Int64} offset Number of results to skip before returning any (used with `limit`). + */ + offset: Int64? = nil, + /** + * @param {String} sorts Fields to sort by. + */ + sorts: String? = nil, + /** + * @param {Int64} id Match role id. + */ + id: Int64? = nil, + /** + * @param {String} name Match role name. + */ + name: String? = nil, + /** + * @param {Bool} built_in Match roles by built_in status. + */ + built_in: Bool? = nil, + /** + * @param {Bool} filter_or Combine given search criteria in a boolean OR expression. + */ + filter_or: Bool? = nil, + options: ITransportSettings? = nil + ) -> SDKResponse { + let result: SDKResponse = self.get("/roles/search/with_user_count", + ["fields": fields, "limit": limit, "offset": offset, "sorts": sorts, "id": id, "name": name, "built_in": built_in as Any?, "filter_or": filter_or as Any?], nil, options) + return result + } + /** * ### Get information about the role with a specific id. * From 16978836f42d8c755031a3438eeee1e9c1a743e6 Mon Sep 17 00:00:00 2001 From: Bryn Ryans Date: Wed, 7 Jul 2021 14:13:24 -0700 Subject: [PATCH 7/8] fix: extension-api-explorer build (#740) --- packages/run-it/src/test-data/responses.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/run-it/src/test-data/responses.ts b/packages/run-it/src/test-data/responses.ts index d741a141d..2977e0eca 100644 --- a/packages/run-it/src/test-data/responses.ts +++ b/packages/run-it/src/test-data/responses.ts @@ -28,6 +28,7 @@ import { IRawResponse } from '@looker/sdk-rtl' export const testJsonResponse: IRawResponse = { url: 'https://some/json/data', + headers: {}, contentType: 'application/json', ok: true, statusCode: 200, @@ -37,6 +38,7 @@ export const testJsonResponse: IRawResponse = { export const testTextResponse: IRawResponse = { url: 'https://some/text/data', + headers: {}, contentType: 'text/plain;charset=utf-8', ok: true, statusCode: 200, @@ -46,6 +48,7 @@ export const testTextResponse: IRawResponse = { export const testHtmlResponse: IRawResponse = { url: `https://some/html`, + headers: {}, contentType: 'text/html;charset=utf-8', ok: true, statusCode: 200, @@ -60,6 +63,7 @@ export const testHtmlResponse: IRawResponse = { export const testSqlResponse: IRawResponse = { url: `https://some/sql`, + headers: {}, contentType: 'application/sql', ok: true, statusCode: 200, @@ -73,6 +77,7 @@ LIMIT 500`), export const testImageResponse = (contentType = 'image/png'): IRawResponse => ({ url: `http://${contentType}`, + headers: {}, contentType, ok: true, statusCode: 200, @@ -82,6 +87,7 @@ export const testImageResponse = (contentType = 'image/png'): IRawResponse => ({ export const testUnknownResponse: IRawResponse = { url: 'http://bogus', + headers: {}, contentType: 'bogus', ok: true, statusCode: 200, @@ -91,6 +97,7 @@ export const testUnknownResponse: IRawResponse = { export const testErrorResponse: IRawResponse = { url: 'http://error', + headers: {}, body: Buffer.from( '{"message": "Not found", "documentation_url": "http://docs.looker.com"}' ), From 3ed6af78b2cb9610b3386ff851013a93fff40f54 Mon Sep 17 00:00:00 2001 From: John Kaster Date: Wed, 7 Jul 2021 16:31:50 -0700 Subject: [PATCH 8/8] fix: check HTTP status code for TS SDK "ok" toggle (#739) `422` and other "not ok" statuses were being left as `ok: true` with the recent raw request observer implementation. This fixes the bug. --- packages/sdk-node/src/nodeTransport.spec.ts | 38 +++++++++++++++++---- packages/sdk-node/src/nodeTransport.ts | 2 ++ packages/sdk-rtl/src/baseTransport.ts | 2 +- packages/sdk-rtl/src/browserTransport.ts | 2 ++ 4 files changed, 37 insertions(+), 7 deletions(-) diff --git a/packages/sdk-node/src/nodeTransport.spec.ts b/packages/sdk-node/src/nodeTransport.spec.ts index 2bb414022..a221603e4 100644 --- a/packages/sdk-node/src/nodeTransport.spec.ts +++ b/packages/sdk-node/src/nodeTransport.spec.ts @@ -24,7 +24,7 @@ */ -import { ITransportSettings } from '@looker/sdk-rtl' +import { IRawResponse, ITransportSettings, StatusCode } from '@looker/sdk-rtl' import { NodeCryptoHash, NodeTransport } from './nodeTransport' describe('NodeTransport', () => { @@ -35,7 +35,7 @@ describe('NodeTransport', () => { const badPath = fullPath + '_bogus' // const queryParams = { a: 'b c', d: false, nil: null, skip: undefined } - it('raw request retrieves fully qualified url', async () => { + test('raw request retrieves fully qualified url', async () => { const response = await xp.rawRequest('GET', fullPath) expect(response).toBeDefined() expect(response.ok).toEqual(true) @@ -50,7 +50,7 @@ describe('NodeTransport', () => { }) describe('transport errors', () => { - it('gracefully handles Node-level transport errors', async () => { + test('gracefully handles Node-level transport errors', async () => { const response = await xp.rawRequest('GET', badPath) const errorMessage = `GET ${badPath}` expect(response).toBeDefined() @@ -62,7 +62,7 @@ describe('NodeTransport', () => { }) }) - it('retrieves fully qualified url', async () => { + test('retrieves fully qualified url', async () => { const response = await xp.request('GET', fullPath) expect(response).toBeDefined() expect(response.ok).toEqual(true) @@ -74,8 +74,34 @@ describe('NodeTransport', () => { } }) + describe('ok check', () => { + const raw: IRawResponse = { + contentType: 'application/json', + headers: {}, + url: 'bogus', + ok: true, + statusCode: StatusCode.OK, + statusMessage: 'Mocked success', + body: 'body', + } + + test('ok is ok', () => { + expect(xp.ok(raw)).toEqual(true) + }) + + test('All 2xx responses are ok', () => { + raw.statusCode = StatusCode.IMUsed + expect(xp.ok(raw)).toEqual(true) + }) + + test('Non-2xx responses are not ok', () => { + raw.statusCode = 422 + expect(xp.ok(raw)).toEqual(false) + }) + }) + describe('NodeCryptoHash', () => { - it('secureRandom', () => { + test('secureRandom', () => { const hasher = new NodeCryptoHash() const rand1 = hasher.secureRandom(5) expect(rand1.length).toEqual(10) @@ -83,7 +109,7 @@ describe('NodeTransport', () => { expect(rand2.length).toEqual(64) }) - it('sha256hash', async () => { + test('sha256hash', async () => { const hasher = new NodeCryptoHash() const message = 'The quick brown fox jumped over the lazy dog.' const hash = await hasher.sha256Hash(message) diff --git a/packages/sdk-node/src/nodeTransport.ts b/packages/sdk-node/src/nodeTransport.ts index 2b4e1f804..61f05addd 100644 --- a/packages/sdk-node/src/nodeTransport.ts +++ b/packages/sdk-node/src/nodeTransport.ts @@ -115,6 +115,8 @@ export class NodeTransport extends BaseTransport { statusMessage: resTyped.statusMessage, headers: res.headers, } + // Update OK with response statusCode check + rawResponse.ok = this.ok(rawResponse) } catch (e) { let statusMessage = `${method} ${path}` let statusCode = 404 diff --git a/packages/sdk-rtl/src/baseTransport.ts b/packages/sdk-rtl/src/baseTransport.ts index 73f97c4a2..f9604d75c 100644 --- a/packages/sdk-rtl/src/baseTransport.ts +++ b/packages/sdk-rtl/src/baseTransport.ts @@ -48,7 +48,7 @@ export abstract class BaseTransport implements ITransport { raw: IRawResponse ): Promise> - protected ok(res: IRawResponse): boolean { + ok(res: IRawResponse): boolean { return ( res.statusCode >= StatusCode.OK && res.statusCode <= StatusCode.IMUsed ) diff --git a/packages/sdk-rtl/src/browserTransport.ts b/packages/sdk-rtl/src/browserTransport.ts index 87038e556..6024d6d6c 100644 --- a/packages/sdk-rtl/src/browserTransport.ts +++ b/packages/sdk-rtl/src/browserTransport.ts @@ -211,6 +211,8 @@ export class BrowserTransport extends BaseTransport { startMark: started, headers, } + // Update OK with response statusCode check + response.ok = this.ok(response) return this.observer ? this.observer(response) : response }