@deadair/sdk 0.86.4 → 0.87.1
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 +45 -17
- package/dist/index.js.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 +3 -3
package/dist/index.js
CHANGED
|
@@ -5691,7 +5691,7 @@ var StorageClient = class {
|
|
|
5691
5691
|
}
|
|
5692
5692
|
};
|
|
5693
5693
|
|
|
5694
|
-
// src/stream/types/stream.
|
|
5694
|
+
// src/stream/types/stream.listeners.types.ts
|
|
5695
5695
|
import { DateTime as DateTime24 } from "luxon";
|
|
5696
5696
|
var __dt24 = /* @__PURE__ */ __name((v, path) => {
|
|
5697
5697
|
if (typeof v !== "string") {
|
|
@@ -5701,11 +5701,28 @@ var __dt24 = /* @__PURE__ */ __name((v, path) => {
|
|
|
5701
5701
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5702
5702
|
return d;
|
|
5703
5703
|
}, "__dt");
|
|
5704
|
+
function reviveStreamListeners(raw) {
|
|
5705
|
+
const __o0 = raw;
|
|
5706
|
+
__o0["readAt"] = __dt24(__o0["readAt"], "StreamListeners.readAt");
|
|
5707
|
+
return raw;
|
|
5708
|
+
}
|
|
5709
|
+
__name(reviveStreamListeners, "reviveStreamListeners");
|
|
5710
|
+
|
|
5711
|
+
// src/stream/types/stream.archive.types.ts
|
|
5712
|
+
import { DateTime as DateTime25 } from "luxon";
|
|
5713
|
+
var __dt25 = /* @__PURE__ */ __name((v, path) => {
|
|
5714
|
+
if (typeof v !== "string") {
|
|
5715
|
+
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
5716
|
+
}
|
|
5717
|
+
const d = DateTime25.fromISO(v);
|
|
5718
|
+
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5719
|
+
return d;
|
|
5720
|
+
}, "__dt");
|
|
5704
5721
|
function reviveRecording(raw) {
|
|
5705
5722
|
const __o0 = raw;
|
|
5706
|
-
__o0["startedAt"] =
|
|
5723
|
+
__o0["startedAt"] = __dt25(__o0["startedAt"], "Recording.startedAt");
|
|
5707
5724
|
if (__o0["endedAt"] != null) {
|
|
5708
|
-
__o0["endedAt"] =
|
|
5725
|
+
__o0["endedAt"] = __dt25(__o0["endedAt"], "Recording.endedAt");
|
|
5709
5726
|
}
|
|
5710
5727
|
return raw;
|
|
5711
5728
|
}
|
|
@@ -5866,6 +5883,16 @@ var StreamClient = class {
|
|
|
5866
5883
|
});
|
|
5867
5884
|
return await parseJson(result);
|
|
5868
5885
|
}
|
|
5886
|
+
/**
|
|
5887
|
+
* @name List stream listeners
|
|
5888
|
+
* @description Who is connected to the station's stream right now, over Icecast and over HLS
|
|
5889
|
+
*/
|
|
5890
|
+
async listStreamListeners() {
|
|
5891
|
+
const result = await this.fetch(`/stream/listeners`, {
|
|
5892
|
+
method: "GET"
|
|
5893
|
+
});
|
|
5894
|
+
return reviveStreamListeners(await parseJson(result));
|
|
5895
|
+
}
|
|
5869
5896
|
};
|
|
5870
5897
|
|
|
5871
5898
|
// src/topics/topics.client.ts
|
|
@@ -5939,27 +5966,27 @@ var TopicsClient = class {
|
|
|
5939
5966
|
};
|
|
5940
5967
|
|
|
5941
5968
|
// src/users/types/users.types.ts
|
|
5942
|
-
import { DateTime as
|
|
5943
|
-
var
|
|
5969
|
+
import { DateTime as DateTime26 } from "luxon";
|
|
5970
|
+
var __dt26 = /* @__PURE__ */ __name((v, path) => {
|
|
5944
5971
|
if (typeof v !== "string") {
|
|
5945
5972
|
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
5946
5973
|
}
|
|
5947
|
-
const d =
|
|
5974
|
+
const d = DateTime26.fromISO(v);
|
|
5948
5975
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
5949
5976
|
return d;
|
|
5950
5977
|
}, "__dt");
|
|
5951
5978
|
function reviveUserSummary(raw) {
|
|
5952
5979
|
const __o0 = raw;
|
|
5953
|
-
__o0["createdAt"] =
|
|
5980
|
+
__o0["createdAt"] = __dt26(__o0["createdAt"], "UserSummary.createdAt");
|
|
5954
5981
|
if (__o0["lastSignInAt"] != null) {
|
|
5955
|
-
__o0["lastSignInAt"] =
|
|
5982
|
+
__o0["lastSignInAt"] = __dt26(__o0["lastSignInAt"], "UserSummary.lastSignInAt");
|
|
5956
5983
|
}
|
|
5957
5984
|
return raw;
|
|
5958
5985
|
}
|
|
5959
5986
|
__name(reviveUserSummary, "reviveUserSummary");
|
|
5960
5987
|
function reviveUserSignIn(raw) {
|
|
5961
5988
|
const __o0 = raw;
|
|
5962
|
-
__o0["occurredAt"] =
|
|
5989
|
+
__o0["occurredAt"] = __dt26(__o0["occurredAt"], "UserSignIn.occurredAt");
|
|
5963
5990
|
return raw;
|
|
5964
5991
|
}
|
|
5965
5992
|
__name(reviveUserSignIn, "reviveUserSignIn");
|
|
@@ -5994,30 +6021,30 @@ function reviveUserDetail(raw) {
|
|
|
5994
6021
|
__name(reviveUserDetail, "reviveUserDetail");
|
|
5995
6022
|
|
|
5996
6023
|
// src/users/types/invitations.types.ts
|
|
5997
|
-
import { DateTime as
|
|
5998
|
-
var
|
|
6024
|
+
import { DateTime as DateTime27 } from "luxon";
|
|
6025
|
+
var __dt27 = /* @__PURE__ */ __name((v, path) => {
|
|
5999
6026
|
if (typeof v !== "string") {
|
|
6000
6027
|
throw new TypeError(`ContractKit: expected an ISO 8601 string at '${path}', received ${typeof v}.`);
|
|
6001
6028
|
}
|
|
6002
|
-
const d =
|
|
6029
|
+
const d = DateTime27.fromISO(v);
|
|
6003
6030
|
if (!d.isValid) throw new TypeError(`ContractKit: '${v}' at '${path}' is not a valid ISO 8601 datetime.`);
|
|
6004
6031
|
return d;
|
|
6005
6032
|
}, "__dt");
|
|
6006
6033
|
function reviveInvitationDetails(raw) {
|
|
6007
6034
|
const __o0 = raw;
|
|
6008
|
-
__o0["expiresAt"] =
|
|
6035
|
+
__o0["expiresAt"] = __dt27(__o0["expiresAt"], "InvitationDetails.expiresAt");
|
|
6009
6036
|
return raw;
|
|
6010
6037
|
}
|
|
6011
6038
|
__name(reviveInvitationDetails, "reviveInvitationDetails");
|
|
6012
6039
|
function reviveInvitation(raw) {
|
|
6013
6040
|
const __o0 = raw;
|
|
6014
|
-
__o0["createdAt"] =
|
|
6015
|
-
__o0["expiresAt"] =
|
|
6041
|
+
__o0["createdAt"] = __dt27(__o0["createdAt"], "Invitation.createdAt");
|
|
6042
|
+
__o0["expiresAt"] = __dt27(__o0["expiresAt"], "Invitation.expiresAt");
|
|
6016
6043
|
if (__o0["acceptedAt"] != null) {
|
|
6017
|
-
__o0["acceptedAt"] =
|
|
6044
|
+
__o0["acceptedAt"] = __dt27(__o0["acceptedAt"], "Invitation.acceptedAt");
|
|
6018
6045
|
}
|
|
6019
6046
|
if (__o0["revokedAt"] != null) {
|
|
6020
|
-
__o0["revokedAt"] =
|
|
6047
|
+
__o0["revokedAt"] = __dt27(__o0["revokedAt"], "Invitation.revokedAt");
|
|
6021
6048
|
}
|
|
6022
6049
|
return raw;
|
|
6023
6050
|
}
|
|
@@ -6448,6 +6475,7 @@ export {
|
|
|
6448
6475
|
reviveStepUpStartResponse,
|
|
6449
6476
|
reviveStepUpStartResponseOutput,
|
|
6450
6477
|
reviveStorageReport,
|
|
6478
|
+
reviveStreamListeners,
|
|
6451
6479
|
reviveTraceDecision,
|
|
6452
6480
|
reviveTraceDetail,
|
|
6453
6481
|
reviveTraceSpan,
|