Unable to send a local mp3 on alexa

First , i am on Amazon.fr
i can’t send a local mp3 on my alexa echo

service: media_player.play_media
data:
media_content_id: http://192.168.y.xxx:8123/local/Alarm-System_alarm1.mp3
media_content_type: music
target:
entity_id: media_player.echo_dot_carlier

have you a solution ? THANKS

as far as I know (unless something has recently changed) there has never been a way for any Echo to play a local MP3.

How can i, in an automation, use alexa to send a alarm voice ?

thanks

you can play a local file only iuf it’s accessible via the internet.

If you have a Nabu Casa subscription and you have the Alexa Media Player custom component installed then you can play the media that way using the following example:

        service: notify.alexa_media
        data:
          message: "<audio src='https://<my_nabu_csa_url>.ui.nabu.casa/local/mp3/nws_alert_tone.mp3' />"
          target: 
            - media_player.computer_room_dot
            - media_player.kitchen_dot
            - media_player.livingroom_dot
            - media_player.lg_webos_tv_echo
          data:
            type: tts

or you could use an offsite file storage such as dropbox to host the file.

thanks

can you explain the second solution (‘dropbox’) and an exemple of code please

I’ve never used it for playing an mp3 thru an echo but here is what I used to use for playing an mp3 via my chromecast audio:

     - service: media_player.play_media
        data:
          entity_id: media_player.chromecastaudio1984
          media_content_id: "https://www.dropbox.com/s/<my_dropbox>/trespass_warning.mp3?dl=0&raw=1"
          media_content_type: audio/mp4

you should be able to just change the previous post above URL to the dropbox URL (keeping the same format) and I think it should work.

so something like:

        service: notify.alexa_media
        data:
          message: "<audio src='https://www.dropbox.com/s/<my_dropbox>/trespass_warning.mp3' />"
          target: 
            - media_player.computer_room_dot
            - media_player.kitchen_dot
            - media_player.livingroom_dot
            - media_player.lg_webos_tv_echo
          data:
            type: tts

thanks but where i can found <my_dropbox> ?

ok i have it

but doen’t work…

alexa says ‘no possible to access for the moment…’ in french
but i can access it with the url on chrome

service: notify.alexa_media_echo_dot_carlier
data:
message: >-

service: notify.alexa_media_echo_dot_carlier
data:
message: >-
<audio
src=https://www.dropbox.com/s/…/Alarm-System_alarm1.mp3?dl=0&raw=1
/>
data:
type: tts