Answer the question
In order to leave comments, you need to log in
How to solve the problem of duplicate response body by Yii HTTP Client?
The problem is with one API method, which is responsible for the delivery to order.
The object must be:
{"tid":4828,"dcid":{"x":482222},"paid":true,"error":[]}
{"tid":4828,"dcid":{"x":482222},"paid":true,"error":[]}{ "tid": 4828, "dcid": { "x": 482222 }, "paid": true, "error": [] }
$response= $client->createRequest()
->setUrl(self::API_ENDPOINT . "$collection/$method")
->setMethod("POST")
->setData($params)
->addHeaders(['Token' => $this->apiKey])->send();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question