Refresh an application alteration package

Re-quotes a pending application alteration package against the application's current product module definition and replaces it. The new package is created with refreshed_from_alteration_package_id set to the original, and the original is archived. If quoting fails, nothing is archived and the original stays pending.

The original's input is replayed: data from the request body if present, otherwise the data the original was created with.

A refresh is only sound when the alteration hook's validation accepts its own output unchanged, and when the hook reads no application data other than monthly_premium, sum_assured, billing_frequency and the module keys the package carries.

Issued and cancelled applications can't be refreshed.

Path Params
string
required

Must be a UUID. The unique identifier of the application.

string
required

Must be a UUID. The ID of the pending application alteration package to refresh.

Query Params
string

To perform an idempotent request, provide the idempotency_key query parameter with the request. An idempotency key is a unique value generated by the client which the platform uses to recognize subsequent retries of the same request. How you create unique keys is up to you, but we suggest using a V4 UUID, or another random string with enough entropy to avoid collisions. Idempotency keys can be up to 255 characters long.

Body Params
data
object

Replaces the stored input for this refresh. When omitted, the data the original package was created with is replayed. An empty object is replayed as an empty object.

boolean

If true, the new alteration package is applied to the application after it is created. If applying fails, the new package stays pending and the error names its ID.

Responses

400

The package is not pending, the application is issued or cancelled, the alteration hook is not in the application's current product module definition, the stored input failed validation, the product module returned other than one alteration package, or the currency changed. The original stays pending.

404

The alteration package was not found, it is archived, or it belongs to another application.

409

Another request superseded, archived or applied the package first. When another refresh won, the message names the alteration package that replaced it.

Language
Credentials
Basic
base64
:
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json