Retrieve the filter list
GET
/ip_filter/list
Request
Placeholders
access_token
string
required
Access token is a 32-byte string with validity of 30 seconds.pagination
integer
required
The pagination of paging.pagesize
integer
optional
The pagesize of paging.sort_by
enum
optional
Values include "DEFAULT" and "Optional". Default value will be used when user does not specify value for this field.
Sample Request
https://example.com/api/ip_filter/list?access_token=196ACE20C6F34027895F7F95402BB164&pagesize=100&pagination=1&sort_by=DEFAULT
Response
Placeholders
pagination
integer
required
The pagination of paging.pagesize
integer
optional
The pagesize of paging.sort_by
enum
optional
Values include "DEFAULT" and "Optional". Default value will be used when user does not specify value for this field.page_count
integer
required
The total count of pages.count
integer
required
Current pagesize.ip_filters
array
required
Show child attributesCollection of ipfilter.
Sample Response
{
"pagination": 1,
"pagesize": 100,
"sort_by": "DEFAULT",
"page_count": 100,
"count": 100,
"ip_filters": [
{
"id": "11111",
"ip": "192.168.1.47",
"mask": "255.255.255.255",
"expires_time": "2064-05-15 16:00",
"type": 2,
"description": "xxxx"
},
{
"id": "11112",
"ip": "192.168.1.46",
"mask": "255.255.255.255",
"expires_time": "2064-05-15 16:00",
"type": 1,
"description": "xxxx"
}
]
}
Retrieve the filter show
GET
/ip_filter/show
Request
Placeholders
access_token
string
required
Access token is a 32-byte string with validity of 30 seconds.id
string
required
Unique id of the ipfilter.
Sample Request
https://example.com/api/ip_filter/show?access_token=196ACE20C6F34027895F7F95402BB164&id=11111
Response
Placeholders
id
string
required
Unique id of the ipfilter.ip
string
required
IPV4 address of the ipfilter.mask
string
required
IP mask of the ipfilter.expires_time
string
required
Expires time of the ipfilter.type
integer
required
type of the ipfilter (0:permanently_block ; 1:time_efficient_block ; 2:permit).description
string
required
Remarks for the ipfilter.
Sample Response
{
"id": "11111",
"ip": "192.168.1.47",
"mask": "255.255.255.255",
"expires_time": "2064-05-15 16:00",
"type": 2,
"description": "xxxx"
}
Add a ipfilter
POST
/ip_filter/create
Placeholders
Request
Placeholders
access_token
string
required
Access token is a 32-byte string with validity of 30 seconds.ip
string
required
IPV4 address of the ipfilter.mask
string
required
IP mask of the ipfilter.expires_time
string
required
Expires time of the ipfilter.type
integer
required
type of the ipfilter (0:permanently_block ; 1:time_efficient_block ; 2:permit).description
string
required
Remarks for the ipfilter.
Sample Request
{
"access_token": "196ACE20C6F34027895F7F95402BB164",
"ip": "192.168.1.46",
"mask": "255.255.255.255",
"expires_time": "2064-05-15 16:00",
"type": 1,
"description": "xxxx"
}
Response
Placeholders
Sample Response
update a ipfilter
POST
/ip_filter/update
Placeholders
Request
Placeholders
access_token
string
required
Access token is a 32-byte string with validity of 30 seconds.id
string
required
Unique id of the ipfilter.ip
string
required
IPV4 address of the ipfilter.mask
string
required
IP mask of the ipfilter.expires_time
string
required
Expires time of the ipfilter.type
integer
required
type of the ipfilter (0:permanently_block ; 1:time_efficient_block ; 2:permit).description
string
required
Remarks for the ipfilter.
Sample Request
{
"access_token": "196ACE20C6F34027895F7F95402BB164",
"id": "11111",
"ip": "192.168.1.47",
"mask": "255.255.255.255",
"expires_time": "2064-05-15 16:00",
"type": 2,
"description": "xxxx"
}
Response
Placeholders
Sample Response
Remove a ipfilter
POST
/ip_filter/destroy
Placeholders
Request
Placeholders
access_token
string
required
Access token is a 32-byte string with validity of 30 seconds.id
string
required
Unique id of the ipfilter.
Sample Request
{
"access_token": "196ACE20C6F34027895F7F95402BB164",
"id": "11111"
}
Response
Placeholders