Open Specific Netflix Movie with Alexa
-
@Felipe-Guedes, no, I updated the code on the server to handle the problem when Alexa sends comando with the trigger word. I'm hoping that solves the problem you're having.
-
When i said the command like you said, alexa anwser me a helper to execute the command.
-
@Felipe-Guedes, are you saying Alexa answered this way again?
Diga algo como execute a calculadora no laptop, você também pode dizer para se já estiver terminado.
Also, if you go to https://alexa.amazon.com/ you can see the words Alexa thinks you said. Can you copy/paste that here?
This is what mine showed:
-
Sorry, i don't see this msg.
Yes, Alexa answer exactly this.Diga algo como execute a calculadora no laptop, você também pode dizer para se já estiver terminado.
-
@Felipe-Guedes, does this site work in Brazil or is this just the english or US version of Alexa web?
https://alexa.amazon.com/spa/index.html#cards
I was hoping you could use that site because it's helpful to know what Alexa is hearing.Also, if this is too much to ask, no problem, but would you mind sending me a recording of yourself saying, this?
Alexa, pergunte Execute Comando executar automação com o parâmetro bos baby.
I might be able to use the recording to "train" Alexa to hear it correctly.Thank you for your patience.
-
its that !
-
@Russ How i send you my voice record?
-
@Felipe-Guedes, you could use one device, like your computer to play it using that play button: ... and use another device, like your phone to record it.
-
@Russ Hello, Russ. I didn't get lucky with this javascript here and I have created my own using Python + Selenium. It actually does the same thing. Opens the browser, inserts the credentials, searchs for the movie (parameter), plays it and puts it on fullscreen. If someone is interested, I can share the code.
But actually, my reply is about the way we talk to Alexa to run the script. I'm from Brazil as well... When I'm using "Execute comando" it doesn't feel natural. Most of it is because the "pergunte" in the beginning. Something more like "Alexa, Execute Comando YYYY com parâmetro XXXX" would feel better.
The "execute comando" needs to be part of the phrase and not the name of the service to feel more natural.
-
@Adalberto eu tenho interesse em testar esse código de puder compartilhar amigo. Muito obrigado.
-
- You will need to install Python and Selenium
- Video for reference (PT-BR):
- Python: https://www.youtube.com/watch?v=FcfalMf9bRY
- Selenium: https://www.youtube.com/watch?v=Ot10qzrb13c (choose the version compatible with your browser)
- Remember to put Python on windows PATH (during installation)
from selenium import webdriver from selenium.webdriver.common.keys import Keys from selenium.webdriver.common.by import By from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditions as EC import time import sys if len(sys.argv) == 2: movie = sys.argv[1] else: movie = ' '.join(sys.argv[1:]) # You can put the chromedriver wherever you want - you can download it from http://seleniumhq.github.io/selenium/docs/api/javascript/ PATH = r"C:\chromedriver.exe" # You can select any browser available for Selenium driver = webdriver.Chrome(PATH) #Netflix login initial page driver.get("https://www.netflix.com/br/login") element = driver.find_element_by_name("userLoginId") #Insert your email element.send_keys("netflixacc@gmail.com") time.sleep(0.2) #Insert your password element2 = driver.find_element_by_name("password") element2.send_keys("netflixpassword") time.sleep(0.3) element2.send_keys(Keys.RETURN) time.sleep(2) #Insert your profile name as seen after you log in profile = driver.find_element_by_link_text("netflixprofilename") profile.click() time.sleep(3) search = driver.find_element_by_class_name("searchBox") search.click() time.sleep(1) searchbox = driver.find_element_by_name("searchInput") searchbox.send_keys(movie) time.sleep(0.5) searchbox.send_keys(Keys.RETURN) time.sleep(2) scene = driver.find_element_by_xpath("/html/body/div[1]/div/div/div[1]/div/div[2]/div/div/div/div[2]/div/div/div[1]/div/div/div/div/div/div[1]") scene.click() time.sleep(0.5) submit = driver.find_element_by_xpath("//button[@class='color-primary hasLabel hasIcon ltr-1jnopvq']") submit.click() time.sleep(5) move = driver.find_element_by_xpath("//button[@class='touchable PlayerControls--control-element nfp-button-control default-control-button button-nfplayerBack tooltip-button tooltip-button-pos-center tooltip-button-align-right']") move.send_keys(Keys.TAB) time.sleep(0.5) fullscreen = driver.find_element_by_xpath("//button[@class='touchable PlayerControls--control-element nfp-button-control default-control-button button-nfplayerFullscreen']") fullscreen.click()
On TRIGGERcmd:
Trigger: Search on Netflix
(EXAMPLE) Command: start C:\PycharmProjects\netflix\netflix.py
(You need to put your py file directory)
Ground: foreground
Voice: netflix
Allow parameters: truePortuguese:
Activate Execute Comando skill on Alexa app
To Alexa: "Alexa, pergunte Execute Comando executar netflix com parâmetro the alienist"English:
Activate TRIGGERcmd skill on Alexa app
To Alexa: "Alexa, ask TRIGGERcmd to run netflix on the alienist"Any updates I will edit the post. There are things that I want to improve (like the sleep time)
-
plz, everything worked fine, but seach bar isnt working :(, what can i do? -
@Devilsir alexa cnt recognize "parametro" commands, if i tell her turn on "netflix" it works, but without parameters
-
@AdalbertUma pergunta, eu uso python, quando procuro que o argumento está vazio, você poderia me ajudar com qual seria o problema, por favor
-
@Nico-Ramirez, Google Translate translated what you said to this:
Question, I use python, when I make sure that the argument is empty, could you help me with what serious or problem, pleaseI'm not sure what the problem is. Please clarify.
-
-