DELETE api/Pricing/{prixid}?user={user}

Delete one or more prices from a price group

Request Information

URI Parameters

NameDescriptionTypeAdditional information
prixid

Price group id

integer

Required

user

Optional user handle - if empty logged in user will be used

string

None.

Body Parameters

Edit details

PricingEdit
NameDescriptionTypeAdditional information
produitPrix

Product price

decimal number

Required

produitID

Product id

integer

Required

IdList

List of ids to update or delete - empty for inserts

Collection of integer

Required

Error

Details of error if edit fails

Error

None.

RowsAffected

Number of rows affected

integer

None.

NewId

Id of new object in case of insert

integer

None.

Request Formats

application/json, text/json

Sample:
{
  "produitPrix": 1.0,
  "produitID": 1,
  "IdList": [
    1,
    2
  ],
  "Error": {
    "Code": 1,
    "Detail": "sample string 2",
    "Data": {}
  },
  "RowsAffected": 1,
  "NewId": 2
}

application/xml, text/xml

Sample:
<PricingEdit xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Pricing">
  <Data xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 1</d2p1:Key>
      <d2p1:Value>sample string 2</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 3</d2p1:Key>
      <d2p1:Value>sample string 4</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>produitPrix</d2p1:Key>
      <d2p1:Value>1</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>produitID</d2p1:Key>
      <d2p1:Value>1</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
  </Data>
  <Error xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <Code>1</Code>
    <Data />
    <Detail>sample string 2</Detail>
  </Error>
  <IdList xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <d2p1:long>1</d2p1:long>
    <d2p1:long>2</d2p1:long>
  </IdList>
  <NewId xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">2</NewId>
  <RowsAffected xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">1</RowsAffected>
  <produitID>1</produitID>
  <produitPrix>1</produitPrix>
</PricingEdit>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Edit details on success
Collection of errors on failure
Return codes
200 - ok
400 - bad request
401 - unauthorized
404 - not found
500 - internal server error

PricingEdit
NameDescriptionTypeAdditional information
produitPrix

Product price

decimal number

Required

produitID

Product id

integer

Required

IdList

List of ids to update or delete - empty for inserts

Collection of integer

Required

Error

Details of error if edit fails

Error

None.

RowsAffected

Number of rows affected

integer

None.

NewId

Id of new object in case of insert

integer

None.

Response Formats

application/json, text/json

Sample:
{
  "produitPrix": 1.0,
  "produitID": 1,
  "IdList": [
    1,
    2
  ],
  "Error": {
    "Code": 1,
    "Detail": "sample string 2",
    "Data": {}
  },
  "RowsAffected": 1,
  "NewId": 2
}

application/xml, text/xml

Sample:
<PricingEdit xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Pricing">
  <Data xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 1</d2p1:Key>
      <d2p1:Value>sample string 2</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 3</d2p1:Key>
      <d2p1:Value>sample string 4</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>produitPrix</d2p1:Key>
      <d2p1:Value>1</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>produitID</d2p1:Key>
      <d2p1:Value>1</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
  </Data>
  <Error xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <Code>1</Code>
    <Data />
    <Detail>sample string 2</Detail>
  </Error>
  <IdList xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
    <d2p1:long>1</d2p1:long>
    <d2p1:long>2</d2p1:long>
  </IdList>
  <NewId xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">2</NewId>
  <RowsAffected xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">1</RowsAffected>
  <produitID>1</produitID>
  <produitPrix>1</produitPrix>
</PricingEdit>