If you like BoxMatrix then please contribute Supportdata, Supportdata2, Firmware and/or Hardware (get in touch).
My metamonk@yahoo.com is not reachable by me since years. Please use hippie2000@webnmail.de instead.

0
U

Property:rest api const.lua

From BoxMatrix


BoxMatrix >> Webinterface >> rest_api_const.lua @ BoxMatrix   -   IRC-Chat   -   Translate: de es fr it nl pl
News Selectors Models Accessories Components Environment Config Commands System Webif Software Develop Lexicon Community Project Media

UI-Structure UI-Modules HTML-Files XML-Files Lua-Scripts Javascript Browser SSI-Files SSI-Directives HTML-Text Event-Text Help-Pages CSS-Files Graphics Research

Lua-Script

Goto:   Variables  -  Error-Codes  -  Error-Strings  -  Dependencies   -   Model-Matrix   -   SMW-Browser

Details

rest_api_const.lua fills REST-API Const Tables and global variables. It is included by nearly all API related Lua-Scripts.

REST-API:

Variables

Global variables used to create the request URI. Excerpt from fw 7.50:

rest_api_const.api_root_path = "/api"
rest_api_const.api_version = "0"
rest_api_const.api_path = rest_api_const.api_root_path .. "/v" .. rest_api_const.api_version

Error-Codes

HTTP error codes which are sent to the client. Excerpt from fw 7.50:

--! The error codes which will be used to send to the client.

rest_api_const.status_code = {

    -- Request is wrong
    LUA_INVALID_REQUEST           = 201,
    LUA_NO_PERMISSION             = 202,
    LUA_INTERNAL                  = 203,

    -- UI MOD (Group) Errors and BACKEND errors
    BACKEND_INVALID_REQUEST        = 301,
    BACKEND_2FA_NEEDED             = 302,
    BACKEND_2FA_BUSY               = 303,
    BACKEND_2FA_BLOCKED            = 304,
    BACKEND_FAIL                   = 339,

    -- If DATA from UIMOD is not as expected
    -- eg. list entry not found
    LUA_UI_DATA_INVALID           = 401,
    LUA_UI_DATA_NOT_FOUND         = 402

}

Error-Strings

HTTP error codes which are sent to the client. Excerpt from fw 7.50:

-- map to convert the status codes (@see scgi_server.h) of a transaction into
-- human readable error messages.

ui_cmd_result_map[0] = "ok"
ui_cmd_result_map[-1] = "internal error"
ui_cmd_result_map[-2] = "bad key"
ui_cmd_result_map[-3] = "bad value"
ui_cmd_result_map[-4] = "permission denied"
ui_cmd_result_map[-5] = "2fa needed"
ui_cmd_result_map[-6] = "2fa busy"
ui_cmd_result_map[-7] = "2fa blocked"
ui_cmd_result_map[-8] = "not processed"

Dependencies

Daily updated index of all dependencies of this script. Last update: 2024-04-23 08:48 GMT.
A * in the Mod column marks info from Supportdata-Probes, which will always stay incomplete.
If an Object includes itself then this is a file with the same name but another Path and the dependencies are merged.

Relation Typ Object Mod Firmware Info Origin
Required by lua api.lua 50 7.39 - 7.90 REST-API Lua-Land root for scgi_server AVM
Required by lua api_generic.lua 50 7.39 - 7.90 REST-API Generic Endpoints AVM
Required by lua boxname.lua 13 7.90 TODO AVM
Required by lua boxnotify_rest.lua 19 7.39 - 7.90 REST-API module for box notifications AVM
Required by lua calllog_rest.lua 19 7.39 - 7.90 REST-API module for the Phone-Calls and TAM-Calls AVM
Required by lua common.lua 14 7.70 - 7.90 TODO AVM
Required by lua datatype.lua 13 7.90 TODO AVM
Required by lua dev_debug.lua 35 7.39 - 7.90 REST-API Developers Debugging Module AVM
Required by lua error.lua 50 7.39 - 7.90 REST-API Error handling AVM
Required by lua eventlog.lua 13 7.90 TODO AVM
Required by lua faxjournal_rest.lua 19 7.39 - 7.90 REST-API module for the Fax-Journal AVM
Required by lua handsets.lua 13 7.90 TODO AVM
Required by lua internet.lua 5 7.70 TODO AVM
Required by lua isp.lua 13 7.90 TODO AVM
Required by lua landevice.lua 37 7.39 - 7.90 REST-API wrapper for the landevice ui-module AVM
Required by lua locale.lua 14 7.70 - 7.90 TODO AVM
Required by lua misc.lua 13 7.90 TODO AVM
Required by lua monitor.lua 13 7.90 TODO AVM
Required by lua obl_fboxname.lua 13 7.39 REST-API Demo Module AVM
Required by lua phonebook.lua 9 7.90 TODO AVM
Required by lua phonebook_rest.lua 19 7.39 - 7.90 REST-API module for the Phonebook AVM
Required by lua plugin_common.lua 13 7.90 TODO AVM
Required by lua progress.lua 14 7.70 - 7.90 TODO AVM
Required by lua response.lua 50 7.39 - 7.90 REST-API Response API AVM
Required by lua saveset.lua 14 7.70 - 7.90 TODO AVM
Required by lua security.lua 50 7.39 - 7.90 REST-API Security AVM
Required by lua setup.lua 14 7.70 - 7.90 TODO AVM
Required by lua smarthome.lua 12 7.90 TODO AVM
Required by lua smarthome_rest.lua 19 7.39 - 7.90 REST-API module for Smarthome AVM
Required by lua storagenasrights_rest.lua 51 7.39 - 7.90 REST-API module for NAS access permissions AVM
Required by lua templateBroken.lua 13 7.90 TODO AVM
Required by lua templateComplex.lua 13 7.90 TODO AVM
Required by lua templateSimple.lua 13 7.90 TODO AVM
Required by lua timermix.lua 13 7.90 TODO AVM
Required by lua uimod.lua 50 7.39 - 7.90 REST-API UI-Modules API AVM
Required by lua uimod_cache.lua 14 7.70 - 7.90 TODO AVM
Required by lua update.lua 14 7.70 - 7.90 TODO AVM
Required by lua validcheck.lua 14 7.70 - 7.90 TODO AVM
Required by lua webusb_rest.lua 51 7.39 - 7.90 REST-API module for NAS handling AVM
Required by lua wifi.lua 5 7.70 TODO AVM
40 dependencies for this script

Model-Matrix

Daily updated index of the presence, path and size of this script for each model. Last update: 2024-04-23 06:22 GMT.
Showing all models using this script. Click any column header (click-wait-click) to sort the list by the respective data.
The (main/scrpn/boot/arm/prx/atom) label in the Model column shows which CPU is meant for models with multiple Linux instances.
Note that this list is merged from Firmware-Probes of all known AVM firmware for a model, including Recovery.exe and Labor-Files.

Model Firmware Path Size/Bytes
FRITZ!Box 4020 7.39 /usr/rest_api 1.6k
FRITZ!Box 4040 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 4050 7.57 /usr/rest_api 1.6k
FRITZ!Box 4060 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 5530 Fiber (main) 7.39 - 7.80 /usr/rest_api 1.6k - 3.1k
FRITZ!Box 5590 Fiber (arm) 7.39 - 7.90 /usr/rest_api 1.6k - 3.9k
FRITZ!Box 5590 Fiber (prx) 7.70 - 7.90 /usr/rest_api 1.9k - 3.9k
FRITZ!Box 5690 Pro (arm) 7.59 - 7.60 /usr/rest_api 1.6k
FRITZ!Box 6430 Cable (arm) 7.57 /usr/rest_api 1.6k
FRITZ!Box 6490 Cable (arm) 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 6490 Cable (atom) 7.39 - 7.51 /usr/rest_api 1.6k
FRITZ!Box 6590 Cable (arm) 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 6590 Cable (atom) 7.39 - 7.51 /usr/rest_api 1.6k
FRITZ!Box 6591 Cable (arm) 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 6591 Cable (atom) 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 6660 Cable (arm) 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 6660 Cable (atom) 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 6670 Cable (arm) 7.57 - 7.62 /usr/rest_api 1.6k
FRITZ!Box 6670 Cable (atom) 7.61 - 7.62 /usr/rest_api 1.6k
FRITZ!Box 6690 Cable (arm) 7.39 - 7.90 /usr/rest_api 1.5k - 4.0k
FRITZ!Box 6690 Cable (atom) 7.39 - 7.90 /usr/rest_api 1.5k - 4.0k
FRITZ!Box 6820 LTE v1 7.39 - 7.51 /usr/rest_api 1.6k
FRITZ!Box 6820 LTE v2 7.39 - 7.51 /usr/rest_api 1.6k
FRITZ!Box 6820 LTE v3 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 6840 LTE 7.39 /usr/rest_api 1.6k
FRITZ!Box 6850 LTE 7.39 - 7.90 /usr/rest_api 1.5k - 3.9k
FRITZ!Box 6850 5G 7.39 - 7.90 /usr/rest_api 1.6k - 3.9k
FRITZ!Box 6890 LTE 7.39 - 7.51 /usr/rest_api 1.4k - 1.6k
FRITZ!Box 6890 LTE v1 7.39 - 7.51 /usr/rest_api 1.4k - 1.6k
FRITZ!Box 6890 LTE v2 7.39 - 7.51 /usr/rest_api 1.4k - 1.6k
FRITZ!Box 7272 7.39 /usr/rest_api 1.6k
FRITZ!Box 7430 7.39 /usr/rest_api 1.6k
FRITZ!Box 7490 (main) 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 7510 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 7520 7.39 - 7.51 /usr/rest_api 1.6k
FRITZ!Box 7520 v2 (arm) 7.39 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 7530 7.39 - 7.56 /usr/rest_api 1.4k - 1.6k
FRITZ!Box 7530 AX 7.39 - 7.90 /usr/rest_api 1.5k - 4.0k
FRITZ!Box 7560 7.39 /usr/rest_api 1.6k
FRITZ!Box 7583 7.50 - 7.57 /usr/rest_api 1.6k
FRITZ!Box 7590 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 7590 AX 7.39 - 7.90 /usr/rest_api 1.4k - 4.0k
FRITZ!Box 7690 7.59 /usr/rest_api 1.6k
FRITZ!Repeater 600 7.39 /usr/rest_api 1.6k
FRITZ!Repeater 1200 7.39 /usr/rest_api 1.6k
FRITZ!WLAN Repeater 1750E 7.39 /usr/rest_api 1.6k
FRITZ!Repeater 2400 7.39 /usr/rest_api 1.4k - 1.6k
FRITZ!Repeater 3000 7.39 /usr/rest_api 1.6k
FRITZ!Repeater 3000 AX 7.39 /usr/rest_api 1.6k
FRITZ!Powerline 1260E 7.39 /usr/rest_api 1.6k
50 models use this script

SMW-Browser

Information is currently being retrieved from the backend.
 

Synonyms

Showing 1 related property.

r