@selfcommunity/api-services 0.7.0-alpha.6 → 0.7.0-alpha.7
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/cjs/constants/Endpoints.js +2 -2
- package/lib/cjs/services/user/index.d.ts +4 -4
- package/lib/cjs/services/user/index.js +2 -2
- package/lib/esm/constants/Endpoints.js +2 -2
- package/lib/esm/services/user/index.d.ts +4 -4
- package/lib/esm/services/user/index.js +2 -2
- package/lib/umd/api-services.js +1 -1
- package/package.json +2 -2
|
@@ -334,8 +334,8 @@ const Endpoints = {
|
|
|
334
334
|
method: 'GET'
|
|
335
335
|
},
|
|
336
336
|
UserMatchUsernames: {
|
|
337
|
-
url: (0, utils_1.urlReplacer)('/api/v2/user/match
|
|
338
|
-
method: '
|
|
337
|
+
url: (0, utils_1.urlReplacer)('/api/v2/user/match/'),
|
|
338
|
+
method: 'POST'
|
|
339
339
|
},
|
|
340
340
|
ListHiddenUsers: {
|
|
341
341
|
url: (0, utils_1.urlReplacer)('/api/v2/user/hidden_users/'),
|
|
@@ -57,7 +57,7 @@ export interface UserApiClientInterface {
|
|
|
57
57
|
getUserLiveStream(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCLiveStreamType>>;
|
|
58
58
|
getOrderHistory(id: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder[]>;
|
|
59
59
|
getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
60
|
-
matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
60
|
+
matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Contains all the endpoints needed to manage users.
|
|
@@ -412,11 +412,11 @@ export declare class UserApiClient {
|
|
|
412
412
|
*/
|
|
413
413
|
static getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
414
414
|
/**
|
|
415
|
-
* This endpoint retrieve
|
|
415
|
+
* This endpoint retrieve the users corresponding to the sent usernames
|
|
416
416
|
* @param usernames
|
|
417
417
|
* @param config
|
|
418
418
|
*/
|
|
419
|
-
static matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
419
|
+
static matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
420
420
|
}
|
|
421
421
|
/**
|
|
422
422
|
*
|
|
@@ -510,5 +510,5 @@ export default class UserService {
|
|
|
510
510
|
static getUserLiveStream(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCLiveStreamType>>;
|
|
511
511
|
static getOrderHistory(id: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCPaymentOrder>>;
|
|
512
512
|
static getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
513
|
-
static matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
513
|
+
static matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
514
514
|
}
|
|
@@ -481,12 +481,12 @@ class UserApiClient {
|
|
|
481
481
|
return (0, apiRequest_1.apiRequest)(Object.assign(Object.assign({}, config), { url: Endpoints_1.default.GetOrderDetail.url({ id, order }), method: Endpoints_1.default.GetOrderDetail.method, params }));
|
|
482
482
|
}
|
|
483
483
|
/**
|
|
484
|
-
* This endpoint retrieve
|
|
484
|
+
* This endpoint retrieve the users corresponding to the sent usernames
|
|
485
485
|
* @param usernames
|
|
486
486
|
* @param config
|
|
487
487
|
*/
|
|
488
488
|
static matchUsernames(usernames, config) {
|
|
489
|
-
return (0, apiRequest_1.apiRequest)(Object.assign(Object.assign({}, config), { url: Endpoints_1.default.UserMatchUsernames.url(
|
|
489
|
+
return (0, apiRequest_1.apiRequest)(Object.assign(Object.assign({}, config), { url: Endpoints_1.default.UserMatchUsernames.url(), method: Endpoints_1.default.UserMatchUsernames.method, data: usernames }));
|
|
490
490
|
}
|
|
491
491
|
}
|
|
492
492
|
exports.UserApiClient = UserApiClient;
|
|
@@ -332,8 +332,8 @@ const Endpoints = {
|
|
|
332
332
|
method: 'GET'
|
|
333
333
|
},
|
|
334
334
|
UserMatchUsernames: {
|
|
335
|
-
url: urlReplacer('/api/v2/user/match
|
|
336
|
-
method: '
|
|
335
|
+
url: urlReplacer('/api/v2/user/match/'),
|
|
336
|
+
method: 'POST'
|
|
337
337
|
},
|
|
338
338
|
ListHiddenUsers: {
|
|
339
339
|
url: urlReplacer('/api/v2/user/hidden_users/'),
|
|
@@ -57,7 +57,7 @@ export interface UserApiClientInterface {
|
|
|
57
57
|
getUserLiveStream(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCLiveStreamType>>;
|
|
58
58
|
getOrderHistory(id: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder[]>;
|
|
59
59
|
getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
60
|
-
matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
60
|
+
matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Contains all the endpoints needed to manage users.
|
|
@@ -412,11 +412,11 @@ export declare class UserApiClient {
|
|
|
412
412
|
*/
|
|
413
413
|
static getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
414
414
|
/**
|
|
415
|
-
* This endpoint retrieve
|
|
415
|
+
* This endpoint retrieve the users corresponding to the sent usernames
|
|
416
416
|
* @param usernames
|
|
417
417
|
* @param config
|
|
418
418
|
*/
|
|
419
|
-
static matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
419
|
+
static matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
420
420
|
}
|
|
421
421
|
/**
|
|
422
422
|
*
|
|
@@ -510,5 +510,5 @@ export default class UserService {
|
|
|
510
510
|
static getUserLiveStream(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCLiveStreamType>>;
|
|
511
511
|
static getOrderHistory(id: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCPaymentOrder>>;
|
|
512
512
|
static getOrderDetail(id: number, order: number, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaymentOrder>;
|
|
513
|
-
static matchUsernames(usernames: string, config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
513
|
+
static matchUsernames(usernames: string[], config?: AxiosRequestConfig): Promise<SCUserAutocompleteType[]>;
|
|
514
514
|
}
|
|
@@ -478,12 +478,12 @@ export class UserApiClient {
|
|
|
478
478
|
return apiRequest(Object.assign(Object.assign({}, config), { url: Endpoints.GetOrderDetail.url({ id, order }), method: Endpoints.GetOrderDetail.method, params }));
|
|
479
479
|
}
|
|
480
480
|
/**
|
|
481
|
-
* This endpoint retrieve
|
|
481
|
+
* This endpoint retrieve the users corresponding to the sent usernames
|
|
482
482
|
* @param usernames
|
|
483
483
|
* @param config
|
|
484
484
|
*/
|
|
485
485
|
static matchUsernames(usernames, config) {
|
|
486
|
-
return apiRequest(Object.assign(Object.assign({}, config), { url: Endpoints.UserMatchUsernames.url(
|
|
486
|
+
return apiRequest(Object.assign(Object.assign({}, config), { url: Endpoints.UserMatchUsernames.url(), method: Endpoints.UserMatchUsernames.method, data: usernames }));
|
|
487
487
|
}
|
|
488
488
|
}
|
|
489
489
|
/**
|