@itentialopensource/adapter-thingspace 0.1.2 → 0.1.3

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/AUTH.md CHANGED
@@ -2,8 +2,8 @@
2
2
 
3
3
  This document will go through the steps for authenticating the Thingspace adapter with Basic Authentication. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://www.itential.com/automation-platform/integrations/adapters-resources/authentication/" target="_blank">HERE</a>.
4
4
 
5
- ### Basic Authentication
6
- The Thingspace adapter requires Basic Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
5
+ ### Multi Step Authentication
6
+ The Thingspace adapter requires Multi Step Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
7
7
 
8
8
  STEPS
9
9
  1. Ensure you have access to a Thingspace server and that it is running
@@ -11,20 +11,48 @@ STEPS
11
11
  3. Use the properties below for the ```properties.authentication``` field
12
12
  ```json
13
13
  "authentication": {
14
- "auth_method": "basic user_password",
15
- "username": "<username>",
16
- "password": "<password>",
17
- "token": "",
18
- "token_timeout": 1800000,
19
- "token_cache": "local",
20
- "invalid_token_error": 401,
21
- "auth_field": "header.headers.Authorization",
22
- "auth_field_format": "Basic {b64}{username}:{password}{/b64}",
23
- "auth_logging": false,
24
- "client_id": "",
25
- "client_secret": "",
26
- "grant_type": ""
27
- }
14
+ "auth_method": "multi_step_authentication",
15
+ "multiStepAuthCalls": [
16
+ {
17
+ "name": "getAccessToken",
18
+ "requestFields": {
19
+ "grant_type": "client_credentials",
20
+ "header.Authorization": "Basic <token>"
21
+ },
22
+ "responseFields": {
23
+ "accessToken": "access_token"
24
+ },
25
+ "successfullResponseCode": 200
26
+ },
27
+ {
28
+ "name": "getSessionToken",
29
+ "requestFields": {
30
+ "header.Authorization": "Bearer {getAccessToken.responseFields.accessToken}",
31
+ "username": "<username>",
32
+ "password": "<password>"
33
+ },
34
+ "responseFields": {
35
+ "token": "sessionToken"
36
+ },
37
+ "successfullResponseCode": 200
38
+ }
39
+ ],
40
+ "token_timeout": 600000,
41
+ "token_cache": "local",
42
+ "invalid_token_error": 401,
43
+ "auth_field": [
44
+ "header.headers.VZ-M2M-Token",
45
+ "header.headers.Authorization"
46
+ ],
47
+ "auth_field_format": [
48
+ "{token}",
49
+ "Bearer {getAccessToken.responseFields.accessToken}"
50
+ ],
51
+ "auth_logging": false,
52
+ "client_id": "",
53
+ "client_secret": "",
54
+ "grant_type": ""
55
+ }
28
56
  ```
29
57
  4. Restart the adapter. If your properties were set correctly, the adapter should go online.
30
58
 
package/CHANGELOG.md CHANGED
@@ -1,4 +1,12 @@
1
1
 
2
+ ## 0.1.3 [02-02-2023]
3
+
4
+ * Bug fixes and performance improvements
5
+
6
+ See commit f5f408c
7
+
8
+ ---
9
+
2
10
  ## 0.1.2 [02-02-2023]
3
11
 
4
12
  * Bug fixes and performance improvements
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itentialopensource/adapter-thingspace",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "This adapter integrates with system described as: ThingSpace.",
5
5
  "main": "adapter.js",
6
6
  "wizardVersion": "2.44.15",
Binary file