Implement Eulerstream send chat API endpoint!

This commit is contained in:
kohlerpop1
2025-08-23 23:04:30 -04:00
parent 183aadb8e8
commit 646e4c68ab
8 changed files with 88 additions and 27 deletions

View File

@@ -26,6 +26,7 @@ import io.github.jwdeveloper.tiktok.data.requests.GiftsData;
import io.github.jwdeveloper.tiktok.data.requests.LiveConnectionData;
import io.github.jwdeveloper.tiktok.data.requests.LiveData;
import io.github.jwdeveloper.tiktok.data.requests.LiveUserData;
import io.github.jwdeveloper.tiktok.live.LiveRoomInfo;
public interface LiveHttpClient
{
@@ -64,4 +65,6 @@ public interface LiveHttpClient
}
LiveConnectionData.Response fetchLiveConnectionData(LiveConnectionData.Request request);
boolean sendChat(LiveRoomInfo roomInfo, String content);
}

View File

@@ -36,7 +36,6 @@ public interface LiveClient {
*/
void connect();
/**
* Connects in asynchronous way
* When connected Consumer returns instance of LiveClient
@@ -48,7 +47,6 @@ public interface LiveClient {
*/
CompletableFuture<LiveClient> connectAsync();
/**
* Disconnects the connection.
* @param type
@@ -68,7 +66,6 @@ public interface LiveClient {
*/
void publishEvent(TikTokEvent event);
/**
* @param webcastMessageName name of TikTok protocol-buffer message
* @param payloadBase64 protocol-buffer message bytes payload
@@ -96,4 +93,12 @@ public interface LiveClient {
* Logger
*/
Logger getLogger();
/**
* Send a chat message to the connected room
* @return true if successful, otherwise false
* @apiNote This is known to return true on some sessionIds despite failing!
* <p>We cannot fix this as it is a TikTok issue, not a library issue.
*/
boolean sendChat(String content);
}