--- title: "Argument feature" slug: "argument-feature" updated: 2026-02-24T06:28:07Z published: 2026-02-24T06:28:07Z canonical: "helpcenter.autify.com/argument-feature" --- > ## Documentation Index > Fetch the complete documentation index at: https://helpcenter.autify.com/llms.txt > Use this file to discover all available pages before exploring further. # Argument feature You can use the **Argument feature** in JavaScript steps, Playwright code steps, and Natural Language steps. By using this feature, you can pass any value—such as data values, results from other steps, or workspace variables, etc.—to JavaScript steps, Playwright code steps, and Natural Language steps to create flexible and dynamic scenarios. ## Instructions ### 1. Define arguments When adding or editing a JavaScript step, Playwright code step, or Natural Language step, configure the **Arguments** in the **Arguments** section of the dialog. 1. Click **+** in the **Arguments** section of the step edit screen. 2. Enter an arbitrary argument name in **Argument name**. 3. Click **Add** to add the argument to the list. ![](https://cdn.document360.io/c040854c-2c75-49d0-98e1-43f462e8657e/Images/Documentation/スクリーンショット 2026-02-17 15.40.02(1).png?sv=2026-02-06&spr=https&st=2026-11-08T16%3A45%3A31Z&se=2026-11-08T17%3A45%3A31Z&sr=c&sp=r&sig=5d1k5Id9uruQzV8kVkO3wnYUDC9pXnzVrkt6pnU9bWY%3D) ### 2. Set argument values Select an input source from the dropdown and set the value you want to pass to the added **Argument**. ![](https://cdn.document360.io/c040854c-2c75-49d0-98e1-43f462e8657e/Images/Documentation/スクリーンショット 2026-02-17 16.35.36.png?sv=2026-02-06&spr=https&st=2026-11-08T16%3A45%3A31Z&se=2026-11-08T17%3A45%3A31Z&sr=c&sp=r&sig=5d1k5Id9uruQzV8kVkO3wnYUDC9pXnzVrkt6pnU9bWY%3D) ### 3. Use arguments in code/Natural Language steps The configured **Arguments** can be used directly as variables within the code editor. ### For JavaScript steps You can use the argument name as a variable directly in the JavaScript code. Example: If you defined the argument `username` ```javascript // Enter the value of the argument username into the element with ID 'login' document.querySelector('#login').value = username; ``` ### For Playwright code steps You can use the argument name as a variable directly in the Playwright code. Example: If you defined the argument `targetUrl` ```typescript // Navigate to the URL of the argument targetUrl await page.goto(targetUrl); ``` ### For Natural Language steps You can use the argument name directly in the prompt of the Natural Language step. Example: If you defined the arguments `loginuser` and `loginpassword` ```plaintext Input loginuser in the username field and loginpassword in the password field, then click the login button to log in. ``` > [!NOTE] > **Note** > > Natural Language steps with arguments cannot be converted to no-code steps. ## Use cases ### Using Data values This is effective when you want to test using different input data (such as email addresses or passwords) with the same operation steps. 1. Prepare data (e.g., `email`, `password` columns) in the scenario. 2. Define arguments `email` and `password` in the code step or Natural Language step. 3. Set the input source of each argument to **Data** and select the corresponding column. 4. Use these **Arguments** in the code/prompt to perform form inputs, etc. ### Using results from other steps This is used when you want to use a dynamic value generated in a previous step (such as a member ID or order number) in a subsequent code step. 1. Place a step that generates or retrieves a dynamic value (e.g., "Generate random value" step). 2. Define an argument (e.g., `orderId`) in the subsequent code step. 3. Set the input source of the argument to **Other step's output** and select the target step. 4. Use `orderId` in the code/prompt to perform verification or operations. ## Notes - **Data types** All arguments are passed to the code as **Strings**. If you want to use them for calculations as numbers, please convert them to a number type using `Number(argumentName)` or `parseInt(argumentName)` in the code.