Search in documentation
ctrl+4K
Modules
Authentication
Merchant
Catalog
Order
Events
Logistics
Shipping
Review
Financial
Solutions

Order negotiation platform

Negotiate post-delivery issues with customers — cancellations, returns, refunds through mediated proposals.
  1. Consume HANDSHAKE_DISPUTE via polling or webhook
  2. Respond with /accept, /reject, or /alternative before expiresAt
  3. Process HANDSHAKE_SETTLEMENT confirming resolution
Requirements:
  • You must respond to every dispute — no response activates timeoutAction automatically
  • One response per disputeId (not reusable)
  • Analyze each negotiation individually
  • After delivery: Full or partial cancellation request
  • During preparation: Full cancellation request
  • Late delivery: Cancellation or time extension request
  • Reshipment: Missing items (experimental)
See implementation guide for workflow examples.
Entity sent in HANDSHAKE_DISPUTE event containing negotiation, requested action, evidence, deadline, and automatic timeout action. Includes DisputeAlternative for refunds and Item/GarnishItem for partial cancellations.Identification and context
AttributeDescriptionTypeRequired
idNegotiation IDuuid
parentDisputeIdOriginal negotiation ID (if counteroffer)uuid
createdAtCreation timestampDateTime
messageCustomer justificationString
Negotiation type
AttributeDescriptionTypeRequired
actionNegotiation purposeString
handshakeTypeNegotiation typeString
handshakeGroupClassificationString
Valid values for action:
  • CANCELLATION — Full cancellation
  • PARTIAL_CANCELLATION — Partial cancellation
  • PROPOSED_AMOUNT_REFUND — Proposed refund
  • PROPOSED_ADDITIONAL_TIME — Proposed time extension
  • VOID — No action
Valid values for handshakeType:
  • AFTER_DELIVERY — Cancellation after customer receives
  • DELAY — Cancellation due to late delivery
  • PREPARATION_TIME — Cancellation during preparation
  • AFTER_DELIVERY_PARTIALLY — Partial cancellation after delivery
Deadline and automation
AttributeDescriptionTypeRequired
expiresAtResponse deadlineDateTime
timeoutActionAction if no responseString
Valid values for timeoutAction:
  • ACCEPT_CANCELLATION — Auto-accept cancellation
  • REJECT_CANCELLATION — Auto-reject cancellation
  • VOID — No automatic action
Negotiation content
AttributeDescriptionTypeRequired
alternativesAvailable response optionsList of DisputeAlternative
metadata.itemItems for partial cancellationList of Item
metadata.garnishItemsSub-items (add-ons)List of GarnishItem
metadata.evidencesPhotos/media from customerList of Media
metadata.acceptCancellationReasonsValid reasons to acceptList of String
Entity sent in HANDSHAKE_SETTLEMENT event containing resolution status and reason. Includes SelectedDisputeAlternative for accepted counteroffers.
AttributeDescriptionTypeRequired
idSettlement IDuuid
disputeIdResolved negotiation IDuuid
statusFinal resultString
reasonRejection justificationString
selectedDisputeAlternativeCounteroffer (if status = ALTERNATIVE_REPLIED)SelectedDisputeAlternative
Valid values for status:
  • ACCEPTED — Negotiation accepted
  • REJECTED — Negotiation rejected
  • EXPIRED — No response until deadline
  • ALTERNATIVE_REPLIED — Counteroffer sent and accepted
Alternative resolution options accompanying HandshakeDispute. Valid values for type: REFUND, BENEFIT, ADDITIONAL_TIME.
AttributeDescriptionTypeRequired
idAlternative IDuuid
typeResolution typeString
metadata.maxAmountMaximum amount (REFUND/BENEFIT)AmountCond
metadata.allowedsAdditionalTimeInMinutesTime extension options (minutes)List of IntCond
metadata.allowedsAdditionalTimeReasonsDelay reasonsList of StringCond
Accepted counteroffer accompanying HandshakeSettlement. Valid values for type: REFUND, BENEFIT, ADDITIONAL_TIME.
AttributeDescriptionTypeRequired
idAlternative IDuuid
typeResolution typeString
metadata.amountAmount (REFUND/BENEFIT)AmountCond
metadata.additionalTimeInMinutesTime extensionintCond
metadata.reasonDelay reasonStringCond
Photo sent by customer.
AttributeType
urlString (requires authentication)
contentTypeString (MIME type)
Item for partial cancellation.
AttributeType
iduuid
uniqueIduuid
externalCodeString
quantityint
indexint
amountAmount
reasonString
Sub-item (add-on) for partial cancellation.
AttributeType
iduuid
parentUniqueIduuid
externalCodeString
quantityint
indexint
amountAmount
reasonString
Monetary value per ISO 4217.
AttributeDescriptionType
valueAmount without decimals ($1.00 = 100)String
currencyCurrency code (ex: USD)String

ValueDescription
AFTER_DELIVERYCancellation after customer received
DELAYCancellation for late delivery
PREPARATION_TIMECancellation during preparation
AFTER_DELIVERY_PARTIALLYPartial cancellation after delivery
ValueDescription
CUSTOMER_ORDER_SUPPORTCustomer-initiated negotiation
ValueDescription
CANCELLATIONFull cancellation
PARTIAL_CANCELLATIONPartial cancellation
PROPOSED_AMOUNT_REFUNDCancellation with refund option
ValueAction
ACCEPT_CANCELLATIONCancel automatically
REJECT_CANCELLATIONReject cancellation automatically
VOIDNo automatic action
ValueDescription
ACCEPTEDNegotiation accepted
REJECTEDNegotiation rejected
EXPIREDNo response before deadline
ALTERNATIVE_REPLIEDCounteroffer sent and accepted
ValueDescription
REFUNDMoney refund
BENEFITCredit/benefit
ADDITIONAL_TIMETime extension
Reasons for negotiation decisions. Use in request bodies when required.
ReasonContext
HIGH_STORE_DEMANDStore at capacity
UNKNOWN_ISSUEUnspecified issue
CUSTOMER_SATISFACTIONCustomer service
INVENTORY_CHECKAvailability verification
SYSTEM_ISSUETechnical issue
WRONG_ORDERIncorrect order
PRODUCT_QUALITYQuality concern
LATE_DELIVERYLate delivery
CUSTOMER_REQUESTCustomer request
POST https://merchant-api.ifood.com.br/order/v1.0/disputes/{disputeId}/acceptParameters:
NameTypeDescription
disputeIduuidDispute ID (URL)
reasonstringReason from metadata.acceptCancellationReasons
detailReasonstringDescription (250 chars max)
Request example:
curl -X POST "https://merchant-api.ifood.com.br/order/v1.0/disputes/dispute_001/accept" \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -d '{"reason": "CUSTOMER_SATISFACTION", "detailReason": "Refund for courtesy"}'
Response (201 Created):
{
  "id": "settlement_001",
  "status": "ACCEPTED",
  "disputeId": "dispute_001",
  "createdAt": "2024-04-25T18:05:00Z"
}
Common errors:
StatusCodeReason
401-Invalid token
404DISPUTE_NOT_FOUNDDispute not found
422DISPUTE_ALREADY_ANSWEREDAlready answered
400INVALID_REASONInvalid reason
POST https://merchant-api.ifood.com.br/order/v1.0/disputes/{disputeId}/rejectParameters:
NameTypeDescription
disputeIduuidDispute ID (URL)
reasonstringReason from negotiationReasons
Request example:
curl -X POST "https://merchant-api.ifood.com.br/order/v1.0/disputes/dispute_002/reject" \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -d '{"reason": "INVENTORY_CHECK"}'
Response (201 Created):
{
  "id": "settlement_002",
  "status": "REJECTED",
  "disputeId": "dispute_002",
  "createdAt": "2024-04-25T18:08:00Z"
}
Common errors:
StatusCodeReason
401-Invalid token
404DISPUTE_NOT_FOUNDDispute not found
422DISPUTE_ALREADY_ANSWEREDAlready answered
400INVALID_REASONInvalid reason
POST https://merchant-api.ifood.com.br/order/v1.0/disputes/{disputeId}/alternativeParameters:
NameTypeDescription
disputeIduuidDispute ID (URL)
typestringREFUND, BENEFIT or ADDITIONAL_TIME
metadata.amountAmountAmount (REFUND/BENEFIT)
metadata.additionalTimeInMinutesintMinutes (ADDITIONAL_TIME)
metadata.reasonstringDelay reason (ADDITIONAL_TIME)
Examples by type:
curl -X POST "https://merchant-api.ifood.com.br/order/v1.0/disputes/dispute_001/alternative" \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "REFUND",
    "metadata": {
      "amount": {
        "value": "5000",
        "currency": "BRL"
      }
    }
  }'
Response (201 Created):
{
  "id": "settlement_003",
  "status": "ALTERNATIVE_REPLIED",
  "disputeId": "dispute_003",
  "selectedDisputeAlternative": {
    "id": "alt_001",
    "type": "ADDITIONAL_TIME",
    "metadata": {
      "additionalTimeInMinutes": 30,
      "reason": "HIGH_STORE_DEMAND"
    }
  },
  "createdAt": "2024-04-25T18:12:00Z"
}
Common errors:
StatusCodeReason
401-Invalid token
404DISPUTE_NOT_FOUNDDispute not found
422DISPUTE_ALREADY_ANSWEREDAlready answered
400INVALID_AMOUNTAmount out of range

ScenariohandshakeTypeactionResponses
Full after deliveryAFTER_DELIVERYCANCELLATIONAccept / Reject / REFUND
Full during preparationPREPARATION_TIMECANCELLATIONAccept / Reject
Full (late)DELAYCANCELLATIONAccept / Reject / ADDITIONAL_TIME
Partial after deliveryAFTER_DELIVERY_PARTIALLYPARTIAL_CANCELLATIONAccept / Reject / REFUND
See implementation guide for complete examples.
If no response before expiresAt, timeoutAction executes:
  • ACCEPT_CANCELLATION: Order canceled
  • REJECT_CANCELLATION: Cancellation rejected
  • VOID: No action
Generates HANDSHAKE_SETTLEMENT with status: EXPIRED.
Published when customer initiates eligible negotiation (cancellation meeting criteria).Event structure
AttributeType
idstring
codestring (always "HSD")
fullCodestring (always "HANDSHAKE_DISPUTE")
orderIduuid
merchantIduuid
createdAtDateTime
metadataHandshakeDispute
Examples by scenario:
{
  "id": "evt_001",
  "code": "HSD",
  "fullCode": "HANDSHAKE_DISPUTE",
  "orderId": "ord_12345",
  "merchantId": "merchant_001",
  "createdAt": "2024-04-25T18:02:46.921Z",
  "metadata": {
    "id": "dispute_001",
    "action": "CANCELLATION",
    "handshakeType": "AFTER_DELIVERY",
    "handshakeGroup": "CUSTOMER_ORDER_SUPPORT",
    "message": "Food arrived cold",
    "expiresAt": "2024-04-25T18:09:46Z",
    "timeoutAction": "REJECT_CANCELLATION",
    "createdAt": "2024-04-25T18:02:46Z",
    "alternatives": [
      {
        "id": "alt_001",
        "type": "REFUND",
        "metadata": {
          "maxAmount": {
            "currency": "BRL",
            "value": "5000"
          }
        }
      }
    ],
    "acceptCancellationReasons": ["PRODUCT_QUALITY", "CUSTOMER_SATISFACTION"],
    "evidences": [
      {
        "url": "https://merchant-api.ifood.com.br/orders/ord_12345/evidences/abc123",
        "contentType": "image/jpeg"
      }
    ]
  }
}
Published when negotiation resolves (accepted, rejected, counteroffer, or timeout).Event structure
AttributeType
idstring
codestring (always "HSS")
fullCodestring (always "HANDSHAKE_SETTLEMENT")
orderIduuid
merchantIduuid
createdAtDateTime
metadataHandshakeSettlement
Examples by outcome:
{
  "id": "evt_settlement_001",
  "code": "HSS",
  "fullCode": "HANDSHAKE_SETTLEMENT",
  "orderId": "ord_12345",
  "merchantId": "merchant_001",
  "createdAt": "2024-04-25T18:05:00Z",
  "metadata": {
    "id": "settlement_001",
    "disputeId": "dispute_001",
    "status": "ACCEPTED",
    "reason": "CUSTOMER_SATISFACTION",
    "createdAt": "2024-04-25T18:05:00Z"
  }
}
Was this page helpful?
Rate your experience in the new Developer portal: