Working with Events in the Developer Portal
Prerequisites for Consuming Events
-
You must first add an OPERA environment from which to consume events before adding and subscribing to events.
-
The OPERA environment must either have streaming enabled (see Streaming API) or have polling configured (see Configuring the Polling Subscription).
For information on working with business events in OPERA Cloud, refer to the Configuring Business Events topic in the OPERA Cloud User Guide. This topic also provides a list of business events and data elements.
Creating a Template of Events for an Application
The event template represents the list of events a given integration will use. When subscribing to consume events from a given OPERA environment, the template is a faster way to ensure the correct list of events is subscribed.
Before subscribing to consume events from a given OPERA environment, you must first create a template for the integration.
The template can be edited at any time. For example, your integration might change, and it now needs to consumer more events or fewer events.
Note:
Changes made on the template do not affect existing subscriptions to OPERA environments but will take effect when subscribing to new OPERA environments.
-
Open the Developer Portal and click the Applications tab.
-
Search for and click an application to open it.
-
Click the Events tab.
-
Click Add Event to Template and complete the following information:
-
Category: Select a category for the event, such as Reservation.
-
Event: Select an event for the category, such as Check In.
- Click Add Filter.
- Select one or more Data Elements. IMPORTANT: You will receive a Business Event notification only when the selected Data Elements change. A maximum of 50 filters can be configured per event subscription; this reflects the current system behavior and may change in future releases.
- Click Next to Add Condition (This is not mandatory, you can click Next.)
- Choose a Data Element and then select an Operator (for example, =, !=, LIKE, NOT LIKE, IN, NOT IN, BETWEEN, <=, IS NULL, IS NOT NULL). IMPORTANT: You will receive a Business Event notification only when the selected Data Element matches the condition specified. Note that different properties (even within the same chain) can have different values for configuration items, such as room types.
- Enter Value 1 (and Value 2 if applicable) up to 500 characters.
- Continue adding conditions as needed.
- Use operators AND or OR to combine multiple conditions.
- Reorder conditions using drag-and-drop.
- Condition Display Flag:
- When a condition is added to an event, a Conditions Set flag appears on the event row in the Subscriptions page, indicating that a condition exists.
- If you edit the event and remove all conditions, the Conditions Set flag no longer appears.
- This allows you to quickly identify which events have conditions applied without opening each event individually.
Note:
To remove an event from the template, click the Remove link. -
-
Click Add to add the event to the template.
-
Repeat these steps to add additional events to the template.
Once you have configured all the events your integration requires, click the Subscribed tab and choose any OPERA environment(s) from which to consume these events.
Subscribing to Events
A partner can subscribe to business events from a customer. Subscriptions to business events are specific to each application.
-
Open the Developer Portal and click the Applications tab.
-
Search for and click an application to open it.
-
Click the Events tab.
-
Click the Subscribed tab.
-
Click the Subscribe link.
-
Select an Environment and click Subscribe.
If one or more of the events on the template are not available for the selected environment, a warning appears. If accepted, only those events available in the selected environment are subscribed.
-
As a customer subscribing to events from your environment, select which hotels will consume the events.
Note:
- Only OPERA environments enabled for streaming appear in the list of environments. Events will not be subscribed if they are not available in the version of OPERA Cloud run by the selected environment.
- If the application needs to forward or publish Business Events to external integrations, a Publisher must be configured in OPERA Cloud. Without a Publisher configuration, the application can receive streamed events but cannot forward them to external integrations.
Disaster Recovery for Event Streaming
- New subscriptions — Any new event subscription you create automatically uses disaster recovery support. No additional setup or configuration is required.
- Existing subscriptions — Existing event
subscriptions continue to work without interruption. To enable
disaster recovery support, you must recreate the subscription by
unsubscribing from all events in the environment and subscribing
again. If applicable, the Developer Portal displays an
information notification on the event subscription indicating
that the subscription does not support disaster recovery and
must be recreated.
Note:
The OPERA environment region shown in the user interface remains unchanged. Enabling disaster recovery does not move your OPERA environment and does not impact event consumption unless you choose to recreate the subscription.
Viewing Connection Status for Subscribed Events
Table 12-1 Status Indicators
| Status Indicator Dot | Meaning |
|---|---|
| Green | The application is actively connected to the environment. |
| Amber | No active connection for 30 minutes. |
| Red | No active connection for 1 hour. |
| (no dot) | The subscription is pending approval, in progress, or not connected to streaming. |
Example Scenarios
- The existing subscription is inactive for more than or equal to 1 hour - A Red dot appears. An email alert is sent.
- Connect an inactive subscription - Dot changes to green.
- First-time subscription - Dot is green immediately after connecting.
- The Customer subscription is without a streaming connection - Green initially, amber after 30 minutes, and red after 1 hour. An email alert is sent.
- The Partner subscription is pending approval - No dot until approved and then green. The dot turns amber after 30 minutes inactive and then red after 1 hour. An email alert is sent.
- Error states - In Progress shows no dot; Error shows dot matching last known state.
- Resubscription - Keeps existing dot until connection changes; green when approved.
- Rejected pending approval - No dot during approval; returns to previous dot color after rejection.
- Partner sandbox subscription - Green when connected; amber after 30 minutes inactive; and red after 1 hour inactive. An email alert is sent only if the Streaming Connection Alerts checkbox is selected.
Streaming Connection Alerts
How It Works
- When a stream becomes inactive for 1 hour (red dot), an email alert is sent to the registered application email.
- Alerts repeat every 1 hour until the connection is restored.
- Partner sandbox environments: Alerts are sent only if the "Streaming Connection Alerts" checkbox is selected in the Developer Portal.
- Non-sandbox environments: Alerts are always sent by default.
- Amber status (30 minutes inactive) does not trigger an alert.
- Go to the Developer Portal and select Applications, select Events, and then select the Subscribed tab.
- If the environment is a partner sandbox, you will see a checkbox labeled Streaming Connection Alerts.
- The Streaming Connection Alerts checkbox is selected by default, meaning alerts are automatically enabled.
- To disable alerts for that sandbox environment, deselect Streaming Connection Alerts.
Note:
- Ensure the email address registered with the application is correct and actively monitored.
- Alerts are only delivered to the registered email; incorrect or inactive addresses will prevent you from receiving notifications.
Disabling or Enabling Event Streaming for an Environment
You can temporarily disable event streaming for a selected environment within an application.
When event streaming is disabled, events from the selected environment are not sent to the application and are not available for later delivery.
Event streaming is managed independently for each application and environment combination. Disabling streaming for one environment does not affect other environments in the same application. If the same environment is subscribed to another application, that application is not affected.
- Verify that the application has at least one subscribed environment.
- Open the Developer Portal and click the Applications tab.
- Search for and click the application.
- Click the Events tab.
- Click the Subscribed tab.
- Locate the environment for which you want to disable event streaming.
- Click Disable.
- Review the confirmation message.
- Confirm that you want to disable event streaming.
Event streaming is disabled for the selected application and environment. The existing event subscription configuration is retained. The environment remains listed on the Subscribed tab and is shown as disabled for the application.
Note:
Events generated while event streaming is disabled are not queued, replayed, or delivered after event streaming is enabled again.Enabling Event Streaming for an Environment
You can enable event streaming for an environment that was previously disabled.
- Verify that event streaming is disabled for the selected environment.
- Open the Developer Portal and click the Applications tab.
- Search for and click the application.
- Click the Events tab.
- Click the Subscribed tab.
- Locate the disabled environment.
- Click Enable.
Events generated after streaming is enabled are sent to the application according to the existing subscription configuration.
Retrying a Failed Enable or Disable Action
If the Developer Portal cannot enable or disable event streaming, an error message with an error code appears.
- Review the error message.
- Click Retry.
If the retry succeeds, the environment status is updated on the Subscribed tab. If the retry fails, an error message with an error code appears again.
Automatic Disabling of Inactive Event Streams
An event stream is a subscription to one environment for one application.
An application can have more than one stream if it is subscribed to multiple environments. Each stream is managed independently.
A stream is evaluated based on the last successful streaming connection.
If the same environment is subscribed to another application, that stream is managed separately.
A stream is considered active only when the streaming consumer successfully connects to the stream. Turning on the streaming toggle in the Developer Portal does not reset the inactivity counter.
If the streaming toggle is turned on but the streaming consumer does not connect, the stream remains inactive and may be automatically disabled again during the next inactivity check.
Inactive Stream Timeline and Descriptions
| Inactivity Period | Description |
|---|---|
| 4 days after the last successful streaming connection |
A warning email is sent to the email address associated with the application. The email advises that streaming will be automatically disabled if the streaming consumer does not connect to the stream within the next 3 days. The email includes the application name and environment description for each affected stream. If the recipient email address is associated with multiple applications, the email might include multiple inactive streams across those applications. The stream remains enabled, but it is subject to automatic disablement if the streaming consumer does not connect before the 7-day inactivity threshold. Note: The warning email does not reset the inactivity counter. The counter is reset only when the streaming consumer successfully connects to the stream. |
| 7 days after the last successful streaming connection |
Streaming is automatically disabled. The stream configuration and stream allocation are retained. When streaming is disabled:
A notification email is sent to the email address associated with the application. The email lists the streams that were disabled due to inactivity and includes the application name and environment description for each stream. The email also informs the user that the disabled streams can be enabled again in the Developer Portal. Other streams are not affected unless they also meet the inactivity criteria. |
| 30 days after the last successful streaming connection | The stream is permanently deleted. The associated configuration and queued events are removed, and capacity is returned to the OHIP stream pool. |
Viewing Automatically Disabled Streams
You can view automatically disabled streams from the application's event subscription details.
- Open the Developer Portal and click the Applications tab.
- Search for and click the application.
- Click the Events tab.
- Click the Subscribed tab.
- Locate the environment associated with the stream.
- Review the streaming toggle for the environment.
Enabling an Automatically Disabled Stream
You can enable an automatically disabled stream from the Subscribed tab before the stream is permanently deleted.
- Verify that the stream is disabled and still within the 30-day inactivity window.
- Open the Developer Portal and click the Applications tab.
- Search for and click the application.
- Click the Events tab.
- Click the Subscribed tab.
- Locate the environment for the disabled stream.
- Turn on the streaming toggle for the environment.
The OPERA configuration is re-enabled, and the existing stream allocation is reused. The stream is available to receive and enqueue events after the streaming consumer successfully connects to the stream. No additional approval is required.
Note:
Turning on the streaming toggle in the Developer Portal does not reset the inactivity counter.
The inactivity counter is reset only when the streaming consumer successfully connects to the stream.
If the streaming toggle is turned on but the streaming consumer does not connect, the stream remains inactive and may be automatically disabled again during the next inactivity check.
30-Day Permanent Deletion
- The stream is removed.
- The associated configuration is deleted.
- Any remaining queued events associated with the stream are removed.
- The stream capacity is returned to the OHIP stream pool.
The stream is no longer available in the Developer Portal. To consume events from the environment again, create a new subscription.
Note:
Stream capacity is not returned to the OHIP stream pool when streaming is disabled after 7 days of inactivity. Capacity is returned only when the stream is permanently deleted after 30 days of inactivity.Unsubscribing from Events
Note:
Unsubscribing from events on the Subscribe tab does not affect the events that appear on the Template tab. Also, changes made to events on the Template tab do not affect event subscriptions.
-
Open the Developer Portal and click the Applications tab.
-
Search for and click an application to open it.
-
Click the Events tab.
-
Click the Subscribed tab.
-
Under Event Subscriptions, locate the event and click the green arrow to expand it and then click Unsubscribe.
Approving Events
A customer with Developer Portal access can approve the consumption of events from a specific environment. The customer can approve a partner's request to consume events before any events are sent to the partner. This enables customers to protect their data.
-
Open the Developer Portal and click the Applications tab.
-
Search for and click an application to open it.
-
Click the Partner Applications tab.
Note:
Applications with pending event subscriptions appear with a red ribbon icon on the application card.
-
Click an application with a pending event to open it.
-
Click the Events tab.
-
Click Next to proceed with approval.
-
Select the properties for the event subscription and click Next.
-
Click Approve.
Rejecting Events
-
Open the Developer Portal and click the Applications tab.
-
Search for and click an application to open it.
-
Click the Partner Applications tab.
-
Click an application with a pending event to open it.
-
Click the Events tab.
-
Click Reject to reject the subscription.
The event status changes to ‘In Progress’ and then to ‘Rejected’ status. The partner can see this status in the Developer Portal.
Revoking Events
As a customer, you can revoke a partner application's access to consume business events from a specific OPERA environment through the Developer Portal. Revoking access disables the partner application's event subscription for that environment.
- The associated external system interface in OPERA is disabled or removed.
- All event subscriptions configured for the partner application are removed.
- Any business events queued in OHIP for delivery to the partner application are purged.
- The partner application owner receives an email notification informing them that access has been revoked.
To revoke access to business events:
- Open the Developer Portal and click the Applications tab.
- Search for and open the application.
- Click the Partner Applications tab.
- Select the Approved partner application associated with the event subscription.
- Click the Events tab.
- Select Revoke Access and confirm the action.
Adding Events to Existing Subscription
-
Add the events on the Template tab (see the ‘Creating a Template of Events for an Application’ procedure above).
-
Subscribe again to consume events from the same environment (see the ‘Subscribing to Events’ procedure above).
Adding Hotels to an Existing Subscription
-
Open the customer or partner application.
-
Go to the Events tab.
-
Click Edit next to the list of hotels.
-
Select the hotels that can consume the events.
-
Click Save.