Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Answered

How to patch product attributes via API

(1) ShareShare
ReportReport
Posted on by 131
Hi,
 
I'm using D365 F & O and would like to update Product Attributes values via an API - I'm currently testing in Postman.
 
I only need to update the TextValue and BooleanValue of the actual Product Attributes - the AttributeTypeName and AttributeName already exist.
 
PATCH: /data/ProductAttributeValuesV3(ProductNumber='001234')
 
In the body I specify:
 
        {
            /AttributeTypeName/: /Brand/,
            /AttributeName/: /Brand/,
            /BooleanValue/: /No/,
            /TextValue/: /Test/
        }
 
But I keep receiving a 401 // not found:
 
{
    /Message/: /No HTTP resource was found that matches the request URI 'https://xxxxxxxxx/data/ProductAttributeValueV3(ProductNumber='001234')'. No route data was found for this request./
}
 
How do I update the text value // boolean value?  
 
 
  • Verified answer
    Michael Hutcheson Profile Picture
    Michael Hutcheson 131 on at
    How to patch product attributes via API
    Its working - the keys are Product Number \ AttributeTypeName \ AttributeName
     
    If we pass those in the URL:
     
    patch:
    /data/ProductAttributeValuesV3(ProductNumber='001213',AttributeTypeName = 'Brand',AttributeName = 'Brand')
     
    Then the values we want to update in the Body:
     
            {
                "BooleanValue": "No",
                "TextValue": "Test"
            }
     
    This will update D365 F&O.
     
    Not sure if this will help anyone wanting to update the Product Attributes via REST
     
     
  • Michael Hutcheson Profile Picture
    Michael Hutcheson 131 on at
    How to patch product attributes via API
    I still get the 404 not found:
     
    PATCH: 
     
    "Message": "No HTTP resource was found that matches the request URI 'https:XXXXXXXXXX/data/ProductAttributeValuesV3(ProductNumber='001234',AttributeTypeName = 'Brand',AttributeName = 'Brand',BooleanValue = 'No',TextValue = 'tEST123' )'. No route data was found for this request."
  • Martin Dráb Profile Picture
    Martin Dráb 230,605 Most Valuable Professional on at
    How to patch product attributes via API
    The problem seems to be in /data/ProductAttributeValueV3(ProductNumber='001234'). The product number alone is not sufficient for finding an individual product attribute value. Use all fields of the entity key.

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

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey Pt 2

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,605 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans