Giter VIP home page Giter VIP logo

Comments (14)

Korki67 avatar Korki67 commented on July 30, 2024

Hello Themaaft,

for me all is working as before. I once had similar issue when the Echo was set to volume zero. You can make a test by playing some music and issueing the speak command while music is running. If volume of music is reduced or not gives you some additional information to think about when looking for the root cause.

You can also test to replace speak by -e textcommand:'anything you would otherwise say to Alexa'. I used this some time ago as a workaround. Some days later, original command was working again for no known reason.

Regards,
Horst (just another user delighted by the script)

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

Hi Horst,

Thanks for the reply. Ive just tested what you said and no drop in volume when i try the speak command when music playing. also the other command "textcommand" doesnt do anything either, very odd. maybe in a few days it will work again?

Thanks

from alexa-remote-control.

Korki67 avatar Korki67 commented on July 30, 2024

Hello Themaaft,

yeah strange. Do you have more than one Echo? Same issue on another one? You could also try to disconnect the Echo from power and re-connect it and retry if you didn't do that already.

Regards,
Horst

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

Hi,

yes tried them all, same result and yea did the power off/on trick, no jou :(

i shall try again in few days

Thanks

from alexa-remote-control.

adn77 avatar adn77 commented on July 30, 2024

@themaaft you could try setting your curl options to export OPTS='-v --compressed --http1.1' and see if you get a HTTP/1.1 200 in return to your speak request.

Another option would be to remove anything .alexa* in your temp folder and start over.

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

The plot thickens...

if i remove all the .alexa files from temp dir i of course get the expected error:
"ERROR: Amazon Login was unsuccessful. Possibly you get a captcha login screen.
Try logging in to https://alexa.amazon.co.uk with your browser. In your browser
make sure to have all Amazon related cookies deleted and Javascript disabled!"

so i re do the cookies file and with the verbose curl flag set the last message is:

(i do get a few http/200 messages but the last message is a 401)

  • upload completely sent off: 414 out of 414 bytes
    < HTTP/1.1 401
    < Content-Length: 0
    < Connection: keep-alive
    < Server: Server
    < Date: Wed, 20 Oct 2021 11:16:25 GMT
    < x-amz-rid: 35Z7GFXXXXXXXXRQXMYF
    < Cache-Control: no-transform, no-store
    < Vary: Content-Type,Accept-Encoding,X-Amzn-CDN-Cache,X-Amzn-AX-Treatment,User-Agent
    < Permissions-Policy: interest-cohort=()
    < X-Cache: Error from cloudfront
    < Via: 1.1 0d02f7d76448fc6a58a71c5efe4feef2.cloudfront.net (CloudFront)
    < X-Amz-Cf-Pop: LHR3-C2
    < X-Amz-Cf-Id: MYcf4uWg5tH1BBxBXXXXXXXXXXSSSYcA23SZIhETOgYJegZ1Vug==
    <
  • Connection #0 to host alexa.amazon.co.uk left intact

so a 401 error occurs, this happens if i do it on a completely fresh machine too

from alexa-remote-control.

adn77 avatar adn77 commented on July 30, 2024

What do you mean by so i re do the cookies file?
The script should be able to log you in - if all fails by using MFA at least.

I created a new login method similar to the Alexa app. For this to work you'll need a REFRESH_TOKEN.
Download the latest alexa_remote_control.sh
For your convenience I created a packed binary for the Alexa-Cookie retrieval: https://github.com/adn77/alexa-cookie-cli/releases
(make sure to adjust the parameters to your local Amazon login page).

You can read more here https://blog.loetzimmer.de/2021/09/alexa-remote-control-shell-script.html

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

I used to manually get the cookies file from my browser extension and paste it as .alexa.cookie worked fine for a long time

ive just setup a new VM and downloaded the latest alexa_remote_control.sh (made changes to my local language etc) and i also downloaded and ran the Alexa-Cookie retrieval and got the output, pasted that into the alexa_remote_control.sh file, seems to work as far as list all devices etc, so thats all good, but still nothing like, textcommand, speak, get current volume etc. i do however get a http/200 where as before it was a http/401 but still not working, i dont know what has happened as ive changed nothing on my amazon/alexa account nor made any changed to my stuff at home. so at a loss as to why the commands no longer work :(

from alexa-remote-control.

adn77 avatar adn77 commented on July 30, 2024

At least you won't have to copy+paste your .alexa.cookie anymore once we get it working :)

Are you able to login to https://alexa.amazon.co.uk/ in your browser? Could you please verify in the developer console that API calls actually use alexa.amazon.co.uk/api/...

Strange thing is that your devices get loaded from /api/devices-v2/device alright.

Either we're using a wrong endpoint or the syntax is wrong.

What do you get when you run alexa_remote_control.sh -q ?

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

Hi

i can login to https://alexa.amazon.co.uk/ fine :)

im not sure how to find the bit you are after in the developer console?

output of alexa_remote_control.sh -q is:

setting default device to: Mancave
queue info for dev:Mancave type:A1Z88NGR2BK6A2 serial:XXXXXXXXXXXXXXXXX (i masked serial)
{
"playerInfo": {
"hint": null,
"infoText": null,
"isPlayingInLemur": false,
"lemurVolume": null,
"lyrics": null,
"mainArt": null,
"mediaId": null,
"miniArt": null,
"miniInfoText": null,
"playbackSource": null,
"playingInLemurId": null,
"progress": null,
"provider": null,
"quality": null,
"queueId": null,
"state": null,
"template": null,
"transport": null,
"upNextItems": null,
"volume": null
}
}
{
"message": "Device is not connected/initialized"
}
{
"queueInfo": {
"header": null,
"media": null,
"nextPageToken": null,
"previousPageToken": null,
"queueType": null
}
}

i dont understand why it says not connected/initilaised? the device (as all of my alexa) is working fine, when i ask it stuff

Thanks

from alexa-remote-control.

themaaft avatar themaaft commented on July 30, 2024

Well i managaed to get it to work, no idea why this worked tho...

so i changed SET_ALEXA='alexa.amazon.co.uk' to SET_ALEXA='alexa.amazon.com' ran the command alexa_remote_control.sh -q and got "ERROR: no CSRF cookie received"

i changed SET_ALEXA back to SET_ALEXA='alexa.amazon.co.uk' and re ran the command and now it all works???

totally confused, but please it now works

from alexa-remote-control.

adn77 avatar adn77 commented on July 30, 2024

I am pretty sure you now have a cookie which you didn't receive correctly from amazon.co.uk.
I'd be very interested to know which one it is... if you're willing to give it another try:

  1. delete .alexa.cookie (or copy as backup)
  2. run a command with ALEXA='alexa.amazon.com
  3. post the anonymized output of .alexa.cookie
  4. run a command with ALEXA='alexa.amazon.co.uk'
  5. post the anonymized output of .alexa.cookie

from alexa-remote-control.

peti69 avatar peti69 commented on July 30, 2024

I have a similar issue. Commands like -r and -a are working but not speak:XXX.

I am using the latest alexa_remove_control script and the new recommended authentication method.

from alexa-remote-control.

adn77 avatar adn77 commented on July 30, 2024

As I wrote in October, this is probably due to some missing cookie.
We'll never find out unless you provide some (anonymized) data :)

from alexa-remote-control.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.