Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Assigne Dimension Value to Sales Invoice API

(0) ShareShare
ReportReport
Posted on by

Hi! 

Does anybody know how we can assigne Dimension Values to Invoices via API '?

Thank you very much for your help

Best regards

  • Verified answer
    Lars Lohndorf-Larsen Profile Picture
    on at
    RE: Assigne Dimension Value to Sales Invoice API

    Hello,

    I happen to have an example of creating a purchase order and assigning dimensions - below. Does that help you?

    Here is an example from the sdandard API PurchaseOrders, using Navigation properties on the API to create both lines and dimensions:

    purchaseOrder resource type - Business Central | Microsoft Docs

    POST api.businesscentral.dynamics.com/.../purchaseOrders

    BODY

    {

    "vendorNumber": "40000",

    "purchaseOrderLines":

    [

    {"itemId" : "3d0b2413-b0fd-ea11-bb48-000d3a2fece2"}

    ]

    ,

    "dimensionSetLines":[{

       "code": "DEPARTMENT",

       "valueCode": "SALES"

    }

    ]

    }

  • Suggested answer
    Nitin Verma Profile Picture
    21,544 Moderator on at
    RE: Assigne Dimension Value to Sales Invoice API

    Please try this

    api.businesscentral.dynamics.com/.../salesInvoiceLines

  • Sleina Profile Picture
    on at
    RE: Assigne Dimension Value to Sales Invoice API

    Hi Thank you for your fast response! Which Base API would you use for this ? Sales Invoice Lines?

  • Suggested answer
    Nitin Verma Profile Picture
    21,544 Moderator on at
    RE: Assigne Dimension Value to Sales Invoice API

    Hi,

    You can try to pass Shortcut Dim1  and Shortcut Dim2 with the API.

    Thanks.

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,095 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,866 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans