You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While you don't have to use type annotations, it is highly recommended because it enables autocomplete in your IDE and helps you spot mistakes faster.
40
-
For our example we only need the [DocumentReleaseEvent](reference/events.md/#documentreleaseevent). It contains a list of documents that were released. Typically this will only be a single document, however it is best practices to iterate over all of the documents.
40
+
For our example we only need the [DocumentReleasedEvent](reference/events.md/#documentreleasedevent). It contains a list of documents that were released. Typically this will only be a single document, however it is best practices to iterate over all of the documents.
41
41
42
42
```python title="mymodule.py"
43
43
import requests
44
44
import json
45
45
46
46
from csfunctions import MetaData, Service
47
-
from csfunctions.events importDocumentReleaseEvent
47
+
from csfunctions.events importDocumentReleasedEvent
Functions can return a list of "Actions" that should be performed in CIM Database Cloud. Not all Events support the same actions, so check the supported actions in the [Events documentation](events.md). For example Events that are triggered **after** the release of an object don't support AbortAndShowError, because the release can't be aborted anymore, however the "release check" events do support it.
2
-
3
-
### Return an Action:
4
-
5
-
Example:
1
+
Functions can return a list of "Actions" that should be performed in CIM Database Cloud.
6
2
7
3
```python
8
4
from csfunctions.actions import AbortAndShowErrorAction
Not all Events support the same actions, so check the supported actions in the [Events documentation](events.md). For example Events that are triggered **after** the release of an object don't support AbortAndShowError, because the release can't be aborted anymore, however the "release check" events do support it.
12
+
13
+
14
+
## AbortAndShowErrorAction
16
15
17
16
`csfunctions.actions.AbortAndShowErrorAction`
18
17
19
18
Aborts the current operation and shows an error message to the user.
20
19
21
20
**Attributes:**
22
21
23
-
|Attribute|Type|Description|
24
-
|-|-|-|
25
-
|message|str|Error message that will be shown to the user|
0 commit comments