cli apps

djuka

Member
1709122252424.png


Is this URl of my rest api to catch events? or it is some internal flash phoner app.

if I remove url of RoomApp and put my rest api url my room aplication does not work.
In my rest api I return content for 'connect', 'OnDataEvent' and 'ConnectionStatusEvent', but room app not work.
No connections or published streams.
 

Max

Administrator
Staff member
Hello

Is this URl of my rest api to catch events? or it is some internal flash phoner app.
This is your custom URL.

if I remove url of RoomApp and put my rest api url my room aplication does not work.
This is because your URL should pass request to default app to get this working.

1. You have custom URL, i.e. /myApp
2. Default URL is /RoomApp
3. Your custom URL receives HTTP request /myApp/connect
4. You should forward this request to /RoomApp/connect
5. The /RoomApp/connect will reply with 200 OK
6. You should forward this 200 OK response back to WCS

Therefore your custom app should operate as a reverse proxy passing all requests and responses as is to the RoomApp.

Now it is not working because 'connect', 'OnDataEvent' and 'ConnectionStatusEvent' are not enough.
All methods should be implemented and all RoomApp logic should be implemented.

We will check if we can share RoomApp source implementation via Github.
Then your will be able to check the application logic.
 

djuka

Member
Thank you. I made a proxy method that gets all requests on /apps/RoomApp and pass content to the room app again.
It works now.
What I want to achieve is to catch publishStream event, to get mediaSessionId and to add that Stream to MultipleRecorder.
I did it and I get mediaSessionId and room uri.
But when I send request to 'http://localhost:8081/rest-api/multipleRecorder/add'

Code:
{
    "mediaSessionId": "1c962531-d64a-11ee-a885-e794e541d6c3",
    "uri": "multi-recorder://707f9ee8-33e9-4438-a6d0-6cd61ae60b59"
}

I got 404 route not found.
But same request from Postman works and from curl too.
What could be issue? Maybe timings?
 

Max

Administrator
Staff member
I got 404 route not found.
There is no message Route not found returned by WCS in response on /multipleRecorder/add query. Check what exactly is returned. May be Stream not found or Recorder not found. You can check if stream exists by /stream/find query and if recorder exists by /multipleRecorder/find_all query.
 
Top