# Disconnect RTMP published Stream via API

**URL:** <https://community.wowza.com/t/disconnect-rtmp-published-stream-via-api/93000>\
**Category:** Wowza Streaming Engine\
**Created:** [March 16, 2021, 6:59pm UTC](https://community.wowza.com/t/disconnect-rtmp-published-stream-via-api/93000 "2021-03-16T18:59:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chris\_Clark](https://avatars.discourse-cdn.com/v4/letter/c/7bcc69/32.png) [@Chris\_Clark](https://community.wowza.com/u/Chris_Clark)\
**Post date:** [March 16, 2021, 6:59pm UTC](https://community.wowza.com/t/disconnect-rtmp-published-stream-via-api/93000/1 "2021-03-16T18:59:27Z")

</div>

I have a stream that is published to my WSE via a user’s RTMP camera. I want to limit their streaming time to 120 minutes. How do I disconnect their RTMP stream?

I have read numerous other posts in here about how its better to terminate on the camera side ([stop publishing live stream server side](http://community.wowza.com/t/stop-publishing-live-stream-server-side/50386)) but in the case of a GoPro or other camera source which is pure RTMP, how can I terminate the connection server side?

I have numerous IP cameras that have stream files and understand that approach but need a similar disconnect for RTMP.

---

<div class="post-metadata">

**Author:** ![Karel\_Boek](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/karel_boek/32/454_2.png) [@Karel\_Boek](https://community.wowza.com/u/Karel_Boek)\
**Post date:** [March 17, 2021, 3:25pm UTC](https://community.wowza.com/t/disconnect-rtmp-published-stream-via-api/93000/2 "2021-03-17T15:25:40Z")

</div>

That will require some custom development; you could write a plug-in that only allows cameras to stream to your server at certain times of the days. If you’re not familiar with developing plug-ins for Wowza StreamingEngine then you may send a request in the “[Hire a Consultant](http://community.wowza.com/c/hire-a-consultant/7)” forums where external, professional consultants can offer their help.
