CalculationLapRequest

Extends \Dumkaaa\Boxberry\Api\C2C\Message\Request\AbstractRequest

Метод позволяет рассчитать стоимость доставки ПиП.

see
package

Dumkaaa\Boxberry\Api\C2C\Message\Request

Methods

__construct

__construct(\Dumkaaa\Boxberry\Api\Common\Http\Client $httpClient, \Symfony\Component\HttpFoundation\Request $httpRequest) 
inherited

Arguments

$httpRequest

\Symfony\Component\HttpFoundation\Request

Возвращает содержимое запроса

getData() : array|mixed
inherited

Response

array|mixed

getEndPoint

getEndPoint() : string
inherited

Response

string

Возвращает заголовки запроса

getHeaders() : array
inherited

Response

array

getHttpMethod

getHttpMethod() : string
inherited

Response

string

Возвращает метод api boxberry

getMethod() : string
inherited abstract

Response

string

Возвращает параметр запроса

getParameter(string $key) : mixed
inherited

Arguments

$key

string

The parameter key

Response

mixed

Возвращает все параметры запроса

getParameters() : array
inherited
inheritdoc

Response

array

Возвращает поодготовленные к отправке параметры запроса

getPreparedData() : array
inherited

Response

array

Возвращает полученный ответ

getResponse() : \Dumkaaa\Boxberry\Api\Common\Message\ResponseInterface
inherited

Возвращает токен api boxberry

getToken() : string
inherited abstract

Response

string

Возвращает правила валидации

getValidationRules() : array
inherited
Throws
\Symfony\Component\Validator\Exception\MissingOptionsException
\Symfony\Component\Validator\Exception\InvalidOptionsException
\Symfony\Component\Validator\Exception\ConstraintDefinitionException

Response

array

Инициализация параметров запроса

initialize(array $parameters = array()) : $this
inherited
inheritdoc
Throws
\Dumkaaa\Boxberry\Api\Common\Exception\RuntimeException

Arguments

$parameters

array

Response

$this

Отправка запроса

send() : \Dumkaaa\Boxberry\Api\Common\Message\ResponseInterface
inherited
inheritdoc
Throws
\ReflectionException

Response

\Dumkaaa\Boxberry\Api\Common\Message\ResponseInterface

send

send() : \Dumkaaa\Boxberry\Api\C2C\Message\Response\CalculationLapResponse

Response

\Dumkaaa\Boxberry\Api\C2C\Message\Response\CalculationLapResponse

sendData

sendData( $data) 
inherited
inheritdoc
Throws
\Dumkaaa\Boxberry\Api\Common\Exception\RuntimeException
\ReflectionException

Arguments

$data

setEndPoint

setEndPoint( $endPoint) : \Dumkaaa\Boxberry\Api\Common\Message\Request\AbstractRequest
inherited

setListServices

setListServices(array<mixed,string> $listServices) : $this

Arguments

$listServices

array<mixed,string>

Массив данных кодов дополнительных услуг

Response

$this

setPackage

setPackage(array|\Dumkaaa\Boxberry\Api\C2C\Model\Package $package) : $this

Arguments

$package

array|\Dumkaaa\Boxberry\Api\C2C\Model\Package

Данные об упаковке

Response

$this

Устанавливает параметр запроса

setParameter( $key,  $value) : $this
inherited
Throws
\Dumkaaa\Boxberry\Api\Common\Exception\RuntimeException

Arguments

$key

$value

Response

$this

setPromoCode

setPromoCode(string $promocode) : $this

Arguments

$promocode

string

Промо код на скидку

Response

$this

setPublicPrice

setPublicPrice(integer $price) : $this

Arguments

$price

integer

Объявленная стоимость в копейках

Response

$this

setReceiverCity

setReceiverCity(string $city) : $this

Arguments

$city

string

Код города получателя

Response

$this

setSenderCity

setSenderCity(string $city) : $this

Arguments

$city

string

Код города отправителя

Response

$this

setToken

setToken( $token) 
inherited abstract

Arguments

$token

Валидация параметров запроса

validateData() 
inherited
Throws
\Symfony\Component\Validator\Exception\MissingOptionsException
\Symfony\Component\Validator\Exception\InvalidOptionsException
\Symfony\Component\Validator\Exception\ConstraintDefinitionException

Properties

Параметры запроса

parameters : \Symfony\Component\HttpFoundation\ParameterBag
inherited
var

Type(s)

\Symfony\Component\HttpFoundation\ParameterBag

Валидатор параметров запроса

validator : \Symfony\Component\Validator\Validator\ValidatorInterface
inherited
var

Type(s)

\Symfony\Component\Validator\Validator\ValidatorInterface

HttpClient, отправляющий запросы

httpClient : \Dumkaaa\Boxberry\Api\Common\Http\Client
inherited

HTTP запрос

httpRequest : \Symfony\Component\HttpFoundation\Request
inherited
var

Type(s)

\Symfony\Component\HttpFoundation\Request

Полученный ответ

response : \Dumkaaa\Boxberry\Api\Common\Message\ResponseInterface
inherited