---
description: This is a platform for hosting various types of webinars.
---

# WebinarGeek

* [How to set up WebinarGeek](#how-to-set-up-webinargeek)&#x20;
* [How to get the list of webinars through the chat-bot](#how-to-get-the-list-of-webinars-through-the-chat-bot)&#x20;
* [How to register for a webinar through the chat-bot](#how-to-register-to-a-webinar-through-the-chat-bot)&#x20;
* [How to check attendance of the webinar through the chat-bot](#how-to-check-attendance-of-the-webinar-through-the-chat-bot)&#x20;
* [How to get broadcast\_id by the webinar name starting with a specified date and time](#how-to-get-broadcast_id-by-the-webinar-name-starting-with-a-specified-date-and-time)

## How to set up WebinarGeek

To get the token, go to the account settings on [WebinarGeek](https://www.webinargeek.com). You can find it in the top right corner of the screen and after you press the word Account, the drop-down menu opens up, where you need to choose the first option:

![](https://lh3.googleusercontent.com/Lee-ZykbxAuLcQxlMkBPc3Y6VnVWHMZsDYq2c9mQvo-Iz_Ap9zh7skq70L3KlUyek8ZidZLRZDkzSQS1V1lMqoHei9fMsf_yjYlsBCJv47xABGzkKgiW2UlQp7vesFmN9XYXiC_BeaIw0-ZjOw)

Then choose API in the menu on the left

![](https://lh3.googleusercontent.com/WC4vNQctjwbzAjivyHBf99vFi43H_Dw0RKndS132QP3KEeYtTligJLX6gEiUmnf700eOOtF3MHU1POLUlMlEUOWqe3uLPGB2G3EbyF8kpsHOu9eUKM847yOfGhYDRVcFrqCN4u0zxbB7aYPnyg)

After that, the page with the API will open up

![](https://lh5.googleusercontent.com/ySUeCLhtqP-X_osv_Unl1nfwat53d7c9_4g_2riwm0e0kTnJurUy9Db0O8WJSK6bgyRq-8KLlt3Hx4C10qnqEEouYxAsQG6vddVIbFlPYC7-smm83UIvTlbqm8V5OjWZ6V9m-VTj_n_qTDiyxg)

{% hint style="info" %}
If you didn’t get the key, then you need to contact customer support and ask for one.
{% endhint %}

After you get the token, open **Settings -> Project constants** and paste it in the variable **webinargeek\_token**:

![](https://lh4.googleusercontent.com/OMoRvM_wvtkp1GrtMUitICvW8X4oNZ_3ctBnIaS7QaE-GbeobFGDv-cy8Le6yA6trdiMecvi2G414KNO4qQwdWaC6Ya3nSilDxyDxPYhCma6nUUa0fZdL5sv4rVSCVuLZuhlmKV4fMAXJM314w)

## How to get the list of webinars through the chat-bot

To get the list, it’s enough to call the function **webinargeek\_get\_webinar\_list()**:

![](https://lh5.googleusercontent.com/zfjxdCkAhwXTJ8-PAWv4NkbCo84usAF9s8Es_iC1JYsMt5X0nXUlCedA7VO6s8vbJJBOtRz4U3u2SGjDmhdmQQEy0Jj7hILWRb5b6TUEacJJ-TZ0ChqrpoQw6y8y8De17z6QihBUJ_Td8SEwlg)

As a result, there will be a list of webinars in this format:

\['{"id":1455034,"date":"11-05-2022 18:00","name":"Second webinar"}', \
'{"id":1455046,"date":"11-05-2022 18:00","name":"My Webinar"}', \
'{"id":1453081,"date":"04-05-2022 18:00","name":"My first webinar"}']

where

**id** - is the id of the broadcast (broadcast\_id), the value is essential to all other actions with this \
**webinar date** - the date and the time of this broadcast \
**name** - the webinar name

If you share with the function any symbol (it’s best to paste '1'), then the function will show only those webinars that aren’t finished yet, and if you don’t paste anything then it will also show the finished ones.

## How to register for a webinar through the chat-bot

For the registration you need the function **webinargeek\_get\_webinar\_list(broadcast\_id, name, email)**, where

**broadcast\_id** - the broadcast’s id for which you need to register the client \
**name** - the client’s name that will be shown in the chat \
**email** - the email address to which the invitation to the webinar with the link will come

Without these parameters you can’t register a client through the bot.

**Example:** \
url = webinargeek\_add\_subscriber(1455046, 'John Smith', 'john\_smith@gmail.com’)

![](https://lh6.googleusercontent.com/mCz3rupL1g9oWy5sZqIqYZGh9J0qnJQgRQcHnaP_AuXPoddR0IA17Z0OvLuANQo-pi9Ga5Sf8yfmsWQ8YhvnLx_o2kSx38QhtNaZFCrZIoK8SC0If2NJ0SWrxwYLaMiWY72EyQLqIVj1mamOsA)

As a result, this variable will hold the link to the webinar through which the user won’t need to register. All user data is set in this variable.

Also, after the function execution, there will be two variables added to the client’s card:

**webinargeek\_broadcast\_id** - the id of the broadcast the user was registered for \
**webinargeek\_email** - the email that was specified in the registration

These variables will be useful for checking the user’s attendance of the webinar.

## How to check attendance of the webinar through the chat-bot

To check attendance, you’ll need this function **webinargeek\_is\_visitor(webinargeek\_broadcast\_id, webinargeek\_email)**, where

**webinargeek\_broadcast\_id** - the id of the broadcast the user was registered for \
**webinargeek\_email** - the email that was specified in the registration \
**watch\_minimum** - (optional parameter) the minimum amount of minutes by which the function identifies if the attendance is counted as one or no

**watch = webinargeek\_is\_visitor(webinargeek\_broadcast\_id, webinargeek\_email)**

![](https://lh6.googleusercontent.com/gQ03L945VLCgJuKstGANE3gPxpq5cy9pMDzAmFmrotxR7rLhtrr1-zyVyHJ9ixwqHxiPT9Jj1kDogriLns5PwX0JHwDIHwzz2CQHk0h3mv4J9gj7NhFT3OFrPFnX8EEVisDBPFwPchFva_o4og)

A reply will be pasted in the variable:

* If the webinar wasn’t finished yet, then this text comes as a reply: “Webinar not ended yet”;&#x20;
* If the client didn’t watch the webinar, then this comes as a reply: “False”;&#x20;
* If the client watched the webinar and the parameter **watch\_minimum** wasn’t used, then this comes as a reply: “True”; \
  If the parameter **watch\_minimum** was used, then the function will check the amount of time the client watched it and:&#x20;
  * If the client watched it for a lesser amount than what was put as the minimum, this comes as a reply: “False”;
  * If the amount of time the client watched the webinar for is equal or higher than the specified amount, then this comes as a reply: “True”.

## How to get broadcast\_id by the webinar name starting with a specified date and time

To get the broadcast\_id of a specified webinar you need the function **webinargeek\_search\_broadcast\_id()** with these parameters:

**webinar\_list** - here you need to transfer the variable that holds the function **webinargeek\_get\_webinar\_list()** result \
**webinar\_name** - the name of the webinar which broadcast\_id you need to find \
**webinar\_date** - the date of the broadcast of the dd.mm.yyyy format. You can also use **curret\_date** \
**webinar\_time** - the time of the broadcast of the hh:mm format, where hh = hours and mm = minutes

**Example:** \
webinar\_list = webinargeek\_get\_webinar\_list() \
broadcast\_id = webinargeek\_search\_broadcast\_id(webinar\_list, 'Second webinar', current\_date-4, '18:00'

![](https://lh5.googleusercontent.com/hLM4geSphPzR30tVjEsisVtlNKboGeuHEQkdkhRDuGqEyn-7y_nm36HDq1wLWSSSMt1NJFqvhVRYekCfNGCFQl7dUvXfe1D7-uVHyr9qJAV0I346SXSC8oPA4h7uMuqgRGpwwQKu1mvN_EXWLw)

Here we’re trying to find the id of the broadcast that was happening 4 days before the current date at 6pm and was called “Second webinar”.

If the webinar that corresponds to the parameters was in the list, then the function returns the id of the found webinar to the broadcast\_id variable.

If such a webinar wasn’t found, then this text is pasted instead: "No webinar with these parameters".
