Skip to main content

Notifications

Power Automate - Using Connectors
Answered

502 Bad Gate way - Salesforce

(0) ShareShare
ReportReport
Posted on by 84

Hello all,

 

I have a flow set up that will parse text from an email that is received into a shared mailbox for terminations. It grabs the business transferee email address and then does a Salesforce query to get the contact ID of said person. It then creates a case in Salesforce using dynamic values adding the email subject line to the subject line, the body to the description, and the contact ID so the case has the correct contact. 

 

The other required fields to open the case which are static are Salesforce Object Type, Case Status, Case Priority, Case Business Hours ID, Case Case Type, Case Category, Case Sub-Category. 

 

I have tested this to success reusing a trigger from a email received in the shared mailbox, which created the case. 

 

When I put this into production, the case creation fails with the following:

 

DH2023_0-1711637110771.png

{
  "error": {
    "code"502,
    "source""flow-apim-unitedstates-XXXXXXXXX",
    "clientRequestId""XXXXXXXX",
    "message""BadGateway",
    "innerError": {
      "status"502,
      "message""Salesforce failed to complete task: Message: We can't save this record because the “Case Actions” process failed. Give your Salesforce admin these details. Probably Limit Exceeded or 0 recipients\n Error ID: XXXXXX",
      "error": {
        "message"null,
        "code""Unknown",
        "originalMessage"null
      },
      "source""Salesforce.Common",
      "errors": []
    }
  }
}
 
ANY help is appreciated! 
  • DH2023 Profile Picture
    DH2023 84 on at
    Re: 502 Bad Gate way - Salesforce

    This ended up being a mistake on the HR side and this field was moved! Thank you for the reply. 

  • Verified answer
    readystart Profile Picture
    readystart 7 on at
    Re: 502 Bad Gate way - Salesforce

    Based on the response, the 'Case Actions' flow/process failed in Salesforce due to a platform governor limit or no recipient successfully satisfying the conditions in your production environment for this execution instance relative to your test case (uncertain what Salesforce environment your successful test was executed against, sandbox, scratch org, etc).

     

    Coordinating with the Salesforce application team to debug the 'Case Action' flow/process and it's execution in production against  your test case debugs should help. Checking that the Salesforce integration user account performing this action has the appropriate permissions in production relative to your successful test may also help.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,508

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,839

Leaderboard

Featured topics