All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
CustomerDetail | Get /api/v1/customers/{cUUID} | Get a customer's details |
DeleteCustomer | Delete /api/v1/customers/{cUUID} | Delete a customer |
GetHostInfo | Get /api/v1/customers/{cUUID}/host_info | Get a customer's host info |
ListOfCustomers | Get /api/v1/customers | List customers |
UpdateCustomer | Put /api/v1/customers/{cUUID} | Update a customer |
CustomerDetailsData CustomerDetail(ctx, cUUID).Execute()
Get a customer's details
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
cUUID := TODO // string |
configuration := openapiclient.NewConfiguration()
api_client := openapiclient.NewAPIClient(configuration)
resp, r, err := api_client.CustomerManagementApi.CustomerDetail(context.Background(), cUUID).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CustomerManagementApi.CustomerDetail``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CustomerDetail`: CustomerDetailsData
fmt.Fprintf(os.Stdout, "Response from `CustomerManagementApi.CustomerDetail`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
cUUID | string |
Other parameters are passed through a pointer to a apiCustomerDetailRequest 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]
YBPSuccess DeleteCustomer(ctx, cUUID).Request(request).Execute()
Delete a customer
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
cUUID := TODO // string |
request := TODO // interface{} | (optional)
configuration := openapiclient.NewConfiguration()
api_client := openapiclient.NewAPIClient(configuration)
resp, r, err := api_client.CustomerManagementApi.DeleteCustomer(context.Background(), cUUID).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CustomerManagementApi.DeleteCustomer``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `DeleteCustomer`: YBPSuccess
fmt.Fprintf(os.Stdout, "Response from `CustomerManagementApi.DeleteCustomer`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
cUUID | string |
Other parameters are passed through a pointer to a apiDeleteCustomerRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
request | interface{} | |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
map[string]map[string]interface{} GetHostInfo(ctx, cUUID).Execute()
Get a customer's host info
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
cUUID := TODO // string |
configuration := openapiclient.NewConfiguration()
api_client := openapiclient.NewAPIClient(configuration)
resp, r, err := api_client.CustomerManagementApi.GetHostInfo(context.Background(), cUUID).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CustomerManagementApi.GetHostInfo``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetHostInfo`: map[string]map[string]interface{}
fmt.Fprintf(os.Stdout, "Response from `CustomerManagementApi.GetHostInfo`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
cUUID | string |
Other parameters are passed through a pointer to a apiGetHostInfoRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
map[string]map[string]interface{}
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]Customer ListOfCustomers(ctx).Request(request).Execute()
List customers
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
request := TODO // interface{} | (optional)
configuration := openapiclient.NewConfiguration()
api_client := openapiclient.NewAPIClient(configuration)
resp, r, err := api_client.CustomerManagementApi.ListOfCustomers(context.Background()).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CustomerManagementApi.ListOfCustomers``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListOfCustomers`: []Customer
fmt.Fprintf(os.Stdout, "Response from `CustomerManagementApi.ListOfCustomers`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiListOfCustomersRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
request | interface{} |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Customer UpdateCustomer(ctx, cUUID).Customer(customer).Request(request).Execute()
Update a customer
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
cUUID := TODO // string |
customer := *openapiclient.NewCustomerAlertData(*openapiclient.NewAlertingData(), "CallhomeLevel_example", *openapiclient.NewSmtpData()) // CustomerAlertData | Customer data to be updated
request := TODO // interface{} | (optional)
configuration := openapiclient.NewConfiguration()
api_client := openapiclient.NewAPIClient(configuration)
resp, r, err := api_client.CustomerManagementApi.UpdateCustomer(context.Background(), cUUID).Customer(customer).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CustomerManagementApi.UpdateCustomer``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateCustomer`: Customer
fmt.Fprintf(os.Stdout, "Response from `CustomerManagementApi.UpdateCustomer`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
cUUID | string |
Other parameters are passed through a pointer to a apiUpdateCustomerRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
customer | CustomerAlertData | Customer data to be updated | request | interface{} | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]