Get prealert
Gets a previously created prealert
Function GetPrealert(Val Token, Val UUID, Val TestAPI = False) Export
Parameter | CLI option | Type | Required | Description |
---|---|---|---|---|
Token | --token | String | ✔ | Auth token |
UUID | --uuid | String | ✔ | Prealert UUID |
TestAPI | --testapi | Boolean | ✖ | Flag to use test API for requests |
Returns: Map Of KeyAndValue - serialized JSON response from CDEK
tip
The prealert must be previously created. See CreatePrealert
Method at API documentation: Details of prealert document
1C:Enterprise/OneScript code example
Token = "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzY29wZSI6WyJsb2NhdGlvbjphbGwiLCJvcmRlcjphbGwiLCJwYXltZW50OmFsbCJdLCJleHAiOjE3MzIyNjMyNTYsImF1dGhvcml0aWVzIjpbInNoYXJkLWlkOnJ1LTAxIiwiY2xpZW50LWNpdHk60J3QvtCy0L7RgdC40LHQuNGA0YHQuiwg0J3QvtCy0L7RgdC40LHQuNGA0YHQutCw0Y8g0L7QsdC70LDRgdGC0YwiLCJjb250cmFjdDrQmNCcLdCg0KQt0JPQm9CTLTIyIiwiYWNjb3VudC1sYW5nOnJ1cyIsImFwaS12ZXJzaW9uOjEuMSIsImFjY291bnQtdXVpZDplOTI1YmQwZi0wNWE2LTRjNTYtYjczNy00Yjk5YzE0ZjY2OWEiLCJjbGllbnQtaWQtZWM1OmVkNzVlY2Y0LTMwZWQtNDE1My1hZmU5LWViODBiYjUxMmYyMiIsImNvbnRyYWN0LWlkOmRlNDJjYjcxLTZjOGMtNGNmNS04MjIyLWNmYjY2MDQ0ZThkZiIsImNsaWVudC1pZC1lYzQ6MTQzNDgyMzEiLCJjb250cmFnZW50L...";
UUID = "72753031-ff98-4e53-b328-c21c371749fc";
Result = OPI_CDEK.GetPrealert(Token, UUID, True);
- Bash
- CMD/Bat
oint cdek GetPrealert \
--token "***" \
--uuid "72753031-ffbd-47e8-bcb9-400eff1ca67f" \
--testapi "***"
oint cdek GetPrealert ^
--token "***" ^
--uuid "72753031-ffbd-47e8-bcb9-400eff1ca67f" ^
--testapi "***"
Result
{
"entity": {
"uuid": "72753031-8222-4d75-9c04-8a14035cbe80",
"prealert_number": "PA/1305/27",
"planned_date": "2024-10-23T00:27:30+03:00",
"shipment_point": "NSK27",
"orders": [
{
"order_uuid": "a93fd1b1-55b3-4033-a52a-d2df7bb6b469",
"cdek_number": 1106094897,
"im_number": "3d2378de-8718-4041-b89a-33e6058810c8"
}
]
},
"requests": [
{
"request_uuid": "d20f73ba-1277-4933-b559-241c4948e8d0",
"type": "CREATE",
"date_time": "2024-10-21T21:27:30+03:00",
"state": "SUCCESSFUL"
}
],
"related_entities": []
}