All URIs are relative to https://napi.arvancloud.ir/cdn/4.0
Method | HTTP request | Description |
---|---|---|
ActiveHealthCheckDestroy | Delete /domains/{domain}/health-checks/{healthcheck} | Delete healthcheck |
ActiveHealthCheckIndex | Get /domains/{domain}/health-checks | Get Defined HealthCheck |
ActiveHealthCheckReportsDetails | Get /domains/{domain}/health-checks/reports/details | Get reports of a single healthcheck monitoring |
ActiveHealthCheckReportsSummary | Get /domains/{domain}/health-checks/reports/summary | Get summary reports of a single healthcheck monitoring |
ActiveHealthCheckShow | Get /domains/{domain}/health-checks/{healthcheck} | Get a single healthcheck |
ActiveHealthCheckStore | Post /domains/{domain}/health-checks | Store a new HealthCheck |
ActiveHealthCheckUpdate | Patch /domains/{domain}/health-checks/{healthcheck} | Update Health check |
HealthChecksZonesIndex | Get /health-checks/zones | Get list of all health-check zones |
MessageResponse ActiveHealthCheckDestroy(ctx, domain, healthcheck).Execute()
Delete healthcheck
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
healthcheck := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckDestroy(context.Background(), domain, healthcheck).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckDestroy``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckDestroy`: MessageResponse
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckDestroy`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name | |
healthcheck | string |
Other parameters are passed through a pointer to a apiActiveHealthCheckDestroyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ActiveHealthCheckIndex200Response ActiveHealthCheckIndex(ctx, domain).Execute()
Get Defined HealthCheck
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckIndex(context.Background(), domain).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckIndex``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckIndex`: ActiveHealthCheckIndex200Response
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckIndex`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name |
Other parameters are passed through a pointer to a apiActiveHealthCheckIndexRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
ActiveHealthCheckIndex200Response
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ActiveHealthCheckReportsDetails200Response ActiveHealthCheckReportsDetails(ctx, domain).Name(name).Upstream(upstream).Type_(type_).Period(period).Since(since).Until(until).Direction(direction).PerPage(perPage).Page(page).Execute()
Get reports of a single healthcheck monitoring
package main
import (
"context"
"fmt"
"os"
"time"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
name := "name_example" // string | Name of the health-check
upstream := "upstream_example" // string | Upstream of the health-check monitoring
type_ := "type__example" // string | Type of reports for the health check (optional) (default to "all")
period := "period_example" // string | Select period -ending now- for report (optional)
since := time.Now() // time.Time | (optional)
until := time.Now() // time.Time | (optional)
direction := "direction_example" // string | Set the direction of sorting (optional)
perPage := int32(56) // int32 | Set how many items returned per page (optional)
page := int32(56) // int32 | Set the desired page number (optional) (default to 1)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckReportsDetails(context.Background(), domain).Name(name).Upstream(upstream).Type_(type_).Period(period).Since(since).Until(until).Direction(direction).PerPage(perPage).Page(page).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckReportsDetails``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckReportsDetails`: ActiveHealthCheckReportsDetails200Response
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckReportsDetails`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name |
Other parameters are passed through a pointer to a apiActiveHealthCheckReportsDetailsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
name | string | Name of the health-check | upstream | string | Upstream of the health-check monitoring | type_ | string | Type of reports for the health check | [default to "all"] period | string | Select period -ending now- for report | since | time.Time | | until | time.Time | | direction | string | Set the direction of sorting | perPage | int32 | Set how many items returned per page | page | int32 | Set the desired page number | [default to 1]
ActiveHealthCheckReportsDetails200Response
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ActiveHealthCheckReportsSummary200Response ActiveHealthCheckReportsSummary(ctx, domain).Name(name).Upstream(upstream).Period(period).Since(since).Until(until).Direction(direction).Execute()
Get summary reports of a single healthcheck monitoring
package main
import (
"context"
"fmt"
"os"
"time"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
name := "name_example" // string | Name of the health-check
upstream := "upstream_example" // string | Upstream of the health-check monitoring
period := "period_example" // string | Select period -ending now- for report (optional)
since := time.Now() // time.Time | (optional)
until := time.Now() // time.Time | (optional)
direction := "direction_example" // string | Set the direction of sorting (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckReportsSummary(context.Background(), domain).Name(name).Upstream(upstream).Period(period).Since(since).Until(until).Direction(direction).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckReportsSummary``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckReportsSummary`: ActiveHealthCheckReportsSummary200Response
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckReportsSummary`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name |
Other parameters are passed through a pointer to a apiActiveHealthCheckReportsSummaryRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
name | string | Name of the health-check | upstream | string | Upstream of the health-check monitoring | period | string | Select period -ending now- for report | since | time.Time | | until | time.Time | | direction | string | Set the direction of sorting |
ActiveHealthCheckReportsSummary200Response
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
HealthCheckResponse ActiveHealthCheckShow(ctx, domain, healthcheck).Execute()
Get a single healthcheck
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
healthcheck := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckShow(context.Background(), domain, healthcheck).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckShow``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckShow`: HealthCheckResponse
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckShow`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name | |
healthcheck | string |
Other parameters are passed through a pointer to a apiActiveHealthCheckShowRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
HealthCheckResponse ActiveHealthCheckStore(ctx, domain).HealthCheck(healthCheck).Execute()
Store a new HealthCheck
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
healthCheck := *openapiclient.NewHealthCheck() // HealthCheck | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckStore(context.Background(), domain).HealthCheck(healthCheck).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckStore``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckStore`: HealthCheckResponse
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckStore`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name |
Other parameters are passed through a pointer to a apiActiveHealthCheckStoreRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
healthCheck | HealthCheck | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
HealthCheckResponse ActiveHealthCheckUpdate(ctx, domain, healthcheck).HealthCheck(healthCheck).Execute()
Update Health check
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
domain := "example.com" // string | Domain name
healthcheck := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string |
healthCheck := *openapiclient.NewHealthCheck() // HealthCheck | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.ActiveHealthCheckUpdate(context.Background(), domain, healthcheck).HealthCheck(healthCheck).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.ActiveHealthCheckUpdate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ActiveHealthCheckUpdate`: HealthCheckResponse
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.ActiveHealthCheckUpdate`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
domain | string | Domain name | |
healthcheck | string |
Other parameters are passed through a pointer to a apiActiveHealthCheckUpdateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
healthCheck | HealthCheck | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
HealthChecksZonesIndex200Response HealthChecksZonesIndex(ctx).Execute()
Get list of all health-check zones
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/arash-r1c/cdn-go-sdk"
)
func main() {
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ActiveHealthCheckApi.HealthChecksZonesIndex(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ActiveHealthCheckApi.HealthChecksZonesIndex``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `HealthChecksZonesIndex`: HealthChecksZonesIndex200Response
fmt.Fprintf(os.Stdout, "Response from `ActiveHealthCheckApi.HealthChecksZonesIndex`: %v\n", resp)
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiHealthChecksZonesIndexRequest struct via the builder pattern
HealthChecksZonesIndex200Response
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]