• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
TRIGGERcmd
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

Open Specific Netflix Movie with Alexa

Windows
8
40
11.8k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F
    Felipe Guedes
    last edited by Aug 2, 2020, 11:08 PM

    its that !
    alexa.PNG

    1 Reply Last reply Reply Quote 0
    • F
      Felipe Guedes @Russ
      last edited by Oct 22, 2020, 8:24 PM

      @Russ How i send you my voice record?

      R 1 Reply Last reply Oct 23, 2020, 12:35 AM Reply Quote 0
      • R
        Russ @Felipe Guedes
        last edited by Oct 23, 2020, 12:35 AM

        @Felipe-Guedes, you could use one device, like your computer to play it using that play button: 1f596754-56ea-4a76-a7f5-92de54da7f62-image.png ... and use another device, like your phone to record it.

        Russell VanderMey

        A 1 Reply Last reply Oct 25, 2020, 11:23 PM Reply Quote 0
        • A
          Adalberto @Russ
          last edited by Adalberto Oct 26, 2020, 9:49 AM Oct 25, 2020, 11:23 PM

          @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.

          A 1 Reply Last reply Oct 26, 2020, 1:42 AM Reply Quote 0
          • A
            André Ricardo da Costa @Adalberto
            last edited by Oct 26, 2020, 1:42 AM

            @Adalberto eu tenho interesse em testar esse código de puder compartilhar amigo. Muito obrigado.

            A 1 Reply Last reply Oct 26, 2020, 11:42 AM Reply Quote 0
            • A
              Adalberto @André Ricardo da Costa
              last edited by Oct 26, 2020, 11:42 AM

              @André-Ricardo-da-Costa

              • 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: true

              Portuguese:
              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)

              N 1 Reply Last reply Oct 21, 2021, 8:58 PM Reply Quote 3
              • D
                Devilsir
                last edited by Apr 15, 2021, 8:15 PM

                Sem título.png
                plz, everything worked fine, but seach bar isnt working :(, what can i do?

                D 1 Reply Last reply Apr 15, 2021, 9:03 PM Reply Quote 0
                • D
                  Devilsir @Devilsir
                  last edited by Apr 15, 2021, 9:03 PM

                  @Devilsir alexa cnt recognize "parametro" commands, if i tell her turn on "netflix" it works, but without parameters

                  1 Reply Last reply Reply Quote 0
                  • N
                    Nico Ramirez @Adalberto
                    last edited by Oct 21, 2021, 8:58 PM

                    @AdalbertUma pergunta, eu uso python, quando procuro que o argumento está vazio, você poderia me ajudar com qual seria o problema, por favor

                    R 1 Reply Last reply Oct 22, 2021, 10:08 PM Reply Quote 0
                    • R
                      Russ @Nico Ramirez
                      last edited by Russ Oct 22, 2021, 10:09 PM Oct 22, 2021, 10:08 PM

                      @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, please

                      I'm not sure what the problem is. Please clarify.

                      Russell VanderMey

                      1 Reply Last reply Reply Quote 0
                      • R Russ referenced this topic on Jan 6, 2022, 1:24 PM
                      • tuicemenT tuicemen referenced this topic on Jan 29, 2022, 3:53 PM
                      • First post
                        Last post