Creating a Subscription (Any Type)
Create any valid type of subscription in Notifications to receive notifications.
These steps show how to open the Create Subscription panel from the details page for the topic that you want to add the subscription to. You can also open this panel from the Subscriptions list page, specifying the topic in the panel: Select Create Subscription, and then select a Subscription Topic. Notifications creates the subscription. If the subscription type requires a confirmation, then Notifications sends a confirmation URL to its endpoint and the subscription is pending until confirmation is received. Use the oci ons subscription create command and required parameters to create a subscription:
oci ons subscription create --compartment-id <compartment_OCID> --protocol <subscription_type> --subscription-endpoint <endpoint> --topic-id <topic_OCID>
For a complete list of parameters and values for CLI commands, see the Command Line Reference for Notifications.
Run the CreateSubscription operation to create a subscription.
What's Next
Confirmation is required for some protocols, such as email. In this case, the new subscription remains in Pending (PENDING
) status until confirmation is received. Notifications sends a confirmation URL to the subscription endpoint, such as an email address for an email subscription. To confirm a new subscription, or to review subscription protocols that require confirmation, see Confirming a Subscription.
Although a new subscription must be in the same compartment as its parent topic, you can move it to another compartment after creation. See Moving a Subscription.