Grandstream Networks GXV3240 User Manual
Grandstream Networks GXV3240 User Manual

Grandstream Networks GXV3240 User Manual

Hide thumbs Also See for GXV3240:
Table of Contents

Advertisement

Grandstream Networks, Inc.
GXV3240/GXV3275
GMI Web Service Guide v1.9 User Guide
GXV3240/GXV3275 GMI WEB SERVICE GUIDE

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the GXV3240 and is the answer not in the manual?

Questions and answers

Summary of Contents for Grandstream Networks GXV3240

  • Page 1 Grandstream Networks, Inc. GXV3240/GXV3275 GMI Web Service Guide v1.9 User Guide GXV3240/GXV3275 GMI WEB SERVICE GUIDE...
  • Page 2: Table Of Contents

    ], callbackFuntion) ..............31 launchService(name, arg, callbackFunction) ..............32 closeService(name, callbackFunction) ................33 grabWindow(path, callbackFuntion) ................34 touchScreen(x, y, msec, callbackFunction) ..............35 getGMIVersion ......................35 getPhoneStatus ......................36 getPhoneMem ........................ 36 GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 1 of 40...
  • Page 3 ........................37 EndCall .......................... 38 getMinPlugins ....................... 38 swipScreen(start_x, start_y, end_x,end_y, callbackFunction) ........39 GMIService EXAMPLE ........................40 USING JAVASCRIPT ......................... 40 GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 2 of 40...
  • Page 4: Overview

    GMI version, please use getGMIVersion to match the returned version number. For interfaces that do not have GMI version requirement, they exist in all GMI versions and there is no need to identify GMI version. GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 3 of 40...
  • Page 5: Gmi Web Service Interface

    GMI WEB SERVICE INTERFACE GMI Service provides basic API to facilitate users calling the existing application on the GXV3240/GXV3275 to retrieve the phone's status. Different development environments provide different interface types. Usually, JavaScript and Windows MFC can be used for development.
  • Page 6: Getuptime(Callbackfunction)

    "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery)  For example: http://192.168.121.230/manager?action=pn&format=json&jsoncallback 1. HTTP request return: Return  Return successful GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 5 of 40...
  • Page 7: Gethardware(Callbackfunction)

    "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery)  For example: http://192.168.121.230/manager?action=vendor&format=json&jsonca llback=? 1. HTTP request return: Return  Return successful "{"res": "success", "vendor": "Grandstream Networks, Inc."}" GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 6 of 40...
  • Page 8: Getproduct(Callbackfuntion)

    "{"res": "error", "msg" : "can't get product model"}" 2. callbackFunction(data) will process the data returned from HTTP request 7. getProductInfo(callbackFunction) Description Retrieve GXV3240/GXV3275 vendor and product information (login is not require). The interface is combined by getVendor and getProduct. Parameters callbackFunction: Call back function ...
  • Page 9: Originatecall(Account, Isvideo Isdialplan, Destnum, Headerstring, Callbackfuntion)

     Destination number is empty "{"res": "error", "msg" : "destnum can't be null"}"  Timeout "{"res": "error", "msg" : "timeout"}"  callbackFunction(data) will process the data returned from HTTP request GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 8 of 40...
  • Page 10: Getnetworkinfo(Callbackfunction)

    "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery)  For example: http://192.168.121.230/manager?action=status&format=json&jsoncall back=? 1. HTTP request return: Return {"Response":"Success","Data":[{"Index":"1","Server":"192.168.120.25 4","Number":"3882","Status":"1","Activate":"1"}, {"Index":"0","Server":"sip.ipvideotalk.com:48879","Number":"8118263 ","Status":"1","Activate":"1"}, {"Index":"2","Server":"192.168.121.22","Number":"1001","Status":"1"," Activate":"1"}]} 2. String definition: GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 9 of 40...
  • Page 11: Getgroup(Gpid, Callbackfuntion)

    2. callbackFunction(data) will process the data returned from HTTP request Note: When using this interface, if the interface amount is greater than 12, it will be exported into text format stored in the phone. GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 10 of 40...
  • Page 12: Getcontact(Ctid, Gpid, Ctname, Callbackfuntion)

    "{"res": "error", "msg" : "wrong format"}" 2. callbackFunction(data) will process the data returned from HTTP request 13. getGroupCount(callbackFuntion) Description Retrieve the number of groups in phonebook Parameters callbackFunction: Call back function GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 11 of 40...
  • Page 13: Getcontactcount(Callbackfuntion)

    "{"res": "error", "msg" : "can't get contact count"}" 2. callbackFunction(data) will process the data returned from HTTP request 15. phbkresponse(phbkGroup, callbackFuntion)  Description Configure phonebook group information (edit group and add group)  Phonebook group structure PhbkGroup GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 12 of 40...
  • Page 14: Setcontact(Phbkcontact, Callbackfuntion)

    2. callbackFunction(data) will process the data returned from HTTP request 16. setContact(phbkContact, callbackFuntion)  Description Configure phonebook contact information (edit contact and add contact)  Phonebook contact structure PhbkContact ctID; //Contact ID ctName; //Contact name GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 13 of 40...
  • Page 15: Removecontact(Ctid, Callbackfunction)

    2. callbackFunction(data) will process the data returned from HTTP request 17. removeContact(ctID, callbackFunction) Description Remove contact ctID from phonebook. If ctID is empty, remove all contacts  Parameters ctID: Contact ID GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 14 of 40...
  • Page 16: Cleargroup(Gpid, Callbackfunction)

    AJAX and JQuery)  For example: http://192.168.121.230/manager?action=cleargroup&groupID=1&for mat=json&jsoncallback=? 1. HTTP request return: Return  Clear successful "{"res": "success"}"  Clear failed "{"res" : "error", "msg": "clear group failed" }" GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 15 of 40...
  • Page 17: Removegroup(Gpid, Callbackfunction)

    The default group and blacklist cannot be removed. The gpID of the default group is 0; the gpID of the blacklist is 100. 20. moveToDefault(ctID, callbackFuntion) Description Move the contact to default phonebook group  Parameters ctID: Contact ID GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 16 of 40...
  • Page 18: Downloadphonebook(Phbkconfigure, Flag, Callbackfunction)

    21. downloadPhonebook(phbkConfigure, flag, callbackFunction)  Description Set up phonebook download configurations and download phonebook.xml  Phonebook download configuration structure phbkConfigure mode; url; interval; redup; clearold; filetype; encode;  Parameters phbkConfigure: Phonebook download configuration GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 17 of 40...
  • Page 19 "1" (clear old list, 0: No, 1: Yes)  downEncode: "UTF-8" (phonebook file encoding format)  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery) GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 18 of 40...
  • Page 20: Setphonebook(Phbkconfigure, Flag, Callbackfunction)

    8: File encoding format wrong 9: Importing (For importing) 10: File format invalid (for importing) 22. setPhonebook(phbkConfigure, flag, callbackFunction)  Description Phonebook import/export  Phonebook configuration structure phbkConfigure mode; url; interval; redup; GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 19 of 40...
  • Page 21 "1"  portEncode: "UTF-8"  portType: "0"  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery) GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 20 of 40...
  • Page 22 "{"res": "success", "flag":"1"}"  "putportphbk": Import failed "{"res" : "error", "msg" : "configuration file not found"}"  "savephbk": Save successful "{"res": "success"}" 2. callbackFunction(data) will process the data returned from HTTP GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 21 of 40...
  • Page 23: Getmessage(Id, Callfunction)

    "getmessage"  id: "-1"  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery)  For example: http://192.168.121.230/manager?action=getmessage&id=-1&for GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 22 of 40...
  • Page 24: Setnewmessage(Num, Account, Text, Flag, Callbackfunction)

    Parameters in wrong format (GMI version 9 or newer) "{"res" : "error", "msg" : "wrong format"}"  Database operation error (GMI version 9 or newer) "{"res" : "error", "msg" : "0"}" GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 23 of 40...
  • Page 25: 25. Senddraftmessage(Id, Callbackfunction)Putportphbk

    "removemessage"  ID: "1"  flag: "1"  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery) GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 24 of 40...
  • Page 26: Savemessage(Callbackfunction)

    Call log type. 0 - answered calls; 1 - dialed calls; 2 - missed calls  callbackFunction: Call back function Http Request  url: "http://"+ ip + "/manager?"  action: "getlastcall"  type: "1" GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 25 of 40...
  • Page 27: Removecall(Id, Flag, Callbackfuntion)

    1. HTTP request return: Return  Remove successful "{"res": "success"}"  Remove failed "{"res" : "error", "msg" : "remove call failed"}"  Parameters in wrong format (GMI version 9 or newer) GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 26 of 40...
  • Page 28: Savecallhistory(Callbackfunction)

    //P value key; //nvram address (P parameter)  The ConfItem list is as follows: UpgradeConf ConfItem updaterule ConfItem updatevia ConfItem firpath ConfItem confpath ConfItem firpre ConfItem firpost ConfItem confpre ConfItem confpost GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 27 of 40...
  • Page 29 Confpath: Config Server Path Firpre: Firmware File Prefix Firpost: Firmware File Postfix Confpre: Config File Prefix Confpost: Config File Postfix dhcp66: DHCP Option 66 0------No Override Server 1------Yes Autoup: Automatic Upgrade 0------No 1------Check GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 28 of 40...
  • Page 30 AJAX and JQuery)  For example: http://192.168.121.230/manager?action=put&var-0000=238&val- 0000=0&var-0001=212&val-0001=1&format=json&jsoncallback= 2. Upgrade  url: http://" + ip +"/manager?"  action: "upgrade"  var-0000: 238 //Key. P238 is for automatic upgrade GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 29 of 40...
  • Page 31: Setparameter(Confitem[ ], Callbackfuntion)

    //Key val-0001: var2 //Value ..var-xxxx val-xxxx  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery) GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 30 of 40...
  • Page 32: Getparameter(Confitem[ ], Callbackfuntion)

    1. HTTP request return: Return  Successful "{"res": "success", "7044":"1", "904":"15"}"  Failed "{"res": "error", "msg":"new memory failed or no value"}" 2. callbackFunction(data) will process the data returned from HTTP request GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 31 of 40...
  • Page 33: Launchservice(Name, Arg, Callbackfunction)

    Check IP Address Location LastMF Last.FM MediaPlay Media Player MovieTrailer Movie Trailer NewsVideos News Video Phanfare Phanfare Photobucket Photobucket Camera Qchecker Game SlideShowApp Slides show Game Solitaire System Information SystemInfo System Settings SystemSetting GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 32 of 40...
  • Page 34: Closeservice(Name, Callbackfunction)

    35. closeService(name, callbackFunction) Description Close an application (GMI 8)  name —— application name (2.34-Application List) Parameters  callbackFunction: Call back function  url —— "http://" + ip +"/manager?" Http Request GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 33 of 40...
  • Page 35: Grabwindow(Path, Callbackfuntion)

    "{"res" : "error", "msg": "save pictrue failed" }" //Save failed  "{"res" : "error", "msg": "wrong extension" }" //Postfix is wrong  "{"res" : "error", "msg": "lost the extension" }" //No postfix GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 34 of 40...
  • Page 36: Touchscreen(X, Y, Msec, Callbackfunction)

    + ip +"/manager?"  action: "gmiVersion"  For example: http://192.168.121.230/manager?action=gmiVersion Return GMI Version number. For example, 6. The version number increases by 1 on each new GMI version. GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 35 of 40...
  • Page 37: 39. Getphonestatus

    "phoneMem"  funcname: process name  format: "json"  jsoncallback: "?" (This is the HTTP request for the call back function, usually used in AJAX and JQuery)  For example: GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 36 of 40...
  • Page 38: Getcstatus

    7: CALL_ENDING. Call is being ended  8: CALL_FAILED. Call cannot be established  9: CALL_TRANSFER. Call is being transferred  10: CALL_CONFERENCE. In conference  11: CALL_PAGING  12: CALL_RINGBACK. Ringback GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 37 of 40...
  • Page 39: Endcall

    Get via json with jsoncallback, the results should be: Return jsoncallback(S), jsoncallback are callback Function names. Return values are json type strings,list below: {"res" : "success", "msg": "SetupGuide,SystemSetting"} Minimized applications have setup wizard and system settings. GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 38 of 40...
  • Page 40: Swipscreen(Start_X, Start_Y, End_X,End_Y, Callbackfunction)

     Return HTTP request return:  "{"res" : "success"}"  "{"res" : "error", "msg": "the point out of screen" }" callbackFunction(data) will process the data returned from HTTP request GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 39 of 40...
  • Page 41: Gxv3240/Gxv3275 Gmi Web Service Guide V1.9

    <div id="connectinfo"> Phone IP: <input id="ip" value="Input Phone IP here"> UserName: <input id="username" value="admin"> Password: <input id="password" value="admin"> <button onclick="login()">Connect</button> </div> <br> <h4>2. Connect info</h4> <div id="connectresult"> not connected </div> …..GXV3240/GXV3275 GMI WEB SERVICE GUIDE V1.9 Page 40 of 40...

This manual is also suitable for:

Gxv3275

Table of Contents