Skip to main content

Notifications

Small and medium business | Business Central, N...
Suggested answer

API V2 Attachment fails

Posted on by 60

Dear All,

My goal ist to create an attachment entry via the API V2 version, followed by adding a PDF to the created entry.

I therefore do POST on

{
 
"parentId" :
"41bc6e53-e40b-ed11-90eb-00224860b9cd",
 
"fileName":
"dummy.pdf"
 
}

The parent id is a valid purchase invoice i queried via the the V2 API.

I receive error:

"You do not have permission to create or run scheduled tasks. CorrelationId: 5ac601b6-7d4b-4d3c-8ad6-1803ec0c7499."


Any pointers what is wrong here?

  • Suggested answer
    Saurav.Dhyani Profile Picture
    Saurav.Dhyani 17,965 Super User 2024 Season 2 on at
    API V2 Attachment fails
    Hi,
     
    Hope this helps - https://youtu.be/hEVjHlAgfbU
     
    Other Items related to API are available in this playlist -  https://www.youtube.com/playlist?list=PL2-PuYsxlF1dpqpRdHUbOtpsbrecuY1wR
     
     
    Regards,
    Saurav Dhyani
  • SvenB Profile Picture
    SvenB 60 on at
    RE: API V2 Attachment fails

    I now just did. D365 FULL ACCESS.

    I made sure to fetch a new token after (not sure that is necessary).

    Same response on Postman.

    "You do not have permission to create or run scheduled tasks "

  • Suggested answer
    JAngle Profile Picture
    JAngle 33,159 on at
    RE: API V2 Attachment fails

    Have you added permissions to that user?

    pastedimage1659640640764v1.png

  • SvenB Profile Picture
    SvenB 60 on at
    RE: API V2 Attachment fails

    Hi Josh,

    it is an Azure Active Directory Applications. Not sure if this is a CSP account.

  • Suggested answer
    JAngle Profile Picture
    JAngle 33,159 on at
    RE: API V2 Attachment fails

    what type of user account is this with? From the error it would seem like it is a CSP account in which case you may need a real user account

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

New! Quick response templatesâš¡

Save time with the new custom templates!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,188 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,030 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans