FirewallAPI
All URIs are relative to https://use1-omada-northbound.tplinkcloud.com
| Method | HTTP request | Description |
|---|---|---|
| GetDefaultFirewallConfig | Get /openapi/v1/{omadacId}/sites/{siteId}/firewall/timeout/default | Get firewall default setting |
| GetFirewallSetting | Get /openapi/v1/{omadacId}/sites/{siteId}/firewall | Get firewall setting |
| ModifyFirewallSetting | Patch /openapi/v1/{omadacId}/sites/{siteId}/firewall | Modify firewall setting |
| ResetFirewallSetting | Patch /openapi/v1/{omadacId}/sites/{siteId}/firewall/reset | Reset firewall setting |
GetDefaultFirewallConfig
OperationResponseFirewallSetting GetDefaultFirewallConfig(ctx, omadacId, siteId).Execute()
Get firewall default setting
Example
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Tohaker/omada-go-sdk/omada"
)
func main() {
omadacId := "omadacId_example" // string | Omada ID
siteId := "siteId_example" // string | Site ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FirewallAPI.GetDefaultFirewallConfig(context.Background(), omadacId, siteId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FirewallAPI.GetDefaultFirewallConfig``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetDefaultFirewallConfig`: OperationResponseFirewallSetting
fmt.Fprintf(os.Stdout, "Response from `FirewallAPI.GetDefaultFirewallConfig`: %v\n", resp)
}
Path Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| omadacId | string | Omada ID | |
| siteId | string | Site ID |
Other Parameters
Other parameters are passed through a pointer to a apiGetDefaultFirewallConfigRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
Return type
OperationResponseFirewallSetting
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetFirewallSetting
OperationResponseFirewallSetting GetFirewallSetting(ctx, omadacId, siteId).Execute()
Get firewall setting
Example
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Tohaker/omada-go-sdk/omada"
)
func main() {
omadacId := "omadacId_example" // string | Omada ID
siteId := "siteId_example" // string | Site ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FirewallAPI.GetFirewallSetting(context.Background(), omadacId, siteId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FirewallAPI.GetFirewallSetting``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFirewallSetting`: OperationResponseFirewallSetting
fmt.Fprintf(os.Stdout, "Response from `FirewallAPI.GetFirewallSetting`: %v\n", resp)
}
Path Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| omadacId | string | Omada ID | |
| siteId | string | Site ID |
Other Parameters
Other parameters are passed through a pointer to a apiGetFirewallSettingRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
Return type
OperationResponseFirewallSetting
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ModifyFirewallSetting
OperationResponseWithoutResult ModifyFirewallSetting(ctx, omadacId, siteId).FirewallSetting(firewallSetting).Execute()
Modify firewall setting
Example
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Tohaker/omada-go-sdk/omada"
)
func main() {
omadacId := "omadacId_example" // string | Omada ID
siteId := "siteId_example" // string | Site ID
firewallSetting := *openapiclient.NewFirewallSetting(false, int32(123), int32(123), false, false, false, int32(123), int32(123), int32(123), int32(123), int32(123), int32(123), int32(123), int32(123), int32(123), int32(123)) // FirewallSetting |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FirewallAPI.ModifyFirewallSetting(context.Background(), omadacId, siteId).FirewallSetting(firewallSetting).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FirewallAPI.ModifyFirewallSetting``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ModifyFirewallSetting`: OperationResponseWithoutResult
fmt.Fprintf(os.Stdout, "Response from `FirewallAPI.ModifyFirewallSetting`: %v\n", resp)
}
Path Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| omadacId | string | Omada ID | |
| siteId | string | Site ID |
Other Parameters
Other parameters are passed through a pointer to a apiModifyFirewallSettingRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
firewallSetting | FirewallSetting | |
Return type
OperationResponseWithoutResult
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ResetFirewallSetting
OperationResponseWithoutResult ResetFirewallSetting(ctx, omadacId, siteId).Execute()
Reset firewall setting
Example
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Tohaker/omada-go-sdk/omada"
)
func main() {
omadacId := "omadacId_example" // string | Omada ID
siteId := "siteId_example" // string | Site ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FirewallAPI.ResetFirewallSetting(context.Background(), omadacId, siteId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FirewallAPI.ResetFirewallSetting``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ResetFirewallSetting`: OperationResponseWithoutResult
fmt.Fprintf(os.Stdout, "Response from `FirewallAPI.ResetFirewallSetting`: %v\n", resp)
}
Path Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| omadacId | string | Omada ID | |
| siteId | string | Site ID |
Other Parameters
Other parameters are passed through a pointer to a apiResetFirewallSettingRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
Return type
OperationResponseWithoutResult
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: /
[Back to top] [Back to API list] [Back to Model list] [Back to README]