ob-bms-sdk 0.0.18 → 0.0.19

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/api/api.ts CHANGED
@@ -223,35 +223,54 @@ export interface DestroyMembersResponse {
223
223
  export interface FindMemberResult {
224
224
  /**
225
225
  *
226
- * @type {boolean}
226
+ * @type {string}
227
227
  * @memberof FindMemberResult
228
228
  */
229
- 'result': boolean;
229
+ 'id': string;
230
230
  /**
231
231
  *
232
- * @type {FindMemberResultMember}
232
+ * @type {string}
233
233
  * @memberof FindMemberResult
234
234
  */
235
- 'member'?: FindMemberResultMember;
236
- }
237
- /**
238
- *
239
- * @export
240
- * @interface FindMemberResultMember
241
- */
242
- export interface FindMemberResultMember {
235
+ 'uid': string;
243
236
  /**
244
237
  *
245
- * @type {{ [key: string]: any; }}
246
- * @memberof FindMemberResultMember
238
+ * @type {string}
239
+ * @memberof FindMemberResult
247
240
  */
248
- 'meta': { [key: string]: any; };
241
+ 'account_id'?: string;
249
242
  /**
250
243
  *
251
- * @type {string}
252
- * @memberof FindMemberResultMember
244
+ * @type {JsonValue}
245
+ * @memberof FindMemberResult
246
+ */
247
+ 'metadata'?: JsonValue | null;
248
+ /**
249
+ *
250
+ * @type {FindMemberResultCreatedAt}
251
+ * @memberof FindMemberResult
253
252
  */
254
- 'personalId': string;
253
+ 'created_at': FindMemberResultCreatedAt;
254
+ /**
255
+ *
256
+ * @type {FindMemberResultCreatedAt}
257
+ * @memberof FindMemberResult
258
+ */
259
+ 'updated_at': FindMemberResultCreatedAt;
260
+ }
261
+ /**
262
+ *
263
+ * @export
264
+ * @interface FindMemberResultCreatedAt
265
+ */
266
+ export interface FindMemberResultCreatedAt {
267
+ }
268
+ /**
269
+ *
270
+ * @export
271
+ * @interface JsonValue
272
+ */
273
+ export interface JsonValue {
255
274
  }
256
275
  /**
257
276
  *
@@ -767,16 +786,16 @@ export interface VisitorSchedule {
767
786
  'floor_id': string;
768
787
  /**
769
788
  *
770
- * @type {VisitorScheduleFrom}
789
+ * @type {FindMemberResultCreatedAt}
771
790
  * @memberof VisitorSchedule
772
791
  */
773
- 'from': VisitorScheduleFrom;
792
+ 'from': FindMemberResultCreatedAt;
774
793
  /**
775
794
  *
776
- * @type {VisitorScheduleFrom}
795
+ * @type {FindMemberResultCreatedAt}
777
796
  * @memberof VisitorSchedule
778
797
  */
779
- 'to': VisitorScheduleFrom;
798
+ 'to': FindMemberResultCreatedAt;
780
799
  /**
781
800
  *
782
801
  * @type {object}
@@ -784,13 +803,6 @@ export interface VisitorSchedule {
784
803
  */
785
804
  'repetition'?: object;
786
805
  }
787
- /**
788
- *
789
- * @export
790
- * @interface VisitorScheduleFrom
791
- */
792
- export interface VisitorScheduleFrom {
793
- }
794
806
  /**
795
807
  *
796
808
  * @export
@@ -868,34 +880,15 @@ export interface WrappedResponseCreateVisitorResponseData {
868
880
  /**
869
881
  *
870
882
  * @export
871
- * @interface WrappedResponseFindMemberResult
883
+ * @interface WrappedResponseFindMemberResultOrNull
872
884
  */
873
- export interface WrappedResponseFindMemberResult {
874
- /**
875
- *
876
- * @type {WrappedResponseFindMemberResultData}
877
- * @memberof WrappedResponseFindMemberResult
878
- */
879
- 'data': WrappedResponseFindMemberResultData;
880
- }
881
- /**
882
- *
883
- * @export
884
- * @interface WrappedResponseFindMemberResultData
885
- */
886
- export interface WrappedResponseFindMemberResultData {
887
- /**
888
- *
889
- * @type {boolean}
890
- * @memberof WrappedResponseFindMemberResultData
891
- */
892
- 'result': boolean;
885
+ export interface WrappedResponseFindMemberResultOrNull {
893
886
  /**
894
887
  *
895
- * @type {FindMemberResultMember}
896
- * @memberof WrappedResponseFindMemberResultData
888
+ * @type {Array<FindMemberResult>}
889
+ * @memberof WrappedResponseFindMemberResultOrNull
897
890
  */
898
- 'member'?: FindMemberResultMember;
891
+ 'data': Array<FindMemberResult> | null;
899
892
  }
900
893
  /**
901
894
  *
@@ -1426,7 +1419,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
1426
1419
  * @param {*} [options] Override http request option.
1427
1420
  * @throws {RequiredError}
1428
1421
  */
1429
- async membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<WrappedResponseFindMemberResult>> {
1422
+ async membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<WrappedResponseFindMemberResultOrNull>> {
1430
1423
  const localVarAxiosArgs = await localVarAxiosParamCreator.membersIndex(identifier, options);
1431
1424
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1432
1425
  },
@@ -1522,7 +1515,7 @@ export const DefaultApiFactory = function (configuration?: Configuration, basePa
1522
1515
  * @param {*} [options] Override http request option.
1523
1516
  * @throws {RequiredError}
1524
1517
  */
1525
- membersIndex(identifier: string, options?: any): AxiosPromise<WrappedResponseFindMemberResult> {
1518
+ membersIndex(identifier: string, options?: any): AxiosPromise<WrappedResponseFindMemberResultOrNull> {
1526
1519
  return localVarFp.membersIndex(identifier, options).then((request) => request(axios, basePath));
1527
1520
  },
1528
1521
  /**
package/dist/api/api.d.ts CHANGED
@@ -221,37 +221,54 @@ export interface DestroyMembersResponse {
221
221
  export interface FindMemberResult {
222
222
  /**
223
223
  *
224
- * @type {boolean}
224
+ * @type {string}
225
225
  * @memberof FindMemberResult
226
226
  */
227
- 'result': boolean;
227
+ 'id': string;
228
228
  /**
229
229
  *
230
- * @type {FindMemberResultMember}
230
+ * @type {string}
231
231
  * @memberof FindMemberResult
232
232
  */
233
- 'member'?: FindMemberResultMember;
234
- }
235
- /**
236
- *
237
- * @export
238
- * @interface FindMemberResultMember
239
- */
240
- export interface FindMemberResultMember {
233
+ 'uid': string;
241
234
  /**
242
235
  *
243
- * @type {{ [key: string]: any; }}
244
- * @memberof FindMemberResultMember
236
+ * @type {string}
237
+ * @memberof FindMemberResult
245
238
  */
246
- 'meta': {
247
- [key: string]: any;
248
- };
239
+ 'account_id'?: string;
249
240
  /**
250
241
  *
251
- * @type {string}
252
- * @memberof FindMemberResultMember
242
+ * @type {JsonValue}
243
+ * @memberof FindMemberResult
253
244
  */
254
- 'personalId': string;
245
+ 'metadata'?: JsonValue | null;
246
+ /**
247
+ *
248
+ * @type {FindMemberResultCreatedAt}
249
+ * @memberof FindMemberResult
250
+ */
251
+ 'created_at': FindMemberResultCreatedAt;
252
+ /**
253
+ *
254
+ * @type {FindMemberResultCreatedAt}
255
+ * @memberof FindMemberResult
256
+ */
257
+ 'updated_at': FindMemberResultCreatedAt;
258
+ }
259
+ /**
260
+ *
261
+ * @export
262
+ * @interface FindMemberResultCreatedAt
263
+ */
264
+ export interface FindMemberResultCreatedAt {
265
+ }
266
+ /**
267
+ *
268
+ * @export
269
+ * @interface JsonValue
270
+ */
271
+ export interface JsonValue {
255
272
  }
256
273
  /**
257
274
  *
@@ -767,16 +784,16 @@ export interface VisitorSchedule {
767
784
  'floor_id': string;
768
785
  /**
769
786
  *
770
- * @type {VisitorScheduleFrom}
787
+ * @type {FindMemberResultCreatedAt}
771
788
  * @memberof VisitorSchedule
772
789
  */
773
- 'from': VisitorScheduleFrom;
790
+ 'from': FindMemberResultCreatedAt;
774
791
  /**
775
792
  *
776
- * @type {VisitorScheduleFrom}
793
+ * @type {FindMemberResultCreatedAt}
777
794
  * @memberof VisitorSchedule
778
795
  */
779
- 'to': VisitorScheduleFrom;
796
+ 'to': FindMemberResultCreatedAt;
780
797
  /**
781
798
  *
782
799
  * @type {object}
@@ -784,13 +801,6 @@ export interface VisitorSchedule {
784
801
  */
785
802
  'repetition'?: object;
786
803
  }
787
- /**
788
- *
789
- * @export
790
- * @interface VisitorScheduleFrom
791
- */
792
- export interface VisitorScheduleFrom {
793
- }
794
804
  /**
795
805
  *
796
806
  * @export
@@ -868,34 +878,15 @@ export interface WrappedResponseCreateVisitorResponseData {
868
878
  /**
869
879
  *
870
880
  * @export
871
- * @interface WrappedResponseFindMemberResult
881
+ * @interface WrappedResponseFindMemberResultOrNull
872
882
  */
873
- export interface WrappedResponseFindMemberResult {
874
- /**
875
- *
876
- * @type {WrappedResponseFindMemberResultData}
877
- * @memberof WrappedResponseFindMemberResult
878
- */
879
- 'data': WrappedResponseFindMemberResultData;
880
- }
881
- /**
882
- *
883
- * @export
884
- * @interface WrappedResponseFindMemberResultData
885
- */
886
- export interface WrappedResponseFindMemberResultData {
887
- /**
888
- *
889
- * @type {boolean}
890
- * @memberof WrappedResponseFindMemberResultData
891
- */
892
- 'result': boolean;
883
+ export interface WrappedResponseFindMemberResultOrNull {
893
884
  /**
894
885
  *
895
- * @type {FindMemberResultMember}
896
- * @memberof WrappedResponseFindMemberResultData
886
+ * @type {Array<FindMemberResult>}
887
+ * @memberof WrappedResponseFindMemberResultOrNull
897
888
  */
898
- 'member'?: FindMemberResultMember;
889
+ 'data': Array<FindMemberResult> | null;
899
890
  }
900
891
  /**
901
892
  *
@@ -1158,7 +1149,7 @@ export declare const DefaultApiFp: (configuration?: Configuration) => {
1158
1149
  * @param {*} [options] Override http request option.
1159
1150
  * @throws {RequiredError}
1160
1151
  */
1161
- membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<WrappedResponseFindMemberResult>>;
1152
+ membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<WrappedResponseFindMemberResultOrNull>>;
1162
1153
  /**
1163
1154
  *
1164
1155
  * @param {SyncBody} syncBody
@@ -1227,7 +1218,7 @@ export declare const DefaultApiFactory: (configuration?: Configuration, basePath
1227
1218
  * @param {*} [options] Override http request option.
1228
1219
  * @throws {RequiredError}
1229
1220
  */
1230
- membersIndex(identifier: string, options?: any): AxiosPromise<WrappedResponseFindMemberResult>;
1221
+ membersIndex(identifier: string, options?: any): AxiosPromise<WrappedResponseFindMemberResultOrNull>;
1231
1222
  /**
1232
1223
  *
1233
1224
  * @param {SyncBody} syncBody
@@ -1303,7 +1294,7 @@ export declare class DefaultApi extends BaseAPI {
1303
1294
  * @throws {RequiredError}
1304
1295
  * @memberof DefaultApi
1305
1296
  */
1306
- membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<WrappedResponseFindMemberResult, any>>;
1297
+ membersIndex(identifier: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<WrappedResponseFindMemberResultOrNull, any>>;
1307
1298
  /**
1308
1299
  *
1309
1300
  * @param {SyncBody} syncBody
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ exports.setBaseUrl = exports.setAcessToken = exports.axiosInstance = exports.cli
7
7
  const api_1 = require("./api");
8
8
  const axios_1 = __importDefault(require("axios"));
9
9
  const axiosInstance = axios_1.default.create({
10
- baseURL: process.env.OB_BMS_URL || 'localhost:3000',
10
+ baseURL: process.env.OB_BMS_URL || 'http://localhost:3000',
11
11
  });
12
12
  exports.axiosInstance = axiosInstance;
13
13
  function setAcessToken(accessToken) {
package/index.ts CHANGED
@@ -2,7 +2,7 @@ import { DefaultApi } from './api';
2
2
  import axios from 'axios';
3
3
 
4
4
  const axiosInstance = axios.create({
5
- baseURL: process.env.OB_BMS_URL || 'localhost:3000',
5
+ baseURL: process.env.OB_BMS_URL || 'http://localhost:3000',
6
6
  });
7
7
 
8
8
  function setAcessToken(accessToken: string): void {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ob-bms-sdk",
3
- "version": "0.0.18",
3
+ "version": "0.0.19",
4
4
  "description": "API interfaces for OB BMS",
5
5
  "main": "./dist/index.js",
6
6
  "license": "MIT"
package/test.ts CHANGED
@@ -1,14 +1,14 @@
1
1
  import * as OB_BMS_SDK from './dist';
2
2
 
3
3
  // OB_BMS_SDK.setAcessToken('789');
4
- OB_BMS_SDK.setBaseUrl('https://dev.glorymtel.xyz/ob-bms');
4
+ OB_BMS_SDK.setBaseUrl('http://dev.glorymtel.xyz/ob-bms');
5
5
  OB_BMS_SDK.setAcessToken(
6
6
  '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0MjcwNWYtMzViNS00ZDcxLThlMTktYzVhNDFhYzJlMGE0IiwiYWNjb3VudF9ncm91cF9pZCI6bnVsbH0seyJpZCI6ImZjYzE3MTY4LWRmNTQtNDIyMy04MzYxLTY4NTlkZmNmMzU2NSIsInBlcm1pdHRlZV90eXBlIjoiYWNjb3VudCIsInZhbHVlIjp7Im5hbWUiOiJvYi1pYW06dG9rZW4iLCJzZXJ2aWNlIjoib2ItaWFtIiwiYWN0aW9ucyI6WyJjcmVhdGUiLCJyZWFkIl0sInJlc291cmNlX3R5cGUiOiJ0b2tlbiIsInJlc291cmNlIjp7ImFjY291bnRfaWQiOiJzZWxmIn19LCJjcmVhdGVkX2F0IjoiMjAyMy0xMS0wMlQwODo1MTo0Mi43NzFaIiwidXBkYXRlZF9hdCI6IjIwMjMtMTEtMDJUMDg6NTE6NDIuNzcxWiIsImRlbGV0ZWRfYXQiOm51bGwsImFjY291bnRfaWQiOiI4MjQyNzA1Zi0zNWI1LTRkNzEtOGUxOS1jNWE0MWFjMmUwYTQiLCJhY2NvdW50X2dyb3VwX2lkIjpudWxsfV19.tfqYJop4iJNlIbBVztf7DFfVhaYAFnUGDhLjik2OGA4',
7
7
  );
8
8
  (async () => {
9
9
  try {
10
- const res = await OB_BMS_SDK.client.memberShow('1', {});
11
- console.dir(res);
10
+ const res = await OB_BMS_SDK.client.membersIndex('t.shin@pjoe.com', {});
11
+ console.dir(res.data, { depth: null });
12
12
  } catch (err) {
13
13
  console.log(err);
14
14
  }