Skip to main content
POST
Purchase a policy

Authorizations

x-api-key
string
header
required

Body

application/json

For CROP: plotId, sumInsured, coverageType, durationDays are required. For LIVESTOCK: herdId and season are required (sumInsured auto-calculated).

farmerId
string<uuid>
required
productType
enum<string>
default:CROP
Available options:
CROP,
LIVESTOCK
plotId
string<uuid>
herdId
string<uuid>
season
enum<string>
Available options:
LRLD,
SRSD
sumInsured
number
Required range: x >= 1000
coverageType
enum<string>
Available options:
DROUGHT,
FLOOD,
BOTH,
COMPREHENSIVE,
LIVESTOCK_DROUGHT,
LIVESTOCK_DISEASE,
LIVESTOCK_COMPREHENSIVE
durationDays
integer
Required range: 30 <= x <= 365

Response

Created

success
boolean
Example:

true

data
object