NAV

<back to all web services

SalesCenterReturnCreate

The following routes are available for this service:
POST/sales-center/return
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports NAV.ServiceModel

Namespace Global

    Namespace NAV.ServiceModel

        Public Partial Class NAVReturnAddress
            Public Overridable Property FirstName As String
            Public Overridable Property LastName As String
            Public Overridable Property AddressLine1 As String
            Public Overridable Property AddressLine2 As String
            Public Overridable Property AddressLine3 As String
            Public Overridable Property AddressLine4 As String
            Public Overridable Property AddressLine5 As String
            Public Overridable Property City As String
            Public Overridable Property StateProvinceCode As String
            Public Overridable Property PostalCode As String
            Public Overridable Property County As String
            Public Overridable Property CountryCode As String
        End Class

        Public Partial Class NAVReturnCreateResponse
            Public Overridable Property RmaNumber As String
            Public Overridable Property PackingListURI As String
            Public Overridable Property Total As Nullable(Of Decimal)
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class

        Public Partial Class NAVReturnHeaderCreate
            Public Overridable Property OriginalOrderNumber As String
            Public Overridable Property OriginalOrderTypeId As String
            Public Overridable Property RmaNote As String
            Public Overridable Property ShipLabelType As String
        End Class

        Public Partial Class NAVReturnInboundSkuCreate
            Public Overridable Property SkuCode As String
            Public Overridable Property OrderLineNumber As Nullable(Of Integer)
            Public Overridable Property QuantityReturned As Nullable(Of Integer)
            Public Overridable Property ReasonType As String
            Public Overridable Property RmaNote As String
        End Class

        Public Partial Class NAVReturnOutboundSkuCreate
            Public Overridable Property SkuCode As String
            Public Overridable Property OrderLineNumber As Nullable(Of Integer)
            Public Overridable Property QuantityReturned As Nullable(Of Integer)
            Public Overridable Property ReasonType As String
        End Class

        Public Partial Class SalesCenterReturnCreate
            Implements IPost
            Public Sub New()
                InboundSkus = New List(Of NAVReturnInboundSkuCreate)
                OutboundSkus = New List(Of NAVReturnOutboundSkuCreate)
            End Sub

            Public Overridable Property Header As NAVReturnHeaderCreate
            Public Overridable Property InboundSkus As List(Of NAVReturnInboundSkuCreate)
            Public Overridable Property OutboundSkus As List(Of NAVReturnOutboundSkuCreate)
            Public Overridable Property BillingAddress As NAVReturnAddress
            Public Overridable Property ShippingAddress As NAVReturnAddress
        End Class
    End Namespace
End Namespace

VB.NET SalesCenterReturnCreate DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /sales-center/return HTTP/1.1 
Host: extensions.avon.ca 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"header":{"originalOrderNumber":"String","originalOrderTypeId":"String","rmaNote":"String","shipLabelType":"String"},"inboundSkus":[{"skuCode":"String","orderLineNumber":0,"quantityReturned":0,"reasonType":"String","rmaNote":"String"}],"outboundSkus":[{"skuCode":"String","orderLineNumber":0,"quantityReturned":0,"reasonType":"String"}],"billingAddress":{"firstName":"String","lastName":"String","addressLine1":"String","addressLine2":"String","addressLine3":"String","addressLine4":"String","addressLine5":"String","city":"String","stateProvinceCode":"String","postalCode":"String","county":"String","countryCode":"String"},"shippingAddress":{"firstName":"String","lastName":"String","addressLine1":"String","addressLine2":"String","addressLine3":"String","addressLine4":"String","addressLine5":"String","city":"String","stateProvinceCode":"String","postalCode":"String","county":"String","countryCode":"String"}}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"rmaNumber":"String","packingListURI":"String","total":0,"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}