愛偽裝(AWZ) Http腳本指南


愛偽裝(AWZ) Http腳本指南

愛偽裝` `AWZ` `Http腳本指南

目錄

前言

要使用HTTP腳本,需要應用的設置中,將腳本選項下的“啟用HTTP腳本指令”開關打開。
手機腳本調用:可直接調用http://127.0.0.1:1688/cmd?
PC調用:可直接調用http://局域網IP:1688/cmd?

HTTP指令說明

功能 代碼
啟動應用 runApp("AWZ"); 注意:以下所有指令調用前,必須先調用該指令,將應用啟動到最前端。
一鍵新機 http://127.0.0.1:1688/cmd?fun=newrecord
下一條記錄 http://127.0.0.1:1688/cmd?fun=nextrecord
清除所有記錄 http://127.0.0.1:1688/cmd?fun=deleteallrecords
生效指定記錄 http://127.0.0.1:1688/cmd?fun=activerecord&record=記錄ID
生效第一條 http://127.0.0.1:1688/cmd?fun=activefirstrecord
生效最后一條 http://127.0.0.1:1688/cmd?fun=activelastrecord
禁用指定記錄 http://127.0.0.1:1688/cmd?fun=disablerecord&record=記錄ID
取消禁用記錄 http://127.0.0.1:1688/cmd?fun=enablerecord&record=記錄ID
刪除指定記錄 http://127.0.0.1:1688/cmd?fun=deleterecord&record=記錄ID
瘦身指定記錄 http://127.0.0.1:1688/cmd?fun=thinrecord&record=記錄ID
導出指定記錄 http://127.0.0.1:1688/cmd?fun=exportrecord&record=記錄ID> 導出記錄在/var/mobile/exportdata/下
導出所有記錄 http://127.0.0.1:1688/cmd?fun=exportallrecords&zip=文件名 導出記錄在/var/mobile/exportdata/下
直接導入記錄 http://127.0.0.1:1688/cmd?fun=importdirect 導入記錄放在/var/mobile/importdata/下 注:可以是導出的目錄,也可以是導出的zip包
兼容性導入記錄 http://127.0.0.1:1688/cmd?fun=importcompatible 導入記錄放在/var/mobile/importdata/下 注:可以是導出的目錄,也可以是導出的zip包
導入NZT記錄 http://127.0.0.1:1688/cmd?fun=importnzt NZT記錄放在/var/mobile/nztdata/下 注:NZT記錄需是解開的目錄,或不加密的zip包
重命名當前記錄 http://127.0.0.1:1688/cmd?fun=renamecurrentrecord&name=新名稱 重命名后,新的名稱將成為ID
設置當前記錄坐標 http://127.0.0.1:1688/cmd?fun=setcurrentrecordlocation&location=坐標 坐標格式為:經度_緯度_地名地名可選
清除當前記錄坐標 http://127.0.0.1:1688/cmd?fun=clearcurrentrecordlocation
獲取當前記錄參數 http://127.0.0.1:1688/cmd?fun=getcurrentrecordparam 獲取的參數在/var/mobile/iggparams.txt文件中
設置當前記錄參數 http://127.0.0.1:1688/cmd?fun=setcurrentrecordparam 要設置的參數在/var/mobile/iggparams.txt文件中
獲取所有記錄名列表 http://127.0.0.1:1688/cmd?fun=getallrecordnames 獲取的記錄名列表在/var/mobile/iggrecords.txt文件中
清理AppStore http://127.0.0.1:1688/cmd?fun=cleanappstore 注:如果已打開"清理AppStore"選項,一鍵新機之后,不再需要調用該指令
卸載選中的應用 http://127.0.0.1:1688/cmd?fun=uninstallselectedapp 注:如果已打開"卸載應用"選項,一鍵新機之后,不再需要調用該指令
時間正序排序 http://127.0.0.1:1688/cmd?fun=orderbytime
時間倒序排序 http://127.0.0.1:1688/cmd?fun=orderbytimedesc

指令返回值說明

指令調用后,直接返回json串,格式:{"result":返回值}
另提供文件返回值,在:/var/mobile/iggresult.txt文件中

返回值 說明
2 指令正在執行過程中,還未完成。
1 指令執行正常完成。
3 一鍵新機成功,但IP地址重復(僅針對newrecord指令)。
4 下一條記錄已到最后一條(僅針對nextrecord指令)。
0 指令執行出錯。
100 產品未激活,或已過期。
10 運行環境異常。

iggparams.txt參數文件說明

獲取或設置當前記錄參數在:/var/mobile/iggparams.txt文件中;
每一行一個參數,換行符為: chr(10)
參數名與參數值之間,使用冒號(:)隔開;
可通過調用指令getcurrentrecordparam后,打開該文件查看格式。

參數名稱 說明
RecordID 記錄ID,如:"APP001"。
DeviceName 設備名稱,如:"xxxx iPhone"。
SystemVersion 系統版本號,如:"10.3.1"。
IDFA IDFA值。
IDFV IDFV值。
UDID 設備UDID值。
IMEI 設備IMEI值。
SerialNum 設備序列號。
MAC MAC地址。
SSID SSID值。
BSSID BSSID值。
OpenUDID OpenUDID值。

觸動腳本示例

1、啟動應用

runApp("AWZ");-- 第一次啟動,建議延遲等待3秒,需要聯網驗證,如:mSleep(3 *1000);

2、生效指定記錄

function activeRecord(name)    local sz = require("sz");    local http = require("szocket.http");    local res, code = http.request("http://127.0.0.1:1688/cmd?fun=activerecord&record="..name);    if code == 200 then        local resJson = sz.json.decode(res);        local result = resJson.result;        dialog("the result is: " .. result, 2);    end end;runApp("AWZ");mSleep(1 * 1000);activeRecord("APP001");

3、一鍵新機

function newRecord()    local sz = require("sz");    local http = require("szocket.http");    local res, code = http.request("http://127.0.0.1:1688/cmd?fun=newrecord");    if code == 200 then        local resJson = sz.json.decode(res);        local result = resJson.result;        dialog("the result is: " .. result, 2);        if result == 3 then            -- IP地址重復        end        -- ....其他代碼    end end;runApp("AWZ");mSleep(1 * 1000);newRecord();

4、重命名當前記錄

function renameCurrentRecord(name)    local sz = require("sz");    local http = require("szocket.http");    local res, code = http.request("http://127.0.0.1:1688/cmd?fun=renamecurrentrecord&name="..name);    if code == 200 then        local resJson = sz.json.decode(res);        local result = resJson.result;        dialog("the result is: " .. result, 2);    end end;runApp("AWZ");mSleep(1 * 1000);renameCurrentRecord("139xxxxxxx吳有財");

5、設置當前記錄坐標

function setCurrentRecordLocation(location)    local sz = require("sz");    local http = require("szocket.http");    local res, code = http.request("http://127.0.0.1:1688/cmd?fun=setcurrentrecordlocation&location="..location);    if code == 200 then        local resJson = sz.json.decode(res);        local result = resJson.result;        dialog("the result is: " .. result, 2);    end end;runApp("AWZ");mSleep(1 * 1000);setCurrentRecordLocation("116.7361382365_39.8887921413_北京老胡同");


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM