Create Insurance Offer
Creates a new insurance offer for a declaration in the system.
Request
POST /api/v1/declarations/{declaration_id}/insurances
Parameters
| Name | Type | In | Description |
|---|---|---|---|
declaration_id | string | path | Required. The ID of the declaration |
username | string | body | Required. Insurance provider username |
password | string | body | Required. Insurance provider password |
owner_identity_number | string | body | Required. Identity number of the policy owner |
policy_number | string | body | Required. Policy number |
policy_renewal_number | number | body | Required. Policy renewal number |
policy_currency_type | string | body | Required. Currency type of the policy (e.g., USD) |
policy_asset_description | string | body | Required. Description of the asset in policy |
policy_reference_number | string | body | Required. Reference number of the policy |
flotan_policy_number | string | body | Optional. Flotan policy number |
asset_value | number | body | Required. Value of the asset |
asset_value_currency_type | string | body | Required. Currency type of the asset value |
asset_description_english | string | body | Required. English description of the asset |
is_asset_used | boolean | body | Required. Whether the asset is used |
transport_license_plate | string | body | Required. License plate of the transport vehicle |
goods_to_be_printed_on_policy | string | body | Required. Goods description to be printed on policy |
from_country | string | body | Required. Country of origin |
from_city | string | body | Required. City of origin |
from_region | string | body | Required. Region of origin |
to_country | string | body | Required. Destination country |
to_city | string | body | Required. Destination city |
to_region | string | body | Required. Destination region |
transport_type | string | body | Required. Type of transport |
transport_vehicle_count | number | body | Required. Number of transport vehicles |
loading_date | string | body | Required. Loading date (YYYY-MM-DD) |
beneficiary_name | string | body | Optional. Name of the beneficiary |
letter_of_credit_number | string | body | Optional. Letter of credit number |
imo_number | string | body | Optional. IMO number |
policy_description_turkish | string | body | Required. Turkish description of the policy |
policy_description_english | string | body | Required. English description of the policy |
Headers
| Name | Description |
|---|---|
Authorization | Required. Bearer token for authentication |
Content-Type | Required. Must be application/json |
X-Target-Server | Required. Target server identifier |
Example
curl --request POST \
--url '{{HOST}}/api/v1/declarations/67db101b6f7e65dcdd379d6f/insurances' \
--header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...' \
--header 'Content-Type: application/json' \
--header 'X-Target-Server: declaration' \
--data '{
"username": "A4882222",
"password": "NKL123456!",
"owner_identity_number": "3241047192",
"policy_number": "1077607962",
"policy_renewal_number": 0,
"policy_currency_type": "USD",
"policy_asset_description": "Policeye Basilacak Emtia",
"policy_reference_number": "24-00025",
"flotan_policy_number": "",
"asset_value": 1000,
"asset_value_currency_type": "USD",
"asset_description_english": "Personal belongings and electronics",
"is_asset_used": false,
"transport_license_plate": "34ABC123",
"goods_to_be_printed_on_policy": "Policeye Basilacak Emtia",
"from_country": "ÇİN",
"from_city": "WOHAM",
"from_region": "WOHAM",
"to_country": "TÜRKİYE",
"to_city": "ISTANBUL",
"to_region": "AHL",
"transport_type": "vehicle",
"transport_vehicle_count": 1,
"loading_date": "2025-05-20",
"beneficiary_name": "",
"letter_of_credit_number": "",
"imo_number": "",
"policy_description_turkish": "Kişisel eşyalar ve elektronik ürünler için sigorta poliçesi",
"policy_description_english": "Insurance policy for personal belongings and electronics"
}'
Response
A successful request returns an HTTP 200 status code with "OK" response.
Status Codes
| Status Code | Description |
|---|---|
| 200 | Success |
| 400 | Bad Request - Invalid parameters |
| 401 | Unauthorized - Invalid or missing authentication token |
| 404 | Not Found - Declaration ID does not exist |
| 500 | Internal Server Error |
Notes
After submitting the insurance offer request, you can track its status using the insurance offer search endpoint.