cakemail / cakemail-php

Client of Cakemail's API Next-Gen
MIT License
0 stars 2 forks source link

The response object no work properly. #3

Closed inmun closed 3 years ago

inmun commented 3 years ago

Hi, I have a problem when try to get tho options on response object. All responses that I checked have the structure similar like this: Cakemail\Subapis::CampaignApi::schedule(): Response new Response($this->openApiObj->scheduleCampaignWithHttpInfo($allParams['campaign_id']['value'], $allParams['account_id']['value'], $allParams['schedule_campaign']['value']));

The response of Cakemail\Lib\Api::scheduleCampaignWithHttpInfo() line 4073 is an array, but \Cakemail\Response::construct() expect an object. Is not possible to validate the response with this structure.

demetrius-edelin commented 3 years ago

Thank you for the fix. We updated the code.