EmbeddedChat icon indicating copy to clipboard operation
EmbeddedChat copied to clipboard

Refactor: Migrating from RocketChat SDK to DDPSDK of Rocket.Chat

Open devanshkansagra opened this issue 8 months ago • 5 comments

Proposed changes

This Pull Request updates the EmbeddedChat API and EmbeddedChat Auth to use the new DDPSDK of RocketChat instead of the Rocket.Chat SDK.

Fixes: N/A

Video/Screenshots

PR Test Details

Note: The PR will be ready for live testing at https://rocketchat.github.io/EmbeddedChat/pulls/pr-1009 after approval. Contributors are requested to replace <pr_number> with the actual PR number.

devanshkansagra avatar Jun 09 '25 17:06 devanshkansagra

I think the way RC is recommending handling real-time communication is by using this: https://developer.rocket.chat/apidocs/realtimeapi

I'm not sure, though, how actively the DDP SDK is maintained.

Spiral-Memory avatar Jun 12 '25 04:06 Spiral-Memory

Is this package "https://www.npmjs.com/package/@rocket.chat/ddp-client" using the same realtime api's defined in the doc, can you check once in your free time

Spiral-Memory avatar Jun 12 '25 04:06 Spiral-Memory

Hey @Spiral-Memory, you might see some of the methods are still using fetch instead of DDPSDK's REST API because some of these methods are giving 401 unauthorized or 403 forbidden error message...I have tried debugging it but still it was giving the same error so kept those methods to use fetch

One of the reason of these errors could be some of the endpoints are not supported by DDPSDK's REST right now..maybe in future they will work as expected.

I have added a comment above those methods which are still using fetch

devanshkansagra avatar Jun 17 '25 11:06 devanshkansagra

Thanks @devanshkansagra for this, Please let me know once you've finalized this PR. Thanks

Spiral-Memory avatar Jul 20 '25 07:07 Spiral-Memory

Ok

devanshkansagra avatar Jul 20 '25 11:07 devanshkansagra