From b445ee9e2c9023346136266e3dc4d9f8bd6a6175 Mon Sep 17 00:00:00 2001 From: Marius Tobiassen Bungum Date: Wed, 14 Aug 2024 07:03:06 +0200 Subject: [PATCH 1/2] :alien: Got latest API changes for related to impersonation feature --- src/api/models/GraphAppRole.ts | 13 +++++++++++++ src/api/models/JToken.ts | 5 ----- src/api/services/AmplifyApplicationService.ts | 15 ++++++++------- 3 files changed, 21 insertions(+), 12 deletions(-) create mode 100644 src/api/models/GraphAppRole.ts delete mode 100644 src/api/models/JToken.ts diff --git a/src/api/models/GraphAppRole.ts b/src/api/models/GraphAppRole.ts new file mode 100644 index 0000000..723208d --- /dev/null +++ b/src/api/models/GraphAppRole.ts @@ -0,0 +1,13 @@ +/* generated using openapi-typescript-codegen -- do not edit */ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +export type GraphAppRole = { + allowedMemberTypes?: Array | null; + description?: string | null; + displayName?: string | null; + id?: string | null; + isEnabled?: boolean | null; + origin?: string | null; + value?: string | null; +}; diff --git a/src/api/models/JToken.ts b/src/api/models/JToken.ts deleted file mode 100644 index e0551d7..0000000 --- a/src/api/models/JToken.ts +++ /dev/null @@ -1,5 +0,0 @@ -/* generated using openapi-typescript-codegen -- do not edit */ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ -export type JToken = Array; diff --git a/src/api/services/AmplifyApplicationService.ts b/src/api/services/AmplifyApplicationService.ts index a73470b..1842276 100644 --- a/src/api/services/AmplifyApplicationService.ts +++ b/src/api/services/AmplifyApplicationService.ts @@ -6,7 +6,7 @@ import type { AmplifyApplication } from '../models/AmplifyApplication'; import type { CancelablePromise } from '../core/CancelablePromise'; import { OpenAPI_Portal, OpenAPI_Portal_Prod } from '../core/OpenAPI'; import { request as __request } from '../core/request'; -import { JToken } from '../models/JToken'; +import { GraphAppRole } from '../models/GraphAppRole'; export class AmplifyApplicationService { /** * Get all applications that user has access to @@ -26,18 +26,19 @@ export class AmplifyApplicationService { }); } /** - * @param appClientId - * @returns JToken Success + * Get all roles for an application + * @param applicationId + * @returns GraphAppRole Success * @throws ApiError */ public static getAllAppRoles( - appClientId: string - ): CancelablePromise> { + applicationId: string + ): CancelablePromise> { return __request(OpenAPI_Portal, { method: 'GET', - url: '/api/v1/AmplifyApplication/application/{appClientId}/groups', + url: '/api/v1/AmplifyApplication/application/{applicationId}/appRoles', path: { - appClientId: appClientId, + applicationId: applicationId, }, }); } From 64b1048c7ddd4f9652129f44fc78174b57c37347 Mon Sep 17 00:00:00 2001 From: Marius Tobiassen Bungum Date: Wed, 14 Aug 2024 07:03:41 +0200 Subject: [PATCH 2/2] :bookmark: 1.1.6 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index f4ef69f..c11bbfd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@equinor/subsurface-app-management", - "version": "1.1.5", + "version": "1.1.6", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@equinor/subsurface-app-management", - "version": "1.1.5", + "version": "1.1.6", "license": "ISC", "dependencies": { "@azure/msal-browser": "3.10.0", diff --git a/package.json b/package.json index d1a9a8f..474dfe7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@equinor/subsurface-app-management", - "version": "1.1.5", + "version": "1.1.6", "description": "React Typescript components/hooks to communicate with equinor/sam", "types": "dist/index.d.ts", "type": "module",