# Help with programmable email and crm\_object

**URL:** <https://community.hubspot.com/t/help-with-programmable-email-and-crm-object/77695>\
**Category:** CMS Development\
**Tags:** email\
**Created:** [March 21, 2023, 11:17pm UTC](https://community.hubspot.com/t/help-with-programmable-email-and-crm-object/77695 "2023-03-21T23:17:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![SStrachan1](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@SStrachan1](https://community.hubspot.com/u/SStrachan1)\
**Post date:** [March 21, 2023, 11:17pm UTC](https://community.hubspot.com/t/help-with-programmable-email-and-crm-object/77695/1 "2023-03-21T23:17:34Z")

</div>

I am trying to pass the ID of an object with the transactional email API.

I cannot save my programmable email module because of this error:  
Missing required input parameters. Object id or query is mandatory for crm\_object function.  
My object ID will be “custom.yacht” passed via API. Why is this not valid? Should it be written another way?

```lia-code-sample
{% set yacht = crm_object("yacht", custom.yacht, "name,builder, year") %}
<h1>{{ yacht.name }}</h1>

```

---

<div class="post-metadata">

**Author:** ![RZhukov](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/rzhukov/32/198100_2.png) [@RZhukov](https://community.hubspot.com/u/RZhukov)\
**Post date:** [March 22, 2023, 7:52am UTC](https://community.hubspot.com/t/help-with-programmable-email-and-crm-object/77695/2 "2023-03-22T07:52:22Z")

</div>

I also need programmable mail and crm\_object for my site [Hire Dedicated CMS Developers in 2024](https://factordedicatedteams.com/hire-dedicated-cms-developers/). Can anyone help me?

---

<div class="post-metadata">

**Author:** ![SStrachan1](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@SStrachan1](https://community.hubspot.com/u/SStrachan1)\
**Post date:** [March 23, 2023, 11:28am UTC](https://community.hubspot.com/t/help-with-programmable-email-and-crm-object/77695/3 "2023-03-23T11:28:18Z")

</div>

I figured it out. You have to add the filter |int to custom.yacht  
from this:

```lia-code-sample
{% set yacht = crm_object("yacht", custom.yacht, "name,builder, year") %}
<h1>{{ yacht.name }}</h1>

```

to this…

```lia-code-sample
{% set yacht = crm_object("yacht", custom.yacht|int, "name,builder, year") %}
<h1>{{ yacht.name }}</h1>

```

since custom.yacht is a string you have to filter it as a number.
