Purchase

The Purchase endpoint enables the RentalCover.com server to book a quoted policy based on the parameters provided.

A previously generated quote must be created before a purchase can be made, the reference for this quote is passed in the AgentReference field.

Currency Code is not supported in Purchase request. If Currency code is used, it will be ignored.

The purchase request sent after modification is different to the purchase request sent after Quote. If an auto re-bill feature is enabled for a partner, the following fields are optional during the Purchase Request: CardHolder, CardNumber, CardExpiry, CardSecurityCode.

Endpoint: /insurances/purchase

Method: POST

Optional Endpoint:/insurances/purchase/<reference:[A-Z0-9\-]+>

Optional Endpoint is to be used if AgentReference is your reference, in this case the Policy reference is passed within the URL.

curl -i -X POST \
-H "X_API_KEY: [my-api-key]" \
-H "Content-Type: application/json" \
-d '{"AgentReference":"AB12-345C-INS","PolicyCode":"RC001","FromDate":"2014-12-17 00:00:00","ToDate":"2014-12-19 00:00:00", "CustomerAge":21, "DestinationCountry":"AU", "FirstName":"Jack", "LastName":"Smith","Address1":"21 This Street","City":"Sydney","Email":"[email protected]","Country":"AU","CardHolder":"TEST TEST","CardNumber":"4111111111111111","CardExpiry":"1216","CardSecurityCode":"111"}' \
https://api-staging.rentalcover.com/insurances/purchase

Request Parameters

Response Attributes

Note that response properties with the text Formatted appended are formatted with the relevant currency code and symbol.

Last updated