> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes.

# playRingtone

> Play a named ringtone on a call.

[playaction]: /docs/server-sdks/reference/typescript/relay/actions

[play]: /docs/server-sdks/reference/typescript/relay/call/play

Play a named ringtone on the call. A typed convenience over [`play()`][play].

## **Parameters**

**`name`** `string` — required

Ringtone name, a country code such as `"us"` or `"gb"`.

---

**`options`** `object`

Playback options.

---

**`options.duration`** `number`

Seconds to play the ringtone.

---

**`options.volume`** `number`

Volume adjustment in dB, from `-40` to `40`.

---

**`options.onCompleted`** `(event: RelayEvent) => void | Promise<void>`

Callback invoked when the operation reaches a terminal state.

---

## **Returns**

`Promise<`[`PlayAction`][playaction]`>` -- An action handle with `stop()`, `pause()`, `resume()`, `volume()`, and `wait()` methods.

## **Example**

```typescript {11}
import { RelayClient } from '@signalwire/sdk';

const client = new RelayClient({
  project: process.env.SIGNALWIRE_PROJECT_ID!,
  token: process.env.SIGNALWIRE_API_TOKEN!,
  contexts: ['default']
});

client.onCall(async (call) => {
  await call.answer();
  const action = await call.playRingtone('us', { duration: 10 });
  await action.wait();
});

await client.run();
```