All URIs are relative to /api
Method | HTTP request | Description |
---|---|---|
PreviewComputersGet | Get /preview/computers | Return a list of Computers |
ComputersSearchResults PreviewComputersGet(ctx).Page(page).Size(size).Pagesize(pagesize).PageSize(pageSize).Sort(sort).Execute()
Return a list of Computers
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
page := int32(56) // int32 | (optional) (default to 0)
size := int32(56) // int32 | (optional) (default to 100)
pagesize := int32(56) // int32 | (optional) (default to 100)
pageSize := int32(56) // int32 | (optional) (default to 100)
sort := "sort_example" // string | Sorting criteria in the format: property:asc/desc. Default sort is name:asc. Multiple sort criteria are supported and must be separated with a comma. Example: sort=date:desc,name:asc (optional) (default to "name:asc")
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.ComputersPreviewApi.PreviewComputersGet(context.Background()).Page(page).Size(size).Pagesize(pagesize).PageSize(pageSize).Sort(sort).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ComputersPreviewApi.PreviewComputersGet``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PreviewComputersGet`: ComputersSearchResults
fmt.Fprintf(os.Stdout, "Response from `ComputersPreviewApi.PreviewComputersGet`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiPreviewComputersGetRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
page | int32 | [default to 0] | |
size | int32 | [default to 100] | |
pagesize | int32 | [default to 100] | |
pageSize | int32 | [default to 100] | |
sort | string | Sorting criteria in the format: property:asc/desc. Default sort is name:asc. Multiple sort criteria are supported and must be separated with a comma. Example: sort=date:desc,name:asc | [default to "name:asc"] |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]