POST api/CreditNote

Request Information

URI Parameters

None.

Body Parameters

CreditNote
NameDescriptionTypeAdditional information
CreditNoteNumber

Número da Fatura.

string

None.

CustomerNumber

Número/ID do Cliente enviado pelo Dynamics.

string

None.

OriginSale

Número/ID da Encomenda enviada pelo Dynamics.

string

None.

Observations

Observações da Nota de Crédito

string

None.

Status

Estado da Nota de Crédito.

CreditNoteStatus

None.

TotalAmount

Montante total da Nota de Crédito.

decimal number

None.

CreditNoteProducts

Lista de Produtos da Nota de Crédito.

Collection of CreditNoteProduct

None.

Request Formats

application/json, text/json

Sample:
{
  "CreditNoteNumber": "sample string 1",
  "CustomerNumber": "sample string 2",
  "OriginSale": "sample string 3",
  "Observations": "sample string 4",
  "Status": 1,
  "TotalAmount": 5.0,
  "CreditNoteProducts": [
    {
      "ExistingProduct": true,
      "ProductId": "sample string 2",
      "SerialNumber": "sample string 3",
      "Description": "sample string 4",
      "Quantity": 5,
      "UnitPrice": 6.0,
      "TaxAmount": 7.0,
      "TotalAmount": 8.0
    },
    {
      "ExistingProduct": true,
      "ProductId": "sample string 2",
      "SerialNumber": "sample string 3",
      "Description": "sample string 4",
      "Quantity": 5,
      "UnitPrice": 6.0,
      "TaxAmount": 7.0,
      "TotalAmount": 8.0
    }
  ]
}

application/xml, text/xml

Sample:
<CreditNote xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Hydra.Filtrarte.WebService.Models">
  <CreditNoteNumber>sample string 1</CreditNoteNumber>
  <CreditNoteProducts>
    <CreditNoteProduct>
      <Description>sample string 4</Description>
      <ExistingProduct>true</ExistingProduct>
      <ProductId>sample string 2</ProductId>
      <Quantity>5</Quantity>
      <SerialNumber>sample string 3</SerialNumber>
      <TaxAmount>7</TaxAmount>
      <TotalAmount>8</TotalAmount>
      <UnitPrice>6</UnitPrice>
    </CreditNoteProduct>
    <CreditNoteProduct>
      <Description>sample string 4</Description>
      <ExistingProduct>true</ExistingProduct>
      <ProductId>sample string 2</ProductId>
      <Quantity>5</Quantity>
      <SerialNumber>sample string 3</SerialNumber>
      <TaxAmount>7</TaxAmount>
      <TotalAmount>8</TotalAmount>
      <UnitPrice>6</UnitPrice>
    </CreditNoteProduct>
  </CreditNoteProducts>
  <CustomerNumber>sample string 2</CustomerNumber>
  <Observations>sample string 4</Observations>
  <OriginSale>sample string 3</OriginSale>
  <Status>New</Status>
  <TotalAmount>5</TotalAmount>
</CreditNote>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

ResponseMessage
NameDescriptionTypeAdditional information
Details

Collection of DetailMessage

None.

Response Formats

application/json, text/json

Sample:
{
  "Details": [
    {
      "Cod": 0,
      "Message": "sample string 1"
    },
    {
      "Cod": 0,
      "Message": "sample string 1"
    }
  ]
}

application/xml, text/xml

Sample:
<ResponseMessage xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Hydra.Filtrarte.Plugins.Models">
  <Details>
    <DetailMessage>
      <Cod>OK</Cod>
      <Message>sample string 1</Message>
    </DetailMessage>
    <DetailMessage>
      <Cod>OK</Cod>
      <Message>sample string 1</Message>
    </DetailMessage>
  </Details>
</ResponseMessage>