Looking for a custom TIDIO chat API WordPress code?
It is a powerful strategy to have a real -time chat solution on your WordPress website. It can not only convert visitors into buyers, but also answer questions to help visitors browse your website.
Over the years, in WP Fix IT, we have the opportunity to cooperate with many popular real -time chat software platforms.
Since early 2020, we have begun to use real -time chat software named Tidio. We accidentally discovered this company from one of the customer websites we provided by WordPress.
Over the years, we have been using another real -time chat software, but the greatest attraction we first paid attention to Tidio is the attraction of chat small components on our client’s website.
Then understand what they must provide through real -time chat solutions, and what makes them different from competitors, we are shocked.
One of our favorite features is their API integration, and how we use it to trigger it to trigger it We have some specific chat messages on different pages in our WordPress website.
This type of integration will enable us to automate things such as capturing visitors’ information and starting chat with new visitors.
Although TIDO does provide documents about how to use its API, we want to create some specific functions we cannot find online.
So we decided to do it ourselves. They are very successful for our company. We hope to find these information with other people who may find these API integrations on their own WordPress website.
We have compiled five powerful Tidio Chat API WordPress code fragments below. You can integrate them to your WordPress website to automatically interact with your website visitor.
Chat installation script – Tidio Chat api wordpress
The script fragment below is the actual installation code running Tidio Chat on your website.
\u0026 lt; script src \u003d \u0026 quot; // code.tidio.co/account_specific_string.js\u0026quot; async \u0026 lt;/script \u0026 gt;
You can use it based on You need to adjust the items in this code:
account_specific_string
- This is what you can find in your Tidio account The script is embedded. See below.
Tidio chat script

Method#1
Putting this code in the foos.php file of the event theme
[[] 123]
Method# 2 Use the free in the link below Put the code fragment in the footer of the event theme https://wordpress.org/plugins/insrt-headers-nd-footers/
Method# 3 Use the Tidio Chat free plug -in that can be found or installed directly from the WordPress management area on WordPress.org. The link of the plugin is as follows. https://wordpress.org/plugins/tidio-live-ll/
Capture user information script-Tidio Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat Chat? API WORDPRESS The following script fragments are classified from the visitors’ names and email addresses in the account information on your website. This will only run when the visitor logs in to your website.

\u0026lt;php if( is_user_logged_in() ) { $current_user \u003d wp_get_current_user(); $current_user_name \u003d $current_user-\u0026gt;user_firstname . \u0026quot; \u0026quot; . $current_user -\u0026gt;user_lastname; $current_user_id \u003d $current_user-\u0026gt;ID; $current_user_mail \u003d $current_user-\u0026gt;user_email; \u0026gt; \u0026lt;script\u0026gt; var user_; // Set customer ID var user_fullname \u003d \u0026quot;\u0026lt;php echo $current_user_name \u0026gt;\u0026quot;; // Set customer email var user_email \u003d \u0026quot;\u0026lt;php echo $current_user_mail \u0026gt;\u0026quot;; // Set customer name document.tidioIdentify \u003d { distinct_id: user_id, email: user_email, name: user_fullname, }; \u0026 lt;/script \u0026 gt;
How to use this code on your WordPress website:

Method#1
Putting this code in the FOOTER.PHP file of the event theme
Method# 2 Use The free plug-in in the link below is placed the code fragment in the footer of the event theme https://wordpress.org/plugins/insrt-headers-nd-footers/ [
Custom visitor name script -Tidio Chat API WordPress The following script fragments are classified from the visitor’s account information on your website. This will only run when the visitor logs in to your website.
\u0026lt;script\u0026gt; document.tidioIdentify \u003d { // You can change visitor name below name: \u0026quot;CUSTOM_VISITOR_NAME\u0026quot;, }; \u0026lt;/script\u0026gt;
[ 123] You can adjust the items in this code as needed:
Name : ”
CUSTOM_VISITOR_NAME “,
如何在您的WordPress 网站上使用此代码:
[ 123] Method#1 Putting this code in the FOOTER.PHP file of the event theme
- Method# 2 Use the free plug-in in the link below to place the code fragment in the footer of the event theme
https://wordpress.org/plugins/insrt-headers-nd-footers/ [ 123]
Customized welcome message script -Tidio Chat API WordPress
The following script fragments will trigger chat customized welcome messages after you choose a period of time.
\u0026lt;script\u0026gt; // Set session cookie name below if(!window.sessionStorage.getItem(\u0026quot;SESSION_COOKIE_NAME\u0026quot;)) { window.sessionStorage.setItem(\u0026quot;SESSION_COOKIE_NAME\u0026quot;, true); (Function () {function onTidioChatApiReady() { setTimeout(function () { // Change message you wish to use below tidioChatApi.messageFromOperator(\u0026quot;CUSTOM MESSAGE HERE\u0026quot;); // Adjsut the time trigger 1000 of message display below }, 5 * 1000); } if (window.tidioChatApi) { window.tidioChatApi.on(\u0026quot;ready\u0026quot;, onTidioChatApiReady); } else { document.addEventListener(\u0026quot;tidioChat-ready\u0026quot;, onTidioChatApiReady); } })(); } \u0026lt;/script\u0026gt ; You can adjust the items in this code as needed:
] If (! Window.SessionStorage.getITEM
Session_cookie_name
\”, really);
Tidiochatapi.messageFromoperator (\”
Custom message
\");
}, 5 *
1000
);
[ 123] How to use this code on your WordPress website:
- Method#1
Method# 2 - https://wordpress.org/plugins/insrt -Headers-And-Footers/
- Customized open chat message script-Tidio Chat API WordPress The following script fragments will trigger the chat window to open the custom message after the time period you choose.
Use the free plug -in in the link below to place the code fragment in the footer of the event theme
You can adjust the items in this code as needed:
123]
If (! Window.SessionStorage.getITEM (\”
session_cookie_name [ 123] \”)) { Window.SessionStorage.Setitem (\” The information you want to say
\”);
}, 5 * 1000 );
How to use this code on your WordPress website:
Method#1
Putting this code in the FOOTER.PHP file of the event theme Method# 2 [ [ 123] Use the free plug-in in the link below to place the code fragment in the footer of the event theme
https://wordpress.org/plugins/insrt-headers-nd-footers/
-
Just end
We really hope that you will find these Tidio Chat API WordPress code fragments to help Your website visitors establish better interaction. - You can also use the WordPress condition statement to set different triggers specific to the URL. To understand the WordPress conditional statement and how to use more information, you can access the following link. https://codex.wordpress.org/Conditional_tags_tags_tags_tags_tags_tags_tags_tags_tags_tags_tags_tags_tags_tags. In https: // www.wpfixit.com/how- to- lower-bouund-raate/ View other powerful techniques that reduce the jump rate