Skip to main content

How do I make a PUT request to QBO using Zapier?

 

I am thrilled to see the custom App Extensions feature as part of Zapier.  However, I am trying to use it with Quickbooks and seem to have run into a problem.

 

I am simply trying to “SEND” an estimate.  Zapier has a good integration with QBO already, but is sadly missing this very important function.

 

When using the App Extensions for a GET request, everything works fine.  But when I try a PUT request it fails with error 405.  From the QBO developer docs it appears that an “Authorization” header is missing.  Below are the responses provided by Zapier for each request. 

 

{
"request": {
"method": "GET",
"url": "https://quickbooks.api.intuit.com/v3/company/<realmID>/estimate/669",
"querystring": {},
"headers": {},
"body": ""
},
"response": {
"status": 200,
"headers": {
"date": "Fri, 23 Jun 2023 21:21:00 GMT",
"content-type": "application/json;charset=utf-8",
"transfer-encoding": "chunked",
"connection": "keep-alive",
"intuit_tid": "<deleted>",
"x-spanid": "<deleted>",
"x-amzn-trace-id": "<deleted>",
"x-content-type-options": "nosniff",
"x-xss-protection": "1; mode=block",
"qbo-version": "2007.158",
"service-time": "total=80, db=23",
"expires": "0",
"content-encoding": "gzip",
"cache-control": "max-age=0, no-cache, no-store, must-revalidate, private",
"x-envoy-upstream-service-time": "109",
"strict-transport-security": "max-age=31536000",
"server": "envoy"
},
"data": {
"Estimate": {
"ExpirationDate": "2023-07-23",
"domain": "QBO",
"sparse": false,
....

However, when using a PUT request, I get a 405 error.

{
"request": {
"method": "PUT",
"url": "https://quickbooks.api.intuit.com/v3/company/<realmID>/estimate/669/send",
"querystring": {},
"headers": {},
"body": "{\n\"sparse\": true, \n\"EmailStatus\": \"NeedToSend\",\n}"
},
"response": {
"status": 400,
"headers": {
"date": "Fri, 23 Jun 2023 21:06:33 GMT",
"content-type": "application/json",
"content-length": "236",
"connection": "keep-alive",
"intuit_tid": "<deleted>",
"x-spanid": "<deleted>",
"x-amzn-trace-id": "<deleted>",
"x-content-type-options": "nosniff",
"x-envoy-upstream-service-time": "46",
"strict-transport-security": "max-age=31536000",
"server": "envoy"
},
"data": {
"Fault": {
"Error": >
{
"Message": "Unsupported Operation",
"Detail": "Operation No resource method found for PUT, return 405 with Allow header is not supported.",
"code": "500"
}
],
"type": "ValidationFault"
},
"time": "2023-06-23T14:06:33.695-07:00"
},
"body": "{\"Fault\":{\"Error\":a{\"Message\":\"Unsupported Operation\",\"Detail\":\"Operation No resource method found for PUT, return 405 with Allow header is not supported.\",\"code\":\"500\"}],\"type\":\"ValidationFault\"},\"time\":\"2023-06-23T14:06:33.695-07:00\"}"
}
}

 

Hi @sgalway 

Good question.

Feedback can be submitted here for App Extensions: https://app-extensions.zapier.app

Base on the error, it looks like an extra header (Allow) is being included.

 

Operation No resource method found for PUT, return 405 with Allow header is not supported.

Agreed.  However there is no way to control this.  I have sent a message to the address you gave.  Thanks for the help.


@sgalway

The workaround is to use this Zap action: QBO - API Request


@Troy Tessalone QBO - API Request fails in a similar fashion.  I ended up at App Extensions because I couldn’t get it to work with API Request.  With API Request GET actions work just fine, but PUT and POST fail as shown below.

 

GET request to https://quickbooks.api.intuit.com/v3/company/<RealmId>/estimate/713?minorversion=40

 

{
"request": {
"method": "GET",
"url": "https://quickbooks.api.intuit.com/v3/company/<RealId>/estimate/713",
"querystring": {},
"headers": {},
"body": null
},
"response": {
"status": 200,
"headers": {
"date": "Tue, 04 Jul 2023 15:00:14 GMT",
"content-type": "application/json;charset=utf-8",
"transfer-encoding": "chunked",
"connection": "keep-alive",
"x-spanid": <redacted>,
"x-amzn-trace-id": <redacted>,
"x-content-type-options": "nosniff",
"x-xss-protection": "1; mode=block",
"qbo-version": "2007.164",
"service-time": "total=85, db=36",
"expires": "0",
"content-encoding": "gzip",
"cache-control": "max-age=0, no-cache, no-store, must-revalidate, private",
"x-envoy-upstream-service-time": "500",
"strict-transport-security": "max-age=31536000",
"intuit_tid": <redacted>,
"x-request-id": <redacted>,
"server": "istio-envoy",
"x-envoy-decorator-operation": "usw2-prd-sb04-intuit-gateway-active-service.services-gateway-apigwsbg-usw2-prd-sb04.svc.cluster.local:7000/*"
},
"data": {
"Estimate": {
"ExpirationDate": "2023-08-02",
"domain": "QBO",
"sparse": false,
"Id": "713",
"SyncToken": "0",
"MetaData": {
"CreateTime": "2023-07-03T09:23:09-07:00",
"LastUpdatedTime": "2023-07-03T09:23:09-07:00"
},
"CustomField": F],
"DocNumber": "1180",
"TxnDate": "2023-07-03",
"CurrencyRef": {
"value": "USD",
"name": "United States Dollar"
},
"TxnStatus": "Pending",
"Line": "
{
"Id": "1",
"LineNum": 1,
.....
}
}

POST request sent to https://quickbooks.api.intuit.com/v3/company/<RealmId>/estimate

 

{
"request": {
"method": "POST",
"url": "https://quickbooks.api.intuit.com/v3/company/<RealmId>/estimate",
"querystring": {
"minorversion": "65"
},
"headers": {
"content type": "application/json"
},
"body": "{\n \"SyncToken\": \"3\", \n \"domain\": \"QBO\", \n \"CustomerMemo\": {\n \"value\": \"An updated memo via full update the second time.\"\n }, \n \"sparse\": true, \n \"Id\": \"713\", \n \"MetaData\": {\n \"CreateTime\": \"2014-09-17T11:20:06-07:00\", \n \"LastUpdatedTime\": \"2015-07-24T14:08:04-07:00\"\n }\n}"
},
"response": {
"status": 400,
"headers": {
"date": "Tue, 04 Jul 2023 15:12:42 GMT",
"content-type": "text/plain",
"content-length": "11",
"connection": "keep-alive",
"intuit_tid": "",
"x-request-id": "",
"server": "istio-envoy"
},
"body": "Bad Request"
}
}

 


@sgalway 

What is the encountered error message for using API Request with POST/PUT? (screenshot)


@Troy Tessalone Zapier is not showing an error, the error is shown in the response from QBO.

 


@sgalway 

No error from QBO is shown in the provided screenshot.

It would be at the bottom of the returned results.

 


@Troy Tessalone I think what you are looking for was already sent up the thread prior to the screenshots.


@sgalway 

If you’re referring to this:

 

Then we’d need to see screenshots with how your Zap step is configured for the QBO - API Request.

 


@Troy Tessalone 

 

 


@sgalway 

Make sure the required or conditionally required fields are set.

QBO API docs for Create Estimate endpoint: https://developer.intuit.com/app/developer/qbo/docs/api/accounting/all-entities/estimate#create-an-estimate

 

 

 


@Troy Tessalone  I have followed the required fields to the letter and it is still not working.  Here is the response received from Zapier.  You can see all required fields are included.

 

Furthermore, when I send the EXACT same body using the Quickbooks playground utility I get success.

 

 


@sgalway 

You can try using Postman to verify the API request.

 

Please clarify which QBO API endpoint you are trying to use.

https://developer.intuit.com/app/developer/qbo/docs/api/accounting/all-entities/estimate