You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sending push notifications using `deviceId` or `clientId` requires the `push-admin` capability for your API key. Use this method for testing purposes. In a production environment, you would typically send push notifications from your backend server (by posting messages with `push``extras` field to a channel).
278
278
279
-
To test push notifications in your app, you can use [Ably dashboard](https://ably.com/dashboard), [Apple developer dashboard](https://icloud.developer.apple.com/dashboard/) or Ably CLI.
279
+
To test push notifications in your app, you can use [Ably dashboard](https://ably.com/dashboard), [Apple developer dashboard](https://icloud.developer.apple.com/dashboard/) or [Ably CLI](/docs/platform/tools/cli).
280
280
281
-
To send to your client ID using Ably CLI paste the following command into your terminal:
281
+
To publish to your client ID using the [Ably CLI](/docs/platform/tools/cli) paste the following command into your terminal:
282
282
283
283
<Code>
284
284
```shell
@@ -554,12 +554,14 @@ You can get your device ID from the device details button (don't confuse it with
554
554
555
555
### Send push via channel <aid="step-4-send-channel"/>
556
556
557
-
To test pushes via channel, subscribe to "Channel 1" in the UI and post a message to the "exampleChannel1"
558
-
with a `push``extras` field using Ably CLI:
557
+
To test pushes via channel, subscribe to "Channel 1" in the UI and publish a push notification to the channel using the [Ably CLI](/docs/platform/tools/cli):
559
558
560
559
<Code>
561
560
```shell
562
-
ably channels publish exampleChannel1 '{"name":"example","data":"Hello from CLI!","extras":{"push":{"notification":{"title":"Ably CLI","body":"Hello from CLI!"},"data":{"foo":"bar"}}}}'
@@ -989,5 +991,6 @@ Verify that your app receives and handles location push notifications correctly
989
991
* Learn about [rules](/docs/channels#rules) for channel-based push notifications.
990
992
* Read more about the [Push Admin API](/docs/api/realtime-sdk?lang=swift#push-admin).
991
993
* Check out the [Push Notifications](/docs/push) documentation for advanced use cases.
994
+
* Explore [Ably CLI push commands](/docs/cli/push) for the full list of push CLI options.
992
995
993
996
You can also explore the [Ably SDK for Swift](https://github.com/ably/ably-cocoa) on GitHub, or visit the [API references](/docs/api/realtime-sdk?lang=swift) for additional functionality.
Copy file name to clipboardExpand all lines: src/pages/docs/push/getting-started/fcm.mdx
+7-3Lines changed: 7 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -399,7 +399,7 @@ fun subscribeToRealtime(channelName: String) {
399
399
Sending push notifications using `deviceId` or `clientId` requires the `push-admin` capability for your API key. Use this method for testing purposes. In a production environment, you would typically send push notifications from your backend server (by posting messages with `push``extras` field to a channel).
400
400
</Aside>
401
401
402
-
Now use the Ably CLI to test sending a push notification to your client ID:
402
+
Now use the [Ably CLI](/docs/platform/tools/cli) to test publishing a push notification to your client ID:
403
403
404
404
<Code>
405
405
```shell
@@ -660,11 +660,14 @@ Build and run your app on an Android device or emulator. Tap **Activate Push** a
660
660
661
661
### Send push via channel <aid="step-4-send-channel"/>
662
662
663
-
To test push notifications via channel, tap **Subscribe to Channel** in the app and then publish a message to "exampleChannel1" with a `push``extras` field using Ably CLI:
663
+
To test push notifications via channel, tap **Subscribe to Channel** in the app and then publish a push notification to the channel using the [Ably CLI](/docs/platform/tools/cli):
664
664
665
665
<Code>
666
666
```shell
667
-
ably channels publish exampleChannel1 '{"name":"example","data":"Hello from CLI!","extras":{"push":{"notification":{"title":"Ably CLI","body":"Hello from CLI!"},"data":{"foo":"bar"}}}}'
@@ -824,5 +827,6 @@ Build and run your app again. Use the new buttons to send push notifications dir
824
827
* Explore [push notification administration](/docs/push#push-admin) for managing devices and subscriptions.
825
828
* Learn about [rules](/docs/channels#rules) for channel-based push notifications.
826
829
* Read more about the [Push Admin API](/docs/api/realtime-sdk/push-admin).
830
+
* Explore [Ably CLI push commands](/docs/cli/push) for the full list of push CLI options.
827
831
828
832
You can also explore the [Ably SDK for Android](https://github.com/ably/ably-java) on GitHub, or visit the [API references](/docs/api/realtime-sdk?lang=kotlin) for additional functionality.
Copy file name to clipboardExpand all lines: src/pages/docs/push/getting-started/flutter.mdx
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -454,7 +454,7 @@ In the app tap **Activate Push** and wait until the status message displays your
454
454
455
455
### Publish directly to your device <aid="step-5-direct"/>
456
456
457
-
Publish a push notification directly to your client ID (or device ID using `--device-id` instead of `--client-id`) via the Ably CLI:
457
+
Publish a push notification directly to your client ID (or device ID using `--device-id` instead of `--client-id`) via the [Ably CLI](/docs/platform/tools/cli):
Copy file name to clipboardExpand all lines: src/pages/docs/push/getting-started/react-native.mdx
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -478,7 +478,7 @@ In the app tap **Activate Push** and wait until the status message displays your
478
478
479
479
### Publish directly to your device <aid="step-5-direct"/>
480
480
481
-
Publish a push notification directly to your client ID (or device ID using `--device-id` instead of `--client-id`) via the Ably CLI:
481
+
Publish a push notification directly to your client ID (or device ID using `--device-id` instead of `--client-id`) via the [Ably CLI](/docs/platform/tools/cli):
Copy file name to clipboardExpand all lines: src/pages/docs/push/getting-started/web.mdx
+8-4Lines changed: 8 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -405,9 +405,9 @@ async function unsubscribeFromChannel() {
405
405
406
406
Sending push notifications using `deviceId` or `clientId` requires the `push-admin` capability for your API key. Use this method for testing purposes. In a production environment, you would typically send push notifications from your backend server (by posting messages with `push``extras` field to a channel).
407
407
408
-
To test push notifications in your app, you can use [Ably dashboard](https://ably.com/dashboard) or Ably CLI.
408
+
To test push notifications in your app, you can use [Ably dashboard](https://ably.com/dashboard) or [Ably CLI](/docs/platform/tools/cli).
409
409
410
-
To send to your client using Ably CLI paste the following command into your terminal:
410
+
To publish to your client using the [Ably CLI](/docs/platform/tools/cli) paste the following command into your terminal:
411
411
412
412
<Code>
413
413
```shell
@@ -570,11 +570,14 @@ Try sending push using this `deviceId` or `clientId` as shown earlier.
570
570
571
571
### Send push via channel <a id="step-4-send-channel"/>
572
572
573
-
To test pushes via channel, subscribe to the channel in the UI and post a message to the "exampleChannel1"with a `push``extras` field using Ably CLI:
573
+
To test pushes via channel, subscribe to the channel in the UI and publish a push notification to the channel using the [Ably CLI](/docs/platform/tools/cli):
574
574
575
575
<Code>
576
576
```shell
577
-
ably channels publish exampleChannel1 '{"name":"example","data":"Hello from CLI!","extras":{"push":{"notification":{"title":"Ably CLI","body":"Hello from CLI!"},"data":{"foo":"bar"}}}}'
@@ -727,5 +730,6 @@ Safari on macOS 13+ supports Web Push, but with some limitations. Notification a
727
730
* Learn about [rules](/docs/channels#rules) for channel-based push notifications.
728
731
* Read more about the [Push Admin API](/docs/api/realtime-sdk/push-admin).
729
732
* Check out the [Web Push Notifications](/docs/push/configure/web) documentation for advanced use cases.
733
+
* Explore [Ably CLI push commands](/docs/cli/push) for the full list of push CLI options.
730
734
731
735
You can also explore the [Ably JavaScript SDK](https://github.com/ably/ably-js) on GitHub, or visit the [API references](/docs/api/realtime-sdk?lang=javascript) for additional functionality.
0 commit comments