QiotaConnect SDK JS

You have two options of UI integration : with popup over of your from or loading widget of

the bottom of your form.

This option is customizaible by your self with your language library when you put the ‘qiota’

div container. See this section.

Popup DropDown

Use the same direct link, you can load Qiota.js directly. Once loaded, qiota library will be

available on your website.

Adding the <script> tag loads Qiota’s JavaScript file.You may include this either within your <head> tag or inside the <body> part of your HTML, before the end of the page

<script src= "https://(beta/www).qiota.com/assets/getQiota.js" ></script>

1. The web site client integrates getQiota.js and configures all options

2. The client calls methode to login or signup

3. The Qiota System verifies the Token and returns html elements form for authentification

4. The client use auth form and Qiota begins the process and returns a user authorisation

The <div> qiota auth tag container

The getQiota.js file allows you to render a Qiota widget on the client side.

Configure the container and form where the Qiota Widget will add the elements.

<div class= "qiota_auth" > </div>

The widget will appear exactly where this <div> tag is included on your page. When the

getQiota.js file is loaded, this <div> tag will get populated.

If you want the integration in modal dialog you just have to embed the qiota_auth div in your

modal class in the. Then you have to add the trigger in your link, here an example.

Requirements for this exemple : JS Boostrap library and JS jquery Library

<a href=" # " onclick=" openModal() ">Login</a>
< script type= "text/javascript" >
function openModal(){
$(' #dialog_qiota' ).modal();
< /script >
<div id=" dialog_qiota " class=" modal fade in ">
<div class=" modal-dialog ">
<div class=" qiota_auth "></div>

In the case of the Qiota script calling at the same time the connect module and the paywall

module, the integration is done with the opening of the Qiota Setup function by integrating the call to the Connect (Auth) function. Make sure to replace TOKEN CLIENT with your generated client token.

< script type = "text/javascript" >
var q_token = "ACCESS_TOKEN" ; //required
var q_urlcallback = "https://yourserver/qiota_return" ; //required
/* below the parameters required for the proper operation of the paywall
module */
var q_logged = " true/false " ;
var q_subscribed = " true/false " ;
var q_ressource_uri = " your_absolute_path/article_to_unlock.php " ;
var q_id_article = " id of article " ;
setupQiota( function ( response ){
if ( response ){
renderQiotaAuth(q_token, q_urlcallback, q_type);
return ; }

< /script type>

The qiota_auth div will be populated for login of the user. After login success, the Qiota

system checks whether the article exists and whether the access right is still valid, and

sends a parms on the UrlCallBack by the Get method.

Response from QiotaAuth

Once the QiotaSub complete the process, the system sends on  URLCALLBACK  the informations about process.