# Custom domain name variable in workflows

**URL:** <https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302>\
**Category:** Ask us anything\
**Created:** [November 8, 2023, 5:22pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302 "2023-11-08T17:22:18Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![felix](https://avatars.discourse-cdn.com/v4/letter/f/aeb1de/32.png) [@felix](https://community.weweb.io/u/felix)\
**Post date:** [November 8, 2023, 5:22pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/1 "2023-11-08T17:22:18Z")

</div>

I was checking the context variables in workflows, and I can’t find the custom domain name.  
Is this missing?

Context: saving the URL of collection items in back-end for sending emails based on back-end triggers.

Thanks!

---

<div class="post-metadata">

**Author:** ![Joyce](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/joyce/32/13232_2.png) [@Joyce](https://community.weweb.io/u/Joyce)\
**Post date:** [November 9, 2023, 1:01pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/2 "2023-11-09T13:01:08Z")

</div>

Hi @felix 👋

I think what you’re looking for is the current page paths variables:

 ![CleanShot 2023-11-09 at 13.58.48@2x](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/8/8e6bd6103281f77903b8270e10add2dd093b0b45.jpeg)

In the example above, I’m on a collection page with the following URL configuration:

 ![CleanShot 2023-11-09 at 14.00.23@2x](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/9/949b4a08c270f61480183e0a60049b61ed049510.png)

Does that help?

---

<div class="post-metadata">

**Author:** ![felix](https://avatars.discourse-cdn.com/v4/letter/f/aeb1de/32.png) [@felix](https://community.weweb.io/u/felix)\
**Post date:** [November 9, 2023, 1:19pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/3 "2023-11-09T13:19:25Z")

</div>

Hi Joyce,

Thanks for your answer.  
The issue I have is when I test workflows, it writes the editor path in my backend database, leading to potential errors in the production env.  
Ideally, the path in the context variable should be the production path (with the custom domain).

Best,  
Felix

---

<div class="post-metadata">

**Author:** ![Joyce](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/joyce/32/13232_2.png) [@Joyce](https://community.weweb.io/u/Joyce)\
**Post date:** [November 9, 2023, 2:11pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/4 "2023-11-09T14:11:42Z")

</div>

Like this?

 ![CleanShot 2023-11-09 at 15.07.24@2x](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/9/95009b9fdb1efdb8a83b9cf42f95db770eaee363.jpeg)

Or maybe like this?

 ![CleanShot 2023-11-09 at 15.11.14@2x](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/6/6e13fa6f1492c07b56cdebe87ddf493332d3efed.jpeg)

---

<div class="post-metadata">

**Author:** ![Joyce](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/joyce/32/13232_2.png) [@Joyce](https://community.weweb.io/u/Joyce)\
**Post date:** [November 9, 2023, 2:17pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/5 "2023-11-09T14:17:05Z")

</div>

Here’s a video that I think might help: [Video for Felix — Tella](https://tella.video/video-for-felix-c9qq)

Let me know if not

---

<div class="post-metadata">

**Author:** ![felix](https://avatars.discourse-cdn.com/v4/letter/f/aeb1de/32.png) [@felix](https://community.weweb.io/u/felix)\
**Post date:** [November 9, 2023, 3:50pm UTC](https://community.weweb.io/t/custom-domain-name-variable-in-workflows/5302/6 "2023-11-09T15:50:57Z")

</div>

I’m incredibly grateful you’ve done this video for me!

Yes, that could work, but:

- I like abstractions, and I may change the domain name any time (forgetting about this)
- I have a dynamic collection, so the URL is build from data in the back-end, I would have to rebuild the parameters here (they say DRY).

It works fine in production so there’s nothing problematic here, I was just trying to optimize.

Thanks again!
