This example shows how to automate the Peachstate Medicaid insurance lookup and extract the resulting data. You will learn how to use aDocumentation Index
Fetch the complete documentation index at: https://docs.optexity.com/llms.txt
Use this file to discover all available pages before exploring further.
ForLoopNode to iterate over multiple links to extract data.
You can use this pattern to extract data from multiple pages of a website.
The automation:
- Opens the Peachstate Medicaid insurance site
- Fills the insurance details (plan type, member id, dob)
- Clicks on the authorization links to extract data
- Extracts the data from the authorization links
Part 1: Record the base workflow
-
Go to the Peachstate Medicaid insurance site and record a workflow that:
- Navigates to the login page
- Fills in username, password
- Clicks on the login button
- Navigates to the authorization page
- Clicks on the authorization links to extract data
-
After saving, you will see a
peachstate_medicaid_insuranceautomation in your dashboard that contains only the interaction actions (clicks, fills, selects). We have also built this automation by default, and you can find it in your dashboard.

Part 2: Refine the automation
Recording captures clicks and inputs, but you still need to:- Tighten some interaction instructions
- Add a
ForLoopNodeto iterate over multiple links to extract data - Add an
ExtractionActionto extract the data from the authorization links
2.1. ForLoopNode to iterate over multiple links to extract data
In the recorded flow, the authorization page might have multiple links for extracting data. You can use aForLoopNode to iterate over multiple links to extract data. However, in the recorded automation, we only capture one link to extract data, so we need to add a ForLoopNode to iterate over multiple links.
Each ForLoopNode contains a list of nodes. In our case, we will click on the authorization link, extract the data from the authorization link, and go back to the authorization page.
We will repeat this for each authorization link. The variable name is the variable on which to iterate. In our case, it is authorization_numbers.
To automatically build the list of authorization numbers, we can use the LLM extraction action to extract the data from the authorization page. We will use the output_variable_names to store the extracted data in the generated_parameters.
optexity/examples/peachstate_medicaid.py. You can also use the optexity dashboard to edit the automation and save it as a new automation.
Part 3: Run the peachstate_medicaid_insurance automation via inference
For a detailed explanation of the inference server, see the Quickstart guide. Below is the minimal flow to run this example.
3.1. Start the inference server
From the project root:3.2. Invoke the peachstate_medicaid_insurance endpoint
You can call the peachstate_medicaid_insurance automation via the /inference endpoint:
- Inspect the task run and extracted data in the dashboard
- Re‑use the extracted JSON in downstream systems