Community Forum
status_updated_at field
Hi,
When [this](https://docs.rootplatform.com/docs/actions#mark-policy-not-taken-up) action occurs, can you confirm whether the `status_updated_at` field on the policy will be updated to the date of the event?
We have an example of an event where this is not the case. The issue on our side (consuming the `policy_updated` event via a webhook) is that we don't know whether that status was updated at the time of the event of previously some time in the past.
Thanks
Posted by Albert over 1 year ago
API key perms required for rp push -f
Hi,
Which permissions need to assigned to an API key to be able to do `rp push -f`?
Posted by Albert over 1 year ago
Prepopulating application schema data
Hi,
After capturing the quote, I have the following (truncated) response from the `getQuote` hook:
```json
{
"quote_package_id": "115f1f1f-0870-49a6-8580-1197f1efb3d2",
"package_name": "OneSpark Essential Funeral",
"input_data": {
"commencement_date": "2023-04-01T00:00:00.000Z"
},
"product_module_definition_id": "b5389a08-94a2-4ed9-a9f9-7abe6d07668f"
}
```
On the application schema page (the page after the policyholder page). I'm trying to prepopulate the `commencement_date`. The relevant schema excerpt below:
```json
{
"key": "commencement_date",
"type": "date-picker",
"label": "Cover Start Date *",
"outputPath": "commencement_date",
"validators": [
{
"validation": {
"type": "required"
}
}
]
},
```
The way I'm interpreting the docs [here](https://docs.rootplatform.com/docs/schemas-overview#prefilling-schema-inputs) is that the `input_data` object should make the page prepopulate the commencement date, but this is not working. The only time the mechanism seems to be working is when I navigate back after capturing the application fields, but then the `input_data` is set on the application, and not coming from the quote anymore.
Please advise.
Thanks
Posted by Albert over 1 year ago
Requote alteration
Hi,
Is there a way to customize the requote alteration hook? I want to validate whether the policy being requoted has a specific field already present, and if so, requoting should not be allowed to continue.
I see a lot of documentation mention the old deprecated requote hook, but none describing the new Requote alteration.
Thanks
Posted by Albert over 1 year ago
Events General Common Structure
Good day
When working with <https://docs.rootplatform.com/reference/events> I know that the structure can vary depending on the event. But is there some sort of common structure we can rely on for the event?
Can I assume the below is common to all events?
```json JSON
{
"event": {
"type": "application_used",
"created_at": "2017-10-05T18:28:30+02:00",
"requested_by": {
"type": "system"
},
// this portion can and will differ based on event.type
}
// this portion can and will differ based on event.type
}
```
Or the TS type for this base event would be something like:
```typescript TypeScript
type base_event = {
"event": string; // this is actually an enum
"created_at": Date;
// the rest of this differes bsaed on the type
}
type base_event_body = {
"event": base_event;
// the rest of this differes bsaed on the type
}
```
Posted by Yair over 1 year ago
Custom notifications sent from [email protected]
We have custom notification sent during our anniversary process. Different to our policy schedule comms which is sent from [email protected]. the custom notification arrives at the end user as sent from [email protected]. Is there a way to change this? Some config in the .root-config.json file?
Posted by Albert over 1 year ago
Policy created_by object and resolving the id to an email or other identifier
On the policy object, the created_by object lists an id field:
```json json
"created_by": {
"id": "00000000-0000-0000-0000-000000000001",
"type": "user"
},
```
Is there a way to resolve the created_by object on a policy to a person's email address or other identifiers?
Posted by Albert over 1 year ago
Unable to send a custom notification
I'm able to send out a custom notification when using the rest API from postman for example, but I'm not managing to send out the notification from the code. I've tried invoking the Root object directly:
await root.notifications.triggerCustomEvent({
customEventKey: 'policy_anniversary_custom_notification',
customEventType: 'policy',
id: policy.policy_id,
});
as well as now with an action from the alteration hook:
{
name: 'trigger_custom_notification_event',
custom_event_key: 'policy_anniversary_custom_notification',
custom_event_type: 'policy',
policy_id: policy.policy_id,
}
But none of the above methods are working.
Please advise. An example of a policy that should have sent a notification is <https://app.root.co.za/orgs/d00e0ea4-0ee2-4c08-804d-61df85ca32ec/insurance/policies/d5f2f53e-10fb-4dd6-bb62-c9374e9c791f>. I can see two alterations where 'applied' one being the update_policy_module_data and the other being the trigger_custom_notification_event.
Thanks in advance,
Posted by Albert over 1 year ago
Send notifications to our team internally
Hi,
I have a requirement to send communication to the team in case of an anniversary process failure. The anniversary process is triggered using a scheduled function.
In case of failure during any part of the scheduled function execution, we'd ideally like to know about it, to enable the team to investigate issues quickly.
Is there a standard pattern that I can follow here and any documentation describing this pattern?
Posted by Albert over 1 year ago
Horizontal scrollbars on datastore screen
Hi,
I'm adding a bunch of values to an existing datastore here: <https://app.root.co.za/orgs/d00e0ea4-0ee2-4c08-804d-61df85ca32ec/insurance/workbench/data-stores/sandbox_environment_secrets>
After adding the edit button is no longer visible and impossible to get to without using 'tab' on the keyboard.
It's not a train smash but should be easily fixable.
Posted by Albert over 1 year ago