Send the customer's feedback on the order.

Send the customer's feedback on the order.

Note

The method is available only by subscription.

The method for providing a response to a feedback is inside the block Vendor Management Integration API.

Request

POST

/v1/feedback

Body

application/json
{
    "feedback": {
        "id": "string",
        "createdAt": "1937-01-01T12:00:27.870000+00:20",
        "eatsId": "190330-12345678",
        "orderId": "string",
        "predefinedComment": "string",
        "comment": "string",
        "restaurantId": "string",
        "rating": 5,
        "takenAt": "1937-01-01T12:00:27+00:20",
        "deliveredAt": "1937-01-01T12:00:27+00:20"
    },
    "orderInfo": {
        "createdAt": "1937-01-01T12:00:27.870000+00:20",
        "platform": "YE",
        "discriminator": "marketplace",
        "deliveryInfo": {
            "clientName": "John Cena"
        },
        "paymentInfo": {
            "total": 200.99
        },
        "items": [
            {
                "id": "937c57f6-4508-4858-be7f-20691a16fbb0",
                "name": "Pizza Pepperoni",
                "quantity": 3.5,
                "price": 100,
                "modifications": [
                    {
                        "id": "937c57f6-4508-4858-be7f-20691a16fbb0",
                        "name": "Utensils",
                        "quantity": 3,
                        "price": 100
                    }
                ]
            }
        ],
        "comment": "Additional order information: ..."
    }
}

Name

Description

feedback*

Type: Feedback

Information about the customer's feedback

orderInfo

Type: OrderInfo

Order information

Feedback

Information about the customer's feedback

Name

Description

createdAt*

Type: string<date-time>

The date the feedback was created in the RFC 3339 format from fractional part of seconds (Y-m-d\TH:i:s.uP)

Example: 1937-01-01T12:00:27.870000+00:20

deliveredAt*

Type: string<date-time>

The date when the order was delivered in ISO 8601 format without fractional part of seconds (Y-m-d\TH:i:s+hh:ss)

Example: 1937-01-01T12:00:27+00:20

eatsId*

Type: string

End-to-end order identifier on the Yandex side in the format DDDDDD-DDDDDDDD

Example: 190330-12345678

orderId*

Type: string

Order identifier in the partner's system

rating*

Type: integer

The customer's rating for the order is from 1 to 5

Example: 5

restaurantId*

Type: string

The ID of the restaurant in the partner's system

comment

Type: string

Text feedback from the customer on the order

id

Type: string

feedback's ID on the Yandex side

predefinedComment

Type: string

Predefined comments on the Yandex side, selected by the client

takenAt

Type: string<date-time>

The date when the courier picked up the order from the restaurant, in ISO format 8601 without fractional part of seconds (Y-m-d\TH:i:s+hh:ss)

Example: 1937-01-01T12:00:27+00:20

OrderInfo

Order information

Name

Description

comment*

Type: string

Additional order information

Example: Additional order information: ...

createdAt*

Type: string<date-time>

The date the review was created in the RFC 3339 format from fractional part of seconds (Y-m-d\TH:i:s.uP)

Example: 1937-01-01T12:00:27.870000+00:20

deliveryInfo*

Type: DeliveryInfo

Delivery info

discriminator*

Type: string

Type of order delivery:

yandex - delivery by Yandex couriers
marketplace - delivery by restaurant couriers
pickup - pickup by the customer from the restaurant

Example: marketplace

Enum: marketplace, yandex, pickup

items*

Type: OrderInfoItem[]

paymentInfo*

Type: PaymentInfo

platform

Type: string

Platform ID.

Enum: YE

DeliveryInfo

Name

Description

clientName*

Type: string

Client's name in Yandex service

Example: John Cena

OrderInfoItem

Name

Description

id*

Type: string

menu item ID in the partner's system

Example: 937c57f6-4508-4858-be7f-20691a16fbb0

modifications*

Type: ModificationsItem[]

List of selected modifications. May be empty, passed
explicitly for each individual item in the order. When ordering two
items of the same dish with different sets of modifications, different
items with different modifications lists are passed.

price*

Type: number<double>

Price of one item including modification costs. In the next version, it will be corrected to the net price of the item without modifications

Example: 100

quantity*

Type: number<float>

The number of items in the order

Example: 3.5

name

Type: string

menu item name

Example: Pizza Pepperoni

PaymentInfo

Name

Description

total*

Type: number<double>

Total order cost

Example: 200.99

ModificationsItem

Name

Description

id*

Type: string

Modifier ID in the partner's system

Example: 937c57f6-4508-4858-be7f-20691a16fbb0

price*

Type: number<double>

Modifier price for the menu item (e.g., additional sauce)

Example: 100

quantity*

Type: integer

Quantity in the order

Example: 3

name

Type: string

Modifier ID in the partner's system

Example: Utensils

Responses

200 OK

The feedback was successfully processed by the restaurant's internal system.

Body

application/json
{
    "result": "OK"
}

Name

Description

result

Type: string

Example: OK

400 Bad Request

Bad request. An array with an object from the error list is expected in the response body

Body

application/json
[
    {
        "code": 100,
        "description": "Description of error"
    }
]

OrderStatusPut[]

OrderStatusPut

Name

Description

status*

Type: string

Order ststus.
Status description:

  • TAKEN_BY_COURIER - courier picked up the order from the restaurant.
  • DELIVERED – order completed.
  • CANCELLED – order cancelled.

Enum: CANCELLED, TAKEN_BY_COURIER, DELIVERED

attributes

Type: string[]

Additional attributes when changing the order status, for example, a sign of payment upon cancellation

Example: paid

comment

Type: string

Description of cancellation reasons (can be empty)

Example: test

Max length: 500

reason

Type: string

The reason for the cancellation of the order. It is transmitted only with the CANCELLED status

Example: place.unable_to_call

updatedAt

Type: string

The date when the order status changed, in RFC 3339 format with fractional part of seconds (Y-m-d\TH:i:s.uP)

Example: 1937-01-01T12:00:27.870000+00:20

401 Unauthorized

Authorization failed - the token expired or was not passed in the request. A retry will be made.

Body

application/json
{
    "reason": "Access token has been expired. You should request a new one"
}

Name

Description

reason*

Type: string

Reason for authorization failure

Example: Access token has been expired. You should request a new one

500 Internal Server Error

Internal server errors

Body

application/json
[
    {
        "code": 100,
        "description": "Description of error"
    }
]

OrderStatusPut[]

No longer supported, please use an alternative and newer version.

Previous