I'm trying to route the chat flow to different tasks based on the origin of the chat webpage. For instance, I have a home page and x, y and z pages within that and all of them have chat present. How can I possibly route the chat flow actions from the home page further to the flow based on the x or y or z pages that chat is started from?
Looking at the builtin-variables that are available in Architect (Architect builtin variables) it looks like there is nothing available to perform the type of action you require.
If you are asking the question for WebChat v2 and if you are using the Genesys Widgets UI on guest side, you can extract "context._genesys_url" from your Architect flow with a Get Participant Data block.
Genesys Widgets automatically attaches a set of data to the conversation when it starts, which are available as participant data/attributes. See here for the Genesys Widgets built-in attributes.
You can then leverage this to segment your Architect flow and target different tasks.