(Call)
- ListUcCalls - List all calls
List all calls
package main
import(
unifiedgosdk "github.com/unified-to/unified-go-sdk"
"github.com/unified-to/unified-go-sdk/pkg/models/operations"
"context"
"log"
)
func main() {
s := unifiedgosdk.New(
unifiedgosdk.WithSecurity("<YOUR_API_KEY_HERE>"),
)
request := operations.ListUcCallsRequest{
ConnectionID: "<value>",
}
ctx := context.Background()
res, err := s.Call.ListUcCalls(ctx, request)
if err != nil {
log.Fatal(err)
}
if res.UcCalls != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
request |
operations.ListUcCallsRequest | ✔️ | The request object to use for the request. |
*operations.ListUcCallsResponse, error
Error Object | Status Code | Content Type |
---|---|---|
sdkerrors.SDKError | 4xx-5xx | / |