@connectedxm/admin 6.4.2 → 6.5.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/index.cjs CHANGED
@@ -203,6 +203,7 @@ __export(index_exports, {
203
203
  CancelGroupInvitation: () => CancelGroupInvitation,
204
204
  ChannelFormat: () => ChannelFormat,
205
205
  CloneEvent: () => CloneEvent,
206
+ CloseStreamSession: () => CloseStreamSession,
206
207
  ConfirmLogin: () => ConfirmLogin,
207
208
  ConnectedXMProvider: () => ConnectedXMProvider,
208
209
  ContentGuestType: () => ContentGuestType,
@@ -2231,6 +2232,7 @@ __export(index_exports, {
2231
2232
  useCancelEventPass: () => useCancelEventPass,
2232
2233
  useCancelGroupInvitation: () => useCancelGroupInvitation,
2233
2234
  useCloneEvent: () => useCloneEvent,
2235
+ useCloseStreamSession: () => useCloseStreamSession,
2234
2236
  useConfirmLogin: () => useConfirmLogin,
2235
2237
  useConnectedCursorQuery: () => useConnectedCursorQuery,
2236
2238
  useConnectedInfiniteQuery: () => useConnectedInfiniteQuery,
@@ -36840,6 +36842,34 @@ var useUploadFile = (options = {}) => {
36840
36842
  return useConnectedMutation(UploadFile, options);
36841
36843
  };
36842
36844
 
36845
+ // src/mutations/stream/useCloseStreamSession.ts
36846
+ var CloseStreamSession = async ({
36847
+ streamId,
36848
+ sessionId,
36849
+ adminApiParams,
36850
+ queryClient
36851
+ }) => {
36852
+ const connectedXM = await GetAdminAPI(adminApiParams);
36853
+ const { data } = await connectedXM.put(
36854
+ `/streams/${streamId}/sessions/${sessionId}/close`
36855
+ );
36856
+ if (queryClient && data.status === "ok") {
36857
+ queryClient.invalidateQueries({
36858
+ queryKey: STREAM_SESSIONS_QUERY_KEY(streamId)
36859
+ });
36860
+ queryClient.invalidateQueries({
36861
+ queryKey: STREAM_SESSION_QUERY_KEY(streamId, sessionId)
36862
+ });
36863
+ queryClient.invalidateQueries({
36864
+ queryKey: STREAM_SESSION_SUBSCRIPTIONS_QUERY_KEY(streamId, sessionId)
36865
+ });
36866
+ }
36867
+ return data;
36868
+ };
36869
+ var useCloseStreamSession = (options = {}) => {
36870
+ return useConnectedMutation(CloseStreamSession, options);
36871
+ };
36872
+
36843
36873
  // src/mutations/stream/useCreateStreamInput.ts
36844
36874
  var CreateStreamInput = async ({
36845
36875
  stream,
@@ -39121,6 +39151,7 @@ var useUploadVideoCaptions = (options = {}) => {
39121
39151
  CancelGroupInvitation,
39122
39152
  ChannelFormat,
39123
39153
  CloneEvent,
39154
+ CloseStreamSession,
39124
39155
  ConfirmLogin,
39125
39156
  ConnectedXMProvider,
39126
39157
  ContentGuestType,
@@ -41149,6 +41180,7 @@ var useUploadVideoCaptions = (options = {}) => {
41149
41180
  useCancelEventPass,
41150
41181
  useCancelGroupInvitation,
41151
41182
  useCloneEvent,
41183
+ useCloseStreamSession,
41152
41184
  useConfirmLogin,
41153
41185
  useConnectedCursorQuery,
41154
41186
  useConnectedInfiniteQuery,