Skip to content

Commit 3969e17

Browse files
IanSkelskeykenstir
authored andcommitted
Rename and update Action Trigger setup documentation
Renames the \"create-an-action-trigger.md\" file to \"configure-evergreen.md\" to better reflect its content. Enhances documentation by adding detailed procedures for cloning and creating action triggers with reminders and warnings. Links to a newly added sample template subsection for better guidance. - Guide title changed to \"Configure Evergreen Action Triggers\" - Added sections on cloning and creating action triggers from scratch - Included tips and warnings for best practices - Provided a link to the Evergreen Action Trigger documentation for additional help Release-Note: Update and rename Action Trigger documentation for clarity Signed-off-by: Ian Skelskey <[email protected]>
1 parent a53995a commit 3969e17

File tree

3 files changed

+32
-7
lines changed

3 files changed

+32
-7
lines changed

docs/pn-setup-guide/create-an-action-trigger.md docs/pn-setup-guide/configure-evergreen.md

+30-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
---
2+
23
sidebar_position: 4
34
---
4-
# Create an action trigger
5+
# Configure Evergreen Action Triggers
56

67
This guide is for the Evergreen Administrator.
78
It will help you set up your Evergreen (EG) server for sending a push notifications with an action trigger. It assumes that your System Administrator has already installed the `hemlock-sendmsg` daemon, and it's listening on `localhost:8842`.
@@ -37,7 +38,29 @@ The action trigger uses the CallHTTP reactor to send a request to the hemlock-se
3738

3839
As an EG admin, login to the Staff client and go to Local Administration >> Notifications / Action Triggers.
3940

40-
Procedure:
41+
Checkout the [Evergreen Action Trigger documentation](https://docs.evergreen-ils.org/docs/latest/admin/actiontriggers.html) for more information.
42+
43+
### Cloning an Existing Action Trigger
44+
45+
:::tip
46+
Cloning an existing action trigger is a good way to start especially if you are not familiar with action triggers. It is easier to modify an existing action trigger than to create one from scratch and can help reduce errors and save time on troubleshooting.
47+
- Make sure that you clone a working action trigger.
48+
- Clone an action trigger that uses the same hook as the one you want to create.
49+
:::
50+
51+
1. Right click an existing event definition and click `Clone Selected` or select the event definition and click `Clone Selected` from the Actions menu.
52+
2. When prompted to clone the environment, select `Yes`.
53+
3. Set the reactor to `CallHTTP`.
54+
4. Set the template according to the [sample template](#sample-template) below.
55+
56+
### Creating an Action Trigger from Scratch
57+
58+
:::warning
59+
Creating an action trigger from scratch can be tricky as the environment and parameters of action triggers can be complex. Only create an action trigger from scratch if you are certain you can do so.
60+
:::
61+
62+
This example event definition is for a courtesy notice. Some details may need to be adjusted for your specific use case. It is most important to set the reactor to `CallHTTP` and the template according to the [sample template](#sample-template) below.
63+
4164
* Click `New Event Definition`
4265
* Set the following form values:
4366

@@ -53,13 +76,15 @@ Procedure:
5376
| Event Repeatability Delay | 00:00:00 |
5477
| Max Event Validity Delay | -300 days |
5578
| Retention Interval | 6 mons |
56-
| Template | (see below) |
79+
| Template | [(see below)](#sample-template) |
5780
| Context Bib Path | target_copy.call_number.record |
5881
| Context Item Path | target_copy |
5982
| Context Library Path | circ_lib |
6083
| Context User Path | usr |
6184

62-
* Set the Template form value to
85+
### Sample Template
86+
87+
Whether cloning an existing action trigger or creating a new one, the template should be set as follows. The parameters `title`, `body`, and `type` will vary depending on the type of notification you want to send.
6388

6489
```
6590
method get
@@ -90,4 +115,4 @@ url http://localhost:8842/send
90115
debug 1
91116
</Parameters>
92117
```
93-
* Click `Save`
118+
* Click `Save`

docs/pn-setup-guide/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ Setup involves the following steps (and the following people):
1313
* [Set up the Firebase project (Mobile App Admin)](setup-firebase-project.md)
1414
* [Configure the Hemlock app (Mobile App Developer)](configure-hemlock-app.md)
1515
* [Install the hemlock-sendmsg daemon (Evergreen System Admin)](install-sendmsg-daemon.md)
16-
* [Create an action trigger (Evergreen Admin)](create-an-action-trigger.md)
16+
* [Configure Evergreen Action Triggers (Evergreen Admin)](configure-evergreen.md)

docs/pn-troubleshooting-guide/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ Ensure that notifications are enabled for the app:
122122

123123
#### "500 Error" after signing in
124124
<details>
125-
1. Ensure the User Setting Type is created. After signing in, the app tries to store the push notification token in the database, and it gets this error if the User Setting Type is missing. See [Push Notification Setup Guide](../pn-setup-guide/create-an-action-trigger.md).
125+
1. Ensure the User Setting Type is created. After signing in, the app tries to store the push notification token in the database, and it gets this error if the User Setting Type is missing. See [Push Notification Setup Guide](../pn-setup-guide/configure-evergreen.md).
126126
</details>
127127

128128
## Additional Notes

0 commit comments

Comments
 (0)