Build

This operation enables building draft provider pricing clauses in a pricing worksheet. For more details on building draft provider clauses please see Draft Provider Pricing Clauses Worksheet

The pricingworksheet resource offers a build link.

 ... pricing worksheet properties ...
 "links": [
    {
      "href": "http://<host>:<port>/api/generic/pricingworksheets/",
      "rel": "self"
    },
    {
      "href": "http://<host>:<port>/api/pricingworksheets/<pricingworksheet_code>/build",
      "rel": "pricingworksheet:build",
      "httpMethod": "POST"
    }
  ]
}

Clients can send in one or more draft provider pricing clauses in the POST payload, if the client does not include a list of draft provider pricing clauses, all draft provider pricing clauses in the pricingWorksheet are built:

{
  "draftProviderPricingClauseList": [
     {"code": ""},
     {"code": ""}
      ..
  ]
}

The build operation validates and builds draft provider pricing clauses. If the request specifies draft provider pricing clause codes, only the draft prover pricing clauses with specified codes are processed otherwise the complete worksheet is validated. If a draft provider pricing clause with the specified code is not found within the context of the pricing sheet, the system creates an interface message " Draft provider pricing clause with {code} not found" for each such codes.

The build operation (re-)validates each draft provider pricing clause in context before creating a provider pricing clause for it, also those that already have the status Valid. This validation is identical to the validation in the Validate operation.

For details on the build function refer to Build Draft Provider Pricing Clauses

The request header parameter "continue_when_invalid" determines if the system stops the build operation when it finds an invalid draft provider pricing clause or that it continues with the building of valid draft provider pricing clause into provider pricing clauses. When set to true, the operation continues, when false the operation stops if there is at least one draft provider pricing clause that is invalid from the list of draft provider pricing clauses being processed.

Response Messages

Success

The system responds with 201 created. The system also returns a link to the task resource in the Location header:
Location:http://[hostName]:[portNumber]/[api-context-root]/claims/generic/task/<id> This enables the external system to track the progress by issuing a GET to this task URI.

Failure

Following Http Status code can be returned in case of error.

Table 1. Failure
Response Description

HTTP 401

Unauthorized

HTTP 404

Pricing worksheet is unknown

Please refer to the "Response Messages" section in the HTTP API Integration Points part of the Common Features book for more details.

Authorization

The operation in this section is protected by access restriction "pricingworksheets.build IP". A grant must be given with both the Read and Update flag set.