Create offer
POST
/Request body
application/jsoncustomerCustomerrequiredShow propertiesHide properties
firstNamestringrequiredFirst name of the customer
min length 1 · max length 100
lastNamestringrequiredLast name of the customer
min length 1 · max length 100
emailstring<email>requiredValid email address of the customer
phonestringrequiredCustomer contact phone number in international format
matches ^\+?[\d\s-()]{10,}$
addressobjectrequiredDelivery address details
Show propertiesHide properties
line1stringrequiredmin length 1 · max length 100
line2stringmin length 1 · max length 100
citystringrequiredmin length 1 · max length 100
stateOrProvincestringrequiredmin length 2 · max length 2
postalCodestringrequiredmatches ^\d{5}(-\d{4})?$
productobjectrequiredReplacement product and add-ons covered by warranty
Show propertiesHide properties
skustringrequiredProduct SKU
addonsobject[]Optional add-ons for the product. Each entry must specify at least one of id or sku. Use `id` for aggregate add-on groups (like Install or Disposal) and `sku` for individual recommended parts or add-on products.
Show propertiesHide properties
Array of
objectidstringThe id of an aggregate add-on group (e.g. Install, Disposal). Use the parent group id from the `addOns` array returned by GET /products/{sku}.
skustringThe sku of an individual add-on product or recommended part. Use the sku from the `recommendedParts` array returned by GET /products/{sku}.
quantityintegerrequiredsendOfferImmediatelybooleanWhether to send the offer email immediately after creation
default: true
allowCommonCarrierbooleanWhether to allow offers for common carrier delivery properties
default: true
externalJobIDstringbuyoutAmountnumberBuyout amount in cents (e.g., 50000 = $500.00). Customer can opt to receive this amount instead of a replacement product.
min 0
includeUpsellsbooleanWhether to include upsells in the offer
default: true
allowExistingOfferbooleanCreating an offer for an externalJobID that already has an active (pending or awaiting-customer) offer is rejected with DUPLICATE_ACTIVE_OFFER unless this is true, confirming the duplicate is intentional.
default: false
subBrandIdstringrequiredThe ID of the sub-brand used to determine customer-facing branding for the offer
Responses
201Offer created successfully
idstringrequiredUnique identifier for the offer
addressobjectrequiredShow propertiesHide properties
line1stringrequiredmin length 1 · max length 100
line2stringmin length 1 · max length 100
citystringrequiredmin length 1 · max length 100
stateOrProvincestringrequiredmin length 2 · max length 2
postalCodestringrequiredmatches ^\d{5}(-\d{4})?$
countrystringrequiredCountry of the property address
createdAtstring<date-time>requiredTimestamp when the offer was created
customerOfferLinkstringrequiredLink to allow the customer to authenticate and view the offer
warningsstring[]Warnings for the offer
400Bad request - Invalid input data
codestringrequiredError code indicating the type of error
messagestringrequiredHuman-readable error message explaining what went wrong
detailsobject[]Detailed validation errors when applicable
Show propertiesHide properties
Array of
objectfieldstringrequirederrorstringrequired401Unauthorized - Missing or invalid authentication
codestringrequiredError code indicating the type of error
messagestringrequiredHuman-readable error message explaining what went wrong
detailsobject[]Detailed validation errors when applicable
Show propertiesHide properties
Array of
objectfieldstringrequirederrorstringrequired409Conflict - an active offer already exists for the provided externalJobID. Retry with allowExistingOffer: true to confirm the duplicate is intentional.
codestringrequiredAn active offer already exists for the provided externalJobID
Allowed:
DUPLICATE_ACTIVE_OFFERmessagestringrequiredexistingOfferIdsstring[]requiredIDs of the active offers already associated with the externalJobID, most recent first
500Internal server error
codestringrequiredError code indicating the type of error
messagestringrequiredHuman-readable error message explaining what went wrong
detailsobject[]Detailed validation errors when applicable
Show propertiesHide properties
Array of
objectfieldstringrequirederrorstringrequiredRequest
curl -X POST "https://api.sibipro.com/prod/offers/" \
-H "Content-Type: application/json" \
-d '{
"customer": {
"firstName": "John",
"lastName": "Doe",
"email": "john@example.com",
"phone": "+1 (123) 456-7890"
},
"address": {
"line1": "123 Main St",
"line2": "Apt 101",
"city": "Springfield",
"stateOrProvince": "IL",
"postalCode": "62701"
},
"product": {
"sku": "GDF511PGRBB",
"addons": [
{
"id": "install-aggregate-id",
"quantity": 1
},
{
"sku": "M007",
"quantity": 1
},
{
"sku": "M021",
"quantity": 1
}
]
},
"sendOfferImmediately": true,
"allowCommonCarrier": true,
"externalJobID": "string",
"buyoutAmount": 50000,
"includeUpsells": true,
"allowExistingOffer": false,
"subBrandId": "string"
}'const response = await fetch("https://api.sibipro.com/prod/offers/", {
method: "POST",
headers: {
"Content-Type": "application/json"
},
body: JSON.stringify({
"customer": {
"firstName": "John",
"lastName": "Doe",
"email": "john@example.com",
"phone": "+1 (123) 456-7890"
},
"address": {
"line1": "123 Main St",
"line2": "Apt 101",
"city": "Springfield",
"stateOrProvince": "IL",
"postalCode": "62701"
},
"product": {
"sku": "GDF511PGRBB",
"addons": [
{
"id": "install-aggregate-id",
"quantity": 1
},
{
"sku": "M007",
"quantity": 1
},
{
"sku": "M021",
"quantity": 1
}
]
},
"sendOfferImmediately": true,
"allowCommonCarrier": true,
"externalJobID": "string",
"buyoutAmount": 50000,
"includeUpsells": true,
"allowExistingOffer": false,
"subBrandId": "string"
})
});Response
{
"id": "testofferid",
"address": {
"line1": "string",
"line2": "string",
"city": "string",
"stateOrProvince": "string",
"postalCode": "string",
"country": "USA"
},
"createdAt": "2024-01-20T12:00:00Z",
"customerOfferLink": "string",
"warnings": [
"This product is only available via common carrier delivery for the selected address."
]
}{
"code": "string",
"message": "The request contains invalid parameters",
"details": [
{
"field": "customer.email",
"error": "Invalid email"
},
{
"field": "address.postalCode",
"error": "Invalid"
}
]
}{
"code": "string",
"message": "The request contains invalid parameters",
"details": [
{
"field": "customer.email",
"error": "Invalid email"
},
{
"field": "address.postalCode",
"error": "Invalid"
}
]
}{
"code": "DUPLICATE_ACTIVE_OFFER",
"message": "An active offer already exists for this job",
"existingOfferIds": [
"_0hVkXc6QX8OzW6kBnoNg"
]
}{
"code": "string",
"message": "The request contains invalid parameters",
"details": [
{
"field": "customer.email",
"error": "Invalid email"
},
{
"field": "address.postalCode",
"error": "Invalid"
}
]
}