I have add field track_url
in table sales_shipment_track
.
I'm creating shipment with API
http://192.168.0.105/magento2/project/rest/V1/order/1292/ship
{
"items": [
{
"order_item_id": 4473,
"qty": 1
}
],
"notify": true,
"tracks": [
{
"track_number": "3456789",
"track_url": "http://192.168.0.105/demo/magento2?gf=13131",
"title": "GEODIS",
"carrier_code": "custom"
}
]
}
everything was working fine before added new field track_url.
Now i'm getting error.
"message": "Property \"TrackUrl
\" does not have corresponding setter in class \"Magento\\Sales\\Api\\Data\\ShipmentTrackCreationInterface\
".",
How can i add extension attribute for it?
EDIT
I have add attribute in extension_attributes.xml
.How can i save it with API
?
<config>
<extension_attributes for="Magento\Sales\Api\Data\OrderInterface">
<attribute code="dpd_relay_id" type="string"/>
<attribute code="erp_exported" type="string"/>
</extension_attributes>
<extension_attributes for="Magento\Catalog\Api\Data\ProductInterface">
<attribute code="finalprice" type="string"/>
<attribute code="brand" type="string"/>
</extension_attributes>
<extension_attributes for="Magento\Sales\Api\Data\ShipmentTrackCreationInterface">
<attribute code="track_url" type="string"/>
</extension_attributes>
</config>