Push Notifications

Form ID: (SM302000)

You use this form to add push notification definitions—that is, to set up MYOB Advanced to send push notifications to the notification destination if specific data is changed in MYOB Advanced. You can also use the form to view the details of existing push notification definitions.

Form Toolbar

The form toolbar includes only standard buttons. For the list of standard buttons, see Form Toolbar and More Menu.

Summary Area

In this area, you can specify the main properties of a new notification definition, or select a definition (by selecting its name) and view its main properties.
Element Description
Destination Name Required. The name of the notification destination.
Active A check box that indicates (if selected) that this notification destination is active and notifications can be sent to it.
Destination Type

Required. The type of the notification destination.

You can select one of the following options:
  • Webhook: An HTTP address to which MYOB Advanced sends HTTP POST requests with notification information.
  • Message Queue: A queue of the Microsoft Message Queuing (MSMQ) service.
  • SignalR Hub: The SignalR hub, which can be used if you can expose neither an HTTP address (webhook) nor a message queue to receive push notifications. For information about how to connect your application to the SignalR hub of MYOB Advanced, see To Connect to the SignalR Hub.
  • Commerce Push Destination: A queue that is used for commerce notifications. The queue uses the RabbitMQ service by default.

For more information on the types of notification destinations, see Push Notification Destinations.

Address

Required. The address to which MYOB Advanced should send push notifications.

The format of the address depends on the value specified in the Destination Type box as follows:

  • For the Webhook type, you specify the HTTP address to which MYOB Advanced should send notifications in the following format: http://<SiteName>:<PortNumber>/<PageName>?<ParameterNames>, where <SiteName> is the name of the site, <PortNumber> is the optional number of the port, <PageName> is the optional name of the page, <ParameterNames> is the optional list of the URL parameters. For example, the following HTTP address specifies a site on the local computer: http://localhost:80/main.aspx?pushqueue.
  • For the Message Queue type, you specify the address of a local or remote private Microsoft message queue in the following format: <ComputerName>\private$\<QueueName>, where <ComputerName> is the name of the computer, and <QueueName> is the name of the queue. For example, the following address specifies the TestQueueForPushNotifications queue on the MyComputer computer: MyComputer\private$\TestQueueForPushNotificatons.
  • For the SignalR Hub type, the system fills in the PushNotificationsHub value automatically.
  • For the Commerce Push Destination type, the system fills in the Commerce value automatically.
Header Name
The name of the header that should be included in the HTTP POST request that MYOB Advanced sends to the destination address (which is specified in the Address box).
Note: Do not specify the Accept and Content-Type headers for the request. The values of these headers are specified automatically by the system.

This element is available only if Webhook is selected in the Destination Type box.

Header Value

The value of the header that should be included in the HTTP POST request that MYOB Advanced sends to the destination address (which is specified in the Address box).

This element is available only if Webhook is selected in the Destination Type box.

Generic Inquiries Tab

This tab contains the Inquiries table, which displays the existing generic inquiries for which MYOB Advanced produces push notifications to the selected destination if the results of any of these generic inquiries change. For any generic inquiry selected in the Inquiries table, the Fields table lists the particular fields whose changes should be tracked by the system in the results of the generic inquiry.

Tip: If any fields are specified on the Fields tab, the push notifications are sent for the changes in only these fields. However, these push notifications include information about the values of all fields in the results of the generic inquiry.
Table 1. Inquiries Table Toolbar

The table toolbar includes standard buttons and buttons that are specific to this table. For the list of standard buttons, see Table Toolbar. The table-specific buttons are listed below.

Button Description
View Inquiry Opens the selected generic inquiry on the Generic Inquiry (SM208000) form.
Table 2. Inquiries Table Columns
Column Description
Active A check box that indicates (if selected) that this generic inquiry is active and MYOB Advanced generates notifications for changes in the results of this generic inquiry.
Inquiry Title The name of the generic inquiry for which MYOB Advanced sends notifications to the selected notification destination.
Track All Fields

A check box that indicates (if selected) that all fields in the results of this generic inquiry are tracked by the system. If all fields in the results of the generic inquiry are tracked, the system produces push notifications for changes of any field in the results of the generic inquiry, which can cause overflow of the push notification queue. If you need to track only particular fields in the results of the generic inquiry, push notifications for changes in other fields are useless for you but consume system resources. Therefore, we recommend that you leave this check box cleared and specify particular fields to be tracked in the Fields table.

By default, the check box is cleared.

If this check box is cleared, the Fields table must contain at least one field that the system should track in the results of the generic inquiry. If this check box is selected, fields cannot be added in the Fields table.

Table 3. Fields Table

The table toolbar includes only standard buttons. For the list of standard buttons, see Table Toolbar.

Column Description
Table Name The name of the table that contains the field that the system should track. You can select any table that is included in the results of the generic inquiry.
Field Name The name of the field that the system should track. You can select any field that is included in the results of the generic inquiry.

Built-In Definitions Tab

This tab contains the Definitions table, which displays the classes for which MYOB Advanced sends push notifications to the selected destination if the results of any of these queries change. These classes are called built-in definitions. For any built-in definition selected in the Definitions table, the Fields table lists the particular fields whose changes should be tracked by the system in the results of the query defined by the built-in definition.

Tip: If any fields are specified on the Fields tab, the push notifications are sent for the changes in only these fields. However,these push notifications include information about the values of all fields in the results of the data query.

For information about how to define a class with a data query, see To Create a Built-In Definition in the MYOB Advanced Framework Development Guide.

Table 4. Definitions Table

The table toolbar includes only standard buttons. For the list of standard buttons, see Table Toolbar.

Columns Description
Active A check box that indicates (if selected) that this class is active and MYOB Advanced generates notifications for the changes in the results of the data query defined by this class.
Class Name The name of the class that defines a data query for which MYOB Advanced sends notifications to the selected notification destination.
Track All Fields

A check box that indicates (if selected) that all fields in the results of the data query defined by the built-in definition are tracked by the system. If all fields in the results of the data query are tracked, the system produces push notifications for changes of any field in the results of the data query, which can cause overflow of the push notification queue. If you need to track only particular fields in the results of the data query, push notifications for changes in other fields are useless for you but consume system resources. Therefore, we recommend that you leave this check box cleared and specify the particular fields to be tracked in the Fields table.

By default, the check box is cleared.

If this check box is cleared, the Fields table must contain at least one field that the system should track in the results of the data query. If this check box is selected, fields cannot be added in the Fields table for this built-in definition.

Table 5. Fields Table

The table toolbar includes only standard buttons. For the list of standard buttons, see Table Toolbar.

Column Description
Table Name The name of the table that contains the field that the system should track. You can select any table that is included in the results of the data query defined by the built-in definition.
Field Name The name of the field that the system should track. You can select any field that is included in the results of the data query defined by the built-in definition.