@deadair/sdk 0.31.2 → 0.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/deadair.sdk.d.ts +4 -0
- package/dist/deadair.sdk.d.ts.map +1 -1
- package/dist/director/types/director.types.d.ts +9 -6
- package/dist/director/types/director.types.d.ts.map +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +397 -46
- package/dist/index.js.map +1 -1
- package/dist/messaging/messaging.client.d.ts +22 -0
- package/dist/messaging/messaging.client.d.ts.map +1 -0
- package/dist/messaging/types/index.d.ts +2 -0
- package/dist/messaging/types/index.d.ts.map +1 -0
- package/dist/messaging/types/messaging.types.d.ts +39 -0
- package/dist/messaging/types/messaging.types.d.ts.map +1 -0
- package/dist/playlists/playlists.client.d.ts +46 -0
- package/dist/playlists/playlists.client.d.ts.map +1 -1
- package/dist/playlists/types/index.d.ts +1 -0
- package/dist/playlists/types/index.d.ts.map +1 -1
- package/dist/playlists/types/station.playlists.types.d.ts +185 -0
- package/dist/playlists/types/station.playlists.types.d.ts.map +1 -0
- package/dist/playout/playout.client.d.ts +6 -1
- package/dist/playout/playout.client.d.ts.map +1 -1
- package/dist/playout/types/playout.types.d.ts +21 -12
- package/dist/playout/types/playout.types.d.ts.map +1 -1
- package/dist/requests/requests.client.d.ts +42 -0
- package/dist/requests/requests.client.d.ts.map +1 -0
- package/dist/requests/types/index.d.ts +2 -0
- package/dist/requests/types/index.d.ts.map +1 -0
- package/dist/requests/types/requests.types.d.ts +89 -0
- package/dist/requests/types/requests.types.d.ts.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { DateTime } from 'luxon';
|
|
2
|
+
/**
|
|
3
|
+
* A record the station holds and could be asked for
|
|
4
|
+
* generated from [RequestableTrack](../../../../../apps/api/data/contracts/requests/requests.types.ck#L7)
|
|
5
|
+
*/
|
|
6
|
+
export interface RequestableTrack {
|
|
7
|
+
/** What to send as `trackId` to make the request */
|
|
8
|
+
trackId: string;
|
|
9
|
+
title: string;
|
|
10
|
+
/** The lead artist */
|
|
11
|
+
artist: string;
|
|
12
|
+
album?: string;
|
|
13
|
+
year?: number;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* generated from [RequestStatus](../../../../../apps/api/data/contracts/requests/requests.types.ck#L19)
|
|
17
|
+
*/
|
|
18
|
+
export type RequestStatus = 'waiting' | 'pending' | 'queued' | 'aired' | 'declined' | 'expired';
|
|
19
|
+
/**
|
|
20
|
+
* generated from [RequestSource](../../../../../apps/api/data/contracts/requests/requests.types.ck#L21)
|
|
21
|
+
*/
|
|
22
|
+
export type RequestSource = 'app' | 'chat';
|
|
23
|
+
/**
|
|
24
|
+
* Ask the station to play a record
|
|
25
|
+
* generated from [ListenerRequestCreate](../../../../../apps/api/data/contracts/requests/requests.types.ck#L41)
|
|
26
|
+
*/
|
|
27
|
+
export interface ListenerRequestCreate {
|
|
28
|
+
/** A record from the request search */
|
|
29
|
+
trackId: string;
|
|
30
|
+
/** What the station should call you. Omitted, you are "a listener": your account's email address is never shown or read out */
|
|
31
|
+
name?: string;
|
|
32
|
+
/** Dedicate it to somebody. The station may say this name on air */
|
|
33
|
+
dedicateTo?: string;
|
|
34
|
+
/** A few words to go with it. The presenter may put them in their own words on air, and leaves out anything unfit to broadcast; the words themselves are never read out */
|
|
35
|
+
message?: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Turn a request down
|
|
39
|
+
* generated from [ListenerRequestDecline](../../../../../apps/api/data/contracts/requests/requests.types.ck#L48)
|
|
40
|
+
*/
|
|
41
|
+
export interface ListenerRequestDecline {
|
|
42
|
+
/** What to tell the listener. Omit for a plain no */
|
|
43
|
+
reason?: string;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Records matching a search, best matches first
|
|
47
|
+
* generated from [RequestableTrackList](../../../../../apps/api/data/contracts/requests/requests.types.ck#L15)
|
|
48
|
+
*/
|
|
49
|
+
export interface RequestableTrackList {
|
|
50
|
+
tracks: RequestableTrack[];
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* A record somebody asked the station to play, and what became of it
|
|
54
|
+
* generated from [ListenerRequest](../../../../../apps/api/data/contracts/requests/requests.types.ck#L23)
|
|
55
|
+
*/
|
|
56
|
+
export interface ListenerRequest {
|
|
57
|
+
id: string;
|
|
58
|
+
/** `waiting` for an operator to approve it, `pending` while its audio is fetched or a place is found for it, `queued` in the running order, `aired` once heard, `declined` or `expired` when it never will be */
|
|
59
|
+
status: RequestStatus;
|
|
60
|
+
/** The record, as it was called when it was asked for */
|
|
61
|
+
title: string;
|
|
62
|
+
artist: string;
|
|
63
|
+
/** Who asked, by the name their account or chat platform gave */
|
|
64
|
+
requesterName: string;
|
|
65
|
+
/** Whether it came from an app or a chat platform */
|
|
66
|
+
source: RequestSource;
|
|
67
|
+
/** When it was asked for */
|
|
68
|
+
createdAt: DateTime;
|
|
69
|
+
/** Why it was declined or expired, in the station's words or an operator's */
|
|
70
|
+
reason?: string;
|
|
71
|
+
/** When it aired */
|
|
72
|
+
airedAt?: DateTime;
|
|
73
|
+
/** Who the listener dedicated it to */
|
|
74
|
+
dedicateTo?: string;
|
|
75
|
+
/** What the listener asked to have said with it, in their own words */
|
|
76
|
+
message?: string;
|
|
77
|
+
}
|
|
78
|
+
/** Rehydrates every wire-encoded scalar in a ListenerRequest into its runtime type. Mutates and returns `raw`. */
|
|
79
|
+
export declare function reviveListenerRequest(raw: ListenerRequest): ListenerRequest;
|
|
80
|
+
/**
|
|
81
|
+
* Requests, newest first
|
|
82
|
+
* generated from [ListenerRequestList](../../../../../apps/api/data/contracts/requests/requests.types.ck#L37)
|
|
83
|
+
*/
|
|
84
|
+
export interface ListenerRequestList {
|
|
85
|
+
requests: ListenerRequest[];
|
|
86
|
+
}
|
|
87
|
+
/** Rehydrates every wire-encoded scalar in a ListenerRequestList into its runtime type. Mutates and returns `raw`. */
|
|
88
|
+
export declare function reviveListenerRequestList(raw: ListenerRequestList): ListenerRequestList;
|
|
89
|
+
//# sourceMappingURL=requests.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requests.types.d.ts","sourceRoot":"","sources":["../../../src/requests/types/requests.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAUjC;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC7B,oDAAoD;IACpD,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,sBAAsB;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,UAAU,GAAG,SAAS,CAAC;AAEhG;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG,MAAM,CAAC;AAE3C;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IAClC,uCAAuC;IACvC,OAAO,EAAE,MAAM,CAAC;IAChB,+HAA+H;IAC/H,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,oEAAoE;IACpE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2KAA2K;IAC3K,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACnC,qDAAqD;IACrD,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACjC,MAAM,EAAE,gBAAgB,EAAE,CAAC;CAC9B;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,iNAAiN;IACjN,MAAM,EAAE,aAAa,CAAC;IACtB,yDAAy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