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
Copy file name to clipboardExpand all lines: content/en/docs/refguide/modeling/integration/odata-services/published-odata-services/published-odata-entity.md
+15-3Lines changed: 15 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -116,7 +116,7 @@ When the app receives a request to insert a new object, it does the following:
116
116
117
117
This is the behavior when you choose the action **Write to database**.
118
118
119
-
You can also choose the **Call a microflow** action to use your own logic. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/) parameter. In the microflow, you can use the [Commit](/refguide/committing-objects/) activity to commit the changes to the database.
119
+
You can also choose the **Call a microflow** action to use your own logic. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/)and/or a [System.HttpResponse](/refguide/http-request-and-response-entities/)parameter. In the microflow, you can use the [Commit](/refguide/committing-objects/) activity to commit the changes to the database. See [Customizing the Outgoing HTTP Response](#custom-http-response) below for more information.
120
120
121
121
In the publishing app, you can use a validation message action to report a validation error. The client app can include a custom error handler on the [Send External Object](/refguide/send-external-object/) activity to handle the error. If the microflow reports [validation feedback](/refguide/validation-feedback/), the runtime informs the client that the request has failed. For more information, see [Supported OData Operations](/refguide/supported-odata-operations/#updating-objects).
122
122
@@ -161,15 +161,15 @@ When the app receives a request to change values, it does the following:
161
161
162
162
This is the behavior when you choose the action **Write to database**.
163
163
164
-
You can also choose the **Call a microflow** action to use your own logic. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/) parameter. In the microflow, you can use the [Commit](/refguide/committing-objects/) activity to commit the changes to the database.
164
+
You can also choose the **Call a microflow** action to use your own logic. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/)and/or a [System.HttpResponse](/refguide/http-request-and-response-entities/)parameter. In the microflow, you can use the [Commit](/refguide/committing-objects/) activity to commit the changes to the database. See [Customizing the Outgoing HTTP Response](#custom-http-response) below for more information.
165
165
166
166
In the publishing app, you can use a validation message action to report a validation error. The client app can include a custom error handler on the [Send External Object](/refguide/send-external-object/) activity to handle the error. If the microflow reports [validation feedback](/refguide/validation-feedback/), the runtime informs the client that the request has failed. For more information, see [Supported OData Operations](/refguide/supported-odata-operations/#updating-objects).
167
167
168
168
### Deletable {#deletable}
169
169
170
170
Select the checkbox for **Deletable** to indicate that clients can delete the values of attributes and associations.
171
171
172
-
Choose whether the object should be deleted from the database directly, or whether to call a microflow. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/) parameter. In the microflow, you can use the [Delete](/refguide/deleting-objects/) activity to delete the object from the database.
172
+
Choose whether the object should be deleted from the database directly, or whether to call a microflow. Specify a microflow that takes the entity as a parameter, and optionally a [System.HttpRequest](/refguide/http-request-and-response-entities/)and/or a [System.HttpResponse](/refguide/http-request-and-response-entities/)parameter. In the microflow, you can use the [Delete](/refguide/deleting-objects/) activity to delete the object from the database. See [Customizing the Outgoing HTTP Response](#custom-http-response) below for more information.
173
173
174
174
You can use a validation message to report a validation error if you are performing, for example, a soft delete. If the microflow reports [validation feedback](/refguide/validation-feedback/), the runtime informs the client that the request has failed.
175
175
@@ -202,3 +202,15 @@ Setting **Use paging** to **Yes** may result in inconsistency in the retrieved d
202
202
When **Use paging** is set to **Yes**, the number of objects per page can be set in **Page size**.
203
203
204
204
Default: **10000**
205
+
206
+
## 8 Customizing the Outgoing HTTP Response {#custom-http-response}
207
+
208
+
When using **Call a microflow** for any of these capabilities, the selected microflow can take a [System.HttpResponse](/refguide/http-request-and-response-entities/) parameter.
209
+
210
+
You can use this parameter to affect the HTTP response:
211
+
212
+
* The microflow can create headers associated to the HttpResponse parameter. These headers will be added to the response, overwriting headers with the same key if those would otherwise have been created.
213
+
* The microflow can change the status code and/or Content attributes of the HttpResponse parameter to ignore the default behavior and respond with that status code and Content instead.
214
+
* Changing the ReasonPhrase attribute has no effect.
215
+
* It is not possible to change values for `Transfer-Encoding` and `Date` headers.
216
+
* When the status code is set to `204`, an empty response body is always produced.
Copy file name to clipboardExpand all lines: content/en/docs/refguide/modeling/integration/odata-services/published-odata-services/published-odata-microflow.md
+11Lines changed: 11 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,3 +73,14 @@ You can also select **Can be empty**. If this checkbox is cleared, calls to the
73
73
{{% alert color="info" %}}
74
74
Boolean and list parameters can never be empty.
75
75
{{% /alert %}}
76
+
77
+
## 4 Customizing the Outgoing HTTP Response
78
+
79
+
It is possible to manipulate the response, which is produced as a result of an OData Action call. To do this, the published microflow must have a parameter with a [System.HttpResponse](/refguide/http-request-and-response-entities/) type.
80
+
81
+
* If no changes were made to HttpResponse object, the actual response will not change.
82
+
* If only headers of the HttpResponse were changed (for instance, a new header was added to the response), those headers are merged with default headers, which replaces values of the same name.
83
+
* If the status code or content of the HttpResponse is changed, the actual response is produced exclusively from the HttpResponse parameter, including status code, headers, and response body.
84
+
* The ReasonPhrase field is ignored.
85
+
* It is not possible to change values for `Transfer-Encoding` and `Date` headers.
86
+
* When the status code is set to `204`, an empty response body is always produced.
0 commit comments