• Guys i need help. I have no idea from where should i get this AVS refresh token.
    any1 can help?

  • @davidrq7 check with the guys here:

  • @davidrq7 said in AlexaPi:

    Guys i need help. I have no idea from where should i get this AVS refresh token.
    any1 can help?

    You need to set up an account with Amazon… when you installed alexapi did you follow the initial instructions?

    You will need to set up your account and follow the steps to enter several details in there… also to edit the Web part in section 2, where you enter the 4 http parts as directed to in the instructions, and when you have completed all the sections on Amazon, you then have to go back into your account via a browser and going to localhost 5050 as stated in the directions.

    When you do this, you will then be faced with a white window saying ''congratulations, here is your Token, it will be placed in your YAML file for you" it will automatically insert the token letters/numbers, and the other 2 sections of letters/numbers into your YAML file for you… then follow next steps, which include changing a few settings within your YAML file ( I did this through the Terminal window) … these include changing to Pulseaudio… changing VLC to sox… ensuring you put magicmirror and NOT raspberrypi…

    Other posts suggest that if sox wont work for you, then change back to VLC… It is a bit of a Hit or Miss I think, so you really do need to play about with several settings to see which works for you.

  • ( I am no expert here, but wondering why you have Magic Mirror HTTP Server - :5055 ?)
    It states that you should use the port :5050 in the instructions when setting it up on Amazon.
    Can you tell me why you put 5055 there?

  • @johnnyboy dunno why, guess i make a mistake. but now i reinstall AlexaPi and make everythink step by step and i have error when i use to use my LocalIp:5050 0_1492682163943_error.jpg
    my config is 0_1492682279256_error1.jpg

  • @davidrq7

    Yeah, I got that too… Do not worry about that as it is as if the Amazon server is busy or something… I got that 3 times and just waited with browser window open there… Then I think I just closed down browser and tried again twice before I actually got it.
    It will appear, just when Amazon is not so busy.

  • @johnnyboy ill wait mby it will be ok. But i found at forum somethink like this" Description of problem:

    If you already have a config file the installer will ask if you want to Keep, Edit or Delete, choosing Keep it does exit the installer even if there is no token saved in the config file. You need to run manually python to finish the configuration."
    Do you think it will help it this case? How should i run it btw?

  • @davidrq7

    I did the install 4 times, and in each instance I created a new file instead of keeping the old one… Incase the old one was my problem.
    I am unsure about the auth_web,py part for alexapi… as I seen no mention to use this in the instructions, but I have seen this file in the folder.

    When I first used another alexa instal, I had to write a python script for that one, but Im sure that alexa instal was an old version, or a different version… not the alexapi that we are using now here… Im not 100% sure of the name, but think it was alexa-client?

  • Yeah, it was Alexa-client… That never worked for me, and also had a different input where you used the auth_web,py script.

    Alexa Client
    Python client for Amazon's Alexa Voice Service (AVS).
    Amazon Developer Account
    In order to use Alexa Voice Service you will need to signup for an Amazon Developer account. You can read about it on my blog post and get the details from Amazon's Getting Started Guide.
    In order to access Alexa Voice Service, you will also need to make an Authorization Code Grant request to get a refresh token. This is detailed in Amazon's guide.
    See the Authorization Code Grant section below for an example of how to do this.
        Clone this repository
        git clone
        Configure settings. Set the PRODUCT_ID, CLIENT_ID, CLIENT_SECRET, and REFRESH_TOKEN values in alexa_client/
        Note: If you do not have a refresh token, see the Authorization Code Grant section below for an example of how to get one.
        Install requirements
        pip install -r requirements.txt
        Install alexa_client
        python install
    Authorization Code Grant
    The Python script, is included in this repository to make it easier to request an Authorization Code Grant as detailed in Amazon's guide.
    NOTE: The script is taken and modified from the respeaker/Alexa Github repository.
    You should have followed Amazon's Getting Started Guide and created a developer account as well as a new Alexa Voice Service device with a Security Profile.
    You should now have the following values and they should be saved in alexa_client/
        Device Type ID
        Client ID
        Client Secret
    In order to authorize a client, you will also need to configure the Web Settings tab of the Security Profile of your device.
        Log into the Amazon Developer Portal and navigate to the Alexa Voice Service section. Click on the device you created in the list.
        Click on Security Profile on the left menu.
        Click on the Web Settings tab
        Click on the Edit button and add the following:
            Allowed Origins: http://localhost:3000/
            Allowed Return URLs: http://localhost:3000/authresponse
        Click the Save button to save the settings.
    Install the requirements for
        sudo pip install -r auth_web_requirements.txt
    Now you can run the script.
        Run the script: python
        Open a web browser and go to http://localhost:3000
        You should be redirected to an Amazon Login page. Enter your username and password and login.
        You should now see a simple page that says Success! and the refresh token value.
        Copy the refresh token value and set it in alexa_client/
    Some sample tests are available in the test directory. Once installed and configured, you can run them to check if everything is working.
        Test a single request: python test/
        Test multiple concurrent requests: python test/

  • @johnnyboy thx so ill just wait for Amazon response . Thx for Your time!

Log in to reply

Looks like your connection to MagicMirror Forum was lost, please wait while we try to reconnect.