I want to make a python program that can check if a google meet is open/available to join (like doing ping meet.google.com/custom-meeting-link from cmd). Is there any modules I could use/any way of doing this?
Asked
Active
Viewed 698 times
2 Answers
1
If ping method works you can use that (even if not in native python)
import subprocess
ret = subprocess.run(["ping", "https://meet.google.com/custom-meeting-link"])
And then check ret
.
EDIT: A different method is to requests the page and parse it. Keeping it simple, you can just check the title of the page (here using bs4
):
import requests
from bs4 import BeautifulSoup
html = requests.get("meet.google.com/custom-meeting-link")
soup = BeautifulSoup(html.text, 'html.parser')
titlestring = soup.find('title').text
# If title string contains the title of the error page, there's no meeting, else it is online
I checked if it was possible to infer the meeting status just from the requests.get()
response but it doesn't seem possible.

frab
- 1,162
- 1
- 4
- 14
-
I can't ping meet.google.com/custom-meeting-link. I get the error `Ping request could not find host meet.google.com/custom-meeting-link. Please check the name and try again.` I can ping the url "meet.google.com" though, just not with a custom meeting link after. (I can't ping the meet from python or cmd). – John Smith Jan 19 '21 at 09:32
-
I edited the answer with an alternative method – frab Jan 20 '21 at 00:34
-
That looks like a good solution but it is getting an error: `Traceback (most recent call last): File "F:\test.py", line 5, in
soup = BeautifulSoup(html, 'html.parser') File "C:\Users\User\AppData\Local\Programs\Python\Python39\lib\site-packages\bs4\__init__.py", line 310, in __init__ elif len(markup) <= 256 and ( TypeError: object of type 'Response' has no len()` The url's I tried were: 1. https://meet.google.com/lookup/custom-meeting-link 2. meet.google.com/lookup/custom-meeting-link (I also tried without the /lookup/) – John Smith Jan 20 '21 at 15:07 -
Sorry, forgot to add .text in beautifulsoup call. Check it now – frab Jan 20 '21 at 15:15
-
That sort of works. I have printed title string but I always get the output "Meet", even if it is closed or it doesn't exist. I used "https://meet.google.com/eek-sdh-etw" as a test (it doesn't exist) but I still get the output "Meet" – John Smith Jan 20 '21 at 15:47
0
I have never worked with Google Meet before, but you can probably detect if a Google meet is open with their API

CryptoFool
- 21,719
- 5
- 26
- 44

Mathis Côté
- 156
- 1
- 5
-
1I have looked at this before but I can't see a way to check if a specific meet is open. – John Smith Jan 19 '21 at 09:50