# How to cast videos

**URL:** <https://discourse.nodered.org/t/how-to-cast-videos/25039>\
**Category:** General\
**Created:** [17 April 2020 21:31 UTC](https://discourse.nodered.org/t/how-to-cast-videos/25039 "2020-04-17T21:31:41Z")\
**Posts on this page:** 1\
**Showing post:** 19

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [22 April 2020 09:41 UTC](https://discourse.nodered.org/t/how-to-cast-videos/25039/19 "2020-04-22T09:41:31Z")

</div>

I'm not certain what home-assistant has to do with this?

I cant imagine what setting up a URL to host an MP3 has to do with anything outside of node-red.

The first test in my mind is - can you access the MP3 in your browser? If you cant, then there is no way the cast device is gonna.

On the same machine where node-red is running, what happens if you point your browser at [http://localhost:1880/endpoint/alavp](http://localhost:1880/endpoint/alavp) ?  
do you get anything?

PS - it works for me...  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/7/4733422448e5f7c86d1f9d7456a04c736102deb5.png)

```auto
[{"id":"d5a6dd33.a0e28","type":"http in","z":"c70ba4a4.e7fb58","name":"","url":"/endpoint/alavp","method":"get","upload":false,"swaggerDoc":"","x":110,"y":120,"wires":[["d59c8c4.b480d7","e7ed07e7.97da58"]]},{"id":"d59c8c4.b480d7","type":"file in","z":"c70ba4a4.e7fb58","name":"","filename":"alavp.mp3","format":"","chunk":false,"sendError":false,"encoding":"none","x":180,"y":160,"wires":[["87b9c5b8.526558","49056e53.5a32b"]]},{"id":"87b9c5b8.526558","type":"http response","z":"c70ba4a4.e7fb58","name":"","statusCode":"","headers":{"contentType":"audio/mp3"},"x":360,"y":160,"wires":[]},{"id":"e7ed07e7.97da58","type":"debug","z":"c70ba4a4.e7fb58","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":320,"y":80,"wires":[]},{"id":"49056e53.5a32b","type":"debug","z":"c70ba4a4.e7fb58","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":340,"y":120,"wires":[]},{"id":"b72151a6.617e3","type":"cast-to-client","z":"c70ba4a4.e7fb58","name":"","url":null,"contentType":"","message":null,"language":"en","ip":"","port":"","volume":null,"x":360,"y":220,"wires":[[]]},{"id":"2dbcc2cc.94f80e","type":"inject","z":"c70ba4a4.e7fb58","name":"","topic":"","payload":"{\"ip\":\"192.168.0.55\",\"url\":\"http://192.168.0.81:1880/endpoint/alavp\",\"contentType\":\"audio/mp3\",\"volume\":50}","payloadType":"json","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":80,"y":220,"wires":[["b72151a6.617e3"]]}]

```

NOTES:

- put an MP3 called `alavp.mp3` in the `.node-red` folder (or adjust the path of the file in node)
- change the 2 IP addresses in the `inject` node
  - change "ip" to your cast device IP
  - change "url" to your node-red PC IP

---

_[View the full topic](https://discourse.nodered.org/t/how-to-cast-videos/25039)._
