@deadair/sdk 0.87.0 → 0.87.2
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/index.js +55 -17
- package/dist/index.js.map +1 -1
- package/dist/render/render.client.d.ts +6 -1
- package/dist/render/render.client.d.ts.map +1 -1
- package/dist/render/types/render.types.d.ts +22 -0
- package/dist/render/types/render.types.d.ts.map +1 -1
- package/dist/stream/stream.client.d.ts +6 -0
- package/dist/stream/stream.client.d.ts.map +1 -1
- package/dist/stream/types/index.d.ts +1 -0
- package/dist/stream/types/index.d.ts.map +1 -1
- package/dist/stream/types/stream.listeners.types.d.ts +43 -0
- package/dist/stream/types/stream.listeners.types.d.ts.map +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4692,6 +4692,16 @@ var RenderClient = class {
|
|
|
4692
4692
|
});
|
|
4693
4693
|
return await parseJson(result);
|
|
4694
4694
|
}
|
|
4695
|
+
/**
|
|
4696
|
+
* @name Read segment sources
|
|
4697
|
+
* @description The stored facts a written break was handed, the ones it said first
|
|
4698
|
+
*/
|
|
4699
|
+
async readSegmentSources(id) {
|
|
4700
|
+
const result = await this.fetch(`/segments/${encodeURIComponent(id)}/sources`, {
|
|
4701
|
+
method: "GET"
|
|
4702
|
+
});
|
|
4703
|
+
return await parseJson(result);
|
|
4704
|
+
}
|
|
4695
4705
|
/**
|
|
4696
4706
|
* @name Get segment audio
|
|
4697
4707
|
* @description The audio of one segment
|
|
@@ -5691,7 +5701,7 @@ var StorageClient = class {
|
|
|
5691
5701
|
}
|
|
5692
5702
|
};
|
|
5693
5703
|
|
|
5694
|
-
// src/stream/types/stream.
|
|
5704
|
+
// src/stream/types/stream.listeners.types.ts
|
|
5695
5705
|
import { DateTime as DateTime24 } from "luxon";
|
|
5696
5706
|
var __dt24 = /* @__PURE__ */ __name((v, path) => {
|
|
5697
5707
|
if (typeof v !== "string") {
|
|
@@ -5701,11 +5711,28 @@ var __dt24 = /* @__PURE__ */ __name((v, path) => {
|
|
|
5701
5711
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5702
5712
|
return d;
|
|
5703
5713
|
}, "__dt");
|
|
5714
|
+
function reviveStreamListeners(raw) {
|
|
5715
|
+
const __o0 = raw;
|
|
5716
|
+
__o0["readAt"] = __dt24(__o0["readAt"], "StreamListeners.readAt");
|
|
5717
|
+
return raw;
|
|
5718
|
+
}
|
|
5719
|
+
__name(reviveStreamListeners, "reviveStreamListeners");
|
|
5720
|
+
|
|
5721
|
+
// src/stream/types/stream.archive.types.ts
|
|
5722
|
+
import { DateTime as DateTime25 } from "luxon";
|
|
5723
|
+
var __dt25 = /* @__PURE__ */ __name((v, path) => {
|
|
5724
|
+
if (typeof v !== "string") {
|
|
5725
|
+
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
5726
|
+
}
|
|
5727
|
+
const d = DateTime25.fromISO(v);
|
|
5728
|
+
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5729
|
+
return d;
|
|
5730
|
+
}, "__dt");
|
|
5704
5731
|
function reviveRecording(raw) {
|
|
5705
5732
|
const __o0 = raw;
|
|
5706
|
-
__o0["startedAt"] =
|
|
5733
|
+
__o0["startedAt"] = __dt25(__o0["startedAt"], "Recording.startedAt");
|
|
5707
5734
|
if (__o0["endedAt"] != null) {
|
|
5708
|
-
__o0["endedAt"] =
|
|
5735
|
+
__o0["endedAt"] = __dt25(__o0["endedAt"], "Recording.endedAt");
|
|
5709
5736
|
}
|
|
5710
5737
|
return raw;
|
|
5711
5738
|
}
|
|
@@ -5866,6 +5893,16 @@ var StreamClient = class {
|
|
|
5866
5893
|
});
|
|
5867
5894
|
return await parseJson(result);
|
|
5868
5895
|
}
|
|
5896
|
+
/**
|
|
5897
|
+
* @name List stream listeners
|
|
5898
|
+
* @description Who is connected to the station's stream right now, over Icecast and over HLS
|
|
5899
|
+
*/
|
|
5900
|
+
async listStreamListeners() {
|
|
5901
|
+
const result = await this.fetch(`/stream/listeners`, {
|
|
5902
|
+
method: "GET"
|
|
5903
|
+
});
|
|
5904
|
+
return reviveStreamListeners(await parseJson(result));
|
|
5905
|
+
}
|
|
5869
5906
|
};
|
|
5870
5907
|
|
|
5871
5908
|
// src/topics/topics.client.ts
|
|
@@ -5939,27 +5976,27 @@ var TopicsClient = class {
|
|
|
5939
5976
|
};
|
|
5940
5977
|
|
|
5941
5978
|
// src/users/types/users.types.ts
|
|
5942
|
-
import { DateTime as
|
|
5943
|
-
var
|
|
5979
|
+
import { DateTime as DateTime26 } from "luxon";
|
|
5980
|
+
var __dt26 = /* @__PURE__ */ __name((v, path) => {
|
|
5944
5981
|
if (typeof v !== "string") {
|
|
5945
5982
|
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
5946
5983
|
}
|
|
5947
|
-
const d =
|
|
5984
|
+
const d = DateTime26.fromISO(v);
|
|
5948
5985
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5949
5986
|
return d;
|
|
5950
5987
|
}, "__dt");
|
|
5951
5988
|
function reviveUserSummary(raw) {
|
|
5952
5989
|
const __o0 = raw;
|
|
5953
|
-
__o0["createdAt"] =
|
|
5990
|
+
__o0["createdAt"] = __dt26(__o0["createdAt"], "UserSummary.createdAt");
|
|
5954
5991
|
if (__o0["lastSignInAt"] != null) {
|
|
5955
|
-
__o0["lastSignInAt"] =
|
|
5992
|
+
__o0["lastSignInAt"] = __dt26(__o0["lastSignInAt"], "UserSummary.lastSignInAt");
|
|
5956
5993
|
}
|
|
5957
5994
|
return raw;
|
|
5958
5995
|
}
|
|
5959
5996
|
__name(reviveUserSummary, "reviveUserSummary");
|
|
5960
5997
|
function reviveUserSignIn(raw) {
|
|
5961
5998
|
const __o0 = raw;
|
|
5962
|
-
__o0["occurredAt"] =
|
|
5999
|
+
__o0["occurredAt"] = __dt26(__o0["occurredAt"], "UserSignIn.occurredAt");
|
|
5963
6000
|
return raw;
|
|
5964
6001
|
}
|
|
5965
6002
|
__name(reviveUserSignIn, "reviveUserSignIn");
|
|
@@ -5994,30 +6031,30 @@ function reviveUserDetail(raw) {
|
|
|
5994
6031
|
__name(reviveUserDetail, "reviveUserDetail");
|
|
5995
6032
|
|
|
5996
6033
|
// src/users/types/invitations.types.ts
|
|
5997
|
-
import { DateTime as
|
|
5998
|
-
var
|
|
6034
|
+
import { DateTime as DateTime27 } from "luxon";
|
|
6035
|
+
var __dt27 = /* @__PURE__ */ __name((v, path) => {
|
|
5999
6036
|
if (typeof v !== "string") {
|
|
6000
6037
|
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
6001
6038
|
}
|
|
6002
|
-
const d =
|
|
6039
|
+
const d = DateTime27.fromISO(v);
|
|
6003
6040
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
6004
6041
|
return d;
|
|
6005
6042
|
}, "__dt");
|
|
6006
6043
|
function reviveInvitationDetails(raw) {
|
|
6007
6044
|
const __o0 = raw;
|
|
6008
|
-
__o0["expiresAt"] =
|
|
6045
|
+
__o0["expiresAt"] = __dt27(__o0["expiresAt"], "InvitationDetails.expiresAt");
|
|
6009
6046
|
return raw;
|
|
6010
6047
|
}
|
|
6011
6048
|
__name(reviveInvitationDetails, "reviveInvitationDetails");
|
|
6012
6049
|
function reviveInvitation(raw) {
|
|
6013
6050
|
const __o0 = raw;
|
|
6014
|
-
__o0["createdAt"] =
|
|
6015
|
-
__o0["expiresAt"] =
|
|
6051
|
+
__o0["createdAt"] = __dt27(__o0["createdAt"], "Invitation.createdAt");
|
|
6052
|
+
__o0["expiresAt"] = __dt27(__o0["expiresAt"], "Invitation.expiresAt");
|
|
6016
6053
|
if (__o0["acceptedAt"] != null) {
|
|
6017
|
-
__o0["acceptedAt"] =
|
|
6054
|
+
__o0["acceptedAt"] = __dt27(__o0["acceptedAt"], "Invitation.acceptedAt");
|
|
6018
6055
|
}
|
|
6019
6056
|
if (__o0["revokedAt"] != null) {
|
|
6020
|
-
__o0["revokedAt"] =
|
|
6057
|
+
__o0["revokedAt"] = __dt27(__o0["revokedAt"], "Invitation.revokedAt");
|
|
6021
6058
|
}
|
|
6022
6059
|
return raw;
|
|
6023
6060
|
}
|
|
@@ -6448,6 +6485,7 @@ export {
|
|
|
6448
6485
|
reviveStepUpStartResponse,
|
|
6449
6486
|
reviveStepUpStartResponseOutput,
|
|
6450
6487
|
reviveStorageReport,
|
|
6488
|
+
reviveStreamListeners,
|
|
6451
6489
|
reviveTraceDecision,
|
|
6452
6490
|
reviveTraceDetail,
|
|
6453
6491
|
reviveTraceSpan,
|