# Create quote with status "approval\_not\_needed"

**URL:** <https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524>\
**Category:** APIs & Integrations\
**Tags:** object\
**Created:** [January 10, 2024, 4:15pm UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524 "2024-01-10T16:15:37Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![enrico\_baskey](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/enrico_baskey/32/98852_2.png) [@enrico\_baskey](https://community.hubspot.com/u/enrico_baskey)\
**Post date:** [January 10, 2024, 4:15pm UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/1 "2024-01-10T16:15:37Z")

</div>

Hello,  
i’m trying to create an approved quote via the API.  
I have associated a deal, line-item and quote template but i always get a `there was a problem with your request` error. I can’t do much with this error message.  
This is my request (i removed all the id’s but they are fine in my code)

`{ "properties": { "hs_status": "APPROVAL_NOT_NEEDED", "hs_sender_firstname": "myName", "hs_sender_email": "my@mail.com", "hs_comments": "Comments for dealName 1", "hs_terms": "terms for dealName 1", "hs_currency": "EUR", "hs_expiration_date": "2024-04-08", "hs_title": "Quote With Template 1", "hs_domain": {{myQuoteDomain}}, "hs_template_type": "QUOTE" }, "associations": [{ "to": {"id": {{templateId}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 286}] }, { "to": {"id": {{dealID}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 64}] }, { "to": {"id": {{lineItemId}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 67}] } ]}`

What am i missing?  
I already tried different variations, with and without setting the domain and template type, owner, different date formats (with hours etc) … always the same error.

---

<div class="post-metadata">

**Author:** ![zach\_threadint](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/zach_threadint/32/46318_2.png) [@zach\_threadint](https://community.hubspot.com/u/zach_threadint)\
**Post date:** [January 11, 2024, 2:17am UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/2 "2024-01-11T02:17:22Z")

</div>

Hi [@enrico\_baskey](https://community.hubspot.com/t5/user/viewprofilepage/user-id/526222) 👋

Certainly sounds like a strange one. I can’t find any clear issues with your request body. Could you also please share additional information relating to your request? For example:

- Endpoint / URL
- Query string parameters (if relevant)
- Request method
- Headers

That additional context might help us get closer to the bottom of this.

Please let me know if you have any follow-up questions.

---

<div class="post-metadata">

**Author:** ![enrico\_baskey](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/enrico_baskey/32/98852_2.png) [@enrico\_baskey](https://community.hubspot.com/u/enrico_baskey)\
**Post date:** [January 14, 2024, 2:53pm UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/3 "2024-01-14T14:53:08Z")

</div>

Hi Zach,  
Thanks for your reply!  
First i sent a post request to

`POST https://api.hubspot.com/crm/v3/objects/line_items`

to create a line item to associate it with the quote.  
Then i also sent a post request to

`POST https://api.hubspot.com/crm/v3/objects/quote`

to create the quote with the given request body. I have the correct scopes in my token, because i can create it as draft, and also tried with a private app token with all available scopes.  
The headers for my create quote request are these:

`Content-Type: application/jsonAuthorization: Bearer {{allscopes}}`

I have no query strings.  
So the full request looks like this (intellij HTTP Client format):

`POST https://api.hubspot.com/crm/v3/objects/quoteContent-Type: application/jsonAuthorization: Bearer {{allscopes}}{ "properties": { "hs_status": "APPROVAL_NOT_NEEDED", "hs_sender_firstname": "myName", "hs_sender_email": "my@mail.com", "hs_comments": "Comments for dealName 1", "hs_terms": "terms for dealName 1", "hs_currency": "EUR", "hs_expiration_date": "2024-04-08", "hs_title": "Quote With Template 1", "hs_domain": {{myQuoteDomain}}, "hs_template_type": "QUOTE" }, "associations": [{ "to": {"id": {{templateId}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 286}] }, { "to": {"id": {{dealID}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 64}] }, { "to": {"id": {{lineItemId}}}, "types": [{"associationCategory": "HUBSPOT_DEFINED", "associationTypeId": 67}] } ]}`

---

<div class="post-metadata">

**Author:** ![zach\_threadint](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/zach_threadint/32/46318_2.png) [@zach\_threadint](https://community.hubspot.com/u/zach_threadint)\
**Post date:** [January 15, 2024, 12:00am UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/4 "2024-01-15T00:00:45Z")

</div>

Hi [@enrico\_baskey](https://community.hubspot.com/t5/user/viewprofilepage/user-id/526222) 👋

No problem at all, happy to help.

Can you please double check your “hs\_domain” property (in your Create Quote API call) and also confirm that you have a connected HubSpot Domain? This can be found in _HubSpot Settings \> Tools \> Website \> Domain & URLs_

The reason being is I was able to replicate your error response in a test HubSpot account that has no connected domains.

I hope this proves useful. Please let me know if you have any follow-up questions.

---

<div class="post-metadata">

**Author:** ![enrico\_baskey](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/enrico_baskey/32/98852_2.png) [@enrico\_baskey](https://community.hubspot.com/u/enrico_baskey)\
**Post date:** [January 15, 2024, 8:22am UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/5 "2024-01-15T08:22:26Z")

</div>

Hi Zach,  
Thats a good call!  
I have no connected domains.  
But i created and approved a quote with the HubSpot UI, and then copied the default domain which for me was \<PortalId\>.hs-sites-eu1.com/.  
I wonder why i can use this domain over the ui, but not via the API, do you think this is the issue? Could you replicate with this domain aswell?

> * * *

---

<div class="post-metadata">

**Author:** ![enrico\_baskey](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/enrico_baskey/32/98852_2.png) [@enrico\_baskey](https://community.hubspot.com/u/enrico_baskey)\
**Post date:** [January 15, 2024, 8:50am UTC](https://community.hubspot.com/t/create-quote-with-status-approval-not-needed/97524/6 "2024-01-15T08:50:50Z")

</div>

oh my god i found the issue.

First i used

`"hs_template_type": "QUOTE"`

Which was an issue because i needed to use: CUSTOMIZABLE\_QUOTE\_TEMPLATE.  
When using QUOTE, the hs-domain was always empty.  
Then my other issue was i used “EUR” as quote currency, but the line-item was in USD.  
Thanks for your time!
