Expensify.org is accepting proposals for new campaigns. Submit yours here by April 30th to receive up to $100,000 in funding for campaigns dismantling injustice related to: Climate, Homes, Hunger, Reentry, or Youth.

How to undo mark as exported onfinish action?

sumitsumit Expensify Customer Posts: 2

I am importing expenses from expensify to Salesforce. After I use report exporter API, the report is marked as exported as per the below code.

        var expenseTransaction = `{

                                    "type":"file",

                                    "onReceive":{

                                            "immediateResponse":["returnRandomFileName"]

                                    },

                                    "credentials":{

                                            "partnerUserID":"${expensifySettings[(`${orgNamespacePrefix}Partner_ID__c`)]}",

                                            "partnerUserSecret":"${expensifySettings[(`${orgNamespacePrefix}Partner_Secret__c`)]}"

                                    },

                                    "inputSettings":{

                                            "type":"combinedReportData",

                                            "reportState":"APPROVED",

                                            "limit":"10",

                                            "filters":{"startDate":"${expensifySettings[(`${orgNamespacePrefix}Last_Sync_Date__c`)]}","markedAsExported":"Expensify Export Test"}


                                    },

                                    "outputSettings":{

                                        "fileExtension":"json"

                                    },

                                    "onFinish":[

                                {"actionName":"markAsExported","label":"Expensify Export Test"}

                            ]

                                }`;


But if I encounter error on Salesforce then I do need to revert/rollback this process.

How can I do that?

Answers

Sign In or Register to comment.