Gets public preset

  1. HTTP Request
  2. Path Parameters
  3. Responses
    1. Code 200
      1. Representation
      2. Fields
    2. Code 401
    3. Code 422
    4. Code 500

Gets public preset by ID.

HTTP Request

GET https://courier.yandex.ru/api/v1/reference-book/public/presets/{preset_id}

Path Parameters

preset_id *

string

ID of the preset in the reference book.

preset_id *

string

ID of the preset in the reference book.

Responses

Code 200

Preset has been successfully returned.

{
  "body": {},
  "description": string,
  "history": {
    "created_at": string,
    "updated_at": string,
    "updated_by": string
  },
  "id": string,
  "number": string,
  "type": string
}
Copied to clipboard

Representation

Collapse all
Expand all

Fields

body

object

The preset body is in the form of json, the schema must match the preset type.

description

string

Description of the preset.

history

object

history.created_at

string

The preset creation time in the format YYYY-MM-DDThh:mm:ssZ.

history.updated_at

string

Preset update time in the format YYYY-MM-DDThh:mm:ssZ.

history.updated_by

string

Who made the last changes.

id

string

ID of the preset in the reference book.

number

string

Preset number. Cannot start with public_ and contain a comma character.

type

string

The type of preset.

Allowed values
  1. depot
  2. location
  3. options
  4. vehicle
  5. vehicle-shift

body

object

The preset body is in the form of json, the schema must match the preset type.

description

string

Description of the preset.

history

object

history.created_at

string

The preset creation time in the format YYYY-MM-DDThh:mm:ssZ.

history.updated_at

string

Preset update time in the format YYYY-MM-DDThh:mm:ssZ.

history.updated_by

string

Who made the last changes.

id

string

ID of the preset in the reference book.

number

string

Preset number. Cannot start with public_ and contain a comma character.

type

string

The type of preset.

Allowed values
  1. depot
  2. location
  3. options
  4. vehicle
  5. vehicle-shift

Code 401

Authorization error. Make sure that the request header contains the correct OAuth token.

Code 422

Incorrect input. Preset doesn't exist.

Code 500

Server error during request processing.