Skip to main content
Solved

How to change Freight Price via rest api?

  • Apr 22, 2026 7:04 PM UTC
  • 3 replies
  • 108 views
  • Translate All

Forum|alt.badge.img+1

Hi All,

I want to change the Freight Price and Amount on SO303000. I tried few different way but can’t make it. 

My most current request.

I send PUT request to endpoint SalesInvoice

with body:

{

  "ReferenceNbr": { "value": "INVSP212099" },

  "Type": { "value": "Invoice" },

  "FreightDetails": [

            {   "OrderNbr":{

                    "value":"SP219039"

                },

                "OrderType":{

                    "value":"SP"

                },

                "ShipmentNbr": {

                    "value": "SHP297504"

                },

                "ShipmentType": {

                    "value": "Shipment"

                },

                "FreightAmount": {

                    "value": 0

                }

            }

        ]

}

This will add a new line not update the current data. 

Do anyone have been done this before? Thank you.

Best answer by Django

Are you trying to update an existing sales invoice or is this happening when creating a new sales invoice?

nvm - I see that you’re trying to update.

What you likely need to do is to query the sales invoice and see what comes back in the FreightDetails section. I haven’t looked but you’ll likely have an “Id” value that’s returned. You’ll send that back in your PUT request to update the value of the field on that particular record.

Your Json, above, isn’t directing ACM to a specific line so it adds a new record.

View original

3 replies

Forum|alt.badge.img+8
  • Captain II
  • Answer
  • Apr 22, 2026 8:36 PM UTC

Are you trying to update an existing sales invoice or is this happening when creating a new sales invoice?

nvm - I see that you’re trying to update.

What you likely need to do is to query the sales invoice and see what comes back in the FreightDetails section. I haven’t looked but you’ll likely have an “Id” value that’s returned. You’ll send that back in your PUT request to update the value of the field on that particular record.

Your Json, above, isn’t directing ACM to a specific line so it adds a new record.

Translate

Forum|alt.badge.img+1
  • Author
  • Semi-Pro III
  • Apr 22, 2026 8:46 PM UTC

​@Django Got you. Let my try to put ID in the request.

Translate

Forum|alt.badge.img+1
  • Author
  • Semi-Pro III
  • Apr 22, 2026 8:51 PM UTC

​@Django Thank you. Problem solved. 

Translate