POST api/v{version}/Providers/me/businesses/{businessId}/servicerequests/{requestId}/finalinvoices

Submit a new Invoice (Final Invoice) for the specified serviceRequest that is belong to current provider and business.

Request Information

URI Parameters

NameDescriptionTypeAdditional information
businessId

integer

Required

requestId

integer

Required

version

string

None.

Body Parameters

AddInvoiceModel
NameDescriptionTypeAdditional information
InvoiceTypeId

InvoiceType

Required

PreInvoiceId

integer

Required

PreInvoiceRowVersion

globally unique identifier

Required

Description

string

None.

InvoiceItems

Collection of AddInvoiceItemModel

None.

Wage

WageModel

None.

Request Formats

application/json, text/json

Sample:
{
  "InvoiceTypeId": 1,
  "PreInvoiceId": 1,
  "PreInvoiceRowVersion": "4f4ce7d0-2e9e-46f4-8a8c-4808f04b7fff",
  "Description": "sample string 1",
  "InvoiceItems": [
    {
      "ServiceId": 1,
      "Price": 1.0,
      "Description": "sample string 1",
      "RowVersion": "sample string 2"
    },
    {
      "ServiceId": 1,
      "Price": 1.0,
      "Description": "sample string 1",
      "RowVersion": "sample string 2"
    }
  ],
  "Wage": {
    "Fee": 1.0
  }
}

application/xml, text/xml

Sample:
<AddInvoiceModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FastFixCore.BindingModels.ServiceRequest">
  <Description>sample string 1</Description>
  <InvoiceItems>
    <AddInvoiceItemModel>
      <Description>sample string 1</Description>
      <Price>1</Price>
      <RowVersion>sample string 2</RowVersion>
      <ServiceId>1</ServiceId>
    </AddInvoiceItemModel>
    <AddInvoiceItemModel>
      <Description>sample string 1</Description>
      <Price>1</Price>
      <RowVersion>sample string 2</RowVersion>
      <ServiceId>1</ServiceId>
    </AddInvoiceItemModel>
  </InvoiceItems>
  <InvoiceTypeId>SameAsPreInvoice</InvoiceTypeId>
  <PreInvoiceId>1</PreInvoiceId>
  <PreInvoiceRowVersion>4f4ce7d0-2e9e-46f4-8a8c-4808f04b7fff</PreInvoiceRowVersion>
  <Wage>
    <Fee>1</Fee>
  </Wage>
</AddInvoiceModel>

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 'AddInvoiceModel'.

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

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

Sample:

Sample not available.