Can't paly a local file on Sonos

Hello,
I’m blocked on a very simple integration. I want to play a greeting audio at 8 pm every day to my integrated sonos.
No way, Sonos app replies me “Impossible to play ‘test.mp4’ the connection to xxxxx.duckdns.org ad been lost”
The url of media file is accessible from outside.

Hereafter my automation code

id: ‘1636410250058’
alias: Sono le 20
description: ‘’
trigger:

  • platform: time
    at: ‘20:00’
    condition: []
    action:
  • service: media_player.play_media
    data:
    media_content_id: https://xxxxx.duckdns.org/local/test.mp4
    media_content_type: music
    target:
    entity_id: media_player.cucina
    mode: single
1 Like

Hi there, instead of the duckdns address, why cant you use the local Ip address and try

Unfortunatley, no result. Simply “Impossible to play ‘test.mp4’ the connection to http://192.168.1.187:8123 as been lost”

Are you sure, your audio is mp4 format?

I think, so. I was successfull to play the file inserting it to a playlist and using the configuration:
service: media_player.play_media
data:
media_content_id: Bigben
media_content_type: playlist
target:
entity_id:
- media_player.cucina

But no way to play it using music tag