private void createChatGroup(ChatGroupType type)
        {
            BacktoryResponse <ChatGroupCreationResponse> response = backtoryApi.CreateChatGroup(getMessage(), type);

            if (response.Successful)
            {
                writeLine("--+group created. id: " + response.Body.GroupId);
            }
            else
            {
                writeLine("--+group creation failed with code: " + response.Code + " and message " + response.Message);
            }
        }
        public BacktoryResponse <ChatGroupCreationResponse> CreateChatGroup(string groupName, ChatGroupType groupType)
        {
            string destination = "/app/chat/group/create";
            Dictionary <string, object> apiParamData = new Dictionary <string, object> ();

            setApiParamData("name", groupName, ref apiParamData);
            setApiParamData("type", groupType, ref apiParamData);
            return(SendAndReceive <ChatGroupCreationResponse> (destination, apiParamData, typeof(ChatGroupCreationResponse)));
//			BacktorySender sender = GetSender(destination, apiParamData);
//			string responseStr = sender.Send();
//			return GenerateBacktoryResponse<ChatGroupCreationResponse>(responseStr, typeof(ChatGroupCreationResponse));
        }
 public BacktoryResponse <ChatGroupCreationResponse> CreateChatGroup(string groupName,
                                                                     ChatGroupType groupType)
 {
     return(backtoryConnectivityApi.CreateChatGroup(groupName, groupType));
 }