POST api/CostEstimate/Get

Get a cost estimate on a activity

Exceptions

ExceptionCondition
UnauthorizedHttpResponseException

If ticket cannot be validated or if you do not have access to activity

ArgumentNullHttpResponseException

If any arguments are null

ArgumentOutOfRangeHttpResponseException

If any arguments out for range

Examples

The sample below show how to setup a call the Get cost estimate




var arg = {
    TicketId : "71137607-4587-44C9-BE92-A699180E42C9",
    CombinedActivityId : "sesam10:1234567"
}
$.ajax({
    url: 'https://api.infocare.com/api/CostEstimate/Get',                    
    type: "POST",
    data: JSON.stringify(arg),
    contentType: "application/json;charset=utf-8"
})
.done(function (result) {
    // you should now iterate through the result to get all values used in a cost estimate, but
    // we just print returned activity number to the console
    console.log("got activity, id: " + result.CombinedActivityId);
})
.fail(function (jqXHR, textStatus, err) {
    console.log("getting activity failed: " + err);
})

Request Information

URI Parameters

None.

Body Parameters

Identifies the activity to retrieve, specify the CostEstimateController.CostEstimateArgumentModel.CombinedActivityId property

CostEstimateArgumentModel
NameDescriptionTypeAdditional information
CombinedActivityId

Gets or sets the criteria.

string

None.

FeedBackStatus

string

None.

TicketId

Gets or sets the ticket id

string

None.

Culture

Gets or sets culture, if not specified we will use culture set on user.

string

None.

Request Formats

application/json, text/json

Sample:
{
  "CombinedActivityId": "sample string 1",
  "FeedBackStatus": "sample string 2",
  "TicketId": "sample string 3",
  "Culture": "sample string 4"
}

application/xml, text/xml

Sample:
<CostEstimateController.CostEstimateArgumentModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Rostov.Controllers">
  <Culture xmlns="http://schemas.datacontract.org/2004/07/Rostov.Models">sample string 4</Culture>
  <TicketId xmlns="http://schemas.datacontract.org/2004/07/Rostov.Models">sample string 3</TicketId>
  <CombinedActivityId>sample string 1</CombinedActivityId>
  <FeedBackStatus>sample string 2</FeedBackStatus>
</CostEstimateController.CostEstimateArgumentModel>

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

Response Information

Resource Description

An activity if found, Null otherwise

CostEstimateModel
NameDescriptionTypeAdditional information
CombinedActivityId

string

None.

CustomerName

string

None.

WarrantyReference

string

None.

SpecialReference

string

None.

CustomerReference

string

None.

ProductName

string

None.

ProductDescription

string

None.

ProductBrand

string

None.

ProblemDescription

string

None.

CostEstimateComment

string

None.

CurrentStatus

CostEstimateStatus

None.

ValidStatus

Collection of string

None.

CostEstimatePrices

Collection of CostEstimatePriceModel

None.

CombinedPerformanceId

Gets or sets the performance id. If performance monitoring is not turned on this property will not be present or set to null

string

Json null value handling: Ignore

Response Formats

application/json, text/json

Sample:
{
  "CombinedActivityId": "sample string 1",
  "CustomerName": "sample string 2",
  "WarrantyReference": "sample string 3",
  "SpecialReference": "sample string 4",
  "CustomerReference": "sample string 5",
  "ProductName": "sample string 6",
  "ProductDescription": "sample string 7",
  "ProductBrand": "sample string 8",
  "ProblemDescription": "sample string 9",
  "CostEstimateComment": "sample string 10",
  "CurrentStatus": 0,
  "ValidStatus": [
    "sample string 1",
    "sample string 2"
  ],
  "CostEstimatePrices": [
    {
      "Description": "sample string 1",
      "AmountIncVAT": "sample string 2",
      "AmountExclVAT": "sample string 3",
      "Currency": "sample string 4"
    },
    {
      "Description": "sample string 1",
      "AmountIncVAT": "sample string 2",
      "AmountExclVAT": "sample string 3",
      "Currency": "sample string 4"
    }
  ],
  "CombinedPerformanceId": "sample string 11"
}

application/xml, text/xml

Sample:
<CostEstimateModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Rostov.Models">
  <CombinedPerformanceId>sample string 11</CombinedPerformanceId>
  <CombinedActivityId>sample string 1</CombinedActivityId>
  <CostEstimateComment>sample string 10</CostEstimateComment>
  <CostEstimatePrices>
    <CostEstimatePriceModel>
      <AmountExclVAT>sample string 3</AmountExclVAT>
      <AmountIncVAT>sample string 2</AmountIncVAT>
      <Currency>sample string 4</Currency>
      <Description>sample string 1</Description>
    </CostEstimatePriceModel>
    <CostEstimatePriceModel>
      <AmountExclVAT>sample string 3</AmountExclVAT>
      <AmountIncVAT>sample string 2</AmountIncVAT>
      <Currency>sample string 4</Currency>
      <Description>sample string 1</Description>
    </CostEstimatePriceModel>
  </CostEstimatePrices>
  <CurrentStatus>None</CurrentStatus>
  <CustomerName>sample string 2</CustomerName>
  <CustomerReference>sample string 5</CustomerReference>
  <ProblemDescription>sample string 9</ProblemDescription>
  <ProductBrand>sample string 8</ProductBrand>
  <ProductDescription>sample string 7</ProductDescription>
  <ProductName>sample string 6</ProductName>
  <SpecialReference>sample string 4</SpecialReference>
  <ValidStatus xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>sample string 1</d2p1:string>
    <d2p1:string>sample string 2</d2p1:string>
  </ValidStatus>
  <WarrantyReference>sample string 3</WarrantyReference>
</CostEstimateModel>