@wireapp/api-client 24.16.0 → 24.17.0
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/lib/self/SelfAPI.d.ts +7 -0
- package/lib/self/SelfAPI.d.ts.map +1 -1
- package/lib/self/SelfAPI.js +13 -0
- package/lib/user/User.d.ts +2 -1
- package/lib/user/User.d.ts.map +1 -1
- package/package.json +2 -2
package/lib/self/SelfAPI.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { AxiosResponse } from 'axios';
|
|
2
|
+
import { ConversationProtocol } from '../conversation';
|
|
2
3
|
import { HttpClient, TraceState } from '../http/';
|
|
3
4
|
import { UserUpdate } from '../user/';
|
|
4
5
|
import { ChangePassword, Consent, ConsentResults, Delete, Name, Self } from './';
|
|
@@ -13,6 +14,7 @@ export declare class SelfAPI {
|
|
|
13
14
|
NAME: string;
|
|
14
15
|
PASSWORD: string;
|
|
15
16
|
PHONE: string;
|
|
17
|
+
SUPPORTED_PROTOCOLS: string;
|
|
16
18
|
SELF: string;
|
|
17
19
|
};
|
|
18
20
|
/**
|
|
@@ -86,6 +88,11 @@ export declare class SelfAPI {
|
|
|
86
88
|
* @see https://staging-nginz-https.zinfra.io/swagger-ui/#!/users/updateSelf
|
|
87
89
|
*/
|
|
88
90
|
putSelf(profileData: UserUpdate): Promise<void>;
|
|
91
|
+
/**
|
|
92
|
+
* Update self user's list of supported-protocols
|
|
93
|
+
* @param supportedProtocols The list of supported protocols
|
|
94
|
+
*/
|
|
95
|
+
putSupportedProtocols(supportedProtocols: ConversationProtocol[]): Promise<void>;
|
|
89
96
|
/**
|
|
90
97
|
* Check if password is set.
|
|
91
98
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelfAPI.d.ts","sourceRoot":"","sources":["../../src/self/SelfAPI.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAqB,aAAa,EAAC,MAAM,OAAO,CAAC;AAExD,O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xD;;;OAGG;IACU,OAAO,CAAC,WAAW,GAAE,UAAU,EAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAanE;;;;OAIG;IACU,SAAS,CAAC,UAAU,EAAE;QAAC,MAAM,EAAE,MAAM,CAAA;KAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAUnE;;;;OAIG;IACU,SAAS,CAAC,UAAU,EAAE;QAAC,MAAM,EAAE,MAAM,CAAA;KAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAUnE;;;;OAIG;IACU,WAAW,CAAC,YAAY,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC;IAUrE;;;;OAIG;IACU,QAAQ,CAAC,SAAS,EAAE;QAAC,KAAK,EAAE,MAAM,CAAA;KAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAUhE;;;;OAIG;IACU,OAAO,CAAC,WAAW,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC;IAU5D;;;OAGG;IACU,qBAAqB,CAAC,kBAAkB,EAAE,oBAAoB,EAAE;IAU7E;;OAEG;IACI,YAAY,IAAI,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;CAQpD"}
|
package/lib/self/SelfAPI.js
CHANGED
|
@@ -174,6 +174,18 @@ class SelfAPI {
|
|
|
174
174
|
};
|
|
175
175
|
await this.client.sendJSON(config);
|
|
176
176
|
}
|
|
177
|
+
/**
|
|
178
|
+
* Update self user's list of supported-protocols
|
|
179
|
+
* @param supportedProtocols The list of supported protocols
|
|
180
|
+
*/
|
|
181
|
+
async putSupportedProtocols(supportedProtocols) {
|
|
182
|
+
const config = {
|
|
183
|
+
data: { supported_protocols: supportedProtocols },
|
|
184
|
+
method: 'put',
|
|
185
|
+
url: `${SelfAPI.URL.SELF}/${SelfAPI.URL.SUPPORTED_PROTOCOLS}`,
|
|
186
|
+
};
|
|
187
|
+
await this.client.sendJSON(config);
|
|
188
|
+
}
|
|
177
189
|
/**
|
|
178
190
|
* Check if password is set.
|
|
179
191
|
*/
|
|
@@ -194,5 +206,6 @@ SelfAPI.URL = {
|
|
|
194
206
|
NAME: 'name',
|
|
195
207
|
PASSWORD: 'password',
|
|
196
208
|
PHONE: 'phone',
|
|
209
|
+
SUPPORTED_PROTOCOLS: 'supported-protocols',
|
|
197
210
|
SELF: '/self',
|
|
198
211
|
};
|
package/lib/user/User.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AccentColor } from '@wireapp/commons';
|
|
2
2
|
import { QualifiedId } from './QualifiedId';
|
|
3
|
-
import { ServiceRef } from '../conversation/';
|
|
3
|
+
import { ConversationProtocol, ServiceRef } from '../conversation/';
|
|
4
4
|
import { Picture } from '../self/';
|
|
5
5
|
import { UserAsset } from '../user/';
|
|
6
6
|
export interface User {
|
|
@@ -17,5 +17,6 @@ export interface User {
|
|
|
17
17
|
qualified_id: QualifiedId;
|
|
18
18
|
service?: ServiceRef;
|
|
19
19
|
team?: string;
|
|
20
|
+
supported_protocols?: ConversationProtocol[];
|
|
20
21
|
}
|
|
21
22
|
//# sourceMappingURL=User.d.ts.map
|
package/lib/user/User.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../src/user/User.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAE1C,OAAO,EAAC,UAAU,EAAC,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../src/user/User.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAE1C,OAAO,EAAC,oBAAoB,EAAE,UAAU,EAAC,MAAM,kBAAkB,CAAC;AAClE,OAAO,EAAC,OAAO,EAAC,MAAM,UAAU,CAAC;AACjC,OAAO,EAAC,SAAS,EAAC,MAAM,UAAU,CAAC;AAEnC,MAAM,WAAW,IAAI;IACnB,SAAS,CAAC,EAAE,WAAW,CAAC,aAAa,CAAC;IACtC,MAAM,CAAC,EAAE,SAAS,EAAE,CAAC;IACrB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,OAAO,EAAE,CAAC;IACpB,YAAY,EAAE,WAAW,CAAC;IAC1B,OAAO,CAAC,EAAE,UAAU,CAAC;IACrB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,mBAAmB,CAAC,EAAE,oBAAoB,EAAE,CAAC;CAC9C"}
|
package/package.json
CHANGED