Get Tag Value
This is pre-built Action located under the @Generic Element Name. It instructs the Avo Assure Client to fetch the tag value from the input and save the result in the given output variable.
Syntax
Input: <XML block/ XML tags>; <number>; <block name>; <tag name>
Output: <Dynamic Variable>;<Dynamic Variable>(Optional)

Usecase/Example

Scenario: Fetching Tag Values from User Input in XML API Testing
You are testing a financial services API that returns transaction history in XML format. Your goal is to dynamically fetch specific tag values based on user input, allowing for flexible and targeted testing.
Consider that you want to retrieve the transaction amount based on a transaction ID provided by the user.
Input
User Input: Transaction ID (e.g., TXN12345)
// xml
<transactions>
<transaction>
<date>2024-10-01</date>
<amount>100.00</amount>
<transactionId>TXN12345</transactionId>
</transaction>
<transaction>
<date>2024-09-30</date>
<amount>150.00</amount>
<transactionId>TXN12344</transactionId>
</transaction>
<transaction>
<date>2024-02-18</date>
<amount>1200.00</amount>
<transactionId>TXN76543</transactionId>
</transaction>
<transaction>
<date>2024-03-01</date>
<amount>1080.00</amount>
<transactionId>TXN67890</transactionId>
</transaction>
</transactions>
Using the Action:
To fetch the specific tag value, you will use the Get Tag Value Action based on the user input.
Expected Result
This Action needs to retrieve the tag name of the desired value whose block name and value has been given in Input Value.
Output
The result is stored in the {result} output variable as TXN12345, which can be utilized for display or other purposes.
Last updated
Was this helpful?