Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Commerce forum / Has anyone tried creat...
Commerce forum
Suggested answer

Has anyone tried creating a custom data action to call an external service/API and get an error "sanitizedActionPath is not defined"?

Posted on by 5

I tried following the guide in the document "Dynamics 365 E-Commerce Developer Extensibility Getting Started Guide" topic #12 discussed in https://community.dynamics.com/365/b/techtalks/posts/dynamics-365-commerce-how-to-extend-dynamics-365-commerce-january-22-2020,

I am getting an error

pastedimage1590637285663v1.png

 Has anyone experienced this?

Categories:
  • Suggested answer
    am24 Profile Picture
    am24 5 on at
    RE: Has anyone tried creating a custom data action to call an external service/API and get an error "sanitizedActionPath is not defined"?

    This has been resolved.

    Fix is to make the createObservableDataAction an export default instead of export const.

    Creating a new data action will have this createObservableDataAction just like in the video guide.

    pastedimage1594106285958v1.png

    Change it to:

    export default Msdyn365.createObservableDataAction({

         action: <Msdyn365.IAction<IGetProductReviewsData>>action,

         input: createInput

    });

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Has anyone tried creating a custom data action to call an external service/API and get an error "sanitizedActionPath is not defined"?

    I am facing the same issue, could you get any resolution to it which you share?

  • Xusheng Profile Picture
    Xusheng on at
    RE: Has anyone tried creating a custom data action to call an external service/API and get an error "sanitizedActionPath is not defined"?

    Hi,

    Since this is a request on customization, I am leaving this thread open for community members to respond to your query.

Helpful resources

Quick Links

Replay now available! Dynamics 365 Community Call (CRM Edition)

Catch up on the first D365 Community Call held on 7/10

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 287,696 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,490 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans