Skip to content

Access Control (Template) ​

3 operations. Call any of them with omada_call_operation (or, in full tool mode, as a tool named by its operationId).

OperationMethodSummary
getAccessControlTemplateGETGet access control setting template
modifyAccessControlTemplatePATCHModify access control setting template
getAutoFreeAuthPolicyTemplateGETGet automatically generated free auth policy template items

getAccessControlTemplate ​

GET /openapi/v1/{omadacId}/sitetemplates/{siteTemplateId}/setting/access-control

Get access control setting template

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteTemplateIdpathstringyesSite Template ID
json
// omada_call_operation
{
  "operationId": "getAccessControlTemplate",
  "params": {
    "siteTemplateId": "<siteTemplateId>"
  }
}
Details, permissions and error codes

Get access control setting template with the given omadacId and siteTemplateId.
The interface requires one of the permissions:
Global Site Template Manager View Only
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33011 - Operation failed because other operations are being performed on this site template. Please wait and try again later.

modifyAccessControlTemplate ​

PATCH /openapi/v1/{omadacId}/sitetemplates/{siteTemplateId}/setting/access-control

Modify access control setting template

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteTemplateIdpathstringyesSite Template ID

Request body — application/json (required) — schema PortalAccessControlOpenApiVO

FieldTypeRequiredDescription
preAuthAccessEnablebooleanyesWhether to enable Pre-Authentication Access. If parameter [preAuthAccessEnable] is true, parameter [preAuthAccessPolicies] is needed
preAuthAccessPoliciesarray<PreAuthAccessPolicyOpenApiVO>noList of Pre-Authentication Access Policy
freeAuthClientEnablebooleanyesWhether to enable Free-Authentication Client. If parameter [freeAuthClientEnable] is true, parameter [freeAuthClientPolicies] is needed
freeAuthClientPoliciesarray<FreeAuthClientPolicyOpenApiVO>noList of Free-Authentication Client Policy
json
// omada_call_operation
{
  "operationId": "modifyAccessControlTemplate",
  "params": {
    "siteTemplateId": "<siteTemplateId>"
  },
  "body": "{...}"
}
Details, permissions and error codes

Modify access control setting template. When modifying, the full configuration parameters should be passed in
The interface requires one of the permissions:
Global Site Template Manager Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33011 - Operation failed because other operations are being performed on this site template. Please wait and try again later.

getAutoFreeAuthPolicyTemplate ​

GET /openapi/v1/{omadacId}/sitetemplates/{siteTemplateId}/setting/auto-free-auth-policy

Get automatically generated free auth policy template items

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteTemplateIdpathstringyesSite Template ID
json
// omada_call_operation
{
  "operationId": "getAutoFreeAuthPolicyTemplate",
  "params": {
    "siteTemplateId": "<siteTemplateId>"
  }
}
Details, permissions and error codes

Get automatically generated free auth policy template items with the given omadacId and siteTemplateId.
The interface requires one of the permissions:
Global Site Template Manager View Only
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33011 - Operation failed because other operations are being performed on this site template. Please wait and try again later.

Released under the MIT License. Not affiliated with or endorsed by TP-Link.