Giter Club home page Giter Club logo

rocket.chat.java.sdk's People

Contributors

filipedelimabrito avatar luciofm avatar rafaelks avatar sacoo7 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rocket.chat.java.sdk's Issues

Register Guest Token Issue

When calling register guest function, the following error is thrown:
org.json.JSONException: JSONObject["token"] not found. at org.json.JSONObject.get(JSONObject.java:473) 2018-07-15 01:51:26.124 at org.json.JSONObject.getString(JSONObject.java:654) at io.rocketchat.livechat.model.GuestObject.<init>(GuestObject.java:21) INFO at io.rocketchat.livechat.middleware.LiveChatMiddleware.processCallback(LiveChatMiddleware.java:57) at io.rocketchat.livechat.LiveChatAPI.onTextMessage(LiveChatAPI.java:176) at io.rocketchat.common.network.Socket$1.onTextMessage(Socket.java:112) at com.neovisionaries.ws.client.ListenerManager.callOnTextMessage(ListenerManager.java:352) at com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:260) at com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:238) at com.neovisionaries.ws.client.ReadingThread.handleTextFrame(ReadingThread.java:963) at com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:746) at com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:108) at com.neovisionaries.ws.client.ReadingThread.runMain(ReadingThread.java:64) at com.neovisionaries.ws.client.WebSocketThread.run(WebSocketThread.java:45)
P.S: I am using version 0.6.4, also on latest this issue reproduces

[NEW] Pinned messages list

Description

Add support to fetch the pinned messages list (paginated) in the SDK as a REST API.

Progress

  • API request;
  • Paginated support;
  • Unit tests;

File upload

I am trying to upload a fille using uploadFIle method it gives me upload error: ErrorObject{reason='Store not found', errorType='Meteor.Error', error=0, message='Store not found [invalid-store]'}

409 Error on gradle dependency

Hello,
I am trying to add this SDK in version 0.2.0 into Android project in gradle dependencies but I get 409 Conflict error.

There is how I am adding sdk:
compile ('io.rocketchat:rocketchatjavasdk:0.2.0'){
exclude group :'org.json', module: 'json'
}

Here is an error:
{
"errors" : [ {
"status" : 409,
"message" : "The repository 'oss-snapshot-local' rejected the resolution of an artifact 'oss-snapshot-local:io/rocketchat/rocketchatjavasdk/0.2.0/rocketchatjavasdk-0.2.0.pom' due to conflict in the snapshot release handling policy."
} ]
}

Version 0.1.1 works fine, I have tested also on fresh project with clear gradle cache.

[QUESTION] Unable to connect server using realtime api

I am trying to connect server using realtime api of rocket chat
i have used these server url
server url = wss://server.com/websocket
or
server url = wss://server.com
But in both case i have got this error :
Disconnected from server
Jan 10, 2018 10:51:47 AM com.rocketchat.common.network.Socket onConnectError
WARNING: Connect error

Please help me how can i connect to rocket chat server using real time api . What server url i need or any configuration in server needed .

Opening an existent session will not subscribe to new messages

When I do open an existent LiveChat support conversation, it loads the history after I send the first message and keeps loading. It does not subscribe to new messages.

Expected results:

  1. Open existing conversation
  2. Instantly load the history
  3. Subscribe to new messages
  4. Allow user to send new messages to the conversation

How can i Get Real time Room Msg???

How can i get Real time Message from From a particular Room? only room info? lol I think this is the only important and main part of this sdk.. i missed or u missed?

onLoadHistory never called

chatRoom.getChatHistory(20, new Date(), null, this);

@OverRide
public void onLoadHistory(List list, int unreadNotLoaded, ErrorObject error) {
System.out.println("onLoadHistory size = " + list.size());
}

above is the callback which was never called by Rocket Chat although messages are printed in the log by System.out. Any ideas?

Doc, Source and Binary is not matching

Latest release is 0.7.1.9, doc and source is more like a mix version. You would find something different all the time 👍

Although you guys marked this as deprecated, the new library is still working in progress right? Please don't stop maintaining it.

[NEW] Starred messages list

Description

Add support to fetch the starred messages list (paginated) in the SDK as a REST API.

Progress

  • API request;
  • Paginated support;
  • Unit tests;

JsonException when restoring object state

When saving the object state, as described in the specs: String state=room.toString(); saveToFile("filename.txt",state);

the follwing exception is throwned:
org.json.JSONException: A JSONObject text must begin with '{' at 1 [character 2 line 1] at org.json.JSONTokener.syntaxError(JSONTokener.java:433) at org.json.JSONObject.<init>(JSONObject.java:194) at org.json.JSONObject.<init>(JSONObject.java:321) at io.rocketchat.livechat.LiveChatAPI$ChatRoom.<init>(LiveChatAPI.java:240) at hello.chat.ChatService.onInitialData(ChatService.java:132) at io.rocketchat.livechat.middleware.LiveChatMiddleware.processCallback(LiveChatMiddleware.java:48) at io.rocketchat.livechat.LiveChatAPI.onTextMessage(LiveChatAPI.java:176) at io.rocketchat.common.network.Socket$1.onTextMessage(Socket.java:112) at com.neovisionaries.ws.client.ListenerManager.callOnTextMessage(ListenerManager.java:352) at com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:260) at com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:238) at com.neovisionaries.ws.client.ReadingThread.handleTextFrame(ReadingThread.java:963) at com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:746) at com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:108) at com.neovisionaries.ws.client.ReadingThread.runMain(ReadingThread.java:64) at com.neovisionaries.ws.client.WebSocketThread.run(WebSocketThread.java:45)

The room.toString() result looks lie this: ChatRoom{userName='guest-25', roomId='1jxze8nc7hs8h', userId='QciLCvpuMq2ZbimBb', visitorToken='-163d29c2d06bf5a4dc1915b4d9e34eeb', authToken='1LfwFzKYgsM3nphcV0EeY3jfnsp-9qBe6oPhRy01gtI'}, but it should look like this:
{userName='guest-25', roomId='1jxze8nc7hs8h', userId='QciLCvpuMq2ZbimBb', visitorToken='-163d29c2d06bf5a4dc1915b4d9e34eeb', authToken='1LfwFzKYgsM3nphcV0EeY3jfnsp-9qBe6oPhRy01gtI'}, in order to be successfully deserialized

[NEW] Files list

Description

Add support to fetch the files list (paginated) in the SDK as a REST API.

Progress

  • API request;
  • Paginated support;
  • Unit tests;

News user Not possible Subscriptions or join room.

News user registerd via restapi Not possible Subscriptions or join room. not get getChatHistory. But it work Default main room but not work other Channel creted by admin.. If that user join using browser after only work in android

@OverRide
public void onLogin(TokenObject token, ErrorObject error) {
client.getSubscriptions(this);
}

@Override
public void onGetSubscriptions(List<SubscriptionObject> subscriptions, ErrorObject error) {
    ChatRoomFactory factory = client.getChatRoomFactory();   //client.is used for creating rooms from subscriptions/ rooms retured by either getSubscriptions or getRooms API
    room = factory.createChatRooms(subscriptions).getChatRoomByName("TestRoom");
}

Get webrtc invite

How can user get private webrtc invite? need some function about webrtc

Separate into modules and artifacts

Separate the SDK into the modules and artifacts
livechat module - rocketchat-sdk-livechat artifact for LiveChat functionality
core module - rocketchat-sdk-core artifact for core SDK functionality, DDP protocol comunication.
common module - rocketchat-sdk-common artifact for common code used by both livechat and core modules.

List Online users?

It is possible get list of online users? online users from specific room id or name?

Rotating device will try to reconnect

I'm using latest version of the demo LiveChat SDK and when I do rotate the device, it seems to reconnect to the server. This is unexpected and unnecessary, it only needs to adjust the UI, nothing else.

[NEW] Members list

Description

Add support to fetch the members list (paginated) in the SDK as a REST API.

Progress

  • API request;
  • Paginated support;
  • Unit tests;

how to build this sdk into a library file

I have added the compile line code in build.gradle to use this sdk. But still i doubt that all the sdk is imported. when i import any class its saying "cannot resolve symbol...".
Is there any way like we can build this sdk into a jar file or something and just copy it into the libs folder

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.