128 lines
7.9 KiB
JavaScript
128 lines
7.9 KiB
JavaScript
"use strict";
|
||
/* tslint:disable */
|
||
/* eslint-disable */
|
||
/**
|
||
* Документация Ozon Seller API
|
||
* По вопросам работы с Seller API обращайтесь в поддержку через личный кабинет. <aside class=\"warning\">Обновляем корневой TLS/SSL-сертификат GlobalSign — вместо него будем использовать <a href=\"https://app.harica.gr/\">HARICA</a>.<br><a href=\"https://dev.ozon.ru/news/775-Izmeneniia-v-Ozon-API-migratsiia-kornevogo-sertifikata-UTs-Ozon/\">Подробнее о переходе на HARICA на платформе разработчиков Ozon for dev</a></aside> > [Инструкции по работе с маркетплейсом](https://seller-edu.ozon.ru) > [Информационная платформа и сообщество разработчиков Ozon for dev](https://dev.ozon.ru/)
|
||
*
|
||
* The version of the OpenAPI document: 2.1
|
||
*
|
||
*
|
||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||
* https://openapi-generator.tech
|
||
* Do not edit the class manually.
|
||
*/
|
||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
||
return new (P || (P = Promise))(function (resolve, reject) {
|
||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
||
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
||
});
|
||
};
|
||
Object.defineProperty(exports, "__esModule", { value: true });
|
||
exports.FboPostingAPI = void 0;
|
||
const runtime = require("../runtime");
|
||
const index_1 = require("../models/index");
|
||
/**
|
||
*
|
||
*/
|
||
class FboPostingAPI extends runtime.BaseAPI {
|
||
/**
|
||
* Отменяет отправление из заказа. Используйте идентификатор причины отмены `reasons.id` из метода [/v1/cancel-reason/list-by-posting](#operation/CancelReasonAPI_CancelReasonListByPosting).
|
||
* Отменить отправление из заказа
|
||
*/
|
||
postingAPIPostingCancelRaw(requestParameters, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
if (requestParameters['v1PostingCancelRequest'] == null) {
|
||
throw new runtime.RequiredError('v1PostingCancelRequest', 'Required parameter "v1PostingCancelRequest" was null or undefined when calling postingAPIPostingCancel().');
|
||
}
|
||
const queryParameters = {};
|
||
const headerParameters = {};
|
||
headerParameters['Content-Type'] = 'application/json';
|
||
const response = yield this.request({
|
||
path: `/v1/posting/cancel`,
|
||
method: 'POST',
|
||
headers: headerParameters,
|
||
query: queryParameters,
|
||
body: (0, index_1.V1PostingCancelRequestToJSON)(requestParameters['v1PostingCancelRequest']),
|
||
}, initOverrides);
|
||
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.V1PostingCancelResponseFromJSON)(jsonValue));
|
||
});
|
||
}
|
||
/**
|
||
* Отменяет отправление из заказа. Используйте идентификатор причины отмены `reasons.id` из метода [/v1/cancel-reason/list-by-posting](#operation/CancelReasonAPI_CancelReasonListByPosting).
|
||
* Отменить отправление из заказа
|
||
*/
|
||
postingAPIPostingCancel(v1PostingCancelRequest, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
const response = yield this.postingAPIPostingCancelRaw({ v1PostingCancelRequest: v1PostingCancelRequest }, initOverrides);
|
||
return yield response.value();
|
||
});
|
||
}
|
||
/**
|
||
* Проверить статус отмены отправления
|
||
*/
|
||
postingAPIPostingCancelStatusRaw(requestParameters, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
if (requestParameters['v1PostingCancelStatusRequest'] == null) {
|
||
throw new runtime.RequiredError('v1PostingCancelStatusRequest', 'Required parameter "v1PostingCancelStatusRequest" was null or undefined when calling postingAPIPostingCancelStatus().');
|
||
}
|
||
const queryParameters = {};
|
||
const headerParameters = {};
|
||
headerParameters['Content-Type'] = 'application/json';
|
||
const response = yield this.request({
|
||
path: `/v1/posting/cancel/status`,
|
||
method: 'POST',
|
||
headers: headerParameters,
|
||
query: queryParameters,
|
||
body: (0, index_1.V1PostingCancelStatusRequestToJSON)(requestParameters['v1PostingCancelStatusRequest']),
|
||
}, initOverrides);
|
||
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.V1PostingCancelStatusResponseFromJSON)(jsonValue));
|
||
});
|
||
}
|
||
/**
|
||
* Проверить статус отмены отправления
|
||
*/
|
||
postingAPIPostingCancelStatus(v1PostingCancelStatusRequest, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
const response = yield this.postingAPIPostingCancelStatusRaw({ v1PostingCancelStatusRequest: v1PostingCancelStatusRequest }, initOverrides);
|
||
return yield response.value();
|
||
});
|
||
}
|
||
/**
|
||
* Возвращает статусы выдачи экземпляров и коды маркировки «Честный ЗНАК» для каждого отправления. Укажите в чеке и выведите из оборота маркировки экземпляров из параметра `issued_exemplars` в ответе.
|
||
* Получить маркировки экземпляров из отправления
|
||
*/
|
||
postingAPIPostingMarksRaw(requestParameters, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
if (requestParameters['v1PostingMarksRequest'] == null) {
|
||
throw new runtime.RequiredError('v1PostingMarksRequest', 'Required parameter "v1PostingMarksRequest" was null or undefined when calling postingAPIPostingMarks().');
|
||
}
|
||
const queryParameters = {};
|
||
const headerParameters = {};
|
||
headerParameters['Content-Type'] = 'application/json';
|
||
const response = yield this.request({
|
||
path: `/v1/posting/marks`,
|
||
method: 'POST',
|
||
headers: headerParameters,
|
||
query: queryParameters,
|
||
body: (0, index_1.V1PostingMarksRequestToJSON)(requestParameters['v1PostingMarksRequest']),
|
||
}, initOverrides);
|
||
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.V1PostingMarksResponseFromJSON)(jsonValue));
|
||
});
|
||
}
|
||
/**
|
||
* Возвращает статусы выдачи экземпляров и коды маркировки «Честный ЗНАК» для каждого отправления. Укажите в чеке и выведите из оборота маркировки экземпляров из параметра `issued_exemplars` в ответе.
|
||
* Получить маркировки экземпляров из отправления
|
||
*/
|
||
postingAPIPostingMarks(v1PostingMarksRequest, initOverrides) {
|
||
return __awaiter(this, void 0, void 0, function* () {
|
||
const response = yield this.postingAPIPostingMarksRaw({ v1PostingMarksRequest: v1PostingMarksRequest }, initOverrides);
|
||
return yield response.value();
|
||
});
|
||
}
|
||
}
|
||
exports.FboPostingAPI = FboPostingAPI;
|