0

I installed this package in a sandbox and it works great. I have a flow call an action which this package created to do call out to an api. I created a changeset to copy the flow to another sandbox. I get this error "getToken (Action) - We can't find an action with the name and action type that you specified."

I made sure to install the package in the new sandbox before I did the changeset. same error. What to do?

Here is some of the flow version source code

<?xml version="1.0" encoding="UTF-8"?>
<Flow xmlns="http://soap.sforce.com/2006/04/metadata">
    <actionCalls>
        <name>getToken</name>
        <label>getToken</label>
        <locationX>362</locationX>
        <locationY>690</locationY>
        <actionName>MakeHTTPCall</actionName>
        <actionType>apex</actionType>
        <connector>
            <targetReference>assnVarToken</targetReference>
        </connector>
        <flowTransactionModel>CurrentTransaction</flowTransactionModel>
        <inputParameters>
            <name>Body</name>
            <value>
                <stringValue>{"client_id":"i4rZm5W44444dddddmo9ZcnJWfGaXGfk","client_secret":"erertttttttlu_Qp5oHOdcYcv1s-bt6LSZmg0_c8m4M79KDnAuVtpD0Jt7tZboR","audience":"https://www.somewebsite.com","grant_type":"client_credentials"}</stringValue>
            </value>
        </inputParameters>
        <inputParameters>
            <name>Endpoint</name>
            <value>
                <stringValue>https://somewebsite.com/oauth/token?</stringValue>
            </value>
        </inputParameters>
        <inputParameters>
            <name>Headers</name>
            <value>
                <stringValue>[{"key":"Content-Type","value":"application/json","order":0}]</stringValue>
            </value>
        </inputParameters>
        <inputParameters>
            <name>Method</name>
            <value>
                <stringValue>POST</stringValue>
            </value>
        </inputParameters>
        <storeOutputAutomatically>true</storeOutputAutomatically>
    </actionCalls>
3
  • is the Apex class associated with MakeHttpCall in the target org?
    – cropredy
    Mar 9, 2022 at 18:39
  • that appears to have been the issue. ty
    – Apex N-u-b
    Mar 10, 2022 at 11:22
  • you should accept the answer as a service to the community
    – cropredy
    Feb 3, 2023 at 17:48

1 Answer 1

1

Flows can comprise actions of various types:

When the error We can't find an action with the name and action type that you specified. occurs, SFDC (unhelpfully) doesn't tell you which action in your Flow is missing its corresponding metadata object

In your case, the <actionName>MakeHTTPCall</actionName> references an Apex action which is associated to some class with an @invocableApex annotation. This Apex class needs to be part of your deployment package (or already present in the target org)

Had your action been an email alert, you would need to have included the Workflow's EmailAlert in your package.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .