SessionServerApi

Functions

Link copied to clipboard
@GET(value = "session/minecraft/profile/{uuid}")
abstract suspend fun fetchProfile(@Path(value = "uuid") uuid: String): Response<SessionProfile>

Returns 204 if the UUID has no player.

Link copied to clipboard
@GET(value = "session/minecraft/profile/{uuid}")
abstract suspend fun fetchProfileSigned(@Path(value = "uuid") uuid: String, @Query(value = "unsigned") unsigned: Boolean = false): Response<SessionProfile>

As above, with signature verification.

Link copied to clipboard
@GET(value = "blockedservers")
abstract suspend fun getBlockedServers(): String

SHA-1 hashes, one per line.

Link copied to clipboard
@GET(value = "session/minecraft/hasJoined")
abstract suspend fun hasJoined(@Query(value = "username") username: String, @Query(value = "serverId") serverId: String, @Query(value = "ip") ip: String? = null): Response<SessionProfile>

Returns the profile on success, 204/empty on failure.

Link copied to clipboard
@POST(value = "session/minecraft/join")
abstract suspend fun joinServer(@Body request: JoinServerRequest): Response<Unit>

Returns 204 on success.