## Documentation Index

Fetch the complete documentation index at: [/llms.txt](https://docs.cognigy.com/llms.txt)

Use this file to discover all available pages before exploring further.

Connects to the SIP server and starts a call in one operation. This is a convenience method that combines [`connect()`](https://docs.cognigy.com/click-to-call/sdk/api-reference/connect) and [`startCall()`](https://docs.cognigy.com/click-to-call/sdk/api-reference/start-call).

## Signature

```
await client.connectAndCall();
```

## Parameters

None.

## Returns

`Promise<void>`

## Throws

An error if the connection or call initiation fails.

## Example

```
await client.connectAndCall();
console.log('Connected and call started');
```

### With Error Handling

```
try {
  await client.connectAndCall();
} catch (error) {
  console.error('Failed to connect and call:', error.message);
}
```

## More Information

- [connect](https://docs.cognigy.com/click-to-call/sdk/api-reference/connect)
- [startCall](https://docs.cognigy.com/click-to-call/sdk/api-reference/start-call)
- [endCall](https://docs.cognigy.com/click-to-call/sdk/api-reference/end-call)

Last modified on April 21, 2026
