Aller au contenu principal

Data Transfer Step

The Data Transfer step extracts values from a test step's request or response into variables, so they can be reused in subsequent test steps. Each rule reads a property from a chosen source step, optionally applies an XPath/JSONPath expression, and stores the result in a variable.

When to Use​

  • Capturing an id, token, or header from a response to feed the next request
  • Extracting request or response text for later assertions
  • Building a chain of dependent requests (e.g. create → read → update)
  • Sharing extracted values across the test case, suite, or project scope

Quickest Scenario​

  1. Add a Data Transfer step after the step whose data you want to capture.
  2. In Select source step, choose the Test Suite, Test Case, and Test Step that produced the data.
  3. Click Add Rule, then Edit the new rule: pick the Property Name, set the Path Type and Path (if needed), and enter the Variable Name.
  4. Click Evaluate to preview the extracted value, then Save.
  5. Choose the Variable Level (where the variable is stored) and run the test.

Configuration​

Source Selection​

FieldDescription
Test SuiteThe suite containing the source step.
Test CaseThe test case containing the source step.
Test StepThe exact step to read data from.

Variable Level​

Determines the lifetime/scope of the stored variable:

ValueScope
TestCaseAvailable within the current test case only.
TestSuiteAvailable across the test suite (not other suites).
ProjectAvailable within the current automation project.

:::note Runtime variables are per run Values written by a transfer (or by any extraction) are runtime values: they live for the run and are never saved into the project file. Each level is cleared when a run of that level starts — a project run starts with empty project-scope runtime variables, a suite run starts with empty suite-scope ones, and a case run clears its own case and step values. This is what makes a run's result depend only on the run itself: a passing step cannot be reading a value left behind by the previous run.

Two consequences worth knowing:

  • Re-running a single case (not its suite) keeps suite-level values between runs on purpose, so a case can consume a value an earlier case run produced — for example running Login once by hand and Use Token several times after it.
  • To carry a value across runs, author it as a normal (persisted) variable in the Parameters tab instead of relying on an extraction from a previous run. :::

Transfer Rules​

Each rule (DataTransferRule) has:

FieldDescription
PropertyThe source property of the selected step (e.g. ResponseText, RequestText, or another property).
Path TypeHow to read the value: PropertyValue (read directly), XPath (XML query), or JsonPath (JSON query).
PathThe XPath or JSONPath expression. Required only when Path Type is XPath or JsonPath. Supports variabilization (e.g. ${jsonPathExpression}).
Variable NameThe variable to create or update. Created automatically if it does not exist.
DataRead-only preview of the last transferred value (or the Error Message if evaluation failed).
remarque

XPath and JsonPath are only meaningful when the selected property is the step's request or response text. For other properties, use PropertyValue to read the value directly (numeric/date values are emitted in culture-invariant format).

:::note Dates and numbers you type are read ISO-first When a rule or a request field receives a date or a number as text, the engine reads it as ISO 8601 first (2026-10-03, 2026-10-03T10:30:00) — the same value on every machine, because that is the format the wire and the storage use. If the text is not ISO, your system's regional format gets one turn (31/12/2026 on a French system is 31 December). If neither reading works, the step fails and names both conventions it tried, so you can see exactly what was rejected. Tip: 10/03/2026 is ambiguous between regions — prefer the ISO form in anything a project shares across machines. :::

Editing a Rule​

The Add/Edit Data Transfer Rule window provides:

  • A Property Name combo (available properties of the source step)
  • A Path Type combo (PropertyValue / XPath / JsonPath)
  • A Path text box (with placeholder "Enter path...")
  • A Variable Name text box
  • An Evaluate button that computes the Transferred Data and any Error Message
  • A live Property Value preview with context-menu actions to copy/show XPath and JSONPath

With Path Type set to PropertyValue, the Path box takes an Object Path — the same addressing the object tree uses, including a collection item by position (Body.photos[0]) or by its tag (Body.bags[type:checked].weightKg). See Object Paths.

Examples​

Extract a JSON Field from a Response​

After a Send Request step returns:

{
"data": {
"id": "usr_abc123",
"token": "eyJ...",
"profile": { "role": "admin" }
}
}
PropertyPath TypePathVariable Name
ResponseTextJsonPath$.data.idUserId
ResponseTextJsonPath$.data.tokenAuthToken
ResponseTextJsonPath$.data.profile.roleUserRole

Extract an XML Value​

PropertyPath TypePathVariable Name
ResponseTextXPath//UserId/text()UserId

Read a Property Directly​

PropertyPath TypePathVariable Name
StatusCodePropertyValue(empty)LastStatusCode

Why​

Data Transfer turns a response into reusable state, enabling realistic multi-step API flows without custom scripts for simple extraction.

See Also​