@@ -55,6 +55,14 @@ export namespace CometChat {
5555 CANCELLED : string ;
5656 ENDED : string ;
5757 } ;
58+ let SORT_BY : {
59+ NAME : string ;
60+ STATUS : string ;
61+ }
62+ let SORT_ORDER : {
63+ ASCENDING : string ;
64+ DESCENDING : string ;
65+ }
5866
5967 let appSettings : AppSettings ;
6068
@@ -512,6 +520,16 @@ export namespace CometChat {
512520 */
513521 export function transferGroupOwnership ( guid : string , uid : string ) : Promise < string > ;
514522
523+ /**
524+ * Function to create a group and add/ban members in/from that group.
525+ * @param {Group } group
526+ * @param {Array<GroupMember> } members
527+ * @param {Array<String> } banMembers
528+ * @returns {Promise<Object> }
529+ * @memberof CometChat
530+ */
531+ export function createGroupWithMembers ( group : Group , members : Array < GroupMember > , banMembers : Array < string > ) : Promise < Object > ;
532+
515533 /**-------------------------------------------------------------------*
516534 * Call related functions provided by CometChat class *
517535 *--------------------------------------------------------------------**/
@@ -3218,6 +3236,10 @@ export class UsersRequestBuilder {
32183236 /** @private */ showFriendsOnly : boolean ;
32193237 /** @private */ showTags : boolean ;
32203238 /** @private */ UIDs : Array < String > ;
3239+ /** @private */ SortBy : string ;
3240+ /** @private */ SortOrder : string ;
3241+ /** @private */ SearchIn : Array < String > ;
3242+
32213243 /**
32223244 * A method to set limit for the number of Users returned in a single iteration. A maximum of 100 users can fetched in a single iteration.
32233245 * @param {number } limit
@@ -3278,6 +3300,31 @@ export class UsersRequestBuilder {
32783300 * @returns
32793301 */
32803302 setUIDs ( uids : Array < String > ) : this;
3303+ /**
3304+ * A method to get the users sorted by either `name` or `status`.
3305+ * It accepts a string as input.
3306+ * By default the SDK fetches users sorted by `status`.
3307+ * @param {string } sortBy
3308+ * @returns
3309+ */
3310+ public sortBy ( sortBy : string ) : this;
3311+ /**
3312+ * A method to get the users sorted either in `asc` or `desc` order.
3313+ * It accepts a string as input.
3314+ * By default the SDK fetches users sorted in `asc` order.
3315+ * @param {string } sortOrder
3316+ * @returns
3317+ */
3318+ public sortByOrder ( sortOrder : string ) : this;
3319+ /**
3320+ * A method to set which field the search string should be searched.
3321+ * It accepts an array of string as input.
3322+ * It can be `["name"]`, `["uid"]` or `["name", "uid"]`.
3323+ * By default the SDK searches the search string in `["name", "uid"]`.
3324+ * @param {string[] } searchIn
3325+ * @returns
3326+ */
3327+ public searchIn ( searchIn : Array < String > ) : this;
32813328 /**
32823329 * This method will return an object of the UsersRequest class.
32833330 * @returns {UsersRequest }
@@ -3303,6 +3350,8 @@ export class ConversationsRequestBuilder {
33033350 /** @private */ getUserAndGroupTags : boolean ;
33043351 /** @private */ tags : Array < String > ;
33053352 /** @private */ WithTags : boolean ;
3353+ /** @private */ groupTags : Array < String > ;
3354+ /** @private */ userTags : Array < String > ;
33063355 /**
33073356 *
33083357 * @param {number } limit
@@ -3336,6 +3385,18 @@ export class ConversationsRequestBuilder {
33363385 * @returns
33373386 */
33383387 setTags ( tags : Array < String > ) : this;
3388+ /**
3389+ * A method to filter conversation list by group tags.
3390+ * @param {Array<String> } groupTags
3391+ * @returns
3392+ */
3393+ public setGroupTags ( groupTags : Array < String > ) : this;
3394+ /**
3395+ * A method to filter conversation list by user tags.
3396+ * @param {Array<String> } userTags
3397+ * @returns
3398+ */
3399+ public setUserTags ( userTags : Array < String > ) : this;
33393400 /**
33403401 * This method will return an object of the ConversationsRequest class.
33413402 * @returns {ConversationsRequest }
0 commit comments