Send Warranty with Product Code
With this service, you can send a warranty using the product code instead of merchantProductId.
For most use cases, we recommend using the Send Warranty with Invoice endpoint instead. It automatically creates products if they don't exist, supports multiple products in a single request, and provides extended warranty support.
This endpoint requires a pre-registered product with a matching productCode. You can create products using the Product Creation service, or use the invoice endpoint which handles product creation automatically.
We recommend keeping externalOrderId unique in your system, because this value is used later to query or delete the warranty. The API does not enforce it: sending the same externalOrderId again creates an additional warranty, and the lookup endpoint then returns more than one warranty ID. See External Order ID uniqueness for details.
If you send externalLineId, it must not already be registered for your merchant account. A previously used value is rejected with HTTP 400 and code 4093.
This endpoint is rate-limited per merchant. Exceeding the limit returns an HTTP 429 Too Many Requests response. If you need a higher limit for your integration, contact us at info@egaranti.com.
Request
curl --location --request POST '<BASE_URL>/individual-customers/warranty/with-product-code' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <jwtToken>' \
--data '{
"productCode": "PRD-001",
"firstName": "John",
"lastName": "Doe",
"email": "john.doe@example.com",
"phone": "+905551234567",
"countryCode": "TR",
"externalOrderId": "ORD-12345",
"externalLineId": "LINE-001",
"purchaseDate": "15-01-2024 10:30",
"warrantyExpireDate": "15-01-2026 10:30",
"invoiceDate": "14-01-2024 16:45",
"invoiceNumber": "FTR-2024-000123"
}'
Here are examples of acceptable phone number formats:
544 333 22 115443332211+90544333221190544333221105443332211
The formats for the purchaseDate, invoiceDate and warrantyExpireDate parameters must be: dd-MM-yyyy HH:mm (e.g., 01-01-2023 00:00).
purchaseDatebecomes the warranty start date. If it is not provided, today's date is used.- If
warrantyExpireDateis not provided, it will be calculated based on the product's warranty period. invoiceDateandinvoiceNumberrecord the sales invoice. They are stored as-is and do not affect the warranty dates — send them when the invoice date differs from the date the warranty should start.
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
| productCode | String | Yes | Unique product code (e.g., "PRD-001") |
| firstName | String | Yes | Customer first name (e.g., "John") |
| lastName | String | Yes | Customer last name (e.g., "Doe") |
| externalOrderId | String | Yes | External order ID from your system (e.g., "ORD-12345") |
| countryCode | Enum | No | Country code for the phone number (default: TR) |
| String | No | Customer email (e.g., "john.doe@example.com") | |
| phone | String | No | Customer phone (e.g., "+905551234567") |
| externalLineId | String | No | Line item ID from your system (e.g., "LINE-001") |
| identificationNumber | String | No | Customer ID number (e.g., "12345678901") |
| birthDate | String | No | Customer birth date (format: dd-MM-yyyy, e.g., "15-06-1990") |
| purchaseDate | String | No | Purchase date (format: dd-MM-yyyy HH:mm). Used as the warranty start date. |
| invoiceDate | String | No | Sales invoice date (format: dd-MM-yyyy HH:mm) |
| invoiceNumber | String | No | Sales invoice number (e.g., "FTR-2024-000123") |
| warrantyExpireDate | String | No | Warranty expiration date (format: dd-MM-yyyy HH:mm) |
TR // Turkey
US // United States
DE // Germany
GB // United Kingdom
AE // United Arab Emirates
NL // Netherlands
FR // France
UZ // Uzbekistan
Response
{
"individualCustomerProductId": 12345
}
Error Cases
| HTTP Status | Code | Description |
|---|---|---|
| 400 | 4093 | The externalLineId is already registered for your merchant account by an earlier request. Use a new value. |
| 429 | - | The per-merchant rate limit has been exceeded. Retry later or request a higher limit. |
externalOrderId has no error case of its own: duplicate values are accepted and create additional warranties. See External Order ID uniqueness.
Example
{
"productCode": "LAPTOP-LENOVO-001",
"firstName": "Mehmet",
"lastName": "Kaya",
"email": "mehmet.kaya@example.com",
"phone": "5421234567",
"countryCode": "TR",
"externalOrderId": "INV-2024-0042",
"externalLineId": "LINE-001",
"purchaseDate": "25-01-2024 16:45"
}