Hi,
I have an HD DAC that I am trying to control via the HTTP API, but cURL doesn’t seem to be able to connect.
Here’s a few variations I’ve tried:
$ curl -k http://10.0.1.220/httpapi.asp?command=getStatusEx
curl: (7) Failed to connect to 10.0.1.220 port 80 after 9 ms: Connection refused
$ curl -k https://10.0.1.220/httpapi.asp?command=getStatusEx
curl: (56) LibreSSL SSL_read: error:1404C45C:SSL routines:ST_OK:reason(1116), errno 0
$ curl -k https://10.0.1.220:443/httpapi.asp?command=getStatusEx
curl: (56) LibreSSL SSL_read: error:1404C45C:SSL routines:ST_OK:reason(1116), errno 0
$ curl -k https://10.0.1.220:4443/httpapi.asp?command=getStatusEx
curl: (7) Failed to connect to 10.0.1.220 port 4443 after 9 ms: Connection refused
UPnP seems to work fine:
$ curl -H 'Content-Type: text/xml; charset=utf-8' \ ⏎
-H 'SOAPAction: "urn:schemas-upnp-org:service:AVTransport:1#GetInfoEx"' \
-d '<?xml version="1.0" encoding="utf-8"?><s:Envelope s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"><s:Body><u:GetInfoEx xmlns:u="urn:schemas-upnp-org:service:AVTransport:1"><InstanceID>0</InstanceID></u:GetInfoEx></s:Body></s:Envelope>' \
'http://10.0.1.220:49152/upnp/control/rendertransport1'
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body>
<u:GetInfoExResponse xmlns:u="urn:schemas-upnp-org:service:AVTransport:1">
<CurrentTransportState>PLAYING</CurrentTransportState>
<CurrentTransportStatus>OK</CurrentTransportStatus>
<CurrentSpeed>1</CurrentSpeed>
<Track>0</Track>
<TrackDuration>00:03:31</TrackDuration>
<TrackMetaData><?xml version="1.0" encoding="UTF-8"?>
<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:song="www.wiimu.com/song/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/">
<upnp:class>object.item.audioItem.musicTrack</upnp:class>
<item id="0">
<song:subid></song:subid>
<song:description>un_known</song:description>
<song:skiplimit>0</song:skiplimit>
<song:id>0</song:id>
<song:like>0</song:like>
<song:singerid>0</song:singerid>
<song:albumid>0</song:albumid>
<res protocolInfo="http-get:*:audio/mpeg:DLNA.ORG_PN=MP3;DLNA.ORG_OP=01;" duration="00:00:00.000">wiimu_airplay</res>
<dc:title>Blast Ya (feat. Barrington Levy)</dc:title>
<dc:creator>Borgore</dc:creator>
<upnp:artist>Borgore</upnp:artist>
<upnp:album>Blast Ya (feat. Barrington Levy) - Single</upnp:album>
<upnp:albumArtURI></upnp:albumArtURI>
</item>
</DIDL-Lite>
</TrackMetaData>
<TrackURI>wiimu_airplay</TrackURI>
<RelTime>00:03:21</RelTime>
<AbsTime>NOT_IMPLEMENTED</AbsTime>
<RelCount>2147483647</RelCount>
<AbsCount>2147483647</AbsCount>
<CurrentVolume>25</CurrentVolume>
<CurrentChannel>0</CurrentChannel>
<LoopMode>0</LoopMode>
<PlayType>1</PlayType>
<SlaveFlag>0</SlaveFlag>
<MasterUUID></MasterUUID>
<SlaveList>{ "slaves": 0, "wmrm_version": "4.2" }</SlaveList>
<PlayMedium>AIRPLAY</PlayMedium>
<TrackSource></TrackSource>
<InternetAccess>1</InternetAccess>
<VerUpdateFlag>0</VerUpdateFlag>
<VerUpdateStatus>20</VerUpdateStatus>
<BatteryFlag>0</BatteryFlag>
<BatteryPercent>0</BatteryPercent>
<AlarmFlag>0</AlarmFlag>
<TimeStamp>80024298</TimeStamp>
<SubNum>0</SubNum>
<SpotifyActive>0</SpotifyActive>
</u:GetInfoExResponse>
</s:Body> </s:Envelope>
Is there something I am missing or is this a bug?