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: docs/metadata.md
+3-2
Original file line number
Diff line number
Diff line change
@@ -25,7 +25,7 @@ This directory contains XML files with metadata required to create a valid reque
25
25
A metadata file contains a list of operations with different types (defined in `type`).
26
26
Each [operation] includes:
27
27
28
-
- The set of adjustments for processing a request in [attributes][operation], and in some cases, a response (see `successRegex`and `returnRegex` in [reference details][operation]).
28
+
- The set of adjustments for processing a request in [attributes][operation], and in some cases, a response (see `successRegex`, `returnRegex`and `returnIndex` in [reference details][operation]).
29
29
- The type of body content encoding in [contentType].
30
30
- The body of the request represented as a tree of objects, arrays, and fields.
31
31
@@ -336,7 +336,7 @@ There are two different attributes to split access to different areas:
336
336
-`auth="adminFormKey"` is used for objects in an Admin area.
337
337
-`auth="customerFormKey"` is used for objects in a storefront.
338
338
339
-
You are able to create assurances with `successRegex`, and even return values with `returnRegex`.
339
+
You are able to create assurances with `successRegex`, and even optionally return values with `returnRegex`. You can also use `returnIndex` when `returnRegex` matches multiple values.
340
340
341
341
### Create an object in Admin {#create-object-as-adminFormKey}
342
342
@@ -418,6 +418,7 @@ Root element that points to the corresponding XML Schema.
418
418
|`method`| string | optional | HTTP method of the operation. Possible values: `POST`, `DELETE`, `PUT`, `GET`. |
419
419
|`successRegex`| string | optional | Determines if the operation was successful. Parses the HTML body in response and asserts if the value assigned to the `successRegex` exists. |
420
420
|`returnRegex`| string | optional | Determines if the response contains the matching value to return. |
421
+
|`returnIndex`| string | optional | Specifies index at which the value will be returned when `returnRegex` matches multiple values |
421
422
|`removeBackend`| boolean | optional | Removes backend name from requested URL. Applicable when `auth="adminFormKey"`. |
0 commit comments