Initial commit

This commit is contained in:
2020-04-07 13:03:04 +00:00
committed by Gitium
commit 00f842d9bf
1673 changed files with 471161 additions and 0 deletions

View File

@ -0,0 +1,302 @@
<?php
/**
* AddChildDomain
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* AddChildDomain Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class AddChildDomain implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'addChildDomain';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'domain' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'domain' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'domain' => 'domain'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'domain' => 'setDomain'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'domain' => 'getDomain'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Sender domain to add for a specific child account
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* AddContactToList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* AddContactToList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class AddContactToList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'addContactToList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'emails' => 'string[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'emails' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'emails' => 'emails'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'emails' => 'setEmails'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'emails' => 'getEmails'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['emails'] = isset($data['emails']) ? $data['emails'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets emails
*
* @return string[]
*/
public function getEmails()
{
return $this->container['emails'];
}
/**
* Sets emails
*
* @param string[] $emails Emails to add to a list
*
* @return $this
*/
public function setEmails($emails)
{
$this->container['emails'] = $emails;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,332 @@
<?php
/**
* AddCredits
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* AddCredits Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class AddCredits implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'addCredits';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'sms' => 'int',
'email' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'sms' => 'int64',
'email' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'sms' => 'sms',
'email' => 'email'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'sms' => 'setSms',
'email' => 'setEmail'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'sms' => 'getSms',
'email' => 'getEmail'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['sms'] = isset($data['sms']) ? $data['sms'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets sms
*
* @return int
*/
public function getSms()
{
return $this->container['sms'];
}
/**
* Sets sms
*
* @param int $sms Required if email credits are empty. SMS credits to be added to the child account
*
* @return $this
*/
public function setSms($sms)
{
$this->container['sms'] = $sms;
return $this;
}
/**
* Gets email
*
* @return int
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param int $email Required if sms credits are empty. Email credits to be added to the child account
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,406 @@
<?php
/**
* CreateAttribute
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateAttribute Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateAttribute implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createAttribute';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'value' => 'string',
'enumeration' => '\SendinBlue\Client\Model\CreateAttributeEnumeration[]',
'type' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'value' => null,
'enumeration' => null,
'type' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'value' => 'value',
'enumeration' => 'enumeration',
'type' => 'type'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'value' => 'setValue',
'enumeration' => 'setEnumeration',
'type' => 'setType'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'value' => 'getValue',
'enumeration' => 'getEnumeration',
'type' => 'getType'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const TYPE_TEXT = 'text';
const TYPE_DATE = 'date';
const TYPE_FLOAT = 'float';
const TYPE_BOOLEAN = 'boolean';
const TYPE_ID = 'id';
const TYPE_CATEGORY = 'category';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getTypeAllowableValues()
{
return [
self::TYPE_TEXT,
self::TYPE_DATE,
self::TYPE_FLOAT,
self::TYPE_BOOLEAN,
self::TYPE_ID,
self::TYPE_CATEGORY,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['value'] = isset($data['value']) ? $data['value'] : null;
$this->container['enumeration'] = isset($data['enumeration']) ? $data['enumeration'] : null;
$this->container['type'] = isset($data['type']) ? $data['type'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets value
*
* @return string
*/
public function getValue()
{
return $this->container['value'];
}
/**
* Sets value
*
* @param string $value Value of the attribute. Use only if the attribute's category is 'calculated' or 'global'
*
* @return $this
*/
public function setValue($value)
{
$this->container['value'] = $value;
return $this;
}
/**
* Gets enumeration
*
* @return \SendinBlue\Client\Model\CreateAttributeEnumeration[]
*/
public function getEnumeration()
{
return $this->container['enumeration'];
}
/**
* Sets enumeration
*
* @param \SendinBlue\Client\Model\CreateAttributeEnumeration[] $enumeration List of values and labels that the attribute can take. Use only if the attribute's category is \"category\". For example, `[{\"value\":1, \"label\":\"male\"}, {\"value\":2, \"label\":\"female\"}]`
*
* @return $this
*/
public function setEnumeration($enumeration)
{
$this->container['enumeration'] = $enumeration;
return $this;
}
/**
* Gets type
*
* @return string
*/
public function getType()
{
return $this->container['type'];
}
/**
* Sets type
*
* @param string $type Type of the attribute. Use only if the attribute's category is 'normal', 'category' or 'transactional' ( type 'boolean' is only available if the category is 'normal' attribute, type 'id' is only available if the category is 'transactional' attribute & type 'category' is only available if the category is 'category' attribute )
*
* @return $this
*/
public function setType($type)
{
$allowedValues = $this->getTypeAllowableValues();
if (!is_null($type) && !in_array($type, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['type'] = $type;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* CreateAttributeEnumeration
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateAttributeEnumeration Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateAttributeEnumeration implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createAttribute_enumeration';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'value' => 'int',
'label' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'value' => null,
'label' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'value' => 'value',
'label' => 'label'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'value' => 'setValue',
'label' => 'setLabel'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'value' => 'getValue',
'label' => 'getLabel'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['value'] = isset($data['value']) ? $data['value'] : null;
$this->container['label'] = isset($data['label']) ? $data['label'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['value'] === null) {
$invalidProperties[] = "'value' can't be null";
}
if ($this->container['label'] === null) {
$invalidProperties[] = "'label' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['value'] === null) {
return false;
}
if ($this->container['label'] === null) {
return false;
}
return true;
}
/**
* Gets value
*
* @return int
*/
public function getValue()
{
return $this->container['value'];
}
/**
* Sets value
*
* @param int $value Id of the value
*
* @return $this
*/
public function setValue($value)
{
$this->container['value'] = $value;
return $this;
}
/**
* Gets label
*
* @return string
*/
public function getLabel()
{
return $this->container['label'];
}
/**
* Sets label
*
* @param string $label Label of the value
*
* @return $this
*/
public function setLabel($label)
{
$this->container['label'] = $label;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,452 @@
<?php
/**
* CreateChild
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateChild Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateChild implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createChild';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'firstName' => 'string',
'lastName' => 'string',
'companyName' => 'string',
'password' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'firstName' => null,
'lastName' => null,
'companyName' => null,
'password' => 'password'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'firstName' => 'firstName',
'lastName' => 'lastName',
'companyName' => 'companyName',
'password' => 'password'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'firstName' => 'setFirstName',
'lastName' => 'setLastName',
'companyName' => 'setCompanyName',
'password' => 'setPassword'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'firstName' => 'getFirstName',
'lastName' => 'getLastName',
'companyName' => 'getCompanyName',
'password' => 'getPassword'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['firstName'] = isset($data['firstName']) ? $data['firstName'] : null;
$this->container['lastName'] = isset($data['lastName']) ? $data['lastName'] : null;
$this->container['companyName'] = isset($data['companyName']) ? $data['companyName'] : null;
$this->container['password'] = isset($data['password']) ? $data['password'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['firstName'] === null) {
$invalidProperties[] = "'firstName' can't be null";
}
if ($this->container['lastName'] === null) {
$invalidProperties[] = "'lastName' can't be null";
}
if ($this->container['companyName'] === null) {
$invalidProperties[] = "'companyName' can't be null";
}
if ($this->container['password'] === null) {
$invalidProperties[] = "'password' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['firstName'] === null) {
return false;
}
if ($this->container['lastName'] === null) {
return false;
}
if ($this->container['companyName'] === null) {
return false;
}
if ($this->container['password'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email address to create the child account
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets firstName
*
* @return string
*/
public function getFirstName()
{
return $this->container['firstName'];
}
/**
* Sets firstName
*
* @param string $firstName First name to use to create the child account
*
* @return $this
*/
public function setFirstName($firstName)
{
$this->container['firstName'] = $firstName;
return $this;
}
/**
* Gets lastName
*
* @return string
*/
public function getLastName()
{
return $this->container['lastName'];
}
/**
* Sets lastName
*
* @param string $lastName Last name to use to create the child account
*
* @return $this
*/
public function setLastName($lastName)
{
$this->container['lastName'] = $lastName;
return $this;
}
/**
* Gets companyName
*
* @return string
*/
public function getCompanyName()
{
return $this->container['companyName'];
}
/**
* Sets companyName
*
* @param string $companyName Company name to use to create the child account
*
* @return $this
*/
public function setCompanyName($companyName)
{
$this->container['companyName'] = $companyName;
return $this;
}
/**
* Gets password
*
* @return string
*/
public function getPassword()
{
return $this->container['password'];
}
/**
* Sets password
*
* @param string $password Password for the child account to login
*
* @return $this
*/
public function setPassword($password)
{
$this->container['password'] = $password;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,482 @@
<?php
/**
* CreateContact
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateContact Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateContact implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createContact';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'attributes' => 'object',
'emailBlacklisted' => 'bool',
'smsBlacklisted' => 'bool',
'listIds' => 'int[]',
'updateEnabled' => 'bool',
'smtpBlacklistSender' => 'string[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'attributes' => null,
'emailBlacklisted' => null,
'smsBlacklisted' => null,
'listIds' => 'int64',
'updateEnabled' => null,
'smtpBlacklistSender' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'attributes' => 'attributes',
'emailBlacklisted' => 'emailBlacklisted',
'smsBlacklisted' => 'smsBlacklisted',
'listIds' => 'listIds',
'updateEnabled' => 'updateEnabled',
'smtpBlacklistSender' => 'smtpBlacklistSender'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'attributes' => 'setAttributes',
'emailBlacklisted' => 'setEmailBlacklisted',
'smsBlacklisted' => 'setSmsBlacklisted',
'listIds' => 'setListIds',
'updateEnabled' => 'setUpdateEnabled',
'smtpBlacklistSender' => 'setSmtpBlacklistSender'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'attributes' => 'getAttributes',
'emailBlacklisted' => 'getEmailBlacklisted',
'smsBlacklisted' => 'getSmsBlacklisted',
'listIds' => 'getListIds',
'updateEnabled' => 'getUpdateEnabled',
'smtpBlacklistSender' => 'getSmtpBlacklistSender'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['attributes'] = isset($data['attributes']) ? $data['attributes'] : null;
$this->container['emailBlacklisted'] = isset($data['emailBlacklisted']) ? $data['emailBlacklisted'] : null;
$this->container['smsBlacklisted'] = isset($data['smsBlacklisted']) ? $data['smsBlacklisted'] : null;
$this->container['listIds'] = isset($data['listIds']) ? $data['listIds'] : null;
$this->container['updateEnabled'] = isset($data['updateEnabled']) ? $data['updateEnabled'] : false;
$this->container['smtpBlacklistSender'] = isset($data['smtpBlacklistSender']) ? $data['smtpBlacklistSender'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email address of the user. Mandatory if \"sms\" field is not passed in \"attributes\" parameter'
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets attributes
*
* @return object
*/
public function getAttributes()
{
return $this->container['attributes'];
}
/**
* Sets attributes
*
* @param object $attributes Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For example, `{\"FNAME\":\"Elly\", \"LNAME\":\"Roger\"}`
*
* @return $this
*/
public function setAttributes($attributes)
{
$this->container['attributes'] = $attributes;
return $this;
}
/**
* Gets emailBlacklisted
*
* @return bool
*/
public function getEmailBlacklisted()
{
return $this->container['emailBlacklisted'];
}
/**
* Sets emailBlacklisted
*
* @param bool $emailBlacklisted Set this field to blacklist the contact for emails (emailBlacklisted = true)
*
* @return $this
*/
public function setEmailBlacklisted($emailBlacklisted)
{
$this->container['emailBlacklisted'] = $emailBlacklisted;
return $this;
}
/**
* Gets smsBlacklisted
*
* @return bool
*/
public function getSmsBlacklisted()
{
return $this->container['smsBlacklisted'];
}
/**
* Sets smsBlacklisted
*
* @param bool $smsBlacklisted Set this field to blacklist the contact for SMS (smsBlacklisted = true)
*
* @return $this
*/
public function setSmsBlacklisted($smsBlacklisted)
{
$this->container['smsBlacklisted'] = $smsBlacklisted;
return $this;
}
/**
* Gets listIds
*
* @return int[]
*/
public function getListIds()
{
return $this->container['listIds'];
}
/**
* Sets listIds
*
* @param int[] $listIds Ids of the lists to add the contact to
*
* @return $this
*/
public function setListIds($listIds)
{
$this->container['listIds'] = $listIds;
return $this;
}
/**
* Gets updateEnabled
*
* @return bool
*/
public function getUpdateEnabled()
{
return $this->container['updateEnabled'];
}
/**
* Sets updateEnabled
*
* @param bool $updateEnabled Facilitate to update the existing contact in the same request (updateEnabled = true)
*
* @return $this
*/
public function setUpdateEnabled($updateEnabled)
{
$this->container['updateEnabled'] = $updateEnabled;
return $this;
}
/**
* Gets smtpBlacklistSender
*
* @return string[]
*/
public function getSmtpBlacklistSender()
{
return $this->container['smtpBlacklistSender'];
}
/**
* Sets smtpBlacklistSender
*
* @param string[] $smtpBlacklistSender SMTP forbidden sender for contact. Use only for email Contact ( only available if updateEnabled = true )
*
* @return $this
*/
public function setSmtpBlacklistSender($smtpBlacklistSender)
{
$this->container['smtpBlacklistSender'] = $smtpBlacklistSender;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,333 @@
<?php
/**
* CreateEmailCampaignRecipients
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateEmailCampaignRecipients Class Doc Comment
*
* @category Class
* @description List ids to include/exclude from campaign
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateEmailCampaignRecipients implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createEmailCampaign_recipients';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'exclusionListIds' => 'int[]',
'listIds' => 'int[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'exclusionListIds' => 'int64',
'listIds' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'exclusionListIds' => 'exclusionListIds',
'listIds' => 'listIds'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'exclusionListIds' => 'setExclusionListIds',
'listIds' => 'setListIds'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'exclusionListIds' => 'getExclusionListIds',
'listIds' => 'getListIds'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['exclusionListIds'] = isset($data['exclusionListIds']) ? $data['exclusionListIds'] : null;
$this->container['listIds'] = isset($data['listIds']) ? $data['listIds'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets exclusionListIds
*
* @return int[]
*/
public function getExclusionListIds()
{
return $this->container['exclusionListIds'];
}
/**
* Sets exclusionListIds
*
* @param int[] $exclusionListIds List ids to exclude from the campaign
*
* @return $this
*/
public function setExclusionListIds($exclusionListIds)
{
$this->container['exclusionListIds'] = $exclusionListIds;
return $this;
}
/**
* Gets listIds
*
* @return int[]
*/
public function getListIds()
{
return $this->container['listIds'];
}
/**
* Sets listIds
*
* @param int[] $listIds Mandatory if scheduledAt is not empty. List Ids to send the campaign to
*
* @return $this
*/
public function setListIds($listIds)
{
$this->container['listIds'] = $listIds;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,339 @@
<?php
/**
* CreateEmailCampaignSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateEmailCampaignSender Class Doc Comment
*
* @category Class
* @description Sender details including email and name (optional). For example &#x60;{\&quot;name\&quot;:\&quot;xyz\&quot;, \&quot;email\&quot;:\&quot;example@abc.com\&quot;}&#x60;
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateEmailCampaignSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createEmailCampaign_sender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'email' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'email' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'email' => 'email'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'email' => 'setEmail'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'email' => 'getEmail'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Sender Name
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Sender email
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* CreateList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'folderId' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'folderId' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'folderId' => 'folderId'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'folderId' => 'setFolderId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'folderId' => 'getFolderId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['folderId'] = isset($data['folderId']) ? $data['folderId'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['folderId'] === null) {
$invalidProperties[] = "'folderId' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['folderId'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the list
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets folderId
*
* @return int
*/
public function getFolderId()
{
return $this->container['folderId'];
}
/**
* Sets folderId
*
* @param int $folderId Id of the parent folder in which this list is to be created
*
* @return $this
*/
public function setFolderId($folderId)
{
$this->container['folderId'] = $folderId;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* CreateModel
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateModel Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateModel implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createModel';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the object created
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* CreateReseller
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateReseller Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateReseller implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createReseller';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'authKey' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'authKey' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'authKey' => 'authKey'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'authKey' => 'setAuthKey'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'authKey' => 'getAuthKey'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['authKey'] = isset($data['authKey']) ? $data['authKey'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['authKey'] === null) {
$invalidProperties[] = "'authKey' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['authKey'] === null) {
return false;
}
return true;
}
/**
* Gets authKey
*
* @return string
*/
public function getAuthKey()
{
return $this->container['authKey'];
}
/**
* Sets authKey
*
* @param string $authKey AuthKey of Reseller child created
*
* @return $this
*/
public function setAuthKey($authKey)
{
$this->container['authKey'] = $authKey;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,374 @@
<?php
/**
* CreateSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSender Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'email' => 'string',
'ips' => '\SendinBlue\Client\Model\CreateSenderIps[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'email' => 'email',
'ips' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'email' => 'email',
'ips' => 'ips'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'email' => 'setEmail',
'ips' => 'setIps'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'email' => 'getEmail',
'ips' => 'getIps'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['ips'] = isset($data['ips']) ? $data['ips'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['email'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name From Name to use for the sender
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email From Email to use for the sender
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets ips
*
* @return \SendinBlue\Client\Model\CreateSenderIps[]
*/
public function getIps()
{
return $this->container['ips'];
}
/**
* Sets ips
*
* @param \SendinBlue\Client\Model\CreateSenderIps[] $ips Mandatory in case of dedicated IP, IPs to associate to the sender
*
* @return $this
*/
public function setIps($ips)
{
$this->container['ips'] = $ips;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,396 @@
<?php
/**
* CreateSenderIps
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSenderIps Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSenderIps implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSender_ips';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'ip' => 'string',
'domain' => 'string',
'weight' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'ip' => null,
'domain' => null,
'weight' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'ip' => 'ip',
'domain' => 'domain',
'weight' => 'weight'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'ip' => 'setIp',
'domain' => 'setDomain',
'weight' => 'setWeight'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'ip' => 'getIp',
'domain' => 'getDomain',
'weight' => 'getWeight'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
$this->container['weight'] = isset($data['weight']) ? $data['weight'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
if ($this->container['domain'] === null) {
$invalidProperties[] = "'domain' can't be null";
}
if (!is_null($this->container['weight']) && ($this->container['weight'] > 100)) {
$invalidProperties[] = "invalid value for 'weight', must be smaller than or equal to 100.";
}
if (!is_null($this->container['weight']) && ($this->container['weight'] < 1)) {
$invalidProperties[] = "invalid value for 'weight', must be bigger than or equal to 1.";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['ip'] === null) {
return false;
}
if ($this->container['domain'] === null) {
return false;
}
if ($this->container['weight'] > 100) {
return false;
}
if ($this->container['weight'] < 1) {
return false;
}
return true;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip Dedicated IP available in your account
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Domain of the IP
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Gets weight
*
* @return int
*/
public function getWeight()
{
return $this->container['weight'];
}
/**
* Sets weight
*
* @param int $weight Weight to apply to the IP. Sum of all IP weights must be 100. Should be passed for either ALL or NONE of the IPs. If it's not passed, the sending will be equally balanced on all IPs.
*
* @return $this
*/
public function setWeight($weight)
{
if (!is_null($weight) && ($weight > 100)) {
throw new \InvalidArgumentException('invalid value for $weight when calling CreateSenderIps., must be smaller than or equal to 100.');
}
if (!is_null($weight) && ($weight < 1)) {
throw new \InvalidArgumentException('invalid value for $weight when calling CreateSenderIps., must be bigger than or equal to 1.');
}
$this->container['weight'] = $weight;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,368 @@
<?php
/**
* CreateSenderModel
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSenderModel Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSenderModel implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSenderModel';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'spfError' => 'bool',
'dkimError' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'spfError' => null,
'dkimError' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'spfError' => 'spfError',
'dkimError' => 'dkimError'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'spfError' => 'setSpfError',
'dkimError' => 'setDkimError'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'spfError' => 'getSpfError',
'dkimError' => 'getDkimError'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['spfError'] = isset($data['spfError']) ? $data['spfError'] : null;
$this->container['dkimError'] = isset($data['dkimError']) ? $data['dkimError'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the Sender created
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets spfError
*
* @return bool
*/
public function getSpfError()
{
return $this->container['spfError'];
}
/**
* Sets spfError
*
* @param bool $spfError Status of SPF configuration for the sender (true = SPF not well configured, false = SPF well configured)
*
* @return $this
*/
public function setSpfError($spfError)
{
$this->container['spfError'] = $spfError;
return $this;
}
/**
* Gets dkimError
*
* @return bool
*/
public function getDkimError()
{
return $this->container['dkimError'];
}
/**
* Sets dkimError
*
* @param bool $dkimError Status of DKIM configuration for the sender (true = DKIM not well configured, false = DKIM well configured)
*
* @return $this
*/
public function setDkimError($dkimError)
{
$this->container['dkimError'] = $dkimError;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,451 @@
<?php
/**
* CreateSmsCampaign
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSmsCampaign Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSmsCampaign implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSmsCampaign';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'sender' => 'string',
'content' => 'string',
'recipients' => '\SendinBlue\Client\Model\CreateSmsCampaignRecipients',
'scheduledAt' => '\DateTime'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'sender' => null,
'content' => null,
'recipients' => null,
'scheduledAt' => 'date-time'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'sender' => 'sender',
'content' => 'content',
'recipients' => 'recipients',
'scheduledAt' => 'scheduledAt'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'sender' => 'setSender',
'content' => 'setContent',
'recipients' => 'setRecipients',
'scheduledAt' => 'setScheduledAt'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'sender' => 'getSender',
'content' => 'getContent',
'recipients' => 'getRecipients',
'scheduledAt' => 'getScheduledAt'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['sender'] = isset($data['sender']) ? $data['sender'] : null;
$this->container['content'] = isset($data['content']) ? $data['content'] : null;
$this->container['recipients'] = isset($data['recipients']) ? $data['recipients'] : null;
$this->container['scheduledAt'] = isset($data['scheduledAt']) ? $data['scheduledAt'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['sender'] === null) {
$invalidProperties[] = "'sender' can't be null";
}
if ((strlen($this->container['sender']) > 11)) {
$invalidProperties[] = "invalid value for 'sender', the character length must be smaller than or equal to 11.";
}
if ($this->container['content'] === null) {
$invalidProperties[] = "'content' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['sender'] === null) {
return false;
}
if (strlen($this->container['sender']) > 11) {
return false;
}
if ($this->container['content'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the campaign
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets sender
*
* @return string
*/
public function getSender()
{
return $this->container['sender'];
}
/**
* Sets sender
*
* @param string $sender Name of the sender. The number of characters is limited to 11
*
* @return $this
*/
public function setSender($sender)
{
if ((strlen($sender) > 11)) {
throw new \InvalidArgumentException('invalid length for $sender when calling CreateSmsCampaign., must be smaller than or equal to 11.');
}
$this->container['sender'] = $sender;
return $this;
}
/**
* Gets content
*
* @return string
*/
public function getContent()
{
return $this->container['content'];
}
/**
* Sets content
*
* @param string $content Content of the message. The maximum characters used per SMS is 160, if used more than that, it will be counted as more than one SMS
*
* @return $this
*/
public function setContent($content)
{
$this->container['content'] = $content;
return $this;
}
/**
* Gets recipients
*
* @return \SendinBlue\Client\Model\CreateSmsCampaignRecipients
*/
public function getRecipients()
{
return $this->container['recipients'];
}
/**
* Sets recipients
*
* @param \SendinBlue\Client\Model\CreateSmsCampaignRecipients $recipients recipients
*
* @return $this
*/
public function setRecipients($recipients)
{
$this->container['recipients'] = $recipients;
return $this;
}
/**
* Gets scheduledAt
*
* @return \DateTime
*/
public function getScheduledAt()
{
return $this->container['scheduledAt'];
}
/**
* Sets scheduledAt
*
* @param \DateTime $scheduledAt UTC date-time on which the campaign has to run (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.
*
* @return $this
*/
public function setScheduledAt($scheduledAt)
{
$this->container['scheduledAt'] = $scheduledAt;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,338 @@
<?php
/**
* CreateSmsCampaignRecipients
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSmsCampaignRecipients Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSmsCampaignRecipients implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSmsCampaign_recipients';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'listIds' => 'int[]',
'exclusionListIds' => 'int[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'listIds' => 'int64',
'exclusionListIds' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'listIds' => 'listIds',
'exclusionListIds' => 'exclusionListIds'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'listIds' => 'setListIds',
'exclusionListIds' => 'setExclusionListIds'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'listIds' => 'getListIds',
'exclusionListIds' => 'getExclusionListIds'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['listIds'] = isset($data['listIds']) ? $data['listIds'] : null;
$this->container['exclusionListIds'] = isset($data['exclusionListIds']) ? $data['exclusionListIds'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['listIds'] === null) {
$invalidProperties[] = "'listIds' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['listIds'] === null) {
return false;
}
return true;
}
/**
* Gets listIds
*
* @return int[]
*/
public function getListIds()
{
return $this->container['listIds'];
}
/**
* Sets listIds
*
* @param int[] $listIds Lists Ids to send the campaign to. REQUIRED if scheduledAt is not empty
*
* @return $this
*/
public function setListIds($listIds)
{
$this->container['listIds'] = $listIds;
return $this;
}
/**
* Gets exclusionListIds
*
* @return int[]
*/
public function getExclusionListIds()
{
return $this->container['exclusionListIds'];
}
/**
* Sets exclusionListIds
*
* @param int[] $exclusionListIds List ids which have to be excluded from a campaign
*
* @return $this
*/
public function setExclusionListIds($exclusionListIds)
{
$this->container['exclusionListIds'] = $exclusionListIds;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* CreateSmtpEmail
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSmtpEmail Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSmtpEmail implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSmtpEmail';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'messageId' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'messageId' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'messageId' => 'messageId'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'messageId' => 'setMessageId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'messageId' => 'getMessageId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['messageId'] = isset($data['messageId']) ? $data['messageId'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['messageId'] === null) {
$invalidProperties[] = "'messageId' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['messageId'] === null) {
return false;
}
return true;
}
/**
* Gets messageId
*
* @return string
*/
public function getMessageId()
{
return $this->container['messageId'];
}
/**
* Sets messageId
*
* @param string $messageId Message ID of the SMTP Email sent
*
* @return $this
*/
public function setMessageId($messageId)
{
$this->container['messageId'] = $messageId;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,590 @@
<?php
/**
* CreateSmtpTemplate
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSmtpTemplate Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSmtpTemplate implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSmtpTemplate';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'tag' => 'string',
'sender' => '\SendinBlue\Client\Model\CreateSmtpTemplateSender',
'templateName' => 'string',
'htmlContent' => 'string',
'htmlUrl' => 'string',
'subject' => 'string',
'replyTo' => 'string',
'toField' => 'string',
'attachmentUrl' => 'string',
'isActive' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'tag' => null,
'sender' => null,
'templateName' => null,
'htmlContent' => null,
'htmlUrl' => 'url',
'subject' => null,
'replyTo' => 'email',
'toField' => null,
'attachmentUrl' => 'url',
'isActive' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'tag' => 'tag',
'sender' => 'sender',
'templateName' => 'templateName',
'htmlContent' => 'htmlContent',
'htmlUrl' => 'htmlUrl',
'subject' => 'subject',
'replyTo' => 'replyTo',
'toField' => 'toField',
'attachmentUrl' => 'attachmentUrl',
'isActive' => 'isActive'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'tag' => 'setTag',
'sender' => 'setSender',
'templateName' => 'setTemplateName',
'htmlContent' => 'setHtmlContent',
'htmlUrl' => 'setHtmlUrl',
'subject' => 'setSubject',
'replyTo' => 'setReplyTo',
'toField' => 'setToField',
'attachmentUrl' => 'setAttachmentUrl',
'isActive' => 'setIsActive'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'tag' => 'getTag',
'sender' => 'getSender',
'templateName' => 'getTemplateName',
'htmlContent' => 'getHtmlContent',
'htmlUrl' => 'getHtmlUrl',
'subject' => 'getSubject',
'replyTo' => 'getReplyTo',
'toField' => 'getToField',
'attachmentUrl' => 'getAttachmentUrl',
'isActive' => 'getIsActive'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['tag'] = isset($data['tag']) ? $data['tag'] : null;
$this->container['sender'] = isset($data['sender']) ? $data['sender'] : null;
$this->container['templateName'] = isset($data['templateName']) ? $data['templateName'] : null;
$this->container['htmlContent'] = isset($data['htmlContent']) ? $data['htmlContent'] : null;
$this->container['htmlUrl'] = isset($data['htmlUrl']) ? $data['htmlUrl'] : null;
$this->container['subject'] = isset($data['subject']) ? $data['subject'] : null;
$this->container['replyTo'] = isset($data['replyTo']) ? $data['replyTo'] : null;
$this->container['toField'] = isset($data['toField']) ? $data['toField'] : null;
$this->container['attachmentUrl'] = isset($data['attachmentUrl']) ? $data['attachmentUrl'] : null;
$this->container['isActive'] = isset($data['isActive']) ? $data['isActive'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['sender'] === null) {
$invalidProperties[] = "'sender' can't be null";
}
if ($this->container['templateName'] === null) {
$invalidProperties[] = "'templateName' can't be null";
}
if ($this->container['subject'] === null) {
$invalidProperties[] = "'subject' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['sender'] === null) {
return false;
}
if ($this->container['templateName'] === null) {
return false;
}
if ($this->container['subject'] === null) {
return false;
}
return true;
}
/**
* Gets tag
*
* @return string
*/
public function getTag()
{
return $this->container['tag'];
}
/**
* Sets tag
*
* @param string $tag Tag of the template
*
* @return $this
*/
public function setTag($tag)
{
$this->container['tag'] = $tag;
return $this;
}
/**
* Gets sender
*
* @return \SendinBlue\Client\Model\CreateSmtpTemplateSender
*/
public function getSender()
{
return $this->container['sender'];
}
/**
* Sets sender
*
* @param \SendinBlue\Client\Model\CreateSmtpTemplateSender $sender sender
*
* @return $this
*/
public function setSender($sender)
{
$this->container['sender'] = $sender;
return $this;
}
/**
* Gets templateName
*
* @return string
*/
public function getTemplateName()
{
return $this->container['templateName'];
}
/**
* Sets templateName
*
* @param string $templateName Name of the template
*
* @return $this
*/
public function setTemplateName($templateName)
{
$this->container['templateName'] = $templateName;
return $this;
}
/**
* Gets htmlContent
*
* @return string
*/
public function getHtmlContent()
{
return $this->container['htmlContent'];
}
/**
* Sets htmlContent
*
* @param string $htmlContent Body of the message (HTML version). The field must have more than 10 characters. REQUIRED if htmlUrl is empty
*
* @return $this
*/
public function setHtmlContent($htmlContent)
{
$this->container['htmlContent'] = $htmlContent;
return $this;
}
/**
* Gets htmlUrl
*
* @return string
*/
public function getHtmlUrl()
{
return $this->container['htmlUrl'];
}
/**
* Sets htmlUrl
*
* @param string $htmlUrl Url which contents the body of the email message. REQUIRED if htmlContent is empty
*
* @return $this
*/
public function setHtmlUrl($htmlUrl)
{
$this->container['htmlUrl'] = $htmlUrl;
return $this;
}
/**
* Gets subject
*
* @return string
*/
public function getSubject()
{
return $this->container['subject'];
}
/**
* Sets subject
*
* @param string $subject Subject of the template
*
* @return $this
*/
public function setSubject($subject)
{
$this->container['subject'] = $subject;
return $this;
}
/**
* Gets replyTo
*
* @return string
*/
public function getReplyTo()
{
return $this->container['replyTo'];
}
/**
* Sets replyTo
*
* @param string $replyTo Email on which campaign recipients will be able to reply to
*
* @return $this
*/
public function setReplyTo($replyTo)
{
$this->container['replyTo'] = $replyTo;
return $this;
}
/**
* Gets toField
*
* @return string
*/
public function getToField()
{
return $this->container['toField'];
}
/**
* Sets toField
*
* @param string $toField To personalize the «To» Field. If you want to include the first name and last name of your recipient, add `{FNAME} {LNAME}`. These contact attributes must already exist in your SendinBlue account. If input parameter 'params' used please use `{{contact.FNAME}} {{contact.LNAME}}` for personalization
*
* @return $this
*/
public function setToField($toField)
{
$this->container['toField'] = $toField;
return $this;
}
/**
* Gets attachmentUrl
*
* @return string
*/
public function getAttachmentUrl()
{
return $this->container['attachmentUrl'];
}
/**
* Sets attachmentUrl
*
* @param string $attachmentUrl Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps
*
* @return $this
*/
public function setAttachmentUrl($attachmentUrl)
{
$this->container['attachmentUrl'] = $attachmentUrl;
return $this;
}
/**
* Gets isActive
*
* @return bool
*/
public function getIsActive()
{
return $this->container['isActive'];
}
/**
* Sets isActive
*
* @param bool $isActive Status of template. isActive = true means template is active and isActive = false means template is inactive
*
* @return $this
*/
public function setIsActive($isActive)
{
$this->container['isActive'] = $isActive;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,339 @@
<?php
/**
* CreateSmtpTemplateSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateSmtpTemplateSender Class Doc Comment
*
* @category Class
* @description Sender details including email and name (optional). For example &#x60;{\&quot;name\&quot;:\&quot;xyz\&quot;, \&quot;email\&quot;:\&quot;example@abc.com\&quot;}&#x60;
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateSmtpTemplateSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createSmtpTemplate_sender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'email' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'email' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'email' => 'email'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'email' => 'setEmail'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'email' => 'getEmail'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the sender. If not passed, will be set to default
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email of the sender
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* CreateUpdateContactModel
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateUpdateContactModel Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateUpdateContactModel implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createUpdateContactModel';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the contact when a new contact is created
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* CreateUpdateFolder
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateUpdateFolder Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateUpdateFolder implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createUpdateFolder';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the folder
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,486 @@
<?php
/**
* CreateWebhook
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreateWebhook Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreateWebhook implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createWebhook';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'url' => 'string',
'description' => 'string',
'events' => 'string[]',
'type' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'url' => 'url',
'description' => null,
'events' => null,
'type' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'url' => 'url',
'description' => 'description',
'events' => 'events',
'type' => 'type'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'url' => 'setUrl',
'description' => 'setDescription',
'events' => 'setEvents',
'type' => 'setType'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'url' => 'getUrl',
'description' => 'getDescription',
'events' => 'getEvents',
'type' => 'getType'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const EVENTS_HARD_BOUNCE = 'hardBounce';
const EVENTS_SOFT_BOUNCE = 'softBounce';
const EVENTS_BLOCKED = 'blocked';
const EVENTS_SPAM = 'spam';
const EVENTS_DELIVERED = 'delivered';
const EVENTS_REQUEST = 'request';
const EVENTS_CLICK = 'click';
const EVENTS_INVALID = 'invalid';
const EVENTS_DEFERRED = 'deferred';
const EVENTS_OPENED = 'opened';
const EVENTS_UNIQUE_OPENED = 'uniqueOpened';
const EVENTS_UNSUBSCRIBED = 'unsubscribed';
const EVENTS_LIST_ADDITION = 'listAddition';
const TYPE_TRANSACTIONAL = 'transactional';
const TYPE_MARKETING = 'marketing';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getEventsAllowableValues()
{
return [
self::EVENTS_HARD_BOUNCE,
self::EVENTS_SOFT_BOUNCE,
self::EVENTS_BLOCKED,
self::EVENTS_SPAM,
self::EVENTS_DELIVERED,
self::EVENTS_REQUEST,
self::EVENTS_CLICK,
self::EVENTS_INVALID,
self::EVENTS_DEFERRED,
self::EVENTS_OPENED,
self::EVENTS_UNIQUE_OPENED,
self::EVENTS_UNSUBSCRIBED,
self::EVENTS_LIST_ADDITION,
];
}
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getTypeAllowableValues()
{
return [
self::TYPE_TRANSACTIONAL,
self::TYPE_MARKETING,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['url'] = isset($data['url']) ? $data['url'] : null;
$this->container['description'] = isset($data['description']) ? $data['description'] : null;
$this->container['events'] = isset($data['events']) ? $data['events'] : null;
$this->container['type'] = isset($data['type']) ? $data['type'] : 'transactional';
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['url'] === null) {
$invalidProperties[] = "'url' can't be null";
}
if ($this->container['events'] === null) {
$invalidProperties[] = "'events' can't be null";
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['url'] === null) {
return false;
}
if ($this->container['events'] === null) {
return false;
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets url
*
* @return string
*/
public function getUrl()
{
return $this->container['url'];
}
/**
* Sets url
*
* @param string $url URL of the webhook
*
* @return $this
*/
public function setUrl($url)
{
$this->container['url'] = $url;
return $this;
}
/**
* Gets description
*
* @return string
*/
public function getDescription()
{
return $this->container['description'];
}
/**
* Sets description
*
* @param string $description Description of the webhook
*
* @return $this
*/
public function setDescription($description)
{
$this->container['description'] = $description;
return $this;
}
/**
* Gets events
*
* @return string[]
*/
public function getEvents()
{
return $this->container['events'];
}
/**
* Sets events
*
* @param string[] $events Events triggering the webhook. Possible values for Transactional type webhook request, delivered, hardBounce, softBounce, blocked, spam, invalid, deferred, click, opened, uniqueOpened and unsubscribed and possible values for Marketing type webhook spam, opened, click, hardBounce, softBounce, unsubscribed, listAddition & delivered
*
* @return $this
*/
public function setEvents($events)
{
$allowedValues = $this->getEventsAllowableValues();
if (array_diff($events, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'events', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['events'] = $events;
return $this;
}
/**
* Gets type
*
* @return string
*/
public function getType()
{
return $this->container['type'];
}
/**
* Sets type
*
* @param string $type Type of the webhook
*
* @return $this
*/
public function setType($type)
{
$allowedValues = $this->getTypeAllowableValues();
if (!is_null($type) && !in_array($type, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['type'] = $type;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* CreatedProcessId
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* CreatedProcessId Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class CreatedProcessId implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'createdProcessId';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'processId' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'processId' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'processId' => 'processId'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'processId' => 'setProcessId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'processId' => 'getProcessId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['processId'] = isset($data['processId']) ? $data['processId'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['processId'] === null) {
$invalidProperties[] = "'processId' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['processId'] === null) {
return false;
}
return true;
}
/**
* Gets processId
*
* @return int
*/
public function getProcessId()
{
return $this->container['processId'];
}
/**
* Sets processId
*
* @param int $processId Id of the process created
*
* @return $this
*/
public function setProcessId($processId)
{
$this->container['processId'] = $processId;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,362 @@
<?php
/**
* DeleteHardbounces
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* DeleteHardbounces Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class DeleteHardbounces implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'deleteHardbounces';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'startDate' => 'string',
'endDate' => 'string',
'contactEmail' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'startDate' => null,
'endDate' => null,
'contactEmail' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'startDate' => 'startDate',
'endDate' => 'endDate',
'contactEmail' => 'contactEmail'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'startDate' => 'setStartDate',
'endDate' => 'setEndDate',
'contactEmail' => 'setContactEmail'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'startDate' => 'getStartDate',
'endDate' => 'getEndDate',
'contactEmail' => 'getContactEmail'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['startDate'] = isset($data['startDate']) ? $data['startDate'] : null;
$this->container['endDate'] = isset($data['endDate']) ? $data['endDate'] : null;
$this->container['contactEmail'] = isset($data['contactEmail']) ? $data['contactEmail'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets startDate
*
* @return string
*/
public function getStartDate()
{
return $this->container['startDate'];
}
/**
* Sets startDate
*
* @param string $startDate Starting date (YYYY-MM-DD) of the time period for deletion. The hardbounces occurred after this date will be deleted. Must be less than or equal to the endDate
*
* @return $this
*/
public function setStartDate($startDate)
{
$this->container['startDate'] = $startDate;
return $this;
}
/**
* Gets endDate
*
* @return string
*/
public function getEndDate()
{
return $this->container['endDate'];
}
/**
* Sets endDate
*
* @param string $endDate Ending date (YYYY-MM-DD) of the time period for deletion. The hardbounces until this date will be deleted. Must be greater than or equal to the startDate
*
* @return $this
*/
public function setEndDate($endDate)
{
$this->container['endDate'] = $endDate;
return $this;
}
/**
* Gets contactEmail
*
* @return string
*/
public function getContactEmail()
{
return $this->container['contactEmail'];
}
/**
* Sets contactEmail
*
* @param string $contactEmail Target a specific email address
*
* @return $this
*/
public function setContactEmail($contactEmail)
{
$this->container['contactEmail'] = $contactEmail;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,386 @@
<?php
/**
* EmailExportRecipients
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* EmailExportRecipients Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class EmailExportRecipients implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'emailExportRecipients';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'notifyURL' => 'string',
'recipientsType' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'notifyURL' => 'url',
'recipientsType' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'notifyURL' => 'notifyURL',
'recipientsType' => 'recipientsType'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'notifyURL' => 'setNotifyURL',
'recipientsType' => 'setRecipientsType'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'notifyURL' => 'getNotifyURL',
'recipientsType' => 'getRecipientsType'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const RECIPIENTS_TYPE_ALL = 'all';
const RECIPIENTS_TYPE_NON_CLICKERS = 'nonClickers';
const RECIPIENTS_TYPE_NON_OPENERS = 'nonOpeners';
const RECIPIENTS_TYPE_CLICKERS = 'clickers';
const RECIPIENTS_TYPE_OPENERS = 'openers';
const RECIPIENTS_TYPE_SOFT_BOUNCES = 'softBounces';
const RECIPIENTS_TYPE_HARD_BOUNCES = 'hardBounces';
const RECIPIENTS_TYPE_UNSUBSCRIBED = 'unsubscribed';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getRecipientsTypeAllowableValues()
{
return [
self::RECIPIENTS_TYPE_ALL,
self::RECIPIENTS_TYPE_NON_CLICKERS,
self::RECIPIENTS_TYPE_NON_OPENERS,
self::RECIPIENTS_TYPE_CLICKERS,
self::RECIPIENTS_TYPE_OPENERS,
self::RECIPIENTS_TYPE_SOFT_BOUNCES,
self::RECIPIENTS_TYPE_HARD_BOUNCES,
self::RECIPIENTS_TYPE_UNSUBSCRIBED,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['notifyURL'] = isset($data['notifyURL']) ? $data['notifyURL'] : null;
$this->container['recipientsType'] = isset($data['recipientsType']) ? $data['recipientsType'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['recipientsType'] === null) {
$invalidProperties[] = "'recipientsType' can't be null";
}
$allowedValues = $this->getRecipientsTypeAllowableValues();
if (!in_array($this->container['recipientsType'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'recipientsType', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['recipientsType'] === null) {
return false;
}
$allowedValues = $this->getRecipientsTypeAllowableValues();
if (!in_array($this->container['recipientsType'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets notifyURL
*
* @return string
*/
public function getNotifyURL()
{
return $this->container['notifyURL'];
}
/**
* Sets notifyURL
*
* @param string $notifyURL Webhook called once the export process is finished
*
* @return $this
*/
public function setNotifyURL($notifyURL)
{
$this->container['notifyURL'] = $notifyURL;
return $this;
}
/**
* Gets recipientsType
*
* @return string
*/
public function getRecipientsType()
{
return $this->container['recipientsType'];
}
/**
* Sets recipientsType
*
* @param string $recipientsType Type of recipients to export for a campaign
*
* @return $this
*/
public function setRecipientsType($recipientsType)
{
$allowedValues = $this->getRecipientsTypeAllowableValues();
if (!in_array($recipientsType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'recipientsType', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['recipientsType'] = $recipientsType;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,406 @@
<?php
/**
* ErrorModel
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* ErrorModel Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class ErrorModel implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'errorModel';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'code' => 'string',
'message' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'code' => null,
'message' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'code' => 'code',
'message' => 'message'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'code' => 'setCode',
'message' => 'setMessage'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'code' => 'getCode',
'message' => 'getMessage'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const CODE_INVALID_PARAMETER = 'invalid_parameter';
const CODE_MISSING_PARAMETER = 'missing_parameter';
const CODE_OUT_OF_RANGE = 'out_of_range';
const CODE_CAMPAIGN_PROCESSING = 'campaign_processing';
const CODE_CAMPAIGN_SENT = 'campaign_sent';
const CODE_DOCUMENT_NOT_FOUND = 'document_not_found';
const CODE_RESELLER_PERMISSION_DENIED = 'reseller_permission_denied';
const CODE_NOT_ENOUGH_CREDITS = 'not_enough_credits';
const CODE_PERMISSION_DENIED = 'permission_denied';
const CODE_DUPLICATE_PARAMETER = 'duplicate_parameter';
const CODE_DUPLICATE_REQUEST = 'duplicate_request';
const CODE_METHOD_NOT_ALLOWED = 'method_not_allowed';
const CODE_UNAUTHORIZED = 'unauthorized';
const CODE_ACCOUNT_UNDER_VALIDATION = 'account_under_validation';
const CODE_NOT_ACCEPTABLE = 'not_acceptable';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getCodeAllowableValues()
{
return [
self::CODE_INVALID_PARAMETER,
self::CODE_MISSING_PARAMETER,
self::CODE_OUT_OF_RANGE,
self::CODE_CAMPAIGN_PROCESSING,
self::CODE_CAMPAIGN_SENT,
self::CODE_DOCUMENT_NOT_FOUND,
self::CODE_RESELLER_PERMISSION_DENIED,
self::CODE_NOT_ENOUGH_CREDITS,
self::CODE_PERMISSION_DENIED,
self::CODE_DUPLICATE_PARAMETER,
self::CODE_DUPLICATE_REQUEST,
self::CODE_METHOD_NOT_ALLOWED,
self::CODE_UNAUTHORIZED,
self::CODE_ACCOUNT_UNDER_VALIDATION,
self::CODE_NOT_ACCEPTABLE,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['code'] = isset($data['code']) ? $data['code'] : null;
$this->container['message'] = isset($data['message']) ? $data['message'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['code'] === null) {
$invalidProperties[] = "'code' can't be null";
}
$allowedValues = $this->getCodeAllowableValues();
if (!in_array($this->container['code'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'code', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['message'] === null) {
$invalidProperties[] = "'message' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['code'] === null) {
return false;
}
$allowedValues = $this->getCodeAllowableValues();
if (!in_array($this->container['code'], $allowedValues)) {
return false;
}
if ($this->container['message'] === null) {
return false;
}
return true;
}
/**
* Gets code
*
* @return string
*/
public function getCode()
{
return $this->container['code'];
}
/**
* Sets code
*
* @param string $code Error code displayed in case of a failure
*
* @return $this
*/
public function setCode($code)
{
$allowedValues = $this->getCodeAllowableValues();
if (!in_array($code, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'code', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['code'] = $code;
return $this;
}
/**
* Gets message
*
* @return string
*/
public function getMessage()
{
return $this->container['message'];
}
/**
* Sets message
*
* @param string $message Readable message associated to the failure
*
* @return $this
*/
public function setMessage($message)
{
$this->container['message'] = $message;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,554 @@
<?php
/**
* GetAccount
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAccount Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAccount implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAccount';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'firstName' => 'string',
'lastName' => 'string',
'companyName' => 'string',
'address' => '\SendinBlue\Client\Model\GetExtendedClientAddress',
'plan' => '\SendinBlue\Client\Model\GetAccountPlan[]',
'relay' => '\SendinBlue\Client\Model\GetAccountRelay',
'marketingAutomation' => '\SendinBlue\Client\Model\GetAccountMarketingAutomation'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'firstName' => null,
'lastName' => null,
'companyName' => null,
'address' => null,
'plan' => null,
'relay' => null,
'marketingAutomation' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'firstName' => 'firstName',
'lastName' => 'lastName',
'companyName' => 'companyName',
'address' => 'address',
'plan' => 'plan',
'relay' => 'relay',
'marketingAutomation' => 'marketingAutomation'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'firstName' => 'setFirstName',
'lastName' => 'setLastName',
'companyName' => 'setCompanyName',
'address' => 'setAddress',
'plan' => 'setPlan',
'relay' => 'setRelay',
'marketingAutomation' => 'setMarketingAutomation'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'firstName' => 'getFirstName',
'lastName' => 'getLastName',
'companyName' => 'getCompanyName',
'address' => 'getAddress',
'plan' => 'getPlan',
'relay' => 'getRelay',
'marketingAutomation' => 'getMarketingAutomation'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['firstName'] = isset($data['firstName']) ? $data['firstName'] : null;
$this->container['lastName'] = isset($data['lastName']) ? $data['lastName'] : null;
$this->container['companyName'] = isset($data['companyName']) ? $data['companyName'] : null;
$this->container['address'] = isset($data['address']) ? $data['address'] : null;
$this->container['plan'] = isset($data['plan']) ? $data['plan'] : null;
$this->container['relay'] = isset($data['relay']) ? $data['relay'] : null;
$this->container['marketingAutomation'] = isset($data['marketingAutomation']) ? $data['marketingAutomation'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['firstName'] === null) {
$invalidProperties[] = "'firstName' can't be null";
}
if ($this->container['lastName'] === null) {
$invalidProperties[] = "'lastName' can't be null";
}
if ($this->container['companyName'] === null) {
$invalidProperties[] = "'companyName' can't be null";
}
if ($this->container['address'] === null) {
$invalidProperties[] = "'address' can't be null";
}
if ($this->container['plan'] === null) {
$invalidProperties[] = "'plan' can't be null";
}
if ($this->container['relay'] === null) {
$invalidProperties[] = "'relay' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['firstName'] === null) {
return false;
}
if ($this->container['lastName'] === null) {
return false;
}
if ($this->container['companyName'] === null) {
return false;
}
if ($this->container['address'] === null) {
return false;
}
if ($this->container['plan'] === null) {
return false;
}
if ($this->container['relay'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Login Email
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets firstName
*
* @return string
*/
public function getFirstName()
{
return $this->container['firstName'];
}
/**
* Sets firstName
*
* @param string $firstName First Name
*
* @return $this
*/
public function setFirstName($firstName)
{
$this->container['firstName'] = $firstName;
return $this;
}
/**
* Gets lastName
*
* @return string
*/
public function getLastName()
{
return $this->container['lastName'];
}
/**
* Sets lastName
*
* @param string $lastName Last Name
*
* @return $this
*/
public function setLastName($lastName)
{
$this->container['lastName'] = $lastName;
return $this;
}
/**
* Gets companyName
*
* @return string
*/
public function getCompanyName()
{
return $this->container['companyName'];
}
/**
* Sets companyName
*
* @param string $companyName Name of the company
*
* @return $this
*/
public function setCompanyName($companyName)
{
$this->container['companyName'] = $companyName;
return $this;
}
/**
* Gets address
*
* @return \SendinBlue\Client\Model\GetExtendedClientAddress
*/
public function getAddress()
{
return $this->container['address'];
}
/**
* Sets address
*
* @param \SendinBlue\Client\Model\GetExtendedClientAddress $address address
*
* @return $this
*/
public function setAddress($address)
{
$this->container['address'] = $address;
return $this;
}
/**
* Gets plan
*
* @return \SendinBlue\Client\Model\GetAccountPlan[]
*/
public function getPlan()
{
return $this->container['plan'];
}
/**
* Sets plan
*
* @param \SendinBlue\Client\Model\GetAccountPlan[] $plan Information about your plans and credits
*
* @return $this
*/
public function setPlan($plan)
{
$this->container['plan'] = $plan;
return $this;
}
/**
* Gets relay
*
* @return \SendinBlue\Client\Model\GetAccountRelay
*/
public function getRelay()
{
return $this->container['relay'];
}
/**
* Sets relay
*
* @param \SendinBlue\Client\Model\GetAccountRelay $relay relay
*
* @return $this
*/
public function setRelay($relay)
{
$this->container['relay'] = $relay;
return $this;
}
/**
* Gets marketingAutomation
*
* @return \SendinBlue\Client\Model\GetAccountMarketingAutomation
*/
public function getMarketingAutomation()
{
return $this->container['marketingAutomation'];
}
/**
* Sets marketingAutomation
*
* @param \SendinBlue\Client\Model\GetAccountMarketingAutomation $marketingAutomation marketingAutomation
*
* @return $this
*/
public function setMarketingAutomation($marketingAutomation)
{
$this->container['marketingAutomation'] = $marketingAutomation;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,338 @@
<?php
/**
* GetAccountMarketingAutomation
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAccountMarketingAutomation Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAccountMarketingAutomation implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAccount_marketingAutomation';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'key' => 'string',
'enabled' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'key' => null,
'enabled' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'key' => 'key',
'enabled' => 'enabled'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'key' => 'setKey',
'enabled' => 'setEnabled'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'key' => 'getKey',
'enabled' => 'getEnabled'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['key'] = isset($data['key']) ? $data['key'] : null;
$this->container['enabled'] = isset($data['enabled']) ? $data['enabled'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['enabled'] === null) {
$invalidProperties[] = "'enabled' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['enabled'] === null) {
return false;
}
return true;
}
/**
* Gets key
*
* @return string
*/
public function getKey()
{
return $this->container['key'];
}
/**
* Sets key
*
* @param string $key Marketing Automation Tracker ID
*
* @return $this
*/
public function setKey($key)
{
$this->container['key'] = $key;
return $this;
}
/**
* Gets enabled
*
* @return bool
*/
public function getEnabled()
{
return $this->container['enabled'];
}
/**
* Sets enabled
*
* @param bool $enabled Status of Marketing Automation Plateform activation for your account (true=enabled, false=disabled)
*
* @return $this
*/
public function setEnabled($enabled)
{
$this->container['enabled'] = $enabled;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,546 @@
<?php
/**
* GetAccountPlan
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAccountPlan Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAccountPlan implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAccount_plan';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'type' => 'string',
'creditsType' => 'string',
'credits' => 'float',
'startDate' => '\DateTime',
'endDate' => '\DateTime',
'userLimit' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'type' => null,
'creditsType' => null,
'credits' => 'float',
'startDate' => 'date',
'endDate' => 'date',
'userLimit' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'type' => 'type',
'creditsType' => 'creditsType',
'credits' => 'credits',
'startDate' => 'startDate',
'endDate' => 'endDate',
'userLimit' => 'userLimit'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'type' => 'setType',
'creditsType' => 'setCreditsType',
'credits' => 'setCredits',
'startDate' => 'setStartDate',
'endDate' => 'setEndDate',
'userLimit' => 'setUserLimit'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'type' => 'getType',
'creditsType' => 'getCreditsType',
'credits' => 'getCredits',
'startDate' => 'getStartDate',
'endDate' => 'getEndDate',
'userLimit' => 'getUserLimit'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const TYPE_PAY_AS_YOU_GO = 'payAsYouGo';
const TYPE_FREE = 'free';
const TYPE_SUBSCRIPTION = 'subscription';
const TYPE_SMS = 'sms';
const TYPE_RESELLER = 'reseller';
const CREDITS_TYPE_SEND_LIMIT = 'sendLimit';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getTypeAllowableValues()
{
return [
self::TYPE_PAY_AS_YOU_GO,
self::TYPE_FREE,
self::TYPE_SUBSCRIPTION,
self::TYPE_SMS,
self::TYPE_RESELLER,
];
}
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getCreditsTypeAllowableValues()
{
return [
self::CREDITS_TYPE_SEND_LIMIT,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['type'] = isset($data['type']) ? $data['type'] : null;
$this->container['creditsType'] = isset($data['creditsType']) ? $data['creditsType'] : null;
$this->container['credits'] = isset($data['credits']) ? $data['credits'] : null;
$this->container['startDate'] = isset($data['startDate']) ? $data['startDate'] : null;
$this->container['endDate'] = isset($data['endDate']) ? $data['endDate'] : null;
$this->container['userLimit'] = isset($data['userLimit']) ? $data['userLimit'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['type'] === null) {
$invalidProperties[] = "'type' can't be null";
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['creditsType'] === null) {
$invalidProperties[] = "'creditsType' can't be null";
}
$allowedValues = $this->getCreditsTypeAllowableValues();
if (!in_array($this->container['creditsType'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'creditsType', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['credits'] === null) {
$invalidProperties[] = "'credits' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['type'] === null) {
return false;
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
return false;
}
if ($this->container['creditsType'] === null) {
return false;
}
$allowedValues = $this->getCreditsTypeAllowableValues();
if (!in_array($this->container['creditsType'], $allowedValues)) {
return false;
}
if ($this->container['credits'] === null) {
return false;
}
return true;
}
/**
* Gets type
*
* @return string
*/
public function getType()
{
return $this->container['type'];
}
/**
* Sets type
*
* @param string $type Displays the plan type of the user
*
* @return $this
*/
public function setType($type)
{
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($type, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['type'] = $type;
return $this;
}
/**
* Gets creditsType
*
* @return string
*/
public function getCreditsType()
{
return $this->container['creditsType'];
}
/**
* Sets creditsType
*
* @param string $creditsType This is the type of the credit, \"Send Limit\" is one of the possible types of credit of a user. \"Send Limit\" implies the total number of emails you can send to the subscribers in your account.
*
* @return $this
*/
public function setCreditsType($creditsType)
{
$allowedValues = $this->getCreditsTypeAllowableValues();
if (!in_array($creditsType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'creditsType', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['creditsType'] = $creditsType;
return $this;
}
/**
* Gets credits
*
* @return float
*/
public function getCredits()
{
return $this->container['credits'];
}
/**
* Sets credits
*
* @param float $credits Remaining credits of the user
*
* @return $this
*/
public function setCredits($credits)
{
$this->container['credits'] = $credits;
return $this;
}
/**
* Gets startDate
*
* @return \DateTime
*/
public function getStartDate()
{
return $this->container['startDate'];
}
/**
* Sets startDate
*
* @param \DateTime $startDate Date of the period from which the plan will start (only available for \"subscription\" and \"reseller\" plan type)
*
* @return $this
*/
public function setStartDate($startDate)
{
$this->container['startDate'] = $startDate;
return $this;
}
/**
* Gets endDate
*
* @return \DateTime
*/
public function getEndDate()
{
return $this->container['endDate'];
}
/**
* Sets endDate
*
* @param \DateTime $endDate Date of the period from which the plan will end (only available for \"subscription\" and \"reseller\" plan type)
*
* @return $this
*/
public function setEndDate($endDate)
{
$this->container['endDate'] = $endDate;
return $this;
}
/**
* Gets userLimit
*
* @return int
*/
public function getUserLimit()
{
return $this->container['userLimit'];
}
/**
* Sets userLimit
*
* @param int $userLimit Only in case of reseller account. It implies the total number of child accounts you can add to your account.
*
* @return $this
*/
public function setUserLimit($userLimit)
{
$this->container['userLimit'] = $userLimit;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,345 @@
<?php
/**
* GetAccountRelay
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAccountRelay Class Doc Comment
*
* @category Class
* @description Information about your SMTP account
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAccountRelay implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAccount_relay';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'enabled' => 'bool',
'data' => '\SendinBlue\Client\Model\GetAccountRelayData'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'enabled' => null,
'data' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'enabled' => 'enabled',
'data' => 'data'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'enabled' => 'setEnabled',
'data' => 'setData'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'enabled' => 'getEnabled',
'data' => 'getData'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['enabled'] = isset($data['enabled']) ? $data['enabled'] : null;
$this->container['data'] = isset($data['data']) ? $data['data'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['enabled'] === null) {
$invalidProperties[] = "'enabled' can't be null";
}
if ($this->container['data'] === null) {
$invalidProperties[] = "'data' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['enabled'] === null) {
return false;
}
if ($this->container['data'] === null) {
return false;
}
return true;
}
/**
* Gets enabled
*
* @return bool
*/
public function getEnabled()
{
return $this->container['enabled'];
}
/**
* Sets enabled
*
* @param bool $enabled Status of your SMTP Account (true=Enabled, false=Disabled)
*
* @return $this
*/
public function setEnabled($enabled)
{
$this->container['enabled'] = $enabled;
return $this;
}
/**
* Gets data
*
* @return \SendinBlue\Client\Model\GetAccountRelayData
*/
public function getData()
{
return $this->container['data'];
}
/**
* Sets data
*
* @param \SendinBlue\Client\Model\GetAccountRelayData $data data
*
* @return $this
*/
public function setData($data)
{
$this->container['data'] = $data;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,381 @@
<?php
/**
* GetAccountRelayData
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAccountRelayData Class Doc Comment
*
* @category Class
* @description Data regarding the SMTP account
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAccountRelayData implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAccount_relay_data';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'userName' => 'string',
'relay' => 'string',
'port' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'userName' => 'email',
'relay' => null,
'port' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'userName' => 'userName',
'relay' => 'relay',
'port' => 'port'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'userName' => 'setUserName',
'relay' => 'setRelay',
'port' => 'setPort'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'userName' => 'getUserName',
'relay' => 'getRelay',
'port' => 'getPort'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['userName'] = isset($data['userName']) ? $data['userName'] : null;
$this->container['relay'] = isset($data['relay']) ? $data['relay'] : null;
$this->container['port'] = isset($data['port']) ? $data['port'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['userName'] === null) {
$invalidProperties[] = "'userName' can't be null";
}
if ($this->container['relay'] === null) {
$invalidProperties[] = "'relay' can't be null";
}
if ($this->container['port'] === null) {
$invalidProperties[] = "'port' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['userName'] === null) {
return false;
}
if ($this->container['relay'] === null) {
return false;
}
if ($this->container['port'] === null) {
return false;
}
return true;
}
/**
* Gets userName
*
* @return string
*/
public function getUserName()
{
return $this->container['userName'];
}
/**
* Sets userName
*
* @param string $userName Email to use as login on SMTP
*
* @return $this
*/
public function setUserName($userName)
{
$this->container['userName'] = $userName;
return $this;
}
/**
* Gets relay
*
* @return string
*/
public function getRelay()
{
return $this->container['relay'];
}
/**
* Sets relay
*
* @param string $relay URL of the SMTP Relay
*
* @return $this
*/
public function setRelay($relay)
{
$this->container['relay'] = $relay;
return $this;
}
/**
* Gets port
*
* @return int
*/
public function getPort()
{
return $this->container['port'];
}
/**
* Sets port
*
* @param int $port Port used for SMTP Relay
*
* @return $this
*/
public function setPort($port)
{
$this->container['port'] = $port;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,740 @@
<?php
/**
* GetAggregatedReport
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAggregatedReport Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAggregatedReport implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAggregatedReport';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'range' => 'string',
'requests' => 'int',
'delivered' => 'int',
'hardBounces' => 'int',
'softBounces' => 'int',
'clicks' => 'int',
'uniqueClicks' => 'int',
'opens' => 'int',
'uniqueOpens' => 'int',
'spamReports' => 'int',
'blocked' => 'int',
'invalid' => 'int',
'unsubscribed' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'range' => null,
'requests' => 'int64',
'delivered' => 'int64',
'hardBounces' => 'int64',
'softBounces' => 'int64',
'clicks' => 'int64',
'uniqueClicks' => 'int64',
'opens' => 'int64',
'uniqueOpens' => 'int64',
'spamReports' => 'int64',
'blocked' => 'int64',
'invalid' => 'int64',
'unsubscribed' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'range' => 'range',
'requests' => 'requests',
'delivered' => 'delivered',
'hardBounces' => 'hardBounces',
'softBounces' => 'softBounces',
'clicks' => 'clicks',
'uniqueClicks' => 'uniqueClicks',
'opens' => 'opens',
'uniqueOpens' => 'uniqueOpens',
'spamReports' => 'spamReports',
'blocked' => 'blocked',
'invalid' => 'invalid',
'unsubscribed' => 'unsubscribed'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'range' => 'setRange',
'requests' => 'setRequests',
'delivered' => 'setDelivered',
'hardBounces' => 'setHardBounces',
'softBounces' => 'setSoftBounces',
'clicks' => 'setClicks',
'uniqueClicks' => 'setUniqueClicks',
'opens' => 'setOpens',
'uniqueOpens' => 'setUniqueOpens',
'spamReports' => 'setSpamReports',
'blocked' => 'setBlocked',
'invalid' => 'setInvalid',
'unsubscribed' => 'setUnsubscribed'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'range' => 'getRange',
'requests' => 'getRequests',
'delivered' => 'getDelivered',
'hardBounces' => 'getHardBounces',
'softBounces' => 'getSoftBounces',
'clicks' => 'getClicks',
'uniqueClicks' => 'getUniqueClicks',
'opens' => 'getOpens',
'uniqueOpens' => 'getUniqueOpens',
'spamReports' => 'getSpamReports',
'blocked' => 'getBlocked',
'invalid' => 'getInvalid',
'unsubscribed' => 'getUnsubscribed'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['range'] = isset($data['range']) ? $data['range'] : null;
$this->container['requests'] = isset($data['requests']) ? $data['requests'] : null;
$this->container['delivered'] = isset($data['delivered']) ? $data['delivered'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['clicks'] = isset($data['clicks']) ? $data['clicks'] : null;
$this->container['uniqueClicks'] = isset($data['uniqueClicks']) ? $data['uniqueClicks'] : null;
$this->container['opens'] = isset($data['opens']) ? $data['opens'] : null;
$this->container['uniqueOpens'] = isset($data['uniqueOpens']) ? $data['uniqueOpens'] : null;
$this->container['spamReports'] = isset($data['spamReports']) ? $data['spamReports'] : null;
$this->container['blocked'] = isset($data['blocked']) ? $data['blocked'] : null;
$this->container['invalid'] = isset($data['invalid']) ? $data['invalid'] : null;
$this->container['unsubscribed'] = isset($data['unsubscribed']) ? $data['unsubscribed'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['range'] === null) {
$invalidProperties[] = "'range' can't be null";
}
if ($this->container['requests'] === null) {
$invalidProperties[] = "'requests' can't be null";
}
if ($this->container['delivered'] === null) {
$invalidProperties[] = "'delivered' can't be null";
}
if ($this->container['hardBounces'] === null) {
$invalidProperties[] = "'hardBounces' can't be null";
}
if ($this->container['softBounces'] === null) {
$invalidProperties[] = "'softBounces' can't be null";
}
if ($this->container['clicks'] === null) {
$invalidProperties[] = "'clicks' can't be null";
}
if ($this->container['uniqueClicks'] === null) {
$invalidProperties[] = "'uniqueClicks' can't be null";
}
if ($this->container['opens'] === null) {
$invalidProperties[] = "'opens' can't be null";
}
if ($this->container['uniqueOpens'] === null) {
$invalidProperties[] = "'uniqueOpens' can't be null";
}
if ($this->container['spamReports'] === null) {
$invalidProperties[] = "'spamReports' can't be null";
}
if ($this->container['blocked'] === null) {
$invalidProperties[] = "'blocked' can't be null";
}
if ($this->container['invalid'] === null) {
$invalidProperties[] = "'invalid' can't be null";
}
if ($this->container['unsubscribed'] === null) {
$invalidProperties[] = "'unsubscribed' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['range'] === null) {
return false;
}
if ($this->container['requests'] === null) {
return false;
}
if ($this->container['delivered'] === null) {
return false;
}
if ($this->container['hardBounces'] === null) {
return false;
}
if ($this->container['softBounces'] === null) {
return false;
}
if ($this->container['clicks'] === null) {
return false;
}
if ($this->container['uniqueClicks'] === null) {
return false;
}
if ($this->container['opens'] === null) {
return false;
}
if ($this->container['uniqueOpens'] === null) {
return false;
}
if ($this->container['spamReports'] === null) {
return false;
}
if ($this->container['blocked'] === null) {
return false;
}
if ($this->container['invalid'] === null) {
return false;
}
if ($this->container['unsubscribed'] === null) {
return false;
}
return true;
}
/**
* Gets range
*
* @return string
*/
public function getRange()
{
return $this->container['range'];
}
/**
* Sets range
*
* @param string $range Time frame of the report
*
* @return $this
*/
public function setRange($range)
{
$this->container['range'] = $range;
return $this;
}
/**
* Gets requests
*
* @return int
*/
public function getRequests()
{
return $this->container['requests'];
}
/**
* Sets requests
*
* @param int $requests Number of requests for the timeframe
*
* @return $this
*/
public function setRequests($requests)
{
$this->container['requests'] = $requests;
return $this;
}
/**
* Gets delivered
*
* @return int
*/
public function getDelivered()
{
return $this->container['delivered'];
}
/**
* Sets delivered
*
* @param int $delivered Number of delivered emails for the timeframe
*
* @return $this
*/
public function setDelivered($delivered)
{
$this->container['delivered'] = $delivered;
return $this;
}
/**
* Gets hardBounces
*
* @return int
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param int $hardBounces Number of hardbounces for the timeframe
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets softBounces
*
* @return int
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param int $softBounces Number of softbounces for the timeframe
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets clicks
*
* @return int
*/
public function getClicks()
{
return $this->container['clicks'];
}
/**
* Sets clicks
*
* @param int $clicks Number of clicks for the timeframe
*
* @return $this
*/
public function setClicks($clicks)
{
$this->container['clicks'] = $clicks;
return $this;
}
/**
* Gets uniqueClicks
*
* @return int
*/
public function getUniqueClicks()
{
return $this->container['uniqueClicks'];
}
/**
* Sets uniqueClicks
*
* @param int $uniqueClicks Number of unique clicks for the timeframe
*
* @return $this
*/
public function setUniqueClicks($uniqueClicks)
{
$this->container['uniqueClicks'] = $uniqueClicks;
return $this;
}
/**
* Gets opens
*
* @return int
*/
public function getOpens()
{
return $this->container['opens'];
}
/**
* Sets opens
*
* @param int $opens Number of openings for the timeframe
*
* @return $this
*/
public function setOpens($opens)
{
$this->container['opens'] = $opens;
return $this;
}
/**
* Gets uniqueOpens
*
* @return int
*/
public function getUniqueOpens()
{
return $this->container['uniqueOpens'];
}
/**
* Sets uniqueOpens
*
* @param int $uniqueOpens Number of unique openings for the timeframe
*
* @return $this
*/
public function setUniqueOpens($uniqueOpens)
{
$this->container['uniqueOpens'] = $uniqueOpens;
return $this;
}
/**
* Gets spamReports
*
* @return int
*/
public function getSpamReports()
{
return $this->container['spamReports'];
}
/**
* Sets spamReports
*
* @param int $spamReports Number of complaint (spam report) for the timeframe
*
* @return $this
*/
public function setSpamReports($spamReports)
{
$this->container['spamReports'] = $spamReports;
return $this;
}
/**
* Gets blocked
*
* @return int
*/
public function getBlocked()
{
return $this->container['blocked'];
}
/**
* Sets blocked
*
* @param int $blocked Number of blocked contact emails for the timeframe
*
* @return $this
*/
public function setBlocked($blocked)
{
$this->container['blocked'] = $blocked;
return $this;
}
/**
* Gets invalid
*
* @return int
*/
public function getInvalid()
{
return $this->container['invalid'];
}
/**
* Sets invalid
*
* @param int $invalid Number of invalid emails for the timeframe
*
* @return $this
*/
public function setInvalid($invalid)
{
$this->container['invalid'] = $invalid;
return $this;
}
/**
* Gets unsubscribed
*
* @return int
*/
public function getUnsubscribed()
{
return $this->container['unsubscribed'];
}
/**
* Sets unsubscribed
*
* @param int $unsubscribed Number of unsubscribed emails for the timeframe
*
* @return $this
*/
public function setUnsubscribed($unsubscribed)
{
$this->container['unsubscribed'] = $unsubscribed;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* GetAttributes
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAttributes Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAttributes implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAttributes';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'attributes' => '\SendinBlue\Client\Model\GetAttributesAttributes[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'attributes' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'attributes' => 'attributes'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'attributes' => 'setAttributes'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'attributes' => 'getAttributes'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['attributes'] = isset($data['attributes']) ? $data['attributes'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['attributes'] === null) {
$invalidProperties[] = "'attributes' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['attributes'] === null) {
return false;
}
return true;
}
/**
* Gets attributes
*
* @return \SendinBlue\Client\Model\GetAttributesAttributes[]
*/
public function getAttributes()
{
return $this->container['attributes'];
}
/**
* Sets attributes
*
* @param \SendinBlue\Client\Model\GetAttributesAttributes[] $attributes Listing of available contact attributes in your account
*
* @return $this
*/
public function setAttributes($attributes)
{
$this->container['attributes'] = $attributes;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,518 @@
<?php
/**
* GetAttributesAttributes
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAttributesAttributes Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAttributesAttributes implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAttributes_attributes';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'category' => 'string',
'type' => 'string',
'enumeration' => '\SendinBlue\Client\Model\GetAttributesEnumeration[]',
'calculatedValue' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'category' => null,
'type' => null,
'enumeration' => null,
'calculatedValue' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'category' => 'category',
'type' => 'type',
'enumeration' => 'enumeration',
'calculatedValue' => 'calculatedValue'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'category' => 'setCategory',
'type' => 'setType',
'enumeration' => 'setEnumeration',
'calculatedValue' => 'setCalculatedValue'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'category' => 'getCategory',
'type' => 'getType',
'enumeration' => 'getEnumeration',
'calculatedValue' => 'getCalculatedValue'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const CATEGORY_NORMAL = 'normal';
const CATEGORY_TRANSACTIONAL = 'transactional';
const CATEGORY_CATEGORY = 'category';
const CATEGORY_CALCULATED = 'calculated';
const CATEGORY__GLOBAL = 'global';
const TYPE_TEXT = 'text';
const TYPE_DATE = 'date';
const TYPE_FLOAT = 'float';
const TYPE_ID = 'id';
const TYPE_BOOLEAN = 'boolean';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getCategoryAllowableValues()
{
return [
self::CATEGORY_NORMAL,
self::CATEGORY_TRANSACTIONAL,
self::CATEGORY_CATEGORY,
self::CATEGORY_CALCULATED,
self::CATEGORY__GLOBAL,
];
}
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getTypeAllowableValues()
{
return [
self::TYPE_TEXT,
self::TYPE_DATE,
self::TYPE_FLOAT,
self::TYPE_ID,
self::TYPE_BOOLEAN,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['category'] = isset($data['category']) ? $data['category'] : null;
$this->container['type'] = isset($data['type']) ? $data['type'] : null;
$this->container['enumeration'] = isset($data['enumeration']) ? $data['enumeration'] : null;
$this->container['calculatedValue'] = isset($data['calculatedValue']) ? $data['calculatedValue'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['category'] === null) {
$invalidProperties[] = "'category' can't be null";
}
$allowedValues = $this->getCategoryAllowableValues();
if (!in_array($this->container['category'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'category', must be one of '%s'",
implode("', '", $allowedValues)
);
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['category'] === null) {
return false;
}
$allowedValues = $this->getCategoryAllowableValues();
if (!in_array($this->container['category'], $allowedValues)) {
return false;
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the attribute
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets category
*
* @return string
*/
public function getCategory()
{
return $this->container['category'];
}
/**
* Sets category
*
* @param string $category Category of the attribute
*
* @return $this
*/
public function setCategory($category)
{
$allowedValues = $this->getCategoryAllowableValues();
if (!in_array($category, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'category', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['category'] = $category;
return $this;
}
/**
* Gets type
*
* @return string
*/
public function getType()
{
return $this->container['type'];
}
/**
* Sets type
*
* @param string $type Type of the attribute
*
* @return $this
*/
public function setType($type)
{
$allowedValues = $this->getTypeAllowableValues();
if (!is_null($type) && !in_array($type, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['type'] = $type;
return $this;
}
/**
* Gets enumeration
*
* @return \SendinBlue\Client\Model\GetAttributesEnumeration[]
*/
public function getEnumeration()
{
return $this->container['enumeration'];
}
/**
* Sets enumeration
*
* @param \SendinBlue\Client\Model\GetAttributesEnumeration[] $enumeration Parameter only available for \"category\" type attributes.
*
* @return $this
*/
public function setEnumeration($enumeration)
{
$this->container['enumeration'] = $enumeration;
return $this;
}
/**
* Gets calculatedValue
*
* @return string
*/
public function getCalculatedValue()
{
return $this->container['calculatedValue'];
}
/**
* Sets calculatedValue
*
* @param string $calculatedValue Calculated value formula
*
* @return $this
*/
public function setCalculatedValue($calculatedValue)
{
$this->container['calculatedValue'] = $calculatedValue;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetAttributesEnumeration
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetAttributesEnumeration Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetAttributesEnumeration implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getAttributes_enumeration';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'value' => 'int',
'label' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'value' => 'int64',
'label' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'value' => 'value',
'label' => 'label'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'value' => 'setValue',
'label' => 'setLabel'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'value' => 'getValue',
'label' => 'getLabel'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['value'] = isset($data['value']) ? $data['value'] : null;
$this->container['label'] = isset($data['label']) ? $data['label'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['value'] === null) {
$invalidProperties[] = "'value' can't be null";
}
if ($this->container['label'] === null) {
$invalidProperties[] = "'label' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['value'] === null) {
return false;
}
if ($this->container['label'] === null) {
return false;
}
return true;
}
/**
* Gets value
*
* @return int
*/
public function getValue()
{
return $this->container['value'];
}
/**
* Sets value
*
* @param int $value ID of Value of the \"category\" type attribute
*
* @return $this
*/
public function setValue($value)
{
$this->container['value'] = $value;
return $this;
}
/**
* Gets label
*
* @return string
*/
public function getLabel()
{
return $this->container['label'];
}
/**
* Sets label
*
* @param string $label Label of the \"category\" type attribute
*
* @return $this
*/
public function setLabel($label)
{
$this->container['label'] = $label;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,766 @@
<?php
/**
* GetCampaignOverview
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetCampaignOverview Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetCampaignOverview implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getCampaignOverview';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'subject' => 'string',
'type' => 'string',
'status' => 'string',
'scheduledAt' => '\DateTime',
'abTesting' => 'bool',
'subjectA' => 'string',
'subjectB' => 'string',
'splitRule' => 'int',
'winnerCriteria' => 'string',
'winnerDelay' => 'int',
'sendAtBestTime' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'subject' => null,
'type' => null,
'status' => null,
'scheduledAt' => 'date-time',
'abTesting' => null,
'subjectA' => null,
'subjectB' => null,
'splitRule' => null,
'winnerCriteria' => null,
'winnerDelay' => null,
'sendAtBestTime' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'subject' => 'subject',
'type' => 'type',
'status' => 'status',
'scheduledAt' => 'scheduledAt',
'abTesting' => 'abTesting',
'subjectA' => 'subjectA',
'subjectB' => 'subjectB',
'splitRule' => 'splitRule',
'winnerCriteria' => 'winnerCriteria',
'winnerDelay' => 'winnerDelay',
'sendAtBestTime' => 'sendAtBestTime'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'subject' => 'setSubject',
'type' => 'setType',
'status' => 'setStatus',
'scheduledAt' => 'setScheduledAt',
'abTesting' => 'setAbTesting',
'subjectA' => 'setSubjectA',
'subjectB' => 'setSubjectB',
'splitRule' => 'setSplitRule',
'winnerCriteria' => 'setWinnerCriteria',
'winnerDelay' => 'setWinnerDelay',
'sendAtBestTime' => 'setSendAtBestTime'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'subject' => 'getSubject',
'type' => 'getType',
'status' => 'getStatus',
'scheduledAt' => 'getScheduledAt',
'abTesting' => 'getAbTesting',
'subjectA' => 'getSubjectA',
'subjectB' => 'getSubjectB',
'splitRule' => 'getSplitRule',
'winnerCriteria' => 'getWinnerCriteria',
'winnerDelay' => 'getWinnerDelay',
'sendAtBestTime' => 'getSendAtBestTime'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const TYPE_CLASSIC = 'classic';
const TYPE_TRIGGER = 'trigger';
const STATUS_DRAFT = 'draft';
const STATUS_SENT = 'sent';
const STATUS_ARCHIVE = 'archive';
const STATUS_QUEUED = 'queued';
const STATUS_SUSPENDED = 'suspended';
const STATUS_IN_PROCESS = 'in_process';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getTypeAllowableValues()
{
return [
self::TYPE_CLASSIC,
self::TYPE_TRIGGER,
];
}
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getStatusAllowableValues()
{
return [
self::STATUS_DRAFT,
self::STATUS_SENT,
self::STATUS_ARCHIVE,
self::STATUS_QUEUED,
self::STATUS_SUSPENDED,
self::STATUS_IN_PROCESS,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['subject'] = isset($data['subject']) ? $data['subject'] : null;
$this->container['type'] = isset($data['type']) ? $data['type'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
$this->container['scheduledAt'] = isset($data['scheduledAt']) ? $data['scheduledAt'] : null;
$this->container['abTesting'] = isset($data['abTesting']) ? $data['abTesting'] : null;
$this->container['subjectA'] = isset($data['subjectA']) ? $data['subjectA'] : null;
$this->container['subjectB'] = isset($data['subjectB']) ? $data['subjectB'] : null;
$this->container['splitRule'] = isset($data['splitRule']) ? $data['splitRule'] : null;
$this->container['winnerCriteria'] = isset($data['winnerCriteria']) ? $data['winnerCriteria'] : null;
$this->container['winnerDelay'] = isset($data['winnerDelay']) ? $data['winnerDelay'] : null;
$this->container['sendAtBestTime'] = isset($data['sendAtBestTime']) ? $data['sendAtBestTime'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['type'] === null) {
$invalidProperties[] = "'type' can't be null";
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['type'] === null) {
return false;
}
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($this->container['type'], $allowedValues)) {
return false;
}
if ($this->container['status'] === null) {
return false;
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the campaign
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the campaign
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets subject
*
* @return string
*/
public function getSubject()
{
return $this->container['subject'];
}
/**
* Sets subject
*
* @param string $subject Subject of the campaign. Only available if `abTesting` flag of the campaign is `false`
*
* @return $this
*/
public function setSubject($subject)
{
$this->container['subject'] = $subject;
return $this;
}
/**
* Gets type
*
* @return string
*/
public function getType()
{
return $this->container['type'];
}
/**
* Sets type
*
* @param string $type Type of campaign
*
* @return $this
*/
public function setType($type)
{
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($type, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'type', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['type'] = $type;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status Status of the campaign
*
* @return $this
*/
public function setStatus($status)
{
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($status, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['status'] = $status;
return $this;
}
/**
* Gets scheduledAt
*
* @return \DateTime
*/
public function getScheduledAt()
{
return $this->container['scheduledAt'];
}
/**
* Sets scheduledAt
*
* @param \DateTime $scheduledAt UTC date-time on which campaign is scheduled (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setScheduledAt($scheduledAt)
{
$this->container['scheduledAt'] = $scheduledAt;
return $this;
}
/**
* Gets abTesting
*
* @return bool
*/
public function getAbTesting()
{
return $this->container['abTesting'];
}
/**
* Sets abTesting
*
* @param bool $abTesting Status of A/B Test for the campaign. abTesting = false means it is disabled, & abTesting = true means it is enabled.
*
* @return $this
*/
public function setAbTesting($abTesting)
{
$this->container['abTesting'] = $abTesting;
return $this;
}
/**
* Gets subjectA
*
* @return string
*/
public function getSubjectA()
{
return $this->container['subjectA'];
}
/**
* Sets subjectA
*
* @param string $subjectA Subject A of the ab-test campaign. Only available if `abTesting` flag of the campaign is `true`
*
* @return $this
*/
public function setSubjectA($subjectA)
{
$this->container['subjectA'] = $subjectA;
return $this;
}
/**
* Gets subjectB
*
* @return string
*/
public function getSubjectB()
{
return $this->container['subjectB'];
}
/**
* Sets subjectB
*
* @param string $subjectB Subject B of the ab-test campaign. Only available if `abTesting` flag of the campaign is `true`
*
* @return $this
*/
public function setSubjectB($subjectB)
{
$this->container['subjectB'] = $subjectB;
return $this;
}
/**
* Gets splitRule
*
* @return int
*/
public function getSplitRule()
{
return $this->container['splitRule'];
}
/**
* Sets splitRule
*
* @param int $splitRule The size of your ab-test groups. Only available if `abTesting` flag of the campaign is `true`
*
* @return $this
*/
public function setSplitRule($splitRule)
{
$this->container['splitRule'] = $splitRule;
return $this;
}
/**
* Gets winnerCriteria
*
* @return string
*/
public function getWinnerCriteria()
{
return $this->container['winnerCriteria'];
}
/**
* Sets winnerCriteria
*
* @param string $winnerCriteria Criteria for the winning version. Only available if `abTesting` flag of the campaign is `true`
*
* @return $this
*/
public function setWinnerCriteria($winnerCriteria)
{
$this->container['winnerCriteria'] = $winnerCriteria;
return $this;
}
/**
* Gets winnerDelay
*
* @return int
*/
public function getWinnerDelay()
{
return $this->container['winnerDelay'];
}
/**
* Sets winnerDelay
*
* @param int $winnerDelay The duration of the test in hours at the end of which the winning version will be sent. Only available if `abTesting` flag of the campaign is `true`
*
* @return $this
*/
public function setWinnerDelay($winnerDelay)
{
$this->container['winnerDelay'] = $winnerDelay;
return $this;
}
/**
* Gets sendAtBestTime
*
* @return bool
*/
public function getSendAtBestTime()
{
return $this->container['sendAtBestTime'];
}
/**
* Sets sendAtBestTime
*
* @param bool $sendAtBestTime It is true if you have chosen to send your campaign at best time, otherwise it is false
*
* @return $this
*/
public function setSendAtBestTime($sendAtBestTime)
{
$this->container['sendAtBestTime'] = $sendAtBestTime;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetCampaignRecipients
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetCampaignRecipients Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetCampaignRecipients implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getCampaignRecipients';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'lists' => 'int[]',
'exclusionLists' => 'int[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'lists' => 'int64',
'exclusionLists' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'lists' => 'lists',
'exclusionLists' => 'exclusionLists'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'lists' => 'setLists',
'exclusionLists' => 'setExclusionLists'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'lists' => 'getLists',
'exclusionLists' => 'getExclusionLists'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['lists'] = isset($data['lists']) ? $data['lists'] : null;
$this->container['exclusionLists'] = isset($data['exclusionLists']) ? $data['exclusionLists'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['lists'] === null) {
$invalidProperties[] = "'lists' can't be null";
}
if ($this->container['exclusionLists'] === null) {
$invalidProperties[] = "'exclusionLists' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['lists'] === null) {
return false;
}
if ($this->container['exclusionLists'] === null) {
return false;
}
return true;
}
/**
* Gets lists
*
* @return int[]
*/
public function getLists()
{
return $this->container['lists'];
}
/**
* Sets lists
*
* @param int[] $lists lists
*
* @return $this
*/
public function setLists($lists)
{
$this->container['lists'] = $lists;
return $this;
}
/**
* Gets exclusionLists
*
* @return int[]
*/
public function getExclusionLists()
{
return $this->container['exclusionLists'];
}
/**
* Sets exclusionLists
*
* @param int[] $exclusionLists exclusionLists
*
* @return $this
*/
public function setExclusionLists($exclusionLists)
{
$this->container['exclusionLists'] = $exclusionLists;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,692 @@
<?php
/**
* GetCampaignStats
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetCampaignStats Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetCampaignStats implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getCampaignStats';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'listId' => 'int',
'uniqueClicks' => 'int',
'clickers' => 'int',
'complaints' => 'int',
'delivered' => 'int',
'sent' => 'int',
'softBounces' => 'int',
'hardBounces' => 'int',
'uniqueViews' => 'int',
'unsubscriptions' => 'int',
'viewed' => 'int',
'deferred' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'listId' => 'int64',
'uniqueClicks' => 'int64',
'clickers' => 'int64',
'complaints' => 'int64',
'delivered' => 'int64',
'sent' => 'int64',
'softBounces' => 'int64',
'hardBounces' => 'int64',
'uniqueViews' => 'int64',
'unsubscriptions' => 'int64',
'viewed' => 'int64',
'deferred' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'listId' => 'listId',
'uniqueClicks' => 'uniqueClicks',
'clickers' => 'clickers',
'complaints' => 'complaints',
'delivered' => 'delivered',
'sent' => 'sent',
'softBounces' => 'softBounces',
'hardBounces' => 'hardBounces',
'uniqueViews' => 'uniqueViews',
'unsubscriptions' => 'unsubscriptions',
'viewed' => 'viewed',
'deferred' => 'deferred'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'listId' => 'setListId',
'uniqueClicks' => 'setUniqueClicks',
'clickers' => 'setClickers',
'complaints' => 'setComplaints',
'delivered' => 'setDelivered',
'sent' => 'setSent',
'softBounces' => 'setSoftBounces',
'hardBounces' => 'setHardBounces',
'uniqueViews' => 'setUniqueViews',
'unsubscriptions' => 'setUnsubscriptions',
'viewed' => 'setViewed',
'deferred' => 'setDeferred'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'listId' => 'getListId',
'uniqueClicks' => 'getUniqueClicks',
'clickers' => 'getClickers',
'complaints' => 'getComplaints',
'delivered' => 'getDelivered',
'sent' => 'getSent',
'softBounces' => 'getSoftBounces',
'hardBounces' => 'getHardBounces',
'uniqueViews' => 'getUniqueViews',
'unsubscriptions' => 'getUnsubscriptions',
'viewed' => 'getViewed',
'deferred' => 'getDeferred'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['listId'] = isset($data['listId']) ? $data['listId'] : null;
$this->container['uniqueClicks'] = isset($data['uniqueClicks']) ? $data['uniqueClicks'] : null;
$this->container['clickers'] = isset($data['clickers']) ? $data['clickers'] : null;
$this->container['complaints'] = isset($data['complaints']) ? $data['complaints'] : null;
$this->container['delivered'] = isset($data['delivered']) ? $data['delivered'] : null;
$this->container['sent'] = isset($data['sent']) ? $data['sent'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['uniqueViews'] = isset($data['uniqueViews']) ? $data['uniqueViews'] : null;
$this->container['unsubscriptions'] = isset($data['unsubscriptions']) ? $data['unsubscriptions'] : null;
$this->container['viewed'] = isset($data['viewed']) ? $data['viewed'] : null;
$this->container['deferred'] = isset($data['deferred']) ? $data['deferred'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['uniqueClicks'] === null) {
$invalidProperties[] = "'uniqueClicks' can't be null";
}
if ($this->container['clickers'] === null) {
$invalidProperties[] = "'clickers' can't be null";
}
if ($this->container['complaints'] === null) {
$invalidProperties[] = "'complaints' can't be null";
}
if ($this->container['delivered'] === null) {
$invalidProperties[] = "'delivered' can't be null";
}
if ($this->container['sent'] === null) {
$invalidProperties[] = "'sent' can't be null";
}
if ($this->container['softBounces'] === null) {
$invalidProperties[] = "'softBounces' can't be null";
}
if ($this->container['hardBounces'] === null) {
$invalidProperties[] = "'hardBounces' can't be null";
}
if ($this->container['uniqueViews'] === null) {
$invalidProperties[] = "'uniqueViews' can't be null";
}
if ($this->container['unsubscriptions'] === null) {
$invalidProperties[] = "'unsubscriptions' can't be null";
}
if ($this->container['viewed'] === null) {
$invalidProperties[] = "'viewed' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['uniqueClicks'] === null) {
return false;
}
if ($this->container['clickers'] === null) {
return false;
}
if ($this->container['complaints'] === null) {
return false;
}
if ($this->container['delivered'] === null) {
return false;
}
if ($this->container['sent'] === null) {
return false;
}
if ($this->container['softBounces'] === null) {
return false;
}
if ($this->container['hardBounces'] === null) {
return false;
}
if ($this->container['uniqueViews'] === null) {
return false;
}
if ($this->container['unsubscriptions'] === null) {
return false;
}
if ($this->container['viewed'] === null) {
return false;
}
return true;
}
/**
* Gets listId
*
* @return int
*/
public function getListId()
{
return $this->container['listId'];
}
/**
* Sets listId
*
* @param int $listId List Id of email campaign (only in case of get email campaign(s)(not for global stats))
*
* @return $this
*/
public function setListId($listId)
{
$this->container['listId'] = $listId;
return $this;
}
/**
* Gets uniqueClicks
*
* @return int
*/
public function getUniqueClicks()
{
return $this->container['uniqueClicks'];
}
/**
* Sets uniqueClicks
*
* @param int $uniqueClicks Number of unique clicks for the campaign
*
* @return $this
*/
public function setUniqueClicks($uniqueClicks)
{
$this->container['uniqueClicks'] = $uniqueClicks;
return $this;
}
/**
* Gets clickers
*
* @return int
*/
public function getClickers()
{
return $this->container['clickers'];
}
/**
* Sets clickers
*
* @param int $clickers Number of total clicks for the campaign
*
* @return $this
*/
public function setClickers($clickers)
{
$this->container['clickers'] = $clickers;
return $this;
}
/**
* Gets complaints
*
* @return int
*/
public function getComplaints()
{
return $this->container['complaints'];
}
/**
* Sets complaints
*
* @param int $complaints Number of complaints (Spam reports) for the campaign
*
* @return $this
*/
public function setComplaints($complaints)
{
$this->container['complaints'] = $complaints;
return $this;
}
/**
* Gets delivered
*
* @return int
*/
public function getDelivered()
{
return $this->container['delivered'];
}
/**
* Sets delivered
*
* @param int $delivered Number of delivered emails for the campaign
*
* @return $this
*/
public function setDelivered($delivered)
{
$this->container['delivered'] = $delivered;
return $this;
}
/**
* Gets sent
*
* @return int
*/
public function getSent()
{
return $this->container['sent'];
}
/**
* Sets sent
*
* @param int $sent Number of sent emails for the campaign
*
* @return $this
*/
public function setSent($sent)
{
$this->container['sent'] = $sent;
return $this;
}
/**
* Gets softBounces
*
* @return int
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param int $softBounces Number of softbounce for the campaign
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets hardBounces
*
* @return int
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param int $hardBounces Number of harbounce for the campaign
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets uniqueViews
*
* @return int
*/
public function getUniqueViews()
{
return $this->container['uniqueViews'];
}
/**
* Sets uniqueViews
*
* @param int $uniqueViews Number of unique openings for the campaign
*
* @return $this
*/
public function setUniqueViews($uniqueViews)
{
$this->container['uniqueViews'] = $uniqueViews;
return $this;
}
/**
* Gets unsubscriptions
*
* @return int
*/
public function getUnsubscriptions()
{
return $this->container['unsubscriptions'];
}
/**
* Sets unsubscriptions
*
* @param int $unsubscriptions Number of unsubscription for the campaign
*
* @return $this
*/
public function setUnsubscriptions($unsubscriptions)
{
$this->container['unsubscriptions'] = $unsubscriptions;
return $this;
}
/**
* Gets viewed
*
* @return int
*/
public function getViewed()
{
return $this->container['viewed'];
}
/**
* Sets viewed
*
* @param int $viewed Number of openings for the campaign
*
* @return $this
*/
public function setViewed($viewed)
{
$this->container['viewed'] = $viewed;
return $this;
}
/**
* Gets deferred
*
* @return int
*/
public function getDeferred()
{
return $this->container['deferred'];
}
/**
* Sets deferred
*
* @param int $deferred Number of deferred emails for the campaign
*
* @return $this
*/
public function setDeferred($deferred)
{
$this->container['deferred'] = $deferred;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetChildDomain
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildDomain Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildDomain implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildDomain';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'domain' => 'string',
'active' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'domain' => null,
'active' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'domain' => 'domain',
'active' => 'active'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'domain' => 'setDomain',
'active' => 'setActive'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'domain' => 'getDomain',
'active' => 'getActive'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
$this->container['active'] = isset($data['active']) ? $data['active'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['domain'] === null) {
$invalidProperties[] = "'domain' can't be null";
}
if ($this->container['active'] === null) {
$invalidProperties[] = "'active' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['domain'] === null) {
return false;
}
if ($this->container['active'] === null) {
return false;
}
return true;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Sender domain
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Gets active
*
* @return bool
*/
public function getActive()
{
return $this->container['active'];
}
/**
* Sets active
*
* @param bool $active indicates whether a domain is verified or not
*
* @return $this
*/
public function setActive($active)
{
$this->container['active'] = $active;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,280 @@
<?php
/**
* GetChildDomains
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildDomains Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildDomains implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildDomains';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = parent::listInvalidProperties();
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if (!parent::valid()) {
return false;
}
return true;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,572 @@
<?php
/**
* GetChildInfo
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfo Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfo implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'firstName' => 'string',
'lastName' => 'string',
'companyName' => 'string',
'credits' => '\SendinBlue\Client\Model\GetChildInfoCredits',
'statistics' => '\SendinBlue\Client\Model\GetChildInfoStatistics',
'password' => 'string',
'ips' => 'string[]',
'apiKeys' => '\SendinBlue\Client\Model\GetChildInfoApiKeys'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'firstName' => null,
'lastName' => null,
'companyName' => null,
'credits' => null,
'statistics' => null,
'password' => 'password',
'ips' => null,
'apiKeys' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'firstName' => 'firstName',
'lastName' => 'lastName',
'companyName' => 'companyName',
'credits' => 'credits',
'statistics' => 'statistics',
'password' => 'password',
'ips' => 'ips',
'apiKeys' => 'apiKeys'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'firstName' => 'setFirstName',
'lastName' => 'setLastName',
'companyName' => 'setCompanyName',
'credits' => 'setCredits',
'statistics' => 'setStatistics',
'password' => 'setPassword',
'ips' => 'setIps',
'apiKeys' => 'setApiKeys'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'firstName' => 'getFirstName',
'lastName' => 'getLastName',
'companyName' => 'getCompanyName',
'credits' => 'getCredits',
'statistics' => 'getStatistics',
'password' => 'getPassword',
'ips' => 'getIps',
'apiKeys' => 'getApiKeys'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['firstName'] = isset($data['firstName']) ? $data['firstName'] : null;
$this->container['lastName'] = isset($data['lastName']) ? $data['lastName'] : null;
$this->container['companyName'] = isset($data['companyName']) ? $data['companyName'] : null;
$this->container['credits'] = isset($data['credits']) ? $data['credits'] : null;
$this->container['statistics'] = isset($data['statistics']) ? $data['statistics'] : null;
$this->container['password'] = isset($data['password']) ? $data['password'] : null;
$this->container['ips'] = isset($data['ips']) ? $data['ips'] : null;
$this->container['apiKeys'] = isset($data['apiKeys']) ? $data['apiKeys'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['firstName'] === null) {
$invalidProperties[] = "'firstName' can't be null";
}
if ($this->container['lastName'] === null) {
$invalidProperties[] = "'lastName' can't be null";
}
if ($this->container['companyName'] === null) {
$invalidProperties[] = "'companyName' can't be null";
}
if ($this->container['password'] === null) {
$invalidProperties[] = "'password' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['firstName'] === null) {
return false;
}
if ($this->container['lastName'] === null) {
return false;
}
if ($this->container['companyName'] === null) {
return false;
}
if ($this->container['password'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Login Email
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets firstName
*
* @return string
*/
public function getFirstName()
{
return $this->container['firstName'];
}
/**
* Sets firstName
*
* @param string $firstName First Name
*
* @return $this
*/
public function setFirstName($firstName)
{
$this->container['firstName'] = $firstName;
return $this;
}
/**
* Gets lastName
*
* @return string
*/
public function getLastName()
{
return $this->container['lastName'];
}
/**
* Sets lastName
*
* @param string $lastName Last Name
*
* @return $this
*/
public function setLastName($lastName)
{
$this->container['lastName'] = $lastName;
return $this;
}
/**
* Gets companyName
*
* @return string
*/
public function getCompanyName()
{
return $this->container['companyName'];
}
/**
* Sets companyName
*
* @param string $companyName Name of the company
*
* @return $this
*/
public function setCompanyName($companyName)
{
$this->container['companyName'] = $companyName;
return $this;
}
/**
* Gets credits
*
* @return \SendinBlue\Client\Model\GetChildInfoCredits
*/
public function getCredits()
{
return $this->container['credits'];
}
/**
* Sets credits
*
* @param \SendinBlue\Client\Model\GetChildInfoCredits $credits credits
*
* @return $this
*/
public function setCredits($credits)
{
$this->container['credits'] = $credits;
return $this;
}
/**
* Gets statistics
*
* @return \SendinBlue\Client\Model\GetChildInfoStatistics
*/
public function getStatistics()
{
return $this->container['statistics'];
}
/**
* Sets statistics
*
* @param \SendinBlue\Client\Model\GetChildInfoStatistics $statistics statistics
*
* @return $this
*/
public function setStatistics($statistics)
{
$this->container['statistics'] = $statistics;
return $this;
}
/**
* Gets password
*
* @return string
*/
public function getPassword()
{
return $this->container['password'];
}
/**
* Sets password
*
* @param string $password The encrypted password of child account
*
* @return $this
*/
public function setPassword($password)
{
$this->container['password'] = $password;
return $this;
}
/**
* Gets ips
*
* @return string[]
*/
public function getIps()
{
return $this->container['ips'];
}
/**
* Sets ips
*
* @param string[] $ips IP(s) associated to a child account user
*
* @return $this
*/
public function setIps($ips)
{
$this->container['ips'] = $ips;
return $this;
}
/**
* Gets apiKeys
*
* @return \SendinBlue\Client\Model\GetChildInfoApiKeys
*/
public function getApiKeys()
{
return $this->container['apiKeys'];
}
/**
* Sets apiKeys
*
* @param \SendinBlue\Client\Model\GetChildInfoApiKeys $apiKeys apiKeys
*
* @return $this
*/
public function setApiKeys($apiKeys)
{
$this->container['apiKeys'] = $apiKeys;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,339 @@
<?php
/**
* GetChildInfoApiKeys
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfoApiKeys Class Doc Comment
*
* @category Class
* @description API Keys associated to child account
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfoApiKeys implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo_apiKeys';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'v2' => '\SendinBlue\Client\Model\GetChildInfoApiKeysV2[]',
'v3' => '\SendinBlue\Client\Model\GetChildInfoApiKeysV3[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'v2' => null,
'v3' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'v2' => 'v2',
'v3' => 'v3'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'v2' => 'setV2',
'v3' => 'setV3'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'v2' => 'getV2',
'v3' => 'getV3'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['v2'] = isset($data['v2']) ? $data['v2'] : null;
$this->container['v3'] = isset($data['v3']) ? $data['v3'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['v2'] === null) {
$invalidProperties[] = "'v2' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['v2'] === null) {
return false;
}
return true;
}
/**
* Gets v2
*
* @return \SendinBlue\Client\Model\GetChildInfoApiKeysV2[]
*/
public function getV2()
{
return $this->container['v2'];
}
/**
* Sets v2
*
* @param \SendinBlue\Client\Model\GetChildInfoApiKeysV2[] $v2 v2
*
* @return $this
*/
public function setV2($v2)
{
$this->container['v2'] = $v2;
return $this;
}
/**
* Gets v3
*
* @return \SendinBlue\Client\Model\GetChildInfoApiKeysV3[]
*/
public function getV3()
{
return $this->container['v3'];
}
/**
* Sets v3
*
* @param \SendinBlue\Client\Model\GetChildInfoApiKeysV3[] $v3 v3
*
* @return $this
*/
public function setV3($v3)
{
$this->container['v3'] = $v3;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetChildInfoApiKeysV2
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfoApiKeysV2 Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfoApiKeysV2 implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo_apiKeys_v2';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'key' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'key' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'key' => 'key'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'key' => 'setKey'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'key' => 'getKey'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['key'] = isset($data['key']) ? $data['key'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['key'] === null) {
$invalidProperties[] = "'key' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['key'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the key for version 2
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets key
*
* @return string
*/
public function getKey()
{
return $this->container['key'];
}
/**
* Sets key
*
* @param string $key API Key for version 2
*
* @return $this
*/
public function setKey($key)
{
$this->container['key'] = $key;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetChildInfoApiKeysV3
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfoApiKeysV3 Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfoApiKeysV3 implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo_apiKeys_v3';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'key' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'key' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'key' => 'key'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'key' => 'setKey'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'key' => 'getKey'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['key'] = isset($data['key']) ? $data['key'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['key'] === null) {
$invalidProperties[] = "'key' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['name'] === null) {
return false;
}
if ($this->container['key'] === null) {
return false;
}
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the key for version 3
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets key
*
* @return string
*/
public function getKey()
{
return $this->container['key'];
}
/**
* Sets key
*
* @param string $key API Key for version 3
*
* @return $this
*/
public function setKey($key)
{
$this->container['key'] = $key;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,333 @@
<?php
/**
* GetChildInfoCredits
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfoCredits Class Doc Comment
*
* @category Class
* @description Credits available for your child
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfoCredits implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo_credits';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'emailCredits' => 'int',
'smsCredits' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'emailCredits' => 'int64',
'smsCredits' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'emailCredits' => 'emailCredits',
'smsCredits' => 'smsCredits'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'emailCredits' => 'setEmailCredits',
'smsCredits' => 'setSmsCredits'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'emailCredits' => 'getEmailCredits',
'smsCredits' => 'getSmsCredits'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['emailCredits'] = isset($data['emailCredits']) ? $data['emailCredits'] : null;
$this->container['smsCredits'] = isset($data['smsCredits']) ? $data['smsCredits'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets emailCredits
*
* @return int
*/
public function getEmailCredits()
{
return $this->container['emailCredits'];
}
/**
* Sets emailCredits
*
* @param int $emailCredits Email credits available for your child
*
* @return $this
*/
public function setEmailCredits($emailCredits)
{
$this->container['emailCredits'] = $emailCredits;
return $this;
}
/**
* Gets smsCredits
*
* @return int
*/
public function getSmsCredits()
{
return $this->container['smsCredits'];
}
/**
* Sets smsCredits
*
* @param int $smsCredits SMS credits available for your child
*
* @return $this
*/
public function setSmsCredits($smsCredits)
{
$this->container['smsCredits'] = $smsCredits;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,363 @@
<?php
/**
* GetChildInfoStatistics
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildInfoStatistics Class Doc Comment
*
* @category Class
* @description Statistics about your child account activity
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildInfoStatistics implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildInfo_statistics';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'previousMonthTotalSent' => 'int',
'currentMonthTotalSent' => 'int',
'totalSent' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'previousMonthTotalSent' => 'int64',
'currentMonthTotalSent' => 'int64',
'totalSent' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'previousMonthTotalSent' => 'previousMonthTotalSent',
'currentMonthTotalSent' => 'currentMonthTotalSent',
'totalSent' => 'totalSent'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'previousMonthTotalSent' => 'setPreviousMonthTotalSent',
'currentMonthTotalSent' => 'setCurrentMonthTotalSent',
'totalSent' => 'setTotalSent'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'previousMonthTotalSent' => 'getPreviousMonthTotalSent',
'currentMonthTotalSent' => 'getCurrentMonthTotalSent',
'totalSent' => 'getTotalSent'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['previousMonthTotalSent'] = isset($data['previousMonthTotalSent']) ? $data['previousMonthTotalSent'] : null;
$this->container['currentMonthTotalSent'] = isset($data['currentMonthTotalSent']) ? $data['currentMonthTotalSent'] : null;
$this->container['totalSent'] = isset($data['totalSent']) ? $data['totalSent'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets previousMonthTotalSent
*
* @return int
*/
public function getPreviousMonthTotalSent()
{
return $this->container['previousMonthTotalSent'];
}
/**
* Sets previousMonthTotalSent
*
* @param int $previousMonthTotalSent Overall emails sent for the previous month
*
* @return $this
*/
public function setPreviousMonthTotalSent($previousMonthTotalSent)
{
$this->container['previousMonthTotalSent'] = $previousMonthTotalSent;
return $this;
}
/**
* Gets currentMonthTotalSent
*
* @return int
*/
public function getCurrentMonthTotalSent()
{
return $this->container['currentMonthTotalSent'];
}
/**
* Sets currentMonthTotalSent
*
* @param int $currentMonthTotalSent Overall emails sent for current month
*
* @return $this
*/
public function setCurrentMonthTotalSent($currentMonthTotalSent)
{
$this->container['currentMonthTotalSent'] = $currentMonthTotalSent;
return $this;
}
/**
* Gets totalSent
*
* @return int
*/
public function getTotalSent()
{
return $this->container['totalSent'];
}
/**
* Sets totalSent
*
* @param int $totalSent Overall emails sent for since the account exists
*
* @return $this
*/
public function setTotalSent($totalSent)
{
$this->container['totalSent'] = $totalSent;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* GetChildrenList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetChildrenList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetChildrenList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getChildrenList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'children' => 'object[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'children' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'children' => 'children'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'children' => 'setChildren'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'children' => 'getChildren'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['children'] = isset($data['children']) ? $data['children'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets children
*
* @return object[]
*/
public function getChildren()
{
return $this->container['children'];
}
/**
* Sets children
*
* @param object[] $children Your children's account information
*
* @return $this
*/
public function setChildren($children)
{
$this->container['children'] = $children;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetClient
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetClient Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetClient implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getClient';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'firstName' => 'string',
'lastName' => 'string',
'companyName' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'firstName' => null,
'lastName' => null,
'companyName' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'firstName' => 'firstName',
'lastName' => 'lastName',
'companyName' => 'companyName'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'firstName' => 'setFirstName',
'lastName' => 'setLastName',
'companyName' => 'setCompanyName'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'firstName' => 'getFirstName',
'lastName' => 'getLastName',
'companyName' => 'getCompanyName'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['firstName'] = isset($data['firstName']) ? $data['firstName'] : null;
$this->container['lastName'] = isset($data['lastName']) ? $data['lastName'] : null;
$this->container['companyName'] = isset($data['companyName']) ? $data['companyName'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['firstName'] === null) {
$invalidProperties[] = "'firstName' can't be null";
}
if ($this->container['lastName'] === null) {
$invalidProperties[] = "'lastName' can't be null";
}
if ($this->container['companyName'] === null) {
$invalidProperties[] = "'companyName' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['firstName'] === null) {
return false;
}
if ($this->container['lastName'] === null) {
return false;
}
if ($this->container['companyName'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Login Email
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets firstName
*
* @return string
*/
public function getFirstName()
{
return $this->container['firstName'];
}
/**
* Sets firstName
*
* @param string $firstName First Name
*
* @return $this
*/
public function setFirstName($firstName)
{
$this->container['firstName'] = $firstName;
return $this;
}
/**
* Gets lastName
*
* @return string
*/
public function getLastName()
{
return $this->container['lastName'];
}
/**
* Sets lastName
*
* @param string $lastName Last Name
*
* @return $this
*/
public function setLastName($lastName)
{
$this->container['lastName'] = $lastName;
return $this;
}
/**
* Gets companyName
*
* @return string
*/
public function getCompanyName()
{
return $this->container['companyName'];
}
/**
* Sets companyName
*
* @param string $companyName Name of the company
*
* @return $this
*/
public function setCompanyName($companyName)
{
$this->container['companyName'] = $companyName;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,513 @@
<?php
/**
* GetContactCampaignStats
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactCampaignStats Class Doc Comment
*
* @category Class
* @description Campaign Statistics for the contact
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactCampaignStats implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactCampaignStats';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'messagesSent' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'hardBounces' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'softBounces' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'complaints' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'unsubscriptions' => '\SendinBlue\Client\Model\GetContactCampaignStatsUnsubscriptions',
'opened' => '\SendinBlue\Client\Model\GetContactCampaignStatsOpened[]',
'clicked' => '\SendinBlue\Client\Model\GetContactCampaignStatsClicked[]',
'transacAttributes' => '\SendinBlue\Client\Model\GetContactCampaignStatsTransacAttributes[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'messagesSent' => null,
'hardBounces' => null,
'softBounces' => null,
'complaints' => null,
'unsubscriptions' => null,
'opened' => null,
'clicked' => null,
'transacAttributes' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'messagesSent' => 'messagesSent',
'hardBounces' => 'hardBounces',
'softBounces' => 'softBounces',
'complaints' => 'complaints',
'unsubscriptions' => 'unsubscriptions',
'opened' => 'opened',
'clicked' => 'clicked',
'transacAttributes' => 'transacAttributes'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'messagesSent' => 'setMessagesSent',
'hardBounces' => 'setHardBounces',
'softBounces' => 'setSoftBounces',
'complaints' => 'setComplaints',
'unsubscriptions' => 'setUnsubscriptions',
'opened' => 'setOpened',
'clicked' => 'setClicked',
'transacAttributes' => 'setTransacAttributes'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'messagesSent' => 'getMessagesSent',
'hardBounces' => 'getHardBounces',
'softBounces' => 'getSoftBounces',
'complaints' => 'getComplaints',
'unsubscriptions' => 'getUnsubscriptions',
'opened' => 'getOpened',
'clicked' => 'getClicked',
'transacAttributes' => 'getTransacAttributes'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['messagesSent'] = isset($data['messagesSent']) ? $data['messagesSent'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['complaints'] = isset($data['complaints']) ? $data['complaints'] : null;
$this->container['unsubscriptions'] = isset($data['unsubscriptions']) ? $data['unsubscriptions'] : null;
$this->container['opened'] = isset($data['opened']) ? $data['opened'] : null;
$this->container['clicked'] = isset($data['clicked']) ? $data['clicked'] : null;
$this->container['transacAttributes'] = isset($data['transacAttributes']) ? $data['transacAttributes'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets messagesSent
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getMessagesSent()
{
return $this->container['messagesSent'];
}
/**
* Sets messagesSent
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $messagesSent messagesSent
*
* @return $this
*/
public function setMessagesSent($messagesSent)
{
$this->container['messagesSent'] = $messagesSent;
return $this;
}
/**
* Gets hardBounces
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $hardBounces hardBounces
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets softBounces
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $softBounces softBounces
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets complaints
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getComplaints()
{
return $this->container['complaints'];
}
/**
* Sets complaints
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $complaints complaints
*
* @return $this
*/
public function setComplaints($complaints)
{
$this->container['complaints'] = $complaints;
return $this;
}
/**
* Gets unsubscriptions
*
* @return \SendinBlue\Client\Model\GetContactCampaignStatsUnsubscriptions
*/
public function getUnsubscriptions()
{
return $this->container['unsubscriptions'];
}
/**
* Sets unsubscriptions
*
* @param \SendinBlue\Client\Model\GetContactCampaignStatsUnsubscriptions $unsubscriptions unsubscriptions
*
* @return $this
*/
public function setUnsubscriptions($unsubscriptions)
{
$this->container['unsubscriptions'] = $unsubscriptions;
return $this;
}
/**
* Gets opened
*
* @return \SendinBlue\Client\Model\GetContactCampaignStatsOpened[]
*/
public function getOpened()
{
return $this->container['opened'];
}
/**
* Sets opened
*
* @param \SendinBlue\Client\Model\GetContactCampaignStatsOpened[] $opened opened
*
* @return $this
*/
public function setOpened($opened)
{
$this->container['opened'] = $opened;
return $this;
}
/**
* Gets clicked
*
* @return \SendinBlue\Client\Model\GetContactCampaignStatsClicked[]
*/
public function getClicked()
{
return $this->container['clicked'];
}
/**
* Sets clicked
*
* @param \SendinBlue\Client\Model\GetContactCampaignStatsClicked[] $clicked clicked
*
* @return $this
*/
public function setClicked($clicked)
{
$this->container['clicked'] = $clicked;
return $this;
}
/**
* Gets transacAttributes
*
* @return \SendinBlue\Client\Model\GetContactCampaignStatsTransacAttributes[]
*/
public function getTransacAttributes()
{
return $this->container['transacAttributes'];
}
/**
* Sets transacAttributes
*
* @param \SendinBlue\Client\Model\GetContactCampaignStatsTransacAttributes[] $transacAttributes transacAttributes
*
* @return $this
*/
public function setTransacAttributes($transacAttributes)
{
$this->container['transacAttributes'] = $transacAttributes;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetContactCampaignStatsClicked
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactCampaignStatsClicked Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactCampaignStatsClicked implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactCampaignStats_clicked';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'links' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'links' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'links' => 'links'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'links' => 'setLinks'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'links' => 'getLinks'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['links'] = isset($data['links']) ? $data['links'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['links'] === null) {
$invalidProperties[] = "'links' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['links'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets links
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[]
*/
public function getLinks()
{
return $this->container['links'];
}
/**
* Sets links
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[] $links links
*
* @return $this
*/
public function setLinks($links)
{
$this->container['links'] = $links;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetContactCampaignStatsOpened
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactCampaignStatsOpened Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactCampaignStatsOpened implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactCampaignStats_opened';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'count' => 'int',
'eventTime' => '\DateTime',
'ip' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'count' => 'int64',
'eventTime' => 'date-time',
'ip' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'count' => 'count',
'eventTime' => 'eventTime',
'ip' => 'ip'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'count' => 'setCount',
'eventTime' => 'setEventTime',
'ip' => 'setIp'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'count' => 'getCount',
'eventTime' => 'getEventTime',
'ip' => 'getIp'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['count'] === null) {
return false;
}
if ($this->container['eventTime'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of openings of the campaign
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has opened the campaign
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,380 @@
<?php
/**
* GetContactCampaignStatsTransacAttributes
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactCampaignStatsTransacAttributes Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactCampaignStatsTransacAttributes implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactCampaignStats_transacAttributes';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'orderDate' => '\DateTime',
'orderPrice' => 'float',
'orderId' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'orderDate' => 'date',
'orderPrice' => 'float',
'orderId' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'orderDate' => 'orderDate',
'orderPrice' => 'orderPrice',
'orderId' => 'orderId'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'orderDate' => 'setOrderDate',
'orderPrice' => 'setOrderPrice',
'orderId' => 'setOrderId'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'orderDate' => 'getOrderDate',
'orderPrice' => 'getOrderPrice',
'orderId' => 'getOrderId'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['orderDate'] = isset($data['orderDate']) ? $data['orderDate'] : null;
$this->container['orderPrice'] = isset($data['orderPrice']) ? $data['orderPrice'] : null;
$this->container['orderId'] = isset($data['orderId']) ? $data['orderId'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['orderDate'] === null) {
$invalidProperties[] = "'orderDate' can't be null";
}
if ($this->container['orderPrice'] === null) {
$invalidProperties[] = "'orderPrice' can't be null";
}
if ($this->container['orderId'] === null) {
$invalidProperties[] = "'orderId' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['orderDate'] === null) {
return false;
}
if ($this->container['orderPrice'] === null) {
return false;
}
if ($this->container['orderId'] === null) {
return false;
}
return true;
}
/**
* Gets orderDate
*
* @return \DateTime
*/
public function getOrderDate()
{
return $this->container['orderDate'];
}
/**
* Sets orderDate
*
* @param \DateTime $orderDate Date of the order
*
* @return $this
*/
public function setOrderDate($orderDate)
{
$this->container['orderDate'] = $orderDate;
return $this;
}
/**
* Gets orderPrice
*
* @return float
*/
public function getOrderPrice()
{
return $this->container['orderPrice'];
}
/**
* Sets orderPrice
*
* @param float $orderPrice Price of the order
*
* @return $this
*/
public function setOrderPrice($orderPrice)
{
$this->container['orderPrice'] = $orderPrice;
return $this;
}
/**
* Gets orderId
*
* @return int
*/
public function getOrderId()
{
return $this->container['orderId'];
}
/**
* Sets orderId
*
* @param int $orderId ID of the order
*
* @return $this
*/
public function setOrderId($orderId)
{
$this->container['orderId'] = $orderId;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetContactCampaignStatsUnsubscriptions
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactCampaignStatsUnsubscriptions Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactCampaignStatsUnsubscriptions implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactCampaignStats_unsubscriptions';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'userUnsubscription' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[]',
'adminUnsubscription' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'userUnsubscription' => null,
'adminUnsubscription' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'userUnsubscription' => 'userUnsubscription',
'adminUnsubscription' => 'adminUnsubscription'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'userUnsubscription' => 'setUserUnsubscription',
'adminUnsubscription' => 'setAdminUnsubscription'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'userUnsubscription' => 'getUserUnsubscription',
'adminUnsubscription' => 'getAdminUnsubscription'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['userUnsubscription'] = isset($data['userUnsubscription']) ? $data['userUnsubscription'] : null;
$this->container['adminUnsubscription'] = isset($data['adminUnsubscription']) ? $data['adminUnsubscription'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['userUnsubscription'] === null) {
$invalidProperties[] = "'userUnsubscription' can't be null";
}
if ($this->container['adminUnsubscription'] === null) {
$invalidProperties[] = "'adminUnsubscription' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['userUnsubscription'] === null) {
return false;
}
if ($this->container['adminUnsubscription'] === null) {
return false;
}
return true;
}
/**
* Gets userUnsubscription
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[]
*/
public function getUserUnsubscription()
{
return $this->container['userUnsubscription'];
}
/**
* Sets userUnsubscription
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[] $userUnsubscription Contact has unsubscribed via the unsubscription link in the email
*
* @return $this
*/
public function setUserUnsubscription($userUnsubscription)
{
$this->container['userUnsubscription'] = $userUnsubscription;
return $this;
}
/**
* Gets adminUnsubscription
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[]
*/
public function getAdminUnsubscription()
{
return $this->container['adminUnsubscription'];
}
/**
* Sets adminUnsubscription
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[] $adminUnsubscription Contact has been unsubscribed from the administrator
*
* @return $this
*/
public function setAdminUnsubscription($adminUnsubscription)
{
$this->container['adminUnsubscription'] = $adminUnsubscription;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,590 @@
<?php
/**
* GetContactDetails
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContactDetails Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContactDetails implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContactDetails';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'id' => 'int',
'emailBlacklisted' => 'bool',
'smsBlacklisted' => 'bool',
'createdAt' => '\DateTime',
'modifiedAt' => '\DateTime',
'listIds' => 'int[]',
'listUnsubscribed' => 'int[]',
'attributes' => 'object'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'id' => 'int64',
'emailBlacklisted' => null,
'smsBlacklisted' => null,
'createdAt' => 'date-time',
'modifiedAt' => 'date-time',
'listIds' => 'int64',
'listUnsubscribed' => 'int64',
'attributes' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'id' => 'id',
'emailBlacklisted' => 'emailBlacklisted',
'smsBlacklisted' => 'smsBlacklisted',
'createdAt' => 'createdAt',
'modifiedAt' => 'modifiedAt',
'listIds' => 'listIds',
'listUnsubscribed' => 'listUnsubscribed',
'attributes' => 'attributes'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'id' => 'setId',
'emailBlacklisted' => 'setEmailBlacklisted',
'smsBlacklisted' => 'setSmsBlacklisted',
'createdAt' => 'setCreatedAt',
'modifiedAt' => 'setModifiedAt',
'listIds' => 'setListIds',
'listUnsubscribed' => 'setListUnsubscribed',
'attributes' => 'setAttributes'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'id' => 'getId',
'emailBlacklisted' => 'getEmailBlacklisted',
'smsBlacklisted' => 'getSmsBlacklisted',
'createdAt' => 'getCreatedAt',
'modifiedAt' => 'getModifiedAt',
'listIds' => 'getListIds',
'listUnsubscribed' => 'getListUnsubscribed',
'attributes' => 'getAttributes'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['emailBlacklisted'] = isset($data['emailBlacklisted']) ? $data['emailBlacklisted'] : null;
$this->container['smsBlacklisted'] = isset($data['smsBlacklisted']) ? $data['smsBlacklisted'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['modifiedAt'] = isset($data['modifiedAt']) ? $data['modifiedAt'] : null;
$this->container['listIds'] = isset($data['listIds']) ? $data['listIds'] : null;
$this->container['listUnsubscribed'] = isset($data['listUnsubscribed']) ? $data['listUnsubscribed'] : null;
$this->container['attributes'] = isset($data['attributes']) ? $data['attributes'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['emailBlacklisted'] === null) {
$invalidProperties[] = "'emailBlacklisted' can't be null";
}
if ($this->container['smsBlacklisted'] === null) {
$invalidProperties[] = "'smsBlacklisted' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
if ($this->container['modifiedAt'] === null) {
$invalidProperties[] = "'modifiedAt' can't be null";
}
if ($this->container['listIds'] === null) {
$invalidProperties[] = "'listIds' can't be null";
}
if ($this->container['attributes'] === null) {
$invalidProperties[] = "'attributes' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['id'] === null) {
return false;
}
if ($this->container['emailBlacklisted'] === null) {
return false;
}
if ($this->container['smsBlacklisted'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
if ($this->container['modifiedAt'] === null) {
return false;
}
if ($this->container['listIds'] === null) {
return false;
}
if ($this->container['attributes'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email address of the contact for which you requested the details
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the contact for which you requested the details
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets emailBlacklisted
*
* @return bool
*/
public function getEmailBlacklisted()
{
return $this->container['emailBlacklisted'];
}
/**
* Sets emailBlacklisted
*
* @param bool $emailBlacklisted Blacklist status for email campaigns (true=blacklisted, false=not blacklisted)
*
* @return $this
*/
public function setEmailBlacklisted($emailBlacklisted)
{
$this->container['emailBlacklisted'] = $emailBlacklisted;
return $this;
}
/**
* Gets smsBlacklisted
*
* @return bool
*/
public function getSmsBlacklisted()
{
return $this->container['smsBlacklisted'];
}
/**
* Sets smsBlacklisted
*
* @param bool $smsBlacklisted Blacklist status for SMS campaigns (true=blacklisted, false=not blacklisted)
*
* @return $this
*/
public function setSmsBlacklisted($smsBlacklisted)
{
$this->container['smsBlacklisted'] = $smsBlacklisted;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets modifiedAt
*
* @return \DateTime
*/
public function getModifiedAt()
{
return $this->container['modifiedAt'];
}
/**
* Sets modifiedAt
*
* @param \DateTime $modifiedAt Last modification UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setModifiedAt($modifiedAt)
{
$this->container['modifiedAt'] = $modifiedAt;
return $this;
}
/**
* Gets listIds
*
* @return int[]
*/
public function getListIds()
{
return $this->container['listIds'];
}
/**
* Sets listIds
*
* @param int[] $listIds listIds
*
* @return $this
*/
public function setListIds($listIds)
{
$this->container['listIds'] = $listIds;
return $this;
}
/**
* Gets listUnsubscribed
*
* @return int[]
*/
public function getListUnsubscribed()
{
return $this->container['listUnsubscribed'];
}
/**
* Sets listUnsubscribed
*
* @param int[] $listUnsubscribed listUnsubscribed
*
* @return $this
*/
public function setListUnsubscribed($listUnsubscribed)
{
$this->container['listUnsubscribed'] = $listUnsubscribed;
return $this;
}
/**
* Gets attributes
*
* @return object
*/
public function getAttributes()
{
return $this->container['attributes'];
}
/**
* Sets attributes
*
* @param object $attributes Set of attributes of the contact
*
* @return $this
*/
public function setAttributes($attributes)
{
$this->container['attributes'] = $attributes;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetContacts
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetContacts Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetContacts implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getContacts';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'contacts' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'contacts' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'contacts' => 'contacts',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'contacts' => 'setContacts',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'contacts' => 'getContacts',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['contacts'] = isset($data['contacts']) ? $data['contacts'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['contacts'] === null) {
$invalidProperties[] = "'contacts' can't be null";
}
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['contacts'] === null) {
return false;
}
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets contacts
*
* @return object[]
*/
public function getContacts()
{
return $this->container['contacts'];
}
/**
* Sets contacts
*
* @param object[] $contacts contacts
*
* @return $this
*/
public function setContacts($contacts)
{
$this->container['contacts'] = $contacts;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of contacts
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,338 @@
<?php
/**
* GetEmailCampaigns
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetEmailCampaigns Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetEmailCampaigns implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getEmailCampaigns';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaigns' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaigns' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaigns' => 'campaigns',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaigns' => 'setCampaigns',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaigns' => 'getCampaigns',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaigns'] = isset($data['campaigns']) ? $data['campaigns'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets campaigns
*
* @return object[]
*/
public function getCampaigns()
{
return $this->container['campaigns'];
}
/**
* Sets campaigns
*
* @param object[] $campaigns campaigns
*
* @return $this
*/
public function setCampaigns($campaigns)
{
$this->container['campaigns'] = $campaigns;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of Email campaigns retrieved
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* GetEmailEventReport
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetEmailEventReport Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetEmailEventReport implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getEmailEventReport';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'events' => '\SendinBlue\Client\Model\GetEmailEventReportEvents[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'events' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'events' => 'events'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'events' => 'setEvents'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'events' => 'getEvents'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['events'] = isset($data['events']) ? $data['events'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets events
*
* @return \SendinBlue\Client\Model\GetEmailEventReportEvents[]
*/
public function getEvents()
{
return $this->container['events'];
}
/**
* Sets events
*
* @param \SendinBlue\Client\Model\GetEmailEventReportEvents[] $events events
*
* @return $this
*/
public function setEvents($events)
{
$this->container['events'] = $events;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,652 @@
<?php
/**
* GetEmailEventReportEvents
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetEmailEventReportEvents Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetEmailEventReportEvents implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getEmailEventReport_events';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'date' => '\DateTime',
'subject' => 'string',
'messageId' => 'string',
'event' => 'string',
'reason' => 'string',
'tag' => 'string',
'ip' => 'string',
'link' => 'string',
'from' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'date' => 'date-time',
'subject' => null,
'messageId' => null,
'event' => null,
'reason' => null,
'tag' => null,
'ip' => null,
'link' => null,
'from' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'date' => 'date',
'subject' => 'subject',
'messageId' => 'messageId',
'event' => 'event',
'reason' => 'reason',
'tag' => 'tag',
'ip' => 'ip',
'link' => 'link',
'from' => 'from'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'date' => 'setDate',
'subject' => 'setSubject',
'messageId' => 'setMessageId',
'event' => 'setEvent',
'reason' => 'setReason',
'tag' => 'setTag',
'ip' => 'setIp',
'link' => 'setLink',
'from' => 'setFrom'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'date' => 'getDate',
'subject' => 'getSubject',
'messageId' => 'getMessageId',
'event' => 'getEvent',
'reason' => 'getReason',
'tag' => 'getTag',
'ip' => 'getIp',
'link' => 'getLink',
'from' => 'getFrom'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const EVENT_BOUNCES = 'bounces';
const EVENT_HARD_BOUNCES = 'hardBounces';
const EVENT_SOFT_BOUNCES = 'softBounces';
const EVENT_DELIVERED = 'delivered';
const EVENT_SPAM = 'spam';
const EVENT_REQUESTS = 'requests';
const EVENT_OPENED = 'opened';
const EVENT_CLICKS = 'clicks';
const EVENT_INVALID = 'invalid';
const EVENT_DEFERRED = 'deferred';
const EVENT_BLOCKED = 'blocked';
const EVENT_UNSUBSCRIBED = 'unsubscribed';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getEventAllowableValues()
{
return [
self::EVENT_BOUNCES,
self::EVENT_HARD_BOUNCES,
self::EVENT_SOFT_BOUNCES,
self::EVENT_DELIVERED,
self::EVENT_SPAM,
self::EVENT_REQUESTS,
self::EVENT_OPENED,
self::EVENT_CLICKS,
self::EVENT_INVALID,
self::EVENT_DEFERRED,
self::EVENT_BLOCKED,
self::EVENT_UNSUBSCRIBED,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['date'] = isset($data['date']) ? $data['date'] : null;
$this->container['subject'] = isset($data['subject']) ? $data['subject'] : null;
$this->container['messageId'] = isset($data['messageId']) ? $data['messageId'] : null;
$this->container['event'] = isset($data['event']) ? $data['event'] : null;
$this->container['reason'] = isset($data['reason']) ? $data['reason'] : null;
$this->container['tag'] = isset($data['tag']) ? $data['tag'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['link'] = isset($data['link']) ? $data['link'] : null;
$this->container['from'] = isset($data['from']) ? $data['from'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['date'] === null) {
$invalidProperties[] = "'date' can't be null";
}
if ($this->container['messageId'] === null) {
$invalidProperties[] = "'messageId' can't be null";
}
if ($this->container['event'] === null) {
$invalidProperties[] = "'event' can't be null";
}
$allowedValues = $this->getEventAllowableValues();
if (!in_array($this->container['event'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'event', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['date'] === null) {
return false;
}
if ($this->container['messageId'] === null) {
return false;
}
if ($this->container['event'] === null) {
return false;
}
$allowedValues = $this->getEventAllowableValues();
if (!in_array($this->container['event'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email address which generates the event
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets date
*
* @return \DateTime
*/
public function getDate()
{
return $this->container['date'];
}
/**
* Sets date
*
* @param \DateTime $date UTC date-time on which the event has been generated
*
* @return $this
*/
public function setDate($date)
{
$this->container['date'] = $date;
return $this;
}
/**
* Gets subject
*
* @return string
*/
public function getSubject()
{
return $this->container['subject'];
}
/**
* Sets subject
*
* @param string $subject Subject of the event
*
* @return $this
*/
public function setSubject($subject)
{
$this->container['subject'] = $subject;
return $this;
}
/**
* Gets messageId
*
* @return string
*/
public function getMessageId()
{
return $this->container['messageId'];
}
/**
* Sets messageId
*
* @param string $messageId Message ID which generated the event
*
* @return $this
*/
public function setMessageId($messageId)
{
$this->container['messageId'] = $messageId;
return $this;
}
/**
* Gets event
*
* @return string
*/
public function getEvent()
{
return $this->container['event'];
}
/**
* Sets event
*
* @param string $event Event which occurred
*
* @return $this
*/
public function setEvent($event)
{
$allowedValues = $this->getEventAllowableValues();
if (!in_array($event, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'event', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['event'] = $event;
return $this;
}
/**
* Gets reason
*
* @return string
*/
public function getReason()
{
return $this->container['reason'];
}
/**
* Sets reason
*
* @param string $reason Reason of bounce (only available if the event is hardbounce or softbounce)
*
* @return $this
*/
public function setReason($reason)
{
$this->container['reason'] = $reason;
return $this;
}
/**
* Gets tag
*
* @return string
*/
public function getTag()
{
return $this->container['tag'];
}
/**
* Sets tag
*
* @param string $tag Tag of the email which generated the event
*
* @return $this
*/
public function setTag($tag)
{
$this->container['tag'] = $tag;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has opened the email or clicked on the link (only available if the event is opened or clicks)
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets link
*
* @return string
*/
public function getLink()
{
return $this->container['link'];
}
/**
* Sets link
*
* @param string $link The link which is sent to the user (only available if the event is requests or opened or clicks)
*
* @return $this
*/
public function setLink($link)
{
$this->container['link'] = $link;
return $this;
}
/**
* Gets from
*
* @return string
*/
public function getFrom()
{
return $this->container['from'];
}
/**
* Sets from
*
* @param string $from Sender email from which the emails are sent
*
* @return $this
*/
public function setFrom($from)
{
$this->container['from'] = $from;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,332 @@
<?php
/**
* GetExtendedCampaignOverviewSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedCampaignOverviewSender Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedCampaignOverviewSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedCampaignOverview_sender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'name' => 'string',
'email' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'name' => null,
'email' => 'email'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'name' => 'name',
'email' => 'email'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'name' => 'setName',
'email' => 'setEmail'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'name' => 'getName',
'email' => 'getEmail'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Sender name of the campaign
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Sender email of the campaign
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,488 @@
<?php
/**
* GetExtendedCampaignStats
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedCampaignStats Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedCampaignStats implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedCampaignStats';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'globalStats' => 'object',
'campaignStats' => 'object[]',
'mirrorClick' => 'int',
'remaining' => 'int',
'linksStats' => 'object',
'statsByDomain' => '\SendinBlue\Client\Model\GetStatsByDomain'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'globalStats' => null,
'campaignStats' => null,
'mirrorClick' => 'int64',
'remaining' => 'int64',
'linksStats' => null,
'statsByDomain' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'globalStats' => 'globalStats',
'campaignStats' => 'campaignStats',
'mirrorClick' => 'mirrorClick',
'remaining' => 'remaining',
'linksStats' => 'linksStats',
'statsByDomain' => 'statsByDomain'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'globalStats' => 'setGlobalStats',
'campaignStats' => 'setCampaignStats',
'mirrorClick' => 'setMirrorClick',
'remaining' => 'setRemaining',
'linksStats' => 'setLinksStats',
'statsByDomain' => 'setStatsByDomain'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'globalStats' => 'getGlobalStats',
'campaignStats' => 'getCampaignStats',
'mirrorClick' => 'getMirrorClick',
'remaining' => 'getRemaining',
'linksStats' => 'getLinksStats',
'statsByDomain' => 'getStatsByDomain'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['globalStats'] = isset($data['globalStats']) ? $data['globalStats'] : null;
$this->container['campaignStats'] = isset($data['campaignStats']) ? $data['campaignStats'] : null;
$this->container['mirrorClick'] = isset($data['mirrorClick']) ? $data['mirrorClick'] : null;
$this->container['remaining'] = isset($data['remaining']) ? $data['remaining'] : null;
$this->container['linksStats'] = isset($data['linksStats']) ? $data['linksStats'] : null;
$this->container['statsByDomain'] = isset($data['statsByDomain']) ? $data['statsByDomain'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['globalStats'] === null) {
$invalidProperties[] = "'globalStats' can't be null";
}
if ($this->container['campaignStats'] === null) {
$invalidProperties[] = "'campaignStats' can't be null";
}
if ($this->container['mirrorClick'] === null) {
$invalidProperties[] = "'mirrorClick' can't be null";
}
if ($this->container['remaining'] === null) {
$invalidProperties[] = "'remaining' can't be null";
}
if ($this->container['linksStats'] === null) {
$invalidProperties[] = "'linksStats' can't be null";
}
if ($this->container['statsByDomain'] === null) {
$invalidProperties[] = "'statsByDomain' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['globalStats'] === null) {
return false;
}
if ($this->container['campaignStats'] === null) {
return false;
}
if ($this->container['mirrorClick'] === null) {
return false;
}
if ($this->container['remaining'] === null) {
return false;
}
if ($this->container['linksStats'] === null) {
return false;
}
if ($this->container['statsByDomain'] === null) {
return false;
}
return true;
}
/**
* Gets globalStats
*
* @return object
*/
public function getGlobalStats()
{
return $this->container['globalStats'];
}
/**
* Sets globalStats
*
* @param object $globalStats Overall statistics of the campaign
*
* @return $this
*/
public function setGlobalStats($globalStats)
{
$this->container['globalStats'] = $globalStats;
return $this;
}
/**
* Gets campaignStats
*
* @return object[]
*/
public function getCampaignStats()
{
return $this->container['campaignStats'];
}
/**
* Sets campaignStats
*
* @param object[] $campaignStats List-wise statistics of the campaign.
*
* @return $this
*/
public function setCampaignStats($campaignStats)
{
$this->container['campaignStats'] = $campaignStats;
return $this;
}
/**
* Gets mirrorClick
*
* @return int
*/
public function getMirrorClick()
{
return $this->container['mirrorClick'];
}
/**
* Sets mirrorClick
*
* @param int $mirrorClick Number of clicks on mirror link
*
* @return $this
*/
public function setMirrorClick($mirrorClick)
{
$this->container['mirrorClick'] = $mirrorClick;
return $this;
}
/**
* Gets remaining
*
* @return int
*/
public function getRemaining()
{
return $this->container['remaining'];
}
/**
* Sets remaining
*
* @param int $remaining Number of remaning emails to send
*
* @return $this
*/
public function setRemaining($remaining)
{
$this->container['remaining'] = $remaining;
return $this;
}
/**
* Gets linksStats
*
* @return object
*/
public function getLinksStats()
{
return $this->container['linksStats'];
}
/**
* Sets linksStats
*
* @param object $linksStats Statistics about the number of clicks for the links
*
* @return $this
*/
public function setLinksStats($linksStats)
{
$this->container['linksStats'] = $linksStats;
return $this;
}
/**
* Gets statsByDomain
*
* @return \SendinBlue\Client\Model\GetStatsByDomain
*/
public function getStatsByDomain()
{
return $this->container['statsByDomain'];
}
/**
* Sets statsByDomain
*
* @param \SendinBlue\Client\Model\GetStatsByDomain $statsByDomain statsByDomain
*
* @return $this
*/
public function setStatsByDomain($statsByDomain)
{
$this->container['statsByDomain'] = $statsByDomain;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,452 @@
<?php
/**
* GetExtendedClient
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedClient Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedClient implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedClient';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'firstName' => 'string',
'lastName' => 'string',
'companyName' => 'string',
'address' => '\SendinBlue\Client\Model\GetExtendedClientAddress'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'firstName' => null,
'lastName' => null,
'companyName' => null,
'address' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'firstName' => 'firstName',
'lastName' => 'lastName',
'companyName' => 'companyName',
'address' => 'address'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'firstName' => 'setFirstName',
'lastName' => 'setLastName',
'companyName' => 'setCompanyName',
'address' => 'setAddress'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'firstName' => 'getFirstName',
'lastName' => 'getLastName',
'companyName' => 'getCompanyName',
'address' => 'getAddress'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['firstName'] = isset($data['firstName']) ? $data['firstName'] : null;
$this->container['lastName'] = isset($data['lastName']) ? $data['lastName'] : null;
$this->container['companyName'] = isset($data['companyName']) ? $data['companyName'] : null;
$this->container['address'] = isset($data['address']) ? $data['address'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['firstName'] === null) {
$invalidProperties[] = "'firstName' can't be null";
}
if ($this->container['lastName'] === null) {
$invalidProperties[] = "'lastName' can't be null";
}
if ($this->container['companyName'] === null) {
$invalidProperties[] = "'companyName' can't be null";
}
if ($this->container['address'] === null) {
$invalidProperties[] = "'address' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['firstName'] === null) {
return false;
}
if ($this->container['lastName'] === null) {
return false;
}
if ($this->container['companyName'] === null) {
return false;
}
if ($this->container['address'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Login Email
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets firstName
*
* @return string
*/
public function getFirstName()
{
return $this->container['firstName'];
}
/**
* Sets firstName
*
* @param string $firstName First Name
*
* @return $this
*/
public function setFirstName($firstName)
{
$this->container['firstName'] = $firstName;
return $this;
}
/**
* Gets lastName
*
* @return string
*/
public function getLastName()
{
return $this->container['lastName'];
}
/**
* Sets lastName
*
* @param string $lastName Last Name
*
* @return $this
*/
public function setLastName($lastName)
{
$this->container['lastName'] = $lastName;
return $this;
}
/**
* Gets companyName
*
* @return string
*/
public function getCompanyName()
{
return $this->container['companyName'];
}
/**
* Sets companyName
*
* @param string $companyName Name of the company
*
* @return $this
*/
public function setCompanyName($companyName)
{
$this->container['companyName'] = $companyName;
return $this;
}
/**
* Gets address
*
* @return \SendinBlue\Client\Model\GetExtendedClientAddress
*/
public function getAddress()
{
return $this->container['address'];
}
/**
* Sets address
*
* @param \SendinBlue\Client\Model\GetExtendedClientAddress $address address
*
* @return $this
*/
public function setAddress($address)
{
$this->container['address'] = $address;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,417 @@
<?php
/**
* GetExtendedClientAddress
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedClientAddress Class Doc Comment
*
* @category Class
* @description Address informations
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedClientAddress implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedClient_address';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'street' => 'string',
'city' => 'string',
'zipCode' => 'string',
'country' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'street' => null,
'city' => null,
'zipCode' => null,
'country' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'street' => 'street',
'city' => 'city',
'zipCode' => 'zipCode',
'country' => 'country'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'street' => 'setStreet',
'city' => 'setCity',
'zipCode' => 'setZipCode',
'country' => 'setCountry'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'street' => 'getStreet',
'city' => 'getCity',
'zipCode' => 'getZipCode',
'country' => 'getCountry'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['street'] = isset($data['street']) ? $data['street'] : null;
$this->container['city'] = isset($data['city']) ? $data['city'] : null;
$this->container['zipCode'] = isset($data['zipCode']) ? $data['zipCode'] : null;
$this->container['country'] = isset($data['country']) ? $data['country'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['street'] === null) {
$invalidProperties[] = "'street' can't be null";
}
if ($this->container['city'] === null) {
$invalidProperties[] = "'city' can't be null";
}
if ($this->container['zipCode'] === null) {
$invalidProperties[] = "'zipCode' can't be null";
}
if ($this->container['country'] === null) {
$invalidProperties[] = "'country' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['street'] === null) {
return false;
}
if ($this->container['city'] === null) {
return false;
}
if ($this->container['zipCode'] === null) {
return false;
}
if ($this->container['country'] === null) {
return false;
}
return true;
}
/**
* Gets street
*
* @return string
*/
public function getStreet()
{
return $this->container['street'];
}
/**
* Sets street
*
* @param string $street Street information
*
* @return $this
*/
public function setStreet($street)
{
$this->container['street'] = $street;
return $this;
}
/**
* Gets city
*
* @return string
*/
public function getCity()
{
return $this->container['city'];
}
/**
* Sets city
*
* @param string $city City information
*
* @return $this
*/
public function setCity($city)
{
$this->container['city'] = $city;
return $this;
}
/**
* Gets zipCode
*
* @return string
*/
public function getZipCode()
{
return $this->container['zipCode'];
}
/**
* Sets zipCode
*
* @param string $zipCode Zip Code information
*
* @return $this
*/
public function setZipCode($zipCode)
{
$this->container['zipCode'] = $zipCode;
return $this;
}
/**
* Gets country
*
* @return string
*/
public function getCountry()
{
return $this->container['country'];
}
/**
* Sets country
*
* @param string $country Country information
*
* @return $this
*/
public function setCountry($country)
{
$this->container['country'] = $country;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,626 @@
<?php
/**
* GetExtendedContactDetails
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetails Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetails implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'email' => 'string',
'id' => 'int',
'emailBlacklisted' => 'bool',
'smsBlacklisted' => 'bool',
'createdAt' => '\DateTime',
'modifiedAt' => '\DateTime',
'listIds' => 'int[]',
'listUnsubscribed' => 'int[]',
'attributes' => 'object',
'statistics' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatistics'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'email' => 'email',
'id' => 'int64',
'emailBlacklisted' => null,
'smsBlacklisted' => null,
'createdAt' => 'date-time',
'modifiedAt' => 'date-time',
'listIds' => 'int64',
'listUnsubscribed' => 'int64',
'attributes' => null,
'statistics' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'email' => 'email',
'id' => 'id',
'emailBlacklisted' => 'emailBlacklisted',
'smsBlacklisted' => 'smsBlacklisted',
'createdAt' => 'createdAt',
'modifiedAt' => 'modifiedAt',
'listIds' => 'listIds',
'listUnsubscribed' => 'listUnsubscribed',
'attributes' => 'attributes',
'statistics' => 'statistics'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'email' => 'setEmail',
'id' => 'setId',
'emailBlacklisted' => 'setEmailBlacklisted',
'smsBlacklisted' => 'setSmsBlacklisted',
'createdAt' => 'setCreatedAt',
'modifiedAt' => 'setModifiedAt',
'listIds' => 'setListIds',
'listUnsubscribed' => 'setListUnsubscribed',
'attributes' => 'setAttributes',
'statistics' => 'setStatistics'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'email' => 'getEmail',
'id' => 'getId',
'emailBlacklisted' => 'getEmailBlacklisted',
'smsBlacklisted' => 'getSmsBlacklisted',
'createdAt' => 'getCreatedAt',
'modifiedAt' => 'getModifiedAt',
'listIds' => 'getListIds',
'listUnsubscribed' => 'getListUnsubscribed',
'attributes' => 'getAttributes',
'statistics' => 'getStatistics'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['emailBlacklisted'] = isset($data['emailBlacklisted']) ? $data['emailBlacklisted'] : null;
$this->container['smsBlacklisted'] = isset($data['smsBlacklisted']) ? $data['smsBlacklisted'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['modifiedAt'] = isset($data['modifiedAt']) ? $data['modifiedAt'] : null;
$this->container['listIds'] = isset($data['listIds']) ? $data['listIds'] : null;
$this->container['listUnsubscribed'] = isset($data['listUnsubscribed']) ? $data['listUnsubscribed'] : null;
$this->container['attributes'] = isset($data['attributes']) ? $data['attributes'] : null;
$this->container['statistics'] = isset($data['statistics']) ? $data['statistics'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['emailBlacklisted'] === null) {
$invalidProperties[] = "'emailBlacklisted' can't be null";
}
if ($this->container['smsBlacklisted'] === null) {
$invalidProperties[] = "'smsBlacklisted' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
if ($this->container['modifiedAt'] === null) {
$invalidProperties[] = "'modifiedAt' can't be null";
}
if ($this->container['listIds'] === null) {
$invalidProperties[] = "'listIds' can't be null";
}
if ($this->container['attributes'] === null) {
$invalidProperties[] = "'attributes' can't be null";
}
if ($this->container['statistics'] === null) {
$invalidProperties[] = "'statistics' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['email'] === null) {
return false;
}
if ($this->container['id'] === null) {
return false;
}
if ($this->container['emailBlacklisted'] === null) {
return false;
}
if ($this->container['smsBlacklisted'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
if ($this->container['modifiedAt'] === null) {
return false;
}
if ($this->container['listIds'] === null) {
return false;
}
if ($this->container['attributes'] === null) {
return false;
}
if ($this->container['statistics'] === null) {
return false;
}
return true;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email Email address of the contact for which you requested the details
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the contact for which you requested the details
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets emailBlacklisted
*
* @return bool
*/
public function getEmailBlacklisted()
{
return $this->container['emailBlacklisted'];
}
/**
* Sets emailBlacklisted
*
* @param bool $emailBlacklisted Blacklist status for email campaigns (true=blacklisted, false=not blacklisted)
*
* @return $this
*/
public function setEmailBlacklisted($emailBlacklisted)
{
$this->container['emailBlacklisted'] = $emailBlacklisted;
return $this;
}
/**
* Gets smsBlacklisted
*
* @return bool
*/
public function getSmsBlacklisted()
{
return $this->container['smsBlacklisted'];
}
/**
* Sets smsBlacklisted
*
* @param bool $smsBlacklisted Blacklist status for SMS campaigns (true=blacklisted, false=not blacklisted)
*
* @return $this
*/
public function setSmsBlacklisted($smsBlacklisted)
{
$this->container['smsBlacklisted'] = $smsBlacklisted;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets modifiedAt
*
* @return \DateTime
*/
public function getModifiedAt()
{
return $this->container['modifiedAt'];
}
/**
* Sets modifiedAt
*
* @param \DateTime $modifiedAt Last modification UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setModifiedAt($modifiedAt)
{
$this->container['modifiedAt'] = $modifiedAt;
return $this;
}
/**
* Gets listIds
*
* @return int[]
*/
public function getListIds()
{
return $this->container['listIds'];
}
/**
* Sets listIds
*
* @param int[] $listIds listIds
*
* @return $this
*/
public function setListIds($listIds)
{
$this->container['listIds'] = $listIds;
return $this;
}
/**
* Gets listUnsubscribed
*
* @return int[]
*/
public function getListUnsubscribed()
{
return $this->container['listUnsubscribed'];
}
/**
* Sets listUnsubscribed
*
* @param int[] $listUnsubscribed listUnsubscribed
*
* @return $this
*/
public function setListUnsubscribed($listUnsubscribed)
{
$this->container['listUnsubscribed'] = $listUnsubscribed;
return $this;
}
/**
* Gets attributes
*
* @return object
*/
public function getAttributes()
{
return $this->container['attributes'];
}
/**
* Sets attributes
*
* @param object $attributes Set of attributes of the contact
*
* @return $this
*/
public function setAttributes($attributes)
{
$this->container['attributes'] = $attributes;
return $this;
}
/**
* Gets statistics
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatistics
*/
public function getStatistics()
{
return $this->container['statistics'];
}
/**
* Sets statistics
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatistics $statistics statistics
*
* @return $this
*/
public function setStatistics($statistics)
{
$this->container['statistics'] = $statistics;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,513 @@
<?php
/**
* GetExtendedContactDetailsStatistics
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatistics Class Doc Comment
*
* @category Class
* @description Campaign statistics of the contact
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatistics implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'messagesSent' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'hardBounces' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'softBounces' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'complaints' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]',
'unsubscriptions' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptions',
'opened' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsOpened[]',
'clicked' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsClicked[]',
'transacAttributes' => 'object[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'messagesSent' => null,
'hardBounces' => null,
'softBounces' => null,
'complaints' => null,
'unsubscriptions' => null,
'opened' => null,
'clicked' => null,
'transacAttributes' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'messagesSent' => 'messagesSent',
'hardBounces' => 'hardBounces',
'softBounces' => 'softBounces',
'complaints' => 'complaints',
'unsubscriptions' => 'unsubscriptions',
'opened' => 'opened',
'clicked' => 'clicked',
'transacAttributes' => 'transacAttributes'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'messagesSent' => 'setMessagesSent',
'hardBounces' => 'setHardBounces',
'softBounces' => 'setSoftBounces',
'complaints' => 'setComplaints',
'unsubscriptions' => 'setUnsubscriptions',
'opened' => 'setOpened',
'clicked' => 'setClicked',
'transacAttributes' => 'setTransacAttributes'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'messagesSent' => 'getMessagesSent',
'hardBounces' => 'getHardBounces',
'softBounces' => 'getSoftBounces',
'complaints' => 'getComplaints',
'unsubscriptions' => 'getUnsubscriptions',
'opened' => 'getOpened',
'clicked' => 'getClicked',
'transacAttributes' => 'getTransacAttributes'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['messagesSent'] = isset($data['messagesSent']) ? $data['messagesSent'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['complaints'] = isset($data['complaints']) ? $data['complaints'] : null;
$this->container['unsubscriptions'] = isset($data['unsubscriptions']) ? $data['unsubscriptions'] : null;
$this->container['opened'] = isset($data['opened']) ? $data['opened'] : null;
$this->container['clicked'] = isset($data['clicked']) ? $data['clicked'] : null;
$this->container['transacAttributes'] = isset($data['transacAttributes']) ? $data['transacAttributes'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets messagesSent
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getMessagesSent()
{
return $this->container['messagesSent'];
}
/**
* Sets messagesSent
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $messagesSent Listing of the sent campaign for the contact
*
* @return $this
*/
public function setMessagesSent($messagesSent)
{
$this->container['messagesSent'] = $messagesSent;
return $this;
}
/**
* Gets hardBounces
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $hardBounces Listing of the hardbounes generated by the contact
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets softBounces
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $softBounces Listing of the softbounes generated by the contact
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets complaints
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[]
*/
public function getComplaints()
{
return $this->container['complaints'];
}
/**
* Sets complaints
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsMessagesSent[] $complaints Listing of the complaints generated by the contact
*
* @return $this
*/
public function setComplaints($complaints)
{
$this->container['complaints'] = $complaints;
return $this;
}
/**
* Gets unsubscriptions
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptions
*/
public function getUnsubscriptions()
{
return $this->container['unsubscriptions'];
}
/**
* Sets unsubscriptions
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptions $unsubscriptions unsubscriptions
*
* @return $this
*/
public function setUnsubscriptions($unsubscriptions)
{
$this->container['unsubscriptions'] = $unsubscriptions;
return $this;
}
/**
* Gets opened
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsOpened[]
*/
public function getOpened()
{
return $this->container['opened'];
}
/**
* Sets opened
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsOpened[] $opened Listing of the openings generated by the contact
*
* @return $this
*/
public function setOpened($opened)
{
$this->container['opened'] = $opened;
return $this;
}
/**
* Gets clicked
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsClicked[]
*/
public function getClicked()
{
return $this->container['clicked'];
}
/**
* Sets clicked
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsClicked[] $clicked Listing of the clicks generated by the contact
*
* @return $this
*/
public function setClicked($clicked)
{
$this->container['clicked'] = $clicked;
return $this;
}
/**
* Gets transacAttributes
*
* @return object[]
*/
public function getTransacAttributes()
{
return $this->container['transacAttributes'];
}
/**
* Sets transacAttributes
*
* @param object[] $transacAttributes Listing of the transactional attributes for the contact
*
* @return $this
*/
public function setTransacAttributes($transacAttributes)
{
$this->container['transacAttributes'] = $transacAttributes;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetExtendedContactDetailsStatisticsClicked
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsClicked Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsClicked implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_clicked';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'links' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'links' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'links' => 'links'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'links' => 'setLinks'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'links' => 'getLinks'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['links'] = isset($data['links']) ? $data['links'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['links'] === null) {
$invalidProperties[] = "'links' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['links'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets links
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[]
*/
public function getLinks()
{
return $this->container['links'];
}
/**
* Sets links
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsLinks[] $links Listing of the clicked links for the campaign
*
* @return $this
*/
public function setLinks($links)
{
$this->container['links'] = $links;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetExtendedContactDetailsStatisticsLinks
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsLinks Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsLinks implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_links';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'count' => 'int',
'eventTime' => '\DateTime',
'ip' => 'string',
'url' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'count' => 'int64',
'eventTime' => 'date-time',
'ip' => null,
'url' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'count' => 'count',
'eventTime' => 'eventTime',
'ip' => 'ip',
'url' => 'url'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'count' => 'setCount',
'eventTime' => 'setEventTime',
'ip' => 'setIp',
'url' => 'setUrl'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'count' => 'getCount',
'eventTime' => 'getEventTime',
'ip' => 'getIp',
'url' => 'getUrl'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['url'] = isset($data['url']) ? $data['url'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
if ($this->container['url'] === null) {
$invalidProperties[] = "'url' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['count'] === null) {
return false;
}
if ($this->container['eventTime'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
if ($this->container['url'] === null) {
return false;
}
return true;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of clicks on this link for the campaign
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has clicked on the link
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets url
*
* @return string
*/
public function getUrl()
{
return $this->container['url'];
}
/**
* Sets url
*
* @param string $url URL of the clicked link
*
* @return $this
*/
public function setUrl($url)
{
$this->container['url'] = $url;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetExtendedContactDetailsStatisticsMessagesSent
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsMessagesSent Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsMessagesSent implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_messagesSent';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'eventTime' => '\DateTime'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'eventTime' => 'date-time'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'eventTime' => 'eventTime'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'eventTime' => 'setEventTime'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'eventTime' => 'getEventTime'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['eventTime'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetExtendedContactDetailsStatisticsOpened
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsOpened Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsOpened implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_opened';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'count' => 'int',
'eventTime' => '\DateTime',
'ip' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'count' => 'int64',
'eventTime' => 'date-time',
'ip' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'count' => 'count',
'eventTime' => 'eventTime',
'ip' => 'ip'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'count' => 'setCount',
'eventTime' => 'setEventTime',
'ip' => 'setIp'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'count' => 'getCount',
'eventTime' => 'getEventTime',
'ip' => 'getIp'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['count'] === null) {
return false;
}
if ($this->container['eventTime'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of openings for the campaign
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has opened the email
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,345 @@
<?php
/**
* GetExtendedContactDetailsStatisticsUnsubscriptions
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsUnsubscriptions Class Doc Comment
*
* @category Class
* @description Listing of the unsubscription for the contact
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsUnsubscriptions implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_unsubscriptions';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'userUnsubscription' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[]',
'adminUnsubscription' => '\SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'userUnsubscription' => null,
'adminUnsubscription' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'userUnsubscription' => 'userUnsubscription',
'adminUnsubscription' => 'adminUnsubscription'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'userUnsubscription' => 'setUserUnsubscription',
'adminUnsubscription' => 'setAdminUnsubscription'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'userUnsubscription' => 'getUserUnsubscription',
'adminUnsubscription' => 'getAdminUnsubscription'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['userUnsubscription'] = isset($data['userUnsubscription']) ? $data['userUnsubscription'] : null;
$this->container['adminUnsubscription'] = isset($data['adminUnsubscription']) ? $data['adminUnsubscription'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['userUnsubscription'] === null) {
$invalidProperties[] = "'userUnsubscription' can't be null";
}
if ($this->container['adminUnsubscription'] === null) {
$invalidProperties[] = "'adminUnsubscription' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['userUnsubscription'] === null) {
return false;
}
if ($this->container['adminUnsubscription'] === null) {
return false;
}
return true;
}
/**
* Gets userUnsubscription
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[]
*/
public function getUserUnsubscription()
{
return $this->container['userUnsubscription'];
}
/**
* Sets userUnsubscription
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription[] $userUnsubscription Contact unsubscribe via unsubscription link in a campaign
*
* @return $this
*/
public function setUserUnsubscription($userUnsubscription)
{
$this->container['userUnsubscription'] = $userUnsubscription;
return $this;
}
/**
* Gets adminUnsubscription
*
* @return \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[]
*/
public function getAdminUnsubscription()
{
return $this->container['adminUnsubscription'];
}
/**
* Sets adminUnsubscription
*
* @param \SendinBlue\Client\Model\GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription[] $adminUnsubscription Contact has been unsubscribed from the administrator
*
* @return $this
*/
public function setAdminUnsubscription($adminUnsubscription)
{
$this->container['adminUnsubscription'] = $adminUnsubscription;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsUnsubscriptionsAdminUnsubscription implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_unsubscriptions_adminUnsubscription';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'eventTime' => '\DateTime',
'ip' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'eventTime' => 'date-time',
'ip' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'eventTime' => 'eventTime',
'ip' => 'ip'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'eventTime' => 'setEventTime',
'ip' => 'setIp'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'eventTime' => 'getEventTime',
'ip' => 'getIp'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['eventTime'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
return true;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has been unsubscribed
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,380 @@
<?php
/**
* GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedContactDetailsStatisticsUnsubscriptionsUserUnsubscription implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedContactDetails_statistics_unsubscriptions_userUnsubscription';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'eventTime' => '\DateTime',
'ip' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'eventTime' => 'date-time',
'ip' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'eventTime' => 'eventTime',
'ip' => 'ip'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'eventTime' => 'setEventTime',
'ip' => 'setIp'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'eventTime' => 'getEventTime',
'ip' => 'getIp'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['eventTime'] = isset($data['eventTime']) ? $data['eventTime'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['eventTime'] === null) {
$invalidProperties[] = "'eventTime' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['eventTime'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign which generated the event
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets eventTime
*
* @return \DateTime
*/
public function getEventTime()
{
return $this->container['eventTime'];
}
/**
* Sets eventTime
*
* @param \DateTime $eventTime UTC date-time of the event
*
* @return $this
*/
public function setEventTime($eventTime)
{
$this->container['eventTime'] = $eventTime;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip IP from which the user has unsubscribed
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,548 @@
<?php
/**
* GetExtendedList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'totalBlacklisted' => 'int',
'totalSubscribers' => 'int',
'folderId' => 'int',
'createdAt' => '\DateTime',
'campaignStats' => '\SendinBlue\Client\Model\GetExtendedListCampaignStats[]',
'dynamicList' => 'bool'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'totalBlacklisted' => 'int64',
'totalSubscribers' => 'int64',
'folderId' => 'int64',
'createdAt' => 'date-time',
'campaignStats' => null,
'dynamicList' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'totalBlacklisted' => 'totalBlacklisted',
'totalSubscribers' => 'totalSubscribers',
'folderId' => 'folderId',
'createdAt' => 'createdAt',
'campaignStats' => 'campaignStats',
'dynamicList' => 'dynamicList'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'totalBlacklisted' => 'setTotalBlacklisted',
'totalSubscribers' => 'setTotalSubscribers',
'folderId' => 'setFolderId',
'createdAt' => 'setCreatedAt',
'campaignStats' => 'setCampaignStats',
'dynamicList' => 'setDynamicList'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'totalBlacklisted' => 'getTotalBlacklisted',
'totalSubscribers' => 'getTotalSubscribers',
'folderId' => 'getFolderId',
'createdAt' => 'getCreatedAt',
'campaignStats' => 'getCampaignStats',
'dynamicList' => 'getDynamicList'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['totalBlacklisted'] = isset($data['totalBlacklisted']) ? $data['totalBlacklisted'] : null;
$this->container['totalSubscribers'] = isset($data['totalSubscribers']) ? $data['totalSubscribers'] : null;
$this->container['folderId'] = isset($data['folderId']) ? $data['folderId'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['campaignStats'] = isset($data['campaignStats']) ? $data['campaignStats'] : null;
$this->container['dynamicList'] = isset($data['dynamicList']) ? $data['dynamicList'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['totalBlacklisted'] === null) {
$invalidProperties[] = "'totalBlacklisted' can't be null";
}
if ($this->container['totalSubscribers'] === null) {
$invalidProperties[] = "'totalSubscribers' can't be null";
}
if ($this->container['folderId'] === null) {
$invalidProperties[] = "'folderId' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['totalBlacklisted'] === null) {
return false;
}
if ($this->container['totalSubscribers'] === null) {
return false;
}
if ($this->container['folderId'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the list
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the list
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets totalBlacklisted
*
* @return int
*/
public function getTotalBlacklisted()
{
return $this->container['totalBlacklisted'];
}
/**
* Sets totalBlacklisted
*
* @param int $totalBlacklisted Number of blacklisted contacts in the list
*
* @return $this
*/
public function setTotalBlacklisted($totalBlacklisted)
{
$this->container['totalBlacklisted'] = $totalBlacklisted;
return $this;
}
/**
* Gets totalSubscribers
*
* @return int
*/
public function getTotalSubscribers()
{
return $this->container['totalSubscribers'];
}
/**
* Sets totalSubscribers
*
* @param int $totalSubscribers Number of contacts in the list
*
* @return $this
*/
public function setTotalSubscribers($totalSubscribers)
{
$this->container['totalSubscribers'] = $totalSubscribers;
return $this;
}
/**
* Gets folderId
*
* @return int
*/
public function getFolderId()
{
return $this->container['folderId'];
}
/**
* Sets folderId
*
* @param int $folderId ID of the folder
*
* @return $this
*/
public function setFolderId($folderId)
{
$this->container['folderId'] = $folderId;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the list (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets campaignStats
*
* @return \SendinBlue\Client\Model\GetExtendedListCampaignStats[]
*/
public function getCampaignStats()
{
return $this->container['campaignStats'];
}
/**
* Sets campaignStats
*
* @param \SendinBlue\Client\Model\GetExtendedListCampaignStats[] $campaignStats campaignStats
*
* @return $this
*/
public function setCampaignStats($campaignStats)
{
$this->container['campaignStats'] = $campaignStats;
return $this;
}
/**
* Gets dynamicList
*
* @return bool
*/
public function getDynamicList()
{
return $this->container['dynamicList'];
}
/**
* Sets dynamicList
*
* @param bool $dynamicList Status telling if the list is dynamic or not (true=dynamic, false=not dynamic)
*
* @return $this
*/
public function setDynamicList($dynamicList)
{
$this->container['dynamicList'] = $dynamicList;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetExtendedListCampaignStats
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetExtendedListCampaignStats Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetExtendedListCampaignStats implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getExtendedList_campaignStats';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaignId' => 'int',
'stats' => '\SendinBlue\Client\Model\GetCampaignStats'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaignId' => 'int64',
'stats' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaignId' => 'campaignId',
'stats' => 'stats'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaignId' => 'setCampaignId',
'stats' => 'setStats'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaignId' => 'getCampaignId',
'stats' => 'getStats'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaignId'] = isset($data['campaignId']) ? $data['campaignId'] : null;
$this->container['stats'] = isset($data['stats']) ? $data['stats'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['campaignId'] === null) {
$invalidProperties[] = "'campaignId' can't be null";
}
if ($this->container['stats'] === null) {
$invalidProperties[] = "'stats' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['campaignId'] === null) {
return false;
}
if ($this->container['stats'] === null) {
return false;
}
return true;
}
/**
* Gets campaignId
*
* @return int
*/
public function getCampaignId()
{
return $this->container['campaignId'];
}
/**
* Sets campaignId
*
* @param int $campaignId ID of the campaign
*
* @return $this
*/
public function setCampaignId($campaignId)
{
$this->container['campaignId'] = $campaignId;
return $this;
}
/**
* Gets stats
*
* @return \SendinBlue\Client\Model\GetCampaignStats
*/
public function getStats()
{
return $this->container['stats'];
}
/**
* Sets stats
*
* @param \SendinBlue\Client\Model\GetCampaignStats $stats stats
*
* @return $this
*/
public function setStats($stats)
{
$this->container['stats'] = $stats;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,452 @@
<?php
/**
* GetFolder
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetFolder Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetFolder implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getFolder';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'totalBlacklisted' => 'int',
'totalSubscribers' => 'int',
'uniqueSubscribers' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'totalBlacklisted' => 'int64',
'totalSubscribers' => 'int64',
'uniqueSubscribers' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'totalBlacklisted' => 'totalBlacklisted',
'totalSubscribers' => 'totalSubscribers',
'uniqueSubscribers' => 'uniqueSubscribers'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'totalBlacklisted' => 'setTotalBlacklisted',
'totalSubscribers' => 'setTotalSubscribers',
'uniqueSubscribers' => 'setUniqueSubscribers'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'totalBlacklisted' => 'getTotalBlacklisted',
'totalSubscribers' => 'getTotalSubscribers',
'uniqueSubscribers' => 'getUniqueSubscribers'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['totalBlacklisted'] = isset($data['totalBlacklisted']) ? $data['totalBlacklisted'] : null;
$this->container['totalSubscribers'] = isset($data['totalSubscribers']) ? $data['totalSubscribers'] : null;
$this->container['uniqueSubscribers'] = isset($data['uniqueSubscribers']) ? $data['uniqueSubscribers'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['totalBlacklisted'] === null) {
$invalidProperties[] = "'totalBlacklisted' can't be null";
}
if ($this->container['totalSubscribers'] === null) {
$invalidProperties[] = "'totalSubscribers' can't be null";
}
if ($this->container['uniqueSubscribers'] === null) {
$invalidProperties[] = "'uniqueSubscribers' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['totalBlacklisted'] === null) {
return false;
}
if ($this->container['totalSubscribers'] === null) {
return false;
}
if ($this->container['uniqueSubscribers'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the folder
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the folder
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets totalBlacklisted
*
* @return int
*/
public function getTotalBlacklisted()
{
return $this->container['totalBlacklisted'];
}
/**
* Sets totalBlacklisted
*
* @param int $totalBlacklisted Number of blacklisted contacts in the folder
*
* @return $this
*/
public function setTotalBlacklisted($totalBlacklisted)
{
$this->container['totalBlacklisted'] = $totalBlacklisted;
return $this;
}
/**
* Gets totalSubscribers
*
* @return int
*/
public function getTotalSubscribers()
{
return $this->container['totalSubscribers'];
}
/**
* Sets totalSubscribers
*
* @param int $totalSubscribers Number of contacts in the folder
*
* @return $this
*/
public function setTotalSubscribers($totalSubscribers)
{
$this->container['totalSubscribers'] = $totalSubscribers;
return $this;
}
/**
* Gets uniqueSubscribers
*
* @return int
*/
public function getUniqueSubscribers()
{
return $this->container['uniqueSubscribers'];
}
/**
* Sets uniqueSubscribers
*
* @param int $uniqueSubscribers Number of unique contacts in the folder
*
* @return $this
*/
public function setUniqueSubscribers($uniqueSubscribers)
{
$this->container['uniqueSubscribers'] = $uniqueSubscribers;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetFolderLists
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetFolderLists Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetFolderLists implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getFolderLists';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'lists' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'lists' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'lists' => 'lists',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'lists' => 'setLists',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'lists' => 'getLists',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['lists'] = isset($data['lists']) ? $data['lists'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['lists'] === null) {
$invalidProperties[] = "'lists' can't be null";
}
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['lists'] === null) {
return false;
}
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets lists
*
* @return object[]
*/
public function getLists()
{
return $this->container['lists'];
}
/**
* Sets lists
*
* @param object[] $lists lists
*
* @return $this
*/
public function setLists($lists)
{
$this->container['lists'] = $lists;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of lists in the folder
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,332 @@
<?php
/**
* GetFolders
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetFolders Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetFolders implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getFolders';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'folders' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'folders' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'folders' => 'folders',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'folders' => 'setFolders',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'folders' => 'getFolders',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['folders'] = isset($data['folders']) ? $data['folders'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets folders
*
* @return object[]
*/
public function getFolders()
{
return $this->container['folders'];
}
/**
* Sets folders
*
* @param object[] $folders folders
*
* @return $this
*/
public function setFolders($folders)
{
$this->container['folders'] = $folders;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of folders available in your account
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetIp
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetIp Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetIp implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getIp';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'ip' => 'string',
'active' => 'bool',
'domain' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'ip' => null,
'active' => null,
'domain' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'ip' => 'ip',
'active' => 'active',
'domain' => 'domain'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'ip' => 'setIp',
'active' => 'setActive',
'domain' => 'setDomain'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'ip' => 'getIp',
'active' => 'getActive',
'domain' => 'getDomain'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['active'] = isset($data['active']) ? $data['active'] : null;
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
if ($this->container['active'] === null) {
$invalidProperties[] = "'active' can't be null";
}
if ($this->container['domain'] === null) {
$invalidProperties[] = "'domain' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
if ($this->container['active'] === null) {
return false;
}
if ($this->container['domain'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the dedicated IP
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip Dedicated IP
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets active
*
* @return bool
*/
public function getActive()
{
return $this->container['active'];
}
/**
* Sets active
*
* @param bool $active Status of the IP (true=active, false=inactive)
*
* @return $this
*/
public function setActive($active)
{
$this->container['active'] = $active;
return $this;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Domain associated to the IP
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetIpFromSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetIpFromSender Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetIpFromSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getIpFromSender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'ip' => 'string',
'domain' => 'string',
'weight' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'ip' => null,
'domain' => null,
'weight' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'ip' => 'ip',
'domain' => 'domain',
'weight' => 'weight'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'ip' => 'setIp',
'domain' => 'setDomain',
'weight' => 'setWeight'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'ip' => 'getIp',
'domain' => 'getDomain',
'weight' => 'getWeight'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
$this->container['weight'] = isset($data['weight']) ? $data['weight'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
if ($this->container['domain'] === null) {
$invalidProperties[] = "'domain' can't be null";
}
if ($this->container['weight'] === null) {
$invalidProperties[] = "'weight' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['ip'] === null) {
return false;
}
if ($this->container['domain'] === null) {
return false;
}
if ($this->container['weight'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the dedicated IP
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip Dedicated IP
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Domain associated to the IP
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Gets weight
*
* @return int
*/
public function getWeight()
{
return $this->container['weight'];
}
/**
* Sets weight
*
* @param int $weight Weight of the IP
*
* @return $this
*/
public function setWeight($weight)
{
$this->container['weight'] = $weight;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* GetIps
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetIps Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetIps implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getIps';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'ips' => '\SendinBlue\Client\Model\GetIp[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'ips' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'ips' => 'ips'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'ips' => 'setIps'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'ips' => 'getIps'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['ips'] = isset($data['ips']) ? $data['ips'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['ips'] === null) {
$invalidProperties[] = "'ips' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['ips'] === null) {
return false;
}
return true;
}
/**
* Gets ips
*
* @return \SendinBlue\Client\Model\GetIp[]
*/
public function getIps()
{
return $this->container['ips'];
}
/**
* Sets ips
*
* @param \SendinBlue\Client\Model\GetIp[] $ips Dedicated IP(s) available on your account
*
* @return $this
*/
public function setIps($ips)
{
$this->container['ips'] = $ips;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,308 @@
<?php
/**
* GetIpsFromSender
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetIpsFromSender Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetIpsFromSender implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getIpsFromSender';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'ips' => '\SendinBlue\Client\Model\GetIpFromSender[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'ips' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'ips' => 'ips'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'ips' => 'setIps'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'ips' => 'getIps'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['ips'] = isset($data['ips']) ? $data['ips'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['ips'] === null) {
$invalidProperties[] = "'ips' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['ips'] === null) {
return false;
}
return true;
}
/**
* Gets ips
*
* @return \SendinBlue\Client\Model\GetIpFromSender[]
*/
public function getIps()
{
return $this->container['ips'];
}
/**
* Sets ips
*
* @param \SendinBlue\Client\Model\GetIpFromSender[] $ips Dedicated IP(s) linked to a sender
*
* @return $this
*/
public function setIps($ips)
{
$this->container['ips'] = $ips;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,416 @@
<?php
/**
* GetList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'totalBlacklisted' => 'int',
'totalSubscribers' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'totalBlacklisted' => 'int64',
'totalSubscribers' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'totalBlacklisted' => 'totalBlacklisted',
'totalSubscribers' => 'totalSubscribers'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'totalBlacklisted' => 'setTotalBlacklisted',
'totalSubscribers' => 'setTotalSubscribers'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'totalBlacklisted' => 'getTotalBlacklisted',
'totalSubscribers' => 'getTotalSubscribers'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['totalBlacklisted'] = isset($data['totalBlacklisted']) ? $data['totalBlacklisted'] : null;
$this->container['totalSubscribers'] = isset($data['totalSubscribers']) ? $data['totalSubscribers'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['totalBlacklisted'] === null) {
$invalidProperties[] = "'totalBlacklisted' can't be null";
}
if ($this->container['totalSubscribers'] === null) {
$invalidProperties[] = "'totalSubscribers' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['totalBlacklisted'] === null) {
return false;
}
if ($this->container['totalSubscribers'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the list
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the list
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets totalBlacklisted
*
* @return int
*/
public function getTotalBlacklisted()
{
return $this->container['totalBlacklisted'];
}
/**
* Sets totalBlacklisted
*
* @param int $totalBlacklisted Number of blacklisted contacts in the list
*
* @return $this
*/
public function setTotalBlacklisted($totalBlacklisted)
{
$this->container['totalBlacklisted'] = $totalBlacklisted;
return $this;
}
/**
* Gets totalSubscribers
*
* @return int
*/
public function getTotalSubscribers()
{
return $this->container['totalSubscribers'];
}
/**
* Sets totalSubscribers
*
* @param int $totalSubscribers Number of contacts in the list
*
* @return $this
*/
public function setTotalSubscribers($totalSubscribers)
{
$this->container['totalSubscribers'] = $totalSubscribers;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,344 @@
<?php
/**
* GetLists
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetLists Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetLists implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getLists';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'lists' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'lists' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'lists' => 'lists',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'lists' => 'setLists',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'lists' => 'getLists',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['lists'] = isset($data['lists']) ? $data['lists'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['lists'] === null) {
$invalidProperties[] = "'lists' can't be null";
}
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['lists'] === null) {
return false;
}
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets lists
*
* @return object[]
*/
public function getLists()
{
return $this->container['lists'];
}
/**
* Sets lists
*
* @param object[] $lists Listing of all the lists available in your account
*
* @return $this
*/
public function setLists($lists)
{
$this->container['lists'] = $lists;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of lists in your account
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,448 @@
<?php
/**
* GetProcess
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetProcess Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetProcess implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getProcess';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'status' => 'string',
'name' => 'string',
'exportUrl' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'status' => null,
'name' => null,
'exportUrl' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'status' => 'status',
'name' => 'name',
'exportUrl' => 'export_url'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'status' => 'setStatus',
'name' => 'setName',
'exportUrl' => 'setExportUrl'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'status' => 'getStatus',
'name' => 'getName',
'exportUrl' => 'getExportUrl'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const STATUS_QUEUED = 'queued';
const STATUS_IN_PROCESS = 'in_process';
const STATUS_COMPLETED = 'completed';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getStatusAllowableValues()
{
return [
self::STATUS_QUEUED,
self::STATUS_IN_PROCESS,
self::STATUS_COMPLETED,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['exportUrl'] = isset($data['exportUrl']) ? $data['exportUrl'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['status'] === null) {
return false;
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id Id of the process
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status Status of the process
*
* @return $this
*/
public function setStatus($status)
{
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($status, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['status'] = $status;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Process name
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets exportUrl
*
* @return string
*/
public function getExportUrl()
{
return $this->container['exportUrl'];
}
/**
* Sets exportUrl
*
* @param string $exportUrl URL on which send export the of contacts once the process is completed
*
* @return $this
*/
public function setExportUrl($exportUrl)
{
$this->container['exportUrl'] = $exportUrl;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,338 @@
<?php
/**
* GetProcesses
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetProcesses Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetProcesses implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getProcesses';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'processes' => '\SendinBlue\Client\Model\GetProcess[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'processes' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'processes' => 'processes',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'processes' => 'setProcesses',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'processes' => 'getProcesses',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['processes'] = isset($data['processes']) ? $data['processes'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets processes
*
* @return \SendinBlue\Client\Model\GetProcess[]
*/
public function getProcesses()
{
return $this->container['processes'];
}
/**
* Sets processes
*
* @param \SendinBlue\Client\Model\GetProcess[] $processes List of processes available on your account
*
* @return $this
*/
public function setProcesses($processes)
{
$this->container['processes'] = $processes;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of processes available on your account
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* GetReports
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetReports Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetReports implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getReports';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'reports' => '\SendinBlue\Client\Model\GetReportsReports[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'reports' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'reports' => 'reports'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'reports' => 'setReports'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'reports' => 'getReports'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['reports'] = isset($data['reports']) ? $data['reports'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets reports
*
* @return \SendinBlue\Client\Model\GetReportsReports[]
*/
public function getReports()
{
return $this->container['reports'];
}
/**
* Sets reports
*
* @param \SendinBlue\Client\Model\GetReportsReports[] $reports reports
*
* @return $this
*/
public function setReports($reports)
{
$this->container['reports'] = $reports;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,740 @@
<?php
/**
* GetReportsReports
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetReportsReports Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetReportsReports implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getReports_reports';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'date' => '\DateTime',
'requests' => 'int',
'delivered' => 'int',
'hardBounces' => 'int',
'softBounces' => 'int',
'clicks' => 'int',
'uniqueClicks' => 'int',
'opens' => 'int',
'uniqueOpens' => 'int',
'spamReports' => 'int',
'blocked' => 'int',
'invalid' => 'int',
'unsubscribed' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'date' => 'date',
'requests' => 'int64',
'delivered' => 'int64',
'hardBounces' => 'int64',
'softBounces' => 'int64',
'clicks' => 'int64',
'uniqueClicks' => 'int64',
'opens' => 'int64',
'uniqueOpens' => 'int64',
'spamReports' => 'int64',
'blocked' => 'int64',
'invalid' => 'int64',
'unsubscribed' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'date' => 'date',
'requests' => 'requests',
'delivered' => 'delivered',
'hardBounces' => 'hardBounces',
'softBounces' => 'softBounces',
'clicks' => 'clicks',
'uniqueClicks' => 'uniqueClicks',
'opens' => 'opens',
'uniqueOpens' => 'uniqueOpens',
'spamReports' => 'spamReports',
'blocked' => 'blocked',
'invalid' => 'invalid',
'unsubscribed' => 'unsubscribed'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'date' => 'setDate',
'requests' => 'setRequests',
'delivered' => 'setDelivered',
'hardBounces' => 'setHardBounces',
'softBounces' => 'setSoftBounces',
'clicks' => 'setClicks',
'uniqueClicks' => 'setUniqueClicks',
'opens' => 'setOpens',
'uniqueOpens' => 'setUniqueOpens',
'spamReports' => 'setSpamReports',
'blocked' => 'setBlocked',
'invalid' => 'setInvalid',
'unsubscribed' => 'setUnsubscribed'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'date' => 'getDate',
'requests' => 'getRequests',
'delivered' => 'getDelivered',
'hardBounces' => 'getHardBounces',
'softBounces' => 'getSoftBounces',
'clicks' => 'getClicks',
'uniqueClicks' => 'getUniqueClicks',
'opens' => 'getOpens',
'uniqueOpens' => 'getUniqueOpens',
'spamReports' => 'getSpamReports',
'blocked' => 'getBlocked',
'invalid' => 'getInvalid',
'unsubscribed' => 'getUnsubscribed'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['date'] = isset($data['date']) ? $data['date'] : null;
$this->container['requests'] = isset($data['requests']) ? $data['requests'] : null;
$this->container['delivered'] = isset($data['delivered']) ? $data['delivered'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['clicks'] = isset($data['clicks']) ? $data['clicks'] : null;
$this->container['uniqueClicks'] = isset($data['uniqueClicks']) ? $data['uniqueClicks'] : null;
$this->container['opens'] = isset($data['opens']) ? $data['opens'] : null;
$this->container['uniqueOpens'] = isset($data['uniqueOpens']) ? $data['uniqueOpens'] : null;
$this->container['spamReports'] = isset($data['spamReports']) ? $data['spamReports'] : null;
$this->container['blocked'] = isset($data['blocked']) ? $data['blocked'] : null;
$this->container['invalid'] = isset($data['invalid']) ? $data['invalid'] : null;
$this->container['unsubscribed'] = isset($data['unsubscribed']) ? $data['unsubscribed'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['date'] === null) {
$invalidProperties[] = "'date' can't be null";
}
if ($this->container['requests'] === null) {
$invalidProperties[] = "'requests' can't be null";
}
if ($this->container['delivered'] === null) {
$invalidProperties[] = "'delivered' can't be null";
}
if ($this->container['hardBounces'] === null) {
$invalidProperties[] = "'hardBounces' can't be null";
}
if ($this->container['softBounces'] === null) {
$invalidProperties[] = "'softBounces' can't be null";
}
if ($this->container['clicks'] === null) {
$invalidProperties[] = "'clicks' can't be null";
}
if ($this->container['uniqueClicks'] === null) {
$invalidProperties[] = "'uniqueClicks' can't be null";
}
if ($this->container['opens'] === null) {
$invalidProperties[] = "'opens' can't be null";
}
if ($this->container['uniqueOpens'] === null) {
$invalidProperties[] = "'uniqueOpens' can't be null";
}
if ($this->container['spamReports'] === null) {
$invalidProperties[] = "'spamReports' can't be null";
}
if ($this->container['blocked'] === null) {
$invalidProperties[] = "'blocked' can't be null";
}
if ($this->container['invalid'] === null) {
$invalidProperties[] = "'invalid' can't be null";
}
if ($this->container['unsubscribed'] === null) {
$invalidProperties[] = "'unsubscribed' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['date'] === null) {
return false;
}
if ($this->container['requests'] === null) {
return false;
}
if ($this->container['delivered'] === null) {
return false;
}
if ($this->container['hardBounces'] === null) {
return false;
}
if ($this->container['softBounces'] === null) {
return false;
}
if ($this->container['clicks'] === null) {
return false;
}
if ($this->container['uniqueClicks'] === null) {
return false;
}
if ($this->container['opens'] === null) {
return false;
}
if ($this->container['uniqueOpens'] === null) {
return false;
}
if ($this->container['spamReports'] === null) {
return false;
}
if ($this->container['blocked'] === null) {
return false;
}
if ($this->container['invalid'] === null) {
return false;
}
if ($this->container['unsubscribed'] === null) {
return false;
}
return true;
}
/**
* Gets date
*
* @return \DateTime
*/
public function getDate()
{
return $this->container['date'];
}
/**
* Sets date
*
* @param \DateTime $date Date of the statistics
*
* @return $this
*/
public function setDate($date)
{
$this->container['date'] = $date;
return $this;
}
/**
* Gets requests
*
* @return int
*/
public function getRequests()
{
return $this->container['requests'];
}
/**
* Sets requests
*
* @param int $requests Number of requests for the date
*
* @return $this
*/
public function setRequests($requests)
{
$this->container['requests'] = $requests;
return $this;
}
/**
* Gets delivered
*
* @return int
*/
public function getDelivered()
{
return $this->container['delivered'];
}
/**
* Sets delivered
*
* @param int $delivered Number of delivered emails for the date
*
* @return $this
*/
public function setDelivered($delivered)
{
$this->container['delivered'] = $delivered;
return $this;
}
/**
* Gets hardBounces
*
* @return int
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param int $hardBounces Number of hardbounces for the date
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets softBounces
*
* @return int
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param int $softBounces Number of softbounces for the date
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets clicks
*
* @return int
*/
public function getClicks()
{
return $this->container['clicks'];
}
/**
* Sets clicks
*
* @param int $clicks Number of clicks for the date
*
* @return $this
*/
public function setClicks($clicks)
{
$this->container['clicks'] = $clicks;
return $this;
}
/**
* Gets uniqueClicks
*
* @return int
*/
public function getUniqueClicks()
{
return $this->container['uniqueClicks'];
}
/**
* Sets uniqueClicks
*
* @param int $uniqueClicks Number of unique clicks for the date
*
* @return $this
*/
public function setUniqueClicks($uniqueClicks)
{
$this->container['uniqueClicks'] = $uniqueClicks;
return $this;
}
/**
* Gets opens
*
* @return int
*/
public function getOpens()
{
return $this->container['opens'];
}
/**
* Sets opens
*
* @param int $opens Number of openings for the date
*
* @return $this
*/
public function setOpens($opens)
{
$this->container['opens'] = $opens;
return $this;
}
/**
* Gets uniqueOpens
*
* @return int
*/
public function getUniqueOpens()
{
return $this->container['uniqueOpens'];
}
/**
* Sets uniqueOpens
*
* @param int $uniqueOpens Number of unique openings for the date
*
* @return $this
*/
public function setUniqueOpens($uniqueOpens)
{
$this->container['uniqueOpens'] = $uniqueOpens;
return $this;
}
/**
* Gets spamReports
*
* @return int
*/
public function getSpamReports()
{
return $this->container['spamReports'];
}
/**
* Sets spamReports
*
* @param int $spamReports Number of complaints (spam reports) for the date
*
* @return $this
*/
public function setSpamReports($spamReports)
{
$this->container['spamReports'] = $spamReports;
return $this;
}
/**
* Gets blocked
*
* @return int
*/
public function getBlocked()
{
return $this->container['blocked'];
}
/**
* Sets blocked
*
* @param int $blocked Number of blocked emails for the date
*
* @return $this
*/
public function setBlocked($blocked)
{
$this->container['blocked'] = $blocked;
return $this;
}
/**
* Gets invalid
*
* @return int
*/
public function getInvalid()
{
return $this->container['invalid'];
}
/**
* Sets invalid
*
* @param int $invalid Number of invalid emails for the date
*
* @return $this
*/
public function setInvalid($invalid)
{
$this->container['invalid'] = $invalid;
return $this;
}
/**
* Gets unsubscribed
*
* @return int
*/
public function getUnsubscribed()
{
return $this->container['unsubscribed'];
}
/**
* Sets unsubscribed
*
* @param int $unsubscribed Number of unsubscribed emails for the date
*
* @return $this
*/
public function setUnsubscribed($unsubscribed)
{
$this->container['unsubscribed'] = $unsubscribed;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* GetSendersList
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSendersList Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSendersList implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSendersList';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'senders' => '\SendinBlue\Client\Model\GetSendersListSenders[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'senders' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'senders' => 'senders'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'senders' => 'setSenders'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'senders' => 'getSenders'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['senders'] = isset($data['senders']) ? $data['senders'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets senders
*
* @return \SendinBlue\Client\Model\GetSendersListSenders[]
*/
public function getSenders()
{
return $this->container['senders'];
}
/**
* Sets senders
*
* @param \SendinBlue\Client\Model\GetSendersListSenders[] $senders List of the senders available in your account
*
* @return $this
*/
public function setSenders($senders)
{
$this->container['senders'] = $senders;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,380 @@
<?php
/**
* GetSendersListIps
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSendersListIps Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSendersListIps implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSendersList_ips';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'ip' => 'string',
'domain' => 'string',
'weight' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'ip' => null,
'domain' => null,
'weight' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'ip' => 'ip',
'domain' => 'domain',
'weight' => 'weight'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'ip' => 'setIp',
'domain' => 'setDomain',
'weight' => 'setWeight'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'ip' => 'getIp',
'domain' => 'getDomain',
'weight' => 'getWeight'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
$this->container['domain'] = isset($data['domain']) ? $data['domain'] : null;
$this->container['weight'] = isset($data['weight']) ? $data['weight'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['ip'] === null) {
$invalidProperties[] = "'ip' can't be null";
}
if ($this->container['domain'] === null) {
$invalidProperties[] = "'domain' can't be null";
}
if ($this->container['weight'] === null) {
$invalidProperties[] = "'weight' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['ip'] === null) {
return false;
}
if ($this->container['domain'] === null) {
return false;
}
if ($this->container['weight'] === null) {
return false;
}
return true;
}
/**
* Gets ip
*
* @return string
*/
public function getIp()
{
return $this->container['ip'];
}
/**
* Sets ip
*
* @param string $ip Dedicated IP available in your account
*
* @return $this
*/
public function setIp($ip)
{
$this->container['ip'] = $ip;
return $this;
}
/**
* Gets domain
*
* @return string
*/
public function getDomain()
{
return $this->container['domain'];
}
/**
* Sets domain
*
* @param string $domain Domain of the IP
*
* @return $this
*/
public function setDomain($domain)
{
$this->container['domain'] = $domain;
return $this;
}
/**
* Gets weight
*
* @return int
*/
public function getWeight()
{
return $this->container['weight'];
}
/**
* Sets weight
*
* @param int $weight Weight of the IP for this sender
*
* @return $this
*/
public function setWeight($weight)
{
$this->container['weight'] = $weight;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,446 @@
<?php
/**
* GetSendersListSenders
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSendersListSenders Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSendersListSenders implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSendersList_senders';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'email' => 'string',
'active' => 'bool',
'ips' => '\SendinBlue\Client\Model\GetSendersListIps[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'email' => null,
'active' => null,
'ips' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'email' => 'email',
'active' => 'active',
'ips' => 'ips'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'email' => 'setEmail',
'active' => 'setActive',
'ips' => 'setIps'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'email' => 'getEmail',
'active' => 'getActive',
'ips' => 'getIps'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['email'] = isset($data['email']) ? $data['email'] : null;
$this->container['active'] = isset($data['active']) ? $data['active'] : null;
$this->container['ips'] = isset($data['ips']) ? $data['ips'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['email'] === null) {
$invalidProperties[] = "'email' can't be null";
}
if ($this->container['active'] === null) {
$invalidProperties[] = "'active' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['email'] === null) {
return false;
}
if ($this->container['active'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id Id of the sender
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name From Name associated to the sender
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets email
*
* @return string
*/
public function getEmail()
{
return $this->container['email'];
}
/**
* Sets email
*
* @param string $email From Email associated to the sender
*
* @return $this
*/
public function setEmail($email)
{
$this->container['email'] = $email;
return $this;
}
/**
* Gets active
*
* @return bool
*/
public function getActive()
{
return $this->container['active'];
}
/**
* Sets active
*
* @param bool $active Status of sender (true=activated, false=deactivated)
*
* @return $this
*/
public function setActive($active)
{
$this->container['active'] = $active;
return $this;
}
/**
* Gets ips
*
* @return \SendinBlue\Client\Model\GetSendersListIps[]
*/
public function getIps()
{
return $this->container['ips'];
}
/**
* Sets ips
*
* @param \SendinBlue\Client\Model\GetSendersListIps[] $ips List of dedicated IP(s) available in the account. This data is displayed only for dedicated IPs
*
* @return $this
*/
public function setIps($ips)
{
$this->container['ips'] = $ips;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,676 @@
<?php
/**
* GetSmsCampaign
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsCampaign Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsCampaign implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsCampaign';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'status' => 'string',
'content' => 'string',
'scheduledAt' => '\DateTime',
'sender' => 'string',
'createdAt' => '\DateTime',
'modifiedAt' => '\DateTime',
'recipients' => 'object',
'statistics' => 'object'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'status' => null,
'content' => null,
'scheduledAt' => 'date-time',
'sender' => null,
'createdAt' => 'date-time',
'modifiedAt' => 'date-time',
'recipients' => null,
'statistics' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'status' => 'status',
'content' => 'content',
'scheduledAt' => 'scheduledAt',
'sender' => 'sender',
'createdAt' => 'createdAt',
'modifiedAt' => 'modifiedAt',
'recipients' => 'recipients',
'statistics' => 'statistics'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'status' => 'setStatus',
'content' => 'setContent',
'scheduledAt' => 'setScheduledAt',
'sender' => 'setSender',
'createdAt' => 'setCreatedAt',
'modifiedAt' => 'setModifiedAt',
'recipients' => 'setRecipients',
'statistics' => 'setStatistics'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'status' => 'getStatus',
'content' => 'getContent',
'scheduledAt' => 'getScheduledAt',
'sender' => 'getSender',
'createdAt' => 'getCreatedAt',
'modifiedAt' => 'getModifiedAt',
'recipients' => 'getRecipients',
'statistics' => 'getStatistics'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const STATUS_DRAFT = 'draft';
const STATUS_SENT = 'sent';
const STATUS_ARCHIVE = 'archive';
const STATUS_QUEUED = 'queued';
const STATUS_SUSPENDED = 'suspended';
const STATUS_IN_PROCESS = 'inProcess';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getStatusAllowableValues()
{
return [
self::STATUS_DRAFT,
self::STATUS_SENT,
self::STATUS_ARCHIVE,
self::STATUS_QUEUED,
self::STATUS_SUSPENDED,
self::STATUS_IN_PROCESS,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
$this->container['content'] = isset($data['content']) ? $data['content'] : null;
$this->container['scheduledAt'] = isset($data['scheduledAt']) ? $data['scheduledAt'] : null;
$this->container['sender'] = isset($data['sender']) ? $data['sender'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['modifiedAt'] = isset($data['modifiedAt']) ? $data['modifiedAt'] : null;
$this->container['recipients'] = isset($data['recipients']) ? $data['recipients'] : null;
$this->container['statistics'] = isset($data['statistics']) ? $data['statistics'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['content'] === null) {
$invalidProperties[] = "'content' can't be null";
}
if ($this->container['scheduledAt'] === null) {
$invalidProperties[] = "'scheduledAt' can't be null";
}
if ($this->container['sender'] === null) {
$invalidProperties[] = "'sender' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
if ($this->container['modifiedAt'] === null) {
$invalidProperties[] = "'modifiedAt' can't be null";
}
if ($this->container['recipients'] === null) {
$invalidProperties[] = "'recipients' can't be null";
}
if ($this->container['statistics'] === null) {
$invalidProperties[] = "'statistics' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['status'] === null) {
return false;
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
return false;
}
if ($this->container['content'] === null) {
return false;
}
if ($this->container['scheduledAt'] === null) {
return false;
}
if ($this->container['sender'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
if ($this->container['modifiedAt'] === null) {
return false;
}
if ($this->container['recipients'] === null) {
return false;
}
if ($this->container['statistics'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the SMS Campaign
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the SMS Campaign
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status Status of the SMS Campaign
*
* @return $this
*/
public function setStatus($status)
{
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($status, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['status'] = $status;
return $this;
}
/**
* Gets content
*
* @return string
*/
public function getContent()
{
return $this->container['content'];
}
/**
* Sets content
*
* @param string $content Content of the SMS Campaign
*
* @return $this
*/
public function setContent($content)
{
$this->container['content'] = $content;
return $this;
}
/**
* Gets scheduledAt
*
* @return \DateTime
*/
public function getScheduledAt()
{
return $this->container['scheduledAt'];
}
/**
* Sets scheduledAt
*
* @param \DateTime $scheduledAt UTC date-time on which SMS campaign is scheduled. Should be in YYYY-MM-DDTHH:mm:ss.SSSZ format
*
* @return $this
*/
public function setScheduledAt($scheduledAt)
{
$this->container['scheduledAt'] = $scheduledAt;
return $this;
}
/**
* Gets sender
*
* @return string
*/
public function getSender()
{
return $this->container['sender'];
}
/**
* Sets sender
*
* @param string $sender Sender of the SMS Campaign
*
* @return $this
*/
public function setSender($sender)
{
$this->container['sender'] = $sender;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets modifiedAt
*
* @return \DateTime
*/
public function getModifiedAt()
{
return $this->container['modifiedAt'];
}
/**
* Sets modifiedAt
*
* @param \DateTime $modifiedAt UTC date-time of last modification of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setModifiedAt($modifiedAt)
{
$this->container['modifiedAt'] = $modifiedAt;
return $this;
}
/**
* Gets recipients
*
* @return object
*/
public function getRecipients()
{
return $this->container['recipients'];
}
/**
* Sets recipients
*
* @param object $recipients recipients
*
* @return $this
*/
public function setRecipients($recipients)
{
$this->container['recipients'] = $recipients;
return $this;
}
/**
* Gets statistics
*
* @return object
*/
public function getStatistics()
{
return $this->container['statistics'];
}
/**
* Sets statistics
*
* @param object $statistics statistics
*
* @return $this
*/
public function setStatistics($statistics)
{
$this->container['statistics'] = $statistics;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,604 @@
<?php
/**
* GetSmsCampaignOverview
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsCampaignOverview Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsCampaignOverview implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsCampaignOverview';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'status' => 'string',
'content' => 'string',
'scheduledAt' => '\DateTime',
'sender' => 'string',
'createdAt' => '\DateTime',
'modifiedAt' => '\DateTime'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'status' => null,
'content' => null,
'scheduledAt' => 'date-time',
'sender' => null,
'createdAt' => 'date-time',
'modifiedAt' => 'date-time'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'status' => 'status',
'content' => 'content',
'scheduledAt' => 'scheduledAt',
'sender' => 'sender',
'createdAt' => 'createdAt',
'modifiedAt' => 'modifiedAt'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'status' => 'setStatus',
'content' => 'setContent',
'scheduledAt' => 'setScheduledAt',
'sender' => 'setSender',
'createdAt' => 'setCreatedAt',
'modifiedAt' => 'setModifiedAt'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'status' => 'getStatus',
'content' => 'getContent',
'scheduledAt' => 'getScheduledAt',
'sender' => 'getSender',
'createdAt' => 'getCreatedAt',
'modifiedAt' => 'getModifiedAt'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const STATUS_DRAFT = 'draft';
const STATUS_SENT = 'sent';
const STATUS_ARCHIVE = 'archive';
const STATUS_QUEUED = 'queued';
const STATUS_SUSPENDED = 'suspended';
const STATUS_IN_PROCESS = 'inProcess';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getStatusAllowableValues()
{
return [
self::STATUS_DRAFT,
self::STATUS_SENT,
self::STATUS_ARCHIVE,
self::STATUS_QUEUED,
self::STATUS_SUSPENDED,
self::STATUS_IN_PROCESS,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
$this->container['content'] = isset($data['content']) ? $data['content'] : null;
$this->container['scheduledAt'] = isset($data['scheduledAt']) ? $data['scheduledAt'] : null;
$this->container['sender'] = isset($data['sender']) ? $data['sender'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['modifiedAt'] = isset($data['modifiedAt']) ? $data['modifiedAt'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
);
}
if ($this->container['content'] === null) {
$invalidProperties[] = "'content' can't be null";
}
if ($this->container['scheduledAt'] === null) {
$invalidProperties[] = "'scheduledAt' can't be null";
}
if ($this->container['sender'] === null) {
$invalidProperties[] = "'sender' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
if ($this->container['modifiedAt'] === null) {
$invalidProperties[] = "'modifiedAt' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['status'] === null) {
return false;
}
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($this->container['status'], $allowedValues)) {
return false;
}
if ($this->container['content'] === null) {
return false;
}
if ($this->container['scheduledAt'] === null) {
return false;
}
if ($this->container['sender'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
if ($this->container['modifiedAt'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the SMS Campaign
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the SMS Campaign
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status Status of the SMS Campaign
*
* @return $this
*/
public function setStatus($status)
{
$allowedValues = $this->getStatusAllowableValues();
if (!in_array($status, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'status', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['status'] = $status;
return $this;
}
/**
* Gets content
*
* @return string
*/
public function getContent()
{
return $this->container['content'];
}
/**
* Sets content
*
* @param string $content Content of the SMS Campaign
*
* @return $this
*/
public function setContent($content)
{
$this->container['content'] = $content;
return $this;
}
/**
* Gets scheduledAt
*
* @return \DateTime
*/
public function getScheduledAt()
{
return $this->container['scheduledAt'];
}
/**
* Sets scheduledAt
*
* @param \DateTime $scheduledAt UTC date-time on which SMS campaign is scheduled. Should be in YYYY-MM-DDTHH:mm:ss.SSSZ format
*
* @return $this
*/
public function setScheduledAt($scheduledAt)
{
$this->container['scheduledAt'] = $scheduledAt;
return $this;
}
/**
* Gets sender
*
* @return string
*/
public function getSender()
{
return $this->container['sender'];
}
/**
* Sets sender
*
* @param string $sender Sender of the SMS Campaign
*
* @return $this
*/
public function setSender($sender)
{
$this->container['sender'] = $sender;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets modifiedAt
*
* @return \DateTime
*/
public function getModifiedAt()
{
return $this->container['modifiedAt'];
}
/**
* Sets modifiedAt
*
* @param \DateTime $modifiedAt UTC date-time of last modification of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setModifiedAt($modifiedAt)
{
$this->container['modifiedAt'] = $modifiedAt;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,524 @@
<?php
/**
* GetSmsCampaignStats
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsCampaignStats Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsCampaignStats implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsCampaignStats';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'delivered' => 'int',
'sent' => 'int',
'processing' => 'int',
'softBounces' => 'int',
'hardBounces' => 'int',
'unsubscriptions' => 'int',
'answered' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'delivered' => 'int64',
'sent' => 'int64',
'processing' => 'int64',
'softBounces' => 'int64',
'hardBounces' => 'int64',
'unsubscriptions' => 'int64',
'answered' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'delivered' => 'delivered',
'sent' => 'sent',
'processing' => 'processing',
'softBounces' => 'softBounces',
'hardBounces' => 'hardBounces',
'unsubscriptions' => 'unsubscriptions',
'answered' => 'answered'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'delivered' => 'setDelivered',
'sent' => 'setSent',
'processing' => 'setProcessing',
'softBounces' => 'setSoftBounces',
'hardBounces' => 'setHardBounces',
'unsubscriptions' => 'setUnsubscriptions',
'answered' => 'setAnswered'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'delivered' => 'getDelivered',
'sent' => 'getSent',
'processing' => 'getProcessing',
'softBounces' => 'getSoftBounces',
'hardBounces' => 'getHardBounces',
'unsubscriptions' => 'getUnsubscriptions',
'answered' => 'getAnswered'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['delivered'] = isset($data['delivered']) ? $data['delivered'] : null;
$this->container['sent'] = isset($data['sent']) ? $data['sent'] : null;
$this->container['processing'] = isset($data['processing']) ? $data['processing'] : null;
$this->container['softBounces'] = isset($data['softBounces']) ? $data['softBounces'] : null;
$this->container['hardBounces'] = isset($data['hardBounces']) ? $data['hardBounces'] : null;
$this->container['unsubscriptions'] = isset($data['unsubscriptions']) ? $data['unsubscriptions'] : null;
$this->container['answered'] = isset($data['answered']) ? $data['answered'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['delivered'] === null) {
$invalidProperties[] = "'delivered' can't be null";
}
if ($this->container['sent'] === null) {
$invalidProperties[] = "'sent' can't be null";
}
if ($this->container['processing'] === null) {
$invalidProperties[] = "'processing' can't be null";
}
if ($this->container['softBounces'] === null) {
$invalidProperties[] = "'softBounces' can't be null";
}
if ($this->container['hardBounces'] === null) {
$invalidProperties[] = "'hardBounces' can't be null";
}
if ($this->container['unsubscriptions'] === null) {
$invalidProperties[] = "'unsubscriptions' can't be null";
}
if ($this->container['answered'] === null) {
$invalidProperties[] = "'answered' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['delivered'] === null) {
return false;
}
if ($this->container['sent'] === null) {
return false;
}
if ($this->container['processing'] === null) {
return false;
}
if ($this->container['softBounces'] === null) {
return false;
}
if ($this->container['hardBounces'] === null) {
return false;
}
if ($this->container['unsubscriptions'] === null) {
return false;
}
if ($this->container['answered'] === null) {
return false;
}
return true;
}
/**
* Gets delivered
*
* @return int
*/
public function getDelivered()
{
return $this->container['delivered'];
}
/**
* Sets delivered
*
* @param int $delivered Number of delivered SMS
*
* @return $this
*/
public function setDelivered($delivered)
{
$this->container['delivered'] = $delivered;
return $this;
}
/**
* Gets sent
*
* @return int
*/
public function getSent()
{
return $this->container['sent'];
}
/**
* Sets sent
*
* @param int $sent Number of sent SMS
*
* @return $this
*/
public function setSent($sent)
{
$this->container['sent'] = $sent;
return $this;
}
/**
* Gets processing
*
* @return int
*/
public function getProcessing()
{
return $this->container['processing'];
}
/**
* Sets processing
*
* @param int $processing Number of processing SMS
*
* @return $this
*/
public function setProcessing($processing)
{
$this->container['processing'] = $processing;
return $this;
}
/**
* Gets softBounces
*
* @return int
*/
public function getSoftBounces()
{
return $this->container['softBounces'];
}
/**
* Sets softBounces
*
* @param int $softBounces Number of softbounced SMS
*
* @return $this
*/
public function setSoftBounces($softBounces)
{
$this->container['softBounces'] = $softBounces;
return $this;
}
/**
* Gets hardBounces
*
* @return int
*/
public function getHardBounces()
{
return $this->container['hardBounces'];
}
/**
* Sets hardBounces
*
* @param int $hardBounces Number of hardbounced SMS
*
* @return $this
*/
public function setHardBounces($hardBounces)
{
$this->container['hardBounces'] = $hardBounces;
return $this;
}
/**
* Gets unsubscriptions
*
* @return int
*/
public function getUnsubscriptions()
{
return $this->container['unsubscriptions'];
}
/**
* Sets unsubscriptions
*
* @param int $unsubscriptions Number of unsubscription SMS
*
* @return $this
*/
public function setUnsubscriptions($unsubscriptions)
{
$this->container['unsubscriptions'] = $unsubscriptions;
return $this;
}
/**
* Gets answered
*
* @return int
*/
public function getAnswered()
{
return $this->container['answered'];
}
/**
* Sets answered
*
* @param int $answered Number of replies to the SMS
*
* @return $this
*/
public function setAnswered($answered)
{
$this->container['answered'] = $answered;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,338 @@
<?php
/**
* GetSmsCampaigns
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsCampaigns Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsCampaigns implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsCampaigns';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'campaigns' => 'object[]',
'count' => 'int'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'campaigns' => null,
'count' => 'int64'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'campaigns' => 'campaigns',
'count' => 'count'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'campaigns' => 'setCampaigns',
'count' => 'setCount'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'campaigns' => 'getCampaigns',
'count' => 'getCount'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['campaigns'] = isset($data['campaigns']) ? $data['campaigns'] : null;
$this->container['count'] = isset($data['count']) ? $data['count'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['count'] === null) {
$invalidProperties[] = "'count' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['count'] === null) {
return false;
}
return true;
}
/**
* Gets campaigns
*
* @return object[]
*/
public function getCampaigns()
{
return $this->container['campaigns'];
}
/**
* Sets campaigns
*
* @param object[] $campaigns campaigns
*
* @return $this
*/
public function setCampaigns($campaigns)
{
$this->container['campaigns'] = $campaigns;
return $this;
}
/**
* Gets count
*
* @return int
*/
public function getCount()
{
return $this->container['count'];
}
/**
* Sets count
*
* @param int $count Number of SMS campaigns retrieved
*
* @return $this
*/
public function setCount($count)
{
$this->container['count'] = $count;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,302 @@
<?php
/**
* GetSmsEventReport
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsEventReport Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsEventReport implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsEventReport';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'events' => '\SendinBlue\Client\Model\GetSmsEventReportEvents[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'events' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'events' => 'events'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'events' => 'setEvents'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'events' => 'getEvents'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['events'] = isset($data['events']) ? $data['events'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return true;
}
/**
* Gets events
*
* @return \SendinBlue\Client\Model\GetSmsEventReportEvents[]
*/
public function getEvents()
{
return $this->container['events'];
}
/**
* Sets events
*
* @param \SendinBlue\Client\Model\GetSmsEventReportEvents[] $events events
*
* @return $this
*/
public function setEvents($events)
{
$this->container['events'] = $events;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,556 @@
<?php
/**
* GetSmsEventReportEvents
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmsEventReportEvents Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmsEventReportEvents implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmsEventReport_events';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'phoneNumber' => 'string',
'date' => '\DateTime',
'messageId' => 'string',
'event' => 'string',
'reason' => 'string',
'reply' => 'string',
'tag' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'phoneNumber' => null,
'date' => 'date-time',
'messageId' => null,
'event' => null,
'reason' => null,
'reply' => null,
'tag' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'phoneNumber' => 'phoneNumber',
'date' => 'date',
'messageId' => 'messageId',
'event' => 'event',
'reason' => 'reason',
'reply' => 'reply',
'tag' => 'tag'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'phoneNumber' => 'setPhoneNumber',
'date' => 'setDate',
'messageId' => 'setMessageId',
'event' => 'setEvent',
'reason' => 'setReason',
'reply' => 'setReply',
'tag' => 'setTag'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'phoneNumber' => 'getPhoneNumber',
'date' => 'getDate',
'messageId' => 'getMessageId',
'event' => 'getEvent',
'reason' => 'getReason',
'reply' => 'getReply',
'tag' => 'getTag'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
const EVENT_BOUNCES = 'bounces';
const EVENT_HARD_BOUNCES = 'hardBounces';
const EVENT_SOFT_BOUNCES = 'softBounces';
const EVENT_DELIVERED = 'delivered';
const EVENT_SENT = 'sent';
const EVENT_ACCEPTED = 'accepted';
const EVENT_UNSUBSCRIPTION = 'unsubscription';
const EVENT_REPLIES = 'replies';
const EVENT_BLOCKED = 'blocked';
/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getEventAllowableValues()
{
return [
self::EVENT_BOUNCES,
self::EVENT_HARD_BOUNCES,
self::EVENT_SOFT_BOUNCES,
self::EVENT_DELIVERED,
self::EVENT_SENT,
self::EVENT_ACCEPTED,
self::EVENT_UNSUBSCRIPTION,
self::EVENT_REPLIES,
self::EVENT_BLOCKED,
];
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['phoneNumber'] = isset($data['phoneNumber']) ? $data['phoneNumber'] : null;
$this->container['date'] = isset($data['date']) ? $data['date'] : null;
$this->container['messageId'] = isset($data['messageId']) ? $data['messageId'] : null;
$this->container['event'] = isset($data['event']) ? $data['event'] : null;
$this->container['reason'] = isset($data['reason']) ? $data['reason'] : null;
$this->container['reply'] = isset($data['reply']) ? $data['reply'] : null;
$this->container['tag'] = isset($data['tag']) ? $data['tag'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['phoneNumber'] === null) {
$invalidProperties[] = "'phoneNumber' can't be null";
}
if ($this->container['date'] === null) {
$invalidProperties[] = "'date' can't be null";
}
if ($this->container['messageId'] === null) {
$invalidProperties[] = "'messageId' can't be null";
}
if ($this->container['event'] === null) {
$invalidProperties[] = "'event' can't be null";
}
$allowedValues = $this->getEventAllowableValues();
if (!in_array($this->container['event'], $allowedValues)) {
$invalidProperties[] = sprintf(
"invalid value for 'event', must be one of '%s'",
implode("', '", $allowedValues)
);
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['phoneNumber'] === null) {
return false;
}
if ($this->container['date'] === null) {
return false;
}
if ($this->container['messageId'] === null) {
return false;
}
if ($this->container['event'] === null) {
return false;
}
$allowedValues = $this->getEventAllowableValues();
if (!in_array($this->container['event'], $allowedValues)) {
return false;
}
return true;
}
/**
* Gets phoneNumber
*
* @return string
*/
public function getPhoneNumber()
{
return $this->container['phoneNumber'];
}
/**
* Sets phoneNumber
*
* @param string $phoneNumber Phone number which has generated the event
*
* @return $this
*/
public function setPhoneNumber($phoneNumber)
{
$this->container['phoneNumber'] = $phoneNumber;
return $this;
}
/**
* Gets date
*
* @return \DateTime
*/
public function getDate()
{
return $this->container['date'];
}
/**
* Sets date
*
* @param \DateTime $date UTC date-time on which the event has been generated
*
* @return $this
*/
public function setDate($date)
{
$this->container['date'] = $date;
return $this;
}
/**
* Gets messageId
*
* @return string
*/
public function getMessageId()
{
return $this->container['messageId'];
}
/**
* Sets messageId
*
* @param string $messageId Message ID which generated the event
*
* @return $this
*/
public function setMessageId($messageId)
{
$this->container['messageId'] = $messageId;
return $this;
}
/**
* Gets event
*
* @return string
*/
public function getEvent()
{
return $this->container['event'];
}
/**
* Sets event
*
* @param string $event Event which occurred
*
* @return $this
*/
public function setEvent($event)
{
$allowedValues = $this->getEventAllowableValues();
if (!in_array($event, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'event', must be one of '%s'",
implode("', '", $allowedValues)
)
);
}
$this->container['event'] = $event;
return $this;
}
/**
* Gets reason
*
* @return string
*/
public function getReason()
{
return $this->container['reason'];
}
/**
* Sets reason
*
* @param string $reason Reason of bounce (only available if the event is hardbounce or softbounce)
*
* @return $this
*/
public function setReason($reason)
{
$this->container['reason'] = $reason;
return $this;
}
/**
* Gets reply
*
* @return string
*/
public function getReply()
{
return $this->container['reply'];
}
/**
* Sets reply
*
* @param string $reply reply
*
* @return $this
*/
public function setReply($reply)
{
$this->container['reply'] = $reply;
return $this;
}
/**
* Gets tag
*
* @return string
*/
public function getTag()
{
return $this->container['tag'];
}
/**
* Sets tag
*
* @param string $tag Tag of the SMS which generated the event
*
* @return $this
*/
public function setTag($tag)
{
$this->container['tag'] = $tag;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@ -0,0 +1,704 @@
<?php
/**
* GetSmtpTemplateOverview
*
* PHP version 5
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* SendinBlue API
*
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed |
*
* OpenAPI spec version: 3.0.0
* Contact: contact@sendinblue.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 2.3.1
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace SendinBlue\Client\Model;
use \ArrayAccess;
use \SendinBlue\Client\ObjectSerializer;
/**
* GetSmtpTemplateOverview Class Doc Comment
*
* @category Class
* @package SendinBlue\Client
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetSmtpTemplateOverview implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'getSmtpTemplateOverview';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'id' => 'int',
'name' => 'string',
'subject' => 'string',
'isActive' => 'bool',
'testSent' => 'bool',
'sender' => '\SendinBlue\Client\Model\GetSmtpTemplateOverviewSender',
'replyTo' => 'string',
'toField' => 'string',
'tag' => 'string',
'htmlContent' => 'string',
'createdAt' => '\DateTime',
'modifiedAt' => '\DateTime'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'id' => 'int64',
'name' => null,
'subject' => null,
'isActive' => null,
'testSent' => null,
'sender' => null,
'replyTo' => 'email',
'toField' => null,
'tag' => null,
'htmlContent' => null,
'createdAt' => 'date-time',
'modifiedAt' => 'date-time'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'id' => 'id',
'name' => 'name',
'subject' => 'subject',
'isActive' => 'isActive',
'testSent' => 'testSent',
'sender' => 'sender',
'replyTo' => 'replyTo',
'toField' => 'toField',
'tag' => 'tag',
'htmlContent' => 'htmlContent',
'createdAt' => 'createdAt',
'modifiedAt' => 'modifiedAt'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'id' => 'setId',
'name' => 'setName',
'subject' => 'setSubject',
'isActive' => 'setIsActive',
'testSent' => 'setTestSent',
'sender' => 'setSender',
'replyTo' => 'setReplyTo',
'toField' => 'setToField',
'tag' => 'setTag',
'htmlContent' => 'setHtmlContent',
'createdAt' => 'setCreatedAt',
'modifiedAt' => 'setModifiedAt'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'id' => 'getId',
'name' => 'getName',
'subject' => 'getSubject',
'isActive' => 'getIsActive',
'testSent' => 'getTestSent',
'sender' => 'getSender',
'replyTo' => 'getReplyTo',
'toField' => 'getToField',
'tag' => 'getTag',
'htmlContent' => 'getHtmlContent',
'createdAt' => 'getCreatedAt',
'modifiedAt' => 'getModifiedAt'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['id'] = isset($data['id']) ? $data['id'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['subject'] = isset($data['subject']) ? $data['subject'] : null;
$this->container['isActive'] = isset($data['isActive']) ? $data['isActive'] : null;
$this->container['testSent'] = isset($data['testSent']) ? $data['testSent'] : null;
$this->container['sender'] = isset($data['sender']) ? $data['sender'] : null;
$this->container['replyTo'] = isset($data['replyTo']) ? $data['replyTo'] : null;
$this->container['toField'] = isset($data['toField']) ? $data['toField'] : null;
$this->container['tag'] = isset($data['tag']) ? $data['tag'] : null;
$this->container['htmlContent'] = isset($data['htmlContent']) ? $data['htmlContent'] : null;
$this->container['createdAt'] = isset($data['createdAt']) ? $data['createdAt'] : null;
$this->container['modifiedAt'] = isset($data['modifiedAt']) ? $data['modifiedAt'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['id'] === null) {
$invalidProperties[] = "'id' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
}
if ($this->container['subject'] === null) {
$invalidProperties[] = "'subject' can't be null";
}
if ($this->container['isActive'] === null) {
$invalidProperties[] = "'isActive' can't be null";
}
if ($this->container['testSent'] === null) {
$invalidProperties[] = "'testSent' can't be null";
}
if ($this->container['sender'] === null) {
$invalidProperties[] = "'sender' can't be null";
}
if ($this->container['replyTo'] === null) {
$invalidProperties[] = "'replyTo' can't be null";
}
if ($this->container['toField'] === null) {
$invalidProperties[] = "'toField' can't be null";
}
if ($this->container['tag'] === null) {
$invalidProperties[] = "'tag' can't be null";
}
if ($this->container['htmlContent'] === null) {
$invalidProperties[] = "'htmlContent' can't be null";
}
if ($this->container['createdAt'] === null) {
$invalidProperties[] = "'createdAt' can't be null";
}
if ($this->container['modifiedAt'] === null) {
$invalidProperties[] = "'modifiedAt' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
if ($this->container['id'] === null) {
return false;
}
if ($this->container['name'] === null) {
return false;
}
if ($this->container['subject'] === null) {
return false;
}
if ($this->container['isActive'] === null) {
return false;
}
if ($this->container['testSent'] === null) {
return false;
}
if ($this->container['sender'] === null) {
return false;
}
if ($this->container['replyTo'] === null) {
return false;
}
if ($this->container['toField'] === null) {
return false;
}
if ($this->container['tag'] === null) {
return false;
}
if ($this->container['htmlContent'] === null) {
return false;
}
if ($this->container['createdAt'] === null) {
return false;
}
if ($this->container['modifiedAt'] === null) {
return false;
}
return true;
}
/**
* Gets id
*
* @return int
*/
public function getId()
{
return $this->container['id'];
}
/**
* Sets id
*
* @param int $id ID of the template
*
* @return $this
*/
public function setId($id)
{
$this->container['id'] = $id;
return $this;
}
/**
* Gets name
*
* @return string
*/
public function getName()
{
return $this->container['name'];
}
/**
* Sets name
*
* @param string $name Name of the template
*
* @return $this
*/
public function setName($name)
{
$this->container['name'] = $name;
return $this;
}
/**
* Gets subject
*
* @return string
*/
public function getSubject()
{
return $this->container['subject'];
}
/**
* Sets subject
*
* @param string $subject Subject of the template
*
* @return $this
*/
public function setSubject($subject)
{
$this->container['subject'] = $subject;
return $this;
}
/**
* Gets isActive
*
* @return bool
*/
public function getIsActive()
{
return $this->container['isActive'];
}
/**
* Sets isActive
*
* @param bool $isActive Status of template (true=active, false=inactive)
*
* @return $this
*/
public function setIsActive($isActive)
{
$this->container['isActive'] = $isActive;
return $this;
}
/**
* Gets testSent
*
* @return bool
*/
public function getTestSent()
{
return $this->container['testSent'];
}
/**
* Sets testSent
*
* @param bool $testSent Status of test sending for the template (true=test email has been sent, false=test email has not been sent)
*
* @return $this
*/
public function setTestSent($testSent)
{
$this->container['testSent'] = $testSent;
return $this;
}
/**
* Gets sender
*
* @return \SendinBlue\Client\Model\GetSmtpTemplateOverviewSender
*/
public function getSender()
{
return $this->container['sender'];
}
/**
* Sets sender
*
* @param \SendinBlue\Client\Model\GetSmtpTemplateOverviewSender $sender sender
*
* @return $this
*/
public function setSender($sender)
{
$this->container['sender'] = $sender;
return $this;
}
/**
* Gets replyTo
*
* @return string
*/
public function getReplyTo()
{
return $this->container['replyTo'];
}
/**
* Sets replyTo
*
* @param string $replyTo Email defined as the \"Reply to\" for the template
*
* @return $this
*/
public function setReplyTo($replyTo)
{
$this->container['replyTo'] = $replyTo;
return $this;
}
/**
* Gets toField
*
* @return string
*/
public function getToField()
{
return $this->container['toField'];
}
/**
* Sets toField
*
* @param string $toField Customisation of the \"to\" field for the template
*
* @return $this
*/
public function setToField($toField)
{
$this->container['toField'] = $toField;
return $this;
}
/**
* Gets tag
*
* @return string
*/
public function getTag()
{
return $this->container['tag'];
}
/**
* Sets tag
*
* @param string $tag Tag of the template
*
* @return $this
*/
public function setTag($tag)
{
$this->container['tag'] = $tag;
return $this;
}
/**
* Gets htmlContent
*
* @return string
*/
public function getHtmlContent()
{
return $this->container['htmlContent'];
}
/**
* Sets htmlContent
*
* @param string $htmlContent HTML content of the template
*
* @return $this
*/
public function setHtmlContent($htmlContent)
{
$this->container['htmlContent'] = $htmlContent;
return $this;
}
/**
* Gets createdAt
*
* @return \DateTime
*/
public function getCreatedAt()
{
return $this->container['createdAt'];
}
/**
* Sets createdAt
*
* @param \DateTime $createdAt Creation UTC date-time of the template (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setCreatedAt($createdAt)
{
$this->container['createdAt'] = $createdAt;
return $this;
}
/**
* Gets modifiedAt
*
* @return \DateTime
*/
public function getModifiedAt()
{
return $this->container['modifiedAt'];
}
/**
* Sets modifiedAt
*
* @param \DateTime $modifiedAt Last modification UTC date-time of the template (YYYY-MM-DDTHH:mm:ss.SSSZ)
*
* @return $this
*/
public function setModifiedAt($modifiedAt)
{
$this->container['modifiedAt'] = $modifiedAt;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

Some files were not shown because too many files have changed in this diff Show More