1.6 Setting up End User logs
Give your end users more details about the integrations they have enabled.
Flow setup
To show the logs for an end user, the underlying Flows need to provide the necessary data in JSON format as the last step of the Flow in the following format (filled with example values, see the example of the resulting logs):
The overview view (1.) will be automatically generated without having to adjust the underlying Flows.
However, the # of successful and unsuccessful records will only be shown when setting up Flows as described.
The values for an end user will be displayed as specified (see above).
Depending on your end users, it might make sense to write entity names in their local language instead of using the terms used by the API.
1. Error handling and status logging
Each upsert (or create/create) step in a Flow should use manual error handling and the error path should set a dictionary such as:
The id
should be an ID that's familiar to the end user (e.g. a number shown in the UI of your system, instead of the internal ID used by the API. If applicable, both can be the same).
In case of success, a similar step (but with a different status
) should be set, so that the results can later be easily summarized.
This part of the Flow would then for example look like this:
For common errors, it might make sense to validate records with a filter action
The same setup should be similar for other entities that are upserted.
2. Setting the errors
list
errors
listAfter all steps of the Flow are finished, the results need to be summarized and transformed into the expected format. For that, it's easiest to use a Spreadsheet Helper with the Query Spreadsheet Action, with the following SQL:
3. Setting the details
list
details
listSimilar to the errors
list, the Query Spreadsheet Action can be used:
4. Setting the overview
list
overview
listSimilar to the errors
list, the Query Spreadsheet Action can be used. This time, the details
output should be the reference of the Action:
5. Setting the combined list
Finally, all the lists are combined in the final step of the Flow:
The end of the Flow would look similar to this:
The logic and format in the Flow can be freely defined (i.e. the examples shown above are just one possibility and might not apply to all Flows).
The only part that needs to be in the same structure as shown in the documentation is the final step of the Flow.
Run Status
The run status is set automatically, based on the following logic:
Last updated