Dashboard

Convert to Workflow

After an AI agent completes a task, you can convert the successful run into a reusable workflow. The workflow replays the same steps without needing the AI model - making it faster and cheaper.

How It Works

  1. The AI agent records every action it takes during a session
  2. When the session completes, you can convert it to a workflow
  3. The conversion creates workflow nodes for each navigation, click, type, wait, and extraction step
  4. Self-healing: if the agent retried an extraction, the final successful version is used
  5. The workflow can then be scheduled and run repeatedly

Via the Dashboard

  1. Run an AI agent session and wait for completion
  2. Click Convert to Workflow on the results page
  3. Review and optionally edit the generated workflow
  4. Save and schedule if needed

Via the API

POST https://api.scrayle.com/api/v1/ai/agent/{jobId}/convert

Headers:
  x-api-key: YOUR_API_KEY

Response:
{
  "workflowId": "wf_abc123",
  "name": "Converted from AI Agent - job_xyz",
  "nodeCount": 8
}

What Gets Converted

The conversion translates AI agent actions into workflow nodes:

Agent ActionWorkflow Node
Navigate to URLnavigate_to_url
Click elementclick_element
Type texttype_text
Wait for elementwait_for_element
Extract dataextract_data
Execute codeexecute_code
Scroll pagescroll_page
💡Self-Healing

If the AI agent retried an extraction (e.g., because a selector failed on the first attempt), the conversion uses the final successful extraction, not the initial broken one.

Benefits