Richemont.Booster2.PublicApi

<back to all web services

CreateSellOut

Requires Authentication
The following routes are available for this service:
POST/warrantyCreate a Sell-OutCreate a sell-out in a POS you are authorised for
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Richemont.Booster2.PublicApi.Sellout.ServiceModel;

namespace Richemont.Booster2.PublicApi.Sellout.ServiceModel
{
    public partial class CreateSellOut
    {
        public CreateSellOut()
        {
            saleRepresentativeEmails = new List<string>{};
        }

        ///<summary>
        ///Brand Trigram, e.g. CAR, IWC; compulsory only if articleCode is not provided
        ///</summary>
        [ApiMember(Description="Brand Trigram, e.g. CAR, IWC; compulsory only if articleCode is not provided")]
        public virtual string brand { get; set; }

        ///<summary>
        ///Richemont POS code
        ///</summary>
        [ApiMember(Description="Richemont POS code", IsRequired=true)]
        public virtual string posCode { get; set; }

        ///<summary>
        ///Receipt or Invoice Number
        ///</summary>
        [ApiMember(Description="Receipt or Invoice Number")]
        public virtual string documentNumber { get; set; }

        ///<summary>
        ///Date of the Sell-out
        ///</summary>
        [ApiMember(Description="Date of the Sell-out", IsRequired=true)]
        public virtual DateTime documentDate { get; set; }

        ///<summary>
        ///Position Number
        ///</summary>
        [ApiMember(Description="Position Number")]
        public virtual int? documentLineNumber { get; set; }

        ///<summary>
        ///Richemont Reference Code of the item
        ///</summary>
        [ApiMember(Description="Richemont Reference Code of the item", IsRequired=true)]
        public virtual string articleCode { get; set; }

        ///<summary>
        ///Serial Number of the item
        ///</summary>
        [ApiMember(Description="Serial Number of the item")]
        public virtual string serialNumber { get; set; }

        ///<summary>
        ///Use positive for standard Sell-out and negative quantity for return
        ///</summary>
        [ApiMember(Description="Use positive for standard Sell-out and negative quantity for return", IsRequired=true)]
        public virtual int quantity { get; set; }

        ///<summary>
        ///Sold Price
        ///</summary>
        [ApiMember(Description="Sold Price")]
        public virtual decimal? unitPrice { get; set; }

        ///<summary>
        ///Currency of the sold price
        ///</summary>
        [ApiMember(Description="Currency of the sold price")]
        public virtual string currencyCode { get; set; }

        ///<summary>
        ///Booster Customer Id
        ///</summary>
        [ApiMember(Description="Booster Customer Id")]
        public virtual int? boosterCustomerId { get; set; }

        ///<summary>
        ///Sale Representative Email e.g. rauf.aliyev@richemont.com
        ///</summary>
        [ApiMember(Description="Sale Representative Email e.g. rauf.aliyev@richemont.com")]
        public virtual List<string> saleRepresentativeEmails { get; set; }

        ///<summary>
        ///Promoter Type ID, e.g. DAI, FIT, GRT
        ///</summary>
        [ApiMember(Description="Promoter Type ID, e.g. DAI, FIT, GRT")]
        public virtual string promoterTypeId { get; set; }

        ///<summary>
        ///Return Reason ID, e.g ADM, CLR, EXC, DEF, OTH
        ///</summary>
        [ApiMember(Description="Return Reason ID, e.g ADM, CLR, EXC, DEF, OTH")]
        public virtual string returnReasonId { get; set; }

        ///<summary>
        ///Sale related comments
        ///</summary>
        [ApiMember(Description="Sale related comments")]
        public virtual string comments { get; set; }

        ///<summary>
        ///Original Sale Detail Id
        ///</summary>
        [ApiMember(Description="Original Sale Detail Id")]
        public virtual int? originalSaleDetailId { get; set; }

        ///<summary>
        ///To have the piece back in stock as consignment in case of consignment sellout return
        ///</summary>
        [ApiMember(Description="To have the piece back in stock as consignment in case of consignment sellout return")]
        public virtual bool? consSelloutReturnInStock { get; set; }
    }

    public partial class CreateSellOutResponse
    {
        public CreateSellOutResponse()
        {
            saleDetailIds = new List<int>{};
        }

        ///<summary>
        ///Unique Identifier of the Sell-out item created in Booster
        ///</summary>
        [ApiMember(Description="Unique Identifier of the Sell-out item created in Booster")]
        public virtual int? saleDetailId { get; set; }

        ///<summary>
        ///Unique Identifiers of the Sell-out items created in Booster if more than one
        ///</summary>
        [ApiMember(Description="Unique Identifiers of the Sell-out items created in Booster if more than one")]
        public virtual List<int> saleDetailIds { get; set; }

        ///<summary>
        ///Unique Identifier of the Sell-out header created in Booster
        ///</summary>
        [ApiMember(Description="Unique Identifier of the Sell-out header created in Booster", IsRequired=true)]
        public virtual int saleId { get; set; }
    }

}

C# CreateSellOut DTOs

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

HTTP + XML

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

POST /warranty HTTP/1.1 
Host: dev-api-booster.richemont.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<CreateSellOut xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Sellout.ServiceModel">
  <articleCode>String</articleCode>
  <boosterCustomerId>0</boosterCustomerId>
  <brand>String</brand>
  <comments>String</comments>
  <consSelloutReturnInStock>false</consSelloutReturnInStock>
  <currencyCode>String</currencyCode>
  <documentDate>0001-01-01T00:00:00</documentDate>
  <documentLineNumber>0</documentLineNumber>
  <documentNumber>String</documentNumber>
  <originalSaleDetailId>0</originalSaleDetailId>
  <posCode>String</posCode>
  <promoterTypeId>String</promoterTypeId>
  <quantity>0</quantity>
  <returnReasonId>String</returnReasonId>
  <saleRepresentativeEmails xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>String</d2p1:string>
  </saleRepresentativeEmails>
  <serialNumber>String</serialNumber>
  <unitPrice>0</unitPrice>
</CreateSellOut>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<CreateSellOutResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Sellout.ServiceModel">
  <saleDetailId>0</saleDetailId>
  <saleDetailIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>0</d2p1:int>
  </saleDetailIds>
  <saleId>0</saleId>
</CreateSellOutResponse>