# Create quote via API wit a custom template

**URL:** <https://community.hubspot.com/t/create-quote-via-api-wit-a-custom-template/108601>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [June 4, 2024, 1:18pm UTC](https://community.hubspot.com/t/create-quote-via-api-wit-a-custom-template/108601 "2024-06-04T13:18:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Niels2](https://avatars.discourse-cdn.com/v4/letter/n/90ced4/32.png) [@Niels2](https://community.hubspot.com/u/Niels2)\
**Post date:** [June 4, 2024, 1:18pm UTC](https://community.hubspot.com/t/create-quote-via-api-wit-a-custom-template/108601/1 "2024-06-04T13:18:20Z")

</div>

Try to create a Quote throught the API.

If I use a ‘default’ template in the payload like:

{“hs\_template”:“ORIGINAL”}

it works.

But I don’t know how to use a “customized quote template”.

What property to use and what value?

I already retrieved all quote properties:

…

‘name’: ‘hs\_template’,  
‘options’: [{‘description’: ‘Legacy: Original quote template’,  
‘display\_order’: 1,  
‘hidden’: False,  
‘label’: ‘Template 1 - Original’,  
‘value’: ‘ORIGINAL’},  
{‘description’: ‘Legacy: Basic quote template’,  
‘display\_order’: 2,  
‘hidden’: False,  
‘label’: ‘Template 2 - Basic’,  
‘value’: ‘BASIC’},  
{‘description’: ‘Legacy: Modern quote template’,  
‘display\_order’: 3,  
‘hidden’: False,  
‘label’: ‘Template 3 - Modern’,  
‘value’: ‘MODERN’}],

‘name’: ‘hs\_template\_type’,  
‘options’: [{‘description’: ‘Uses customizable quote template’,  
‘display\_order’: 0,  
‘hidden’: False,  
‘label’: ‘CUSTOMIZABLE\_QUOTE\_TEMPLATE’,  
‘value’: ‘CUSTOMIZABLE\_QUOTE\_TEMPLATE’},  
{‘description’: ‘Uses proposal cms template’,  
‘display\_order’: 1,  
‘hidden’: False,  
‘label’: ‘PROPOSAL’,  
‘value’: ‘PROPOSAL’},  
{‘description’: ‘Uses quotes template’,  
‘display\_order’: 2,  
‘hidden’: False,  
‘label’: ‘QUOTE’,  
‘value’: ‘QUOTE’}],

…

I can’t find a property/value for my custom template.

---

<div class="post-metadata">

**Author:** ![GRajput](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/grajput/32/102020_2.png) [@GRajput](https://community.hubspot.com/u/GRajput)\
**Post date:** [June 5, 2024, 9:24am UTC](https://community.hubspot.com/t/create-quote-via-api-wit-a-custom-template/108601/2 "2024-06-05T09:24:58Z")

</div>

I think you are creating a quote with a customized quote template. If you are not able to use a customized quote template then please try with the association attribute for this. you have to associate the quote template with it. The syntax is given below.

```lia-code-sample
curl --request POST \
 --url https://api.hubapi.com/crm/v3/objects/quotes \
 --header 'authorization: Bearer YOUR_ACCESS_TOKEN' \
 --header 'content-type: application/json' \
 --data '{
 "associations": [
 {
 "types": [
 {
 "associationCategory": "HUBSPOT_DEFINED",
 "associationTypeId": 286
 }
 ],
 "to": {
 "id": "Enter quote_template_id"
 }
 }
 ],
 "properties": {
 "additionalProp1": "string",
 "additionalProp2": "string",
 "additionalProp3": "string"
 }
}'

```

“I hope this will help you out. Please mark it as **Solution Accepted and upvote** to help another Community member.  
Thanks!”

---

<div class="post-metadata">

**Author:** ![Niels2](https://avatars.discourse-cdn.com/v4/letter/n/90ced4/32.png) [@Niels2](https://community.hubspot.com/u/Niels2)\
**Post date:** [June 5, 2024, 12:30pm UTC](https://community.hubspot.com/t/create-quote-via-api-wit-a-custom-template/108601/3 "2024-06-05T12:30:41Z")

</div>

Yes, that is the way to go. Thanks.
