POST api/carrinho

Request Information

URI Parameters

None.

Body Parameters

carrinhoPOSTModel
NameDescriptionTypeAdditional information
carrinho_id

integer

None.

cod_barras

string

None.

qtde

integer

None.

Request Formats

application/json, text/json

Sample:
{
  "carrinho_id": 1,
  "cod_barras": "sample string 2",
  "qtde": 3
}

application/xml, text/xml

Sample:
<carrinhoPOSTModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ShopperREST.Models">
  <carrinho_id>1</carrinho_id>
  <cod_barras>sample string 2</cod_barras>
  <qtde>3</qtde>
</carrinhoPOSTModel>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

carrinhoPOSTRetModel
NameDescriptionTypeAdditional information
status

string

None.

mensagem

string

None.

carrinho_id

integer

None.

tipo

TcarrinhoTipoCodBarras

None.

total

decimal number

None.

itens

Collection of itensCarrinhoModel

None.

depende

Collection of dependeLojaModel

None.

busca

Collection of buscaModel

None.

Response Formats

application/json, text/json

Sample:
{
  "status": "sample string 1",
  "mensagem": "sample string 2",
  "carrinho_id": 3,
  "tipo": 1,
  "total": 4.0,
  "itens": [
    {
      "cod_barras": "sample string 1",
      "apelido": "sample string 2",
      "qtde": 3,
      "unitario": 4.0,
      "total": 5.0,
      "foto": "sample string 6",
      "unidade": "sample string 7"
    },
    {
      "cod_barras": "sample string 1",
      "apelido": "sample string 2",
      "qtde": 3,
      "unitario": 4.0,
      "total": 5.0,
      "foto": "sample string 6",
      "unidade": "sample string 7"
    }
  ],
  "depende": [
    {
      "id": 1,
      "nome": "sample string 2",
      "tipo": "sample string 3",
      "cartao_id": 4,
      "CardNumber": "sample string 5",
      "Brand": "sample string 6",
      "CardType": "sample string 7"
    },
    {
      "id": 1,
      "nome": "sample string 2",
      "tipo": "sample string 3",
      "cartao_id": 4,
      "CardNumber": "sample string 5",
      "Brand": "sample string 6",
      "CardType": "sample string 7"
    }
  ],
  "busca": [
    {
      "cod_barras": "sample string 1",
      "descricao": "sample string 2",
      "preco": 3.0
    },
    {
      "cod_barras": "sample string 1",
      "descricao": "sample string 2",
      "preco": 3.0
    }
  ]
}

application/xml, text/xml

Sample:
<carrinhoPOSTRetModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ShopperREST.Models">
  <busca>
    <buscaModel>
      <cod_barras>sample string 1</cod_barras>
      <descricao>sample string 2</descricao>
      <preco>3</preco>
    </buscaModel>
    <buscaModel>
      <cod_barras>sample string 1</cod_barras>
      <descricao>sample string 2</descricao>
      <preco>3</preco>
    </buscaModel>
  </busca>
  <carrinho_id>3</carrinho_id>
  <depende>
    <dependeLojaModel>
      <Brand>sample string 6</Brand>
      <CardNumber>sample string 5</CardNumber>
      <CardType>sample string 7</CardType>
      <cartao_id>4</cartao_id>
      <id>1</id>
      <nome>sample string 2</nome>
      <tipo>sample string 3</tipo>
    </dependeLojaModel>
    <dependeLojaModel>
      <Brand>sample string 6</Brand>
      <CardNumber>sample string 5</CardNumber>
      <CardType>sample string 7</CardType>
      <cartao_id>4</cartao_id>
      <id>1</id>
      <nome>sample string 2</nome>
      <tipo>sample string 3</tipo>
    </dependeLojaModel>
  </depende>
  <itens>
    <itensCarrinhoModel>
      <apelido>sample string 2</apelido>
      <cod_barras>sample string 1</cod_barras>
      <foto>sample string 6</foto>
      <qtde>3</qtde>
      <total>5</total>
      <unidade>sample string 7</unidade>
      <unitario>4</unitario>
    </itensCarrinhoModel>
    <itensCarrinhoModel>
      <apelido>sample string 2</apelido>
      <cod_barras>sample string 1</cod_barras>
      <foto>sample string 6</foto>
      <qtde>3</qtde>
      <total>5</total>
      <unidade>sample string 7</unidade>
      <unitario>4</unitario>
    </itensCarrinhoModel>
  </itens>
  <mensagem>sample string 2</mensagem>
  <status>sample string 1</status>
  <tipo>porta</tipo>
  <total>4</total>
</carrinhoPOSTRetModel>