POST api/ms/product/create

Create

Request Information

URI Parameters

None.

Body Parameters

m_product_create
NameDescriptionTypeAdditional information
Name

string

Required

String length: inclusive between 0 and 50

Detail

string

String length: inclusive between 0 and 4000

Price

decimal number

None.

RegisterCarImagePreview

string

None.

RegisterCarImagePrivate

string

None.

IdentificationCardImage

string

None.

SellerEmail

string

None.

SellerFirstName

string

None.

SellerLastName

string

None.

SellerIdentificationNumber

string

None.

SellerCountryCode

string

None.

SellerPhoneNumber

string

None.

ProductImages

Collection of m_product_image

None.

Infomation

m_product_create_infomation

None.

Request Formats

application/json, text/json

Sample:
{
  "Name": "sample string 1",
  "Detail": "sample string 2",
  "Price": 3.0,
  "RegisterCarImagePreview": "sample string 4",
  "RegisterCarImagePrivate": "sample string 5",
  "IdentificationCardImage": "sample string 6",
  "SellerEmail": "sample string 7",
  "SellerFirstName": "sample string 8",
  "SellerLastName": "sample string 9",
  "SellerIdentificationNumber": "sample string 10",
  "SellerCountryCode": "sample string 11",
  "SellerPhoneNumber": "sample string 12",
  "ProductImages": [
    {
      "Name": "sample string 1"
    },
    {
      "Name": "sample string 1"
    }
  ],
  "Infomation": {
    "IsSecondHand": true,
    "MileCount": 1,
    "ProductionYear": "2025-12-06T12:12:38.957602+07:00",
    "AreaDistrictId": 1,
    "BrandId": 1,
    "ModelId": 1,
    "TypeVehicleId": 1,
    "GearId": 1,
    "FuelId": 1,
    "Colors": [
      1,
      2
    ],
    "MoreModelName": "sample string 1",
    "MoreColorName": "sample string 2",
    "Attributes": [
      {
        "AttributeId": 1,
        "AttributeValue": "sample string 2"
      },
      {
        "AttributeId": 1,
        "AttributeValue": "sample string 2"
      }
    ]
  }
}

application/xml, text/xml

Sample:
<m_product_create xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Project.Modules.Models.Mainsystem">
  <Detail>sample string 2</Detail>
  <IdentificationCardImage>sample string 6</IdentificationCardImage>
  <Infomation>
    <AreaDistrictId>1</AreaDistrictId>
    <Attributes>
      <m_product_create_infomation_attributes>
        <AttributeId>1</AttributeId>
        <AttributeValue>sample string 2</AttributeValue>
      </m_product_create_infomation_attributes>
      <m_product_create_infomation_attributes>
        <AttributeId>1</AttributeId>
        <AttributeValue>sample string 2</AttributeValue>
      </m_product_create_infomation_attributes>
    </Attributes>
    <BrandId>1</BrandId>
    <Colors xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:int>1</d3p1:int>
      <d3p1:int>2</d3p1:int>
    </Colors>
    <FuelId>1</FuelId>
    <GearId>1</GearId>
    <IsSecondHand>true</IsSecondHand>
    <MileCount>1</MileCount>
    <ModelId>1</ModelId>
    <MoreColorName>sample string 2</MoreColorName>
    <MoreModelName>sample string 1</MoreModelName>
    <ProductionYear>2025-12-06T12:12:38.957602+07:00</ProductionYear>
    <TypeVehicleId>1</TypeVehicleId>
  </Infomation>
  <Name>sample string 1</Name>
  <Price>3</Price>
  <ProductImages>
    <m_product_image>
      <Name>sample string 1</Name>
    </m_product_image>
    <m_product_image>
      <Name>sample string 1</Name>
    </m_product_image>
  </ProductImages>
  <RegisterCarImagePreview>sample string 4</RegisterCarImagePreview>
  <RegisterCarImagePrivate>sample string 5</RegisterCarImagePrivate>
  <SellerCountryCode>sample string 11</SellerCountryCode>
  <SellerEmail>sample string 7</SellerEmail>
  <SellerFirstName>sample string 8</SellerFirstName>
  <SellerIdentificationNumber>sample string 10</SellerIdentificationNumber>
  <SellerLastName>sample string 9</SellerLastName>
  <SellerPhoneNumber>sample string 12</SellerPhoneNumber>
</m_product_create>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'm_product_create'.

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

application/json, text/json, application/xml, text/xml

Sample:

Sample not available.