# Broken REST API or bad documentation on disconnect incoming stream

**URL:** <https://community.wowza.com/t/broken-rest-api-or-bad-documentation-on-disconnect-incoming-stream/49150>\
**Category:** Wowza Streaming Engine\
**Tags:** wowza-streaming-server-java-api\
**Created:** [July 7, 2017, 6:38pm UTC](https://community.wowza.com/t/broken-rest-api-or-bad-documentation-on-disconnect-incoming-stream/49150 "2017-07-07T18:38:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kev\_Zettler](https://avatars.discourse-cdn.com/v4/letter/k/f475e1/32.png) [@Kev\_Zettler](https://community.wowza.com/u/Kev_Zettler)\
**Post date:** [July 7, 2017, 6:38pm UTC](https://community.wowza.com/t/broken-rest-api-or-bad-documentation-on-disconnect-incoming-stream/49150/1 "2017-07-07T18:38:21Z")

</div>

I am having the same unsolved problem as: [http://community.wowza.com/community/questions/7796/rest-api-endpoint-to-disconnect-incoming-stream-is.html#post165545](http://community.wowza.com/community/questions/7796/rest-api-endpoint-to-disconnect-incoming-stream-is.html#post165545)

The documentation suggests a PUT request. If I change the request from PUT to GET

```auto
GET http://wowzadev:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/test1/instances/_definst_/incomingstreams/mmuid_100_3ac566a6-4402-4c76-a163-b14a612b608c/actions/disconnectStream

```

I get a non 404 response:

```auto
<wmsResponse> <success>false</success> <message>Unknown action: disconnectStream</message> </wmsResponse>

```

I’ve tried many actions. This is on

```auto
<wowzaServer>4.7.0</wowzaServer> 

```

---

<div class="post-metadata">

**Author:** ![Miguel\_Alatorre](https://avatars.discourse-cdn.com/v4/letter/m/aca169/32.png) [@Miguel\_Alatorre](https://community.wowza.com/u/Miguel_Alatorre)\
**Post date:** [July 21, 2017, 11:01pm UTC](https://community.wowza.com/t/broken-rest-api-or-bad-documentation-on-disconnect-incoming-stream/49150/2 "2017-07-21T23:01:02Z")

</div>

I’m experiencing the same issue on 4.7.0. Here’s the response:

```auto
PUT request sent to:
/v2/servers/_defaultServer_/vhosts/_defaultVHost_/streamfiles/<STREAM_NAME>/actions/disconnectStream

Response:
{

  status: 200,

  data: {

    success: false,

    message: 'Unknown action: disconnectStream',

    data: null

  }

}

```

---

<div class="post-metadata">

**Author:** ![Michelle\_B](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/michelle_b/32/394_2.png) [@Michelle\_B](https://community.wowza.com/u/Michelle_B)\
**Post date:** [July 22, 2017, 12:39am UTC](https://community.wowza.com/t/broken-rest-api-or-bad-documentation-on-disconnect-incoming-stream/49150/3 "2017-07-22T00:39:03Z")

</div>

Hi Kev,

This issue was addressed in ticket #238094, and I am posting it here for others as well. The disconnect endpoint should be called with a PUT and not a GET request, which is why the GET request was returning an error for you.

Your PUT request, while correctly formed, was failing because the incoming stream in your command is not a valid one. This command is only applicable to streams that have been connected via the [MediaCaster](https://www.wowza.com/docs/stream-management-query-examples) system. If your incoming stream was pushed to the Wowza server (for encoders such as Wirecast and GoCoder) where the connection was not initiated on the server, then your Wowza server would be unable to disconnect the stream.

Michelle
