@flipdish/authorization 0.0.6-rc.1764848040 → 0.0.6-rc.1764848166
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/configuration.ts +1 -1
- package/dist/configuration.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -12,8 +12,8 @@ import {
|
|
|
12
12
|
Configuration,
|
|
13
13
|
type ErrorResponse,
|
|
14
14
|
Permissions,
|
|
15
|
-
PermissionsApi,
|
|
16
15
|
UserPermissionsApi,
|
|
16
|
+
ConfigurationDataApi,
|
|
17
17
|
} from "@flipdish/authorization";
|
|
18
18
|
import { describe, expect, it, test } from "@jest/globals";
|
|
19
19
|
import axios, { isAxiosError } from "axios";
|
|
@@ -30,7 +30,7 @@ const bearerConfiguration = new Configuration({
|
|
|
30
30
|
});
|
|
31
31
|
|
|
32
32
|
const authorization = new AuthorizationApi(bearerConfiguration);
|
|
33
|
-
const
|
|
33
|
+
const configurationData = new ConfigurationDataApi(bearerConfiguration);
|
|
34
34
|
|
|
35
35
|
// mimic brower config where cookies will be sent automatically
|
|
36
36
|
// you shouldn't need to pass an axios instance as the cookies will be
|
|
@@ -48,7 +48,7 @@ const userPermissions = new UserPermissionsApi(
|
|
|
48
48
|
describe("Authorization Tests", () => {
|
|
49
49
|
describe("Authorization", () => {
|
|
50
50
|
test("List Permissions", async () => {
|
|
51
|
-
const permissionsResponse = await
|
|
51
|
+
const permissionsResponse = await configurationData.listPermissions();
|
|
52
52
|
expect(permissionsResponse.status).toBe(200);
|
|
53
53
|
expect(permissionsResponse.data.permissions).toBeDefined();
|
|
54
54
|
expect(permissionsResponse.data.permissions.length).toBeGreaterThan(0);
|
package/configuration.ts
CHANGED
|
@@ -100,7 +100,7 @@ export class Configuration {
|
|
|
100
100
|
|
|
101
101
|
const extraHeaders = param.useDefaultUserAgent ? {} : {
|
|
102
102
|
headers: {
|
|
103
|
-
"user-agent": "Flipdish authorization typescript SDK / 0.0.6-rc.
|
|
103
|
+
"user-agent": "Flipdish authorization typescript SDK / 0.0.6-rc.1764848166"
|
|
104
104
|
}
|
|
105
105
|
};
|
|
106
106
|
|
package/dist/configuration.js
CHANGED
|
@@ -36,7 +36,7 @@ var Configuration = /** @class */ (function () {
|
|
|
36
36
|
this.serverIndex = param.serverIndex;
|
|
37
37
|
var extraHeaders = param.useDefaultUserAgent ? {} : {
|
|
38
38
|
headers: {
|
|
39
|
-
"user-agent": "Flipdish authorization typescript SDK / 0.0.6-rc.
|
|
39
|
+
"user-agent": "Flipdish authorization typescript SDK / 0.0.6-rc.1764848166"
|
|
40
40
|
}
|
|
41
41
|
};
|
|
42
42
|
this.baseOptions = __assign(__assign({}, extraHeaders), param.baseOptions);
|