Notification
Upsert
Inserts or updates a notification record. Notifications can be applied for either one of the following dimensions:
- Global
- Job
- Task
- Appointment
This is a cascading mechanism. The appointment has a reference to a task, and a task has a reference to a job. Notifications for a job will be shown for all corresponding tasks and jobs. Same goes for tasks, whose notifications will be shown to the planned appointments.
Name | Data Type | Default | Required | Description |
---|---|---|---|---|
SourceApp | nvarchar(30) | See API reference | ||
SourceType | nvarchar(10) | See API reference | ||
NotificationType | int | 0 | See API reference | |
NotificationCode | nvarchar(20) | |||
NotificationText | nvarchar(max) | |||
NotificationDate | datetime | |||
mboc_id | nvarchar(50) | |||
JobNo | nvarchar(50) | |||
TaskNo | nvarchar(50) | |||
AppointmentId | bigint | |||
AppointmentGuid | nvarchar(50) | |||
SentFromBackOffice | bit | 1 |
- Import
- API
- This endpoint is available in the import API endpoint
/import
via the proceduremboc_upsertConnector
. - Example body:
[
{
"StoredProcedureName": "mboc_upsertNotification",
"ParameterNames": ["SourceApp","SourceType", "NotificationType", "NotificationCode", "NotificationText", "NotificationDate", "JobNo", "TaskNo"],
"ParameterValues": ["MYSOURCEAPP","MYSOURCETYPE", "1","CODE","TEXT","DATE", "JOBNO", "TASKNO"]
}
]
- Endpoint:
/notification
- Supported HTTP methods: POST (create) and PUT (update)
- Example body:
{
"SourceApp": "MYSOURCEAPP",
"SourceType": "MYSOURCETYPE",
"AppointmentNo": "MYAPPOINTMENTNO",
"TaskNo": "MYTASKNO",
"JobNo": "MYJOBNO",
"Type": 1,
"Code": "MYCODE",
"Text": "MYTEXT",
"Date": "MYDATE"
}
Delete
Deletes the notification record. The behavior of this procedure depends on the data passed to it:
- A filled out
JobNo
andTaskNo
will lead to all notification records attached to theTaskNo
being deleted. - Populating
JobNo
will delete all notification records attached to theJobNo
.
Name | Data Type | Default | Required | Description |
---|---|---|---|---|
SourceApp | nvarchar(30) | See API reference | ||
SourceType | nvarchar(10) | See API reference | ||
mboc_id | nvarchar(50) | |||
JobNo | nvarchar(50) | |||
TaskNo | nvarchar(50) | |||
AppointmentId | bigint | 0 | ||
AppointmentGuid | nvarchar(50) | |||
SentFromBackOffice | bit | 1 |
- Import
- API
- This endpoint is available in the import API endpoint
/import
via the proceduremboc_upsertConnector
. - Example body:
[
{
"StoredProcedureName": "mboc_deleteNotification",
"ParameterNames": ["SourceApp","SourceType", "JobNo", "TaskNo", "AppointmentGuid"],
"ParameterValues": ["MYSOURCEAPP","MYSOURCETYPE", "JOBNO","TASKNO","APPOINTMENTGUID"]
}
]
- Endpoint:
/notification
- Supported HTTP methods: DELETE
- Example body:
{
"SourceApp": "MYSOURCEAPP",
"SourceType": "MYSOURCETYPE",
"AppointmentNo": "MYAPPOINTMENTNO",
"TaskNo": "MYTASKNO",
"JobNo": "MYJOBNO",
"Type": 1,
"Code": "MYCODE",
"Text": "MYTEXT",
"Date": "MYDATE"
}
API reference
Source
Dime.Scheduler is a centralized planning application. One of its key tenets is the ability to accommodate data from different origins. For instance, it is perfectly acceptable to plan work orders from Business Central, CRM, imported Excel sheets, etc., and Dime.Scheduler won't break a sweat because of the existence of the Source App
and Source Type
fields in the data model.
Source App
When the planner creates an appointment for a resource or task, Dime.Scheduler knows which system to notify. Through the connector setup, Dime.Scheduler will find a matching SourceApp
and subsequently send the appointment to the corresponding URI.
The source app field is a unique identifier that identifies a back-office instance such as a tenant of Business Central, a test environment, an instance of CRM cloud, or any other application you wish to use to feed data into Dime.Scheduler.
Source Type
The SourceType
is used inside the back-office system itself. A source type represents a distinct entity such as a service order, production order, assembly order, etc.
The standard connectors that Dime Software provides make it possible to plan different types of resources and tasks. When Dime.Scheduler posts an appointment to a standard connector, it ends up in a staging table, which is then processed by the connector to ensure the appointment produced in Dime.Scheduler is traced back to the original record using the externally identifiable fields (JobNo
, TaskNo
, ResourceNo
) that identify the record.
Notification type
The values for notification types are:
- 0 for Information
- 1 for Warning
- 2 for Error.