All URIs are relative to https://api.meraki.com/api/v1
Method | HTTP request | Description |
---|---|---|
CreateDeviceLiveToolsPing | Post /devices/{serial}/liveTools/ping | Enqueue a job to ping a target host from the device |
GetDeviceLiveToolsPing | Get /devices/{serial}/liveTools/ping/{id} | Return a ping job |
CreateDeviceLiveToolsPing201Response CreateDeviceLiveToolsPing(ctx, serial).CreateDeviceLiveToolsPingRequest(createDeviceLiveToolsPingRequest).Execute()
Enqueue a job to ping a target host from the device
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/meraki/dashboard-api-go/client"
)
func main() {
serial := "serial_example" // string | Serial
createDeviceLiveToolsPingRequest := *openapiclient.NewCreateDeviceLiveToolsPingRequest("Target_example") // CreateDeviceLiveToolsPingRequest |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.PingApi.CreateDeviceLiveToolsPing(context.Background(), serial).CreateDeviceLiveToolsPingRequest(createDeviceLiveToolsPingRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `PingApi.CreateDeviceLiveToolsPing``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateDeviceLiveToolsPing`: CreateDeviceLiveToolsPing201Response
fmt.Fprintf(os.Stdout, "Response from `PingApi.CreateDeviceLiveToolsPing`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
serial | string | Serial |
Other parameters are passed through a pointer to a apiCreateDeviceLiveToolsPingRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
createDeviceLiveToolsPingRequest | CreateDeviceLiveToolsPingRequest | |
CreateDeviceLiveToolsPing201Response
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DevicesSerialLiveToolsPingPostRequestMessage GetDeviceLiveToolsPing(ctx, serial, id).Execute()
Return a ping job
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/meraki/dashboard-api-go/client"
)
func main() {
serial := "serial_example" // string | Serial
id := "id_example" // string | ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.PingApi.GetDeviceLiveToolsPing(context.Background(), serial, id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `PingApi.GetDeviceLiveToolsPing``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetDeviceLiveToolsPing`: DevicesSerialLiveToolsPingPostRequestMessage
fmt.Fprintf(os.Stdout, "Response from `PingApi.GetDeviceLiveToolsPing`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
serial | string | Serial | |
id | string | ID |
Other parameters are passed through a pointer to a apiGetDeviceLiveToolsPingRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
DevicesSerialLiveToolsPingPostRequestMessage
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]