4.3. Skip a point in an order with multiple route points

  1. HTTP Request
  2. Query Parameters
  3. Header Parameters
  4. Request Body
    1. Representation
    2. Fields
  5. Responses
    1. Code 200
    2. Code 400
      1. Representation
      2. Fields
    3. Code 404
      1. Representation
      2. Fields
    4. Code 409
      1. Representation
      2. Fields
    5. Code 410
      1. Representation
      2. Fields
  6. Example

Initiates the return of the order by the courier to the pickup point. The operation can only be performed if the courier has already picked up the order.


If this is a claim with multiple route points, the current delivery point will be skipped, and the courier will return the parcel to the pickup point at the end of the route.

HTTP Request

POST b2b.taxi.yandex.net/b2b/cargo/integration/v2/claims/return\
?claim_id={string}

Query Parameters

claim_id *

string

Claim ID, received upon creation of claim

claim_id *

string

Claim ID, received upon creation of claim

Header Parameters

Accept-Language *

string

Preferred language of response. Examples: "ru" — Russian, "en" — English

Accept-Language *

string

Preferred language of response. Examples: "ru" — Russian, "en" — English

Request Body

{
  "comment": string,
  "need_return_items": boolean,
  "point_id": integer
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

comment *

string

The reason for skipping a point

need_return_items

boolean

Identifier of the need to return the item to the return point

point_id *

integer

The integer ID (int64) of the point generated by Delivery.
Contained in the route_points[].id. Applicable to points with the following types:

source, destination, return

comment *

string

The reason for skipping a point

need_return_items

boolean

Identifier of the need to return the item to the return point

point_id *

integer

The integer ID (int64) of the point generated by Delivery.
Contained in the route_points[].id. Applicable to points with the following types:

source, destination, return

Responses

Code 200

Return initiated

Code 400

Invalid point

{
  "code": string,
  "message": string
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

code *

string

String error code

Allowed values
  1. state_mismatch

message *

string

Human-readable error message

code *

string

String error code

Allowed values
  1. state_mismatch

message *

string

Human-readable error message

Code 404

Claim not found

{
  "code": string,
  "message": string
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

code *

string

String error code

Allowed values
  1. not_found

message *

string

Human-readable error message

code *

string

String error code

Allowed values
  1. not_found

message *

string

Human-readable error message

Code 409

The courier hasn't been found yet, you can cancel the claim

{
  "code": string,
  "message": string
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

code *

string

String error code

Allowed values
  1. not_allowed
  2. state_transition_forbidden
  3. state_mismatch

message *

string

Human-readable error message

code *

string

String error code

Allowed values
  1. not_allowed
  2. state_transition_forbidden
  3. state_mismatch

message *

string

Human-readable error message

Code 410

Claim status is inactive

{
  "code": string,
  "message": string
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

code *

string

String error code

Allowed values
  1. inappropriate_status

message *

string

Human-readable error message

code *

string

String error code

Allowed values
  1. inappropriate_status

message *

string

Human-readable error message

Example

Request:

curl -X POST "b2b.taxi.yandex.net/b2b/cargo/integration/v2/claims/return?claim_id={string}" \
-H "Accept-Language: {string}" \
-d '{
  "comment": "The client refused to accept the order",
  "point_id": 6987
}'
Copied to clipboard