mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 07:29:32 +00:00
Example fix
This commit is contained in:
parent
8397d849d9
commit
6ddaa8dce0
2 changed files with 4 additions and 7 deletions
|
|
@ -13,12 +13,11 @@ local json = require "dkjson"
|
|||
sendHTTPContentTypeHeader('application/json')
|
||||
|
||||
--[[
|
||||
|
||||
Request example:
|
||||
curl -u admin:admin -H "Content-Type: application/json" -d '{"associations" = {["DE:AD:BE:EE:FF:FF"] = {"group" = "staff", "connectivity" = "pass"},["AB:AB:AB:AB:AB:AB"] = {"group" = "guest", "connectivity" = "reject"}}}' http://192.168.1.1:3000/lua/admin/manage_pool_members.lua
|
||||
curl -u admin:admin -H "Content-Type: application/json" -d '{"associations" : {"DE:AD:BE:EE:FF:FF" : {"group" : "staff", "connectivity" : "pass"},"AB:AB:AB:AB:AB:AB" : {"group" : "guest", "connectivity" : "reject"}}}' http://192.168.1.1:3000/lua/admin/manage_pool_members.lua
|
||||
|
||||
Payload example:
|
||||
local ret = {
|
||||
Data example:
|
||||
local res = {
|
||||
associations = {
|
||||
["DE:AD:BE:EE:FF:FF"] = {
|
||||
group = "staff",
|
||||
|
|
@ -30,8 +29,6 @@ sendHTTPContentTypeHeader('application/json')
|
|||
}
|
||||
}
|
||||
}
|
||||
return ret
|
||||
|
||||
--]]
|
||||
|
||||
-- Instantiate host pools
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue