# Customised Email subject line

**URL:** <https://community.hubspot.com/t/customised-email-subject-line/19204>\
**Category:** APIs & Integrations\
**Tags:** email\
**Created:** [March 4, 2020, 2:15pm UTC](https://community.hubspot.com/t/customised-email-subject-line/19204 "2020-03-04T14:15:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![unnati](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/unnati/32/29892_2.png) [@unnati](https://community.hubspot.com/u/unnati)\
**Post date:** [March 4, 2020, 2:15pm UTC](https://community.hubspot.com/t/customised-email-subject-line/19204/1 "2020-03-04T14:15:30Z")

</div>

I’m using a transactional email (Save for single-send API). Here I want to set a subject line with custom values.  
for example, subject line is: Hello {{ personalization\_token(“contact.firstname”, “”) }}, Would you like to join our group {{group\_name}} ?

this group\_name is dynamic value and is coming from API call request body. Is there any provision to set this type of dynamic values?

Any help will be appreciated.

---

<div class="post-metadata">

**Author:** ![IsaacTakushi](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/isaactakushi/32/70387_2.png) [@IsaacTakushi](https://community.hubspot.com/u/IsaacTakushi)\
**Post date:** [March 10, 2020, 7:25pm UTC](https://community.hubspot.com/t/customised-email-subject-line/19204/2 "2020-03-10T19:25:59Z")

</div>

Welcome, @unnati.

Yes, it’s the same convention outlined [here](https://developers.hubspot.com/docs/methods/email/transactional_email/single-send-overview) for custom properties in the body of single-send emails.

In your case, your subject line would be:

`Hello {{contact.firstname}}, Would you like to join our group {{custom.group_name}}?`

`contact.firstname` would populate with “John” and `custom.group_name` with “Cool Group” if you sent the following request to the Single-send API:

```auto
POST
https://api.hubapi.com/email/public/v1/singleEmail/send

{
 "emailId": 123456789,
 "message": {
 "to": "example@hubspot.com"
 },
 "contactProperties": [
 {
 "name": "firstname",
 "value": "John"
 }
 ],
 "customProperties": [
 {
 "name": "group_name",
 "value": "Cool Group"
 }
 ]
}

```
