Skip to main content

I am trying to have an invoice sent from QBO attach to an account in Clarity.  Technically it is a ZAP between Outlook and Clarity

 

Here is my Zap:

1, Trigger: New email is received by a specific outlook account used by QBO and has a CC email address in the format of (Account#@domain.com- fake email address)

2. Filter: only continue if email subject contains, Invoice, Paid Invoice, PO

3. Remove domain from CC email. 

4. Look up the account using the value from #3(#4 & #5 are not both needed)

5. Look up the account using the value from #3 (#4 & #5 are not both needed)

6. Confirm the attachment and prepare it to be uploaded.

7. Upload the attachment to the account

 

Here is my step 6:

And says it is working (Test was successful!)

 

Here are my commands in step 7:

When I use this the upload fails:

Clarity says:

10101 The JSON body send in the request is an Invalid JSON. The Error occurred when tried to parse the JSON.

 

{

                " APIKey": "purefiltration-key-XXXXXXXXXXXXXXXXXXXXXX",

                "Resource": "Attachment",

                "Operation": "Create",

   

                "Data": {

                                "Name": "{{103964163__subject}}.pdf",

                                "Title": "{{103964163__subject}}

                                "SourceObjectId": "{{103964166__AccountId}}",

                                "SourceObjectType": "Account",

                                "FileContent": "{{103964167__data}}"

                }

}

 

I think it worked when I use this upload:

{

                "APIKey": "purefiltration-key-XXXXXXXXXXXXXXXXXXXXXX",

                "Resource": "Attachment",

                "Operation": "Create",

                "Data": {

                                "Name": "{{103656557__subject}}.pdf",

                                "Title": "{{103656557__subject}}",

                                "SourceObjectId": "{{103961482__Data ]AccountId}}",

                                "SourceObjectType": "Account",

                                "FileContent": "{{103964007__data}}"

                }

}

 

However I do not know where to find the DataÂ]AccountId}}",   to make this work.

 

 

Any advice on why the emailed attachment is not uploading to the CRM?  Is there a different way I should be doing this.  I am a novice at this stuff and blindly finding my way through this.

 

Scott

Hi @sboyd - The error you’re getting is caused by an invalid JSON body. By inspecting the payload you’re sending, I found that it was missing a quote mark and a comma here (See the screenshot).

Try this instead:

{
"APIKey": "purefiltration-key-XXXXXXXXXXXXXXXXXXXXXX",
"Resource": "Attachment",
"Operation": "Create",
"Data": {
"Name": "{{103964163__subject}}.pdf",
"Title": "{{103964163__subject}}",
"SourceObjectId": "{{103964166__AccountId}}",
"SourceObjectType": "Account",
"FileContent": "{{103964167__data}}"
}
}

 


You nailed it.  Such a small item and caused a ton of pain.  Thank you for your help.  That did fix it.

Â