Skip to content
This repository has been archived by the owner on Jan 27, 2023. It is now read-only.
/ CaffeineTVJavaApi Public archive

A (very) unofficial way of getting Caffeine related data including stream chat.

Notifications You must be signed in to change notification settings

e3ndr/CaffeineTVJavaApi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CaffeineTVJavaApi

A (very) unofficial way of getting Caffeine related data including stream chat.

Usage

You can find the project on JitPack.

CaffeineProfile profile = new CaffeineProfile(username);
profile.isValid(); // returns false if a user doesn't exist.

EventListener listener = (new ChatListener() {
  @Override
  public void onEvent(Chat chat) {
    // Code here
  }
})
CaffeineStream stream = new CaffeineStream(profile, listener); // Automatically connects, if not an error is thrown.
stream.close(); // Close.
stream.isOpen(); // Is open, directly from the websocket api.

What it accesses

https://api.caffeine.tv/v1/users/$username # Where to get client information
wss://realtime.caffeine.tv/v2/reaper/stages/$stage-id/messages # Socket address for stream events
{"Headers":{"Authorization":"Anonymous API","X-Client-Type":"api"}} # Headers for websocket
https://images.caffeine.tv/$avatar-link # Where you can get an avatar, every client has an associated avatar_link

About

A (very) unofficial way of getting Caffeine related data including stream chat.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages