# Add to Siri Shortcut (iOS Only)

{% hint style="info" %}
You'll need to import the javascript file in your website before starting from this [link](https://docs.webtonative.com/javascript-apis/getting-started).
{% endhint %}

{% tabs %}
{% tab title="Plain Javascript" %}

```
const { Siri } = window.WTN

Siri.addToSiri({
  title: "Your Title for Siri Function",
  suggestedPhrase: "Prase for Siri to recognise and take action",
  actionUrl: "Url to redirect"
});


//Example
Siri.addToSiri({
  title: "Siri Shortcut",
  suggestedPhrase: "Open Webtonative",
  actionUrl: "https://www.webtonative.com/"
});
```

{% endtab %}

{% tab title="ES5+" %}

<pre><code>import { Siri } from "webtonative";
<strong>
</strong>Siri.addToSiri({
  title: "Track Order",
  suggestedPhrase: "Track my order",
  actionUrl: "https://yourdomain.com/orders"
});

//Example
Siri.addToSiri({
  title: "Track Order",
  suggestedPhrase: "Track my order",
  actionUrl: "https://yourdomain.com/orders"
});
</code></pre>

{% endtab %}
{% endtabs %}

This allows you to define a custom Siri shortcut (e.g., “Open Webtonative”) that opens a specific URL inside your app using voice commands like:

> *“Hey Siri, open webtonative”*

<div><figure><img src="https://46162361-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MbRbEDU7JrvMAgg52AY%2Fuploads%2FvaYh1xfSeobaDwsMQ5Lb%2FIMG_F54379AA523F-1.jpeg?alt=media&#x26;token=ba5d693d-1294-4eaa-9be2-eeb2ed619bbb" alt=""><figcaption></figcaption></figure> <figure><img src="https://46162361-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MbRbEDU7JrvMAgg52AY%2Fuploads%2FU54eVpl9Vmyam8ClsWRs%2FIMG_C18A408DD364-1.jpeg?alt=media&#x26;token=a9d8e30e-f6ec-423b-bc66-9b18722b13a3" alt=""><figcaption></figcaption></figure></div>

| Key               | Type   | Required | Description                                             |
| ----------------- | ------ | -------- | ------------------------------------------------------- |
| `title`           | string | ✅        | The title of the shortcut shown in iOS UI               |
| `suggestedPhrase` | string | ✅        | The voice command you suggest users add to Siri         |
| `actionUrl`       | string | ✅        | The URL that should open when the shortcut is triggered |

Feature added in iOS on 04/08/25
