diff --git a/README.md b/README.md index 9d6ca5b1..db003993 100644 --- a/README.md +++ b/README.md @@ -19,23 +19,15 @@ PHP 5.6 and later ## Installation & Usage ### Composer -To install the bindings via [Composer](http://getcomposer.org/), add the following to `composer.json`: +To install the bindings via [Composer](http://getcomposer.org/): ``` -{ - "repositories": [ - { - "type": "git", - "url": "https://github.com/sendinblue/APIv3-php-library.git" - } - ], - "require": { - "sendinblue/api-v3-sdk": "*@dev" - } -} +composer require sendinblue/api-v3-sdk "^6.0.0" ``` -Then run `composer install` +Further do: +* run `composer install` to get these dependencies added to your vendor directory +* add the autoloader to your application with this line: require(__DIR__ . '/vendor/autoload.php') ### Manual Installation diff --git a/composer.lock b/composer.lock index c96f5981..fa9e607c 100644 --- a/composer.lock +++ b/composer.lock @@ -1435,16 +1435,16 @@ }, { "name": "symfony/console", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "36f83f642443c46f3cf751d4d2ee5d047d757a27" + "reference": "1b97071a26d028c9bd4588264e101e14f6e7cd00" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/36f83f642443c46f3cf751d4d2ee5d047d757a27", - "reference": "36f83f642443c46f3cf751d4d2ee5d047d757a27", + "url": "https://api.github.com/repos/symfony/console/zipball/1b97071a26d028c9bd4588264e101e14f6e7cd00", + "reference": "1b97071a26d028c9bd4588264e101e14f6e7cd00", "shasum": "" }, "require": { @@ -1500,20 +1500,20 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2018-05-16T08:49:21+00:00" + "time": "2018-05-23T05:02:55+00:00" }, { "name": "symfony/debug", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "b28fd73fefbac341f673f5efd707d539d6a19f68" + "reference": "47e6788c5b151cf0cfdf3329116bf33800632d75" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/b28fd73fefbac341f673f5efd707d539d6a19f68", - "reference": "b28fd73fefbac341f673f5efd707d539d6a19f68", + "url": "https://api.github.com/repos/symfony/debug/zipball/47e6788c5b151cf0cfdf3329116bf33800632d75", + "reference": "47e6788c5b151cf0cfdf3329116bf33800632d75", "shasum": "" }, "require": { @@ -1556,11 +1556,11 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2018-05-16T14:03:39+00:00" + "time": "2018-06-25T11:10:40+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", @@ -1623,16 +1623,16 @@ }, { "name": "symfony/filesystem", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "8e03ca3fa52a0f56b87506f38cf7bd3f9442b3a0" + "reference": "8a721a5f2553c6c3482b1c5b22ed60fe94dd63ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/8e03ca3fa52a0f56b87506f38cf7bd3f9442b3a0", - "reference": "8e03ca3fa52a0f56b87506f38cf7bd3f9442b3a0", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/8a721a5f2553c6c3482b1c5b22ed60fe94dd63ed", + "reference": "8a721a5f2553c6c3482b1c5b22ed60fe94dd63ed", "shasum": "" }, "require": { @@ -1669,20 +1669,20 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", - "time": "2018-05-16T08:49:21+00:00" + "time": "2018-06-21T11:10:19+00:00" }, { "name": "symfony/finder", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "472a92f3df8b247b49ae364275fb32943b9656c6" + "reference": "3a8c3de91d2b2c68cd2d665cf9d00f7ef9eaa394" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/472a92f3df8b247b49ae364275fb32943b9656c6", - "reference": "472a92f3df8b247b49ae364275fb32943b9656c6", + "url": "https://api.github.com/repos/symfony/finder/zipball/3a8c3de91d2b2c68cd2d665cf9d00f7ef9eaa394", + "reference": "3a8c3de91d2b2c68cd2d665cf9d00f7ef9eaa394", "shasum": "" }, "require": { @@ -1718,7 +1718,7 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2018-05-16T08:49:21+00:00" + "time": "2018-06-19T20:52:10+00:00" }, { "name": "symfony/polyfill-ctype", @@ -1836,16 +1836,16 @@ }, { "name": "symfony/process", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "4cbf2db9abcb01486a21b7a059e03a62fae63187" + "reference": "acc5a37c706ace827962851b69705b24e71ca17c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/4cbf2db9abcb01486a21b7a059e03a62fae63187", - "reference": "4cbf2db9abcb01486a21b7a059e03a62fae63187", + "url": "https://api.github.com/repos/symfony/process/zipball/acc5a37c706ace827962851b69705b24e71ca17c", + "reference": "acc5a37c706ace827962851b69705b24e71ca17c", "shasum": "" }, "require": { @@ -1881,11 +1881,11 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2018-05-16T08:49:21+00:00" + "time": "2018-05-30T04:24:30+00:00" }, { "name": "symfony/stopwatch", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", @@ -1934,7 +1934,7 @@ }, { "name": "symfony/yaml", - "version": "v3.4.10", + "version": "v3.4.12", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", diff --git a/docs/Model/SendTransacSms.md b/docs/Model/SendTransacSms.md index 33f11fb5..adc80cde 100644 --- a/docs/Model/SendTransacSms.md +++ b/docs/Model/SendTransacSms.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **sender** | **string** | Name of the sender. Only alphanumeric characters. No more than 11 characters | **recipient** | **string** | Mobile number to send SMS with the country code | -**content** | **string** | Content of the message. If more than 160 characters long, multiple text messages will be sent | +**content** | **string** | Content of the message. If more than 160 characters long, will be sent as multiple text messages | **type** | **string** | Type of the SMS | [optional] [default to 'transactional'] **tag** | **string** | Tag of the message | [optional] **webUrl** | **string** | Webhook to call for each event triggered by the message (delivered etc.) | [optional] diff --git a/lib/Model/SendTransacSms.php b/lib/Model/SendTransacSms.php index cd07c0bb..09339af3 100644 --- a/lib/Model/SendTransacSms.php +++ b/lib/Model/SendTransacSms.php @@ -247,10 +247,6 @@ public function listInvalidProperties() if ($this->container['content'] === null) { $invalidProperties[] = "'content' can't be null"; } - if ((strlen($this->container['content']) > 160)) { - $invalidProperties[] = "invalid value for 'content', the character length must be smaller than or equal to 160."; - } - $allowedValues = $this->getTypeAllowableValues(); if (!in_array($this->container['type'], $allowedValues)) { $invalidProperties[] = sprintf( @@ -283,9 +279,6 @@ public function valid() if ($this->container['content'] === null) { return false; } - if (strlen($this->container['content']) > 160) { - return false; - } $allowedValues = $this->getTypeAllowableValues(); if (!in_array($this->container['type'], $allowedValues)) { return false; @@ -359,16 +352,12 @@ public function getContent() /** * Sets content * - * @param string $content Content of the message. If more than 160 characters long, multiple text messages will be sent + * @param string $content Content of the message. If more than 160 characters long, will be sent as multiple text messages * * @return $this */ public function setContent($content) { - if ((strlen($content) > 160)) { - throw new \InvalidArgumentException('invalid length for $content when calling SendTransacSms., must be smaller than or equal to 160.'); - } - $this->container['content'] = $content; return $this;