OryksaTvClientBackend class
The real backend: the ORYKSA API through an OryksaClient (its session token, its
platform). Written against the contract in the TV SDK design (section 9); each call is
only proven once the server side is live.
- Implemented types
Constructors
- OryksaTvClientBackend(OryksaClient client)
-
Creates the backend on
client. Create the client with the TVplatform, for exampleOryksaClient(getToken: ..., platform: OryksaTvPlatform.fireTv.wire).
Properties
- client → OryksaClient
-
The client with the session token.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- platform → String
-
The value sent as
platform(for examplefire_tv).no setteroverride - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
ai(
{String? instructions, String? input, Map< String, dynamic> ? schema}) → Future<OryksaAiResult> -
An AI task of your app (
client.ai), counted as ORYKSA interactions.override -
chat(
String message, {required String locale, OryksaAppContext? appContext, bool voice = false}) → Future< OryksaReply> -
Sends a message to the AI and waits for the reply (the assistant panel).
override
-
config(
String locale) → Future< OryksaTvConfig> -
The TV configuration for
locale(texts, presenter, rules). The server picks the supported locale and says which in OryksaTvConfig.locale.override -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
pair(
String locale) → Future< OryksaPairing> -
Starts pairing a phone: the QR and the code to show.
override
-
phoneEvents(
String pairId, {int after = 0, Duration wait = const Duration(seconds: 25)}) → Future< OryksaPhoneEventsPage> -
Waits up to
waitfor phone events newer thanafter(long-poll).override -
speak(
String text, {required String locale, bool whisper = false, bool voice = true, String? cachedRev}) → Future< OryksaTvSpeech?> -
The presenter's line
textinlocale, charged each time by the ORYKSA interaction cost table (OryksaTvSpeech.interactionsSpent; a line not counted is not shown).voicefalse: subtitles only, no voice wanted.cachedRev: the device already has this line with that voice revision, so the server may only count it and send no voice. The bytes may be empty (subtitles only). Null when the server gave nothing for it. Throws on other errors.override -
toString(
) → String -
A string representation of this object.
inherited
-
unpair(
String pairId) → Future< void> -
Ends the pairing.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited