Overview:
This is a guide on how to implement StringUID environment with RTT. This is typically for developers that want their StringUID users in a channel to be able to use RTT and send stream-message. One way to implement this is by enabling 128-host environment due to the fact that String UID is not directly supported by RTT bots for now.
Why 128-host environment?
This is because this environment supports 2 data types when joining a channel. After calling the Join() method, an event callback will return both String UID assigned and an Integer UID which is assigned automatically by the SDK.
Prerequisites:
- Your base implementation of Voice or Video SDK.
- Existing Restful Implementation for RTT task for reference, you may check this guide.
- Enablement request of 128-host environment. This can be done by contacting Agora Support.
-
- Once enabled, you may now continue on the next steps.
-
Next Steps:
- Join a channel using a String UID. Once joined, a callback will return both assigned StringUID and a random Integer UID assigned by the SDK which then will be used by the RTT bots to listen to.
- Call the START request for Transcription. Once started and if the user with StringUID speaks, the subBot will listen to its Integer UID (1000000052 is the assigned UID to the string userID luistester) and the text will be published by pubBot within the channel and can be retrieved by using stream-message.
This can be tested in parallel by using client-side RestAPI using our Agora RTT Webdemo just like the above:
https://webdemo-na.agora.io/stt/index.html
Make sure that you have a separate environment that accepts StringUID to join a channel as this demo only accepts IntegerUID. This will only be used to see the transcriptions from the StringUID remote user.