Flow Automation: Finding Custom Pages via Action
You can use the Find pages action in Flow Automation to find custom pages in your store, such as an "About Us" page or campaign landing pages, based on specified conditions, including publish status, page title, creation time, update time, and publish time. The query results can then be passed to subsequent steps in your workflow for further processing.
With this action, you can automatically identify campaign pages after a marketing campaign ends or regularly find pages that haven't been updated for an extended period. This helps you promptly clean up outdated content, reduce manual effort, and manage your custom pages more efficiently.
This guide explains when to use this action, how to configure its fields, applicable workflows, testing procedures, and usage limitations. It also provides a practical workflow example.
| Note: This action only retrieves custom page information without modifying or deleting pages. To automatically delete custom pages, refer to "Flow Automation: Deleting Custom Pages via Action." |
When to Use the Find Pages Action
Use the Find pages action in the following scenarios:
- Reviewing campaign pages: Automatically find landing pages created during a marketing campaign after it ends, allowing your team to promptly review, unpublish, or delete them.
- Identifying inactive pages: Regularly find unpublished pages that haven't been updated for an extended period and determine whether they should be retained.
Field Descriptions
The Find pages action retrieves custom pages that match your specified conditions. You can also configure pagination and sorting settings to control how the query results are returned.
Each field is identified by the field name displayed below its description in the action configuration panel. Refer to the following table for detailed field descriptions:
| Field | Description |
| created_at_max (Optional) | Returns pages created on or before the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| created_at_min (Optional) | Returns pages created on or after the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| handle (Optional) | Finds a specific page by its URL handle. For example, if the page path is /pages/about-us, enter about-us. |
| page_num | Specifies the page number of the query results to return. Enter 1 to retrieve the first page of results. If the results span multiple pages, enter 2, 3, and so on to retrieve subsequent pages. |
| page_size | Specifies the maximum number of custom pages returned per page of results. Supported range: 1–250. Default: 50. |
| published_at_max (Optional) | Returns pages published on or before the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| published_at_min (Optional) | Returns pages published on or after the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| published_status (Optional) | Filters pages by publish status. Supported values: any (all pages, default), published (published pages), and unpublished (unpublished pages). |
| search_by_source (Optional) | Specifies whether to retrieve only pages created through an app. Enter 1 to retrieve only app-created pages, such as those created using the Smart Landing Page app. Enter 0 (default) to retrieve pages regardless of their creation source. |
| since_id (Optional) | Specifies the custom page ID from which to start the query. This is useful for retrieving large numbers of custom pages in batches. |
| sort_field (Optional) | Specifies the field by which query results are sorted. The only supported value is 1, which sorts pages by update time. If left blank, results are sorted by page ID. |
| sort_type (Optional) | Specifies the sort direction. Enter 0 (default) for ascending order or 1 for descending order. For example, when sorting by update time, ascending order returns the least recently updated pages first, while descending order returns the most recently updated pages first. |
| title (Optional) | Finds custom pages by page title. Maximum length: 255 characters. |
| updated_at_max (Optional) | Returns pages updated on or before the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| updated_at_min (Optional) | Returns pages updated on or after the specified time. Format: yyyy-MM-dd HH:mm:ss.SSS (for example, 2026-12-01 00:00:00.000). |
| Note: In subsequent workflow steps, click + Add variable to reference information about the retrieved pages, including [page title], [author], [page url], [publish status], [created at], [updated at], [published at], and [template used]. |
Applicable Workflows
The Find pages action is primarily used in workflows initiated by the following trigger:
- [General] Scheduled time
| Note: For detailed instructions on configuring the Scheduled time trigger, refer to "Flow Automation: Scheduled Trigger." |
Testing the Workflow
To verify that the workflow successfully retrieves custom pages matching the specified conditions, follow these steps:
-
From your SHOPLINE Admin, go to Online Store > Page. Click Create a page to create a custom page for testing and note its title.
- In Flow Automation, create a workflow using the Scheduled time trigger and the Find pages action. Configure the following settings:
-
Scheduled time:
- First trigger time: Set to a few minutes from now.
- Repeat or not: Select Not repeating.
-
Find pages:
- page_num: 1
- page_size: 10
- created_at_min: Enter today's date with the time 00:00:00.000 to retrieve only pages created from the beginning of today onward.
- title: Enter the title of the test page to narrow the query results.
-
Scheduled time:
- After the Find pages action, add a Send email action. Set the recipient email address to your own and insert the page title variable into the email content to verify the query results.
- Once the workflow is configured, click Publish.
-
After the scheduled trigger time, return to Flow Automation to check the workflow execution results.
Note: For detailed instructions on checking workflow execution results, refer to the "How to View the Running of a Flow" section in the "Introduction to Flow Automation" guide. - Confirm that the received email contains the test page's title. Then, go to Online Store > Page to verify that the test page remains unchanged.
Example Use Case
The following example demonstrates how to use the Find pages action to automatically identify campaign landing pages after a marketing campaign ends and notify your team to review them.
Scenario: Your team created several campaign landing pages in December for your year-end sale. The sale ends at 10:00 PM on December 31, 2026. You want the workflow to automatically find pages created during the campaign and send your operations team a reminder email for each page, so they can determine whether to unpublish or delete it. This helps prevent customers from accessing outdated campaign content through existing links.
Configure the workflow as follows:
-
Trigger: Scheduled time
- First trigger time: 2026-12-31 22:00:00 (the end time of the year-end sale)
- Repeat or not: Select Not repeating
-
Action: Find pages
- created_at_max: 2026-12-31 22:00:00.000
- created_at_min: 2026-12-01 00:00:00.000
- page_num: 1
- page_size: 50
-
Action: Send email
- Subject: Year-End Sale Page Requires Review: [Page title]
- Content: The year-end sale has ended. The page "[Page title]" ([Page URL]) was created during the campaign period. Go to Online Store > Page in your SHOPLINE Admin to determine whether the page should be unpublished or deleted.
- Recipient: Your operations team's email address.
Result: When the year-end sale ends, the workflow automatically retrieves custom pages created within the specified time range, up to the configured result limit, and sends your operations team a reminder email for each retrieved page. Your team can use the page information in each email to promptly review and manage outdated campaign content without manually searching for pages.
|
Notes:
|
Usage Limits and Notes
When using the Find pages action, keep the following rules and limitations in mind:
- Pagination limits: Each query returns only the results for the specified page number, with a maximum of 250 custom pages per page of results (default: 50). If the results span multiple pages, narrow the query conditions or adjust page_num across multiple workflow executions to retrieve the remaining results.
- Read-only operation: This action only retrieves custom page information without modifying or deleting pages. To perform additional operations on the retrieved pages, add the corresponding actions to your workflow.
- Empty results: If no pages match the specified conditions, the action returns an empty result. Any subsequent action that uses the query results will have no pages to process.