Get Settings

API will return settings with a Javascript variable called 'settings'. This variable is being used to initialize chatbox window on the website where chatbox added.

Resource URL

https://Server Node Environment/index.php

Example : https://api.yourdomain.com/index.php

Resource Information

Parameters Values
Resource Format JSON
Method GET
Requires authentication? Yes

Request

GET Params

Parameters Mandatory Description
[Request parameters]
d REQUIRED visitors - Controller directory name
c REQUIRED chatbox - Controller name
m REQUIRED settings - Controller method name
token REQUIRED Access Token for authentication picked from widget code

Response


var settings = {
    "current_version": "1.0.0",
    "current_product_name": "product_name",
    "enable_agent_initiate_chats": "yes",
    "chat_status": "enable",
    "time_interwal": "3",
    "chat_mode": "online"
    ........
}
                                        

Messages returned

HTTP STATUS CODE Description MESSAGE BODY
200 Successfully Return Return Javascript varriable settings with Json data.
200 Authorization Error var settings = {"result":"failed","error":"Invalid access token or Token has been expired.","plugin_validated":"yes"}
400 Request is malformed {"error": "invalid_request", "error_description": "description"}
403 Forbidden Directory access is forbidden.
404 Resource Not found The page you requested was not found.