| All Verbs | /UpdateStock | ||
|---|---|---|---|
| All Verbs | /StockUpdate |
Imports System
Imports System.IO
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports GoToLightAPI
Namespace Global
Namespace GoToLightAPI
Public Partial Class StockAdditional
Public Overridable Property StockID As Integer
Public Overridable Property Gtin As String
Public Overridable Property StockLocation As String
Public Overridable Property PhysicalQuantityStockLocation As Double
End Class
Public Partial Class StockUpdate
'''<Summary>
'''Internal DB identifier
'''</Summary>
<ApiMember(Description:="Internal DB identifier", IsRequired:=true)>
Public Overridable Property StockID As Integer
'''<Summary>
'''Global Trade Item Number : usually is the barcode of product (EAN, UPC, Gencode, etc...)
'''</Summary>
<ApiMember(Description:="Global Trade Item Number : usually is the barcode of product (EAN, UPC, Gencode, etc...)", IsRequired:=true)>
Public Overridable Property Gtin As String
'''<Summary>
'''Location of main stock or stock address
'''</Summary>
<ApiMember(Description:="Location of main stock or stock address")>
Public Overridable Property StockLocation As String
'''<Summary>
'''Quantity physically stocked at this location
'''</Summary>
<ApiMember(Description:="Quantity physically stocked at this location")>
Public Overridable Property PhysicalQuantityStockLocation As Double
'''<Summary>
'''Location of reserve stock (2nd stock location address)
'''</Summary>
<ApiMember(Description:="Location of reserve stock (2nd stock location address)")>
Public Overridable Property ReserveStockLocation As String
'''<Summary>
'''Quantity physically stocked at this location
'''</Summary>
<ApiMember(Description:="Quantity physically stocked at this location")>
Public Overridable Property PhysicalQuantityReserveStockLocation As Double
'''<Summary>
'''Product ID
'''</Summary>
<ApiMember(Description:="Product ID")>
Public Overridable Property ProductID As String
'''<Summary>
'''Second product ID E.g. in case of variant
'''</Summary>
<ApiMember(Description:="Second product ID E.g. in case of variant")>
Public Overridable Property ProductAttributeID As String
'''<Summary>
'''Product reference
'''</Summary>
<ApiMember(Description:="Product reference")>
Public Overridable Property Reference As String
'''<Summary>
'''GTIN of variant
'''</Summary>
<ApiMember(Description:="GTIN of variant")>
Public Overridable Property GtinAttribute As String
'''<Summary>
'''Product label
'''</Summary>
<ApiMember(Description:="Product label")>
Public Overridable Property Label As String
'''<Summary>
'''NbSKUInPackage
'''</Summary>
<ApiMember(Description:="NbSKUInPackage")>
Public Overridable Property NbSKUInPackage As Integer?
'''<Summary>
'''PackageReference
'''</Summary>
<ApiMember(Description:="PackageReference")>
Public Overridable Property PackageReference As String
'''<Summary>
'''NbSKUInPackage2
'''</Summary>
<ApiMember(Description:="NbSKUInPackage2")>
Public Overridable Property NbSKUInPackage2 As Integer?
'''<Summary>
'''PackageReference2
'''</Summary>
<ApiMember(Description:="PackageReference2")>
Public Overridable Property PackageReference2 As String
'''<Summary>
'''Weight
'''</Summary>
<ApiMember(Description:="Weight")>
Public Overridable Property Weight As String
'''<Summary>
'''List of stock Additional
'''</Summary>
<ApiMember(Description:="List of stock Additional")>
Public Overridable Property StockAdditionals As List(Of StockAdditional) = New List(Of StockAdditional)
End Class
End Namespace
End Namespace
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /UpdateStock HTTP/1.1
Host: clouddemo.pickeos.com
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
StockID: 0,
Gtin: String,
StockLocation: String,
PhysicalQuantityStockLocation: 0,
ReserveStockLocation: String,
PhysicalQuantityReserveStockLocation: 0,
ProductID: String,
ProductAttributeID: String,
Reference: String,
GtinAttribute: String,
Label: String,
NbSKUInPackage: 0,
PackageReference: String,
NbSKUInPackage2: 0,
PackageReference2: String,
Weight: String,
StockAdditionals:
[
{
StockID: 0,
Gtin: String,
StockLocation: String,
PhysicalQuantityStockLocation: 0
}
]
}