Hello, I have Developed multiple Custom APIs to receive Documents and respective Lines. Orders/Shipments/Credits. The data is inserted into one single table if that information is of any help. However, At times, without any changes to the code (API Pages), the Line Property just disappears. I have no better way of saying it. I get the following response 'The property 'shipmentLines' does not exist on type 'Microsoft.NAV.easyShipment'. Make sure to only use property names that are defined by the type. CorrelationId: 18a70822-cc72-4c56-8c48-2a5df03678e8. ' It reappears once we redeploy.
The $metadata (yourbaseurl:port/(ServerInstance)/api/(APIPublisher)/(APIGroup)/(APIVersion)/$metadata) response will show it as:
Response:
{
"responses": [
{
"id": "r1",
"status": 201,
"headers": {
"location": "https://YourBaseURL:Port/(ServerInstance)/api/(APIPublisher)/(APIGroup)/v2.0/companies(9848fdb3-4041-eb11-bbfc-000d3ad4efad)/easyShipments(ecf7af9b-aef0-ed11-964f-0022480177a4)",
"content-type": "application/json; odata.metadata=minimal",
"odata-version": "4.0"
},
"body": {
"@odata.context": "https://YourBaseURL:Port/(ServerInstance)/api/(APIPublisher)/(APIGroup)/v2.0/$metadata#companies(9848fdb3-4041-eb11-bbfc-000d3ad4efad)/easyShipments/$entity",
"@odata.etag": "W/\"JzQ0OzBhL1k2cTFkZk9oZG43K1MrbGZ4ZnFWR2NoOE1uSmI5S0pMajhhK1BuQnc9MTswMDsn\"",
"id": "ecf7af9b-aef0-ed11-964f-0022480177a4",
"documentNo": "PM-TESTSHP2",
"customerComments": "",
"customerEmail": "Cust@email.co.uk",
"customerID": "Cust",
"weight": 24.28,
"dateTime": "2023-02-15T12:17:54Z",
"discountAmount": 0,
"discountCode": "",
"grandTotal": "",
"indexNo": "",
"type": "Insert",
"orderExists": false,
"orderID": "PM-TESTORD2",
"paymentMethod": "CASH",
"receipted": "2023-05-12T10:20:25.533Z",
"shipmentCount": 0,
"shipmentDate": "2021-09-21",
"shipmentID": "PM-TESTSHP1",
"shippingHandling": 0,
"shippingDescription": "Ship",
"shippingMethod": "Ship Method",
"store": "Store",
"subtotal": 0,
"totalNoOfLines": 1,
"isOrderCompletelySynced": false,
"isShopOrder": true,
"dimensionCode": "TST",
"shipmentLines": []
}
}
]
}
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,232 Super User 2024 Season 2
Martin Dráb 230,064 Most Valuable Professional
nmaenpaa 101,156