Skip to content

Wireguard VPN ​

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

OperationMethodSummary
getWireguardKeyGETGet new private key and public key
listPeerGETGet wireguard peer list (deprecated)
createPeerPOSTCreate new wireguard peer (deprecated)
deletePeerDELETEDelete an existing wireguard peer (deprecated)
modifyPeerPUTModify an existing wireguard peer (deprecated)
getWireguardSummaryGETGet all wireguard's id and name info (deprecated)
listWireguardGETGet wireguard list (deprecated)
createWireguardPOSTCreate new wireguard (deprecated)
deleteWireguardDELETEDelete an existing wireguard (deprecated)
modifyWireguardPUTModify an existing wireguard (deprecated)

getWireguardKey ​

GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-key

Get new private key and public key

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
json
// omada_call_operation
{
  "operationId": "getWireguardKey",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get new private key and public key.
The interface requires one of the permissions:
Site Settings Manager View Only
Network Config Page View Only
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-1001 - Invalid request parameters.

listPeer ​

GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers

Deprecated

This operation is deprecated.

Get wireguard peer list

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
pagequeryintegernoStart page number. Start from 1. (default 1)
pageSizequeryintegernoNumber of entries per page. It should be within the range of 1–1000. (default 100)
searchKeyquerystringnosearchKey
json
// omada_call_operation
{
  "operationId": "listPeer",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get wireguard peer list. This interface has been deprecated. Please use the following interfaces instead: Get site-to-site VPN detail info.
The interface requires one of the permissions:
Site Settings Manager View Only
Network Config Page View Only

createPeer ​

POST /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers

Deprecated

This operation is deprecated.

Create new wireguard peer

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)

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

FieldTypeRequiredDescription
namestringyesThe name of WireGuard peer should contain 1 to 64 characters.
statusbooleanyesThe status of WireGuard peer. Valid value is true or false.
interfaceIdstringyesThe ID of WireGuard VPN to which this WireGuard peer binds. The ID can be obtained from 'Get all wireguard's id and name info' interface.
publicKeystringyesThe public key of WireGuard peer must have 44 character of base64 and end with '='.
endPointstringnoThe end point IP of WireGuard peer. Get whether supports domain from interface 'Get wireguard peer list'.
endPointPortintegernoThe end point port of WireGuard peer should be within the range of 1-65535.
allowAddressarray<string>yesIP/MASK address list of WireGuard peer allowed.
presharedKeystringnoThe presharedKey of WireGuard peer must have 44 character of base64 and end with '='.
keepAliveintegeryesThe keepalive second of WireGuard peer should be within the range of 0-65535.
commentstringnoThe comment of WireGuard peer should contain 0 to 128 characters.
json
// omada_call_operation
{
  "operationId": "createPeer",
  "params": {
    "siteId": "<siteId>"
  },
  "body": "{...}"
}
Details, permissions and error codes

Create new wireguard peer. This interface has been deprecated. Please use the following interfaces instead: Create site-to-site VPN by manual or Modify site-to-site VPN by manual.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33006 - This name already exists in this site.
-43202 - The number of WireGuard peers has reached the limit.
-43205 - The public key of the WireGuard peer for the same interface already exists.
-43206 - The device does not support configuring domain for WireGuard peer.
-43207 - Endpoint and Endpoint Port need to be filled in at the same time or both left blank.
-43208 - The device does not support WireGuard VPN.

deletePeer ​

DELETE /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers/{id}

Deprecated

This operation is deprecated.

Delete an existing wireguard peer

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
idpathstringyesPeer ID
json
// omada_call_operation
{
  "operationId": "deletePeer",
  "params": {
    "siteId": "<siteId>",
    "id": "<id>"
  }
}
Details, permissions and error codes

Delete an existing wireguard peer. This interface has been deprecated. Please use the following interfaces instead: Modify site-to-site VPN by manual.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify

modifyPeer ​

PUT /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers/{id}

Deprecated

This operation is deprecated.

Modify an existing wireguard peer

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
idpathstringyesPeer ID

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

FieldTypeRequiredDescription
namestringyesThe name of WireGuard peer should contain 1 to 64 characters.
statusbooleanyesThe status of WireGuard peer. Valid value is true or false.
interfaceIdstringyesThe ID of WireGuard VPN to which this WireGuard peer binds. The ID can be obtained from 'Get all wireguard's id and name info' interface.
publicKeystringyesThe public key of WireGuard peer must have 44 character of base64 and end with '='.
endPointstringnoThe end point IP of WireGuard peer. Get whether supports domain from interface 'Get wireguard peer list'.
endPointPortintegernoThe end point port of WireGuard peer should be within the range of 1-65535.
allowAddressarray<string>yesIP/MASK address list of WireGuard peer allowed.
presharedKeystringnoThe presharedKey of WireGuard peer must have 44 character of base64 and end with '='.
keepAliveintegeryesThe keepalive second of WireGuard peer should be within the range of 0-65535.
commentstringnoThe comment of WireGuard peer should contain 0 to 128 characters.
json
// omada_call_operation
{
  "operationId": "modifyPeer",
  "params": {
    "siteId": "<siteId>",
    "id": "<id>"
  },
  "body": "{...}"
}
Details, permissions and error codes

Modify an existing wireguard peer. This interface has been deprecated. Please use the following interfaces instead: Modify site-to-site VPN by manual.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33006 - This name already exists in this site.
-43202 - The number of WireGuard peers has reached the limit.
-43203 - The WireGuard peer does not exist.
-43205 - The public key of the WireGuard peer for the same interface already exists.
-43206 - The device does not support configuring domain for WireGuard peer.
-43207 - Endpoint and Endpoint Port need to be filled in at the same time or both left blank.
-43208 - The device does not support WireGuard VPN.

getWireguardSummary ​

GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-summarys

Deprecated

This operation is deprecated.

Get all wireguard's id and name info

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
json
// omada_call_operation
{
  "operationId": "getWireguardSummary",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get all wireguard's id and name info.
The interface requires one of the permissions:
Site Settings Manager View Only
Network Config Page View Only

listWireguard ​

GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards

Deprecated

This operation is deprecated.

Get wireguard list

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
pagequeryintegernoStart page number. Start from 1. (default 1)
pageSizequeryintegernoNumber of entries per page. It should be within the range of 1–1000. (default 100)
searchKeyquerystringnosearchKey
json
// omada_call_operation
{
  "operationId": "listWireguard",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get wireguard list. This interface has been deprecated. Please use the following interfaces instead: Get VPN Site to Site summary list and Get site-to-site VPN detail info.
The interface requires one of the permissions:
Site Settings Manager View Only
Network Config Page View Only

createWireguard ​

POST /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards

Deprecated

This operation is deprecated.

Create new wireguard

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)

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

FieldTypeRequiredDescription
namestringyesThe name of WireGuard VPN should contain 1 to 64 characters.
statusbooleanyesThe status of WireGuard VPN. Valid value is true or false.
mtuintegeryesThe MTU of WireGuard VPN should be within the range of 576-1440.
listenPortintegeryesThe listening port for WireGuard VPN should be within the range of 1-65535.
privateKeystringyesThe private key of WireGuard VPN must have 44 character of base64 and end with '='.
localIpstringyesThe local IP address of WireGuard VPN.
json
// omada_call_operation
{
  "operationId": "createWireguard",
  "params": {
    "siteId": "<siteId>"
  },
  "body": "{...}"
}
Details, permissions and error codes

Create new wireguard. This interface has been deprecated. Please use the following interfaces instead: Create site-to-site VPN by manual.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33006 - This name already exists in this site.
-43200 - The number of WireGuard entries has reached the limit.
-43204 - The port has been used.
-43208 - The device does not support WireGuard VPN.

deleteWireguard ​

DELETE /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards/{id}

Deprecated

This operation is deprecated.

Delete an existing wireguard

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
idpathstringyesWireGuard VPN ID
json
// omada_call_operation
{
  "operationId": "deleteWireguard",
  "params": {
    "siteId": "<siteId>",
    "id": "<id>"
  }
}
Details, permissions and error codes

Delete an existing wireguard. This interface has been deprecated. Please use the following interfaces instead: Delete VPN V2.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify

modifyWireguard ​

PUT /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards/{id}

Deprecated

This operation is deprecated.

Modify an existing wireguard

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
idpathstringyesWireguard ID

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

FieldTypeRequiredDescription
namestringyesThe name of WireGuard VPN should contain 1 to 64 characters.
statusbooleanyesThe status of WireGuard VPN. Valid value is true or false.
mtuintegeryesThe MTU of WireGuard VPN should be within the range of 576-1440.
listenPortintegeryesThe listening port for WireGuard VPN should be within the range of 1-65535.
privateKeystringyesThe private key of WireGuard VPN must have 44 character of base64 and end with '='.
localIpstringyesThe local IP address of WireGuard VPN.
json
// omada_call_operation
{
  "operationId": "modifyWireguard",
  "params": {
    "siteId": "<siteId>",
    "id": "<id>"
  },
  "body": "{...}"
}
Details, permissions and error codes

Modify an existing wireguard. This interface has been deprecated. Please use the following interfaces instead: Modify site-to-site VPN by manual.
The interface requires one of the permissions:
Site Settings Manager Modify
Network Config Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-33006 - This name already exists in this site.
-43201 - The WireGuard entry does not exist.
-43204 - The port has been used.
-43208 - The device does not support WireGuard VPN.

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