diff --git a/README.md b/README.md
index 4669350..07bec49 100644
--- a/README.md
+++ b/README.md
@@ -55,165 +55,197 @@ All URIs are relative to *https://api.sendinblue.com/v3*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*AccountApi* | [**GetAccount**](docs/AccountApi.md#Getaccount) | **Get** /account | Get your account information, plan and credits details
-*AttributesApi* | [**CreateAttribute**](docs/AttributesApi.md#createattribute) | **Post** /contacts/attributes/{attributeCategory}/{attributeName} | Create contact attribute
-*AttributesApi* | [**DeleteAttribute**](docs/AttributesApi.md#deleteattribute) | **Delete** /contacts/attributes/{attributeCategory}/{attributeName} | Delete an attribute
-*AttributesApi* | [**GetAttributes**](docs/AttributesApi.md#getattributes) | **Get** /contacts/attributes | List all attributes
-*AttributesApi* | [**UpdateAttribute**](docs/AttributesApi.md#updateattribute) | **Put** /contacts/attributes/{attributeCategory}/{attributeName} | Update contact attribute
-*CRMApi* | [**CrmNotesGet**](docs/CRMApi.md#crmnotesget) | **Get** /crm/notes | Get all notes
-*CRMApi* | [**CrmNotesIdDelete**](docs/CRMApi.md#crmnotesiddelete) | **Delete** /crm/notes/{id} | Delete a note
-*CRMApi* | [**CrmNotesIdGet**](docs/CRMApi.md#crmnotesidget) | **Get** /crm/notes/{id} | Get a note
-*CRMApi* | [**CrmNotesIdPatch**](docs/CRMApi.md#crmnotesidpatch) | **Patch** /crm/notes/{id} | Update a note
-*CRMApi* | [**CrmNotesPost**](docs/CRMApi.md#crmnotespost) | **Post** /crm/notes | Create a note
-*CRMApi* | [**CrmTasksGet**](docs/CRMApi.md#crmtasksget) | **Get** /crm/tasks | Get all tasks
-*CRMApi* | [**CrmTasksIdDelete**](docs/CRMApi.md#crmtasksiddelete) | **Delete** /crm/tasks/{id} | Delete a task
-*CRMApi* | [**CrmTasksIdGet**](docs/CRMApi.md#crmtasksidget) | **Get** /crm/tasks/{id} | Get a task
-*CRMApi* | [**CrmTasksIdPatch**](docs/CRMApi.md#crmtasksidpatch) | **Patch** /crm/tasks/{id} | Update a task
-*CRMApi* | [**CrmTasksPost**](docs/CRMApi.md#crmtaskspost) | **Post** /crm/tasks | Create a task
-*CRMApi* | [**CrmTasktypesGet**](docs/CRMApi.md#crmtasktypesget) | **Get** /crm/tasktypes | Get all task types
-*CompaniesApi* | [**CompaniesAttributesGet**](docs/CompaniesApi.md#companiesattributesget) | **Get** /companies/attributes | Get company attributes
-*CompaniesApi* | [**CompaniesGet**](docs/CompaniesApi.md#companiesget) | **Get** /companies | Get all companies
-*CompaniesApi* | [**CompaniesIdDelete**](docs/CompaniesApi.md#companiesiddelete) | **Delete** /companies/{id} | Delete a company
-*CompaniesApi* | [**CompaniesIdGet**](docs/CompaniesApi.md#companiesidget) | **Get** /companies/{id} | Get a company
-*CompaniesApi* | [**CompaniesIdPatch**](docs/CompaniesApi.md#companiesidpatch) | **Patch** /companies/{id} | Update a company
-*CompaniesApi* | [**CompaniesLinkUnlinkIdPatch**](docs/CompaniesApi.md#companieslinkunlinkidpatch) | **Patch** /companies/link-unlink/{id} | Link and Unlink company with contacts and deals
-*CompaniesApi* | [**CompaniesPost**](docs/CompaniesApi.md#companiespost) | **Post** /companies | Create a company
-*ContactsApi* | [**AddContactToList**](docs/ContactsApi.md#addcontacttolist) | **Post** /contacts/lists/{listId}/contacts/add | Add existing contacts to a list
-*ContactsApi* | [**CreateAttribute**](docs/ContactsApi.md#createattribute) | **Post** /contacts/attributes/{attributeCategory}/{attributeName} | Create contact attribute
-*ContactsApi* | [**CreateContact**](docs/ContactsApi.md#createcontact) | **Post** /contacts | Create a contact
-*ContactsApi* | [**CreateDoiContact**](docs/ContactsApi.md#createdoicontact) | **Post** /contacts/doubleOptinConfirmation | Create Contact via DOI (Double-Opt-In) Flow
-*ContactsApi* | [**CreateFolder**](docs/ContactsApi.md#createfolder) | **Post** /contacts/folders | Create a folder
-*ContactsApi* | [**CreateList**](docs/ContactsApi.md#createlist) | **Post** /contacts/lists | Create a list
-*ContactsApi* | [**DeleteAttribute**](docs/ContactsApi.md#deleteattribute) | **Delete** /contacts/attributes/{attributeCategory}/{attributeName} | Delete an attribute
-*ContactsApi* | [**DeleteContact**](docs/ContactsApi.md#deletecontact) | **Delete** /contacts/{identifier} | Delete a contact
-*ContactsApi* | [**DeleteFolder**](docs/ContactsApi.md#deletefolder) | **Delete** /contacts/folders/{folderId} | Delete a folder (and all its lists)
-*ContactsApi* | [**DeleteList**](docs/ContactsApi.md#deletelist) | **Delete** /contacts/lists/{listId} | Delete a list
-*ContactsApi* | [**GetAttributes**](docs/ContactsApi.md#getattributes) | **Get** /contacts/attributes | List all attributes
-*ContactsApi* | [**GetContactInfo**](docs/ContactsApi.md#getcontactinfo) | **Get** /contacts/{identifier} | Get a contact's details
-*ContactsApi* | [**GetContactStats**](docs/ContactsApi.md#getcontactstats) | **Get** /contacts/{identifier}/campaignStats | Get email campaigns' statistics for a contact
-*ContactsApi* | [**GetContacts**](docs/ContactsApi.md#getcontacts) | **Get** /contacts | Get all the contacts
-*ContactsApi* | [**GetContactsFromList**](docs/ContactsApi.md#getcontactsfromlist) | **Get** /contacts/lists/{listId}/contacts | Get contacts in a list
-*ContactsApi* | [**GetFolder**](docs/ContactsApi.md#getfolder) | **Get** /contacts/folders/{folderId} | Returns a folder's details
-*ContactsApi* | [**GetFolderLists**](docs/ContactsApi.md#getfolderlists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
-*ContactsApi* | [**GetFolders**](docs/ContactsApi.md#getfolders) | **Get** /contacts/folders | Get all folders
-*ContactsApi* | [**GetList**](docs/ContactsApi.md#getlist) | **Get** /contacts/lists/{listId} | Get a list's details
-*ContactsApi* | [**GetLists**](docs/ContactsApi.md#getlists) | **Get** /contacts/lists | Get all the lists
-*ContactsApi* | [**ImportContacts**](docs/ContactsApi.md#importcontacts) | **Post** /contacts/import | Import contacts
-*ContactsApi* | [**RemoveContactFromList**](docs/ContactsApi.md#removecontactfromlist) | **Post** /contacts/lists/{listId}/contacts/remove | Delete a contact from a list
-*ContactsApi* | [**RequestContactExport**](docs/ContactsApi.md#requestcontactexport) | **Post** /contacts/export | Export contacts
-*ContactsApi* | [**UpdateAttribute**](docs/ContactsApi.md#updateattribute) | **Put** /contacts/attributes/{attributeCategory}/{attributeName} | Update contact attribute
-*ContactsApi* | [**UpdateBatchContacts**](docs/ContactsApi.md#updatebatchcontacts) | **Post** /contacts/batch | Update multiple contacts
-*ContactsApi* | [**UpdateContact**](docs/ContactsApi.md#updatecontact) | **Put** /contacts/{identifier} | Update a contact
-*ContactsApi* | [**UpdateFolder**](docs/ContactsApi.md#updatefolder) | **Put** /contacts/folders/{folderId} | Update a folder
-*ContactsApi* | [**UpdateList**](docs/ContactsApi.md#updatelist) | **Put** /contacts/lists/{listId} | Update a list
-*DealsApi* | [**CrmAttributesDealsGet**](docs/DealsApi.md#crmattributesdealsget) | **Get** /crm/attributes/deals | Get deal attributes
-*DealsApi* | [**CrmDealsGet**](docs/DealsApi.md#crmdealsget) | **Get** /crm/deals | Get all deals
-*DealsApi* | [**CrmDealsIdDelete**](docs/DealsApi.md#crmdealsiddelete) | **Delete** /crm/deals/{id} | Delete a deal
-*DealsApi* | [**CrmDealsIdGet**](docs/DealsApi.md#crmdealsidget) | **Get** /crm/deals/{id} | Get a deal
-*DealsApi* | [**CrmDealsIdPatch**](docs/DealsApi.md#crmdealsidpatch) | **Patch** /crm/deals/{id} | Update a deal
-*DealsApi* | [**CrmDealsPost**](docs/DealsApi.md#crmdealspost) | **Post** /crm/deals | Create a deal
-*DealsApi* | [**CrmPipelineDetailsGet**](docs/DealsApi.md#crmpipelinedetailsget) | **Get** /crm/pipeline/details | Get pipeline stages
-*EmailCampaignsApi* | [**CreateEmailCampaign**](docs/EmailCampaignsApi.md#createemailcampaign) | **Post** /emailCampaigns | Create an email campaign
-*EmailCampaignsApi* | [**DeleteEmailCampaign**](docs/EmailCampaignsApi.md#deleteemailcampaign) | **Delete** /emailCampaigns/{campaignId} | Delete an email campaign
-*EmailCampaignsApi* | [**EmailExportRecipients**](docs/EmailCampaignsApi.md#emailexportrecipients) | **Post** /emailCampaigns/{campaignId}/exportRecipients | Export the recipients of an email campaign
-*EmailCampaignsApi* | [**GetAbTestCampaignResult**](docs/EmailCampaignsApi.md#getabtestcampaignresult) | **Get** /emailCampaigns/{campaignId}/abTestCampaignResult | Get an A/B test email campaign results
-*EmailCampaignsApi* | [**GetEmailCampaign**](docs/EmailCampaignsApi.md#getemailcampaign) | **Get** /emailCampaigns/{campaignId} | Get an email campaign report
-*EmailCampaignsApi* | [**GetEmailCampaigns**](docs/EmailCampaignsApi.md#getemailcampaigns) | **Get** /emailCampaigns | Return all your created email campaigns
-*EmailCampaignsApi* | [**GetSharedTemplateUrl**](docs/EmailCampaignsApi.md#getsharedtemplateurl) | **Get** /emailCampaigns/{campaignId}/sharedUrl | Get a shared template url
-*EmailCampaignsApi* | [**SendEmailCampaignNow**](docs/EmailCampaignsApi.md#sendemailcampaignnow) | **Post** /emailCampaigns/{campaignId}/sendNow | Send an email campaign immediately, based on campaignId
-*EmailCampaignsApi* | [**SendReport**](docs/EmailCampaignsApi.md#sendreport) | **Post** /emailCampaigns/{campaignId}/sendReport | Send the report of a campaign
-*EmailCampaignsApi* | [**SendTestEmail**](docs/EmailCampaignsApi.md#sendtestemail) | **Post** /emailCampaigns/{campaignId}/sendTest | Send an email campaign to your test list
-*EmailCampaignsApi* | [**UpdateCampaignStatus**](docs/EmailCampaignsApi.md#updatecampaignstatus) | **Put** /emailCampaigns/{campaignId}/status | Update an email campaign status
-*EmailCampaignsApi* | [**UpdateEmailCampaign**](docs/EmailCampaignsApi.md#updateemailcampaign) | **Put** /emailCampaigns/{campaignId} | Update an email campaign
-*EmailCampaignsApi* | [**UploadImageToGallery**](docs/EmailCampaignsApi.md#uploadimagetogallery) | **Post** /emailCampaigns/images | Upload an image to your account's image gallery
-*FoldersApi* | [**CreateFolder**](docs/FoldersApi.md#createfolder) | **Post** /contacts/folders | Create a folder
-*FoldersApi* | [**DeleteFolder**](docs/FoldersApi.md#deletefolder) | **Delete** /contacts/folders/{folderId} | Delete a folder (and all its lists)
-*FoldersApi* | [**GetFolder**](docs/FoldersApi.md#getfolder) | **Get** /contacts/folders/{folderId} | Returns a folder's details
-*FoldersApi* | [**GetFolderLists**](docs/FoldersApi.md#getfolderlists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
-*FoldersApi* | [**GetFolders**](docs/FoldersApi.md#getfolders) | **Get** /contacts/folders | Get all folders
-*FoldersApi* | [**UpdateFolder**](docs/FoldersApi.md#updatefolder) | **Put** /contacts/folders/{folderId} | Update a folder
-*InboundParsingApi* | [**GetInboundEmailEvents**](docs/InboundParsingApi.md#getinboundemailevents) | **Get** /inbound/events | Get the list of all the events for the received emails.
-*InboundParsingApi* | [**GetInboundEmailEventsByUuid**](docs/InboundParsingApi.md#getinboundemaileventsbyuuid) | **Get** /inbound/events/{uuid} | Fetch all events history for one particular received email.
-*ListsApi* | [**AddContactToList**](docs/ListsApi.md#addcontacttolist) | **Post** /contacts/lists/{listId}/contacts/add | Add existing contacts to a list
-*ListsApi* | [**CreateList**](docs/ListsApi.md#createlist) | **Post** /contacts/lists | Create a list
-*ListsApi* | [**DeleteList**](docs/ListsApi.md#deletelist) | **Delete** /contacts/lists/{listId} | Delete a list
-*ListsApi* | [**GetContactsFromList**](docs/ListsApi.md#getcontactsfromlist) | **Get** /contacts/lists/{listId}/contacts | Get contacts in a list
-*ListsApi* | [**GetFolderLists**](docs/ListsApi.md#getfolderlists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
-*ListsApi* | [**GetList**](docs/ListsApi.md#getlist) | **Get** /contacts/lists/{listId} | Get a list's details
-*ListsApi* | [**GetLists**](docs/ListsApi.md#getlists) | **Get** /contacts/lists | Get all the lists
-*ListsApi* | [**RemoveContactFromList**](docs/ListsApi.md#removecontactfromlist) | **Post** /contacts/lists/{listId}/contacts/remove | Delete a contact from a list
-*ListsApi* | [**UpdateList**](docs/ListsApi.md#updatelist) | **Put** /contacts/lists/{listId} | Update a list
-*MasterAccountApi* | [**CorporateMasterAccountGet**](docs/MasterAccountApi.md#corporatemasteraccountget) | **Get** /corporate/masterAccount | Get the details of requested master account
-*MasterAccountApi* | [**CorporateSubAccountGet**](docs/MasterAccountApi.md#corporatesubaccountget) | **Get** /corporate/subAccount | Get the list of all the sub-accounts of the master account.
-*MasterAccountApi* | [**CorporateSubAccountIdDelete**](docs/MasterAccountApi.md#corporatesubaccountiddelete) | **Delete** /corporate/subAccount/{id} | Delete a sub-account
-*MasterAccountApi* | [**CorporateSubAccountIdGet**](docs/MasterAccountApi.md#corporatesubaccountidget) | **Get** /corporate/subAccount/{id} | Get sub-account details
-*MasterAccountApi* | [**CorporateSubAccountIdPlanPut**](docs/MasterAccountApi.md#corporatesubaccountidplanput) | **Put** /corporate/subAccount/{id}/plan | Update sub-account plan
-*MasterAccountApi* | [**CorporateSubAccountPost**](docs/MasterAccountApi.md#corporatesubaccountpost) | **Post** /corporate/subAccount | Create a new sub-account under a master account.
-*MasterAccountApi* | [**CorporateSubAccountSsoTokenPost**](docs/MasterAccountApi.md#corporatesubaccountssotokenpost) | **Post** /corporate/subAccount/ssoToken | Generate SSO token to access Sendinblue
-*ProcessApi* | [**GetProcess**](docs/ProcessApi.md#getprocess) | **Get** /processes/{processId} | Return the informations for a process
-*ProcessApi* | [**GetProcesses**](docs/ProcessApi.md#getprocesses) | **Get** /processes | Return all the processes for your account
-*ResellerApi* | [**AddCredits**](docs/ResellerApi.md#addcredits) | **Post** /reseller/children/{childIdentifier}/credits/add | Add Email and/or SMS credits to a specific child account
-*ResellerApi* | [**AssociateIpToChild**](docs/ResellerApi.md#associateiptochild) | **Post** /reseller/children/{childIdentifier}/ips/associate | Associate a dedicated IP to the child
-*ResellerApi* | [**CreateChildDomain**](docs/ResellerApi.md#createchilddomain) | **Post** /reseller/children/{childIdentifier}/domains | Create a domain for a child account
-*ResellerApi* | [**CreateResellerChild**](docs/ResellerApi.md#createresellerchild) | **Post** /reseller/children | Creates a reseller child
-*ResellerApi* | [**DeleteChildDomain**](docs/ResellerApi.md#deletechilddomain) | **Delete** /reseller/children/{childIdentifier}/domains/{domainName} | Delete the sender domain of the reseller child based on the childIdentifier and domainName passed
-*ResellerApi* | [**DeleteResellerChild**](docs/ResellerApi.md#deleteresellerchild) | **Delete** /reseller/children/{childIdentifier} | Delete a single reseller child based on the child identifier supplied
-*ResellerApi* | [**DissociateIpFromChild**](docs/ResellerApi.md#dissociateipfromchild) | **Post** /reseller/children/{childIdentifier}/ips/dissociate | Dissociate a dedicated IP to the child
-*ResellerApi* | [**GetChildAccountCreationStatus**](docs/ResellerApi.md#getchildaccountcreationstatus) | **Get** /reseller/children/{childIdentifier}/accountCreationStatus | Get the status of a reseller's child account creation, whether it is successfully created (exists) or not based on the identifier supplied
-*ResellerApi* | [**GetChildDomains**](docs/ResellerApi.md#getchilddomains) | **Get** /reseller/children/{childIdentifier}/domains | Get all sender domains for a specific child account
-*ResellerApi* | [**GetChildInfo**](docs/ResellerApi.md#getchildinfo) | **Get** /reseller/children/{childIdentifier} | Get a child account's details
-*ResellerApi* | [**GetResellerChilds**](docs/ResellerApi.md#getresellerchilds) | **Get** /reseller/children | Get the list of all children accounts
-*ResellerApi* | [**GetSsoToken**](docs/ResellerApi.md#getssotoken) | **Get** /reseller/children/{childIdentifier}/auth | Get session token to access Sendinblue (SSO)
-*ResellerApi* | [**RemoveCredits**](docs/ResellerApi.md#removecredits) | **Post** /reseller/children/{childIdentifier}/credits/remove | Remove Email and/or SMS credits from a specific child account
-*ResellerApi* | [**UpdateChildAccountStatus**](docs/ResellerApi.md#updatechildaccountstatus) | **Put** /reseller/children/{childIdentifier}/accountStatus | Update info of reseller's child account status based on the childIdentifier supplied
-*ResellerApi* | [**UpdateChildDomain**](docs/ResellerApi.md#updatechilddomain) | **Put** /reseller/children/{childIdentifier}/domains/{domainName} | Update the sender domain of reseller's child based on the childIdentifier and domainName passed
-*ResellerApi* | [**UpdateResellerChild**](docs/ResellerApi.md#updateresellerchild) | **Put** /reseller/children/{childIdentifier} | Update info of reseller's child based on the child identifier supplied
-*SMSCampaignsApi* | [**CreateSmsCampaign**](docs/SMSCampaignsApi.md#createsmscampaign) | **Post** /smsCampaigns | Creates an SMS campaign
-*SMSCampaignsApi* | [**DeleteSmsCampaign**](docs/SMSCampaignsApi.md#deletesmscampaign) | **Delete** /smsCampaigns/{campaignId} | Delete an SMS campaign
-*SMSCampaignsApi* | [**GetSmsCampaign**](docs/SMSCampaignsApi.md#getsmscampaign) | **Get** /smsCampaigns/{campaignId} | Get an SMS campaign
-*SMSCampaignsApi* | [**GetSmsCampaigns**](docs/SMSCampaignsApi.md#getsmscampaigns) | **Get** /smsCampaigns | Returns the information for all your created SMS campaigns
-*SMSCampaignsApi* | [**RequestSmsRecipientExport**](docs/SMSCampaignsApi.md#requestsmsrecipientexport) | **Post** /smsCampaigns/{campaignId}/exportRecipients | Export an SMS campaign's recipients
-*SMSCampaignsApi* | [**SendSmsCampaignNow**](docs/SMSCampaignsApi.md#sendsmscampaignnow) | **Post** /smsCampaigns/{campaignId}/sendNow | Send your SMS campaign immediately
-*SMSCampaignsApi* | [**SendSmsReport**](docs/SMSCampaignsApi.md#sendsmsreport) | **Post** /smsCampaigns/{campaignId}/sendReport | Send an SMS campaign's report
-*SMSCampaignsApi* | [**SendTestSms**](docs/SMSCampaignsApi.md#sendtestsms) | **Post** /smsCampaigns/{campaignId}/sendTest | Send a test SMS campaign
-*SMSCampaignsApi* | [**UpdateSmsCampaign**](docs/SMSCampaignsApi.md#updatesmscampaign) | **Put** /smsCampaigns/{campaignId} | Update an SMS campaign
-*SMSCampaignsApi* | [**UpdateSmsCampaignStatus**](docs/SMSCampaignsApi.md#updatesmscampaignstatus) | **Put** /smsCampaigns/{campaignId}/status | Update a campaign's status
-*SendersApi* | [**CreateSender**](docs/SendersApi.md#createsender) | **Post** /senders | Create a new sender
-*SendersApi* | [**DeleteSender**](docs/SendersApi.md#deletesender) | **Delete** /senders/{senderId} | Delete a sender
-*SendersApi* | [**GetIps**](docs/SendersApi.md#getips) | **Get** /senders/ips | Get all the dedicated IPs for your account
-*SendersApi* | [**GetIpsFromSender**](docs/SendersApi.md#getipsfromsender) | **Get** /senders/{senderId}/ips | Get all the dedicated IPs for a sender
-*SendersApi* | [**GetSenders**](docs/SendersApi.md#getsenders) | **Get** /senders | Get the list of all your senders
-*SendersApi* | [**UpdateSender**](docs/SendersApi.md#updatesender) | **Put** /senders/{senderId} | Update a sender
-*TransactionalEmailsApi* | [**BlockNewDomain**](docs/TransactionalEmailsApi.md#blocknewdomain) | **Post** /smtp/blockedDomains | Add a new domain to the list of blocked domains
-*TransactionalEmailsApi* | [**CreateSmtpTemplate**](docs/TransactionalEmailsApi.md#createsmtptemplate) | **Post** /smtp/templates | Create an email template
-*TransactionalEmailsApi* | [**DeleteBlockedDomain**](docs/TransactionalEmailsApi.md#deleteblockeddomain) | **Delete** /smtp/blockedDomains/{domain} | Unblock an existing domain from the list of blocked domains
-*TransactionalEmailsApi* | [**DeleteHardbounces**](docs/TransactionalEmailsApi.md#deletehardbounces) | **Post** /smtp/deleteHardbounces | Delete hardbounces
-*TransactionalEmailsApi* | [**DeleteScheduledEmailById**](docs/TransactionalEmailsApi.md#deletescheduledemailbyid) | **Delete** /smtp/email/{identifier} | Delete scheduled emails by batchId or messageId
-*TransactionalEmailsApi* | [**DeleteSmtpTemplate**](docs/TransactionalEmailsApi.md#deletesmtptemplate) | **Delete** /smtp/templates/{templateId} | Delete an inactive email template
-*TransactionalEmailsApi* | [**GetAggregatedSmtpReport**](docs/TransactionalEmailsApi.md#getaggregatedsmtpreport) | **Get** /smtp/statistics/aggregatedReport | Get your transactional email activity aggregated over a period of time
-*TransactionalEmailsApi* | [**GetBlockedDomains**](docs/TransactionalEmailsApi.md#getblockeddomains) | **Get** /smtp/blockedDomains | Get the list of blocked domains
-*TransactionalEmailsApi* | [**GetEmailEventReport**](docs/TransactionalEmailsApi.md#getemaileventreport) | **Get** /smtp/statistics/events | Get all your transactional email activity (unaggregated events)
-*TransactionalEmailsApi* | [**GetScheduledEmailByBatchId**](docs/TransactionalEmailsApi.md#getscheduledemailbybatchid) | **Get** /smtp/emailStatus/{batchId} | Fetch scheduled emails by batchId
-*TransactionalEmailsApi* | [**GetScheduledEmailByMessageId**](docs/TransactionalEmailsApi.md#getscheduledemailbymessageid) | **Get** /smtp/emailStatus/{messageId} | Fetch scheduled email by messageId
-*TransactionalEmailsApi* | [**GetSmtpReport**](docs/TransactionalEmailsApi.md#getsmtpreport) | **Get** /smtp/statistics/reports | Get your transactional email activity aggregated per day
-*TransactionalEmailsApi* | [**GetSmtpTemplate**](docs/TransactionalEmailsApi.md#getsmtptemplate) | **Get** /smtp/templates/{templateId} | Returns the template information
-*TransactionalEmailsApi* | [**GetSmtpTemplates**](docs/TransactionalEmailsApi.md#getsmtptemplates) | **Get** /smtp/templates | Get the list of email templates
-*TransactionalEmailsApi* | [**GetTransacBlockedContacts**](docs/TransactionalEmailsApi.md#gettransacblockedcontacts) | **Get** /smtp/blockedContacts | Get the list of blocked or unsubscribed transactional contacts
-*TransactionalEmailsApi* | [**GetTransacEmailContent**](docs/TransactionalEmailsApi.md#gettransacemailcontent) | **Get** /smtp/emails/{uuid} | Get the personalized content of a sent transactional email
-*TransactionalEmailsApi* | [**GetTransacEmailsList**](docs/TransactionalEmailsApi.md#gettransacemailslist) | **Get** /smtp/emails | Get the list of transactional emails on the basis of allowed filters
-*TransactionalEmailsApi* | [**SendTestTemplate**](docs/TransactionalEmailsApi.md#sendtesttemplate) | **Post** /smtp/templates/{templateId}/sendTest | Send a template to your test list
-*TransactionalEmailsApi* | [**SendTransacEmail**](docs/TransactionalEmailsApi.md#sendtransacemail) | **Post** /smtp/email | Send a transactional email
-*TransactionalEmailsApi* | [**SmtpBlockedContactsEmailDelete**](docs/TransactionalEmailsApi.md#smtpblockedcontactsemaildelete) | **Delete** /smtp/blockedContacts/{email} | Unblock or resubscribe a transactional contact
-*TransactionalEmailsApi* | [**SmtpLogMessageIdDelete**](docs/TransactionalEmailsApi.md#smtplogmessageiddelete) | **Delete** /smtp/log/{messageId} | Delete an SMTP transactional log
-*TransactionalEmailsApi* | [**UpdateSmtpTemplate**](docs/TransactionalEmailsApi.md#updatesmtptemplate) | **Put** /smtp/templates/{templateId} | Update an email template
-*TransactionalSMSApi* | [**GetSmsEvents**](docs/TransactionalSMSApi.md#getsmsevents) | **Get** /transactionalSMS/statistics/events | Get all your SMS activity (unaggregated events)
-*TransactionalSMSApi* | [**GetTransacAggregatedSmsReport**](docs/TransactionalSMSApi.md#gettransacaggregatedsmsreport) | **Get** /transactionalSMS/statistics/aggregatedReport | Get your SMS activity aggregated over a period of time
-*TransactionalSMSApi* | [**GetTransacSmsReport**](docs/TransactionalSMSApi.md#gettransacsmsreport) | **Get** /transactionalSMS/statistics/reports | Get your SMS activity aggregated per day
-*TransactionalSMSApi* | [**SendTransacSms**](docs/TransactionalSMSApi.md#sendtransacsms) | **Post** /transactionalSMS/sms | Send SMS message to a mobile number
-*WebhooksApi* | [**CreateWebhook**](docs/WebhooksApi.md#createwebhook) | **Post** /webhooks | Create a webhook
-*WebhooksApi* | [**DeleteWebhook**](docs/WebhooksApi.md#deletewebhook) | **Delete** /webhooks/{webhookId} | Delete a webhook
-*WebhooksApi* | [**GetWebhook**](docs/WebhooksApi.md#getwebhook) | **Get** /webhooks/{webhookId} | Get a webhook details
-*WebhooksApi* | [**GetWebhooks**](docs/WebhooksApi.md#getwebhooks) | **Get** /webhooks | Get all webhooks
-*WebhooksApi* | [**UpdateWebhook**](docs/WebhooksApi.md#updatewebhook) | **Put** /webhooks/{webhookId} | Update a webhook
+*AttributesApi* | [**CreateAttribute**](docs/AttributesApi.md#CreateAttribute) | **Post** /contacts/attributes/{attributeCategory}/{attributeName} | Create contact attribute
+*AttributesApi* | [**DeleteAttribute**](docs/AttributesApi.md#DeleteAttribute) | **Delete** /contacts/attributes/{attributeCategory}/{attributeName} | Delete an attribute
+*AttributesApi* | [**GetAttributes**](docs/AttributesApi.md#GetAttributes) | **Get** /contacts/attributes | List all attributes
+*AttributesApi* | [**UpdateAttribute**](docs/AttributesApi.md#UpdateAttribute) | **Put** /contacts/attributes/{attributeCategory}/{attributeName} | Update contact attribute
+*CRMApi* | [**CrmNotesGet**](docs/CRMApi.md#CrmNotesGet) | **Get** /crm/notes | Get all notes
+*CRMApi* | [**CrmNotesIdDelete**](docs/CRMApi.md#CrmNotesIdDelete) | **Delete** /crm/notes/{id} | Delete a note
+*CRMApi* | [**CrmNotesIdGet**](docs/CRMApi.md#CrmNotesIdGet) | **Get** /crm/notes/{id} | Get a note
+*CRMApi* | [**CrmNotesIdPatch**](docs/CRMApi.md#CrmNotesIdPatch) | **Patch** /crm/notes/{id} | Update a note
+*CRMApi* | [**CrmNotesPost**](docs/CRMApi.md#CrmNotesPost) | **Post** /crm/notes | Create a note
+*CRMApi* | [**CrmTasksGet**](docs/CRMApi.md#CrmTasksGet) | **Get** /crm/tasks | Get all tasks
+*CRMApi* | [**CrmTasksIdDelete**](docs/CRMApi.md#CrmTasksIdDelete) | **Delete** /crm/tasks/{id} | Delete a task
+*CRMApi* | [**CrmTasksIdGet**](docs/CRMApi.md#CrmTasksIdGet) | **Get** /crm/tasks/{id} | Get a task
+*CRMApi* | [**CrmTasksIdPatch**](docs/CRMApi.md#CrmTasksIdPatch) | **Patch** /crm/tasks/{id} | Update a task
+*CRMApi* | [**CrmTasksPost**](docs/CRMApi.md#CrmTasksPost) | **Post** /crm/tasks | Create a task
+*CRMApi* | [**CrmTasktypesGet**](docs/CRMApi.md#CrmTasktypesGet) | **Get** /crm/tasktypes | Get all task types
+*CompaniesApi* | [**CompaniesAttributesGet**](docs/CompaniesApi.md#CompaniesAttributesGet) | **Get** /companies/attributes | Get company attributes
+*CompaniesApi* | [**CompaniesGet**](docs/CompaniesApi.md#CompaniesGet) | **Get** /companies | Get all companies
+*CompaniesApi* | [**CompaniesIdDelete**](docs/CompaniesApi.md#CompaniesIdDelete) | **Delete** /companies/{id} | Delete a company
+*CompaniesApi* | [**CompaniesIdGet**](docs/CompaniesApi.md#CompaniesIdGet) | **Get** /companies/{id} | Get a company
+*CompaniesApi* | [**CompaniesIdPatch**](docs/CompaniesApi.md#CompaniesIdPatch) | **Patch** /companies/{id} | Update a company
+*CompaniesApi* | [**CompaniesLinkUnlinkIdPatch**](docs/CompaniesApi.md#CompaniesLinkUnlinkIdPatch) | **Patch** /companies/link-unlink/{id} | Link and Unlink company with contacts and deals
+*CompaniesApi* | [**CompaniesPost**](docs/CompaniesApi.md#CompaniesPost) | **Post** /companies | Create a company
+*ContactsApi* | [**AddContactToList**](docs/ContactsApi.md#AddContactToList) | **Post** /contacts/lists/{listId}/contacts/add | Add existing contacts to a list
+*ContactsApi* | [**CreateAttribute**](docs/ContactsApi.md#CreateAttribute) | **Post** /contacts/attributes/{attributeCategory}/{attributeName} | Create contact attribute
+*ContactsApi* | [**CreateContact**](docs/ContactsApi.md#CreateContact) | **Post** /contacts | Create a contact
+*ContactsApi* | [**CreateDoiContact**](docs/ContactsApi.md#CreateDoiContact) | **Post** /contacts/doubleOptinConfirmation | Create Contact via DOI (Double-Opt-In) Flow
+*ContactsApi* | [**CreateFolder**](docs/ContactsApi.md#CreateFolder) | **Post** /contacts/folders | Create a folder
+*ContactsApi* | [**CreateList**](docs/ContactsApi.md#CreateList) | **Post** /contacts/lists | Create a list
+*ContactsApi* | [**DeleteAttribute**](docs/ContactsApi.md#DeleteAttribute) | **Delete** /contacts/attributes/{attributeCategory}/{attributeName} | Delete an attribute
+*ContactsApi* | [**DeleteContact**](docs/ContactsApi.md#DeleteContact) | **Delete** /contacts/{identifier} | Delete a contact
+*ContactsApi* | [**DeleteFolder**](docs/ContactsApi.md#DeleteFolder) | **Delete** /contacts/folders/{folderId} | Delete a folder (and all its lists)
+*ContactsApi* | [**DeleteList**](docs/ContactsApi.md#DeleteList) | **Delete** /contacts/lists/{listId} | Delete a list
+*ContactsApi* | [**GetAttributes**](docs/ContactsApi.md#GetAttributes) | **Get** /contacts/attributes | List all attributes
+*ContactsApi* | [**GetContactInfo**](docs/ContactsApi.md#GetContactInfo) | **Get** /contacts/{identifier} | Get a contact's details
+*ContactsApi* | [**GetContactStats**](docs/ContactsApi.md#GetContactStats) | **Get** /contacts/{identifier}/campaignStats | Get email campaigns' statistics for a contact
+*ContactsApi* | [**GetContacts**](docs/ContactsApi.md#GetContacts) | **Get** /contacts | Get all the contacts
+*ContactsApi* | [**GetContactsFromList**](docs/ContactsApi.md#GetContactsFromList) | **Get** /contacts/lists/{listId}/contacts | Get contacts in a list
+*ContactsApi* | [**GetFolder**](docs/ContactsApi.md#GetFolder) | **Get** /contacts/folders/{folderId} | Returns a folder's details
+*ContactsApi* | [**GetFolderLists**](docs/ContactsApi.md#GetFolderLists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
+*ContactsApi* | [**GetFolders**](docs/ContactsApi.md#GetFolders) | **Get** /contacts/folders | Get all folders
+*ContactsApi* | [**GetList**](docs/ContactsApi.md#GetList) | **Get** /contacts/lists/{listId} | Get a list's details
+*ContactsApi* | [**GetLists**](docs/ContactsApi.md#GetLists) | **Get** /contacts/lists | Get all the lists
+*ContactsApi* | [**ImportContacts**](docs/ContactsApi.md#ImportContacts) | **Post** /contacts/import | Import contacts
+*ContactsApi* | [**RemoveContactFromList**](docs/ContactsApi.md#RemoveContactFromList) | **Post** /contacts/lists/{listId}/contacts/remove | Delete a contact from a list
+*ContactsApi* | [**RequestContactExport**](docs/ContactsApi.md#RequestContactExport) | **Post** /contacts/export | Export contacts
+*ContactsApi* | [**UpdateAttribute**](docs/ContactsApi.md#UpdateAttribute) | **Put** /contacts/attributes/{attributeCategory}/{attributeName} | Update contact attribute
+*ContactsApi* | [**UpdateBatchContacts**](docs/ContactsApi.md#UpdateBatchContacts) | **Post** /contacts/batch | Update multiple contacts
+*ContactsApi* | [**UpdateContact**](docs/ContactsApi.md#UpdateContact) | **Put** /contacts/{identifier} | Update a contact
+*ContactsApi* | [**UpdateFolder**](docs/ContactsApi.md#UpdateFolder) | **Put** /contacts/folders/{folderId} | Update a folder
+*ContactsApi* | [**UpdateList**](docs/ContactsApi.md#UpdateList) | **Put** /contacts/lists/{listId} | Update a list
+*ConversationsApi* | [**ConversationsAgentOnlinePingPost**](docs/ConversationsApi.md#ConversationsAgentOnlinePingPost) | **Post** /conversations/agentOnlinePing | Sets agent’s status to online for 2-3 minutes
+*ConversationsApi* | [**ConversationsMessagesIdDelete**](docs/ConversationsApi.md#ConversationsMessagesIdDelete) | **Delete** /conversations/messages/{id} | Delete a message sent by an agent
+*ConversationsApi* | [**ConversationsMessagesIdGet**](docs/ConversationsApi.md#ConversationsMessagesIdGet) | **Get** /conversations/messages/{id} | Get a message
+*ConversationsApi* | [**ConversationsMessagesIdPut**](docs/ConversationsApi.md#ConversationsMessagesIdPut) | **Put** /conversations/messages/{id} | Update a message sent by an agent
+*ConversationsApi* | [**ConversationsMessagesPost**](docs/ConversationsApi.md#ConversationsMessagesPost) | **Post** /conversations/messages | Send a message as an agent
+*ConversationsApi* | [**ConversationsPushedMessagesIdDelete**](docs/ConversationsApi.md#ConversationsPushedMessagesIdDelete) | **Delete** /conversations/pushedMessages/{id} | Delete an automated message
+*ConversationsApi* | [**ConversationsPushedMessagesIdGet**](docs/ConversationsApi.md#ConversationsPushedMessagesIdGet) | **Get** /conversations/pushedMessages/{id} | Get an automated message
+*ConversationsApi* | [**ConversationsPushedMessagesIdPut**](docs/ConversationsApi.md#ConversationsPushedMessagesIdPut) | **Put** /conversations/pushedMessages/{id} | Update an automated message
+*ConversationsApi* | [**ConversationsPushedMessagesPost**](docs/ConversationsApi.md#ConversationsPushedMessagesPost) | **Post** /conversations/pushedMessages | Send an automated message to a visitor
+*DealsApi* | [**CrmAttributesDealsGet**](docs/DealsApi.md#CrmAttributesDealsGet) | **Get** /crm/attributes/deals | Get deal attributes
+*DealsApi* | [**CrmDealsGet**](docs/DealsApi.md#CrmDealsGet) | **Get** /crm/deals | Get all deals
+*DealsApi* | [**CrmDealsIdDelete**](docs/DealsApi.md#CrmDealsIdDelete) | **Delete** /crm/deals/{id} | Delete a deal
+*DealsApi* | [**CrmDealsIdGet**](docs/DealsApi.md#CrmDealsIdGet) | **Get** /crm/deals/{id} | Get a deal
+*DealsApi* | [**CrmDealsIdPatch**](docs/DealsApi.md#CrmDealsIdPatch) | **Patch** /crm/deals/{id} | Update a deal
+*DealsApi* | [**CrmDealsLinkUnlinkIdPatch**](docs/DealsApi.md#CrmDealsLinkUnlinkIdPatch) | **Patch** /crm/deals/link-unlink/{id} | Link and Unlink a deal with contacts and companies
+*DealsApi* | [**CrmDealsPost**](docs/DealsApi.md#CrmDealsPost) | **Post** /crm/deals | Create a deal
+*DealsApi* | [**CrmPipelineDetailsGet**](docs/DealsApi.md#CrmPipelineDetailsGet) | **Get** /crm/pipeline/details | Get pipeline stages
+*EcommerceApi* | [**CreateBatchOrder**](docs/EcommerceApi.md#CreateBatchOrder) | **Post** /orders/status/batch | Maintains a batch of orders
+*EcommerceApi* | [**CreateOrder**](docs/EcommerceApi.md#CreateOrder) | **Post** /orders/status | Maintains every transactional status of the order
+*EcommerceApi* | [**CreateUpdateBatchCategory**](docs/EcommerceApi.md#CreateUpdateBatchCategory) | **Post** /categories/batch | Create the categories in a batch
+*EcommerceApi* | [**CreateUpdateBatchProducts**](docs/EcommerceApi.md#CreateUpdateBatchProducts) | **Post** /products/batch | Creates the products in a batch
+*EcommerceApi* | [**CreateUpdateCategory**](docs/EcommerceApi.md#CreateUpdateCategory) | **Post** /categories | Create/Update a category
+*EcommerceApi* | [**CreateUpdateProduct**](docs/EcommerceApi.md#CreateUpdateProduct) | **Post** /products | Create/Update a product
+*EcommerceApi* | [**EcommerceActivatePost**](docs/EcommerceApi.md#EcommerceActivatePost) | **Post** /ecommerce/activate | **Fulfills the eCommerce pre-requisites**
+*EcommerceApi* | [**GetCategories**](docs/EcommerceApi.md#GetCategories) | **Get** /categories | Return all your categories
+*EcommerceApi* | [**GetCategoryInfo**](docs/EcommerceApi.md#GetCategoryInfo) | **Get** /categories/{id} | Get a category details
+*EcommerceApi* | [**GetProductInfo**](docs/EcommerceApi.md#GetProductInfo) | **Get** /products/{id} | Get a product's details
+*EcommerceApi* | [**GetProducts**](docs/EcommerceApi.md#GetProducts) | **Get** /products | Return all your products
+*EmailCampaignsApi* | [**CreateEmailCampaign**](docs/EmailCampaignsApi.md#CreateEmailCampaign) | **Post** /emailCampaigns | Create an email campaign
+*EmailCampaignsApi* | [**DeleteEmailCampaign**](docs/EmailCampaignsApi.md#DeleteEmailCampaign) | **Delete** /emailCampaigns/{campaignId} | Delete an email campaign
+*EmailCampaignsApi* | [**EmailExportRecipients**](docs/EmailCampaignsApi.md#EmailExportRecipients) | **Post** /emailCampaigns/{campaignId}/exportRecipients | Export the recipients of an email campaign
+*EmailCampaignsApi* | [**GetAbTestCampaignResult**](docs/EmailCampaignsApi.md#GetAbTestCampaignResult) | **Get** /emailCampaigns/{campaignId}/abTestCampaignResult | Get an A/B test email campaign results
+*EmailCampaignsApi* | [**GetEmailCampaign**](docs/EmailCampaignsApi.md#GetEmailCampaign) | **Get** /emailCampaigns/{campaignId} | Get an email campaign report
+*EmailCampaignsApi* | [**GetEmailCampaigns**](docs/EmailCampaignsApi.md#GetEmailCampaigns) | **Get** /emailCampaigns | Return all your created email campaigns
+*EmailCampaignsApi* | [**GetSharedTemplateUrl**](docs/EmailCampaignsApi.md#GetSharedTemplateUrl) | **Get** /emailCampaigns/{campaignId}/sharedUrl | Get a shared template url
+*EmailCampaignsApi* | [**SendEmailCampaignNow**](docs/EmailCampaignsApi.md#SendEmailCampaignNow) | **Post** /emailCampaigns/{campaignId}/sendNow | Send an email campaign immediately, based on campaignId
+*EmailCampaignsApi* | [**SendReport**](docs/EmailCampaignsApi.md#SendReport) | **Post** /emailCampaigns/{campaignId}/sendReport | Send the report of a campaign
+*EmailCampaignsApi* | [**SendTestEmail**](docs/EmailCampaignsApi.md#SendTestEmail) | **Post** /emailCampaigns/{campaignId}/sendTest | Send an email campaign to your test list
+*EmailCampaignsApi* | [**UpdateCampaignStatus**](docs/EmailCampaignsApi.md#UpdateCampaignStatus) | **Put** /emailCampaigns/{campaignId}/status | Update an email campaign status
+*EmailCampaignsApi* | [**UpdateEmailCampaign**](docs/EmailCampaignsApi.md#UpdateEmailCampaign) | **Put** /emailCampaigns/{campaignId} | Update an email campaign
+*EmailCampaignsApi* | [**UploadImageToGallery**](docs/EmailCampaignsApi.md#UploadImageToGallery) | **Post** /emailCampaigns/images | Upload an image to your account's image gallery
+*FoldersApi* | [**CreateFolder**](docs/FoldersApi.md#CreateFolder) | **Post** /contacts/folders | Create a folder
+*FoldersApi* | [**DeleteFolder**](docs/FoldersApi.md#DeleteFolder) | **Delete** /contacts/folders/{folderId} | Delete a folder (and all its lists)
+*FoldersApi* | [**GetFolder**](docs/FoldersApi.md#GetFolder) | **Get** /contacts/folders/{folderId} | Returns a folder's details
+*FoldersApi* | [**GetFolderLists**](docs/FoldersApi.md#GetFolderLists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
+*FoldersApi* | [**GetFolders**](docs/FoldersApi.md#GetFolders) | **Get** /contacts/folders | Get all folders
+*FoldersApi* | [**UpdateFolder**](docs/FoldersApi.md#UpdateFolder) | **Put** /contacts/folders/{folderId} | Update a folder
+*InboundParsingApi* | [**GetInboundEmailEvents**](docs/InboundParsingApi.md#GetInboundEmailEvents) | **Get** /inbound/events | Get the list of all the events for the received emails.
+*InboundParsingApi* | [**GetInboundEmailEventsByUuid**](docs/InboundParsingApi.md#GetInboundEmailEventsByUuid) | **Get** /inbound/events/{uuid} | Fetch all events history for one particular received email.
+*ListsApi* | [**AddContactToList**](docs/ListsApi.md#AddContactToList) | **Post** /contacts/lists/{listId}/contacts/add | Add existing contacts to a list
+*ListsApi* | [**CreateList**](docs/ListsApi.md#CreateList) | **Post** /contacts/lists | Create a list
+*ListsApi* | [**DeleteList**](docs/ListsApi.md#DeleteList) | **Delete** /contacts/lists/{listId} | Delete a list
+*ListsApi* | [**GetContactsFromList**](docs/ListsApi.md#GetContactsFromList) | **Get** /contacts/lists/{listId}/contacts | Get contacts in a list
+*ListsApi* | [**GetFolderLists**](docs/ListsApi.md#GetFolderLists) | **Get** /contacts/folders/{folderId}/lists | Get lists in a folder
+*ListsApi* | [**GetList**](docs/ListsApi.md#GetList) | **Get** /contacts/lists/{listId} | Get a list's details
+*ListsApi* | [**GetLists**](docs/ListsApi.md#GetLists) | **Get** /contacts/lists | Get all the lists
+*ListsApi* | [**RemoveContactFromList**](docs/ListsApi.md#RemoveContactFromList) | **Post** /contacts/lists/{listId}/contacts/remove | Delete a contact from a list
+*ListsApi* | [**UpdateList**](docs/ListsApi.md#UpdateList) | **Put** /contacts/lists/{listId} | Update a list
+*MasterAccountApi* | [**CorporateMasterAccountGet**](docs/MasterAccountApi.md#CorporateMasterAccountGet) | **Get** /corporate/masterAccount | Get the details of requested master account
+*MasterAccountApi* | [**CorporateSubAccountGet**](docs/MasterAccountApi.md#CorporateSubAccountGet) | **Get** /corporate/subAccount | Get the list of all the sub-accounts of the master account.
+*MasterAccountApi* | [**CorporateSubAccountIdDelete**](docs/MasterAccountApi.md#CorporateSubAccountIdDelete) | **Delete** /corporate/subAccount/{id} | Delete a sub-account
+*MasterAccountApi* | [**CorporateSubAccountIdGet**](docs/MasterAccountApi.md#CorporateSubAccountIdGet) | **Get** /corporate/subAccount/{id} | Get sub-account details
+*MasterAccountApi* | [**CorporateSubAccountIdPlanPut**](docs/MasterAccountApi.md#CorporateSubAccountIdPlanPut) | **Put** /corporate/subAccount/{id}/plan | Update sub-account plan
+*MasterAccountApi* | [**CorporateSubAccountPost**](docs/MasterAccountApi.md#CorporateSubAccountPost) | **Post** /corporate/subAccount | Create a new sub-account under a master account.
+*MasterAccountApi* | [**CorporateSubAccountSsoTokenPost**](docs/MasterAccountApi.md#CorporateSubAccountSsoTokenPost) | **Post** /corporate/subAccount/ssoToken | Generate SSO token to access Sendinblue
+*NotesApi* | [**CrmNotesGet**](docs/NotesApi.md#CrmNotesGet) | **Get** /crm/notes | Get all notes
+*NotesApi* | [**CrmNotesIdDelete**](docs/NotesApi.md#CrmNotesIdDelete) | **Delete** /crm/notes/{id} | Delete a note
+*NotesApi* | [**CrmNotesIdGet**](docs/NotesApi.md#CrmNotesIdGet) | **Get** /crm/notes/{id} | Get a note
+*NotesApi* | [**CrmNotesIdPatch**](docs/NotesApi.md#CrmNotesIdPatch) | **Patch** /crm/notes/{id} | Update a note
+*NotesApi* | [**CrmNotesPost**](docs/NotesApi.md#CrmNotesPost) | **Post** /crm/notes | Create a note
+*ProcessApi* | [**GetProcess**](docs/ProcessApi.md#GetProcess) | **Get** /processes/{processId} | Return the informations for a process
+*ProcessApi* | [**GetProcesses**](docs/ProcessApi.md#GetProcesses) | **Get** /processes | Return all the processes for your account
+*ResellerApi* | [**AddCredits**](docs/ResellerApi.md#AddCredits) | **Post** /reseller/children/{childIdentifier}/credits/add | Add Email and/or SMS credits to a specific child account
+*ResellerApi* | [**AssociateIpToChild**](docs/ResellerApi.md#AssociateIpToChild) | **Post** /reseller/children/{childIdentifier}/ips/associate | Associate a dedicated IP to the child
+*ResellerApi* | [**CreateChildDomain**](docs/ResellerApi.md#CreateChildDomain) | **Post** /reseller/children/{childIdentifier}/domains | Create a domain for a child account
+*ResellerApi* | [**CreateResellerChild**](docs/ResellerApi.md#CreateResellerChild) | **Post** /reseller/children | Creates a reseller child
+*ResellerApi* | [**DeleteChildDomain**](docs/ResellerApi.md#DeleteChildDomain) | **Delete** /reseller/children/{childIdentifier}/domains/{domainName} | Delete the sender domain of the reseller child based on the childIdentifier and domainName passed
+*ResellerApi* | [**DeleteResellerChild**](docs/ResellerApi.md#DeleteResellerChild) | **Delete** /reseller/children/{childIdentifier} | Delete a single reseller child based on the child identifier supplied
+*ResellerApi* | [**DissociateIpFromChild**](docs/ResellerApi.md#DissociateIpFromChild) | **Post** /reseller/children/{childIdentifier}/ips/dissociate | Dissociate a dedicated IP to the child
+*ResellerApi* | [**GetChildAccountCreationStatus**](docs/ResellerApi.md#GetChildAccountCreationStatus) | **Get** /reseller/children/{childIdentifier}/accountCreationStatus | Get the status of a reseller's child account creation, whether it is successfully created (exists) or not based on the identifier supplied
+*ResellerApi* | [**GetChildDomains**](docs/ResellerApi.md#GetChildDomains) | **Get** /reseller/children/{childIdentifier}/domains | Get all sender domains for a specific child account
+*ResellerApi* | [**GetChildInfo**](docs/ResellerApi.md#GetChildInfo) | **Get** /reseller/children/{childIdentifier} | Get a child account's details
+*ResellerApi* | [**GetResellerChilds**](docs/ResellerApi.md#GetResellerChilds) | **Get** /reseller/children | Get the list of all children accounts
+*ResellerApi* | [**GetSsoToken**](docs/ResellerApi.md#GetSsoToken) | **Get** /reseller/children/{childIdentifier}/auth | Get session token to access Sendinblue (SSO)
+*ResellerApi* | [**RemoveCredits**](docs/ResellerApi.md#RemoveCredits) | **Post** /reseller/children/{childIdentifier}/credits/remove | Remove Email and/or SMS credits from a specific child account
+*ResellerApi* | [**UpdateChildAccountStatus**](docs/ResellerApi.md#UpdateChildAccountStatus) | **Put** /reseller/children/{childIdentifier}/accountStatus | Update info of reseller's child account status based on the childIdentifier supplied
+*ResellerApi* | [**UpdateChildDomain**](docs/ResellerApi.md#UpdateChildDomain) | **Put** /reseller/children/{childIdentifier}/domains/{domainName} | Update the sender domain of reseller's child based on the childIdentifier and domainName passed
+*ResellerApi* | [**UpdateResellerChild**](docs/ResellerApi.md#UpdateResellerChild) | **Put** /reseller/children/{childIdentifier} | Update info of reseller's child based on the child identifier supplied
+*SMSCampaignsApi* | [**CreateSmsCampaign**](docs/SMSCampaignsApi.md#CreateSmsCampaign) | **Post** /smsCampaigns | Creates an SMS campaign
+*SMSCampaignsApi* | [**DeleteSmsCampaign**](docs/SMSCampaignsApi.md#DeleteSmsCampaign) | **Delete** /smsCampaigns/{campaignId} | Delete an SMS campaign
+*SMSCampaignsApi* | [**GetSmsCampaign**](docs/SMSCampaignsApi.md#GetSmsCampaign) | **Get** /smsCampaigns/{campaignId} | Get an SMS campaign
+*SMSCampaignsApi* | [**GetSmsCampaigns**](docs/SMSCampaignsApi.md#GetSmsCampaigns) | **Get** /smsCampaigns | Returns the information for all your created SMS campaigns
+*SMSCampaignsApi* | [**RequestSmsRecipientExport**](docs/SMSCampaignsApi.md#RequestSmsRecipientExport) | **Post** /smsCampaigns/{campaignId}/exportRecipients | Export an SMS campaign's recipients
+*SMSCampaignsApi* | [**SendSmsCampaignNow**](docs/SMSCampaignsApi.md#SendSmsCampaignNow) | **Post** /smsCampaigns/{campaignId}/sendNow | Send your SMS campaign immediately
+*SMSCampaignsApi* | [**SendSmsReport**](docs/SMSCampaignsApi.md#SendSmsReport) | **Post** /smsCampaigns/{campaignId}/sendReport | Send an SMS campaign's report
+*SMSCampaignsApi* | [**SendTestSms**](docs/SMSCampaignsApi.md#SendTestSms) | **Post** /smsCampaigns/{campaignId}/sendTest | Send a test SMS campaign
+*SMSCampaignsApi* | [**UpdateSmsCampaign**](docs/SMSCampaignsApi.md#UpdateSmsCampaign) | **Put** /smsCampaigns/{campaignId} | Update an SMS campaign
+*SMSCampaignsApi* | [**UpdateSmsCampaignStatus**](docs/SMSCampaignsApi.md#UpdateSmsCampaignStatus) | **Put** /smsCampaigns/{campaignId}/status | Update a campaign's status
+*SendersApi* | [**CreateSender**](docs/SendersApi.md#CreateSender) | **Post** /senders | Create a new sender
+*SendersApi* | [**DeleteSender**](docs/SendersApi.md#DeleteSender) | **Delete** /senders/{senderId} | Delete a sender
+*SendersApi* | [**GetIps**](docs/SendersApi.md#GetIps) | **Get** /senders/ips | Get all the dedicated IPs for your account
+*SendersApi* | [**GetIpsFromSender**](docs/SendersApi.md#GetIpsFromSender) | **Get** /senders/{senderId}/ips | Get all the dedicated IPs for a sender
+*SendersApi* | [**GetSenders**](docs/SendersApi.md#GetSenders) | **Get** /senders | Get the list of all your senders
+*SendersApi* | [**UpdateSender**](docs/SendersApi.md#UpdateSender) | **Put** /senders/{senderId} | Update a sender
+*TasksApi* | [**CrmTasksGet**](docs/TasksApi.md#CrmTasksGet) | **Get** /crm/tasks | Get all tasks
+*TasksApi* | [**CrmTasksIdDelete**](docs/TasksApi.md#CrmTasksIdDelete) | **Delete** /crm/tasks/{id} | Delete a task
+*TasksApi* | [**CrmTasksIdGet**](docs/TasksApi.md#CrmTasksIdGet) | **Get** /crm/tasks/{id} | Get a task
+*TasksApi* | [**CrmTasksIdPatch**](docs/TasksApi.md#CrmTasksIdPatch) | **Patch** /crm/tasks/{id} | Update a task
+*TasksApi* | [**CrmTasksPost**](docs/TasksApi.md#CrmTasksPost) | **Post** /crm/tasks | Create a task
+*TasksApi* | [**CrmTasktypesGet**](docs/TasksApi.md#CrmTasktypesGet) | **Get** /crm/tasktypes | Get all task types
+*TransactionalEmailsApi* | [**BlockNewDomain**](docs/TransactionalEmailsApi.md#BlockNewDomain) | **Post** /smtp/blockedDomains | Add a new domain to the list of blocked domains
+*TransactionalEmailsApi* | [**CreateSmtpTemplate**](docs/TransactionalEmailsApi.md#CreateSmtpTemplate) | **Post** /smtp/templates | Create an email template
+*TransactionalEmailsApi* | [**DeleteBlockedDomain**](docs/TransactionalEmailsApi.md#DeleteBlockedDomain) | **Delete** /smtp/blockedDomains/{domain} | Unblock an existing domain from the list of blocked domains
+*TransactionalEmailsApi* | [**DeleteHardbounces**](docs/TransactionalEmailsApi.md#DeleteHardbounces) | **Post** /smtp/deleteHardbounces | Delete hardbounces
+*TransactionalEmailsApi* | [**DeleteScheduledEmailById**](docs/TransactionalEmailsApi.md#DeleteScheduledEmailById) | **Delete** /smtp/email/{identifier} | Delete scheduled emails by batchId or messageId
+*TransactionalEmailsApi* | [**DeleteSmtpTemplate**](docs/TransactionalEmailsApi.md#DeleteSmtpTemplate) | **Delete** /smtp/templates/{templateId} | Delete an inactive email template
+*TransactionalEmailsApi* | [**GetAggregatedSmtpReport**](docs/TransactionalEmailsApi.md#GetAggregatedSmtpReport) | **Get** /smtp/statistics/aggregatedReport | Get your transactional email activity aggregated over a period of time
+*TransactionalEmailsApi* | [**GetBlockedDomains**](docs/TransactionalEmailsApi.md#GetBlockedDomains) | **Get** /smtp/blockedDomains | Get the list of blocked domains
+*TransactionalEmailsApi* | [**GetEmailEventReport**](docs/TransactionalEmailsApi.md#GetEmailEventReport) | **Get** /smtp/statistics/events | Get all your transactional email activity (unaggregated events)
+*TransactionalEmailsApi* | [**GetScheduledEmailByBatchId**](docs/TransactionalEmailsApi.md#GetScheduledEmailByBatchId) | **Get** /smtp/emailStatus/{batchId} | Fetch scheduled emails by batchId
+*TransactionalEmailsApi* | [**GetScheduledEmailByMessageId**](docs/TransactionalEmailsApi.md#GetScheduledEmailByMessageId) | **Get** /smtp/emailStatus/{messageId} | Fetch scheduled email by messageId
+*TransactionalEmailsApi* | [**GetSmtpReport**](docs/TransactionalEmailsApi.md#GetSmtpReport) | **Get** /smtp/statistics/reports | Get your transactional email activity aggregated per day
+*TransactionalEmailsApi* | [**GetSmtpTemplate**](docs/TransactionalEmailsApi.md#GetSmtpTemplate) | **Get** /smtp/templates/{templateId} | Returns the template information
+*TransactionalEmailsApi* | [**GetSmtpTemplates**](docs/TransactionalEmailsApi.md#GetSmtpTemplates) | **Get** /smtp/templates | Get the list of email templates
+*TransactionalEmailsApi* | [**GetTransacBlockedContacts**](docs/TransactionalEmailsApi.md#GetTransacBlockedContacts) | **Get** /smtp/blockedContacts | Get the list of blocked or unsubscribed transactional contacts
+*TransactionalEmailsApi* | [**GetTransacEmailContent**](docs/TransactionalEmailsApi.md#GetTransacEmailContent) | **Get** /smtp/emails/{uuid} | Get the personalized content of a sent transactional email
+*TransactionalEmailsApi* | [**GetTransacEmailsList**](docs/TransactionalEmailsApi.md#GetTransacEmailsList) | **Get** /smtp/emails | Get the list of transactional emails on the basis of allowed filters
+*TransactionalEmailsApi* | [**SendTestTemplate**](docs/TransactionalEmailsApi.md#SendTestTemplate) | **Post** /smtp/templates/{templateId}/sendTest | Send a template to your test list
+*TransactionalEmailsApi* | [**SendTransacEmail**](docs/TransactionalEmailsApi.md#SendTransacEmail) | **Post** /smtp/email | Send a transactional email
+*TransactionalEmailsApi* | [**SmtpBlockedContactsEmailDelete**](docs/TransactionalEmailsApi.md#SmtpBlockedContactsEmailDelete) | **Delete** /smtp/blockedContacts/{email} | Unblock or resubscribe a transactional contact
+*TransactionalEmailsApi* | [**SmtpLogMessageIdDelete**](docs/TransactionalEmailsApi.md#SmtpLogMessageIdDelete) | **Delete** /smtp/log/{messageId} | Delete an SMTP transactional log
+*TransactionalEmailsApi* | [**UpdateSmtpTemplate**](docs/TransactionalEmailsApi.md#UpdateSmtpTemplate) | **Put** /smtp/templates/{templateId} | Update an email template
+*TransactionalSMSApi* | [**GetSmsEvents**](docs/TransactionalSMSApi.md#GetSmsEvents) | **Get** /transactionalSMS/statistics/events | Get all your SMS activity (unaggregated events)
+*TransactionalSMSApi* | [**GetTransacAggregatedSmsReport**](docs/TransactionalSMSApi.md#GetTransacAggregatedSmsReport) | **Get** /transactionalSMS/statistics/aggregatedReport | Get your SMS activity aggregated over a period of time
+*TransactionalSMSApi* | [**GetTransacSmsReport**](docs/TransactionalSMSApi.md#GetTransacSmsReport) | **Get** /transactionalSMS/statistics/reports | Get your SMS activity aggregated per day
+*TransactionalSMSApi* | [**SendTransacSms**](docs/TransactionalSMSApi.md#SendTransacSms) | **Post** /transactionalSMS/sms | Send SMS message to a mobile number
+*WebhooksApi* | [**CreateWebhook**](docs/WebhooksApi.md#CreateWebhook) | **Post** /webhooks | Create a webhook
+*WebhooksApi* | [**DeleteWebhook**](docs/WebhooksApi.md#DeleteWebhook) | **Delete** /webhooks/{webhookId} | Delete a webhook
+*WebhooksApi* | [**GetWebhook**](docs/WebhooksApi.md#GetWebhook) | **Get** /webhooks/{webhookId} | Get a webhook details
+*WebhooksApi* | [**GetWebhooks**](docs/WebhooksApi.md#GetWebhooks) | **Get** /webhooks | Get all webhooks
+*WebhooksApi* | [**UpdateWebhook**](docs/WebhooksApi.md#UpdateWebhook) | **Put** /webhooks/{webhookId} | Update a webhook
## Documentation For Models
@@ -235,12 +267,24 @@ Class | Method | HTTP request | Description
- [Body4](docs/Body4.md)
- [Body5](docs/Body5.md)
- [Body6](docs/Body6.md)
+ - [Body7](docs/Body7.md)
+ - [Body8](docs/Body8.md)
+ - [Body9](docs/Body9.md)
+ - [Body10](docs/Body10.md)
+ - [Body11](docs/Body11.md)
+ - [Body12](docs/Body12.md)
- [CompaniesList](docs/CompaniesList.md)
- [Company](docs/Company.md)
- [CompanyAttributes](docs/CompanyAttributes.md)
- [CompanyAttributesInner](docs/CompanyAttributesInner.md)
+ - [ConversationsMessage](docs/ConversationsMessage.md)
+ - [ConversationsMessageFile](docs/ConversationsMessageFile.md)
+ - [ConversationsMessageFileImageInfo](docs/ConversationsMessageFileImageInfo.md)
+ - [CreateApiKeyRequest](docs/CreateApiKeyRequest.md)
+ - [CreateApiKeyResponse](docs/CreateApiKeyResponse.md)
- [CreateAttribute](docs/CreateAttribute.md)
- [CreateAttributeEnumeration](docs/CreateAttributeEnumeration.md)
+ - [CreateCategoryModel](docs/CreateCategoryModel.md)
- [CreateChild](docs/CreateChild.md)
- [CreateContact](docs/CreateContact.md)
- [CreateDoiContact](docs/CreateDoiContact.md)
@@ -249,6 +293,7 @@ Class | Method | HTTP request | Description
- [CreateEmailCampaignSender](docs/CreateEmailCampaignSender.md)
- [CreateList](docs/CreateList.md)
- [CreateModel](docs/CreateModel.md)
+ - [CreateProductModel](docs/CreateProductModel.md)
- [CreateReseller](docs/CreateReseller.md)
- [CreateSender](docs/CreateSender.md)
- [CreateSenderIps](docs/CreateSenderIps.md)
@@ -260,9 +305,18 @@ Class | Method | HTTP request | Description
- [CreateSmtpTemplateSender](docs/CreateSmtpTemplateSender.md)
- [CreateSubAccount](docs/CreateSubAccount.md)
- [CreateSubAccountResponse](docs/CreateSubAccountResponse.md)
+ - [CreateUpdateBatchCategory](docs/CreateUpdateBatchCategory.md)
+ - [CreateUpdateBatchCategoryModel](docs/CreateUpdateBatchCategoryModel.md)
+ - [CreateUpdateBatchProducts](docs/CreateUpdateBatchProducts.md)
+ - [CreateUpdateBatchProductsModel](docs/CreateUpdateBatchProductsModel.md)
+ - [CreateUpdateCategories](docs/CreateUpdateCategories.md)
+ - [CreateUpdateCategory](docs/CreateUpdateCategory.md)
- [CreateUpdateContactModel](docs/CreateUpdateContactModel.md)
- [CreateUpdateFolder](docs/CreateUpdateFolder.md)
+ - [CreateUpdateProduct](docs/CreateUpdateProduct.md)
+ - [CreateUpdateProducts](docs/CreateUpdateProducts.md)
- [CreateWebhook](docs/CreateWebhook.md)
+ - [CreatedBatchId](docs/CreatedBatchId.md)
- [CreatedProcessId](docs/CreatedProcessId.md)
- [Deal](docs/Deal.md)
- [DealAttributes](docs/DealAttributes.md)
@@ -271,6 +325,9 @@ Class | Method | HTTP request | Description
- [DeleteHardbounces](docs/DeleteHardbounces.md)
- [EmailExportRecipients](docs/EmailExportRecipients.md)
- [ErrorModel](docs/ErrorModel.md)
+ - [FileData](docs/FileData.md)
+ - [FileDownloadableLink](docs/FileDownloadableLink.md)
+ - [FileList](docs/FileList.md)
- [GetAccountMarketingAutomation](docs/GetAccountMarketingAutomation.md)
- [GetAccountPlan](docs/GetAccountPlan.md)
- [GetAccountRelay](docs/GetAccountRelay.md)
@@ -283,6 +340,8 @@ Class | Method | HTTP request | Description
- [GetCampaignOverview](docs/GetCampaignOverview.md)
- [GetCampaignRecipients](docs/GetCampaignRecipients.md)
- [GetCampaignStats](docs/GetCampaignStats.md)
+ - [GetCategories](docs/GetCategories.md)
+ - [GetCategoryDetails](docs/GetCategoryDetails.md)
- [GetChildAccountCreationStatus](docs/GetChildAccountCreationStatus.md)
- [GetChildDomain](docs/GetChildDomain.md)
- [GetChildDomains](docs/GetChildDomains.md)
@@ -333,6 +392,8 @@ Class | Method | HTTP request | Description
- [GetLists](docs/GetLists.md)
- [GetProcess](docs/GetProcess.md)
- [GetProcesses](docs/GetProcesses.md)
+ - [GetProductDetails](docs/GetProductDetails.md)
+ - [GetProducts](docs/GetProducts.md)
- [GetReports](docs/GetReports.md)
- [GetReportsReports](docs/GetReportsReports.md)
- [GetScheduledEmailByBatchId](docs/GetScheduledEmailByBatchId.md)
@@ -380,6 +441,10 @@ Class | Method | HTTP request | Description
- [NoteData](docs/NoteData.md)
- [NoteId](docs/NoteId.md)
- [NoteList](docs/NoteList.md)
+ - [Order](docs/Order.md)
+ - [OrderBatch](docs/OrderBatch.md)
+ - [OrderBilling](docs/OrderBilling.md)
+ - [OrderProducts](docs/OrderProducts.md)
- [Pipeline](docs/Pipeline.md)
- [PipelineStage](docs/PipelineStage.md)
- [PostContactInfo](docs/PostContactInfo.md)
@@ -450,6 +515,7 @@ Class | Method | HTTP request | Description
- [UpdateSmtpTemplate](docs/UpdateSmtpTemplate.md)
- [UpdateSmtpTemplateSender](docs/UpdateSmtpTemplateSender.md)
- [UpdateWebhook](docs/UpdateWebhook.md)
+ - [UploadImageModel](docs/UploadImageModel.md)
- [UploadImageToGallery](docs/UploadImageToGallery.md)
- [GetChildInfo](docs/GetChildInfo.md)
- [GetExtendedCampaignOverview](docs/GetExtendedCampaignOverview.md)
diff --git a/api/swagger.yaml b/api/swagger.yaml
index a667194..c7df75e 100644
--- a/api/swagger.yaml
+++ b/api/swagger.yaml
@@ -91,6 +91,7 @@ paths:
type: "integer"
default: 50
maximum: 100
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -804,6 +805,8 @@ paths:
responses:
"201":
description: "Image successfully uploaded"
+ schema:
+ $ref: "#/definitions/uploadImageModel"
"400":
description: "bad request"
schema:
@@ -907,6 +910,7 @@ paths:
type: "integer"
default: 500
maximum: 1000
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1023,6 +1027,7 @@ paths:
type: "integer"
default: 50
maximum: 1000
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1324,6 +1329,7 @@ paths:
type: "integer"
default: 10
maximum: 30
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1431,8 +1437,9 @@ paths:
description: "Number limitation for the result returned"
required: false
type: "integer"
- default: 50
- maximum: 100
+ default: 2500
+ maximum: 5000
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1614,6 +1621,7 @@ paths:
type: "integer"
default: 50
maximum: 100
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1818,6 +1826,7 @@ paths:
type: "integer"
default: 100
maximum: 500
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -1950,6 +1959,7 @@ paths:
type: "integer"
default: 50
maximum: 1000
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -2340,7 +2350,6 @@ paths:
get:
tags:
- "Contacts"
- - "Attributes"
summary: "List all attributes"
operationId: "getAttributes"
parameters: []
@@ -2375,7 +2384,6 @@ paths:
post:
tags:
- "Contacts"
- - "Attributes"
summary: "Create contact attribute"
operationId: "createAttribute"
parameters:
@@ -2414,7 +2422,6 @@ paths:
put:
tags:
- "Contacts"
- - "Attributes"
summary: "Update contact attribute"
operationId: "updateAttribute"
parameters:
@@ -2455,7 +2462,6 @@ paths:
delete:
tags:
- "Contacts"
- - "Attributes"
summary: "Delete an attribute"
operationId: "deleteAttribute"
parameters:
@@ -2492,7 +2498,6 @@ paths:
get:
tags:
- "Contacts"
- - "Folders"
summary: "Get all folders"
operationId: "getFolders"
parameters:
@@ -2503,6 +2508,7 @@ paths:
type: "integer"
default: 10
maximum: 50
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
- name: "offset"
@@ -2551,7 +2557,6 @@ paths:
post:
tags:
- "Contacts"
- - "Folders"
summary: "Create a folder"
operationId: "createFolder"
parameters:
@@ -2575,7 +2580,6 @@ paths:
get:
tags:
- "Contacts"
- - "Folders"
summary: "Returns a folder's details"
operationId: "getFolder"
parameters:
@@ -2609,7 +2613,6 @@ paths:
put:
tags:
- "Contacts"
- - "Folders"
summary: "Update a folder"
operationId: "updateFolder"
parameters:
@@ -2641,7 +2644,6 @@ paths:
delete:
tags:
- "Contacts"
- - "Folders"
summary: "Delete a folder (and all its lists)"
operationId: "deleteFolder"
parameters:
@@ -2667,8 +2669,6 @@ paths:
get:
tags:
- "Contacts"
- - "Folders"
- - "Lists"
summary: "Get lists in a folder"
operationId: "getFolderLists"
parameters:
@@ -2686,6 +2686,7 @@ paths:
type: "integer"
default: 10
maximum: 50
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -2746,7 +2747,6 @@ paths:
get:
tags:
- "Contacts"
- - "Lists"
summary: "Get all the lists"
operationId: "getLists"
parameters:
@@ -2757,6 +2757,7 @@ paths:
type: "integer"
default: 10
maximum: 50
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -2809,7 +2810,6 @@ paths:
post:
tags:
- "Contacts"
- - "Lists"
summary: "Create a list"
operationId: "createList"
parameters:
@@ -2833,7 +2833,6 @@ paths:
get:
tags:
- "Contacts"
- - "Lists"
summary: "Get a list's details"
operationId: "getList"
parameters:
@@ -2897,7 +2896,6 @@ paths:
put:
tags:
- "Contacts"
- - "Lists"
summary: "Update a list"
operationId: "updateList"
parameters:
@@ -2929,7 +2927,6 @@ paths:
delete:
tags:
- "Contacts"
- - "Lists"
summary: "Delete a list"
operationId: "deleteList"
parameters:
@@ -2955,7 +2952,6 @@ paths:
get:
tags:
- "Contacts"
- - "Lists"
summary: "Get contacts in a list"
operationId: "getContactsFromList"
parameters:
@@ -2982,6 +2978,7 @@ paths:
type: "integer"
default: 50
maximum: 500
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -3078,7 +3075,6 @@ paths:
post:
tags:
- "Contacts"
- - "Lists"
summary: "Add existing contacts to a list"
operationId: "addContactToList"
parameters:
@@ -3114,7 +3110,6 @@ paths:
post:
tags:
- "Contacts"
- - "Lists"
summary: "Delete a contact from a list"
operationId: "removeContactFromList"
parameters:
@@ -3246,6 +3241,7 @@ paths:
type: "integer"
default: 500
maximum: 1000
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -4309,6 +4305,7 @@ paths:
type: "integer"
default: 10
maximum: 20
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -4984,6 +4981,7 @@ paths:
type: "integer"
default: 10
maximum: 50
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -5113,6 +5111,7 @@ paths:
type: "integer"
default: 100
maximum: 500
+ minimum: 0
format: "int64"
x-exportParamName: "Limit"
x-optionalDataType: "Int64"
@@ -5201,6 +5200,44 @@ paths:
description: "bad request"
schema:
$ref: "#/definitions/errorModel"
+ /inbound/attachments/{downloadToken}:
+ get:
+ tags:
+ - "Inbound Parsing"
+ summary: "Retrieve inbound attachment with download token."
+ description: "This endpoint will retrieve inbound attachment with download token."
+ operationId: "getInboundEmailAttachment"
+ parameters:
+ - name: "downloadToken"
+ in: "path"
+ description: "Token to fetch a particular attachment"
+ required: true
+ type: "string"
+ x-exportParamName: "DownloadToken"
+ responses:
+ "200":
+ description: "Attachment information"
+ headers:
+ Content-Type:
+ type: "string"
+ description: "example: image/png"
+ Content-Disposition:
+ type: "string"
+ description: "example: attachment; filename=\"download.png\""
+ Content-Length:
+ type: "integer"
+ description: "example: 4032"
+ schema:
+ type: "file"
+ format: "binary"
+ "400":
+ description: "bad request"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "attachment not found"
+ schema:
+ $ref: "#/definitions/errorModel"
/corporate/subAccount:
get:
tags:
@@ -5386,7 +5423,7 @@ paths:
- "Master account"
summary: "Generate SSO token to access Sendinblue"
description: "This endpoint generates an sso token to authenticate and access\
- \ a sub-account of the master using the account endpoint https://app.sendinblue.com/account/login/sub-account/sso/[token],\
+ \ a sub-account of the master using the account endpoint https://account-app.sendinblue.com/account/login/sub-account/sso/[token],\
\ where [token] will be replaced by the actual token."
parameters:
- in: "body"
@@ -5487,212 +5524,35 @@ paths:
description: "bad request"
schema:
$ref: "#/definitions/errorModel"
- /crm/pipeline/details:
- get:
- tags:
- - "Deals"
- summary: "Get pipeline stages"
- parameters: []
- responses:
- "200":
- description: "Returns list of pipeline stages"
- schema:
- $ref: "#/definitions/Pipeline"
- /crm/attributes/deals:
- get:
- tags:
- - "Deals"
- summary: "Get deal attributes"
- parameters: []
- responses:
- "200":
- description: "Returns list of deal attributes"
- schema:
- $ref: "#/definitions/DealAttributes"
- /crm/deals:
- get:
- tags:
- - "Deals"
- summary: "Get all deals"
- parameters:
- - name: "filter[attributes]"
- in: "query"
- description: "Filter by attrbutes. If you have filter for owner on your side\
- \ please send it as `attributes.owner`.\""
- required: false
- type: "string"
- x-exportParamName: "FilterAttributes"
- x-optionalDataType: "String"
- - name: "filter[linkedCompaniesIds]"
- in: "query"
- description: "Filter by linked companies ids"
- required: false
- type: "string"
- x-exportParamName: "FilterLinkedCompaniesIds"
- x-optionalDataType: "String"
- - name: "filter[linkedContactsIds]"
- in: "query"
- description: "Filter by linked companies ids"
- required: false
- type: "string"
- x-exportParamName: "FilterLinkedContactsIds"
- x-optionalDataType: "String"
- - name: "offset"
- in: "query"
- description: "Index of the first document of the page"
- required: false
- type: "integer"
- format: "int64"
- x-exportParamName: "Offset"
- x-optionalDataType: "Int64"
- - name: "limit"
- in: "query"
- description: "Number of documents per page"
- required: false
- type: "integer"
- default: 50
- format: "int64"
- x-exportParamName: "Limit"
- x-optionalDataType: "Int64"
- - name: "sort"
- in: "query"
- description: "Sort the results in the ascending/descending order. Default\
- \ order is **descending** by creation if `sort` is not passed"
- required: false
- type: "string"
- enum:
- - "asc"
- - "desc"
- x-exportParamName: "Sort"
- x-optionalDataType: "String"
- - name: "sortBy"
- in: "query"
- description: "The field used to sort field names."
- required: false
- type: "string"
- x-exportParamName: "SortBy"
- x-optionalDataType: "String"
- responses:
- "200":
- description: "Returns deals list with filters"
- schema:
- $ref: "#/definitions/DealsList"
- "400":
- description: "Returned when query params are invalid"
- examples:
- response:
- value:
- message: "Not valid data."
- schema:
- $ref: "#/definitions/errorModel"
+ /corporate/subAccount/key:
post:
tags:
- - "Deals"
- summary: "Create a deal"
+ - "Master account"
+ summary: "Create an API key for a sub-account"
+ description: "This endpoint will generate an API v3 key for a sub account"
parameters:
- in: "body"
- name: "body"
- description: "Deal create data."
+ name: "createApiKeyRequest"
+ description: "Values to generate API key for sub-account"
required: true
schema:
- $ref: "#/definitions/body"
- x-exportParamName: "Body"
+ $ref: "#/definitions/createApiKeyRequest"
+ x-exportParamName: "CreateApiKeyRequest"
responses:
"201":
- description: "Created new Deal"
- schema:
- $ref: "#/definitions/inline_response_201"
- "400":
- description: "Returned when invalid data posted"
- /crm/deals/{id}:
- get:
- tags:
- - "Deals"
- summary: "Get a deal"
- parameters:
- - name: "id"
- in: "path"
- required: true
- type: "string"
- x-exportParamName: "Id"
- responses:
- "200":
- description: "Returns the deal by id"
- schema:
- $ref: "#/definitions/Deal"
- "400":
- description: "Returned when task id is invalid"
- examples:
- application/json:
- message: "Route attribute id is not valid."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when item not found"
- examples:
- application/json:
- message: "Document not found"
- schema:
- $ref: "#/definitions/errorModel"
- delete:
- tags:
- - "Deals"
- summary: "Delete a deal"
- parameters:
- - name: "id"
- in: "path"
- required: true
- type: "string"
- x-exportParamName: "Id"
- responses:
- "204":
- description: "Returned when item deleted"
- "400":
- description: "Returned when invalid data posted"
+ description: "API Key"
examples:
application/json:
- message: "Route attribute id is not valid."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when deal id is not found"
- examples:
- application/json:
- message: "Document not found"
+ status: "success"
+ key: "xkeysib-21881axxxxxcc92e04-mIrexxxx7z"
schema:
- $ref: "#/definitions/errorModel"
- patch:
- tags:
- - "Deals"
- summary: "Update a deal"
- parameters:
- - name: "id"
- in: "path"
- required: true
- type: "string"
- x-exportParamName: "Id"
- - in: "body"
- name: "body"
- description: "Updated deal details."
- required: true
- schema:
- $ref: "#/definitions/body_1"
- x-exportParamName: "Body"
- responses:
- "204":
- description: "Deal updated successfully"
+ $ref: "#/definitions/createApiKeyResponse"
"400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Route attribute id is not valid."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when deal id is not found"
+ description: "bad request"
examples:
application/json:
- message: "Document not found"
+ code: "invalid_parameter"
+ message: "id should be a positive number"
schema:
$ref: "#/definitions/errorModel"
/companies:
@@ -5783,7 +5643,7 @@ paths:
description: "Company create data."
required: true
schema:
- $ref: "#/definitions/body_2"
+ $ref: "#/definitions/body"
x-exportParamName: "Body"
responses:
"200":
@@ -5864,7 +5724,7 @@ paths:
description: "Updated company details."
required: true
schema:
- $ref: "#/definitions/body_3"
+ $ref: "#/definitions/body_1"
x-exportParamName: "Body"
responses:
"200":
@@ -5912,7 +5772,7 @@ paths:
description: "Linked / Unlinked contacts and deals ids."
required: true
schema:
- $ref: "#/definitions/body_4"
+ $ref: "#/definitions/body_2"
x-exportParamName: "Body"
responses:
"204":
@@ -5925,24 +5785,262 @@ paths:
message: "Not valid data."
schema:
$ref: "#/definitions/errorModel"
- /crm/tasktypes:
+ /crm/pipeline/details:
get:
tags:
- - "CRM"
- summary: "Get all task types"
+ - "Deals"
+ summary: "Get pipeline stages"
parameters: []
responses:
"200":
- description: "Returns all the Task types"
+ description: "Returns list of pipeline stages"
schema:
- $ref: "#/definitions/TaskTypes"
- /crm/tasks:
+ $ref: "#/definitions/Pipeline"
+ /crm/attributes/deals:
get:
tags:
- - "CRM"
- summary: "Get all tasks"
+ - "Deals"
+ summary: "Get deal attributes"
+ parameters: []
+ responses:
+ "200":
+ description: "Returns list of deal attributes"
+ schema:
+ $ref: "#/definitions/DealAttributes"
+ /crm/deals:
+ get:
+ tags:
+ - "Deals"
+ summary: "Get all deals"
parameters:
- - name: "filter[type]"
+ - name: "filters[attributes]"
+ in: "query"
+ description: "Filter by attrbutes. If you have filter for owner on your side\
+ \ please send it as `attributes.owner`.\""
+ required: false
+ type: "string"
+ x-exportParamName: "FiltersAttributes"
+ x-optionalDataType: "String"
+ - name: "filters[linkedCompaniesIds]"
+ in: "query"
+ description: "Filter by linked companies ids"
+ required: false
+ type: "string"
+ x-exportParamName: "FiltersLinkedCompaniesIds"
+ x-optionalDataType: "String"
+ - name: "filters[linkedContactsIds]"
+ in: "query"
+ description: "Filter by linked companies ids"
+ required: false
+ type: "string"
+ x-exportParamName: "FiltersLinkedContactsIds"
+ x-optionalDataType: "String"
+ - name: "offset"
+ in: "query"
+ description: "Index of the first document of the page"
+ required: false
+ type: "integer"
+ format: "int64"
+ x-exportParamName: "Offset"
+ x-optionalDataType: "Int64"
+ - name: "limit"
+ in: "query"
+ description: "Number of documents per page"
+ required: false
+ type: "integer"
+ default: 50
+ format: "int64"
+ x-exportParamName: "Limit"
+ x-optionalDataType: "Int64"
+ - name: "sort"
+ in: "query"
+ description: "Sort the results in the ascending/descending order. Default\
+ \ order is **descending** by creation if `sort` is not passed"
+ required: false
+ type: "string"
+ enum:
+ - "asc"
+ - "desc"
+ x-exportParamName: "Sort"
+ x-optionalDataType: "String"
+ - name: "sortBy"
+ in: "query"
+ description: "The field used to sort field names."
+ required: false
+ type: "string"
+ x-exportParamName: "SortBy"
+ x-optionalDataType: "String"
+ responses:
+ "200":
+ description: "Returns deals list with filters"
+ schema:
+ $ref: "#/definitions/DealsList"
+ "400":
+ description: "Returned when query params are invalid"
+ examples:
+ response:
+ value:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ post:
+ tags:
+ - "Deals"
+ summary: "Create a deal"
+ parameters:
+ - in: "body"
+ name: "body"
+ description: "Deal create data."
+ required: true
+ schema:
+ $ref: "#/definitions/body_3"
+ x-exportParamName: "Body"
+ responses:
+ "201":
+ description: "Created new Deal"
+ schema:
+ $ref: "#/definitions/inline_response_201"
+ "400":
+ description: "Returned when invalid data posted"
+ /crm/deals/{id}:
+ get:
+ tags:
+ - "Deals"
+ summary: "Get a deal"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Returns the deal by id"
+ schema:
+ $ref: "#/definitions/Deal"
+ "400":
+ description: "Returned when task id is invalid"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Deals"
+ summary: "Delete a deal"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "Returned when item deleted"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when deal id is not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ patch:
+ tags:
+ - "Deals"
+ summary: "Update a deal"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ description: "Updated deal details."
+ required: true
+ schema:
+ $ref: "#/definitions/body_4"
+ x-exportParamName: "Body"
+ responses:
+ "204":
+ description: "Deal updated successfully"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when deal id is not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/deals/link-unlink/{id}:
+ patch:
+ tags:
+ - "Deals"
+ summary: "Link and Unlink a deal with contacts and companies"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ description: "Linked / Unlinked contacts and companies ids."
+ required: true
+ schema:
+ $ref: "#/definitions/body_5"
+ x-exportParamName: "Body"
+ responses:
+ "204":
+ description: "Successfully linked/unlinked contacts/companies with the deal."
+ "400":
+ description: "Returned when query params are invalid or invalid data provided\
+ \ in request."
+ examples:
+ response:
+ value:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/tasktypes:
+ get:
+ tags:
+ - "Tasks"
+ summary: "Get all task types"
+ parameters: []
+ responses:
+ "200":
+ description: "Returns all the Task types"
+ schema:
+ $ref: "#/definitions/TaskTypes"
+ /crm/tasks:
+ get:
+ tags:
+ - "Tasks"
+ summary: "Get all tasks"
+ parameters:
+ - name: "filter[type]"
in: "query"
description: "Filter by task type (ID)"
required: false
@@ -6055,334 +6153,1181 @@ paths:
schema:
$ref: "#/definitions/TaskList"
"400":
- description: "Returned when query params are invalid"
- examples:
- response:
- value:
- message: "Not valid data."
+ description: "Returned when query params are invalid"
+ examples:
+ response:
+ value:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ post:
+ tags:
+ - "Tasks"
+ summary: "Create a task"
+ parameters:
+ - in: "body"
+ name: "body"
+ description: "Task name."
+ required: true
+ schema:
+ $ref: "#/definitions/body_6"
+ x-exportParamName: "Body"
+ responses:
+ "201":
+ description: "Created new task"
+ schema:
+ $ref: "#/definitions/inline_response_201_1"
+ "400":
+ description: "Returned when invalid data posted"
+ /crm/tasks/{id}:
+ get:
+ tags:
+ - "Tasks"
+ summary: "Get a task"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Returns the Task by id"
+ schema:
+ $ref: "#/definitions/Task"
+ "400":
+ description: "Returned when task id is invalid"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Tasks"
+ summary: "Delete a task"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "Returned when item deleted"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when task id is not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ patch:
+ tags:
+ - "Tasks"
+ summary: "Update a task"
+ parameters:
+ - name: "id"
+ in: "path"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ description: "Updated task details."
+ required: true
+ schema:
+ $ref: "#/definitions/body_7"
+ x-exportParamName: "Body"
+ responses:
+ "204":
+ description: "Task updated successfully"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when task id is not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/notes:
+ get:
+ tags:
+ - "Notes"
+ summary: "Get all notes"
+ parameters:
+ - name: "entity"
+ in: "query"
+ description: "Filter by note entity type"
+ required: false
+ type: "string"
+ enum:
+ - "companies"
+ - "deals"
+ - "contacts"
+ x-exportParamName: "Entity"
+ x-optionalDataType: "String"
+ - name: "entityIds"
+ in: "query"
+ description: "Filter by note entity IDs"
+ required: false
+ type: "string"
+ x-exportParamName: "EntityIds"
+ x-optionalDataType: "String"
+ - name: "dateFrom"
+ in: "query"
+ description: "dateFrom to date range filter type (timestamp in milliseconds)"
+ required: false
+ type: "integer"
+ x-exportParamName: "DateFrom"
+ x-optionalDataType: "Int32"
+ - name: "dateTo"
+ in: "query"
+ description: "dateTo to date range filter type (timestamp in milliseconds)"
+ required: false
+ type: "integer"
+ x-exportParamName: "DateTo"
+ x-optionalDataType: "Int32"
+ - name: "offset"
+ in: "query"
+ description: "Index of the first document of the page"
+ required: false
+ type: "integer"
+ format: "int64"
+ x-exportParamName: "Offset"
+ x-optionalDataType: "Int64"
+ - name: "limit"
+ in: "query"
+ description: "Number of documents per page"
+ required: false
+ type: "integer"
+ default: 50
+ format: "int64"
+ x-exportParamName: "Limit"
+ x-optionalDataType: "Int64"
+ - name: "sort"
+ in: "query"
+ description: "Sort the results in the ascending/descending order. Default\
+ \ order is **descending** by creation if `sort` is not passed"
+ required: false
+ type: "string"
+ enum:
+ - "asc"
+ - "desc"
+ x-exportParamName: "Sort"
+ x-optionalDataType: "String"
+ responses:
+ "200":
+ description: "Returns notes list with filters"
+ schema:
+ $ref: "#/definitions/NoteList"
+ "400":
+ description: "Returned when query params are invalid"
+ examples:
+ response:
+ value:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ post:
+ tags:
+ - "Notes"
+ summary: "Create a note"
+ parameters:
+ - in: "body"
+ name: "body"
+ description: "Note data to create a note."
+ required: true
+ schema:
+ $ref: "#/definitions/NoteData"
+ x-exportParamName: "Body"
+ responses:
+ "200":
+ description: "Created new note"
+ schema:
+ $ref: "#/definitions/NoteId"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "415":
+ description: "Format is not supported"
+ examples:
+ application/json:
+ message: "The format not supported for deserialization."
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/notes/{id}:
+ get:
+ tags:
+ - "Notes"
+ summary: "Get a note"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "Note ID to get"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Returns the Note by id"
+ schema:
+ $ref: "#/definitions/Note"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Notes"
+ summary: "Delete a note"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "Note ID to delete"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "Returned when item deleted"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ patch:
+ tags:
+ - "Notes"
+ summary: "Update a note"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "Note ID to update"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ description: "Note data to update a note"
+ required: true
+ schema:
+ $ref: "#/definitions/NoteData"
+ x-exportParamName: "Body"
+ responses:
+ "204":
+ description: "Note updated successfully"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "415":
+ description: "Format is not supported"
+ examples:
+ application/json:
+ message: "The format not supported for deserialization."
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/files:
+ get:
+ tags:
+ - "Files"
+ summary: "Get all files"
+ parameters:
+ - name: "entity"
+ in: "query"
+ description: "Filter by file entity type"
+ required: false
+ type: "string"
+ enum:
+ - "companies"
+ - "deals"
+ - "contacts"
+ x-exportParamName: "Entity"
+ x-optionalDataType: "String"
+ - name: "entityIds"
+ in: "query"
+ description: "Filter by file entity IDs"
+ required: false
+ type: "string"
+ x-exportParamName: "EntityIds"
+ x-optionalDataType: "String"
+ - name: "dateFrom"
+ in: "query"
+ description: "dateFrom to date range filter type (timestamp in milliseconds)"
+ required: false
+ type: "integer"
+ x-exportParamName: "DateFrom"
+ x-optionalDataType: "Int32"
+ - name: "dateTo"
+ in: "query"
+ description: "dateTo to date range filter type (timestamp in milliseconds)"
+ required: false
+ type: "integer"
+ x-exportParamName: "DateTo"
+ x-optionalDataType: "Int32"
+ - name: "offset"
+ in: "query"
+ description: "Index of the first document of the page"
+ required: false
+ type: "integer"
+ format: "int64"
+ x-exportParamName: "Offset"
+ x-optionalDataType: "Int64"
+ - name: "limit"
+ in: "query"
+ description: "Number of documents per page"
+ required: false
+ type: "integer"
+ default: 50
+ format: "int64"
+ x-exportParamName: "Limit"
+ x-optionalDataType: "Int64"
+ - name: "sort"
+ in: "query"
+ description: "Sort the results in the ascending/descending order. Default\
+ \ order is **descending** by creation if `sort` is not passed"
+ required: false
+ type: "string"
+ enum:
+ - "asc"
+ - "desc"
+ x-exportParamName: "Sort"
+ x-optionalDataType: "String"
+ responses:
+ "200":
+ description: "Returns files list with filters"
+ schema:
+ $ref: "#/definitions/FileList"
+ "400":
+ description: "Returned when query params are invalid"
+ examples:
+ application/json:
+ message: "Not valid data."
+ schema:
+ $ref: "#/definitions/errorModel"
+ post:
+ tags:
+ - "Files"
+ summary: "Upload a file"
+ consumes:
+ - "multipart/form-data"
+ parameters:
+ - name: "file"
+ in: "formData"
+ description: "File data to create a file."
+ required: true
+ type: "file"
+ x-exportParamName: "File"
+ - name: "dealId"
+ in: "formData"
+ description: "Deal id linked to a file"
+ required: false
+ type: "string"
+ x-exportParamName: "DealId"
+ x-optionalDataType: "String"
+ - name: "contactId"
+ in: "formData"
+ description: "Contact id linked to a file"
+ required: false
+ type: "integer"
+ format: "int64"
+ x-exportParamName: "ContactId"
+ x-optionalDataType: "Int64"
+ - name: "companyId"
+ in: "formData"
+ description: "Company id linked to a file"
+ required: false
+ type: "string"
+ x-exportParamName: "CompanyId"
+ x-optionalDataType: "String"
+ responses:
+ "201":
+ description: "Returns the created File with additional details"
+ schema:
+ $ref: "#/definitions/FileData"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Invalid deals ids format."
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/files/{id}:
+ get:
+ tags:
+ - "Files"
+ summary: "Download a file"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "File id to download."
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Returns downloadable file link. Valid for next 5 minutes only."
+ schema:
+ $ref: "#/definitions/FileDownloadableLink"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Files"
+ summary: "Delete a file"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "File id to delete."
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "Returned when file is deleted."
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /crm/files/{id}/data:
+ get:
+ tags:
+ - "Files"
+ summary: "Get file details"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "File id to get file data."
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Returned when file is found."
+ schema:
+ $ref: "#/definitions/FileData"
+ "400":
+ description: "Returned when invalid data posted"
+ examples:
+ application/json:
+ message: "Route attribute id is not valid"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ examples:
+ application/json:
+ message: "Document not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /conversations/messages:
+ post:
+ tags:
+ - "Conversations"
+ summary: "Send a message as an agent"
+ consumes:
+ - "application/json"
+ produces:
+ - "application/json"
+ parameters:
+ - in: "body"
+ name: "body"
+ description: "Message fields."
+ required: true
+ schema:
+ $ref: "#/definitions/body_8"
+ x-exportParamName: "Body"
+ responses:
+ "200":
+ description: "Newly created message is returned as a response"
+ examples:
+ application/json:
+ id: "eYBEm3gq3zc5ayE2g"
+ type: "agent"
+ text: "Hello! How can I help you?"
+ visitorId: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ agentId: "d9nKoegKSjmCtyK78"
+ createdAt: 1482512803740
+ receivedFrom: "SuperAwesomeHelpdesk"
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /conversations/messages/{id}:
+ get:
+ tags:
+ - "Conversations"
+ summary: "Get a message"
+ produces:
+ - "application/json"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Requested message is returned as a response"
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ put:
+ tags:
+ - "Conversations"
+ summary: "Update a message sent by an agent"
+ description: "Only agents’ messages can be edited."
+ consumes:
+ - "application/json"
+ produces:
+ - "application/json"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ required: false
+ schema:
+ $ref: "#/definitions/body_9"
+ x-exportParamName: "Body"
+ responses:
+ "200":
+ description: "Updated message is returned as a response"
+ examples:
+ application/json:
+ id: "eYBEm3gq3zc5ayE2g"
+ type: "agent"
+ text: "Hello! How can I help you?"
+ visitorId: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ agentId: "d9nKoegKSjmCtyK78"
+ createdAt: 1482512803740
+ receivedFrom: "SuperAwesomeHelpdesk"
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Conversations"
+ summary: "Delete a message sent by an agent"
+ description: "Only agents’ messages can be deleted."
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "The message was deleted from the conversation"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /conversations/pushedMessages:
+ post:
+ tags:
+ - "Conversations"
+ summary: "Send an automated message to a visitor"
+ description: "Example of automated messages: order status, announce new features\
+ \ in your web app, etc."
+ consumes:
+ - "application/json"
+ produces:
+ - "application/json"
+ parameters:
+ - in: "body"
+ name: "body"
+ required: true
+ schema:
+ $ref: "#/definitions/body_10"
+ x-exportParamName: "Body"
+ responses:
+ "200":
+ description: "Newly created message is returned as a response"
+ examples:
+ application/json:
+ id: "AXCR3k9bpSY7bpuh7"
+ type: "agent"
+ text: "Your order has shipped! Here’s your tracking number: 9114 5847\
+ \ 3325 9667 4328 88"
+ visitorId: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ agentId: "d9nKoegKSjmCtyK78"
+ createdAt: 1470222622433
+ isPushed: true
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /conversations/pushedMessages/{id}:
+ get:
+ tags:
+ - "Conversations"
+ summary: "Get an automated message"
+ produces:
+ - "application/json"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message sent previously"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "200":
+ description: "Requested message is returned as a response"
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ put:
+ tags:
+ - "Conversations"
+ summary: "Update an automated message"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ - in: "body"
+ name: "body"
+ required: true
+ schema:
+ $ref: "#/definitions/body_11"
+ x-exportParamName: "Body"
+ responses:
+ "200":
+ description: "Updated message is returned as a response"
+ examples:
+ application/json:
+ id: "AXCR3k9bpSY7bpuh7"
+ type: "agent"
+ text: "Your order has shipped! Here’s your tracking number: 9114 5847\
+ \ 4668 7775 9233 54"
+ visitorId: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ agentId: "d9nKoegKSjmCtyK78"
+ createdAt: 1470222622433
+ isPushed: true
+ schema:
+ $ref: "#/definitions/ConversationsMessage"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ delete:
+ tags:
+ - "Conversations"
+ summary: "Delete an automated message"
+ parameters:
+ - name: "id"
+ in: "path"
+ description: "ID of the message"
+ required: true
+ type: "string"
+ x-exportParamName: "Id"
+ responses:
+ "204":
+ description: "The message was deleted from the conversation"
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ "404":
+ description: "Returned when item not found"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /conversations/agentOnlinePing:
+ post:
+ tags:
+ - "Conversations"
+ summary: "Sets agent’s status to online for 2-3 minutes"
+ description: "We recommend pinging this endpoint every minute for as long as\
+ \ the agent has to be considered online."
+ consumes:
+ - "application/json"
+ parameters:
+ - in: "body"
+ name: "body"
+ description: "Agent fields."
+ required: true
+ schema:
+ $ref: "#/definitions/body_12"
+ x-exportParamName: "Body"
+ responses:
+ "201":
+ description: "Status of the agent was set successfully. Response body will\
+ \ be empty."
+ "400":
+ description: "Returned when invalid data posted"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /ecommerce/activate:
+ post:
+ tags:
+ - "Ecommerce"
+ summary: "**Fulfills the eCommerce pre-requisites**"
+ parameters: []
+ responses:
+ "200":
+ description: "DB created successfully"
+ "401":
+ description: "unauthorized"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /orders/status:
+ post:
+ tags:
+ - "Ecommerce"
+ summary: "Maintains every transactional status of the order"
+ operationId: "createOrder"
+ parameters:
+ - in: "body"
+ name: "order"
+ required: true
+ schema:
+ $ref: "#/definitions/order"
+ x-exportParamName: "Order"
+ responses:
+ "204":
+ description: "Order Event posted"
+ "400":
+ description: "bad request"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /orders/status/batch:
+ post:
+ tags:
+ - "Ecommerce"
+ summary: "Maintains a batch of orders"
+ operationId: "createBatchOrder"
+ parameters:
+ - in: "body"
+ name: "orderBatch"
+ required: true
+ schema:
+ $ref: "#/definitions/orderBatch"
+ x-exportParamName: "OrderBatch"
+ responses:
+ "202":
+ $ref: "#/definitions/createdBatchId"
+ "400":
+ description: "bad request"
+ schema:
+ $ref: "#/definitions/errorModel"
+ /categories:
+ get:
+ tags:
+ - "Ecommerce"
+ summary: "Return all your categories"
+ operationId: "getCategories"
+ parameters:
+ - name: "limit"
+ in: "query"
+ description: "Number of documents per page"
+ required: false
+ type: "integer"
+ default: 50
+ maximum: 100
+ format: "int64"
+ x-exportParamName: "Limit"
+ x-optionalDataType: "Int64"
+ - name: "offset"
+ in: "query"
+ description: "Index of the first document in the page"
+ required: false
+ type: "integer"
+ default: 0
+ format: "int64"
+ x-exportParamName: "Offset"
+ x-optionalDataType: "Int64"
+ - name: "sort"
+ in: "query"
+ description: "Sort the results in the ascending/descending order of record\
+ \ creation. Default order is **descending** if `sort` is not passed"
+ required: false
+ type: "string"
+ default: "desc"
+ enum:
+ - "asc"
+ - "desc"
+ x-exportParamName: "Sort"
+ x-optionalDataType: "String"
+ - name: "ids"
+ in: "query"
+ description: "Filter by category ids"
+ required: false
+ type: "array"
+ items:
+ type: "string"
+ x-exportParamName: "Ids"
+ responses:
+ "200":
+ description: "All categories listed"
+ examples:
+ application/json:
+ categories:
+ - id: 19
+ name: "Food"
+ url: "https://mydomain.com/cagetory/food"
+ modifiedAt: "2022-03-03T14:48:31.867Z"
+ createdAt: "2021-12-31T11:42:35.638Z"
+ - id: 20
+ name: "clothing"
+ url: "https://mydomain.com/cagetory/food"
+ modifiedAt: "2022-03-03T14:48:31.867Z"
+ createdAt: "2021-12-31T11:42:35.638Z"
+ count: 2
+ schema:
+ $ref: "#/definitions/getCategories"
+ "400":
+ description: "bad request"
schema:
$ref: "#/definitions/errorModel"
post:
tags:
- - "CRM"
- summary: "Create a task"
+ - "Ecommerce"
+ summary: "Create/Update a category"
+ operationId: "createUpdateCategory"
parameters:
- in: "body"
- name: "body"
- description: "Task name."
+ name: "createUpdateCategory"
+ description: "Values to create/update a category"
required: true
schema:
- $ref: "#/definitions/body_5"
- x-exportParamName: "Body"
+ $ref: "#/definitions/createUpdateCategory"
+ x-exportParamName: "CreateUpdateCategory"
responses:
"201":
- description: "Created new task"
+ description: "Category created"
schema:
- $ref: "#/definitions/inline_response_201_1"
- "400":
- description: "Returned when invalid data posted"
- /crm/tasks/{id}:
+ $ref: "#/definitions/createCategoryModel"
+ "204":
+ description: "Category updated"
+ /categories/{id}:
get:
tags:
- - "CRM"
- summary: "Get a task"
+ - "Ecommerce"
+ summary: "Get a category details"
+ operationId: "getCategoryInfo"
parameters:
- name: "id"
in: "path"
+ description: "Category ID"
required: true
type: "string"
x-exportParamName: "Id"
responses:
"200":
- description: "Returns the Task by id"
- schema:
- $ref: "#/definitions/Task"
- "400":
- description: "Returned when task id is invalid"
- examples:
- application/json:
- message: "Route attribute id is not valid."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when item not found"
- examples:
- application/json:
- message: "Document not found"
+ description: "Category informations"
schema:
- $ref: "#/definitions/errorModel"
- delete:
- tags:
- - "CRM"
- summary: "Delete a task"
- parameters:
- - name: "id"
- in: "path"
- required: true
- type: "string"
- x-exportParamName: "Id"
- responses:
- "204":
- description: "Returned when item deleted"
+ $ref: "#/definitions/getCategoryDetails"
"400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Route attribute id is not valid."
+ description: "bad request"
schema:
$ref: "#/definitions/errorModel"
"404":
- description: "Returned when task id is not found"
- examples:
- application/json:
- message: "Document not found"
+ description: "Category id not found"
schema:
$ref: "#/definitions/errorModel"
- patch:
+ /categories/batch:
+ post:
tags:
- - "CRM"
- summary: "Update a task"
+ - "Ecommerce"
+ summary: "Create the categories in a batch"
+ operationId: "createUpdateBatchCategory"
parameters:
- - name: "id"
- in: "path"
- required: true
- type: "string"
- x-exportParamName: "Id"
- in: "body"
- name: "body"
- description: "Updated task details."
+ name: "createUpdateBatchCategory"
+ description: "Values to create a batch of categories"
required: true
schema:
- $ref: "#/definitions/body_6"
- x-exportParamName: "Body"
+ $ref: "#/definitions/createUpdateBatchCategory"
+ x-exportParamName: "CreateUpdateBatchCategory"
responses:
- "204":
- description: "Task updated successfully"
- "400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Route attribute id is not valid."
+ "201":
+ description: "Category created and updated"
schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when task id is not found"
- examples:
- application/json:
- message: "Document not found"
+ $ref: "#/definitions/createUpdateBatchCategoryModel"
+ "400":
+ description: "bad request"
schema:
$ref: "#/definitions/errorModel"
- /crm/notes:
+ /products:
get:
tags:
- - "CRM"
- summary: "Get all notes"
+ - "Ecommerce"
+ summary: "Return all your products"
+ operationId: "getProducts"
parameters:
- - name: "entity"
- in: "query"
- description: "Filter by note entity type"
- required: false
- type: "string"
- enum:
- - "companies"
- - "deals"
- - "contacts"
- x-exportParamName: "Entity"
- x-optionalDataType: "String"
- - name: "entityIds"
- in: "query"
- description: "Filter by note entity IDs"
- required: false
- type: "string"
- x-exportParamName: "EntityIds"
- x-optionalDataType: "String"
- - name: "dateFrom"
- in: "query"
- description: "dateFrom to date range filter type (timestamp in milliseconds)"
- required: false
- type: "integer"
- x-exportParamName: "DateFrom"
- x-optionalDataType: "Int32"
- - name: "dateTo"
- in: "query"
- description: "dateTo to date range filter type (timestamp in milliseconds)"
- required: false
- type: "integer"
- x-exportParamName: "DateTo"
- x-optionalDataType: "Int32"
- - name: "offset"
+ - name: "limit"
in: "query"
- description: "Index of the first document of the page"
+ description: "Number of documents per page"
required: false
type: "integer"
+ default: 50
+ maximum: 1000
format: "int64"
- x-exportParamName: "Offset"
+ x-exportParamName: "Limit"
x-optionalDataType: "Int64"
- - name: "limit"
+ - name: "offset"
in: "query"
- description: "Number of documents per page"
+ description: "Index of the first document in the page"
required: false
type: "integer"
- default: 50
+ default: 0
format: "int64"
- x-exportParamName: "Limit"
+ x-exportParamName: "Offset"
x-optionalDataType: "Int64"
- name: "sort"
in: "query"
- description: "Sort the results in the ascending/descending order. Default\
- \ order is **descending** by creation if `sort` is not passed"
+ description: "Sort the results in the ascending/descending order of record\
+ \ creation. Default order is **descending** if `sort` is not passed"
required: false
type: "string"
+ default: "desc"
enum:
- "asc"
- "desc"
x-exportParamName: "Sort"
x-optionalDataType: "String"
+ - name: "ids"
+ in: "query"
+ description: "Filter by product ids"
+ required: false
+ type: "array"
+ items:
+ type: "string"
+ x-exportParamName: "Ids"
responses:
"200":
- description: "Returns notes list with filters"
+ description: "All products listed"
+ examples:
+ application/json:
+ products:
+ - id: 7498033266862
+ name: "Alpina Panoma Classic"
+ url: "https://mydomain.com/products/alpina-panoma-classic"
+ sku: "186622-9"
+ imageUrl: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ categories:
+ - "279638835374"
+ - "279502848174"
+ price: 49.95
+ modifiedAt: "2022-06-30T10:29:16.078Z"
+ createdAt: "2022-06-30T10:29:16.078Z"
+ s3Original: "https://img-ecom.mailinblue.com/path-to-original/img.jpg"
+ s3ThumbAnalytics: "https://img-ecom.mailinblue.com/path-to-analytics/img.jpg"
+ s3ThumbEditor: "https://img-ecom.mailinblue.com/path-to-editor/img.jpg"
+ - id: 7498033266862
+ name: "Alpina Panoma Classic2"
+ url: "https://mydomain.com/products/alpina-panoma-classic2"
+ sku: "186622-9"
+ imageUrl: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ categories:
+ - "2d79638835374"
+ - "27d9502848174"
+ price: 49.95
+ modifiedAt: "2022-06-30T10:29:16.078Z"
+ createdAt: "2022-06-30T10:29:16.078Z"
+ s3Original: "https://img-ecom.mailinblue.com/path-to-original/img.jpg"
+ s3ThumbAnalytics: "https://img-ecom.mailinblue.com/path-to-analytics/img.jpg"
+ s3ThumbEditor: "https://img-ecom.mailinblue.com/path-to-editor/img.jpg"
+ count: 2
schema:
- $ref: "#/definitions/NoteList"
+ $ref: "#/definitions/getProducts"
"400":
- description: "Returned when query params are invalid"
- examples:
- response:
- value:
- message: "Not valid data."
+ description: "bad request"
schema:
$ref: "#/definitions/errorModel"
post:
tags:
- - "CRM"
- summary: "Create a note"
+ - "Ecommerce"
+ summary: "Create/Update a product"
+ operationId: "createUpdateProduct"
parameters:
- in: "body"
- name: "body"
- description: "Note data to create a note."
+ name: "createUpdateProduct"
+ description: "Values to create/update a product"
required: true
schema:
- $ref: "#/definitions/NoteData"
- x-exportParamName: "Body"
+ $ref: "#/definitions/createUpdateProduct"
+ x-exportParamName: "CreateUpdateProduct"
responses:
- "200":
- description: "Created new note"
- schema:
- $ref: "#/definitions/NoteId"
- "400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Not valid data."
- schema:
- $ref: "#/definitions/errorModel"
- "415":
- description: "Format is not supported"
+ "201":
+ description: "Product created"
examples:
application/json:
- message: "The format not supported for deserialization."
+ id: 21
schema:
- $ref: "#/definitions/errorModel"
- /crm/notes/{id}:
+ $ref: "#/definitions/createProductModel"
+ "204":
+ description: "Product updated"
+ /products/{id}:
get:
tags:
- - "CRM"
- summary: "Get a note"
+ - "Ecommerce"
+ summary: "Get a product's details"
+ operationId: "getProductInfo"
parameters:
- name: "id"
in: "path"
- description: "Note ID to get"
+ description: "Product ID"
required: true
type: "string"
x-exportParamName: "Id"
responses:
"200":
- description: "Returns the Note by id"
- schema:
- $ref: "#/definitions/Note"
- "400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Route attribute id is not valid."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when item not found"
- examples:
- application/json:
- message: "Document not found"
+ description: "Product informations"
schema:
- $ref: "#/definitions/errorModel"
- delete:
- tags:
- - "CRM"
- summary: "Delete a note"
- parameters:
- - name: "id"
- in: "path"
- description: "Note ID to delete"
- required: true
- type: "string"
- x-exportParamName: "Id"
- responses:
- "204":
- description: "Returned when item deleted"
+ $ref: "#/definitions/getProductDetails"
"400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Route attribute id is not valid."
+ description: "bad request"
schema:
$ref: "#/definitions/errorModel"
"404":
- description: "Returned when item not found"
- examples:
- application/json:
- message: "Document not found"
+ description: "Product's id not found"
schema:
$ref: "#/definitions/errorModel"
- patch:
+ /products/batch:
+ post:
tags:
- - "CRM"
- summary: "Update a note"
+ - "Ecommerce"
+ summary: "Creates the products in a batch"
+ operationId: "createUpdateBatchProducts"
parameters:
- - name: "id"
- in: "path"
- description: "Note ID to update"
- required: true
- type: "string"
- x-exportParamName: "Id"
- in: "body"
- name: "body"
- description: "Note data to update a note"
+ name: "createUpdateBatchProducts"
+ description: "Values to create a batch of products"
required: true
schema:
- $ref: "#/definitions/NoteData"
- x-exportParamName: "Body"
+ $ref: "#/definitions/createUpdateBatchProducts"
+ x-exportParamName: "CreateUpdateBatchProducts"
responses:
- "204":
- description: "Note updated successfully"
- "400":
- description: "Returned when invalid data posted"
- examples:
- application/json:
- message: "Not valid data."
- schema:
- $ref: "#/definitions/errorModel"
- "404":
- description: "Returned when item not found"
- examples:
- application/json:
- message: "Document not found"
- schema:
- $ref: "#/definitions/errorModel"
- "415":
- description: "Format is not supported"
+ "201":
+ description: "Products created and updated"
examples:
application/json:
- message: "The format not supported for deserialization."
+ createdCount: 2
+ updatedCount: 7
schema:
- $ref: "#/definitions/errorModel"
+ $ref: "#/definitions/createUpdateBatchProductsModel"
+ "400":
+ description: "bad request"
securityDefinitions:
api-key:
description: "The API key should be passed in the request headers as `api-key`\
@@ -7277,7 +8222,19 @@ definitions:
example: 122
description: "ID of the object created"
example:
- id: 122
+ id: 122
+ uploadImageModel:
+ type: "object"
+ required:
+ - "url"
+ properties:
+ url:
+ type: "string"
+ format: "string"
+ example: "https://img.mailinblue.com/100000/images/rnb/original/62casdase8wewq9df1c2f27c.jpeg"
+ description: "URL of the image uploaded"
+ example:
+ url: "https://img.mailinblue.com/100000/images/rnb/original/62casdase8wewq9df1c2f27c.jpeg"
createUpdateContactModel:
properties:
id:
@@ -7733,10 +8690,10 @@ definitions:
type:
type: "string"
example: "marketing"
- description: "Type of webhook (marketing or transac)"
+ description: "Type of webhook (marketing or transactional)"
enum:
- "marketing"
- - "transac"
+ - "transactional"
createdAt:
type: "string"
example: "2016-12-01T12:50:00Z"
@@ -8526,6 +9483,19 @@ definitions:
\ day, set the daily increase value to 0%."
minimum: 0
maximum: 100
+ unsubscriptionPageId:
+ type: "string"
+ example: "62cbb7fabbe85021021aac52"
+ description: "Enter an unsubscription page id. The page id is a 24 digit alphanumeric\
+ \ id that can be found in the URL when editing the page. If not entered,\
+ \ then the default unsubscription page will be used."
+ updateFormId:
+ type: "string"
+ example: "6313436b9ad40e23b371d095"
+ description: "Mandatory if templateId is used containing the {{ update_profile\
+ \ }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric\
+ \ id that can be found in the URL when editing the form. If not entered,\
+ \ then the default update profile form will be used."
updateEmailCampaign:
type: "object"
properties:
@@ -8709,6 +9679,17 @@ definitions:
\ number of emails every day, set the daily increase value to 0%."
minimum: 0
maximum: 100
+ unsubscriptionPageId:
+ type: "string"
+ example: "62cbb7fabbe85021021aac52"
+ description: "Enter an unsubscription page id. The page id is a 24 digit alphanumeric\
+ \ id that can be found in the URL when editing the page."
+ updateFormId:
+ type: "string"
+ example: "6313436b9ad40e23b371d095"
+ description: "Mandatory if templateId is used containing the {{ update_profile\
+ \ }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric\
+ \ id that can be found in the URL when editing the form."
getSharedTemplateUrl:
type: "object"
required:
@@ -9259,6 +10240,11 @@ definitions:
example: "COUNT[BLACKLISTED,BLACKLISTED,<,NOW()]"
description: "Value of the attribute. Use only if the attribute's category\
\ is 'calculated' or 'global'"
+ isRecurring:
+ type: "boolean"
+ example: true
+ description: "Type of the calculated attribute. Use only if the attribute's\
+ \ category is 'calculated'"
enumeration:
type: "array"
description: "List of values and labels that the attribute can take. Use only\
@@ -9325,6 +10311,20 @@ definitions:
type: "string"
example: "vipin+subaccount@sendinblue.com"
description: "User email of sub-account organization"
+ createApiKeyRequest:
+ type: "object"
+ required:
+ - "id"
+ properties:
+ id:
+ type: "integer"
+ format: "int64"
+ example: 2333323
+ description: "Id of the sub-account organization"
+ name:
+ type: "string"
+ example: "My Api Key"
+ description: "Name of the API key"
updateList:
type: "object"
properties:
@@ -9477,6 +10477,22 @@ definitions:
description: "Format of the message. It indicates whether the content should\
\ be treated as unicode or not."
default: false
+ organisationPrefix:
+ type: "string"
+ example: "MyCompany"
+ description: "A recognizable prefix will ensure your audience knows who you\
+ \ are. Recommended by U.S. carriers. This will be added as your Brand Name\
+ \ before the message content. **Prefer verifying maximum length of 160 characters\
+ \ including this prefix in message content to avoid multiple sending of\
+ \ same sms.**"
+ unsubscribeInstruction:
+ type: "string"
+ example: "send Stop if you want to unsubscribe."
+ description: "Instructions to unsubscribe from future communications. Recommended\
+ \ by U.S. carriers. Must include **STOP** keyword. This will be added as\
+ \ instructions after the end of message content. **Prefer verifying maximum\
+ \ length of 160 characters including this instructions in message content\
+ \ to avoid multiple sending of same sms.**"
updateSmsCampaign:
type: "object"
properties:
@@ -9508,6 +10524,22 @@ definitions:
description: "Format of the message. It indicates whether the content should\
\ be treated as unicode or not."
default: false
+ organisationPrefix:
+ type: "string"
+ example: "MyCompany"
+ description: "A recognizable prefix will ensure your audience knows who you\
+ \ are. Recommended by U.S. carriers. This will be added as your Brand Name\
+ \ before the message content. **Prefer verifying maximum length of 160 characters\
+ \ including this prefix in message content to avoid multiple sending of\
+ \ same sms.**"
+ unsubscribeInstruction:
+ type: "string"
+ example: "send Stop if you want to unsubscribe."
+ description: "Instructions to unsubscribe from future communications. Recommended\
+ \ by U.S. carriers. Must include **STOP** keyword. This will be added as\
+ \ instructions after the end of message content. **Prefer verifying maximum\
+ \ length of 160 characters including this instructions in message content\
+ \ to avoid multiple sending of same sms.**"
sendTransacSms:
type: "object"
required:
@@ -9557,6 +10589,14 @@ definitions:
description: "Format of the message. It indicates whether the content should\
\ be treated as unicode or not."
default: false
+ organisationPrefix:
+ type: "string"
+ example: "MyCompany"
+ description: "A recognizable prefix will ensure your audience knows who you\
+ \ are. Recommended by U.S. carriers. This will be added as your Brand Name\
+ \ before the message content. **Prefer verifying maximum length of 160 characters\
+ \ including this prefix in message content to avoid multiple sending of\
+ \ same sms.**"
sendTestEmail:
type: "object"
properties:
@@ -9967,6 +11007,15 @@ definitions:
$ref: "#/definitions/masterDetailsResponse_billingInfo"
planInfo:
$ref: "#/definitions/masterDetailsResponse_planInfo"
+ createApiKeyResponse:
+ type: "object"
+ properties:
+ status:
+ type: "string"
+ description: "Status of the API operation."
+ key:
+ type: "string"
+ description: "API Key"
subAccountDetailsResponse:
type: "object"
properties:
@@ -10093,6 +11142,66 @@ definitions:
items:
type: "string"
description: "Task reminder date/time for a task"
+ FileList:
+ type: "array"
+ description: "List of files"
+ items:
+ $ref: "#/definitions/FileData"
+ FileDownloadableLink:
+ type: "object"
+ required:
+ - "fileUrl"
+ properties:
+ fileUrl:
+ type: "string"
+ format: "url"
+ example: "https://storage.googleapis.com/sendinblue-app-crm.......-sample.pdf"
+ description: "A unique link to download the requested file."
+ example:
+ fileUrl: "https://storage.googleapis.com/sendinblue-app-crm.......-sample.pdf"
+ FileData:
+ type: "object"
+ properties:
+ name:
+ type: "string"
+ example: "example.png"
+ description: "Name of uploaded file"
+ authorId:
+ type: "string"
+ example: "61a5ce58y5d4795761045991"
+ description: "Account id of user which created the file"
+ contactId:
+ type: "integer"
+ format: "int64"
+ example: 1
+ description: "Contact id of contact on which file is uploaded"
+ dealId:
+ type: "string"
+ example: "61a5ce58c5d4795761045991"
+ description: "Deal id linked to a file"
+ companyId:
+ type: "string"
+ example: "61a5ce58c5d4795761045991"
+ description: "Company id linked to a file"
+ size:
+ type: "integer"
+ format: "int64"
+ example: 10
+ description: "Size of file in bytes"
+ createdAt:
+ type: "string"
+ format: "date-time"
+ example: "2017-05-01T17:05:03.000Z"
+ description: "File created date/time"
+ description: "File data that is uploaded"
+ example:
+ createdAt: "2017-05-01T17:05:03.000Z"
+ companyId: "61a5ce58c5d4795761045991"
+ size: 10
+ contactId: 1
+ dealId: "61a5ce58c5d4795761045991"
+ name: "example.png"
+ authorId: "61a5ce58y5d4795761045991"
NoteData:
type: "object"
required:
@@ -10121,8 +11230,19 @@ definitions:
description: "Deal Ids linked to a note"
items:
type: "string"
+ companyIds:
+ type: "array"
+ example:
+ - "61a5ce58c5d4795761045990"
+ - "61a5ce58c5d4795761045991"
+ description: "Company Ids linked to a note"
+ items:
+ type: "string"
description: "Note data to be saved"
example:
+ companyIds:
+ - "61a5ce58c5d4795761045990"
+ - "61a5ce58c5d4795761045991"
text: "In communication with client for resolution of queries."
dealIds:
- "61a5ce58c5d4795761045990"
@@ -10420,7 +11540,7 @@ definitions:
description: "List of compaies"
items:
$ref: "#/definitions/Company"
- description: "List of comapnies"
+ description: "List of companies"
example:
items:
- linkedDealsIds:
@@ -10526,49 +11646,540 @@ definitions:
description: "List of company attributes"
items:
$ref: "#/definitions/CompanyAttributes_inner"
- body:
+ ConversationsMessage:
+ type: "object"
+ properties:
+ id:
+ type: "string"
+ example: "eYBEm3gq3zc5ayE2g"
+ description: "Message ID. It can be used for further manipulations with the\
+ \ message."
+ type:
+ type: "string"
+ example: "agent"
+ description: "`\"agent\"` for agents’ messages, `\"visitor\"` for visitors’\
+ \ messages."
+ enum:
+ - "agent"
+ - "visitor"
+ text:
+ type: "string"
+ example: "Good morning! How can I help you?"
+ description: "Message text or name of the attached file"
+ visitorId:
+ type: "string"
+ example: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ description: "visitor’s ID"
+ agentId:
+ type: "string"
+ example: "d9nKoegKSjmCtyK78"
+ description: "ID of the agent on whose behalf the message was sent (only in\
+ \ messages sent by an agent)."
+ agentName:
+ type: "string"
+ example: "Liz"
+ description: "Agent’s name as displayed to the visitor. Only in the messages\
+ \ sent by an agent."
+ createdAt:
+ type: "integer"
+ format: "int64"
+ example: 1470222622433
+ description: "Timestamp in milliseconds."
+ minimum: 0
+ isPushed:
+ type: "boolean"
+ example: true
+ description: "`true` for pushed messages"
+ receivedFrom:
+ type: "string"
+ example: "SuperAwesomeHelpdesk"
+ description: "In two-way integrations, messages sent via REST API can be marked\
+ \ with receivedFrom property and then filtered out when received in a webhook\
+ \ to avoid infinite loop."
+ file:
+ $ref: "#/definitions/ConversationsMessage_file"
+ description: "a Conversations message"
+ example:
+ createdAt: 1470222622433
+ isPushed: true
+ agentId: "d9nKoegKSjmCtyK78"
+ file:
+ isImage: true
+ filename: "conversations.png"
+ size: 15538
+ imageInfo:
+ previewUrl: "https://ucarecdn.com/03cd56cd-1de9-4f65-996d-08afdf27fa1b/-/preview/800x800/-/quality/lighter/"
+ width: 1129
+ height: 525
+ url: "https://ucarecdn.com/cee5c10c-8302-45c1-b1fb-43860ca941a9/"
+ receivedFrom: "SuperAwesomeHelpdesk"
+ agentName: "Liz"
+ id: "eYBEm3gq3zc5ayE2g"
+ text: "Good morning! How can I help you?"
+ type: "agent"
+ visitorId: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ order:
+ type: "object"
+ required:
+ - "amount"
+ - "createdAt"
+ - "id"
+ - "products"
+ - "status"
+ - "updatedAt"
+ properties:
+ id:
+ type: "string"
+ example: "14"
+ description: "Unique ID of the order."
+ createdAt:
+ type: "string"
+ example: "2021-07-29T20:59:23.383Z"
+ description: "Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when\
+ \ order is actually created."
+ updatedAt:
+ type: "string"
+ example: "2021-07-30T10:59:23.383Z"
+ description: "Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the\
+ \ status of the order is actually changed/updated."
+ status:
+ type: "string"
+ example: "completed"
+ description: "State of the order."
+ amount:
+ type: "number"
+ example: 308.42
+ description: "Total amount of the order, including all shipping expenses,\
+ \ tax and the price of items."
+ products:
+ type: "array"
+ items:
+ $ref: "#/definitions/order_products"
+ email:
+ type: "string"
+ example: "example@sendinblue.com"
+ description: "Email of the contact, Mandatory if \"phone\" field is not passed\
+ \ in \"billing\" parameter."
+ billing:
+ $ref: "#/definitions/order_billing"
+ coupons:
+ type: "array"
+ example:
+ - "EASTER15OFF"
+ description: "Coupons applied to the order. Stored case insensitive."
+ items:
+ type: "string"
+ orderBatch:
+ type: "object"
+ required:
+ - "orders"
+ properties:
+ orders:
+ type: "array"
+ description: "array of order objects"
+ items:
+ $ref: "#/definitions/order"
+ notifyUrl:
+ type: "string"
+ example: "https://en.wikipedia.org/wiki/Webhook"
+ description: "Notify Url provided by client to get the status of batch request"
+ createdBatchId:
+ type: "object"
+ required:
+ - "batchId"
+ properties:
+ batchId:
+ type: "number"
+ example: 1.0
+ description: "Batch ID of the request"
+ getCategories:
+ type: "object"
+ required:
+ - "categories"
+ - "count"
+ properties:
+ categories:
+ type: "array"
+ items:
+ type: "object"
+ allOf:
+ - $ref: "#/definitions/getCategoryDetails"
+ count:
+ type: "integer"
+ format: "int64"
+ example: 17655
+ description: "Number of categories"
+ getCategoryDetails:
+ type: "object"
+ required:
+ - "createdAt"
+ - "id"
+ - "modifiedAt"
+ - "name"
+ properties:
+ id:
+ type: "string"
+ format: "string"
+ example: "C11"
+ description: "Category ID for which you requested the details"
+ name:
+ type: "string"
+ format: "string"
+ example: "Electronics"
+ description: "Name of the category for which you requested the details"
+ createdAt:
+ type: "string"
+ example: "2017-05-12T12:30:00.000+0000"
+ description: "Creation UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ)"
+ modifiedAt:
+ type: "string"
+ example: "2017-05-12T12:30:00.000+0000"
+ description: "Last modification UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ)"
+ url:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/cagetory/clothing"
+ description: "URL to the category"
+ example:
+ createdAt: "2017-05-12T12:30:00.000+0000"
+ modifiedAt: "2017-05-12T12:30:00.000+0000"
+ name: "Electronics"
+ id: "C11"
+ url: "http://mydomain.com/cagetory/clothing"
+ createUpdateCategory:
+ type: "object"
+ required:
+ - "id"
+ properties:
+ id:
+ type: "string"
+ format: "email"
+ example: "CAT123"
+ description: "Unique Category ID as saved in the shop\n"
+ name:
+ type: "string"
+ example: "Electronics"
+ description: "**Mandatory in case of creation**. Name of the Category, as\
+ \ displayed in the shop\n"
+ url:
+ type: "string"
+ example: "http://mydomain.com/category/electronics"
+ description: "URL to the category"
+ updateEnabled:
+ type: "boolean"
+ example: false
+ description: "Facilitate to update the existing category in the same request\
+ \ (updateEnabled = true)"
+ default: false
+ createUpdateCategories:
+ type: "object"
+ required:
+ - "id"
+ properties:
+ id:
+ type: "string"
+ format: "email"
+ example: "CAT123"
+ description: "Unique Category ID as saved in the shop\n"
+ name:
+ type: "string"
+ example: "Electronics"
+ description: "**Mandatory in case of creation**. Name of the Category, as\
+ \ displayed in the shop\n"
+ url:
+ type: "string"
+ example: "http://mydomain.com/category/electronics"
+ description: "URL to the category"
+ createUpdateBatchCategory:
+ type: "object"
+ required:
+ - "categories"
+ properties:
+ categories:
+ type: "array"
+ description: "array of categories objects"
+ items:
+ $ref: "#/definitions/createUpdateCategories"
+ updateEnabled:
+ type: "boolean"
+ description: "Facilitate to update the existing categories in the same request\
+ \ (updateEnabled = true)"
+ createCategoryModel:
+ type: "object"
+ properties:
+ id:
+ type: "integer"
+ format: "int64"
+ example: 122
+ description: "ID of the category when a new category is created"
+ example:
+ id: 122
+ createUpdateBatchCategoryModel:
+ type: "object"
+ properties:
+ createdCount:
+ type: "integer"
+ format: "int64"
+ example: 7
+ description: "Number of the new created categories"
+ updatedCount:
+ type: "integer"
+ format: "int64"
+ example: 5
+ description: "Number of the existing categories updated"
+ example:
+ updatedCount: 5
+ createdCount: 7
+ getProducts:
+ type: "object"
+ required:
+ - "count"
+ - "products"
+ properties:
+ products:
+ type: "array"
+ items:
+ type: "object"
+ allOf:
+ - $ref: "#/definitions/getProductDetails"
+ count:
+ type: "integer"
+ format: "int64"
+ example: 17655
+ description: "Number of products"
+ getProductDetails:
+ type: "object"
+ required:
+ - "createdAt"
+ - "id"
+ - "modifiedAt"
+ - "name"
+ - "s3ThumbAnalytics"
+ - "s3ThumbEditor"
+ properties:
+ id:
+ type: "string"
+ format: "string"
+ example: "P11"
+ description: "Product ID for which you requested the details"
+ name:
+ type: "string"
+ format: "string"
+ example: "Iphone 11"
+ description: "Name of the product for which you requested the details"
+ createdAt:
+ type: "string"
+ example: "2017-05-12T12:30:00.000+0000"
+ description: "Creation UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ)"
+ modifiedAt:
+ type: "string"
+ example: "2017-05-12T12:30:00.000+0000"
+ description: "Last modification UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ)"
+ url:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product/electronics/product1"
+ description: "URL to the product"
+ imageUrl:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ description: "Absolute URL to the cover image of the product"
+ sku:
+ type: "string"
+ format: "string"
+ description: "Product identifier from the shop"
+ price:
+ type: "number"
+ format: "float"
+ description: "Price of the product"
+ categories:
+ type: "array"
+ description: "Category ID-s of the product"
+ items:
+ type: "string"
+ parentId:
+ type: "string"
+ format: "string"
+ description: "Parent product id of the product"
+ s3Original:
+ type: "string"
+ format: "string"
+ description: "S3 url of original image"
+ s3ThumbAnalytics:
+ type: "string"
+ format: "string"
+ description: "S3 thumbnail url of original image in 120x120 dimension for\
+ \ analytics section"
+ s3ThumbEditor:
+ type: "string"
+ format: "string"
+ description: "S3 thumbnail url of original image in 600x400 dimension for\
+ \ editor section"
+ example:
+ s3ThumbAnalytics: "s3ThumbAnalytics"
+ modifiedAt: "2017-05-12T12:30:00.000+0000"
+ url: "http://mydomain.com/product/electronics/product1"
+ parentId: "parentId"
+ createdAt: "2017-05-12T12:30:00.000+0000"
+ price: 0.8008282
+ imageUrl: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ name: "Iphone 11"
+ s3ThumbEditor: "s3ThumbEditor"
+ id: "P11"
+ categories:
+ - "categories"
+ - "categories"
+ sku: "sku"
+ s3Original: "s3Original"
+ createUpdateProduct:
type: "object"
required:
+ - "id"
- "name"
properties:
+ id:
+ type: "string"
+ format: "string"
+ example: "P11"
+ description: "Product ID for which you requested the details"
name:
type: "string"
- example: "Deal: Connect with company"
- description: "Name of deal"
- attributes:
+ format: "string"
+ example: "Iphone 11"
+ description: "Mandatory in case of creation**. Name of the product for which\
+ \ you requested the details"
+ url:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product/electronics/product1"
+ description: "URL to the product"
+ imageUrl:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ description: "Absolute URL to the cover image of the product"
+ sku:
+ type: "string"
+ format: "string"
+ description: "Product identifier from the shop"
+ price:
+ type: "number"
+ format: "float"
+ description: "Price of the product"
+ categories:
+ type: "array"
+ description: "Category ID-s of the product"
+ items:
+ type: "string"
+ parentId:
+ type: "string"
+ format: "string"
+ description: "Parent product id of the product"
+ metaInfo:
type: "object"
example:
- deal_owner: "6093d2425a9b436e9519d034"
- amount: 12
- description: "Attributes fo\\r deal creation"
- properties: {}
- inline_response_201:
+ description: "Shoes for sports"
+ brand: "addidas"
+ description: "Meta data of product such as description, vendor, producer,\
+ \ stock level. The size of cumulative metaInfo shall not exceed **1000 KB**.\
+ \ Maximum length of metaInfo object can be 10."
+ additionalProperties: {}
+ updateEnabled:
+ type: "boolean"
+ example: false
+ description: "Facilitate to update the existing category in the same request\
+ \ (updateEnabled = true)"
+ default: false
+ createUpdateBatchProducts:
+ type: "object"
+ required:
+ - "products"
+ properties:
+ products:
+ type: "array"
+ description: "array of products objects"
+ items:
+ $ref: "#/definitions/createUpdateProducts"
+ updateEnabled:
+ type: "boolean"
+ description: "Facilitate to update the existing categories in the same request\
+ \ (updateEnabled = true)"
+ createUpdateProducts:
type: "object"
required:
- "id"
+ - "name"
properties:
id:
type: "string"
- example: "61a5cd07ca1347c82306ad06"
- description: "Unique deal id"
- description: "Created deal id"
- example:
- id: "61a5cd07ca1347c82306ad06"
- body_1:
- type: "object"
- properties:
+ format: "string"
+ example: "P11"
+ description: "Product ID for which you requested the details"
name:
type: "string"
- example: "Deal: Connect with client"
- description: "Name of deal"
- attributes:
+ format: "string"
+ example: "Iphone 11"
+ description: "Mandatory in case of creation**. Name of the product for which\
+ \ you requested the details"
+ url:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product/electronics/product1"
+ description: "URL to the product"
+ imageUrl:
+ type: "string"
+ format: "string"
+ example: "http://mydomain.com/product-absoulte-url/img.jpeg"
+ description: "Absolute URL to the cover image of the product"
+ sku:
+ type: "string"
+ format: "string"
+ description: "Product identifier from the shop"
+ price:
+ type: "number"
+ format: "float"
+ description: "Price of the product"
+ categories:
+ type: "array"
+ description: "Category ID-s of the product"
+ items:
+ type: "string"
+ parentId:
+ type: "string"
+ format: "string"
+ description: "Parent product id of the product"
+ metaInfo:
type: "object"
example:
- deal_owner: "6093d2425a9b436e9519d034"
- amount: 12
- description: "Attributes for deal update"
- properties: {}
- body_2:
+ description: "Shoes for sports"
+ brand: "addidas"
+ description: "Meta data of product such as description, vendor, producer,\
+ \ stock level. The size of cumulative metaInfo shall not exceed **1000 KB**.\
+ \ Maximum length of metaInfo object can be 10."
+ additionalProperties: {}
+ createProductModel:
+ type: "object"
+ properties:
+ id:
+ type: "integer"
+ format: "int64"
+ example: 122
+ description: "ID of the Product when a new product is created"
+ createUpdateBatchProductsModel:
+ type: "object"
+ properties:
+ createdCount:
+ type: "integer"
+ format: "int64"
+ example: 7
+ description: "Number of the new created products"
+ updatedCount:
+ type: "integer"
+ format: "int64"
+ example: 5
+ description: "Number of the existing products updated"
+ body:
type: "object"
required:
- "name"
@@ -10585,6 +12196,11 @@ definitions:
owner: "60e68d60582a3b006f524197"
description: "Attributes for company creation"
properties: {}
+ countryCode:
+ type: "integer"
+ format: "int64"
+ example: 91
+ description: "Country code if phone_number is passed in attributes."
inline_response_200:
type: "object"
required:
@@ -10597,7 +12213,7 @@ definitions:
description: "Created company id"
example:
id: "61a5cd07ca1347c82306ad06"
- body_3:
+ body_1:
type: "object"
properties:
name:
@@ -10618,7 +12234,12 @@ definitions:
revenue: 10000.34222
description: "Attributes for company update"
properties: {}
- body_4:
+ countryCode:
+ type: "integer"
+ format: "int64"
+ example: 91
+ description: "Country code if phone_number is passed in attributes."
+ body_2:
type: "object"
properties:
linkContactIds:
@@ -10630,6 +12251,7 @@ definitions:
description: "Contact ids for contacts to be linked with company"
items:
type: "integer"
+ format: "int64"
unlinkContactIds:
type: "array"
example:
@@ -10639,6 +12261,7 @@ definitions:
description: "Contact ids for contacts to be unlinked from company"
items:
type: "integer"
+ format: "int64"
linkDealsIds:
type: "array"
example:
@@ -10657,7 +12280,90 @@ definitions:
description: "Deals ids for deals to be unlinked from company"
items:
type: "string"
+ body_3:
+ type: "object"
+ required:
+ - "name"
+ properties:
+ name:
+ type: "string"
+ example: "Deal: Connect with company"
+ description: "Name of deal"
+ attributes:
+ type: "object"
+ example:
+ deal_owner: "6093d2425a9b436e9519d034"
+ amount: 12
+ description: "Attributes fo\\r deal creation"
+ properties: {}
+ inline_response_201:
+ type: "object"
+ required:
+ - "id"
+ properties:
+ id:
+ type: "string"
+ example: "61a5cd07ca1347c82306ad06"
+ description: "Unique deal id"
+ description: "Created deal id"
+ example:
+ id: "61a5cd07ca1347c82306ad06"
+ body_4:
+ type: "object"
+ properties:
+ name:
+ type: "string"
+ example: "Deal: Connect with client"
+ description: "Name of deal"
+ attributes:
+ type: "object"
+ example:
+ deal_owner: "6093d2425a9b436e9519d034"
+ amount: 12
+ description: "Attributes for deal update"
+ properties: {}
body_5:
+ type: "object"
+ properties:
+ linkContactIds:
+ type: "array"
+ example:
+ - 1
+ - 2
+ - 3
+ description: "Contact ids for contacts to be linked with deal"
+ items:
+ type: "integer"
+ format: "int64"
+ unlinkContactIds:
+ type: "array"
+ example:
+ - 4
+ - 5
+ - 6
+ description: "Contact ids for contacts to be unlinked from deal"
+ items:
+ type: "integer"
+ format: "int64"
+ linkCompanyIds:
+ type: "array"
+ example:
+ - "61a5ce58c5d4795761045990"
+ - "61a5ce58c5d4795761045991"
+ - "61a5ce58c5d4795761045992"
+ description: "Company ids to be linked with deal"
+ items:
+ type: "string"
+ unlinkCompanyIds:
+ type: "array"
+ example:
+ - "61a5ce58c5d4795761045994"
+ - "61a5ce58c5d479576104595"
+ - "61a5ce58c5d4795761045996"
+ description: "Company ids to be unlinked from deal"
+ items:
+ type: "string"
+ body_6:
type: "object"
required:
- "date"
@@ -10736,7 +12442,7 @@ definitions:
description: "Task Details"
example:
id: "61a5cd07ca1347c82306ad06"
- body_6:
+ body_7:
type: "object"
properties:
name:
@@ -10795,6 +12501,122 @@ definitions:
description: "Companies ids for companies a task is linked to"
items:
type: "string"
+ body_8:
+ type: "object"
+ required:
+ - "text"
+ - "visitorId"
+ properties:
+ visitorId:
+ type: "string"
+ example: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ description: "visitor’s ID received from a webhook or generated by you to bind existing user account to Conversations"
+ text:
+ type: "string"
+ example: "Hello! How can I help you?"
+ description: "message text"
+ agentId:
+ type: "string"
+ example: "d9nKoegKSjmCtyK78"
+ description: "agent ID. It can be found on agent’s page or received from a webhook.\
+ \ Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom`\
+ \ instead (all 3 fields required)."
+ receivedFrom:
+ type: "string"
+ example: "SuperAwesomeHelpdesk"
+ description: "mark your messages to distinguish messages created by you from\
+ \ the others."
+ agentEmail:
+ type: "string"
+ format: "email"
+ example: "liz@getwear.com"
+ description: "agent email. When sending messages from a standalone system,\
+ \ it’s hard to maintain a 1-to-1 relationship between the users of both\
+ \ systems. In this case, an agent can be specified by their email address."
+ agentName:
+ type: "string"
+ example: "Liz"
+ description: "agent name"
+ body_9:
+ required:
+ - "text"
+ properties:
+ text:
+ type: "string"
+ description: "edited message text"
+ example:
+ edition:
+ value:
+ text: "Good morning! How can I help you?"
+ body_10:
+ type: "object"
+ required:
+ - "text"
+ - "visitorId"
+ properties:
+ visitorId:
+ type: "string"
+ example: "kZMvWhf8npAu3H6qd57w2Hv6nh6rnxvg"
+ description: "visitor’s ID received from a webhook or generated by you to bind existing user account to Conversations"
+ text:
+ type: "string"
+ example: "Your order has shipped! Here’s your tracking number: 9114 5847 3325\
+ \ 9667 4328 88"
+ description: "message text"
+ agentId:
+ type: "string"
+ example: "PjRBMhWGen6aRHjif"
+ description: "agent ID. It can be found on agent’s page or received from a webhook.\
+ \ Optional if `groupId` is set."
+ groupId:
+ type: "string"
+ example: "PjRBMhWGen6aRHjif"
+ description: "group ID. It can be found on group’s page. Optional if `agentId`\
+ \ is set."
+ body_11:
+ type: "object"
+ required:
+ - "text"
+ properties:
+ text:
+ type: "string"
+ example: "Your order has shipped! Here’s your tracking number: 9114 5847 4668\
+ \ 7775 9233 54"
+ description: "edited message text"
+ body_12:
+ type: "object"
+ properties:
+ agentId:
+ type: "string"
+ example: "d9nKoegKSjmCtyK78"
+ description: "agent ID. It can be found on agent’s page or received from a webhook.\
+ \ Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom`\
+ \ instead (all 3 fields required)."
+ receivedFrom:
+ type: "string"
+ example: "SuperAwesomeHelpdesk"
+ description: "mark your messages to distinguish messages created by you from\
+ \ the others."
+ agentEmail:
+ type: "string"
+ format: "email"
+ example: "liz@getwear.com"
+ description: "agent email. When sending online pings from a standalone system,\
+ \ it’s hard to maintain a 1-to-1 relationship between the users of both\
+ \ systems. In this case, an agent can be specified by their email address.\
+ \ If there’s no agent with the specified email address in your Sendinblue\
+ \ organization, a dummy agent will be created automatically."
+ agentName:
+ type: "string"
+ example: "Liz"
+ description: "agent name."
getAccount_plan:
type: "object"
required:
@@ -11840,7 +13662,15 @@ definitions:
type: "integer"
format: "int64"
example: 32
- description: "List ids to include/exclude from campaign"
+ segmentIds:
+ type: "array"
+ description: "Mandatory if listIds are not used. Segment ids to send the campaign\
+ \ to."
+ items:
+ type: "integer"
+ format: "int64"
+ example: 23
+ description: "Segment ids and List ids to include/exclude from campaign"
updateEmailCampaign_sender:
type: "object"
properties:
@@ -11876,13 +13706,23 @@ definitions:
example: 8
listIds:
type: "array"
- description: "Lists Ids to send the campaign to. REQUIRED if already not present\
- \ in campaign and scheduledAt is not empty"
+ description: "Lists Ids to send the campaign to. Campaign should only be updated\
+ \ with listIds if listIds were used to create it. REQUIRED if already not\
+ \ present in campaign and scheduledAt is not empty"
items:
type: "integer"
format: "int64"
example: 32
- description: "List ids to include/exclude from campaign"
+ segmentIds:
+ type: "array"
+ description: "Mandatory if listIds are not used. Campaign should only be updated\
+ \ with segmentIds if segmentIds were used to create it. Segment ids to send\
+ \ the campaign to."
+ items:
+ type: "integer"
+ format: "int64"
+ example: 23
+ description: "Segment ids and List ids to include/exclude from campaign"
abTestCampaignResult_statistics:
type: "object"
required:
@@ -12791,5 +14631,122 @@ definitions:
type: "boolean"
example: true
description: "List of attributes"
+ ConversationsMessage_file_imageInfo:
+ type: "object"
+ properties:
+ width:
+ type: "integer"
+ format: "int64"
+ example: 1129
+ description: "Width of the image"
+ minimum: 0
+ height:
+ type: "integer"
+ format: "int64"
+ example: 525
+ description: "height of the image"
+ minimum: 0
+ previewUrl:
+ type: "string"
+ format: "url"
+ example: "https://ucarecdn.com/03cd56cd-1de9-4f65-996d-08afdf27fa1b/-/preview/800x800/-/quality/lighter/"
+ description: "URL of the preview"
+ description: "image info is passed in case the file is an image"
+ example:
+ previewUrl: "https://ucarecdn.com/03cd56cd-1de9-4f65-996d-08afdf27fa1b/-/preview/800x800/-/quality/lighter/"
+ width: 1129
+ height: 525
+ ConversationsMessage_file:
+ type: "object"
+ properties:
+ filename:
+ type: "string"
+ example: "conversations.png"
+ description: "Name of the file"
+ size:
+ type: "integer"
+ format: "int64"
+ example: 15538
+ description: "Size in bytes"
+ minimum: 0
+ isImage:
+ type: "boolean"
+ example: true
+ description: "Whether the file is an image"
+ url:
+ type: "string"
+ format: "url"
+ example: "https://ucarecdn.com/cee5c10c-8302-45c1-b1fb-43860ca941a9/"
+ description: "URL of the file"
+ imageInfo:
+ $ref: "#/definitions/ConversationsMessage_file_imageInfo"
+ example:
+ isImage: true
+ filename: "conversations.png"
+ size: 15538
+ imageInfo:
+ previewUrl: "https://ucarecdn.com/03cd56cd-1de9-4f65-996d-08afdf27fa1b/-/preview/800x800/-/quality/lighter/"
+ width: 1129
+ height: 525
+ url: "https://ucarecdn.com/cee5c10c-8302-45c1-b1fb-43860ca941a9/"
+ order_products:
+ type: "object"
+ required:
+ - "price"
+ - "productId"
+ - "quantity"
+ properties:
+ productId:
+ type: "string"
+ example: "P1"
+ description: "ID of the product."
+ quantity:
+ type: "number"
+ example: 10.0
+ description: "How many pieces of the product the visitor has added to the\
+ \ cart."
+ variantId:
+ type: "string"
+ example: "P100"
+ description: "Product ID of the red color shirts."
+ price:
+ type: "number"
+ example: 99.99
+ description: "The price of a unit of product"
+ description: "Details for the Products in an order."
+ order_billing:
+ type: "object"
+ properties:
+ address:
+ type: "string"
+ example: "15 Somewhere Road, Brynmenyn"
+ description: "Full billing address."
+ city:
+ type: "string"
+ example: "Basel"
+ description: "Exact city of the address."
+ countryCode:
+ type: "string"
+ example: "CA"
+ description: "Billing country 2-letter ISO code."
+ phone:
+ type: "string"
+ example: "01559 032133"
+ description: "Phone number to contact for further details about the order,\
+ \ Mandatory if \"email\" field is not passed."
+ postCode:
+ type: "string"
+ example: "4052"
+ description: "Postcode for delivery and billing."
+ paymentMethod:
+ type: "string"
+ example: "PayPal"
+ description: "How the visitor will pay for the item(s), e.g. paypal, check,\
+ \ etc."
+ region:
+ type: "string"
+ example: "Northwestern Switzerland"
+ description: "Exact region (state/province) for delivery and billing."
+ description: "Billing details of an order."
x-samples-languages:
- "curl"
diff --git a/docs/AbTestCampaignResult.md b/docs/AbTestCampaignResult.md
index 7147589..a4a44a1 100644
--- a/docs/AbTestCampaignResult.md
+++ b/docs/AbTestCampaignResult.md
@@ -9,8 +9,8 @@ Name | Type | Description | Notes
**OpenRate** | **string** | Open rate for current winning version | [optional] [default to null]
**ClickRate** | **string** | Click rate for current winning version | [optional] [default to null]
**WinningVersionRate** | **string** | Open/Click rate for the winner version | [optional] [default to null]
-**Statistics** | [***AbTestCampaignResultStatistics**](AbTestCampaignResultStatistics.md) | | [optional] [default to null]
-**ClickedLinks** | [***AbTestCampaignResultClickedLinks**](AbTestCampaignResultClickedLinks.md) | | [optional] [default to null]
+**Statistics** | [***AbTestCampaignResultStatistics**](ABTestCampaignResultStatistics.md) | | [optional] [default to null]
+**ClickedLinks** | [***AbTestCampaignResultClickedLinks**](ABTestCampaignResultClickedLinks.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/AbTestCampaignResultClickedLinks.md b/docs/AbTestCampaignResultClickedLinks.md
index 6a41612..8acd2f2 100644
--- a/docs/AbTestCampaignResultClickedLinks.md
+++ b/docs/AbTestCampaignResultClickedLinks.md
@@ -3,8 +3,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**VersionA** | [***AbTestVersionClicks**](AbTestVersionClicks.md) | | [default to null]
-**VersionB** | [***AbTestVersionClicks**](AbTestVersionClicks.md) | | [default to null]
+**VersionA** | [***AbTestVersionClicks**](ABTestVersionClicks.md) | | [default to null]
+**VersionB** | [***AbTestVersionClicks**](ABTestVersionClicks.md) | | [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/AttributesApi.md b/docs/AttributesApi.md
index 0482a45..eb5e275 100644
--- a/docs/AttributesApi.md
+++ b/docs/AttributesApi.md
@@ -114,4 +114,3 @@ Name | Type | Description | Notes
- **Accept**: application/json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
-
diff --git a/docs/Body.md b/docs/Body.md
index 4aaa1e9..8b4838e 100644
--- a/docs/Body.md
+++ b/docs/Body.md
@@ -3,8 +3,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of deal | [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Attributes fo\\r deal creation | [optional] [default to null]
+**Name** | **string** | Name of company | [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Attributes for company creation | [optional] [default to null]
+**CountryCode** | **int64** | Country code if phone_number is passed in attributes. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body1.md b/docs/Body1.md
index 99a521f..19a081e 100644
--- a/docs/Body1.md
+++ b/docs/Body1.md
@@ -3,8 +3,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of deal | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Attributes for deal update | [optional] [default to null]
+**Name** | **string** | Name of company | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Attributes for company update | [optional] [default to null]
+**CountryCode** | **int64** | Country code if phone_number is passed in attributes. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body10.md b/docs/Body10.md
new file mode 100644
index 0000000..19575cf
--- /dev/null
+++ b/docs/Body10.md
@@ -0,0 +1,13 @@
+# Body10
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**VisitorId** | **string** | visitor’s ID received <a href=\"https://developers.sendinblue.com/docs/conversations-webhooks\">from a webhook</a> or generated by you to <a href=\"https://developers.sendinblue.com/docs/customize-the-widget#identifying-existing-users\">bind existing user account to Conversations</a> | [default to null]
+**Text** | **string** | message text | [default to null]
+**AgentId** | **string** | agent ID. It can be found on agent’s page or received <a href=\"https://developers.sendinblue.com/docs/conversations-webhooks\">from a webhook</a>. Optional if `groupId` is set. | [optional] [default to null]
+**GroupId** | **string** | group ID. It can be found on group’s page. Optional if `agentId` is set. | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Body11.md b/docs/Body11.md
new file mode 100644
index 0000000..d810c79
--- /dev/null
+++ b/docs/Body11.md
@@ -0,0 +1,10 @@
+# Body11
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Text** | **string** | edited message text | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Body12.md b/docs/Body12.md
new file mode 100644
index 0000000..cc9a09e
--- /dev/null
+++ b/docs/Body12.md
@@ -0,0 +1,13 @@
+# Body12
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**AgentId** | **string** | agent ID. It can be found on agent’s page or received <a href=\"https://developers.sendinblue.com/docs/conversations-webhooks\">from a webhook</a>. Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom` instead (all 3 fields required). | [optional] [default to null]
+**ReceivedFrom** | **string** | mark your messages to distinguish messages created by you from the others. | [optional] [default to null]
+**AgentEmail** | **string** | agent email. When sending online pings from a standalone system, it’s hard to maintain a 1-to-1 relationship between the users of both systems. In this case, an agent can be specified by their email address. If there’s no agent with the specified email address in your Sendinblue organization, a dummy agent will be created automatically. | [optional] [default to null]
+**AgentName** | **string** | agent name. | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Body2.md b/docs/Body2.md
index 5ab3e78..17d6bdc 100644
--- a/docs/Body2.md
+++ b/docs/Body2.md
@@ -3,8 +3,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of company | [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Attributes for company creation | [optional] [default to null]
+**LinkContactIds** | **[]int64** | Contact ids for contacts to be linked with company | [optional] [default to null]
+**UnlinkContactIds** | **[]int64** | Contact ids for contacts to be unlinked from company | [optional] [default to null]
+**LinkDealsIds** | **[]string** | Deals ids for deals to be linked with company | [optional] [default to null]
+**UnlinkDealsIds** | **[]string** | Deals ids for deals to be unlinked from company | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body3.md b/docs/Body3.md
index 7da2598..b2ad2be 100644
--- a/docs/Body3.md
+++ b/docs/Body3.md
@@ -3,8 +3,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of company | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Attributes for company update | [optional] [default to null]
+**Name** | **string** | Name of deal | [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Attributes fo\\r deal creation | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body4.md b/docs/Body4.md
index 25f25cd..2957139 100644
--- a/docs/Body4.md
+++ b/docs/Body4.md
@@ -3,10 +3,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**LinkContactIds** | **[]int32** | Contact ids for contacts to be linked with company | [optional] [default to null]
-**UnlinkContactIds** | **[]int32** | Contact ids for contacts to be unlinked from company | [optional] [default to null]
-**LinkDealsIds** | **[]string** | Deals ids for deals to be linked with company | [optional] [default to null]
-**UnlinkDealsIds** | **[]string** | Deals ids for deals to be unlinked from company | [optional] [default to null]
+**Name** | **string** | Name of deal | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Attributes for deal update | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body5.md b/docs/Body5.md
index 3ceb95a..3899e1a 100644
--- a/docs/Body5.md
+++ b/docs/Body5.md
@@ -3,17 +3,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of task | [default to null]
-**Duration** | **int64** | Duration of task in milliseconds [1 minute = 60000 ms] | [optional] [default to null]
-**TaskTypeId** | **string** | Id for type of task e.g Call / Email / Meeting etc. | [default to null]
-**Date** | [**time.Time**](time.Time.md) | Task due date and time | [default to null]
-**Notes** | **string** | Notes added to a task | [optional] [default to null]
-**Done** | **bool** | Task marked as done | [optional] [default to null]
-**AssignToId** | **string** | User id to whom task is assigned | [optional] [default to null]
-**ContactsIds** | **[]int32** | Contact ids for contacts linked to this task | [optional] [default to null]
-**DealsIds** | **[]string** | Deal ids for deals a task is linked to | [optional] [default to null]
-**CompaniesIds** | **[]string** | Companies ids for companies a task is linked to | [optional] [default to null]
-**Reminder** | [***TaskReminder**](TaskReminder.md) | | [optional] [default to null]
+**LinkContactIds** | **[]int64** | Contact ids for contacts to be linked with deal | [optional] [default to null]
+**UnlinkContactIds** | **[]int64** | Contact ids for contacts to be unlinked from deal | [optional] [default to null]
+**LinkCompanyIds** | **[]string** | Company ids to be linked with deal | [optional] [default to null]
+**UnlinkCompanyIds** | **[]string** | Company ids to be unlinked from deal | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body6.md b/docs/Body6.md
index a99c633..87091ca 100644
--- a/docs/Body6.md
+++ b/docs/Body6.md
@@ -3,16 +3,17 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Name** | **string** | Name of task | [optional] [default to null]
-**Duration** | **int32** | Duration of task in milliseconds [1 minute = 60000 ms] | [optional] [default to null]
-**TaskTypeId** | **string** | Id for type of task e.g Call / Email / Meeting etc. | [optional] [default to null]
-**Date** | [**time.Time**](time.Time.md) | Task date/time | [optional] [default to null]
+**Name** | **string** | Name of task | [default to null]
+**Duration** | **int64** | Duration of task in milliseconds [1 minute = 60000 ms] | [optional] [default to null]
+**TaskTypeId** | **string** | Id for type of task e.g Call / Email / Meeting etc. | [default to null]
+**Date** | [**time.Time**](time.Time.md) | Task due date and time | [default to null]
**Notes** | **string** | Notes added to a task | [optional] [default to null]
**Done** | **bool** | Task marked as done | [optional] [default to null]
**AssignToId** | **string** | User id to whom task is assigned | [optional] [default to null]
**ContactsIds** | **[]int32** | Contact ids for contacts linked to this task | [optional] [default to null]
**DealsIds** | **[]string** | Deal ids for deals a task is linked to | [optional] [default to null]
**CompaniesIds** | **[]string** | Companies ids for companies a task is linked to | [optional] [default to null]
+**Reminder** | [***TaskReminder**](TaskReminder.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/Body7.md b/docs/Body7.md
new file mode 100644
index 0000000..a01db2f
--- /dev/null
+++ b/docs/Body7.md
@@ -0,0 +1,19 @@
+# Body7
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Name** | **string** | Name of task | [optional] [default to null]
+**Duration** | **int32** | Duration of task in milliseconds [1 minute = 60000 ms] | [optional] [default to null]
+**TaskTypeId** | **string** | Id for type of task e.g Call / Email / Meeting etc. | [optional] [default to null]
+**Date** | [**time.Time**](time.Time.md) | Task date/time | [optional] [default to null]
+**Notes** | **string** | Notes added to a task | [optional] [default to null]
+**Done** | **bool** | Task marked as done | [optional] [default to null]
+**AssignToId** | **string** | User id to whom task is assigned | [optional] [default to null]
+**ContactsIds** | **[]int32** | Contact ids for contacts linked to this task | [optional] [default to null]
+**DealsIds** | **[]string** | Deal ids for deals a task is linked to | [optional] [default to null]
+**CompaniesIds** | **[]string** | Companies ids for companies a task is linked to | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Body8.md b/docs/Body8.md
new file mode 100644
index 0000000..b6b171a
--- /dev/null
+++ b/docs/Body8.md
@@ -0,0 +1,15 @@
+# Body8
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**VisitorId** | **string** | visitor’s ID received <a href=\"https://developers.sendinblue.com/docs/conversations-webhooks\">from a webhook</a> or generated by you to <a href=\"https://developers.sendinblue.com/docs/customize-the-widget#identifying-existing-users\">bind existing user account to Conversations</a> | [default to null]
+**Text** | **string** | message text | [default to null]
+**AgentId** | **string** | agent ID. It can be found on agent’s page or received <a href=\"https://developers.sendinblue.com/docs/conversations-webhooks\">from a webhook</a>. Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom` instead (all 3 fields required). | [optional] [default to null]
+**ReceivedFrom** | **string** | mark your messages to distinguish messages created by you from the others. | [optional] [default to null]
+**AgentEmail** | **string** | agent email. When sending messages from a standalone system, it’s hard to maintain a 1-to-1 relationship between the users of both systems. In this case, an agent can be specified by their email address. | [optional] [default to null]
+**AgentName** | **string** | agent name | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Body9.md b/docs/Body9.md
new file mode 100644
index 0000000..6367fed
--- /dev/null
+++ b/docs/Body9.md
@@ -0,0 +1,10 @@
+# Body9
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Text** | **string** | edited message text | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CRMApi.md b/docs/CRMApi.md
index 4e677c4..cd08a8d 100644
--- a/docs/CRMApi.md
+++ b/docs/CRMApi.md
@@ -332,4 +332,3 @@ This endpoint does not need any parameter.
- **Accept**: application/json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
-
diff --git a/docs/CompaniesApi.md b/docs/CompaniesApi.md
index 6a41c4e..88193e5 100644
--- a/docs/CompaniesApi.md
+++ b/docs/CompaniesApi.md
@@ -136,7 +136,7 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
**id** | **string**| |
- **body** | [**Body3**](Body3.md)| Updated company details. |
+ **body** | [**Body1**](Body1.md)| Updated company details. |
### Return type
@@ -163,7 +163,7 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
**id** | **string**| |
- **body** | [**Body4**](Body4.md)| Linked / Unlinked contacts and deals ids. |
+ **body** | [**Body2**](Body2.md)| Linked / Unlinked contacts and deals ids. |
### Return type
@@ -189,11 +189,11 @@ Create a company
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
- **body** | [**Body2**](Body2.md)| Company create data. |
+ **body** | [**Body**](Body.md)| Company create data. |
### Return type
-[**InlineResponse200**](InlineResponse200.md)
+[**InlineResponse200**](inline_response_200.md)
### Authorization
diff --git a/docs/Company.md b/docs/Company.md
index f7c4248..3afa5b2 100644
--- a/docs/Company.md
+++ b/docs/Company.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **string** | Unique company id | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Company attributes with values | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Company attributes with values | [optional] [default to null]
**LinkedContactsIds** | **[]int32** | Contact ids for contacts linked to this company | [optional] [default to null]
**LinkedDealsIds** | **[]string** | Deals ids for companies linked to this company | [optional] [default to null]
diff --git a/docs/ConversationsApi.md b/docs/ConversationsApi.md
new file mode 100644
index 0000000..30aa093
--- /dev/null
+++ b/docs/ConversationsApi.md
@@ -0,0 +1,269 @@
+# \ConversationsApi
+
+All URIs are relative to *https://api.sendinblue.com/v3*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**ConversationsAgentOnlinePingPost**](ConversationsApi.md#ConversationsAgentOnlinePingPost) | **Post** /conversations/agentOnlinePing | Sets agent’s status to online for 2-3 minutes
+[**ConversationsMessagesIdDelete**](ConversationsApi.md#ConversationsMessagesIdDelete) | **Delete** /conversations/messages/{id} | Delete a message sent by an agent
+[**ConversationsMessagesIdGet**](ConversationsApi.md#ConversationsMessagesIdGet) | **Get** /conversations/messages/{id} | Get a message
+[**ConversationsMessagesIdPut**](ConversationsApi.md#ConversationsMessagesIdPut) | **Put** /conversations/messages/{id} | Update a message sent by an agent
+[**ConversationsMessagesPost**](ConversationsApi.md#ConversationsMessagesPost) | **Post** /conversations/messages | Send a message as an agent
+[**ConversationsPushedMessagesIdDelete**](ConversationsApi.md#ConversationsPushedMessagesIdDelete) | **Delete** /conversations/pushedMessages/{id} | Delete an automated message
+[**ConversationsPushedMessagesIdGet**](ConversationsApi.md#ConversationsPushedMessagesIdGet) | **Get** /conversations/pushedMessages/{id} | Get an automated message
+[**ConversationsPushedMessagesIdPut**](ConversationsApi.md#ConversationsPushedMessagesIdPut) | **Put** /conversations/pushedMessages/{id} | Update an automated message
+[**ConversationsPushedMessagesPost**](ConversationsApi.md#ConversationsPushedMessagesPost) | **Post** /conversations/pushedMessages | Send an automated message to a visitor
+
+
+# **ConversationsAgentOnlinePingPost**
+> ConversationsAgentOnlinePingPost(ctx, body)
+Sets agent’s status to online for 2-3 minutes
+
+We recommend pinging this endpoint every minute for as long as the agent has to be considered online.
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **body** | [**Body12**](Body12.md)| Agent fields. |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsMessagesIdDelete**
+> ConversationsMessagesIdDelete(ctx, id)
+Delete a message sent by an agent
+
+Only agents’ messages can be deleted.
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsMessagesIdGet**
+> ConversationsMessage ConversationsMessagesIdGet(ctx, id)
+Get a message
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsMessagesIdPut**
+> ConversationsMessage ConversationsMessagesIdPut(ctx, id, optional)
+Update a message sent by an agent
+
+Only agents’ messages can be edited.
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message |
+ **optional** | ***ConversationsMessagesIdPutOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a ConversationsMessagesIdPutOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+
+ **body** | [**optional.Interface of Body9**](Body9.md)| |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsMessagesPost**
+> ConversationsMessage ConversationsMessagesPost(ctx, body)
+Send a message as an agent
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **body** | [**Body8**](Body8.md)| Message fields. |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsPushedMessagesIdDelete**
+> ConversationsPushedMessagesIdDelete(ctx, id)
+Delete an automated message
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsPushedMessagesIdGet**
+> ConversationsMessage ConversationsPushedMessagesIdGet(ctx, id)
+Get an automated message
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message sent previously |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsPushedMessagesIdPut**
+> ConversationsMessage ConversationsPushedMessagesIdPut(ctx, id, body)
+Update an automated message
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| ID of the message |
+ **body** | [**Body11**](Body11.md)| |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **ConversationsPushedMessagesPost**
+> ConversationsMessage ConversationsPushedMessagesPost(ctx, body)
+Send an automated message to a visitor
+
+Example of automated messages: order status, announce new features in your web app, etc.
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **body** | [**Body10**](Body10.md)| |
+
+### Return type
+
+[**ConversationsMessage**](ConversationsMessage.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/ConversationsMessage.md b/docs/ConversationsMessage.md
new file mode 100644
index 0000000..312c52c
--- /dev/null
+++ b/docs/ConversationsMessage.md
@@ -0,0 +1,19 @@
+# ConversationsMessage
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Message ID. It can be used for further manipulations with the message. | [optional] [default to null]
+**Type_** | **string** | `\"agent\"` for agents’ messages, `\"visitor\"` for visitors’ messages. | [optional] [default to null]
+**Text** | **string** | Message text or name of the attached file | [optional] [default to null]
+**VisitorId** | **string** | visitor’s ID | [optional] [default to null]
+**AgentId** | **string** | ID of the agent on whose behalf the message was sent (only in messages sent by an agent). | [optional] [default to null]
+**AgentName** | **string** | Agent’s name as displayed to the visitor. Only in the messages sent by an agent. | [optional] [default to null]
+**CreatedAt** | **int64** | Timestamp in milliseconds. | [optional] [default to null]
+**IsPushed** | **bool** | `true` for pushed messages | [optional] [default to null]
+**ReceivedFrom** | **string** | In two-way integrations, messages sent via REST API can be marked with receivedFrom property and then filtered out when received in a webhook to avoid infinite loop. | [optional] [default to null]
+**File** | [***ConversationsMessageFile**](ConversationsMessageFile.md) | | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/ConversationsMessageFile.md b/docs/ConversationsMessageFile.md
new file mode 100644
index 0000000..6ac18bb
--- /dev/null
+++ b/docs/ConversationsMessageFile.md
@@ -0,0 +1,14 @@
+# ConversationsMessageFile
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Filename** | **string** | Name of the file | [optional] [default to null]
+**Size** | **int64** | Size in bytes | [optional] [default to null]
+**IsImage** | **bool** | Whether the file is an image | [optional] [default to null]
+**Url** | **string** | URL of the file | [optional] [default to null]
+**ImageInfo** | [***ConversationsMessageFileImageInfo**](ConversationsMessageFileImageInfo.md) | | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/ConversationsMessageFileImageInfo.md b/docs/ConversationsMessageFileImageInfo.md
new file mode 100644
index 0000000..25b5229
--- /dev/null
+++ b/docs/ConversationsMessageFileImageInfo.md
@@ -0,0 +1,12 @@
+# ConversationsMessageFileImageInfo
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Width** | **int64** | Width of the image | [optional] [default to null]
+**Height** | **int64** | height of the image | [optional] [default to null]
+**PreviewUrl** | **string** | URL of the preview | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateApiKeyRequest.md b/docs/CreateApiKeyRequest.md
new file mode 100644
index 0000000..6a3826e
--- /dev/null
+++ b/docs/CreateApiKeyRequest.md
@@ -0,0 +1,11 @@
+# CreateApiKeyRequest
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **int64** | Id of the sub-account organization | [default to null]
+**Name** | **string** | Name of the API key | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateApiKeyResponse.md b/docs/CreateApiKeyResponse.md
new file mode 100644
index 0000000..6c2b33a
--- /dev/null
+++ b/docs/CreateApiKeyResponse.md
@@ -0,0 +1,11 @@
+# CreateApiKeyResponse
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Status** | **string** | Status of the API operation. | [optional] [default to null]
+**Key** | **string** | API Key | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateAttribute.md b/docs/CreateAttribute.md
index bdb5f60..5cde77c 100644
--- a/docs/CreateAttribute.md
+++ b/docs/CreateAttribute.md
@@ -4,6 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Value** | **string** | Value of the attribute. Use only if the attribute's category is 'calculated' or 'global' | [optional] [default to null]
+**IsRecurring** | **bool** | Type of the calculated attribute. Use only if the attribute's category is 'calculated' | [optional] [default to null]
**Enumeration** | [**[]CreateAttributeEnumeration**](CreateAttributeEnumeration.md) | 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\"}] | [optional] [default to null]
**Type_** | **string** | 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 ) | [optional] [default to null]
diff --git a/docs/CreateCategoryModel.md b/docs/CreateCategoryModel.md
new file mode 100644
index 0000000..9b24bf7
--- /dev/null
+++ b/docs/CreateCategoryModel.md
@@ -0,0 +1,10 @@
+# CreateCategoryModel
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **int64** | ID of the category when a new category is created | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateContact.md b/docs/CreateContact.md
index cea3eb3..c13bbcb 100644
--- a/docs/CreateContact.md
+++ b/docs/CreateContact.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Email** | **string** | Email address of the user. Mandatory if \"SMS\" field is not passed in \"attributes\" parameter. Mobile Number in \"SMS\" field should be passed with proper country code. For example {\"SMS\":\"+91xxxxxxxxxx\"} or {\"SMS\":\"0091xxxxxxxxxx\"} | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes and their values. The attribute's parameter should be passed in capital letter while creating a contact. These attributes must be present in your SendinBlue account. For eg. {\"FNAME\":\"Elly\", \"LNAME\":\"Roger\"} | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Pass the set of attributes and their values. The attribute's parameter should be passed in capital letter while creating a contact. These attributes must be present in your SendinBlue account. For eg. {\"FNAME\":\"Elly\", \"LNAME\":\"Roger\"} | [optional] [default to null]
**EmailBlacklisted** | **bool** | Set this field to blacklist the contact for emails (emailBlacklisted = true) | [optional] [default to null]
**SmsBlacklisted** | **bool** | Set this field to blacklist the contact for SMS (smsBlacklisted = true) | [optional] [default to null]
**ListIds** | **[]int64** | Ids of the lists to add the contact to | [optional] [default to null]
diff --git a/docs/CreateDoiContact.md b/docs/CreateDoiContact.md
index 62075c6..2b456c4 100644
--- a/docs/CreateDoiContact.md
+++ b/docs/CreateDoiContact.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Email** | **string** | Email address where the confirmation email will be sent. This email address will be the identifier for all other contact attributes. | [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For eg. {'FNAME':'Elly', 'LNAME':'Roger'} | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For eg. {'FNAME':'Elly', 'LNAME':'Roger'} | [optional] [default to null]
**IncludeListIds** | **[]int64** | Lists under user account where contact should be added | [default to null]
**ExcludeListIds** | **[]int64** | Lists under user account where contact should not be added | [optional] [default to null]
**TemplateId** | **int64** | Id of the Double opt-in (DOI) template | [default to null]
diff --git a/docs/CreateEmailCampaign.md b/docs/CreateEmailCampaign.md
index 8720aeb..ef3edf7 100644
--- a/docs/CreateEmailCampaign.md
+++ b/docs/CreateEmailCampaign.md
@@ -13,14 +13,14 @@ Name | Type | Description | Notes
**Subject** | **string** | Subject of the campaign. Mandatory if abTesting is false. Ignored if abTesting is true. | [optional] [default to null]
**ReplyTo** | **string** | Email on which the campaign recipients will be able to reply to | [optional] [default to null]
**ToField** | **string** | 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 | [optional] [default to null]
-**Recipients** | [***CreateEmailCampaignRecipients**](createEmailCampaign_recipients.md) | | [optional] [default to null]
+**Recipients** | [***CreateEmailCampaignRecipients**](CreateEmailCampaignRecipients.md) | | [optional] [default to null]
**AttachmentUrl** | **string** | 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 | [optional] [default to null]
**InlineImageActivation** | **bool** | Use true to embedded the images in your email. Final size of the email should be less than 4MB. Campaigns with embedded images can not be sent to more than 5000 contacts | [optional] [default to null]
**MirrorActive** | **bool** | Use true to enable the mirror link | [optional] [default to null]
**Footer** | **string** | Footer of the email campaign | [optional] [default to null]
**Header** | **string** | Header of the email campaign | [optional] [default to null]
**UtmCampaign** | **string** | Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed | [optional] [default to null]
-**Params** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes to customize the type classic campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. Only available if 'type' is 'classic'. It's considered only if campaign is in New Template Language format. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField' | [optional] [default to null]
+**Params** | [***interface{}**](interface{}.md) | Pass the set of attributes to customize the type classic campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. Only available if 'type' is 'classic'. It's considered only if campaign is in New Template Language format. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField' | [optional] [default to null]
**SendAtBestTime** | **bool** | Set this to true if you want to send your campaign at best time. | [optional] [default to null]
**AbTesting** | **bool** | Status of A/B Test. abTesting = false means it is disabled, & abTesting = true means it is enabled. 'subjectA', 'subjectB', 'splitRule', 'winnerCriteria' & 'winnerDelay' will be considered when abTesting is set to true. 'subjectA' & 'subjectB' are mandatory together & 'subject' if passed is ignored. Can be set to true only if 'sendAtBestTime' is 'false'. You will be able to set up two subject lines for your campaign and send them to a random sample of your total recipients. Half of the test group will receive version A, and the other half will receive version B | [optional] [default to null]
**SubjectA** | **string** | Subject A of the campaign. Mandatory if abTesting = true. subjectA & subjectB should have unique value | [optional] [default to null]
@@ -31,6 +31,8 @@ Name | Type | Description | Notes
**IpWarmupEnable** | **bool** | Available for dedicated ip clients. Set this to true if you wish to warm up your ip. | [optional] [default to null]
**InitialQuota** | **int64** | Mandatory if ipWarmupEnable is set to true. Set an initial quota greater than 1 for warming up your ip. We recommend you set a value of 3000. | [optional] [default to null]
**IncreaseRate** | **int64** | Mandatory if ipWarmupEnable is set to true. Set a percentage increase rate for warming up your ip. We recommend you set the increase rate to 30% per day. If you want to send the same number of emails every day, set the daily increase value to 0%. | [optional] [default to null]
+**UnsubscriptionPageId** | **string** | Enter an unsubscription page id. The page id is a 24 digit alphanumeric id that can be found in the URL when editing the page. If not entered, then the default unsubscription page will be used. | [optional] [default to null]
+**UpdateFormId** | **string** | Mandatory if templateId is used containing the {{ update_profile }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric id that can be found in the URL when editing the form. If not entered, then the default update profile form will be used. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/CreateEmailCampaignRecipients.md b/docs/CreateEmailCampaignRecipients.md
index baeec99..cb42227 100644
--- a/docs/CreateEmailCampaignRecipients.md
+++ b/docs/CreateEmailCampaignRecipients.md
@@ -5,6 +5,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**ExclusionListIds** | **[]int64** | List ids to exclude from the campaign | [optional] [default to null]
**ListIds** | **[]int64** | Mandatory if scheduledAt is not empty. List Ids to send the campaign to | [optional] [default to null]
+**SegmentIds** | **[]int64** | Mandatory if listIds are not used. Segment ids to send the campaign to. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/CreateProductModel.md b/docs/CreateProductModel.md
new file mode 100644
index 0000000..ed6beda
--- /dev/null
+++ b/docs/CreateProductModel.md
@@ -0,0 +1,10 @@
+# CreateProductModel
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **int64** | ID of the Product when a new product is created | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateSmsCampaign.md b/docs/CreateSmsCampaign.md
index 7dbd11f..f7b190b 100644
--- a/docs/CreateSmsCampaign.md
+++ b/docs/CreateSmsCampaign.md
@@ -9,6 +9,8 @@ Name | Type | Description | Notes
**Recipients** | [***CreateSmsCampaignRecipients**](CreateSmsCampaignRecipients.md) | | [optional] [default to null]
**ScheduledAt** | **string** | 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. | [optional] [default to null]
**UnicodeEnabled** | **bool** | Format of the message. It indicates whether the content should be treated as unicode or not. | [optional] [default to null]
+**OrganisationPrefix** | **string** | A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.** | [optional] [default to null]
+**UnsubscribeInstruction** | **string** | Instructions to unsubscribe from future communications. Recommended by U.S. carriers. Must include **STOP** keyword. This will be added as instructions after the end of message content. **Prefer verifying maximum length of 160 characters including this instructions in message content to avoid multiple sending of same sms.** | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/CreateUpdateBatchCategory.md b/docs/CreateUpdateBatchCategory.md
new file mode 100644
index 0000000..c22afc9
--- /dev/null
+++ b/docs/CreateUpdateBatchCategory.md
@@ -0,0 +1,11 @@
+# CreateUpdateBatchCategory
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Categories** | [**[]CreateUpdateCategories**](CreateUpdateCategories.md) | array of categories objects | [default to null]
+**UpdateEnabled** | **bool** | Facilitate to update the existing categories in the same request (updateEnabled = true) | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateBatchCategoryModel.md b/docs/CreateUpdateBatchCategoryModel.md
new file mode 100644
index 0000000..030f6ae
--- /dev/null
+++ b/docs/CreateUpdateBatchCategoryModel.md
@@ -0,0 +1,11 @@
+# CreateUpdateBatchCategoryModel
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**CreatedCount** | **int64** | Number of the new created categories | [optional] [default to null]
+**UpdatedCount** | **int64** | Number of the existing categories updated | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateBatchProducts.md b/docs/CreateUpdateBatchProducts.md
new file mode 100644
index 0000000..8b8db62
--- /dev/null
+++ b/docs/CreateUpdateBatchProducts.md
@@ -0,0 +1,11 @@
+# CreateUpdateBatchProducts
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Products** | [**[]CreateUpdateProducts**](CreateUpdateProducts.md) | array of products objects | [default to null]
+**UpdateEnabled** | **bool** | Facilitate to update the existing categories in the same request (updateEnabled = true) | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateBatchProductsModel.md b/docs/CreateUpdateBatchProductsModel.md
new file mode 100644
index 0000000..ad783c8
--- /dev/null
+++ b/docs/CreateUpdateBatchProductsModel.md
@@ -0,0 +1,11 @@
+# CreateUpdateBatchProductsModel
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**CreatedCount** | **int64** | Number of the new created products | [optional] [default to null]
+**UpdatedCount** | **int64** | Number of the existing products updated | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateCategories.md b/docs/CreateUpdateCategories.md
new file mode 100644
index 0000000..0c5c096
--- /dev/null
+++ b/docs/CreateUpdateCategories.md
@@ -0,0 +1,12 @@
+# CreateUpdateCategories
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Unique Category ID as saved in the shop | [default to null]
+**Name** | **string** | **Mandatory in case of creation**. Name of the Category, as displayed in the shop | [optional] [default to null]
+**Url** | **string** | URL to the category | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateCategory.md b/docs/CreateUpdateCategory.md
new file mode 100644
index 0000000..2819395
--- /dev/null
+++ b/docs/CreateUpdateCategory.md
@@ -0,0 +1,13 @@
+# CreateUpdateCategory
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Unique Category ID as saved in the shop | [default to null]
+**Name** | **string** | **Mandatory in case of creation**. Name of the Category, as displayed in the shop | [optional] [default to null]
+**Url** | **string** | URL to the category | [optional] [default to null]
+**UpdateEnabled** | **bool** | Facilitate to update the existing category in the same request (updateEnabled = true) | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateProduct.md b/docs/CreateUpdateProduct.md
new file mode 100644
index 0000000..5a7ee3c
--- /dev/null
+++ b/docs/CreateUpdateProduct.md
@@ -0,0 +1,19 @@
+# CreateUpdateProduct
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Product ID for which you requested the details | [default to null]
+**Name** | **string** | Mandatory in case of creation**. Name of the product for which you requested the details | [default to null]
+**Url** | **string** | URL to the product | [optional] [default to null]
+**ImageUrl** | **string** | Absolute URL to the cover image of the product | [optional] [default to null]
+**Sku** | **string** | Product identifier from the shop | [optional] [default to null]
+**Price** | **float32** | Price of the product | [optional] [default to null]
+**Categories** | **[]string** | Category ID-s of the product | [optional] [default to null]
+**ParentId** | **string** | Parent product id of the product | [optional] [default to null]
+**MetaInfo** | [**map[string]interface{}**](interface{}.md) | Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 10. | [optional] [default to null]
+**UpdateEnabled** | **bool** | Facilitate to update the existing category in the same request (updateEnabled = true) | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateUpdateProducts.md b/docs/CreateUpdateProducts.md
new file mode 100644
index 0000000..e299f68
--- /dev/null
+++ b/docs/CreateUpdateProducts.md
@@ -0,0 +1,18 @@
+# CreateUpdateProducts
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Product ID for which you requested the details | [default to null]
+**Name** | **string** | Mandatory in case of creation**. Name of the product for which you requested the details | [default to null]
+**Url** | **string** | URL to the product | [optional] [default to null]
+**ImageUrl** | **string** | Absolute URL to the cover image of the product | [optional] [default to null]
+**Sku** | **string** | Product identifier from the shop | [optional] [default to null]
+**Price** | **float32** | Price of the product | [optional] [default to null]
+**Categories** | **[]string** | Category ID-s of the product | [optional] [default to null]
+**ParentId** | **string** | Parent product id of the product | [optional] [default to null]
+**MetaInfo** | [**map[string]interface{}**](interface{}.md) | Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 10. | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreatedBatchId.md b/docs/CreatedBatchId.md
new file mode 100644
index 0000000..a35b25e
--- /dev/null
+++ b/docs/CreatedBatchId.md
@@ -0,0 +1,10 @@
+# CreatedBatchId
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**BatchId** | **float32** | Batch ID of the request | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/Deal.md b/docs/Deal.md
index c763752..46e87e9 100644
--- a/docs/Deal.md
+++ b/docs/Deal.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **string** | Unique deal id | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Deal attributes with values | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Deal attributes with values | [optional] [default to null]
**LinkedContactsIds** | **[]int32** | Contact ids for contacts linked to this deal | [optional] [default to null]
**LinkedCompaniesIds** | **[]string** | Companies ids for companies linked to this deal | [optional] [default to null]
diff --git a/docs/DealsApi.md b/docs/DealsApi.md
index e69112a..0a30b87 100644
--- a/docs/DealsApi.md
+++ b/docs/DealsApi.md
@@ -9,6 +9,7 @@ Method | HTTP request | Description
[**CrmDealsIdDelete**](DealsApi.md#CrmDealsIdDelete) | **Delete** /crm/deals/{id} | Delete a deal
[**CrmDealsIdGet**](DealsApi.md#CrmDealsIdGet) | **Get** /crm/deals/{id} | Get a deal
[**CrmDealsIdPatch**](DealsApi.md#CrmDealsIdPatch) | **Patch** /crm/deals/{id} | Update a deal
+[**CrmDealsLinkUnlinkIdPatch**](DealsApi.md#CrmDealsLinkUnlinkIdPatch) | **Patch** /crm/deals/link-unlink/{id} | Link and Unlink a deal with contacts and companies
[**CrmDealsPost**](DealsApi.md#CrmDealsPost) | **Post** /crm/deals | Create a deal
[**CrmPipelineDetailsGet**](DealsApi.md#CrmPipelineDetailsGet) | **Get** /crm/pipeline/details | Get pipeline stages
@@ -51,9 +52,9 @@ Optional parameters are passed through a pointer to a CrmDealsGetOpts struct
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **filterAttributes** | **optional.String**| Filter by attrbutes. If you have filter for owner on your side please send it as `attributes.owner`.\" |
- **filterLinkedCompaniesIds** | **optional.String**| Filter by linked companies ids |
- **filterLinkedContactsIds** | **optional.String**| Filter by linked companies ids |
+ **filtersAttributes** | **optional.String**| Filter by attrbutes. If you have filter for owner on your side please send it as `attributes.owner`.\" |
+ **filtersLinkedCompaniesIds** | **optional.String**| Filter by linked companies ids |
+ **filtersLinkedContactsIds** | **optional.String**| Filter by linked companies ids |
**offset** | **optional.Int64**| Index of the first document of the page |
**limit** | **optional.Int64**| Number of documents per page | [default to 50]
**sort** | **optional.String**| Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed |
@@ -136,7 +137,34 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
**id** | **string**| |
- **body** | [**Body1**](Body1.md)| Updated deal details. |
+ **body** | [**Body4**](Body4.md)| Updated deal details. |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmDealsLinkUnlinkIdPatch**
+> CrmDealsLinkUnlinkIdPatch(ctx, id, body)
+Link and Unlink a deal with contacts and companies
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| |
+ **body** | [**Body5**](Body5.md)| Linked / Unlinked contacts and companies ids. |
### Return type
@@ -162,7 +190,7 @@ Create a deal
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
- **body** | [**Body**](Body.md)| Deal create data. |
+ **body** | [**Body3**](Body3.md)| Deal create data. |
### Return type
diff --git a/docs/EcommerceApi.md b/docs/EcommerceApi.md
new file mode 100644
index 0000000..5a00ec8
--- /dev/null
+++ b/docs/EcommerceApi.md
@@ -0,0 +1,321 @@
+# \EcommerceApi
+
+All URIs are relative to *https://api.sendinblue.com/v3*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**CreateBatchOrder**](EcommerceApi.md#CreateBatchOrder) | **Post** /orders/status/batch | Maintains a batch of orders
+[**CreateOrder**](EcommerceApi.md#CreateOrder) | **Post** /orders/status | Maintains every transactional status of the order
+[**CreateUpdateBatchCategory**](EcommerceApi.md#CreateUpdateBatchCategory) | **Post** /categories/batch | Create the categories in a batch
+[**CreateUpdateBatchProducts**](EcommerceApi.md#CreateUpdateBatchProducts) | **Post** /products/batch | Creates the products in a batch
+[**CreateUpdateCategory**](EcommerceApi.md#CreateUpdateCategory) | **Post** /categories | Create/Update a category
+[**CreateUpdateProduct**](EcommerceApi.md#CreateUpdateProduct) | **Post** /products | Create/Update a product
+[**EcommerceActivatePost**](EcommerceApi.md#EcommerceActivatePost) | **Post** /ecommerce/activate | **Fulfills the eCommerce pre-requisites**
+[**GetCategories**](EcommerceApi.md#GetCategories) | **Get** /categories | Return all your categories
+[**GetCategoryInfo**](EcommerceApi.md#GetCategoryInfo) | **Get** /categories/{id} | Get a category details
+[**GetProductInfo**](EcommerceApi.md#GetProductInfo) | **Get** /products/{id} | Get a product's details
+[**GetProducts**](EcommerceApi.md#GetProducts) | **Get** /products | Return all your products
+
+
+# **CreateBatchOrder**
+> CreateBatchOrder(ctx, orderBatch)
+Maintains a batch of orders
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **orderBatch** | [**OrderBatch**](OrderBatch.md)| |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CreateOrder**
+> CreateOrder(ctx, order)
+Maintains every transactional status of the order
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **order** | [**Order**](Order.md)| |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CreateUpdateBatchCategory**
+> CreateUpdateBatchCategoryModel CreateUpdateBatchCategory(ctx, createUpdateBatchCategory)
+Create the categories in a batch
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **createUpdateBatchCategory** | [**CreateUpdateBatchCategory**](CreateUpdateBatchCategory.md)| Values to create a batch of categories |
+
+### Return type
+
+[**CreateUpdateBatchCategoryModel**](CreateUpdateBatchCategoryModel.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CreateUpdateBatchProducts**
+> CreateUpdateBatchProductsModel CreateUpdateBatchProducts(ctx, createUpdateBatchProducts)
+Creates the products in a batch
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **createUpdateBatchProducts** | [**CreateUpdateBatchProducts**](CreateUpdateBatchProducts.md)| Values to create a batch of products |
+
+### Return type
+
+[**CreateUpdateBatchProductsModel**](CreateUpdateBatchProductsModel.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CreateUpdateCategory**
+> CreateCategoryModel CreateUpdateCategory(ctx, createUpdateCategory)
+Create/Update a category
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **createUpdateCategory** | [**CreateUpdateCategory**](CreateUpdateCategory.md)| Values to create/update a category |
+
+### Return type
+
+[**CreateCategoryModel**](CreateCategoryModel.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CreateUpdateProduct**
+> CreateProductModel CreateUpdateProduct(ctx, createUpdateProduct)
+Create/Update a product
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **createUpdateProduct** | [**CreateUpdateProduct**](CreateUpdateProduct.md)| Values to create/update a product |
+
+### Return type
+
+[**CreateProductModel**](CreateProductModel.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **EcommerceActivatePost**
+> EcommerceActivatePost(ctx, )
+**Fulfills the eCommerce pre-requisites**
+
+### Required Parameters
+This endpoint does not need any parameter.
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **GetCategories**
+> GetCategories GetCategories(ctx, optional)
+Return all your categories
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **optional** | ***GetCategoriesOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a GetCategoriesOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **limit** | **optional.Int64**| Number of documents per page | [default to 50]
+ **offset** | **optional.Int64**| Index of the first document in the page | [default to 0]
+ **sort** | **optional.String**| Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed | [default to desc]
+ **ids** | [**optional.Interface of []string**](string.md)| Filter by category ids |
+
+### Return type
+
+[**GetCategories**](GetCategories.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **GetCategoryInfo**
+> GetCategoryDetails GetCategoryInfo(ctx, id)
+Get a category details
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| Category ID |
+
+### Return type
+
+[**GetCategoryDetails**](GetCategoryDetails.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **GetProductInfo**
+> GetProductDetails GetProductInfo(ctx, id)
+Get a product's details
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| Product ID |
+
+### Return type
+
+[**GetProductDetails**](GetProductDetails.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **GetProducts**
+> GetProducts GetProducts(ctx, optional)
+Return all your products
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **optional** | ***GetProductsOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a GetProductsOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **limit** | **optional.Int64**| Number of documents per page | [default to 50]
+ **offset** | **optional.Int64**| Index of the first document in the page | [default to 0]
+ **sort** | **optional.String**| Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed | [default to desc]
+ **ids** | [**optional.Interface of []string**](string.md)| Filter by product ids |
+
+### Return type
+
+[**GetProducts**](GetProducts.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/EmailCampaignsApi.md b/docs/EmailCampaignsApi.md
index 649b36b..0aaa1be 100644
--- a/docs/EmailCampaignsApi.md
+++ b/docs/EmailCampaignsApi.md
@@ -364,7 +364,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **UploadImageToGallery**
-> UploadImageToGallery(ctx, uploadImage)
+> UploadImageModel UploadImageToGallery(ctx, uploadImage)
Upload an image to your account's image gallery
### Required Parameters
@@ -376,7 +376,7 @@ Name | Type | Description | Notes
### Return type
- (empty response body)
+[**UploadImageModel**](UploadImageModel.md)
### Authorization
diff --git a/docs/FileData.md b/docs/FileData.md
new file mode 100644
index 0000000..054ff26
--- /dev/null
+++ b/docs/FileData.md
@@ -0,0 +1,16 @@
+# FileData
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Name** | **string** | Name of uploaded file | [optional] [default to null]
+**AuthorId** | **string** | Account id of user which created the file | [optional] [default to null]
+**ContactId** | **int64** | Contact id of contact on which file is uploaded | [optional] [default to null]
+**DealId** | **string** | Deal id linked to a file | [optional] [default to null]
+**CompanyId** | **string** | Company id linked to a file | [optional] [default to null]
+**Size** | **int64** | Size of file in bytes | [optional] [default to null]
+**CreatedAt** | [**time.Time**](time.Time.md) | File created date/time | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/FileDownloadableLink.md b/docs/FileDownloadableLink.md
new file mode 100644
index 0000000..017c3ed
--- /dev/null
+++ b/docs/FileDownloadableLink.md
@@ -0,0 +1,10 @@
+# FileDownloadableLink
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**FileUrl** | **string** | A unique link to download the requested file. | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/FileList.md b/docs/FileList.md
new file mode 100644
index 0000000..887c2d9
--- /dev/null
+++ b/docs/FileList.md
@@ -0,0 +1,9 @@
+# FileList
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/FilesApi.md b/docs/FilesApi.md
new file mode 100644
index 0000000..5c525cc
--- /dev/null
+++ b/docs/FilesApi.md
@@ -0,0 +1,167 @@
+# \FilesApi
+
+All URIs are relative to *https://api.sendinblue.com/v3*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**CrmFilesGet**](FilesApi.md#CrmFilesGet) | **Get** /crm/files | Get all files
+[**CrmFilesIdDataGet**](FilesApi.md#CrmFilesIdDataGet) | **Get** /crm/files/{id}/data | Get file details
+[**CrmFilesIdDelete**](FilesApi.md#CrmFilesIdDelete) | **Delete** /crm/files/{id} | Delete a file
+[**CrmFilesIdGet**](FilesApi.md#CrmFilesIdGet) | **Get** /crm/files/{id} | Download a file
+[**CrmFilesPost**](FilesApi.md#CrmFilesPost) | **Post** /crm/files | Upload a file
+
+
+# **CrmFilesGet**
+> FileList CrmFilesGet(ctx, optional)
+Get all files
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **optional** | ***CrmFilesGetOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a CrmFilesGetOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **entity** | **optional.String**| Filter by file entity type |
+ **entityIds** | **optional.String**| Filter by file entity IDs |
+ **dateFrom** | **optional.Int32**| dateFrom to date range filter type (timestamp in milliseconds) |
+ **dateTo** | **optional.Int32**| dateTo to date range filter type (timestamp in milliseconds) |
+ **offset** | **optional.Int64**| Index of the first document of the page |
+ **limit** | **optional.Int64**| Number of documents per page | [default to 50]
+ **sort** | **optional.String**| Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed |
+
+### Return type
+
+[**FileList**](FileList.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmFilesIdDataGet**
+> FileData CrmFilesIdDataGet(ctx, id)
+Get file details
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| File id to get file data. |
+
+### Return type
+
+[**FileData**](FileData.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmFilesIdDelete**
+> CrmFilesIdDelete(ctx, id)
+Delete a file
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| File id to delete. |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmFilesIdGet**
+> FileDownloadableLink CrmFilesIdGet(ctx, id)
+Download a file
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| File id to download. |
+
+### Return type
+
+[**FileDownloadableLink**](FileDownloadableLink.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmFilesPost**
+> FileData CrmFilesPost(ctx, file, optional)
+Upload a file
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **file** | ***os.File**| File data to create a file. |
+ **optional** | ***CrmFilesPostOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a CrmFilesPostOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+
+ **dealId** | **optional.String**| Deal id linked to a file |
+ **contactId** | **optional.Int64**| Contact id linked to a file |
+ **companyId** | **optional.String**| Company id linked to a file |
+
+### Return type
+
+[**FileData**](FileData.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/FoldersApi.md b/docs/FoldersApi.md
index ab464b6..45653a8 100644
--- a/docs/FoldersApi.md
+++ b/docs/FoldersApi.md
@@ -190,4 +190,3 @@ Name | Type | Description | Notes
- **Accept**: application/json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
-
diff --git a/docs/GetAttributesAttributes.md b/docs/GetAttributesAttributes.md
index 169d3c5..c332726 100644
--- a/docs/GetAttributesAttributes.md
+++ b/docs/GetAttributesAttributes.md
@@ -6,7 +6,7 @@ Name | Type | Description | Notes
**Name** | **string** | Name of the attribute | [default to null]
**Category** | **string** | Category of the attribute | [default to null]
**Type_** | **string** | Type of the attribute | [optional] [default to null]
-**Enumeration** | [**[]GetAttributesEnumeration**](getAttributes_enumeration.md) | Parameter only available for \"category\" type attributes. | [optional] [default to null]
+**Enumeration** | [**[]GetAttributesEnumeration**](GetAttributesEnumeration.md) | Parameter only available for \"category\" type attributes. | [optional] [default to null]
**CalculatedValue** | **string** | Calculated value formula | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetCategories.md b/docs/GetCategories.md
new file mode 100644
index 0000000..b3e2974
--- /dev/null
+++ b/docs/GetCategories.md
@@ -0,0 +1,11 @@
+# GetCategories
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Categories** | [**[]interface{}**](interface{}.md) | | [default to null]
+**Count** | **int64** | Number of categories | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/GetCategoryDetails.md b/docs/GetCategoryDetails.md
new file mode 100644
index 0000000..2c751cd
--- /dev/null
+++ b/docs/GetCategoryDetails.md
@@ -0,0 +1,14 @@
+# GetCategoryDetails
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Category ID for which you requested the details | [default to null]
+**Name** | **string** | Name of the category for which you requested the details | [default to null]
+**CreatedAt** | **string** | Creation UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
+**ModifiedAt** | **string** | Last modification UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
+**Url** | **string** | URL to the category | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/GetContactDetails.md b/docs/GetContactDetails.md
index 6388cf4..0677f68 100644
--- a/docs/GetContactDetails.md
+++ b/docs/GetContactDetails.md
@@ -11,7 +11,7 @@ Name | Type | Description | Notes
**ModifiedAt** | **string** | Last modification UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
**ListIds** | **[]int64** | | [default to null]
**ListUnsubscribed** | **[]int64** | | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Set of attributes of the contact | [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Set of attributes of the contact | [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetEmailCampaign.md b/docs/GetEmailCampaign.md
index 80aeed1..9e2c044 100644
--- a/docs/GetEmailCampaign.md
+++ b/docs/GetEmailCampaign.md
@@ -32,8 +32,8 @@ Name | Type | Description | Notes
**Recurring** | **bool** | FOR TRIGGER ONLY ! Type of trigger campaign.recurring = false means contact can receive the same Trigger campaign only once, & recurring = true means contact can receive the same Trigger campaign several times | [optional] [default to null]
**SentDate** | **string** | Sent UTC date-time of the campaign (YYYY-MM-DDTHH:mm:ss.SSSZ). Only available if 'status' of the campaign is 'sent' | [optional] [default to null]
**ReturnBounce** | **int64** | Total number of non-delivered campaigns for a particular campaign id. | [optional] [default to null]
-**Recipients** | [**map[string]interface{}**](interface{}.md) | | [default to null]
-**Statistics** | [**map[string]interface{}**](interface{}.md) | | [default to null]
+**Recipients** | [***interface{}**](interface{}.md) | | [default to null]
+**Statistics** | [***interface{}**](interface{}.md) | | [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetExtendedCampaignStats.md b/docs/GetExtendedCampaignStats.md
index a3c7985..a0256c7 100644
--- a/docs/GetExtendedCampaignStats.md
+++ b/docs/GetExtendedCampaignStats.md
@@ -3,11 +3,11 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**GlobalStats** | [**map[string]interface{}**](interface{}.md) | Overall statistics of the campaign | [default to null]
+**GlobalStats** | [***interface{}**](interface{}.md) | Overall statistics of the campaign | [default to null]
**CampaignStats** | [**[]interface{}**](interface{}.md) | List-wise statistics of the campaign. | [default to null]
**MirrorClick** | **int64** | Number of clicks on mirror link | [default to null]
**Remaining** | **int64** | Number of remaning emails to send | [default to null]
-**LinksStats** | [**map[string]interface{}**](interface{}.md) | Statistics about the number of clicks for the links | [default to null]
+**LinksStats** | [***interface{}**](interface{}.md) | Statistics about the number of clicks for the links | [default to null]
**StatsByDomain** | [***GetStatsByDomain**](GetStatsByDomain.md) | | [default to null]
**StatsByDevice** | [***GetStatsByDevice**](GetStatsByDevice.md) | Statistics about the campaign on the basis of various devices | [default to null]
**StatsByBrowser** | [***GetStatsByBrowser**](GetStatsByBrowser.md) | Statistics about the campaign on the basis of various browsers | [default to null]
diff --git a/docs/GetExtendedContactDetails.md b/docs/GetExtendedContactDetails.md
index f208268..82c7392 100644
--- a/docs/GetExtendedContactDetails.md
+++ b/docs/GetExtendedContactDetails.md
@@ -11,7 +11,7 @@ Name | Type | Description | Notes
**ModifiedAt** | **string** | Last modification UTC date-time of the contact (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
**ListIds** | **[]int64** | | [default to null]
**ListUnsubscribed** | **[]int64** | | [optional] [default to null]
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Set of attributes of the contact | [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Set of attributes of the contact | [default to null]
**Statistics** | [***GetExtendedContactDetailsStatistics**](GetExtendedContactDetailsStatistics.md) | | [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetProductDetails.md b/docs/GetProductDetails.md
new file mode 100644
index 0000000..63d596a
--- /dev/null
+++ b/docs/GetProductDetails.md
@@ -0,0 +1,22 @@
+# GetProductDetails
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Product ID for which you requested the details | [default to null]
+**Name** | **string** | Name of the product for which you requested the details | [default to null]
+**CreatedAt** | **string** | Creation UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
+**ModifiedAt** | **string** | Last modification UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
+**Url** | **string** | URL to the product | [optional] [default to null]
+**ImageUrl** | **string** | Absolute URL to the cover image of the product | [optional] [default to null]
+**Sku** | **string** | Product identifier from the shop | [optional] [default to null]
+**Price** | **float32** | Price of the product | [optional] [default to null]
+**Categories** | **[]string** | Category ID-s of the product | [optional] [default to null]
+**ParentId** | **string** | Parent product id of the product | [optional] [default to null]
+**S3Original** | **string** | S3 url of original image | [optional] [default to null]
+**S3ThumbAnalytics** | **string** | S3 thumbnail url of original image in 120x120 dimension for analytics section | [default to null]
+**S3ThumbEditor** | **string** | S3 thumbnail url of original image in 600x400 dimension for editor section | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/GetProducts.md b/docs/GetProducts.md
new file mode 100644
index 0000000..e1efc6e
--- /dev/null
+++ b/docs/GetProducts.md
@@ -0,0 +1,11 @@
+# GetProducts
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Products** | [**[]interface{}**](interface{}.md) | | [default to null]
+**Count** | **int64** | Number of products | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/GetSmsCampaign.md b/docs/GetSmsCampaign.md
index 3a75f38..d5f6978 100644
--- a/docs/GetSmsCampaign.md
+++ b/docs/GetSmsCampaign.md
@@ -11,8 +11,8 @@ Name | Type | Description | Notes
**Sender** | **string** | Sender of the SMS Campaign | [default to null]
**CreatedAt** | **string** | Creation UTC date-time of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
**ModifiedAt** | **string** | UTC date-time of last modification of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
-**Recipients** | [**map[string]interface{}**](interface{}.md) | | [default to null]
-**Statistics** | [**map[string]interface{}**](interface{}.md) | | [default to null]
+**Recipients** | [***interface{}**](interface{}.md) | | [default to null]
+**Statistics** | [***interface{}**](interface{}.md) | | [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetSmsEventReport.md b/docs/GetSmsEventReport.md
index 23bf6a1..d1fddf1 100644
--- a/docs/GetSmsEventReport.md
+++ b/docs/GetSmsEventReport.md
@@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Events** | [**[]GetSmsEventReportEvents**](GetSmsEventReportEvents.md) | | [optional] [default to null]
+**Events** | [**[]GetSmsEventReportEvents**](getSmsEventReportEvents.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/GetWebhook.md b/docs/GetWebhook.md
index 100c656..fab9f39 100644
--- a/docs/GetWebhook.md
+++ b/docs/GetWebhook.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
**Id** | **int64** | ID of the webhook | [default to null]
**Description** | **string** | Description of the webhook | [default to null]
**Events** | **[]string** | | [default to null]
-**Type_** | **string** | Type of webhook (marketing or transac) | [default to null]
+**Type_** | **string** | Type of webhook (marketing or transactional) | [default to null]
**CreatedAt** | **string** | Creation UTC date-time of the webhook (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
**ModifiedAt** | **string** | Last modification UTC date-time of the webhook (YYYY-MM-DDTHH:mm:ss.SSSZ) | [default to null]
diff --git a/docs/InboundParsingApi.md b/docs/InboundParsingApi.md
index 7bdc0b2..58d8876 100644
--- a/docs/InboundParsingApi.md
+++ b/docs/InboundParsingApi.md
@@ -4,10 +4,39 @@ All URIs are relative to *https://api.sendinblue.com/v3*
Method | HTTP request | Description
------------- | ------------- | -------------
+[**GetInboundEmailAttachment**](InboundParsingApi.md#GetInboundEmailAttachment) | **Get** /inbound/attachments/{downloadToken} | Retrieve inbound attachment with download token.
[**GetInboundEmailEvents**](InboundParsingApi.md#GetInboundEmailEvents) | **Get** /inbound/events | Get the list of all the events for the received emails.
[**GetInboundEmailEventsByUuid**](InboundParsingApi.md#GetInboundEmailEventsByUuid) | **Get** /inbound/events/{uuid} | Fetch all events history for one particular received email.
+# **GetInboundEmailAttachment**
+> *os.File GetInboundEmailAttachment(ctx, downloadToken)
+Retrieve inbound attachment with download token.
+
+This endpoint will retrieve inbound attachment with download token.
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **downloadToken** | **string**| Token to fetch a particular attachment |
+
+### Return type
+
+[***os.File**](*os.File.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **GetInboundEmailEvents**
> GetInboundEmailEvents GetInboundEmailEvents(ctx, optional)
Get the list of all the events for the received emails.
diff --git a/docs/ListsApi.md b/docs/ListsApi.md
index 3028ccb..b16683e 100644
--- a/docs/ListsApi.md
+++ b/docs/ListsApi.md
@@ -283,4 +283,3 @@ Name | Type | Description | Notes
- **Accept**: application/json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
-
diff --git a/docs/MasterAccountApi.md b/docs/MasterAccountApi.md
index 31a7345..303850e 100644
--- a/docs/MasterAccountApi.md
+++ b/docs/MasterAccountApi.md
@@ -9,6 +9,7 @@ Method | HTTP request | Description
[**CorporateSubAccountIdDelete**](MasterAccountApi.md#CorporateSubAccountIdDelete) | **Delete** /corporate/subAccount/{id} | Delete a sub-account
[**CorporateSubAccountIdGet**](MasterAccountApi.md#CorporateSubAccountIdGet) | **Get** /corporate/subAccount/{id} | Get sub-account details
[**CorporateSubAccountIdPlanPut**](MasterAccountApi.md#CorporateSubAccountIdPlanPut) | **Put** /corporate/subAccount/{id}/plan | Update sub-account plan
+[**CorporateSubAccountKeyPost**](MasterAccountApi.md#CorporateSubAccountKeyPost) | **Post** /corporate/subAccount/key | Create an API key for a sub-account
[**CorporateSubAccountPost**](MasterAccountApi.md#CorporateSubAccountPost) | **Post** /corporate/subAccount | Create a new sub-account under a master account.
[**CorporateSubAccountSsoTokenPost**](MasterAccountApi.md#CorporateSubAccountSsoTokenPost) | **Post** /corporate/subAccount/ssoToken | Generate SSO token to access Sendinblue
@@ -149,6 +150,34 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+# **CorporateSubAccountKeyPost**
+> CreateApiKeyResponse CorporateSubAccountKeyPost(ctx, createApiKeyRequest)
+Create an API key for a sub-account
+
+This endpoint will generate an API v3 key for a sub account
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **createApiKeyRequest** | [**CreateApiKeyRequest**](CreateApiKeyRequest.md)| Values to generate API key for sub-account |
+
+### Return type
+
+[**CreateApiKeyResponse**](CreateApiKeyResponse.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **CorporateSubAccountPost**
> CreateSubAccountResponse CorporateSubAccountPost(ctx, subAccountCreate)
Create a new sub-account under a master account.
@@ -181,7 +210,7 @@ Name | Type | Description | Notes
> GetSsoToken CorporateSubAccountSsoTokenPost(ctx, ssoTokenRequest)
Generate SSO token to access Sendinblue
-This endpoint generates an sso token to authenticate and access a sub-account of the master using the account endpoint https://app.sendinblue.com/account/login/sub-account/sso/[token], where [token] will be replaced by the actual token.
+This endpoint generates an sso token to authenticate and access a sub-account of the master using the account endpoint https://account-app.sendinblue.com/account/login/sub-account/sso/[token], where [token] will be replaced by the actual token.
### Required Parameters
@@ -192,7 +221,7 @@ Name | Type | Description | Notes
### Return type
-[**GetSsoToken**](GetSsoToken.md)
+[**GetSsoToken**](CetSsoToken.md)
### Authorization
diff --git a/docs/Note.md b/docs/Note.md
index 7719b19..98929f6 100644
--- a/docs/Note.md
+++ b/docs/Note.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
**Text** | **string** | Text content of a note | [default to null]
**ContactIds** | **[]int32** | Contact ids linked to a note | [optional] [default to null]
**DealIds** | **[]string** | Deal ids linked to a note | [optional] [default to null]
-**AuthorId** | [**map[string]interface{}**](interface{}.md) | Account details of user which created the note | [optional] [default to null]
+**AuthorId** | [***interface{}**](interface{}.md) | Account details of user which created the note | [optional] [default to null]
**CreatedAt** | [**time.Time**](time.Time.md) | Note created date/time | [optional] [default to null]
**UpdatedAt** | [**time.Time**](time.Time.md) | Note updated date/time | [optional] [default to null]
diff --git a/docs/NoteData.md b/docs/NoteData.md
index 7480f49..ad8f438 100644
--- a/docs/NoteData.md
+++ b/docs/NoteData.md
@@ -6,6 +6,7 @@ Name | Type | Description | Notes
**Text** | **string** | Text content of a note | [default to null]
**ContactIds** | **[]int32** | Contact Ids linked to a note | [optional] [default to null]
**DealIds** | **[]string** | Deal Ids linked to a note | [optional] [default to null]
+**CompanyIds** | **[]string** | Company Ids linked to a note | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/NotesApi.md b/docs/NotesApi.md
new file mode 100644
index 0000000..05716a6
--- /dev/null
+++ b/docs/NotesApi.md
@@ -0,0 +1,157 @@
+# \NotesApi
+
+All URIs are relative to *https://api.sendinblue.com/v3*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**CrmNotesGet**](NotesApi.md#CrmNotesGet) | **Get** /crm/notes | Get all notes
+[**CrmNotesIdDelete**](NotesApi.md#CrmNotesIdDelete) | **Delete** /crm/notes/{id} | Delete a note
+[**CrmNotesIdGet**](NotesApi.md#CrmNotesIdGet) | **Get** /crm/notes/{id} | Get a note
+[**CrmNotesIdPatch**](NotesApi.md#CrmNotesIdPatch) | **Patch** /crm/notes/{id} | Update a note
+[**CrmNotesPost**](NotesApi.md#CrmNotesPost) | **Post** /crm/notes | Create a note
+
+
+# **CrmNotesGet**
+> NoteList CrmNotesGet(ctx, optional)
+Get all notes
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **optional** | ***CrmNotesGetOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a CrmNotesGetOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **entity** | **optional.String**| Filter by note entity type |
+ **entityIds** | **optional.String**| Filter by note entity IDs |
+ **dateFrom** | **optional.Int32**| dateFrom to date range filter type (timestamp in milliseconds) |
+ **dateTo** | **optional.Int32**| dateTo to date range filter type (timestamp in milliseconds) |
+ **offset** | **optional.Int64**| Index of the first document of the page |
+ **limit** | **optional.Int64**| Number of documents per page | [default to 50]
+ **sort** | **optional.String**| Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed |
+
+### Return type
+
+[**NoteList**](NoteList.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmNotesIdDelete**
+> CrmNotesIdDelete(ctx, id)
+Delete a note
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| Note ID to delete |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmNotesIdGet**
+> Note CrmNotesIdGet(ctx, id)
+Get a note
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| Note ID to get |
+
+### Return type
+
+[**Note**](Note.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmNotesIdPatch**
+> CrmNotesIdPatch(ctx, id, body)
+Update a note
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| Note ID to update |
+ **body** | [**NoteData**](NoteData.md)| Note data to update a note |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmNotesPost**
+> NoteId CrmNotesPost(ctx, body)
+Create a note
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **body** | [**NoteData**](NoteData.md)| Note data to create a note. |
+
+### Return type
+
+[**NoteId**](NoteId.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/Order.md b/docs/Order.md
new file mode 100644
index 0000000..c1a2721
--- /dev/null
+++ b/docs/Order.md
@@ -0,0 +1,18 @@
+# Order
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Id** | **string** | Unique ID of the order. | [default to null]
+**CreatedAt** | **string** | Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created. | [default to null]
+**UpdatedAt** | **string** | Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated. | [default to null]
+**Status** | **string** | State of the order. | [default to null]
+**Amount** | **float32** | Total amount of the order, including all shipping expenses, tax and the price of items. | [default to null]
+**Products** | [**[]OrderProducts**](OrderProducts.md) | | [default to null]
+**Email** | **string** | Email of the contact, Mandatory if \"phone\" field is not passed in \"billing\" parameter. | [optional] [default to null]
+**Billing** | [***OrderBilling**](OrderBilling.md) | | [optional] [default to null]
+**Coupons** | **[]string** | Coupons applied to the order. Stored case insensitive. | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/OrderBatch.md b/docs/OrderBatch.md
new file mode 100644
index 0000000..ee97bb6
--- /dev/null
+++ b/docs/OrderBatch.md
@@ -0,0 +1,11 @@
+# OrderBatch
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Orders** | [**[]Order**](Order.md) | array of order objects | [default to null]
+**NotifyUrl** | **string** | Notify Url provided by client to get the status of batch request | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/OrderBilling.md b/docs/OrderBilling.md
new file mode 100644
index 0000000..f1bd579
--- /dev/null
+++ b/docs/OrderBilling.md
@@ -0,0 +1,16 @@
+# OrderBilling
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Address** | **string** | Full billing address. | [optional] [default to null]
+**City** | **string** | Exact city of the address. | [optional] [default to null]
+**CountryCode** | **string** | Billing country 2-letter ISO code. | [optional] [default to null]
+**Phone** | **string** | Phone number to contact for further details about the order, Mandatory if \"email\" field is not passed. | [optional] [default to null]
+**PostCode** | **string** | Postcode for delivery and billing. | [optional] [default to null]
+**PaymentMethod** | **string** | How the visitor will pay for the item(s), e.g. paypal, check, etc. | [optional] [default to null]
+**Region** | **string** | Exact region (state/province) for delivery and billing. | [optional] [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/OrderProducts.md b/docs/OrderProducts.md
new file mode 100644
index 0000000..8d65084
--- /dev/null
+++ b/docs/OrderProducts.md
@@ -0,0 +1,13 @@
+# OrderProducts
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**ProductId** | **string** | ID of the product. | [default to null]
+**Quantity** | **float32** | How many pieces of the product the visitor has added to the cart. | [default to null]
+**VariantId** | **string** | Product ID of the red color shirts. | [optional] [default to null]
+**Price** | **float32** | The price of a unit of product | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/SendSmtpEmail.md b/docs/SendSmtpEmail.md
index 19e724a..815b102 100644
--- a/docs/SendSmtpEmail.md
+++ b/docs/SendSmtpEmail.md
@@ -12,9 +12,9 @@ Name | Type | Description | Notes
**Subject** | **string** | Subject of the message. Mandatory if 'templateId' is not passed | [optional] [default to null]
**ReplyTo** | [***SendSmtpEmailReplyTo**](SendSmtpEmailReplyTo.md) | | [optional] [default to null]
**Attachment** | [**[]SendSmtpEmailAttachment**](SendSmtpEmailAttachment.md) | Pass the absolute URL (no local file) or the base64 content of the attachment along with the attachment name (Mandatory if attachment content is passed). For example, `[{\"url\":\"https://attachment.domain.com/myAttachmentFromUrl.jpg\", \"name\":\"myAttachmentFromUrl.jpg\"}, {\"content\":\"base64 example content\", \"name\":\"myAttachmentFromBase64.jpg\"}]`. Allowed extensions for attachment file: 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, eps, odt, mp3, m4a, m4v, wma, ogg, flac, wav, aif, aifc, aiff, mp4, mov, avi, mkv, mpeg, mpg, wmv, pkpass and xlsm ( If 'templateId' is passed and is in New Template Language format then both attachment url and content are accepted. If template is in Old template Language format, then 'attachment' is ignored ) | [optional] [default to null]
-**Headers** | [**map[string]interface{}**](interface{}.md) | Pass the set of custom headers (not the standard headers) that shall be sent along the mail headers in the original email. 'sender.ip' header can be set (only for dedicated ip users) to mention the IP to be used for sending transactional emails. Headers are allowed in `This-Case-Only` (i.e. words separated by hyphen with first letter of each word in capital letter), they will be converted to such case styling if not in this format in the request payload. For example, `{\"sender.ip\":\"1.2.3.4\", \"X-Mailin-custom\":\"some_custom_header\", \"idempotencyKey\":\"abc-123\"}`. | [optional] [default to null]
+**Headers** | [***interface{}**](interface{}.md) | Pass the set of custom headers (not the standard headers) that shall be sent along the mail headers in the original email. 'sender.ip' header can be set (only for dedicated ip users) to mention the IP to be used for sending transactional emails. Headers are allowed in `This-Case-Only` (i.e. words separated by hyphen with first letter of each word in capital letter), they will be converted to such case styling if not in this format in the request payload. For example, `{\"sender.ip\":\"1.2.3.4\", \"X-Mailin-custom\":\"some_custom_header\", \"idempotencyKey\":\"abc-123\"}`. | [optional] [default to null]
**TemplateId** | **int64** | Id of the template. | [optional] [default to null]
-**Params** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes to customize the template. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. It's considered only if template is in New Template Language format. | [optional] [default to null]
+**Params** | [***interface{}**](interface{}.md) | Pass the set of attributes to customize the template. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. It's considered only if template is in New Template Language format. | [optional] [default to null]
**MessageVersions** | [**[]SendSmtpEmailMessageVersions**](SendSmtpEmailMessageVersions.md) | You can customize and send out multiple versions of a mail. templateId can be customized only if global parameter contains templateId. htmlContent and textContent can be customized only if any of the two, htmlContent or textContent, is present in global parameters. Some global parameters such as **to(mandatory), bcc, cc, replyTo, subject** can also be customized specific to each version. Total number of recipients in one API request must not exceed 2000. However, you can still pass upto 99 recipients maximum in one message version. The size of individual params in all the messageVersions shall not exceed 100 KB limit and that of cumulative params shall not exceed 1000 KB. You can follow this **step-by-step guide** on how to use **messageVersions** to batch send emails - https://developers.sendinblue.com/docs/batch-send-transactional-emails | [optional] [default to null]
**Tags** | **[]string** | Tag your emails to find them more easily | [optional] [default to null]
**ScheduledAt** | [**time.Time**](time.Time.md) | UTC date-time on which the email has to schedule (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for scheduling. There can be an expected delay of +5 minutes in scheduled email delivery. **Please note this feature is currently a public beta**. | [optional] [default to null]
diff --git a/docs/SendTransacSms.md b/docs/SendTransacSms.md
index 2f7d76d..71bdd9d 100644
--- a/docs/SendTransacSms.md
+++ b/docs/SendTransacSms.md
@@ -10,6 +10,7 @@ Name | Type | Description | Notes
**Tag** | **string** | Tag of the message | [optional] [default to null]
**WebUrl** | **string** | Webhook to call for each event triggered by the message (delivered etc.) | [optional] [default to null]
**UnicodeEnabled** | **bool** | Format of the message. It indicates whether the content should be treated as unicode or not. | [optional] [default to null]
+**OrganisationPrefix** | **string** | A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.** | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/SubAccountDetailsResponsePlanInfoFeatures.md b/docs/SubAccountDetailsResponsePlanInfoFeatures.md
index 8ecd5f1..a8b2b6c 100644
--- a/docs/SubAccountDetailsResponsePlanInfoFeatures.md
+++ b/docs/SubAccountDetailsResponsePlanInfoFeatures.md
@@ -3,9 +3,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Inbox** | [***SubAccountDetailsResponsePlanInfoFeaturesInbox**](SubAccountDetailsResponsePlanInfoFeaturesInbox.md) | | [optional] [default to null]
-**LandingPage** | [***SubAccountDetailsResponsePlanInfoFeaturesLandingPage**](SubAccountDetailsResponsePlanInfoFeaturesLandingPage.md) | | [optional] [default to null]
-**Users** | [***SubAccountDetailsResponsePlanInfoFeaturesUsers**](SubAccountDetailsResponsePlanInfoFeaturesUsers.md) | | [optional] [default to null]
+**Inbox** | [***SubAccountDetailsResponsePlanInfoFeaturesInbox**](SubAccountDetailsResponsePlanInfoFeaturesinbox.md) | | [optional] [default to null]
+**LandingPage** | [***SubAccountDetailsResponsePlanInfoFeaturesLandingPage**](SubAccountDetailsResponsePlanInfoFeatureslandingPage.md) | | [optional] [default to null]
+**Users** | [***SubAccountDetailsResponsePlanInfoFeaturesUsers**](SubAccountDetailsResponsePlanInfoFeaturesusers.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/SubAccountUpdatePlanRequest.md b/docs/SubAccountUpdatePlanRequest.md
index 3b4e4b1..4cef5be 100644
--- a/docs/SubAccountUpdatePlanRequest.md
+++ b/docs/SubAccountUpdatePlanRequest.md
@@ -3,8 +3,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Credits** | [***SubAccountUpdatePlanRequestCredits**](SubAccountUpdatePlanRequestCredits.md) | | [optional] [default to null]
-**Features** | [***SubAccountUpdatePlanRequestFeatures**](SubAccountUpdatePlanRequestFeatures.md) | | [optional] [default to null]
+**Credits** | [***SubAccountUpdatePlanRequestCredits**](SubAccountUpdatePlanRequestcredits.md) | | [optional] [default to null]
+**Features** | [***SubAccountUpdatePlanRequestFeatures**](SubAccountUpdatePlanRequestfeatures.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/SubAccountsResponse.md b/docs/SubAccountsResponse.md
index 8ac0c81..533cc56 100644
--- a/docs/SubAccountsResponse.md
+++ b/docs/SubAccountsResponse.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Count** | **int32** | Total number of subaccounts | [optional] [default to null]
-**SubAccounts** | [**[]SubAccountsResponseSubAccounts**](SubAccountsResponseSubAccounts.md) | | [optional] [default to null]
+**SubAccounts** | [**[]SubAccountsResponseSubAccounts**](SubAccountsResponsesubAccounts.md) | | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/TasksApi.md b/docs/TasksApi.md
new file mode 100644
index 0000000..6966b72
--- /dev/null
+++ b/docs/TasksApi.md
@@ -0,0 +1,186 @@
+# \TasksApi
+
+All URIs are relative to *https://api.sendinblue.com/v3*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**CrmTasksGet**](TasksApi.md#CrmTasksGet) | **Get** /crm/tasks | Get all tasks
+[**CrmTasksIdDelete**](TasksApi.md#CrmTasksIdDelete) | **Delete** /crm/tasks/{id} | Delete a task
+[**CrmTasksIdGet**](TasksApi.md#CrmTasksIdGet) | **Get** /crm/tasks/{id} | Get a task
+[**CrmTasksIdPatch**](TasksApi.md#CrmTasksIdPatch) | **Patch** /crm/tasks/{id} | Update a task
+[**CrmTasksPost**](TasksApi.md#CrmTasksPost) | **Post** /crm/tasks | Create a task
+[**CrmTasktypesGet**](TasksApi.md#CrmTasktypesGet) | **Get** /crm/tasktypes | Get all task types
+
+
+# **CrmTasksGet**
+> TaskList CrmTasksGet(ctx, optional)
+Get all tasks
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **optional** | ***CrmTasksGetOpts** | optional parameters | nil if no parameters
+
+### Optional Parameters
+Optional parameters are passed through a pointer to a CrmTasksGetOpts struct
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **filterType** | **optional.String**| Filter by task type (ID) |
+ **filterStatus** | **optional.String**| Filter by task status |
+ **filterDate** | **optional.String**| Filter by date |
+ **filterAssignTo** | **optional.String**| Filter by assignTo id |
+ **filterContacts** | **optional.String**| Filter by contact ids |
+ **filterDeals** | **optional.String**| Filter by deals ids |
+ **filterCompanies** | **optional.String**| Filter by companies ids |
+ **dateFrom** | **optional.Int32**| dateFrom to date range filter type (timestamp in milliseconds) |
+ **dateTo** | **optional.Int32**| dateTo to date range filter type (timestamp in milliseconds) |
+ **offset** | **optional.Int64**| Index of the first document of the page |
+ **limit** | **optional.Int64**| Number of documents per page | [default to 50]
+ **sort** | **optional.String**| Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed |
+ **sortBy** | **optional.String**| The field used to sort field names. |
+
+### Return type
+
+[**TaskList**](TaskList.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmTasksIdDelete**
+> CrmTasksIdDelete(ctx, id)
+Delete a task
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmTasksIdGet**
+> Task CrmTasksIdGet(ctx, id)
+Get a task
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| |
+
+### Return type
+
+[**Task**](Task.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmTasksIdPatch**
+> CrmTasksIdPatch(ctx, id, body)
+Update a task
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **id** | **string**| |
+ **body** | [**Body7**](Body7.md)| Updated task details. |
+
+### Return type
+
+ (empty response body)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmTasksPost**
+> InlineResponse2011 CrmTasksPost(ctx, body)
+Create a task
+
+### Required Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
+ **body** | [**Body6**](Body6.md)| Task name. |
+
+### Return type
+
+[**InlineResponse2011**](inlineresponse2011.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **CrmTasktypesGet**
+> TaskTypes CrmTasktypesGet(ctx, )
+Get all task types
+
+### Required Parameters
+This endpoint does not need any parameter.
+
+### Return type
+
+[**TaskTypes**](TaskTypes.md)
+
+### Authorization
+
+[api-key](../README.md#api-key), [partner-key](../README.md#partner-key)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/json
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/TransactionalEmailsApi.md b/docs/TransactionalEmailsApi.md
index f6f08cd..d7b6c2f 100644
--- a/docs/TransactionalEmailsApi.md
+++ b/docs/TransactionalEmailsApi.md
@@ -279,7 +279,7 @@ Optional parameters are passed through a pointer to a GetEmailEventReportOpts st
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **limit** | **optional.Int64**| Number limitation for the result returned | [default to 50]
+ **limit** | **optional.Int64**| Number limitation for the result returned | [default to 2500]
**offset** | **optional.Int64**| Beginning point in the list to retrieve from. | [default to 0]
**startDate** | **optional.String**| Mandatory if endDate is used. Starting date of the report (YYYY-MM-DD). Must be lower than equal to endDate |
**endDate** | **optional.String**| Mandatory if startDate is used. Ending date of the report (YYYY-MM-DD). Must be greater than equal to startDate |
diff --git a/docs/UpdateAttribute.md b/docs/UpdateAttribute.md
index e05ae4f..4e846d0 100644
--- a/docs/UpdateAttribute.md
+++ b/docs/UpdateAttribute.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Value** | **string** | Value of the attribute to update. Use only if the attribute's category is 'calculated' or 'global' | [optional] [default to null]
-**Enumeration** | [**[]UpdateAttributeEnumeration**](UpdateAttributeEnumeration.md) | List of the 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\"}] | [optional] [default to null]
+**Enumeration** | [**[]UpdateAttributeEnumeration**](UpdateAttributeenumeration.md) | List of the 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\"}] | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateBatchContacts.md b/docs/UpdateBatchContacts.md
index 9621aad..b557ce2 100644
--- a/docs/UpdateBatchContacts.md
+++ b/docs/UpdateBatchContacts.md
@@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Contacts** | [**[]UpdateBatchContactsContacts**](UpdateBatchContactsContacts.md) | List of contacts to be updated | [optional] [default to null]
+**Contacts** | [**[]UpdateBatchContactsContacts**](UpdateBatchContactscontacts.md) | List of contacts to be updated | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateContact.md b/docs/UpdateContact.md
index 05078b1..375394c 100644
--- a/docs/UpdateContact.md
+++ b/docs/UpdateContact.md
@@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**Attributes** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes to be updated. These attributes must be present in your account. To update existing email address of a contact with the new one please pass EMAIL in attributes. For example, `{ \"EMAIL\":\"newemail@domain.com\", \"FNAME\":\"Ellie\", \"LNAME\":\"Roger\"}`. The attribute's parameter should be passed in capital letter while updating a contact. Keep in mind transactional attributes can be updated the same way as normal attributes. Mobile Number in \"SMS\" field should be passed with proper country code. For example {\"SMS\":\"+91xxxxxxxxxx\"} or {\"SMS\":\"0091xxxxxxxxxx\"} | [optional] [default to null]
+**Attributes** | [***interface{}**](interface{}.md) | Pass the set of attributes to be updated. These attributes must be present in your account. To update existing email address of a contact with the new one please pass EMAIL in attributes. For example, `{ \"EMAIL\":\"newemail@domain.com\", \"FNAME\":\"Ellie\", \"LNAME\":\"Roger\"}`. The attribute's parameter should be passed in capital letter while updating a contact. Keep in mind transactional attributes can be updated the same way as normal attributes. Mobile Number in \"SMS\" field should be passed with proper country code. For example {\"SMS\":\"+91xxxxxxxxxx\"} or {\"SMS\":\"0091xxxxxxxxxx\"} | [optional] [default to null]
**EmailBlacklisted** | **bool** | Set/unset this field to blacklist/allow the contact for emails (emailBlacklisted = true) | [optional] [default to null]
**SmsBlacklisted** | **bool** | Set/unset this field to blacklist/allow the contact for SMS (smsBlacklisted = true) | [optional] [default to null]
**ListIds** | **[]int64** | Ids of the lists to add the contact to | [optional] [default to null]
diff --git a/docs/UpdateEmailCampaign.md b/docs/UpdateEmailCampaign.md
index e803785..fa0f456 100644
--- a/docs/UpdateEmailCampaign.md
+++ b/docs/UpdateEmailCampaign.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Tag** | **string** | Tag of the campaign | [optional] [default to null]
-**Sender** | [***UpdateEmailCampaignSender**](UpdateEmailCampaignSender.md) | | [optional] [default to null]
+**Sender** | [***UpdateEmailCampaignSender**](UpdateEmailCampaignsender.md) | | [optional] [default to null]
**Name** | **string** | Name of the campaign | [optional] [default to null]
**HtmlContent** | **string** | Body of the message (HTML version). If the campaign is designed using Drag & Drop editor via HTML content, then the design page will not have Drag & Drop editor access for that campaign. REQUIRED if htmlUrl is empty | [optional] [default to null]
**HtmlUrl** | **string** | Url which contents the body of the email message. REQUIRED if htmlContent is empty | [optional] [default to null]
@@ -12,7 +12,7 @@ Name | Type | Description | Notes
**Subject** | **string** | Subject of the campaign | [optional] [default to null]
**ReplyTo** | **string** | Email on which campaign recipients will be able to reply to | [optional] [default to null]
**ToField** | **string** | 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 | [optional] [default to null]
-**Recipients** | [***UpdateEmailCampaignRecipients**](UpdateEmailCampaignRecipients.md) | | [optional] [default to null]
+**Recipients** | [***UpdateEmailCampaignRecipients**](UpdateEmailCampaignrecipients.md) | | [optional] [default to null]
**AttachmentUrl** | **string** | 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 | [optional] [default to null]
**InlineImageActivation** | **bool** | Status of inline image. inlineImageActivation = false means image can’t be embedded, & inlineImageActivation = true means image can be embedded, in the email. You cannot send a campaign of more than 4MB with images embedded in the email. Campaigns with the images embedded in the email must be sent to less than 5000 contacts. | [optional] [default to null]
**MirrorActive** | **bool** | Status of mirror links in campaign. mirrorActive = false means mirror links are deactivated, & mirrorActive = true means mirror links are activated, in the campaign | [optional] [default to null]
@@ -20,7 +20,7 @@ Name | Type | Description | Notes
**Footer** | **string** | Footer of the email campaign | [optional] [default to null]
**Header** | **string** | Header of the email campaign | [optional] [default to null]
**UtmCampaign** | **string** | Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed | [optional] [default to null]
-**Params** | [**map[string]interface{}**](interface{}.md) | Pass the set of attributes to customize the type 'classic' campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. The 'params' field will get updated, only if the campaign is in New Template Language, else ignored. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField' | [optional] [default to null]
+**Params** | [***interface{}**](interface{}.md) | Pass the set of attributes to customize the type 'classic' campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. The 'params' field will get updated, only if the campaign is in New Template Language, else ignored. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField' | [optional] [default to null]
**SendAtBestTime** | **bool** | Set this to true if you want to send your campaign at best time. Note:- if true, warmup ip will be disabled. | [optional] [default to null]
**AbTesting** | **bool** | Status of A/B Test. abTesting = false means it is disabled, & abTesting = true means it is enabled. 'subjectA', 'subjectB', 'splitRule', 'winnerCriteria' & 'winnerDelay' will be considered if abTesting is set to true. 'subject' if passed is ignored. Can be set to true only if 'sendAtBestTime' is 'false'. You will be able to set up two subject lines for your campaign and send them to a random sample of your total recipients. Half of the test group will receive version A, and the other half will receive version B | [optional] [default to null]
**SubjectA** | **string** | Subject A of the campaign. Considered if abTesting = true. subjectA & subjectB should have unique value | [optional] [default to null]
@@ -31,6 +31,8 @@ Name | Type | Description | Notes
**IpWarmupEnable** | **bool** | Available for dedicated ip clients. Set this to true if you wish to warm up your ip. | [optional] [default to null]
**InitialQuota** | **int64** | Set an initial quota greater than 1 for warming up your ip. We recommend you set a value of 3000. | [optional] [default to null]
**IncreaseRate** | **int64** | Set a percentage increase rate for warming up your ip. We recommend you set the increase rate to 30% per day. If you want to send the same number of emails every day, set the daily increase value to 0%. | [optional] [default to null]
+**UnsubscriptionPageId** | **string** | Enter an unsubscription page id. The page id is a 24 digit alphanumeric id that can be found in the URL when editing the page. | [optional] [default to null]
+**UpdateFormId** | **string** | Mandatory if templateId is used containing the {{ update_profile }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric id that can be found in the URL when editing the form. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateEmailCampaignRecipients.md b/docs/UpdateEmailCampaignRecipients.md
index b2f1802..4565c34 100644
--- a/docs/UpdateEmailCampaignRecipients.md
+++ b/docs/UpdateEmailCampaignRecipients.md
@@ -4,7 +4,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**ExclusionListIds** | **[]int64** | List ids which have to be excluded from a campaign | [optional] [default to null]
-**ListIds** | **[]int64** | Lists Ids to send the campaign to. REQUIRED if already not present in campaign and scheduledAt is not empty | [optional] [default to null]
+**ListIds** | **[]int64** | Lists Ids to send the campaign to. Campaign should only be updated with listIds if listIds were used to create it. REQUIRED if already not present in campaign and scheduledAt is not empty | [optional] [default to null]
+**SegmentIds** | **[]int64** | Mandatory if listIds are not used. Campaign should only be updated with segmentIds if segmentIds were used to create it. Segment ids to send the campaign to. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateSender.md b/docs/UpdateSender.md
index eaec5bb..b016b73 100644
--- a/docs/UpdateSender.md
+++ b/docs/UpdateSender.md
@@ -5,7 +5,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Name** | **string** | From Name to update the sender | [optional] [default to null]
**Email** | **string** | From Email to update the sender | [optional] [default to null]
-**Ips** | [**[]CreateSenderIps**](CreateSenderIps.md) | Only in case of dedicated IP, IPs to associate to the sender. If passed, will replace all the existing IPs. | [optional] [default to null]
+**Ips** | [**[]CreateSenderIps**](CreateSenderips.md) | Only in case of dedicated IP, IPs to associate to the sender. If passed, will replace all the existing IPs. | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateSmsCampaign.md b/docs/UpdateSmsCampaign.md
index f7fb6b1..c1f395b 100644
--- a/docs/UpdateSmsCampaign.md
+++ b/docs/UpdateSmsCampaign.md
@@ -6,9 +6,11 @@ Name | Type | Description | Notes
**Name** | **string** | Name of the campaign | [optional] [default to null]
**Sender** | **string** | Name of the sender. **The number of characters is limited to 11 for alphanumeric characters and 15 for numeric characters** | [optional] [default to null]
**Content** | **string** | 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 | [optional] [default to null]
-**Recipients** | [***CreateSmsCampaignRecipients**](CreateSmsCampaignRecipients.md) | | [optional] [default to null]
+**Recipients** | [***CreateSmsCampaignRecipients**](CreateSmsCampaignrecipients.md) | | [optional] [default to null]
**ScheduledAt** | **string** | 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. | [optional] [default to null]
**UnicodeEnabled** | **bool** | Format of the message. It indicates whether the content should be treated as unicode or not. | [optional] [default to null]
+**OrganisationPrefix** | **string** | A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.** | [optional] [default to null]
+**UnsubscribeInstruction** | **string** | Instructions to unsubscribe from future communications. Recommended by U.S. carriers. Must include **STOP** keyword. This will be added as instructions after the end of message content. **Prefer verifying maximum length of 160 characters including this instructions in message content to avoid multiple sending of same sms.** | [optional] [default to null]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/docs/UpdateSmtpTemplate.md b/docs/UpdateSmtpTemplate.md
index d3ee8b1..e0d9cd7 100644
--- a/docs/UpdateSmtpTemplate.md
+++ b/docs/UpdateSmtpTemplate.md
@@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Tag** | **string** | Tag of the template | [optional] [default to null]
-**Sender** | [***UpdateSmtpTemplateSender**](UpdateSmtpTemplateSender.md) | | [optional] [default to null]
+**Sender** | [***UpdateSmtpTemplateSender**](UpdateSmtpTemplatesender.md) | | [optional] [default to null]
**TemplateName** | **string** | Name of the template | [optional] [default to null]
**HtmlContent** | **string** | Required if htmlUrl is empty. If the template is designed using Drag & Drop editor via HTML content, then the design page will not have Drag & Drop editor access for that template. Body of the message (HTML must have more than 10 characters) | [optional] [default to null]
**HtmlUrl** | **string** | Required if htmlContent is empty. URL to the body of the email (HTML) | [optional] [default to null]
diff --git a/docs/UploadImageModel.md b/docs/UploadImageModel.md
new file mode 100644
index 0000000..373a75b
--- /dev/null
+++ b/docs/UploadImageModel.md
@@ -0,0 +1,10 @@
+# UploadImageModel
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Url** | **string** | URL of the image uploaded | [default to null]
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/lib/api_account.go b/lib/api_account.go
index 0ba406c..bed873a 100644
--- a/lib/api_account.go
+++ b/lib/api_account.go
@@ -27,7 +27,7 @@ type AccountApiService service
/*
AccountApiService Get your account information, plan and credits details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return GetAccount
*/
diff --git a/lib/api_companies.go b/lib/api_companies.go
index 5d64a62..71fdafd 100644
--- a/lib/api_companies.go
+++ b/lib/api_companies.go
@@ -30,7 +30,7 @@ type CompaniesApiService service
/*
CompaniesApiService Get company attributes
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return CompanyAttributes
*/
@@ -305,10 +305,8 @@ func (a *CompaniesApiService) CompaniesGet(ctx context.Context, localVarOptional
/*
CompaniesApiService Delete a company
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
*/
func (a *CompaniesApiService) CompaniesIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
@@ -421,8 +419,8 @@ func (a *CompaniesApiService) CompaniesIdDelete(ctx context.Context, id string)
/*
CompaniesApiService Get a company
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
@return Company
*/
@@ -557,13 +555,13 @@ func (a *CompaniesApiService) CompaniesIdGet(ctx context.Context, id string) (Co
/*
CompaniesApiService Update a company
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
- * @param body Updated company details.
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
+ - @param body Updated company details.
@return Company
*/
-func (a *CompaniesApiService) CompaniesIdPatch(ctx context.Context, id string, body Body3) (Company, *http.Response, error) {
+func (a *CompaniesApiService) CompaniesIdPatch(ctx context.Context, id string, body Body1) (Company, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Patch")
localVarPostBody interface{}
@@ -696,13 +694,11 @@ func (a *CompaniesApiService) CompaniesIdPatch(ctx context.Context, id string, b
/*
CompaniesApiService Link and Unlink company with contacts and deals
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
- * @param body Linked / Unlinked contacts and deals ids.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
+ - @param body Linked / Unlinked contacts and deals ids.
*/
-func (a *CompaniesApiService) CompaniesLinkUnlinkIdPatch(ctx context.Context, id string, body Body4) (*http.Response, error) {
+func (a *CompaniesApiService) CompaniesLinkUnlinkIdPatch(ctx context.Context, id string, body Body2) (*http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Patch")
localVarPostBody interface{}
@@ -804,12 +800,12 @@ func (a *CompaniesApiService) CompaniesLinkUnlinkIdPatch(ctx context.Context, id
/*
CompaniesApiService Create a company
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param body Company create data.
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param body Company create data.
@return InlineResponse200
*/
-func (a *CompaniesApiService) CompaniesPost(ctx context.Context, body Body2) (InlineResponse200, *http.Response, error) {
+func (a *CompaniesApiService) CompaniesPost(ctx context.Context, body Body) (InlineResponse200, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
diff --git a/lib/api_contacts.go b/lib/api_contacts.go
index 78768ae..788dfd6 100644
--- a/lib/api_contacts.go
+++ b/lib/api_contacts.go
@@ -30,9 +30,9 @@ type ContactsApiService service
/*
ContactsApiService Add existing contacts to a list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
- * @param contactEmails Emails addresses OR IDs of the contacts
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param listId Id of the list
+ - @param contactEmails Emails addresses OR IDs of the contacts
@return PostContactInfo
*/
@@ -169,12 +169,10 @@ func (a *ContactsApiService) AddContactToList(ctx context.Context, listId int64,
/*
ContactsApiService Create contact attribute
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the attribute
- * @param createAttribute Values to create an attribute
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param attributeCategory Category of the attribute
+ - @param attributeName Name of the attribute
+ - @param createAttribute Values to create an attribute
*/
func (a *ContactsApiService) CreateAttribute(ctx context.Context, attributeCategory string, attributeName string, createAttribute CreateAttribute) (*http.Response, error) {
var (
@@ -279,8 +277,8 @@ func (a *ContactsApiService) CreateAttribute(ctx context.Context, attributeCateg
/*
ContactsApiService Create a contact
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createContact Values to create a contact
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createContact Values to create a contact
@return CreateUpdateContactModel
*/
@@ -416,10 +414,8 @@ func (a *ContactsApiService) CreateContact(ctx context.Context, createContact Cr
/*
ContactsApiService Create Contact via DOI (Double-Opt-In) Flow
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createDoiContact Values to create the Double opt-in (DOI) contact
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createDoiContact Values to create the Double opt-in (DOI) contact
*/
func (a *ContactsApiService) CreateDoiContact(ctx context.Context, createDoiContact CreateDoiContact) (*http.Response, error) {
var (
@@ -522,8 +518,8 @@ func (a *ContactsApiService) CreateDoiContact(ctx context.Context, createDoiCont
/*
ContactsApiService Create a folder
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createFolder Name of the folder
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createFolder Name of the folder
@return CreateModel
*/
@@ -648,8 +644,8 @@ func (a *ContactsApiService) CreateFolder(ctx context.Context, createFolder Crea
/*
ContactsApiService Create a list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createList Values to create a list
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createList Values to create a list
@return CreateModel
*/
@@ -774,11 +770,9 @@ func (a *ContactsApiService) CreateList(ctx context.Context, createList CreateLi
/*
ContactsApiService Delete an attribute
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the existing attribute
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param attributeCategory Category of the attribute
+ - @param attributeName Name of the existing attribute
*/
func (a *ContactsApiService) DeleteAttribute(ctx context.Context, attributeCategory string, attributeName string) (*http.Response, error) {
var (
@@ -892,10 +886,8 @@ func (a *ContactsApiService) DeleteAttribute(ctx context.Context, attributeCateg
/*
ContactsApiService Delete a contact
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param identifier Email (urlencoded) OR ID of the contact
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param identifier Email (urlencoded) OR ID of the contact
*/
func (a *ContactsApiService) DeleteContact(ctx context.Context, identifier string) (*http.Response, error) {
var (
@@ -1019,10 +1011,8 @@ func (a *ContactsApiService) DeleteContact(ctx context.Context, identifier strin
/*
ContactsApiService Delete a folder (and all its lists)
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param folderId Id of the folder
*/
func (a *ContactsApiService) DeleteFolder(ctx context.Context, folderId int64) (*http.Response, error) {
var (
@@ -1135,10 +1125,8 @@ func (a *ContactsApiService) DeleteFolder(ctx context.Context, folderId int64) (
/*
ContactsApiService Delete a list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param listId Id of the list
*/
func (a *ContactsApiService) DeleteList(ctx context.Context, listId int64) (*http.Response, error) {
var (
@@ -1251,7 +1239,7 @@ func (a *ContactsApiService) DeleteList(ctx context.Context, listId int64) (*htt
/*
ContactsApiService List all attributes
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return GetAttributes
*/
@@ -1975,8 +1963,8 @@ func (a *ContactsApiService) GetContactsFromList(ctx context.Context, listId int
/*
ContactsApiService Returns a folder's details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId id of the folder
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param folderId id of the folder
@return GetFolder
*/
@@ -2295,6 +2283,9 @@ func (a *ContactsApiService) GetFolders(ctx context.Context, limit int64, offset
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
+ if limit < 0 {
+ return localVarReturnValue, nil, reportError("limit must be greater than 0")
+ }
if limit > 50 {
return localVarReturnValue, nil, reportError("limit must be less than 50")
}
@@ -2407,8 +2398,8 @@ func (a *ContactsApiService) GetFolders(ctx context.Context, limit int64, offset
/*
ContactsApiService Get a list's details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param listId Id of the list
@return GetExtendedList
*/
@@ -2687,8 +2678,8 @@ func (a *ContactsApiService) GetLists(ctx context.Context, localVarOptionals *Ge
/*
ContactsApiService Import contacts
It returns the background process ID which on completion calls the notify URL that you have set in the input.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param requestContactImport Values to import contacts in Sendinblue. To know more about the expected format, please have a look at ``https://help.sendinblue.com/hc/en-us/articles/209499265-Build-contacts-lists-for-your-email-marketing-campaigns``
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param requestContactImport Values to import contacts in Sendinblue. To know more about the expected format, please have a look at ``https://help.sendinblue.com/hc/en-us/articles/209499265-Build-contacts-lists-for-your-email-marketing-campaigns``
@return CreatedProcessId
*/
@@ -2813,9 +2804,9 @@ func (a *ContactsApiService) ImportContacts(ctx context.Context, requestContactI
/*
ContactsApiService Delete a contact from a list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
- * @param contactEmails Emails addresses OR IDs of the contacts
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param listId Id of the list
+ - @param contactEmails Emails addresses OR IDs of the contacts
@return PostContactInfo
*/
@@ -2953,8 +2944,8 @@ func (a *ContactsApiService) RemoveContactFromList(ctx context.Context, listId i
/*
ContactsApiService Export contacts
It returns the background process ID which on completion calls the notify URL that you have set in the input. File will be available in csv.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param requestContactExport Values to request a contact export
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param requestContactExport Values to request a contact export
@return CreatedProcessId
*/
@@ -3079,12 +3070,10 @@ func (a *ContactsApiService) RequestContactExport(ctx context.Context, requestCo
/*
ContactsApiService Update contact attribute
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the existing attribute
- * @param updateAttribute Values to update an attribute
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param attributeCategory Category of the attribute
+ - @param attributeName Name of the existing attribute
+ - @param updateAttribute Values to update an attribute
*/
func (a *ContactsApiService) UpdateAttribute(ctx context.Context, attributeCategory string, attributeName string, updateAttribute UpdateAttribute) (*http.Response, error) {
var (
@@ -3200,10 +3189,8 @@ func (a *ContactsApiService) UpdateAttribute(ctx context.Context, attributeCateg
/*
ContactsApiService Update multiple contacts
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param updateBatchContacts Values to update multiple contacts
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param updateBatchContacts Values to update multiple contacts
*/
func (a *ContactsApiService) UpdateBatchContacts(ctx context.Context, updateBatchContacts UpdateBatchContacts) (*http.Response, error) {
var (
@@ -3317,11 +3304,9 @@ func (a *ContactsApiService) UpdateBatchContacts(ctx context.Context, updateBatc
/*
ContactsApiService Update a contact
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param identifier Email (urlencoded) OR ID of the contact
- * @param updateContact Values to update a contact
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param identifier Email (urlencoded) OR ID of the contact
+ - @param updateContact Values to update a contact
*/
func (a *ContactsApiService) UpdateContact(ctx context.Context, identifier string, updateContact UpdateContact) (*http.Response, error) {
var (
@@ -3436,11 +3421,9 @@ func (a *ContactsApiService) UpdateContact(ctx context.Context, identifier strin
/*
ContactsApiService Update a folder
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
- * @param updateFolder Name of the folder
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param folderId Id of the folder
+ - @param updateFolder Name of the folder
*/
func (a *ContactsApiService) UpdateFolder(ctx context.Context, folderId int64, updateFolder CreateUpdateFolder) (*http.Response, error) {
var (
@@ -3555,11 +3538,9 @@ func (a *ContactsApiService) UpdateFolder(ctx context.Context, folderId int64, u
/*
ContactsApiService Update a list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
- * @param updateList Values to update a list
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param listId Id of the list
+ - @param updateList Values to update a list
*/
func (a *ContactsApiService) UpdateList(ctx context.Context, listId int64, updateList UpdateList) (*http.Response, error) {
var (
diff --git a/lib/api_lists.go b/lib/api_conversations.go
similarity index 77%
rename from lib/api_lists.go
rename to lib/api_conversations.go
index 4d5132f..d2bad14 100644
--- a/lib/api_lists.go
+++ b/lib/api_conversations.go
@@ -17,6 +17,8 @@ import (
"net/http"
"net/url"
"strings"
+
+ "github.com/antihax/optional"
)
// Linger please
@@ -24,28 +26,24 @@ var (
_ context.Context
)
-type ListsApiService service
+type ConversationsApiService service
/*
-ListsApiService Add existing contacts to a list
+ConversationsApiService Sets agent’s status to online for 2-3 minutes
+We recommend pinging this endpoint every minute for as long as the agent has to be considered online.
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param listId Id of the list
- - @param contactEmails Emails addresses OR IDs of the contacts
-
-@return PostContactInfo
+ - @param body Agent fields.
*/
-func (a *ListsApiService) AddContactToList(ctx context.Context, listId int64, contactEmails AddContactToList) (PostContactInfo, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsAgentOnlinePingPost(ctx context.Context, body Body12) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
- localVarReturnValue PostContactInfo
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}/contacts/add"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/agentOnlinePing"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -69,7 +67,7 @@ func (a *ListsApiService) AddContactToList(ctx context.Context, listId int64, co
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &contactEmails
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -98,26 +96,18 @@ func (a *ListsApiService) AddContactToList(ctx context.Context, listId int64, co
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return localVarReturnValue, nil, err
+ return nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarReturnValue, localVarHttpResponse, err
+ return localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
-
- if localVarHttpResponse.StatusCode < 300 {
- // If we succeed, return the data, otherwise pass on to decode error.
- err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err == nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
+ return localVarHttpResponse, err
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -126,63 +116,40 @@ func (a *ListsApiService) AddContactToList(ctx context.Context, listId int64, co
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 201 {
- var v PostContactInfo
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, nil
+ return localVarHttpResponse, nil
}
/*
-ListsApiService Create a list
+ConversationsApiService Delete a message sent by an agent
+Only agents’ messages can be deleted.
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param createList Values to create a list
-
-@return CreateModel
+ - @param id ID of the message
*/
-func (a *ListsApiService) CreateList(ctx context.Context, createList CreateList) (CreateModel, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsMessagesIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
- localVarReturnValue CreateModel
+ localVarHttpMethod = strings.ToUpper("Delete")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists"
+ localVarPath := a.client.cfg.BasePath + "/conversations/messages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -205,8 +172,6 @@ func (a *ListsApiService) CreateList(ctx context.Context, createList CreateList)
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &createList
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -235,26 +200,18 @@ func (a *ListsApiService) CreateList(ctx context.Context, createList CreateList)
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return localVarReturnValue, nil, err
+ return nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarReturnValue, localVarHttpResponse, err
+ return localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
-
- if localVarHttpResponse.StatusCode < 300 {
- // If we succeed, return the data, otherwise pass on to decode error.
- err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err == nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
+ return localVarHttpResponse, err
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -263,50 +220,53 @@ func (a *ListsApiService) CreateList(ctx context.Context, createList CreateList)
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 201 {
- var v CreateModel
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 400 {
+ if localVarHttpResponse.StatusCode == 404 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, nil
+ return localVarHttpResponse, nil
}
/*
-ListsApiService Delete a list
+ConversationsApiService Get a message
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param listId Id of the list
+ - @param id ID of the message
+
+@return ConversationsMessage
*/
-func (a *ListsApiService) DeleteList(ctx context.Context, listId int64) (*http.Response, error) {
+func (a *ConversationsApiService) ConversationsMessagesIdGet(ctx context.Context, id string) (ConversationsMessage, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Delete")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/messages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -357,18 +317,26 @@ func (a *ListsApiService) DeleteList(ctx context.Context, listId int64) (*http.R
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -377,15 +345,26 @@ func (a *ListsApiService) DeleteList(ctx context.Context, listId int64) (*http.R
error: localVarHttpResponse.Status,
}
+ if localVarHttpResponse.StatusCode == 200 {
+ var v ConversationsMessage
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
if localVarHttpResponse.StatusCode == 404 {
@@ -393,60 +372,50 @@ func (a *ListsApiService) DeleteList(ctx context.Context, listId int64) (*http.R
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
/*
-ListsApiService Get contacts in a list
+ConversationsApiService Update a message sent by an agent
+Only agents’ messages can be edited.
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param listId Id of the list
- * @param optional nil or *GetContactsFromListOpts - Optional Parameters:
- * @param "ModifiedSince" (optional.String) - Filter (urlencoded) the contacts modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
-
-@return GetContacts
+ * @param id ID of the message
+ * @param optional nil or *ConversationsMessagesIdPutOpts - Optional Parameters:
+ * @param "Body" (optional.Interface of Body9) -
+
+@return ConversationsMessage
*/
-func (a *ListsApiService) GetContactsFromList(ctx context.Context, listId int64, localVarOptionals *GetContactsFromListOpts) (GetContacts, *http.Response, error) {
+type ConversationsMessagesIdPutOpts struct {
+ Body optional.Interface
+}
+
+func (a *ConversationsApiService) ConversationsMessagesIdPut(ctx context.Context, id string, localVarOptionals *ConversationsMessagesIdPutOpts) (ConversationsMessage, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Put")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetContacts
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}/contacts"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/messages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.ModifiedSince.IsSet() {
- localVarQueryParams.Add("modifiedSince", parameterToString(localVarOptionals.ModifiedSince.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -464,6 +433,15 @@ func (a *ListsApiService) GetContactsFromList(ctx context.Context, listId int64,
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ if localVarOptionals != nil && localVarOptionals.Body.IsSet() {
+
+ localVarOptionalBody, localVarOptionalBodyok := localVarOptionals.Body.Value().(Body9)
+ if !localVarOptionalBodyok {
+ return localVarReturnValue, nil, reportError("body should be Body9")
+ }
+ localVarPostBody = &localVarOptionalBody
+ }
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -521,7 +499,7 @@ func (a *ListsApiService) GetContactsFromList(ctx context.Context, listId int64,
}
if localVarHttpResponse.StatusCode == 200 {
- var v GetContacts
+ var v ConversationsMessage
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -560,43 +538,28 @@ func (a *ListsApiService) GetContactsFromList(ctx context.Context, listId int64,
}
/*
-ListsApiService Get lists in a folder
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
- * @param optional nil or *GetFolderListsOpts - Optional Parameters:
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
+ConversationsApiService Send a message as an agent
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param body Message fields.
-@return GetFolderLists
+@return ConversationsMessage
*/
-
-func (a *ListsApiService) GetFolderLists(ctx context.Context, folderId int64, localVarOptionals *GetFolderListsOpts) (GetFolderLists, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsMessagesPost(ctx context.Context, body Body8) (ConversationsMessage, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetFolderLists
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders/{folderId}/lists"
- localVarPath = strings.Replace(localVarPath, "{"+"folderId"+"}", fmt.Sprintf("%v", folderId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/messages"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -614,6 +577,8 @@ func (a *ListsApiService) GetFolderLists(ctx context.Context, folderId int64, lo
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -671,7 +636,7 @@ func (a *ListsApiService) GetFolderLists(ctx context.Context, folderId int64, lo
}
if localVarHttpResponse.StatusCode == 200 {
- var v GetFolderLists
+ var v ConversationsMessage
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -692,17 +657,6 @@ func (a *ListsApiService) GetFolderLists(ctx context.Context, folderId int64, lo
return localVarReturnValue, localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
return localVarReturnValue, localVarHttpResponse, newErr
}
@@ -710,24 +664,21 @@ func (a *ListsApiService) GetFolderLists(ctx context.Context, folderId int64, lo
}
/*
-ListsApiService Get a list's details
+ConversationsApiService Delete an automated message
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param listId Id of the list
-
-@return GetExtendedList
+ - @param id ID of the message
*/
-func (a *ListsApiService) GetList(ctx context.Context, listId int64) (GetExtendedList, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsPushedMessagesIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
- localVarReturnValue GetExtendedList
+ localVarHttpMethod = strings.ToUpper("Delete")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/pushedMessages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -778,26 +729,18 @@ func (a *ListsApiService) GetList(ctx context.Context, listId int64) (GetExtende
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return localVarReturnValue, nil, err
+ return nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarReturnValue, localVarHttpResponse, err
+ return localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
-
- if localVarHttpResponse.StatusCode < 300 {
- // If we succeed, return the data, otherwise pass on to decode error.
- err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err == nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
+ return localVarHttpResponse, err
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -806,26 +749,15 @@ func (a *ListsApiService) GetList(ctx context.Context, listId int64) (GetExtende
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v GetExtendedList
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
if localVarHttpResponse.StatusCode == 404 {
@@ -833,54 +765,42 @@ func (a *ListsApiService) GetList(ctx context.Context, listId int64) (GetExtende
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, nil
+ return localVarHttpResponse, nil
}
/*
-ListsApiService Get all the lists
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param optional nil or *GetListsOpts - Optional Parameters:
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
+ConversationsApiService Get an automated message
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id ID of the message sent previously
-@return GetLists
+@return ConversationsMessage
*/
-
-func (a *ListsApiService) GetLists(ctx context.Context, localVarOptionals *GetListsOpts) (GetLists, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsPushedMessagesIdGet(ctx context.Context, id string) (ConversationsMessage, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetLists
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists"
+ localVarPath := a.client.cfg.BasePath + "/conversations/pushedMessages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -955,7 +875,7 @@ func (a *ListsApiService) GetLists(ctx context.Context, localVarOptionals *GetLi
}
if localVarHttpResponse.StatusCode == 200 {
- var v GetLists
+ var v ConversationsMessage
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -976,6 +896,17 @@ func (a *ListsApiService) GetLists(ctx context.Context, localVarOptionals *GetLi
return localVarReturnValue, localVarHttpResponse, newErr
}
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
return localVarReturnValue, localVarHttpResponse, newErr
}
@@ -983,25 +914,25 @@ func (a *ListsApiService) GetLists(ctx context.Context, localVarOptionals *GetLi
}
/*
-ListsApiService Delete a contact from a list
+ConversationsApiService Update an automated message
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param listId Id of the list
- - @param contactEmails Emails addresses OR IDs of the contacts
+ - @param id ID of the message
+ - @param body
-@return PostContactInfo
+@return ConversationsMessage
*/
-func (a *ListsApiService) RemoveContactFromList(ctx context.Context, listId int64, contactEmails RemoveContactFromList) (PostContactInfo, *http.Response, error) {
+func (a *ConversationsApiService) ConversationsPushedMessagesIdPut(ctx context.Context, id string, body Body11) (ConversationsMessage, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
+ localVarHttpMethod = strings.ToUpper("Put")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue PostContactInfo
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}/contacts/remove"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/pushedMessages/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -1025,7 +956,7 @@ func (a *ListsApiService) RemoveContactFromList(ctx context.Context, listId int6
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &contactEmails
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -1082,8 +1013,8 @@ func (a *ListsApiService) RemoveContactFromList(ctx context.Context, listId int6
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 201 {
- var v PostContactInfo
+ if localVarHttpResponse.StatusCode == 200 {
+ var v ConversationsMessage
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -1122,22 +1053,24 @@ func (a *ListsApiService) RemoveContactFromList(ctx context.Context, listId int6
}
/*
-ListsApiService Update a list
+ConversationsApiService Send an automated message to a visitor
+Example of automated messages: order status, announce new features in your web app, etc.
- @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- - @param listId Id of the list
- - @param updateList Values to update a list
+ - @param body
+
+@return ConversationsMessage
*/
-func (a *ListsApiService) UpdateList(ctx context.Context, listId int64, updateList UpdateList) (*http.Response, error) {
+func (a *ConversationsApiService) ConversationsPushedMessagesPost(ctx context.Context, body Body10) (ConversationsMessage, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Put")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue ConversationsMessage
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/lists/{listId}"
- localVarPath = strings.Replace(localVarPath, "{"+"listId"+"}", fmt.Sprintf("%v", listId), -1)
+ localVarPath := a.client.cfg.BasePath + "/conversations/pushedMessages"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -1161,7 +1094,7 @@ func (a *ListsApiService) UpdateList(ctx context.Context, listId int64, updateLi
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &updateList
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -1190,18 +1123,26 @@ func (a *ListsApiService) UpdateList(ctx context.Context, listId int64, updateLi
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -1210,30 +1151,30 @@ func (a *ListsApiService) UpdateList(ctx context.Context, listId int64, updateLi
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 200 {
+ var v ConversationsMessage
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 404 {
+ if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
diff --git a/lib/api_deals.go b/lib/api_deals.go
index 6b07609..59246bf 100644
--- a/lib/api_deals.go
+++ b/lib/api_deals.go
@@ -30,7 +30,7 @@ type DealsApiService service
/*
DealsApiService Get deal attributes
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return DealAttributes
*/
@@ -144,9 +144,9 @@ func (a *DealsApiService) CrmAttributesDealsGet(ctx context.Context) (DealAttrib
DealsApiService Get all deals
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
* @param optional nil or *CrmDealsGetOpts - Optional Parameters:
- * @param "FilterAttributes" (optional.String) - Filter by attrbutes. If you have filter for owner on your side please send it as `attributes.owner`.\"
- * @param "FilterLinkedCompaniesIds" (optional.String) - Filter by linked companies ids
- * @param "FilterLinkedContactsIds" (optional.String) - Filter by linked companies ids
+ * @param "FiltersAttributes" (optional.String) - Filter by attrbutes. If you have filter for owner on your side please send it as `attributes.owner`.\"
+ * @param "FiltersLinkedCompaniesIds" (optional.String) - Filter by linked companies ids
+ * @param "FiltersLinkedContactsIds" (optional.String) - Filter by linked companies ids
* @param "Offset" (optional.Int64) - Index of the first document of the page
* @param "Limit" (optional.Int64) - Number of documents per page
* @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
@@ -156,13 +156,13 @@ DealsApiService Get all deals
*/
type CrmDealsGetOpts struct {
- FilterAttributes optional.String
- FilterLinkedCompaniesIds optional.String
- FilterLinkedContactsIds optional.String
- Offset optional.Int64
- Limit optional.Int64
- Sort optional.String
- SortBy optional.String
+ FiltersAttributes optional.String
+ FiltersLinkedCompaniesIds optional.String
+ FiltersLinkedContactsIds optional.String
+ Offset optional.Int64
+ Limit optional.Int64
+ Sort optional.String
+ SortBy optional.String
}
func (a *DealsApiService) CrmDealsGet(ctx context.Context, localVarOptionals *CrmDealsGetOpts) (DealsList, *http.Response, error) {
@@ -181,14 +181,14 @@ func (a *DealsApiService) CrmDealsGet(ctx context.Context, localVarOptionals *Cr
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.FilterAttributes.IsSet() {
- localVarQueryParams.Add("filter[attributes]", parameterToString(localVarOptionals.FilterAttributes.Value(), ""))
+ if localVarOptionals != nil && localVarOptionals.FiltersAttributes.IsSet() {
+ localVarQueryParams.Add("filters[attributes]", parameterToString(localVarOptionals.FiltersAttributes.Value(), ""))
}
- if localVarOptionals != nil && localVarOptionals.FilterLinkedCompaniesIds.IsSet() {
- localVarQueryParams.Add("filter[linkedCompaniesIds]", parameterToString(localVarOptionals.FilterLinkedCompaniesIds.Value(), ""))
+ if localVarOptionals != nil && localVarOptionals.FiltersLinkedCompaniesIds.IsSet() {
+ localVarQueryParams.Add("filters[linkedCompaniesIds]", parameterToString(localVarOptionals.FiltersLinkedCompaniesIds.Value(), ""))
}
- if localVarOptionals != nil && localVarOptionals.FilterLinkedContactsIds.IsSet() {
- localVarQueryParams.Add("filter[linkedContactsIds]", parameterToString(localVarOptionals.FilterLinkedContactsIds.Value(), ""))
+ if localVarOptionals != nil && localVarOptionals.FiltersLinkedContactsIds.IsSet() {
+ localVarQueryParams.Add("filters[linkedContactsIds]", parameterToString(localVarOptionals.FiltersLinkedContactsIds.Value(), ""))
}
if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
@@ -305,10 +305,8 @@ func (a *DealsApiService) CrmDealsGet(ctx context.Context, localVarOptionals *Cr
/*
DealsApiService Delete a deal
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
*/
func (a *DealsApiService) CrmDealsIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
@@ -421,8 +419,8 @@ func (a *DealsApiService) CrmDealsIdDelete(ctx context.Context, id string) (*htt
/*
DealsApiService Get a deal
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
@return Deal
*/
@@ -557,13 +555,11 @@ func (a *DealsApiService) CrmDealsIdGet(ctx context.Context, id string) (Deal, *
/*
DealsApiService Update a deal
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
- * @param body Updated deal details.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
+ - @param body Updated deal details.
*/
-func (a *DealsApiService) CrmDealsIdPatch(ctx context.Context, id string, body Body1) (*http.Response, error) {
+func (a *DealsApiService) CrmDealsIdPatch(ctx context.Context, id string, body Body4) (*http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Patch")
localVarPostBody interface{}
@@ -674,14 +670,120 @@ func (a *DealsApiService) CrmDealsIdPatch(ctx context.Context, id string, body B
return localVarHttpResponse, nil
}
+/*
+DealsApiService Link and Unlink a deal with contacts and companies
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
+ - @param body Linked / Unlinked contacts and companies ids.
+*/
+func (a *DealsApiService) CrmDealsLinkUnlinkIdPatch(ctx context.Context, id string, body Body5) (*http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Patch")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/deals/link-unlink/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ // body params
+ localVarPostBody = &body
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarHttpResponse, newErr
+ }
+
+ return localVarHttpResponse, newErr
+ }
+
+ return localVarHttpResponse, nil
+}
+
/*
DealsApiService Create a deal
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param body Deal create data.
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param body Deal create data.
@return InlineResponse201
*/
-func (a *DealsApiService) CrmDealsPost(ctx context.Context, body Body) (InlineResponse201, *http.Response, error) {
+func (a *DealsApiService) CrmDealsPost(ctx context.Context, body Body3) (InlineResponse201, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
@@ -791,7 +893,7 @@ func (a *DealsApiService) CrmDealsPost(ctx context.Context, body Body) (InlineRe
/*
DealsApiService Get pipeline stages
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return Pipeline
*/
diff --git a/lib/api_crm.go b/lib/api_ecommerce.go
similarity index 74%
rename from lib/api_crm.go
rename to lib/api_ecommerce.go
index 191a5fe..61bb655 100644
--- a/lib/api_crm.go
+++ b/lib/api_ecommerce.go
@@ -26,70 +26,29 @@ var (
_ context.Context
)
-type CRMApiService service
+type EcommerceApiService service
/*
-CRMApiService Get all notes
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param optional nil or *CrmNotesGetOpts - Optional Parameters:
- * @param "Entity" (optional.String) - Filter by note entity type
- * @param "EntityIds" (optional.String) - Filter by note entity IDs
- * @param "DateFrom" (optional.Int32) - dateFrom to date range filter type (timestamp in milliseconds)
- * @param "DateTo" (optional.Int32) - dateTo to date range filter type (timestamp in milliseconds)
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
-
-@return NoteList
+EcommerceApiService Maintains a batch of orders
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param orderBatch
*/
-
-type CrmNotesGetOpts struct {
- Entity optional.String
- EntityIds optional.String
- DateFrom optional.Int32
- DateTo optional.Int32
- Offset optional.Int64
- Limit optional.Int64
- Sort optional.String
-}
-
-func (a *CRMApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmNotesGetOpts) (NoteList, *http.Response, error) {
+func (a *EcommerceApiService) CreateBatchOrder(ctx context.Context, orderBatch OrderBatch) (CreatedBatchId, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue NoteList
+ localVarReturnValue CreatedBatchId
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/notes"
+ localVarPath := a.client.cfg.BasePath + "/orders/status/batch"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.Entity.IsSet() {
- localVarQueryParams.Add("entity", parameterToString(localVarOptionals.Entity.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.EntityIds.IsSet() {
- localVarQueryParams.Add("entityIds", parameterToString(localVarOptionals.EntityIds.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.DateFrom.IsSet() {
- localVarQueryParams.Add("dateFrom", parameterToString(localVarOptionals.DateFrom.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.DateTo.IsSet() {
- localVarQueryParams.Add("dateTo", parameterToString(localVarOptionals.DateTo.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -107,6 +66,8 @@ func (a *CRMApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmN
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &orderBatch
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -144,12 +105,15 @@ func (a *CRMApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmN
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+
localVarHttpResponse.Body.Close()
if err != nil {
return localVarReturnValue, localVarHttpResponse, err
}
if localVarHttpResponse.StatusCode < 300 {
+ var localVarReturnValue CreatedBatchId
+ localVarHttpResponse.Header.Set("Content-Type", "application/json")
// If we succeed, return the data, otherwise pass on to decode error.
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err == nil {
@@ -163,8 +127,9 @@ func (a *CRMApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmN
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v NoteList
+ if localVarHttpResponse.StatusCode == 202 {
+ var v CreatedBatchId
+
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -192,23 +157,20 @@ func (a *CRMApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmN
}
/*
-CRMApiService Delete a note
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Note ID to delete
-
-
+EcommerceApiService Maintains every transactional status of the order
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param order
*/
-func (a *CRMApiService) CrmNotesIdDelete(ctx context.Context, id string) (*http.Response, error) {
+func (a *EcommerceApiService) CreateOrder(ctx context.Context, order Order) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Delete")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
- localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+ localVarPath := a.client.cfg.BasePath + "/orders/status"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -231,6 +193,8 @@ func (a *CRMApiService) CrmNotesIdDelete(ctx context.Context, id string) (*http.
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &order
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -290,17 +254,6 @@ func (a *CRMApiService) CrmNotesIdDelete(ctx context.Context, id string) (*http.
return localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarHttpResponse, newErr
- }
-
return localVarHttpResponse, newErr
}
@@ -308,24 +261,23 @@ func (a *CRMApiService) CrmNotesIdDelete(ctx context.Context, id string) (*http.
}
/*
-CRMApiService Get a note
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Note ID to get
+EcommerceApiService Create the categories in a batch
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createUpdateBatchCategory Values to create a batch of categories
-@return Note
+@return CreateUpdateBatchCategoryModel
*/
-func (a *CRMApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *http.Response, error) {
+func (a *EcommerceApiService) CreateUpdateBatchCategory(ctx context.Context, createUpdateBatchCategory CreateUpdateBatchCategory) (CreateUpdateBatchCategoryModel, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue Note
+ localVarReturnValue CreateUpdateBatchCategoryModel
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
- localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+ localVarPath := a.client.cfg.BasePath + "/categories/batch"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -348,6 +300,8 @@ func (a *CRMApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *ht
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &createUpdateBatchCategory
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -404,8 +358,8 @@ func (a *CRMApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *ht
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v Note
+ if localVarHttpResponse.StatusCode == 201 {
+ var v CreateUpdateBatchCategoryModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -426,17 +380,6 @@ func (a *CRMApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *ht
return localVarReturnValue, localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
return localVarReturnValue, localVarHttpResponse, newErr
}
@@ -444,24 +387,23 @@ func (a *CRMApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *ht
}
/*
-CRMApiService Update a note
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Note ID to update
- * @param body Note data to update a note
-
+EcommerceApiService Creates the products in a batch
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createUpdateBatchProducts Values to create a batch of products
+@return CreateUpdateBatchProductsModel
*/
-func (a *CRMApiService) CrmNotesIdPatch(ctx context.Context, id string, body NoteData) (*http.Response, error) {
+func (a *EcommerceApiService) CreateUpdateBatchProducts(ctx context.Context, createUpdateBatchProducts CreateUpdateBatchProducts) (CreateUpdateBatchProductsModel, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Patch")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue CreateUpdateBatchProductsModel
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
- localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+ localVarPath := a.client.cfg.BasePath + "/products/batch"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -485,7 +427,7 @@ func (a *CRMApiService) CrmNotesIdPatch(ctx context.Context, id string, body Not
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &body
+ localVarPostBody = &createUpdateBatchProducts
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -514,18 +456,26 @@ func (a *CRMApiService) CrmNotesIdPatch(ctx context.Context, id string, body Not
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -534,63 +484,41 @@ func (a *CRMApiService) CrmNotesIdPatch(ctx context.Context, id string, body Not
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 415 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 201 {
+ var v CreateUpdateBatchProductsModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
/*
-CRMApiService Create a note
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param body Note data to create a note.
+EcommerceApiService Create/Update a category
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createUpdateCategory Values to create/update a category
-@return NoteId
+@return CreateCategoryModel
*/
-func (a *CRMApiService) CrmNotesPost(ctx context.Context, body NoteData) (NoteId, *http.Response, error) {
+func (a *EcommerceApiService) CreateUpdateCategory(ctx context.Context, createUpdateCategory CreateUpdateCategory) (CreateCategoryModel, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue NoteId
+ localVarReturnValue CreateCategoryModel
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/notes"
+ localVarPath := a.client.cfg.BasePath + "/categories"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -614,7 +542,7 @@ func (a *CRMApiService) CrmNotesPost(ctx context.Context, body NoteData) (NoteId
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &body
+ localVarPostBody = &createUpdateCategory
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -671,30 +599,8 @@ func (a *CRMApiService) CrmNotesPost(ctx context.Context, body NoteData) (NoteId
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v NoteId
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 415 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 201 {
+ var v CreateCategoryModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -711,97 +617,28 @@ func (a *CRMApiService) CrmNotesPost(ctx context.Context, body NoteData) (NoteId
}
/*
-CRMApiService Get all tasks
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param optional nil or *CrmTasksGetOpts - Optional Parameters:
- * @param "FilterType" (optional.String) - Filter by task type (ID)
- * @param "FilterStatus" (optional.String) - Filter by task status
- * @param "FilterDate" (optional.String) - Filter by date
- * @param "FilterAssignTo" (optional.String) - Filter by assignTo id
- * @param "FilterContacts" (optional.String) - Filter by contact ids
- * @param "FilterDeals" (optional.String) - Filter by deals ids
- * @param "FilterCompanies" (optional.String) - Filter by companies ids
- * @param "DateFrom" (optional.Int32) - dateFrom to date range filter type (timestamp in milliseconds)
- * @param "DateTo" (optional.Int32) - dateTo to date range filter type (timestamp in milliseconds)
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
- * @param "SortBy" (optional.String) - The field used to sort field names.
+EcommerceApiService Create/Update a product
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createUpdateProduct Values to create/update a product
-@return TaskList
+@return CreateProductModel
*/
-
-type CrmTasksGetOpts struct {
- FilterType optional.String
- FilterStatus optional.String
- FilterDate optional.String
- FilterAssignTo optional.String
- FilterContacts optional.String
- FilterDeals optional.String
- FilterCompanies optional.String
- DateFrom optional.Int32
- DateTo optional.Int32
- Offset optional.Int64
- Limit optional.Int64
- Sort optional.String
- SortBy optional.String
-}
-
-func (a *CRMApiService) CrmTasksGet(ctx context.Context, localVarOptionals *CrmTasksGetOpts) (TaskList, *http.Response, error) {
+func (a *EcommerceApiService) CreateUpdateProduct(ctx context.Context, createUpdateProduct CreateUpdateProduct) (CreateProductModel, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue TaskList
+ localVarReturnValue CreateProductModel
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasks"
+ localVarPath := a.client.cfg.BasePath + "/products"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.FilterType.IsSet() {
- localVarQueryParams.Add("filter[type]", parameterToString(localVarOptionals.FilterType.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterStatus.IsSet() {
- localVarQueryParams.Add("filter[status]", parameterToString(localVarOptionals.FilterStatus.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterDate.IsSet() {
- localVarQueryParams.Add("filter[date]", parameterToString(localVarOptionals.FilterDate.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterAssignTo.IsSet() {
- localVarQueryParams.Add("filter[assignTo]", parameterToString(localVarOptionals.FilterAssignTo.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterContacts.IsSet() {
- localVarQueryParams.Add("filter[contacts]", parameterToString(localVarOptionals.FilterContacts.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterDeals.IsSet() {
- localVarQueryParams.Add("filter[deals]", parameterToString(localVarOptionals.FilterDeals.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.FilterCompanies.IsSet() {
- localVarQueryParams.Add("filter[companies]", parameterToString(localVarOptionals.FilterCompanies.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.DateFrom.IsSet() {
- localVarQueryParams.Add("dateFrom", parameterToString(localVarOptionals.DateFrom.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.DateTo.IsSet() {
- localVarQueryParams.Add("dateTo", parameterToString(localVarOptionals.DateTo.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.SortBy.IsSet() {
- localVarQueryParams.Add("sortBy", parameterToString(localVarOptionals.SortBy.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -819,6 +656,8 @@ func (a *CRMApiService) CrmTasksGet(ctx context.Context, localVarOptionals *CrmT
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &createUpdateProduct
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -875,19 +714,8 @@ func (a *CRMApiService) CrmTasksGet(ctx context.Context, localVarOptionals *CrmT
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v TaskList
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 201 {
+ var v CreateProductModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -904,23 +732,19 @@ func (a *CRMApiService) CrmTasksGet(ctx context.Context, localVarOptionals *CrmT
}
/*
-CRMApiService Delete a task
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
-
-
+EcommerceApiService **Fulfills the eCommerce pre-requisites**
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
*/
-func (a *CRMApiService) CrmTasksIdDelete(ctx context.Context, id string) (*http.Response, error) {
+func (a *EcommerceApiService) EcommerceActivatePost(ctx context.Context) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Delete")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
- localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+ localVarPath := a.client.cfg.BasePath + "/ecommerce/activate"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -991,18 +815,7 @@ func (a *CRMApiService) CrmTasksIdDelete(ctx context.Context, id string) (*http.
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 404 {
+ if localVarHttpResponse.StatusCode == 401 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
@@ -1020,29 +833,52 @@ func (a *CRMApiService) CrmTasksIdDelete(ctx context.Context, id string) (*http.
}
/*
-CRMApiService Get a task
+EcommerceApiService Return all your categories
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
+ * @param optional nil or *GetCategoriesOpts - Optional Parameters:
+ * @param "Limit" (optional.Int64) - Number of documents per page
+ * @param "Offset" (optional.Int64) - Index of the first document in the page
+ * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
+ * @param "Ids" (optional.Interface of []string) - Filter by category ids
-@return Task
+@return GetCategories
*/
-func (a *CRMApiService) CrmTasksIdGet(ctx context.Context, id string) (Task, *http.Response, error) {
+
+type GetCategoriesOpts struct {
+ Limit optional.Int64
+ Offset optional.Int64
+ Sort optional.String
+ Ids optional.Interface
+}
+
+func (a *EcommerceApiService) GetCategories(ctx context.Context, localVarOptionals *GetCategoriesOpts) (GetCategories, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue Task
+ localVarReturnValue GetCategories
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
- localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+ localVarPath := a.client.cfg.BasePath + "/categories"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
+ if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
+ localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
+ localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
+ localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Ids.IsSet() {
+ localVarQueryParams.Add("ids", parameterToString(localVarOptionals.Ids.Value(), "csv"))
+ }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -1117,7 +953,7 @@ func (a *CRMApiService) CrmTasksIdGet(ctx context.Context, id string) (Task, *ht
}
if localVarHttpResponse.StatusCode == 200 {
- var v Task
+ var v GetCategories
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -1138,17 +974,6 @@ func (a *CRMApiService) CrmTasksIdGet(ctx context.Context, id string) (Task, *ht
return localVarReturnValue, localVarHttpResponse, newErr
}
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
return localVarReturnValue, localVarHttpResponse, newErr
}
@@ -1156,23 +981,23 @@ func (a *CRMApiService) CrmTasksIdGet(ctx context.Context, id string) (Task, *ht
}
/*
-CRMApiService Update a task
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id
- * @param body Updated task details.
-
+EcommerceApiService Get a category details
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Category ID
+@return GetCategoryDetails
*/
-func (a *CRMApiService) CrmTasksIdPatch(ctx context.Context, id string, body Body6) (*http.Response, error) {
+func (a *EcommerceApiService) GetCategoryInfo(ctx context.Context, id string) (GetCategoryDetails, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Patch")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue GetCategoryDetails
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
+ localVarPath := a.client.cfg.BasePath + "/categories/{id}"
localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
@@ -1196,8 +1021,6 @@ func (a *CRMApiService) CrmTasksIdPatch(ctx context.Context, id string, body Bod
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -1226,18 +1049,26 @@ func (a *CRMApiService) CrmTasksIdPatch(ctx context.Context, id string, body Bod
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -1246,15 +1077,26 @@ func (a *CRMApiService) CrmTasksIdPatch(ctx context.Context, id string, body Bod
error: localVarHttpResponse.Status,
}
+ if localVarHttpResponse.StatusCode == 200 {
+ var v GetCategoryDetails
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
if localVarHttpResponse.StatusCode == 404 {
@@ -1262,36 +1104,37 @@ func (a *CRMApiService) CrmTasksIdPatch(ctx context.Context, id string, body Bod
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
/*
-CRMApiService Create a task
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param body Task name.
+EcommerceApiService Get a product's details
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Product ID
-@return InlineResponse2011
+@return GetProductDetails
*/
-func (a *CRMApiService) CrmTasksPost(ctx context.Context, body Body5) (InlineResponse2011, *http.Response, error) {
+func (a *EcommerceApiService) GetProductInfo(ctx context.Context, id string) (GetProductDetails, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
+ localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue InlineResponse2011
+ localVarReturnValue GetProductDetails
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasks"
+ localVarPath := a.client.cfg.BasePath + "/products/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -1314,8 +1157,6 @@ func (a *CRMApiService) CrmTasksPost(ctx context.Context, body Body5) (InlineRes
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -1372,8 +1213,30 @@ func (a *CRMApiService) CrmTasksPost(ctx context.Context, body Body5) (InlineRes
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 201 {
- var v InlineResponse2011
+ if localVarHttpResponse.StatusCode == 200 {
+ var v GetProductDetails
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -1390,27 +1253,52 @@ func (a *CRMApiService) CrmTasksPost(ctx context.Context, body Body5) (InlineRes
}
/*
-CRMApiService Get all task types
+EcommerceApiService Return all your products
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ * @param optional nil or *GetProductsOpts - Optional Parameters:
+ * @param "Limit" (optional.Int64) - Number of documents per page
+ * @param "Offset" (optional.Int64) - Index of the first document in the page
+ * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
+ * @param "Ids" (optional.Interface of []string) - Filter by product ids
-@return TaskTypes
+@return GetProducts
*/
-func (a *CRMApiService) CrmTasktypesGet(ctx context.Context) (TaskTypes, *http.Response, error) {
+
+type GetProductsOpts struct {
+ Limit optional.Int64
+ Offset optional.Int64
+ Sort optional.String
+ Ids optional.Interface
+}
+
+func (a *EcommerceApiService) GetProducts(ctx context.Context, localVarOptionals *GetProductsOpts) (GetProducts, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue TaskTypes
+ localVarReturnValue GetProducts
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/crm/tasktypes"
+ localVarPath := a.client.cfg.BasePath + "/products"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
+ if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
+ localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
+ localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
+ localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Ids.IsSet() {
+ localVarQueryParams.Add("ids", parameterToString(localVarOptionals.Ids.Value(), "csv"))
+ }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -1485,7 +1373,18 @@ func (a *CRMApiService) CrmTasktypesGet(ctx context.Context) (TaskTypes, *http.R
}
if localVarHttpResponse.StatusCode == 200 {
- var v TaskTypes
+ var v GetProducts
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
diff --git a/lib/api_email_campaigns.go b/lib/api_email_campaigns.go
index 2b00052..a36eb0d 100644
--- a/lib/api_email_campaigns.go
+++ b/lib/api_email_campaigns.go
@@ -30,8 +30,8 @@ type EmailCampaignsApiService service
/*
EmailCampaignsApiService Create an email campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param emailCampaigns Values to create a campaign
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param emailCampaigns Values to create a campaign
@return CreateModel
*/
@@ -156,10 +156,8 @@ func (a *EmailCampaignsApiService) CreateEmailCampaign(ctx context.Context, emai
/*
EmailCampaignsApiService Delete an email campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the campaign
*/
func (a *EmailCampaignsApiService) DeleteEmailCampaign(ctx context.Context, campaignId int64) (*http.Response, error) {
var (
@@ -425,8 +423,8 @@ func (a *EmailCampaignsApiService) EmailExportRecipients(ctx context.Context, ca
/*
EmailCampaignsApiService Get an A/B test email campaign results
Obtain winning version of an A/B test email campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the A/B test campaign
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the A/B test campaign
@return AbTestCampaignResult
*/
@@ -572,8 +570,8 @@ func (a *EmailCampaignsApiService) GetAbTestCampaignResult(ctx context.Context,
/*
EmailCampaignsApiService Get an email campaign report
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
@return GetEmailCampaign
*/
@@ -872,8 +870,8 @@ func (a *EmailCampaignsApiService) GetEmailCampaigns(ctx context.Context, localV
/*
EmailCampaignsApiService Get a shared template url
Get a unique URL to share & import an email template from one Sendinblue account to another.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign or template
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign or template
@return GetSharedTemplateUrl
*/
@@ -1008,10 +1006,8 @@ func (a *EmailCampaignsApiService) GetSharedTemplateUrl(ctx context.Context, cam
/*
EmailCampaignsApiService Send an email campaign immediately, based on campaignId
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
*/
func (a *EmailCampaignsApiService) SendEmailCampaignNow(ctx context.Context, campaignId int64) (*http.Response, error) {
var (
@@ -1136,11 +1132,9 @@ func (a *EmailCampaignsApiService) SendEmailCampaignNow(ctx context.Context, cam
/*
EmailCampaignsApiService Send the report of a campaign
A PDF will be sent to the specified email addresses
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
- * @param sendReport Values for send a report
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
+ - @param sendReport Values for send a report
*/
func (a *EmailCampaignsApiService) SendReport(ctx context.Context, campaignId int64, sendReport SendReport) (*http.Response, error) {
var (
@@ -1255,11 +1249,9 @@ func (a *EmailCampaignsApiService) SendReport(ctx context.Context, campaignId in
/*
EmailCampaignsApiService Send an email campaign to your test list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
- * @param emailTo
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
+ - @param emailTo
*/
func (a *EmailCampaignsApiService) SendTestEmail(ctx context.Context, campaignId int64, emailTo SendTestEmail) (*http.Response, error) {
var (
@@ -1374,11 +1366,9 @@ func (a *EmailCampaignsApiService) SendTestEmail(ctx context.Context, campaignId
/*
EmailCampaignsApiService Update an email campaign status
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
- * @param status Status of the campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
+ - @param status Status of the campaign
*/
func (a *EmailCampaignsApiService) UpdateCampaignStatus(ctx context.Context, campaignId int64, status UpdateCampaignStatus) (*http.Response, error) {
var (
@@ -1493,11 +1483,9 @@ func (a *EmailCampaignsApiService) UpdateCampaignStatus(ctx context.Context, cam
/*
EmailCampaignsApiService Update an email campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the campaign
- * @param emailCampaign Values to update a campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the campaign
+ - @param emailCampaign Values to update a campaign
*/
func (a *EmailCampaignsApiService) UpdateEmailCampaign(ctx context.Context, campaignId int64, emailCampaign UpdateEmailCampaign) (*http.Response, error) {
var (
@@ -1612,17 +1600,18 @@ func (a *EmailCampaignsApiService) UpdateEmailCampaign(ctx context.Context, camp
/*
EmailCampaignsApiService Upload an image to your account's image gallery
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param uploadImage Parameters to upload an image
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param uploadImage Parameters to upload an image
+@return UploadImageModel
*/
-func (a *EmailCampaignsApiService) UploadImageToGallery(ctx context.Context, uploadImage UploadImageToGallery) (*http.Response, error) {
+func (a *EmailCampaignsApiService) UploadImageToGallery(ctx context.Context, uploadImage UploadImageToGallery) (UploadImageModel, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue UploadImageModel
)
// create path and map variables
@@ -1679,18 +1668,26 @@ func (a *EmailCampaignsApiService) UploadImageToGallery(ctx context.Context, upl
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -1699,19 +1696,30 @@ func (a *EmailCampaignsApiService) UploadImageToGallery(ctx context.Context, upl
error: localVarHttpResponse.Status,
}
+ if localVarHttpResponse.StatusCode == 201 {
+ var v UploadImageModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
diff --git a/lib/api_files.go b/lib/api_files.go
new file mode 100644
index 0000000..8d1c8d7
--- /dev/null
+++ b/lib/api_files.go
@@ -0,0 +1,730 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+import (
+ "context"
+ "fmt"
+ "io/ioutil"
+ "net/http"
+ "net/url"
+ "os"
+ "strings"
+
+ "github.com/antihax/optional"
+)
+
+// Linger please
+var (
+ _ context.Context
+)
+
+type FilesApiService service
+
+/*
+FilesApiService Get all files
+ * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ * @param optional nil or *CrmFilesGetOpts - Optional Parameters:
+ * @param "Entity" (optional.String) - Filter by file entity type
+ * @param "EntityIds" (optional.String) - Filter by file entity IDs
+ * @param "DateFrom" (optional.Int32) - dateFrom to date range filter type (timestamp in milliseconds)
+ * @param "DateTo" (optional.Int32) - dateTo to date range filter type (timestamp in milliseconds)
+ * @param "Offset" (optional.Int64) - Index of the first document of the page
+ * @param "Limit" (optional.Int64) - Number of documents per page
+ * @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
+
+@return FileList
+*/
+
+type CrmFilesGetOpts struct {
+ Entity optional.String
+ EntityIds optional.String
+ DateFrom optional.Int32
+ DateTo optional.Int32
+ Offset optional.Int64
+ Limit optional.Int64
+ Sort optional.String
+}
+
+func (a *FilesApiService) CrmFilesGet(ctx context.Context, localVarOptionals *CrmFilesGetOpts) (FileList, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue FileList
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/files"
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ if localVarOptionals != nil && localVarOptionals.Entity.IsSet() {
+ localVarQueryParams.Add("entity", parameterToString(localVarOptionals.Entity.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.EntityIds.IsSet() {
+ localVarQueryParams.Add("entityIds", parameterToString(localVarOptionals.EntityIds.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateFrom.IsSet() {
+ localVarQueryParams.Add("dateFrom", parameterToString(localVarOptionals.DateFrom.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateTo.IsSet() {
+ localVarQueryParams.Add("dateTo", parameterToString(localVarOptionals.DateTo.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
+ localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
+ localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
+ localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
+ }
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 200 {
+ var v FileList
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
+
+/*
+FilesApiService Get file details
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id File id to get file data.
+
+@return FileData
+*/
+func (a *FilesApiService) CrmFilesIdDataGet(ctx context.Context, id string) (FileData, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue FileData
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/files/{id}/data"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 200 {
+ var v FileData
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
+
+/*
+FilesApiService Delete a file
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id File id to delete.
+*/
+func (a *FilesApiService) CrmFilesIdDelete(ctx context.Context, id string) (*http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Delete")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/files/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarHttpResponse, newErr
+ }
+
+ return localVarHttpResponse, newErr
+ }
+
+ return localVarHttpResponse, nil
+}
+
+/*
+FilesApiService Download a file
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id File id to download.
+
+@return FileDownloadableLink
+*/
+func (a *FilesApiService) CrmFilesIdGet(ctx context.Context, id string) (FileDownloadableLink, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue FileDownloadableLink
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/files/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 200 {
+ var v FileDownloadableLink
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
+
+/*
+FilesApiService Upload a file
+ * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ * @param file File data to create a file.
+ * @param optional nil or *CrmFilesPostOpts - Optional Parameters:
+ * @param "DealId" (optional.String) - Deal id linked to a file
+ * @param "ContactId" (optional.Int64) - Contact id linked to a file
+ * @param "CompanyId" (optional.String) - Company id linked to a file
+
+@return FileData
+*/
+
+type CrmFilesPostOpts struct {
+ DealId optional.String
+ ContactId optional.Int64
+ CompanyId optional.String
+}
+
+func (a *FilesApiService) CrmFilesPost(ctx context.Context, file *os.File, localVarOptionals *CrmFilesPostOpts) (FileData, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue FileData
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/files"
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"multipart/form-data"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ var localVarFile *os.File
+ if localVarFile != nil {
+ fbs, _ := ioutil.ReadAll(localVarFile)
+ localVarFileBytes = fbs
+ localVarFileName = localVarFile.Name()
+ localVarFile.Close()
+ }
+ if localVarOptionals != nil && localVarOptionals.DealId.IsSet() {
+ localVarFormParams.Add("dealId", parameterToString(localVarOptionals.DealId.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.ContactId.IsSet() {
+ localVarFormParams.Add("contactId", parameterToString(localVarOptionals.ContactId.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.CompanyId.IsSet() {
+ localVarFormParams.Add("companyId", parameterToString(localVarOptionals.CompanyId.Value(), ""))
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 201 {
+ var v FileData
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
diff --git a/lib/api_inbound_parsing.go b/lib/api_inbound_parsing.go
index 3832404..358c523 100644
--- a/lib/api_inbound_parsing.go
+++ b/lib/api_inbound_parsing.go
@@ -16,6 +16,7 @@ import (
"io/ioutil"
"net/http"
"net/url"
+ "os"
"strings"
"github.com/antihax/optional"
@@ -28,6 +29,143 @@ var (
type InboundParsingApiService service
+/*
+InboundParsingApiService Retrieve inbound attachment with download token.
+This endpoint will retrieve inbound attachment with download token.
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param downloadToken Token to fetch a particular attachment
+
+@return *os.File
+*/
+func (a *InboundParsingApiService) GetInboundEmailAttachment(ctx context.Context, downloadToken string) (*os.File, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue *os.File
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/inbound/attachments/{downloadToken}"
+ localVarPath = strings.Replace(localVarPath, "{"+"downloadToken"+"}", fmt.Sprintf("%v", downloadToken), -1)
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 200 {
+ var v *os.File
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
+
/*
InboundParsingApiService Get the list of all the events for the received emails.
This endpoint will show the list of all the events for the received emails.
@@ -190,8 +328,8 @@ func (a *InboundParsingApiService) GetInboundEmailEvents(ctx context.Context, lo
/*
InboundParsingApiService Fetch all events history for one particular received email.
This endpoint will show the list of all events history for one particular received email.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param uuid UUID to fetch events specific to recieved email
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param uuid UUID to fetch events specific to recieved email
@return GetInboundEmailEventsByUuid
*/
diff --git a/lib/api_master_account.go b/lib/api_master_account.go
index 9e55fd0..c08e1cb 100644
--- a/lib/api_master_account.go
+++ b/lib/api_master_account.go
@@ -29,7 +29,7 @@ type MasterAccountApiService service
/*
MasterAccountApiService Get the details of requested master account
This endpoint will provide the details of the master account.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return MasterDetailsResponse
*/
@@ -153,9 +153,9 @@ func (a *MasterAccountApiService) CorporateMasterAccountGet(ctx context.Context)
/*
MasterAccountApiService Get the list of all the sub-accounts of the master account.
This endpoint will provide the list all the sub-accounts of the master account.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param offset Index of the first sub-account in the page
- * @param limit Number of sub-accounts to be displayed on each page
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param offset Index of the first sub-account in the page
+ - @param limit Number of sub-accounts to be displayed on each page
@return SubAccountsResponse
*/
@@ -280,10 +280,8 @@ func (a *MasterAccountApiService) CorporateSubAccountGet(ctx context.Context, of
/*
MasterAccountApiService Delete a sub-account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Id of the sub-account organization to be deleted
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Id of the sub-account organization to be deleted
*/
func (a *MasterAccountApiService) CorporateSubAccountIdDelete(ctx context.Context, id int64) (*http.Response, error) {
var (
@@ -375,8 +373,8 @@ func (a *MasterAccountApiService) CorporateSubAccountIdDelete(ctx context.Contex
/*
MasterAccountApiService Get sub-account details
This endpoint will provide the details for the specified sub-account company
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Id of the sub-account organization
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Id of the sub-account organization
@return SubAccountDetailsResponse
*/
@@ -490,11 +488,9 @@ func (a *MasterAccountApiService) CorporateSubAccountIdGet(ctx context.Context,
/*
MasterAccountApiService Update sub-account plan
This endpoint will update the sub-account plan
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param id Id of the sub-account organization
- * @param updatePlanDetails Values to update a sub-account plan
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Id of the sub-account organization
+ - @param updatePlanDetails Values to update a sub-account plan
*/
func (a *MasterAccountApiService) CorporateSubAccountIdPlanPut(ctx context.Context, id int64, updatePlanDetails SubAccountUpdatePlanRequest) (*http.Response, error) {
var (
@@ -607,11 +603,138 @@ func (a *MasterAccountApiService) CorporateSubAccountIdPlanPut(ctx context.Conte
return localVarHttpResponse, nil
}
+/*
+MasterAccountApiService Create an API key for a sub-account
+This endpoint will generate an API v3 key for a sub account
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createApiKeyRequest Values to generate API key for sub-account
+
+@return CreateApiKeyResponse
+*/
+func (a *MasterAccountApiService) CorporateSubAccountKeyPost(ctx context.Context, createApiKeyRequest CreateApiKeyRequest) (CreateApiKeyResponse, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue CreateApiKeyResponse
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/corporate/subAccount/key"
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ // body params
+ localVarPostBody = &createApiKeyRequest
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 201 {
+ var v CreateApiKeyResponse
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
+
/*
MasterAccountApiService Create a new sub-account under a master account.
This endpoint will create a new sub-account under a master account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param subAccountCreate values to create new sub-account
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param subAccountCreate values to create new sub-account
@return CreateSubAccountResponse
*/
@@ -736,9 +859,9 @@ func (a *MasterAccountApiService) CorporateSubAccountPost(ctx context.Context, s
/*
MasterAccountApiService Generate SSO token to access Sendinblue
-This endpoint generates an sso token to authenticate and access a sub-account of the master using the account endpoint https://app.sendinblue.com/account/login/sub-account/sso/[token], where [token] will be replaced by the actual token.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param ssoTokenRequest Values to generate SSO token for sub-account
+This endpoint generates an sso token to authenticate and access a sub-account of the master using the account endpoint https://account-app.sendinblue.com/account/login/sub-account/sso/[token], where [token] will be replaced by the actual token.
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ssoTokenRequest Values to generate SSO token for sub-account
@return GetSsoToken
*/
diff --git a/lib/api_attributes.go b/lib/api_notes.go
similarity index 54%
rename from lib/api_attributes.go
rename to lib/api_notes.go
index f361495..baa34f0 100644
--- a/lib/api_attributes.go
+++ b/lib/api_notes.go
@@ -17,6 +17,8 @@ import (
"net/http"
"net/url"
"strings"
+
+ "github.com/antihax/optional"
)
// Linger please
@@ -24,34 +26,70 @@ var (
_ context.Context
)
-type AttributesApiService service
+type NotesApiService service
/*
-AttributesApiService Create contact attribute
+NotesApiService Get all notes
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the attribute
- * @param createAttribute Values to create an attribute
+ * @param optional nil or *CrmNotesGetOpts - Optional Parameters:
+ * @param "Entity" (optional.String) - Filter by note entity type
+ * @param "EntityIds" (optional.String) - Filter by note entity IDs
+ * @param "DateFrom" (optional.Int32) - dateFrom to date range filter type (timestamp in milliseconds)
+ * @param "DateTo" (optional.Int32) - dateTo to date range filter type (timestamp in milliseconds)
+ * @param "Offset" (optional.Int64) - Index of the first document of the page
+ * @param "Limit" (optional.Int64) - Number of documents per page
+ * @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
+
+@return NoteList
+*/
+type CrmNotesGetOpts struct {
+ Entity optional.String
+ EntityIds optional.String
+ DateFrom optional.Int32
+ DateTo optional.Int32
+ Offset optional.Int64
+ Limit optional.Int64
+ Sort optional.String
+}
-*/
-func (a *AttributesApiService) CreateAttribute(ctx context.Context, attributeCategory string, attributeName string, createAttribute CreateAttribute) (*http.Response, error) {
+func (a *NotesApiService) CrmNotesGet(ctx context.Context, localVarOptionals *CrmNotesGetOpts) (NoteList, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue NoteList
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/attributes/{attributeCategory}/{attributeName}"
- localVarPath = strings.Replace(localVarPath, "{"+"attributeCategory"+"}", fmt.Sprintf("%v", attributeCategory), -1)
- localVarPath = strings.Replace(localVarPath, "{"+"attributeName"+"}", fmt.Sprintf("%v", attributeName), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/notes"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
+ if localVarOptionals != nil && localVarOptionals.Entity.IsSet() {
+ localVarQueryParams.Add("entity", parameterToString(localVarOptionals.Entity.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.EntityIds.IsSet() {
+ localVarQueryParams.Add("entityIds", parameterToString(localVarOptionals.EntityIds.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateFrom.IsSet() {
+ localVarQueryParams.Add("dateFrom", parameterToString(localVarOptionals.DateFrom.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateTo.IsSet() {
+ localVarQueryParams.Add("dateTo", parameterToString(localVarOptionals.DateTo.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
+ localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
+ localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
+ localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
+ }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -69,8 +107,6 @@ func (a *AttributesApiService) CreateAttribute(ctx context.Context, attributeCat
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &createAttribute
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -99,18 +135,26 @@ func (a *AttributesApiService) CreateAttribute(ctx context.Context, attributeCat
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -119,32 +163,40 @@ func (a *AttributesApiService) CreateAttribute(ctx context.Context, attributeCat
error: localVarHttpResponse.Status,
}
+ if localVarHttpResponse.StatusCode == 200 {
+ var v NoteList
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
/*
-AttributesApiService Delete an attribute
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the existing attribute
-
-
+NotesApiService Delete a note
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Note ID to delete
*/
-func (a *AttributesApiService) DeleteAttribute(ctx context.Context, attributeCategory string, attributeName string) (*http.Response, error) {
+func (a *NotesApiService) CrmNotesIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Delete")
localVarPostBody interface{}
@@ -153,9 +205,8 @@ func (a *AttributesApiService) DeleteAttribute(ctx context.Context, attributeCat
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/attributes/{attributeCategory}/{attributeName}"
- localVarPath = strings.Replace(localVarPath, "{"+"attributeCategory"+"}", fmt.Sprintf("%v", attributeCategory), -1)
- localVarPath = strings.Replace(localVarPath, "{"+"attributeName"+"}", fmt.Sprintf("%v", attributeName), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -255,22 +306,24 @@ func (a *AttributesApiService) DeleteAttribute(ctx context.Context, attributeCat
}
/*
-AttributesApiService List all attributes
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+NotesApiService Get a note
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Note ID to get
-@return GetAttributes
+@return Note
*/
-func (a *AttributesApiService) GetAttributes(ctx context.Context) (GetAttributes, *http.Response, error) {
+func (a *NotesApiService) CrmNotesIdGet(ctx context.Context, id string) (Note, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetAttributes
+ localVarReturnValue Note
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/attributes"
+ localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -350,7 +403,29 @@ func (a *AttributesApiService) GetAttributes(ctx context.Context) (GetAttributes
}
if localVarHttpResponse.StatusCode == 200 {
- var v GetAttributes
+ var v Note
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 404 {
+ var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -367,26 +442,22 @@ func (a *AttributesApiService) GetAttributes(ctx context.Context) (GetAttributes
}
/*
-AttributesApiService Update contact attribute
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param attributeCategory Category of the attribute
- * @param attributeName Name of the existing attribute
- * @param updateAttribute Values to update an attribute
-
-
+NotesApiService Update a note
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id Note ID to update
+ - @param body Note data to update a note
*/
-func (a *AttributesApiService) UpdateAttribute(ctx context.Context, attributeCategory string, attributeName string, updateAttribute UpdateAttribute) (*http.Response, error) {
+func (a *NotesApiService) CrmNotesIdPatch(ctx context.Context, id string, body NoteData) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Put")
+ localVarHttpMethod = strings.ToUpper("Patch")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/attributes/{attributeCategory}/{attributeName}"
- localVarPath = strings.Replace(localVarPath, "{"+"attributeCategory"+"}", fmt.Sprintf("%v", attributeCategory), -1)
- localVarPath = strings.Replace(localVarPath, "{"+"attributeName"+"}", fmt.Sprintf("%v", attributeName), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/notes/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -410,7 +481,7 @@ func (a *AttributesApiService) UpdateAttribute(ctx context.Context, attributeCat
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
// body params
- localVarPostBody = &updateAttribute
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -481,8 +552,156 @@ func (a *AttributesApiService) UpdateAttribute(ctx context.Context, attributeCat
return localVarHttpResponse, newErr
}
+ if localVarHttpResponse.StatusCode == 415 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarHttpResponse, newErr
+ }
+
return localVarHttpResponse, newErr
}
return localVarHttpResponse, nil
}
+
+/*
+NotesApiService Create a note
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param body Note data to create a note.
+
+@return NoteId
+*/
+func (a *NotesApiService) CrmNotesPost(ctx context.Context, body NoteData) (NoteId, *http.Response, error) {
+ var (
+ localVarHttpMethod = strings.ToUpper("Post")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue NoteId
+ )
+
+ // create path and map variables
+ localVarPath := a.client.cfg.BasePath + "/crm/notes"
+
+ localVarHeaderParams := make(map[string]string)
+ localVarQueryParams := url.Values{}
+ localVarFormParams := url.Values{}
+
+ // to determine the Content-Type header
+ localVarHttpContentTypes := []string{"application/json"}
+
+ // set Content-Type header
+ localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
+ if localVarHttpContentType != "" {
+ localVarHeaderParams["Content-Type"] = localVarHttpContentType
+ }
+
+ // to determine the Accept header
+ localVarHttpHeaderAccepts := []string{"application/json"}
+
+ // set Accept header
+ localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
+ if localVarHttpHeaderAccept != "" {
+ localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
+ }
+ // body params
+ localVarPostBody = &body
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["api-key"] = key
+
+ }
+ }
+ if ctx != nil {
+ // API Key Authentication
+ if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
+ var key string
+ if auth.Prefix != "" {
+ key = auth.Prefix + " " + auth.Key
+ } else {
+ key = auth.Key
+ }
+ localVarHeaderParams["partner-key"] = key
+
+ }
+ }
+ r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
+ if err != nil {
+ return localVarReturnValue, nil, err
+ }
+
+ localVarHttpResponse, err := a.client.callAPI(r)
+ if err != nil || localVarHttpResponse == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
+ localVarHttpResponse.Body.Close()
+ if err != nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+ }
+
+ if localVarHttpResponse.StatusCode >= 300 {
+ newErr := GenericSwaggerError{
+ body: localVarBody,
+ error: localVarHttpResponse.Status,
+ }
+
+ if localVarHttpResponse.StatusCode == 200 {
+ var v NoteId
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 400 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ if localVarHttpResponse.StatusCode == 415 {
+ var v ErrorModel
+ err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err != nil {
+ newErr.error = err.Error()
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+ newErr.model = v
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, newErr
+ }
+
+ return localVarReturnValue, localVarHttpResponse, nil
+}
diff --git a/lib/api_process.go b/lib/api_process.go
index edbf0e7..0d244ca 100644
--- a/lib/api_process.go
+++ b/lib/api_process.go
@@ -30,8 +30,8 @@ type ProcessApiService service
/*
ProcessApiService Return the informations for a process
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param processId Id of the process
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param processId Id of the process
@return GetProcess
*/
diff --git a/lib/api_reseller.go b/lib/api_reseller.go
index f7301e3..afcb6d1 100644
--- a/lib/api_reseller.go
+++ b/lib/api_reseller.go
@@ -30,9 +30,9 @@ type ResellerApiService service
/*
ResellerApiService Add Email and/or SMS credits to a specific child account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param addCredits Values to post to add credit to a specific child account
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param addCredits Values to post to add credit to a specific child account
@return RemainingCreditModel
*/
@@ -180,11 +180,9 @@ func (a *ResellerApiService) AddCredits(ctx context.Context, childIdentifier str
/*
ResellerApiService Associate a dedicated IP to the child
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param ip IP to associate
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param ip IP to associate
*/
func (a *ResellerApiService) AssociateIpToChild(ctx context.Context, childIdentifier string, ip ManageIp) (*http.Response, error) {
var (
@@ -299,11 +297,9 @@ func (a *ResellerApiService) AssociateIpToChild(ctx context.Context, childIdenti
/*
ResellerApiService Create a domain for a child account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param addChildDomain Sender domain to add for a specific child account. This will not be displayed to the parent account.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param addChildDomain Sender domain to add for a specific child account. This will not be displayed to the parent account.
*/
func (a *ResellerApiService) CreateChildDomain(ctx context.Context, childIdentifier string, addChildDomain AddChildDomain) (*http.Response, error) {
var (
@@ -579,11 +575,9 @@ func (a *ResellerApiService) CreateResellerChild(ctx context.Context, localVarOp
/*
ResellerApiService Delete the sender domain of the reseller child based on the childIdentifier and domainName passed
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param domainName Pass the existing domain that needs to be deleted
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param domainName Pass the existing domain that needs to be deleted
*/
func (a *ResellerApiService) DeleteChildDomain(ctx context.Context, childIdentifier string, domainName string) (*http.Response, error) {
var (
@@ -708,10 +702,8 @@ func (a *ResellerApiService) DeleteChildDomain(ctx context.Context, childIdentif
/*
ResellerApiService Delete a single reseller child based on the child identifier supplied
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or child id of reseller's child
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or child id of reseller's child
*/
func (a *ResellerApiService) DeleteResellerChild(ctx context.Context, childIdentifier string) (*http.Response, error) {
var (
@@ -835,11 +827,9 @@ func (a *ResellerApiService) DeleteResellerChild(ctx context.Context, childIdent
/*
ResellerApiService Dissociate a dedicated IP to the child
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param ip IP to dissociate
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param ip IP to dissociate
*/
func (a *ResellerApiService) DissociateIpFromChild(ctx context.Context, childIdentifier string, ip ManageIp) (*http.Response, error) {
var (
@@ -954,8 +944,8 @@ func (a *ResellerApiService) DissociateIpFromChild(ctx context.Context, childIde
/*
ResellerApiService Get the status of a reseller's child account creation, whether it is successfully created (exists) or not based on the identifier supplied
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
@return GetChildAccountCreationStatus
*/
@@ -1101,8 +1091,8 @@ func (a *ResellerApiService) GetChildAccountCreationStatus(ctx context.Context,
/*
ResellerApiService Get all sender domains for a specific child account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
@return GetChildDomains
*/
@@ -1248,8 +1238,8 @@ func (a *ResellerApiService) GetChildDomains(ctx context.Context, childIdentifie
/*
ResellerApiService Get a child account's details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
@return GetChildInfo
*/
@@ -1534,8 +1524,8 @@ func (a *ResellerApiService) GetResellerChilds(ctx context.Context, localVarOpti
/*
ResellerApiService Get session token to access Sendinblue (SSO)
It returns a session [token] which will remain valid for a short period of time. A child account will be able to access a white-labeled section by using the following url pattern => https:/email.mydomain.com/login/sso?token=[token]
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
@return GetSsoToken
*/
@@ -1681,9 +1671,9 @@ func (a *ResellerApiService) GetSsoToken(ctx context.Context, childIdentifier st
/*
ResellerApiService Remove Email and/or SMS credits from a specific child account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param removeCredits Values to post to remove email or SMS credits from a specific child account
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param removeCredits Values to post to remove email or SMS credits from a specific child account
@return RemainingCreditModel
*/
@@ -1831,11 +1821,9 @@ func (a *ResellerApiService) RemoveCredits(ctx context.Context, childIdentifier
/*
ResellerApiService Update info of reseller's child account status based on the childIdentifier supplied
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param updateChildAccountStatus values to update in child account status
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param updateChildAccountStatus values to update in child account status
*/
func (a *ResellerApiService) UpdateChildAccountStatus(ctx context.Context, childIdentifier string, updateChildAccountStatus UpdateChildAccountStatus) (*http.Response, error) {
var (
@@ -1961,12 +1949,10 @@ func (a *ResellerApiService) UpdateChildAccountStatus(ctx context.Context, child
/*
ResellerApiService Update the sender domain of reseller's child based on the childIdentifier and domainName passed
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param domainName Pass the existing domain that needs to be updated
- * @param updateChildDomain value to update for sender domain
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param domainName Pass the existing domain that needs to be updated
+ - @param updateChildDomain value to update for sender domain
*/
func (a *ResellerApiService) UpdateChildDomain(ctx context.Context, childIdentifier string, domainName string, updateChildDomain UpdateChildDomain) (*http.Response, error) {
var (
@@ -2093,11 +2079,9 @@ func (a *ResellerApiService) UpdateChildDomain(ctx context.Context, childIdentif
/*
ResellerApiService Update info of reseller's child based on the child identifier supplied
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param childIdentifier Either auth key or id of reseller's child
- * @param resellerChild values to update in child profile
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param childIdentifier Either auth key or id of reseller's child
+ - @param resellerChild values to update in child profile
*/
func (a *ResellerApiService) UpdateResellerChild(ctx context.Context, childIdentifier string, resellerChild UpdateChild) (*http.Response, error) {
var (
diff --git a/lib/api_senders.go b/lib/api_senders.go
index eae2033..e7645a5 100644
--- a/lib/api_senders.go
+++ b/lib/api_senders.go
@@ -169,10 +169,8 @@ func (a *SendersApiService) CreateSender(ctx context.Context, localVarOptionals
/*
SendersApiService Delete a sender
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param senderId Id of the sender
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param senderId Id of the sender
*/
func (a *SendersApiService) DeleteSender(ctx context.Context, senderId int64) (*http.Response, error) {
var (
@@ -285,7 +283,7 @@ func (a *SendersApiService) DeleteSender(ctx context.Context, senderId int64) (*
/*
SendersApiService Get all the dedicated IPs for your account
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return GetIps
*/
@@ -397,8 +395,8 @@ func (a *SendersApiService) GetIps(ctx context.Context) (GetIps, *http.Response,
/*
SendersApiService Get all the dedicated IPs for a sender
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param senderId Id of the sender
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param senderId Id of the sender
@return GetIpsFromSender
*/
diff --git a/lib/api_sms_campaigns.go b/lib/api_sms_campaigns.go
index f3e7408..5bf9dcb 100644
--- a/lib/api_sms_campaigns.go
+++ b/lib/api_sms_campaigns.go
@@ -30,8 +30,8 @@ type SMSCampaignsApiService service
/*
SMSCampaignsApiService Creates an SMS campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createSmsCampaign Values to create an SMS Campaign
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createSmsCampaign Values to create an SMS Campaign
@return CreateModel
*/
@@ -156,10 +156,8 @@ func (a *SMSCampaignsApiService) CreateSmsCampaign(ctx context.Context, createSm
/*
SMSCampaignsApiService Delete an SMS campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the SMS campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the SMS campaign
*/
func (a *SMSCampaignsApiService) DeleteSmsCampaign(ctx context.Context, campaignId int64) (*http.Response, error) {
var (
@@ -272,8 +270,8 @@ func (a *SMSCampaignsApiService) DeleteSmsCampaign(ctx context.Context, campaign
/*
SMSCampaignsApiService Get an SMS campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the SMS campaign
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the SMS campaign
@return GetSmsCampaign
*/
@@ -719,10 +717,8 @@ func (a *SMSCampaignsApiService) RequestSmsRecipientExport(ctx context.Context,
/*
SMSCampaignsApiService Send your SMS campaign immediately
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the campaign
*/
func (a *SMSCampaignsApiService) SendSmsCampaignNow(ctx context.Context, campaignId int64) (*http.Response, error) {
var (
@@ -847,11 +843,9 @@ func (a *SMSCampaignsApiService) SendSmsCampaignNow(ctx context.Context, campaig
/*
SMSCampaignsApiService Send an SMS campaign's report
Send report of Sent and Archived campaign, to the specified email addresses, with respective data and a pdf attachment in detail.
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the campaign
- * @param sendReport Values for send a report
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the campaign
+ - @param sendReport Values for send a report
*/
func (a *SMSCampaignsApiService) SendSmsReport(ctx context.Context, campaignId int64, sendReport SendReport) (*http.Response, error) {
var (
@@ -966,11 +960,9 @@ func (a *SMSCampaignsApiService) SendSmsReport(ctx context.Context, campaignId i
/*
SMSCampaignsApiService Send a test SMS campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId Id of the SMS campaign
- * @param phoneNumber Mobile number of the recipient with the country code. This number must belong to one of your contacts in SendinBlue account and must not be blacklisted
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId Id of the SMS campaign
+ - @param phoneNumber Mobile number of the recipient with the country code. This number must belong to one of your contacts in SendinBlue account and must not be blacklisted
*/
func (a *SMSCampaignsApiService) SendTestSms(ctx context.Context, campaignId int64, phoneNumber SendTestSms) (*http.Response, error) {
var (
@@ -1085,11 +1077,9 @@ func (a *SMSCampaignsApiService) SendTestSms(ctx context.Context, campaignId int
/*
SMSCampaignsApiService Update an SMS campaign
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the SMS campaign
- * @param updateSmsCampaign Values to update an SMS Campaign
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the SMS campaign
+ - @param updateSmsCampaign Values to update an SMS Campaign
*/
func (a *SMSCampaignsApiService) UpdateSmsCampaign(ctx context.Context, campaignId int64, updateSmsCampaign UpdateSmsCampaign) (*http.Response, error) {
var (
@@ -1204,11 +1194,9 @@ func (a *SMSCampaignsApiService) UpdateSmsCampaign(ctx context.Context, campaign
/*
SMSCampaignsApiService Update a campaign's status
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param campaignId id of the campaign
- * @param status Status of the campaign.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param campaignId id of the campaign
+ - @param status Status of the campaign.
*/
func (a *SMSCampaignsApiService) UpdateSmsCampaignStatus(ctx context.Context, campaignId int64, status UpdateCampaignStatus) (*http.Response, error) {
var (
diff --git a/lib/api_folders.go b/lib/api_tasks.go
similarity index 77%
rename from lib/api_folders.go
rename to lib/api_tasks.go
index 866ca55..3b759aa 100644
--- a/lib/api_folders.go
+++ b/lib/api_tasks.go
@@ -17,6 +17,8 @@ import (
"net/http"
"net/url"
"strings"
+
+ "github.com/antihax/optional"
)
// Linger please
@@ -24,31 +26,100 @@ var (
_ context.Context
)
-type FoldersApiService service
+type TasksApiService service
/*
-FoldersApiService Create a folder
+TasksApiService Get all tasks
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createFolder Name of the folder
+ * @param optional nil or *CrmTasksGetOpts - Optional Parameters:
+ * @param "FilterType" (optional.String) - Filter by task type (ID)
+ * @param "FilterStatus" (optional.String) - Filter by task status
+ * @param "FilterDate" (optional.String) - Filter by date
+ * @param "FilterAssignTo" (optional.String) - Filter by assignTo id
+ * @param "FilterContacts" (optional.String) - Filter by contact ids
+ * @param "FilterDeals" (optional.String) - Filter by deals ids
+ * @param "FilterCompanies" (optional.String) - Filter by companies ids
+ * @param "DateFrom" (optional.Int32) - dateFrom to date range filter type (timestamp in milliseconds)
+ * @param "DateTo" (optional.Int32) - dateTo to date range filter type (timestamp in milliseconds)
+ * @param "Offset" (optional.Int64) - Index of the first document of the page
+ * @param "Limit" (optional.Int64) - Number of documents per page
+ * @param "Sort" (optional.String) - Sort the results in the ascending/descending order. Default order is **descending** by creation if `sort` is not passed
+ * @param "SortBy" (optional.String) - The field used to sort field names.
-@return CreateModel
+@return TaskList
*/
-func (a *FoldersApiService) CreateFolder(ctx context.Context, createFolder CreateUpdateFolder) (CreateModel, *http.Response, error) {
+
+type CrmTasksGetOpts struct {
+ FilterType optional.String
+ FilterStatus optional.String
+ FilterDate optional.String
+ FilterAssignTo optional.String
+ FilterContacts optional.String
+ FilterDeals optional.String
+ FilterCompanies optional.String
+ DateFrom optional.Int32
+ DateTo optional.Int32
+ Offset optional.Int64
+ Limit optional.Int64
+ Sort optional.String
+ SortBy optional.String
+}
+
+func (a *TasksApiService) CrmTasksGet(ctx context.Context, localVarOptionals *CrmTasksGetOpts) (TaskList, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Post")
+ localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue CreateModel
+ localVarReturnValue TaskList
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders"
+ localVarPath := a.client.cfg.BasePath + "/crm/tasks"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
+ if localVarOptionals != nil && localVarOptionals.FilterType.IsSet() {
+ localVarQueryParams.Add("filter[type]", parameterToString(localVarOptionals.FilterType.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterStatus.IsSet() {
+ localVarQueryParams.Add("filter[status]", parameterToString(localVarOptionals.FilterStatus.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterDate.IsSet() {
+ localVarQueryParams.Add("filter[date]", parameterToString(localVarOptionals.FilterDate.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterAssignTo.IsSet() {
+ localVarQueryParams.Add("filter[assignTo]", parameterToString(localVarOptionals.FilterAssignTo.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterContacts.IsSet() {
+ localVarQueryParams.Add("filter[contacts]", parameterToString(localVarOptionals.FilterContacts.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterDeals.IsSet() {
+ localVarQueryParams.Add("filter[deals]", parameterToString(localVarOptionals.FilterDeals.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.FilterCompanies.IsSet() {
+ localVarQueryParams.Add("filter[companies]", parameterToString(localVarOptionals.FilterCompanies.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateFrom.IsSet() {
+ localVarQueryParams.Add("dateFrom", parameterToString(localVarOptionals.DateFrom.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.DateTo.IsSet() {
+ localVarQueryParams.Add("dateTo", parameterToString(localVarOptionals.DateTo.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
+ localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
+ localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
+ localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
+ }
+ if localVarOptionals != nil && localVarOptionals.SortBy.IsSet() {
+ localVarQueryParams.Add("sortBy", parameterToString(localVarOptionals.SortBy.Value(), ""))
+ }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -66,8 +137,6 @@ func (a *FoldersApiService) CreateFolder(ctx context.Context, createFolder Creat
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &createFolder
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -124,8 +193,8 @@ func (a *FoldersApiService) CreateFolder(ctx context.Context, createFolder Creat
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 201 {
- var v CreateModel
+ if localVarHttpResponse.StatusCode == 200 {
+ var v TaskList
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -153,13 +222,11 @@ func (a *FoldersApiService) CreateFolder(ctx context.Context, createFolder Creat
}
/*
-FoldersApiService Delete a folder (and all its lists)
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
-
-
+TasksApiService Delete a task
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
*/
-func (a *FoldersApiService) DeleteFolder(ctx context.Context, folderId int64) (*http.Response, error) {
+func (a *TasksApiService) CrmTasksIdDelete(ctx context.Context, id string) (*http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Delete")
localVarPostBody interface{}
@@ -168,8 +235,8 @@ func (a *FoldersApiService) DeleteFolder(ctx context.Context, folderId int64) (*
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders/{folderId}"
- localVarPath = strings.Replace(localVarPath, "{"+"folderId"+"}", fmt.Sprintf("%v", folderId), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -269,24 +336,24 @@ func (a *FoldersApiService) DeleteFolder(ctx context.Context, folderId int64) (*
}
/*
-FoldersApiService Returns a folder's details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId id of the folder
+TasksApiService Get a task
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
-@return GetFolder
+@return Task
*/
-func (a *FoldersApiService) GetFolder(ctx context.Context, folderId int64) (GetFolder, *http.Response, error) {
+func (a *TasksApiService) CrmTasksIdGet(ctx context.Context, id string) (Task, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetFolder
+ localVarReturnValue Task
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders/{folderId}"
- localVarPath = strings.Replace(localVarPath, "{"+"folderId"+"}", fmt.Sprintf("%v", folderId), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -366,7 +433,7 @@ func (a *FoldersApiService) GetFolder(ctx context.Context, folderId int64) (GetF
}
if localVarHttpResponse.StatusCode == 200 {
- var v GetFolder
+ var v Task
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -405,43 +472,27 @@ func (a *FoldersApiService) GetFolder(ctx context.Context, folderId int64) (GetF
}
/*
-FoldersApiService Get lists in a folder
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
- * @param optional nil or *GetFolderListsOpts - Optional Parameters:
- * @param "Limit" (optional.Int64) - Number of documents per page
- * @param "Offset" (optional.Int64) - Index of the first document of the page
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
-
-@return GetFolderLists
+TasksApiService Update a task
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param id
+ - @param body Updated task details.
*/
-
-func (a *FoldersApiService) GetFolderLists(ctx context.Context, folderId int64, localVarOptionals *GetFolderListsOpts) (GetFolderLists, *http.Response, error) {
+func (a *TasksApiService) CrmTasksIdPatch(ctx context.Context, id string, body Body7) (*http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
- localVarReturnValue GetFolderLists
+ localVarHttpMethod = strings.ToUpper("Patch")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders/{folderId}/lists"
- localVarPath = strings.Replace(localVarPath, "{"+"folderId"+"}", fmt.Sprintf("%v", folderId), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/tasks/{id}"
+ localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", fmt.Sprintf("%v", id), -1)
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if localVarOptionals != nil && localVarOptionals.Limit.IsSet() {
- localVarQueryParams.Add("limit", parameterToString(localVarOptionals.Limit.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Offset.IsSet() {
- localVarQueryParams.Add("offset", parameterToString(localVarOptionals.Offset.Value(), ""))
- }
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -459,6 +510,8 @@ func (a *FoldersApiService) GetFolderLists(ctx context.Context, folderId int64,
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -487,26 +540,18 @@ func (a *FoldersApiService) GetFolderLists(ctx context.Context, folderId int64,
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return localVarReturnValue, nil, err
+ return nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarReturnValue, localVarHttpResponse, err
+ return localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
-
- if localVarHttpResponse.StatusCode < 300 {
- // If we succeed, return the data, otherwise pass on to decode error.
- err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err == nil {
- return localVarReturnValue, localVarHttpResponse, err
- }
+ return localVarHttpResponse, err
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -515,26 +560,15 @@ func (a *FoldersApiService) GetFolderLists(ctx context.Context, folderId int64,
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v GetFolderLists
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
if localVarHttpResponse.StatusCode == 400 {
var v ErrorModel
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
if localVarHttpResponse.StatusCode == 404 {
@@ -542,53 +576,41 @@ func (a *FoldersApiService) GetFolderLists(ctx context.Context, folderId int64,
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, newErr
+ return localVarHttpResponse, newErr
}
- return localVarReturnValue, localVarHttpResponse, nil
+ return localVarHttpResponse, nil
}
/*
-FoldersApiService Get all folders
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param limit Number of documents per page
- * @param offset Index of the first document of the page
- * @param optional nil or *GetFoldersOpts - Optional Parameters:
- * @param "Sort" (optional.String) - Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
+TasksApiService Create a task
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param body Task name.
-@return GetFolders
+@return InlineResponse2011
*/
-
-func (a *FoldersApiService) GetFolders(ctx context.Context, limit int64, offset int64, localVarOptionals *GetFoldersOpts) (GetFolders, *http.Response, error) {
+func (a *TasksApiService) CrmTasksPost(ctx context.Context, body Body6) (InlineResponse2011, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Get")
+ localVarHttpMethod = strings.ToUpper("Post")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue GetFolders
+ localVarReturnValue InlineResponse2011
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders"
+ localVarPath := a.client.cfg.BasePath + "/crm/tasks"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
localVarFormParams := url.Values{}
- if limit > 50 {
- return localVarReturnValue, nil, reportError("limit must be less than 50")
- }
- localVarQueryParams.Add("limit", parameterToString(limit, ""))
- localVarQueryParams.Add("offset", parameterToString(offset, ""))
- if localVarOptionals != nil && localVarOptionals.Sort.IsSet() {
- localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), ""))
- }
// to determine the Content-Type header
localVarHttpContentTypes := []string{"application/json"}
@@ -606,6 +628,8 @@ func (a *FoldersApiService) GetFolders(ctx context.Context, limit int64, offset
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
+ // body params
+ localVarPostBody = &body
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -662,19 +686,8 @@ func (a *FoldersApiService) GetFolders(ctx context.Context, limit int64, offset
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 200 {
- var v GetFolders
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarReturnValue, localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarReturnValue, localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 201 {
+ var v InlineResponse2011
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
@@ -691,24 +704,22 @@ func (a *FoldersApiService) GetFolders(ctx context.Context, limit int64, offset
}
/*
-FoldersApiService Update a folder
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param folderId Id of the folder
- * @param updateFolder Name of the folder
-
+TasksApiService Get all task types
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+@return TaskTypes
*/
-func (a *FoldersApiService) UpdateFolder(ctx context.Context, folderId int64, updateFolder CreateUpdateFolder) (*http.Response, error) {
+func (a *TasksApiService) CrmTasktypesGet(ctx context.Context) (TaskTypes, *http.Response, error) {
var (
- localVarHttpMethod = strings.ToUpper("Put")
- localVarPostBody interface{}
- localVarFileName string
- localVarFileBytes []byte
+ localVarHttpMethod = strings.ToUpper("Get")
+ localVarPostBody interface{}
+ localVarFileName string
+ localVarFileBytes []byte
+ localVarReturnValue TaskTypes
)
// create path and map variables
- localVarPath := a.client.cfg.BasePath + "/contacts/folders/{folderId}"
- localVarPath = strings.Replace(localVarPath, "{"+"folderId"+"}", fmt.Sprintf("%v", folderId), -1)
+ localVarPath := a.client.cfg.BasePath + "/crm/tasktypes"
localVarHeaderParams := make(map[string]string)
localVarQueryParams := url.Values{}
@@ -731,8 +742,6 @@ func (a *FoldersApiService) UpdateFolder(ctx context.Context, folderId int64, up
if localVarHttpHeaderAccept != "" {
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
}
- // body params
- localVarPostBody = &updateFolder
if ctx != nil {
// API Key Authentication
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
@@ -761,18 +770,26 @@ func (a *FoldersApiService) UpdateFolder(ctx context.Context, folderId int64, up
}
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
if err != nil {
- return nil, err
+ return localVarReturnValue, nil, err
}
localVarHttpResponse, err := a.client.callAPI(r)
if err != nil || localVarHttpResponse == nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
}
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
localVarHttpResponse.Body.Close()
if err != nil {
- return localVarHttpResponse, err
+ return localVarReturnValue, localVarHttpResponse, err
+ }
+
+ if localVarHttpResponse.StatusCode < 300 {
+ // If we succeed, return the data, otherwise pass on to decode error.
+ err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
+ if err == nil {
+ return localVarReturnValue, localVarHttpResponse, err
+ }
}
if localVarHttpResponse.StatusCode >= 300 {
@@ -781,30 +798,19 @@ func (a *FoldersApiService) UpdateFolder(ctx context.Context, folderId int64, up
error: localVarHttpResponse.Status,
}
- if localVarHttpResponse.StatusCode == 400 {
- var v ErrorModel
- err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = err.Error()
- return localVarHttpResponse, newErr
- }
- newErr.model = v
- return localVarHttpResponse, newErr
- }
-
- if localVarHttpResponse.StatusCode == 404 {
- var v ErrorModel
+ if localVarHttpResponse.StatusCode == 200 {
+ var v TaskTypes
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
newErr.model = v
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, newErr
+ return localVarReturnValue, localVarHttpResponse, newErr
}
- return localVarHttpResponse, nil
+ return localVarReturnValue, localVarHttpResponse, nil
}
diff --git a/lib/api_transactional_emails.go b/lib/api_transactional_emails.go
index 49bebc8..997f2b3 100644
--- a/lib/api_transactional_emails.go
+++ b/lib/api_transactional_emails.go
@@ -31,10 +31,8 @@ type TransactionalEmailsApiService service
/*
TransactionalEmailsApiService Add a new domain to the list of blocked domains
Blocks a new domain in order to avoid messages being sent to the same
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param blockDomain
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param blockDomain
*/
func (a *TransactionalEmailsApiService) BlockNewDomain(ctx context.Context, blockDomain BlockDomain) (*http.Response, error) {
var (
@@ -137,8 +135,8 @@ func (a *TransactionalEmailsApiService) BlockNewDomain(ctx context.Context, bloc
/*
TransactionalEmailsApiService Create an email template
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param smtpTemplate values to update in transactional email template
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param smtpTemplate values to update in transactional email template
@return CreateModel
*/
@@ -264,10 +262,8 @@ func (a *TransactionalEmailsApiService) CreateSmtpTemplate(ctx context.Context,
/*
TransactionalEmailsApiService Unblock an existing domain from the list of blocked domains
Unblocks an existing domain from the list of blocked domains
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param domain The name of the domain to be deleted
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param domain The name of the domain to be deleted
*/
func (a *TransactionalEmailsApiService) DeleteBlockedDomain(ctx context.Context, domain string) (*http.Response, error) {
var (
@@ -490,10 +486,8 @@ func (a *TransactionalEmailsApiService) DeleteHardbounces(ctx context.Context, l
/*
TransactionalEmailsApiService Delete scheduled emails by batchId or messageId
Delete scheduled batch of emails by batchId or single scheduled email by messageId
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param identifier The `batchId` of scheduled emails batch (Should be a valid UUIDv4) or the `messageId` of scheduled email.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param identifier The `batchId` of scheduled emails batch (Should be a valid UUIDv4) or the `messageId` of scheduled email.
*/
func (a *TransactionalEmailsApiService) DeleteScheduledEmailById(ctx context.Context, identifier string) (*http.Response, error) {
var (
@@ -606,10 +600,8 @@ func (a *TransactionalEmailsApiService) DeleteScheduledEmailById(ctx context.Con
/*
TransactionalEmailsApiService Delete an inactive email template
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param templateId id of the template
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param templateId id of the template
*/
func (a *TransactionalEmailsApiService) DeleteSmtpTemplate(ctx context.Context, templateId int64) (*http.Response, error) {
var (
@@ -872,7 +864,7 @@ func (a *TransactionalEmailsApiService) GetAggregatedSmtpReport(ctx context.Cont
/*
TransactionalEmailsApiService Get the list of blocked domains
Get the list of blocked domains
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
@return GetBlockedDomains
*/
@@ -1655,8 +1647,8 @@ func (a *TransactionalEmailsApiService) GetSmtpReport(ctx context.Context, local
/*
TransactionalEmailsApiService Returns the template information
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param templateId id of the template
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param templateId id of the template
@return GetSmtpTemplateOverview
*/
@@ -2097,8 +2089,8 @@ func (a *TransactionalEmailsApiService) GetTransacBlockedContacts(ctx context.Co
/*
TransactionalEmailsApiService Get the personalized content of a sent transactional email
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param uuid Unique id of the transactional email that has been sent to a particular contact
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param uuid Unique id of the transactional email that has been sent to a particular contact
@return GetTransacEmailContent
*/
@@ -2380,11 +2372,9 @@ func (a *TransactionalEmailsApiService) GetTransacEmailsList(ctx context.Context
/*
TransactionalEmailsApiService Send a template to your test list
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param templateId Id of the template
- * @param sendTestEmail
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param templateId Id of the template
+ - @param sendTestEmail
*/
func (a *TransactionalEmailsApiService) SendTestTemplate(ctx context.Context, templateId int64, sendTestEmail SendTestEmail) (*http.Response, error) {
var (
@@ -2499,8 +2489,8 @@ func (a *TransactionalEmailsApiService) SendTestTemplate(ctx context.Context, te
/*
TransactionalEmailsApiService Send a transactional email
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param sendSmtpEmail Values to send a transactional email
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param sendSmtpEmail Values to send a transactional email
@return CreateSmtpEmail
*/
@@ -2636,10 +2626,8 @@ func (a *TransactionalEmailsApiService) SendTransacEmail(ctx context.Context, se
/*
TransactionalEmailsApiService Unblock or resubscribe a transactional contact
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param email contact email (urlencoded) to unblock.
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param email contact email (urlencoded) to unblock.
*/
func (a *TransactionalEmailsApiService) SmtpBlockedContactsEmailDelete(ctx context.Context, email string) (*http.Response, error) {
var (
@@ -2752,10 +2740,8 @@ func (a *TransactionalEmailsApiService) SmtpBlockedContactsEmailDelete(ctx conte
/*
TransactionalEmailsApiService Delete an SMTP transactional log
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param messageId MessageId of the transactional log to delete
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param messageId MessageId of the transactional log to delete
*/
func (a *TransactionalEmailsApiService) SmtpLogMessageIdDelete(ctx context.Context, messageId string) (*http.Response, error) {
var (
@@ -2868,11 +2854,9 @@ func (a *TransactionalEmailsApiService) SmtpLogMessageIdDelete(ctx context.Conte
/*
TransactionalEmailsApiService Update an email template
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param templateId id of the template
- * @param smtpTemplate values to update in transactional email template
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param templateId id of the template
+ - @param smtpTemplate values to update in transactional email template
*/
func (a *TransactionalEmailsApiService) UpdateSmtpTemplate(ctx context.Context, templateId int64, smtpTemplate UpdateSmtpTemplate) (*http.Response, error) {
var (
diff --git a/lib/api_transactional_sms.go b/lib/api_transactional_sms.go
index 3196d20..72186f7 100644
--- a/lib/api_transactional_sms.go
+++ b/lib/api_transactional_sms.go
@@ -503,8 +503,8 @@ func (a *TransactionalSMSApiService) GetTransacSmsReport(ctx context.Context, lo
/*
TransactionalSMSApiService Send SMS message to a mobile number
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param sendTransacSms Values to send a transactional SMS
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param sendTransacSms Values to send a transactional SMS
@return SendSms
*/
diff --git a/lib/api_webhooks.go b/lib/api_webhooks.go
index e19470e..7ec147c 100644
--- a/lib/api_webhooks.go
+++ b/lib/api_webhooks.go
@@ -30,8 +30,8 @@ type WebhooksApiService service
/*
WebhooksApiService Create a webhook
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param createWebhook Values to create a webhook
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param createWebhook Values to create a webhook
@return CreateModel
*/
@@ -156,10 +156,8 @@ func (a *WebhooksApiService) CreateWebhook(ctx context.Context, createWebhook Cr
/*
WebhooksApiService Delete a webhook
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param webhookId Id of the webhook
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param webhookId Id of the webhook
*/
func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, webhookId int64) (*http.Response, error) {
var (
@@ -272,8 +270,8 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, webhookId int64)
/*
WebhooksApiService Get a webhook details
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param webhookId Id of the webhook
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param webhookId Id of the webhook
@return GetWebhook
*/
@@ -546,11 +544,9 @@ func (a *WebhooksApiService) GetWebhooks(ctx context.Context, localVarOptionals
/*
WebhooksApiService Update a webhook
- * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param webhookId Id of the webhook
- * @param updateWebhook Values to update a webhook
-
-
+ - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
+ - @param webhookId Id of the webhook
+ - @param updateWebhook Values to update a webhook
*/
func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, webhookId int64, updateWebhook UpdateWebhook) (*http.Response, error) {
var (
diff --git a/lib/client.go b/lib/client.go
index fcdb34a..596fc65 100644
--- a/lib/client.go
+++ b/lib/client.go
@@ -48,26 +48,26 @@ type APIClient struct {
AccountApi *AccountApiService
- AttributesApi *AttributesApiService
-
- CRMApi *CRMApiService
-
CompaniesApi *CompaniesApiService
ContactsApi *ContactsApiService
+ ConversationsApi *ConversationsApiService
+
DealsApi *DealsApiService
+ EcommerceApi *EcommerceApiService
+
EmailCampaignsApi *EmailCampaignsApiService
- FoldersApi *FoldersApiService
+ FilesApi *FilesApiService
InboundParsingApi *InboundParsingApiService
- ListsApi *ListsApiService
-
MasterAccountApi *MasterAccountApiService
+ NotesApi *NotesApiService
+
ProcessApi *ProcessApiService
ResellerApi *ResellerApiService
@@ -76,6 +76,8 @@ type APIClient struct {
SendersApi *SendersApiService
+ TasksApi *TasksApiService
+
TransactionalEmailsApi *TransactionalEmailsApiService
TransactionalSMSApi *TransactionalSMSApiService
@@ -100,20 +102,21 @@ func NewAPIClient(cfg *Configuration) *APIClient {
// API Services
c.AccountApi = (*AccountApiService)(&c.common)
- c.AttributesApi = (*AttributesApiService)(&c.common)
- c.CRMApi = (*CRMApiService)(&c.common)
c.CompaniesApi = (*CompaniesApiService)(&c.common)
c.ContactsApi = (*ContactsApiService)(&c.common)
+ c.ConversationsApi = (*ConversationsApiService)(&c.common)
c.DealsApi = (*DealsApiService)(&c.common)
+ c.EcommerceApi = (*EcommerceApiService)(&c.common)
c.EmailCampaignsApi = (*EmailCampaignsApiService)(&c.common)
- c.FoldersApi = (*FoldersApiService)(&c.common)
+ c.FilesApi = (*FilesApiService)(&c.common)
c.InboundParsingApi = (*InboundParsingApiService)(&c.common)
- c.ListsApi = (*ListsApiService)(&c.common)
c.MasterAccountApi = (*MasterAccountApiService)(&c.common)
+ c.NotesApi = (*NotesApiService)(&c.common)
c.ProcessApi = (*ProcessApiService)(&c.common)
c.ResellerApi = (*ResellerApiService)(&c.common)
c.SMSCampaignsApi = (*SMSCampaignsApiService)(&c.common)
c.SendersApi = (*SendersApiService)(&c.common)
+ c.TasksApi = (*TasksApiService)(&c.common)
c.TransactionalEmailsApi = (*TransactionalEmailsApiService)(&c.common)
c.TransactionalSMSApi = (*TransactionalSMSApiService)(&c.common)
c.WebhooksApi = (*WebhooksApiService)(&c.common)
diff --git a/lib/configuration.go b/lib/configuration.go
index 9297144..18bad41 100644
--- a/lib/configuration.go
+++ b/lib/configuration.go
@@ -63,7 +63,7 @@ func NewConfiguration() *Configuration {
cfg := &Configuration{
BasePath: "https://api.sendinblue.com/v3",
DefaultHeader: make(map[string]string),
- UserAgent: "Swagger-Codegen/2.0.1/go",
+ UserAgent: "Swagger-Codegen/1.0.0/go",
}
return cfg
}
diff --git a/lib/model_body.go b/lib/model_body.go
index 1bb4f5f..750fe15 100644
--- a/lib/model_body.go
+++ b/lib/model_body.go
@@ -11,8 +11,10 @@
package lib
type Body struct {
- // Name of deal
+ // Name of company
Name string `json:"name"`
- // Attributes fo\\r deal creation
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ // Attributes for company creation
+ Attributes *interface{} `json:"attributes,omitempty"`
+ // Country code if phone_number is passed in attributes.
+ CountryCode int64 `json:"countryCode,omitempty"`
}
diff --git a/lib/model_body_1.go b/lib/model_body_1.go
index 96e7319..000d7b9 100644
--- a/lib/model_body_1.go
+++ b/lib/model_body_1.go
@@ -11,8 +11,10 @@
package lib
type Body1 struct {
- // Name of deal
+ // Name of company
Name string `json:"name,omitempty"`
- // Attributes for deal update
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ // Attributes for company update
+ Attributes *interface{} `json:"attributes,omitempty"`
+ // Country code if phone_number is passed in attributes.
+ CountryCode int64 `json:"countryCode,omitempty"`
}
diff --git a/lib/model_body_10.go b/lib/model_body_10.go
new file mode 100644
index 0000000..e2a4014
--- /dev/null
+++ b/lib/model_body_10.go
@@ -0,0 +1,22 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Body10 struct {
+ // visitor’s ID received from a webhook or generated by you to bind existing user account to Conversations
+ VisitorId string `json:"visitorId"`
+ // message text
+ Text string `json:"text"`
+ // agent ID. It can be found on agent’s page or received from a webhook. Optional if `groupId` is set.
+ AgentId string `json:"agentId,omitempty"`
+ // group ID. It can be found on group’s page. Optional if `agentId` is set.
+ GroupId string `json:"groupId,omitempty"`
+}
diff --git a/lib/model_body_11.go b/lib/model_body_11.go
new file mode 100644
index 0000000..c36ff10
--- /dev/null
+++ b/lib/model_body_11.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Body11 struct {
+ // edited message text
+ Text string `json:"text"`
+}
diff --git a/lib/model_body_12.go b/lib/model_body_12.go
new file mode 100644
index 0000000..9e431dd
--- /dev/null
+++ b/lib/model_body_12.go
@@ -0,0 +1,22 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Body12 struct {
+ // agent ID. It can be found on agent’s page or received from a webhook. Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom` instead (all 3 fields required).
+ AgentId string `json:"agentId,omitempty"`
+ // mark your messages to distinguish messages created by you from the others.
+ ReceivedFrom string `json:"receivedFrom,omitempty"`
+ // agent email. When sending online pings from a standalone system, it’s hard to maintain a 1-to-1 relationship between the users of both systems. In this case, an agent can be specified by their email address. If there’s no agent with the specified email address in your Sendinblue organization, a dummy agent will be created automatically.
+ AgentEmail string `json:"agentEmail,omitempty"`
+ // agent name.
+ AgentName string `json:"agentName,omitempty"`
+}
diff --git a/lib/model_body_2.go b/lib/model_body_2.go
index ae10f50..b8eef81 100644
--- a/lib/model_body_2.go
+++ b/lib/model_body_2.go
@@ -11,8 +11,12 @@
package lib
type Body2 struct {
- // Name of company
- Name string `json:"name"`
- // Attributes for company creation
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ // Contact ids for contacts to be linked with company
+ LinkContactIds []int64 `json:"linkContactIds,omitempty"`
+ // Contact ids for contacts to be unlinked from company
+ UnlinkContactIds []int64 `json:"unlinkContactIds,omitempty"`
+ // Deals ids for deals to be linked with company
+ LinkDealsIds []string `json:"linkDealsIds,omitempty"`
+ // Deals ids for deals to be unlinked from company
+ UnlinkDealsIds []string `json:"unlinkDealsIds,omitempty"`
}
diff --git a/lib/model_body_3.go b/lib/model_body_3.go
index 8d3e339..7e2b9a9 100644
--- a/lib/model_body_3.go
+++ b/lib/model_body_3.go
@@ -11,8 +11,8 @@
package lib
type Body3 struct {
- // Name of company
- Name string `json:"name,omitempty"`
- // Attributes for company update
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ // Name of deal
+ Name string `json:"name"`
+ // Attributes fo\\r deal creation
+ Attributes *interface{} `json:"attributes,omitempty"`
}
diff --git a/lib/model_body_4.go b/lib/model_body_4.go
index fa3d936..db22db2 100644
--- a/lib/model_body_4.go
+++ b/lib/model_body_4.go
@@ -11,12 +11,8 @@
package lib
type Body4 struct {
- // Contact ids for contacts to be linked with company
- LinkContactIds []int32 `json:"linkContactIds,omitempty"`
- // Contact ids for contacts to be unlinked from company
- UnlinkContactIds []int32 `json:"unlinkContactIds,omitempty"`
- // Deals ids for deals to be linked with company
- LinkDealsIds []string `json:"linkDealsIds,omitempty"`
- // Deals ids for deals to be unlinked from company
- UnlinkDealsIds []string `json:"unlinkDealsIds,omitempty"`
+ // Name of deal
+ Name string `json:"name,omitempty"`
+ // Attributes for deal update
+ Attributes *interface{} `json:"attributes,omitempty"`
}
diff --git a/lib/model_body_5.go b/lib/model_body_5.go
index cd6633e..270f8c9 100644
--- a/lib/model_body_5.go
+++ b/lib/model_body_5.go
@@ -10,30 +10,13 @@
package lib
-import (
- "time"
-)
-
type Body5 struct {
- // Name of task
- Name string `json:"name"`
- // Duration of task in milliseconds [1 minute = 60000 ms]
- Duration int64 `json:"duration,omitempty"`
- // Id for type of task e.g Call / Email / Meeting etc.
- TaskTypeId string `json:"taskTypeId"`
- // Task due date and time
- Date time.Time `json:"date"`
- // Notes added to a task
- Notes string `json:"notes,omitempty"`
- // Task marked as done
- Done bool `json:"done,omitempty"`
- // User id to whom task is assigned
- AssignToId string `json:"assignToId,omitempty"`
- // Contact ids for contacts linked to this task
- ContactsIds []int32 `json:"contactsIds,omitempty"`
- // Deal ids for deals a task is linked to
- DealsIds []string `json:"dealsIds,omitempty"`
- // Companies ids for companies a task is linked to
- CompaniesIds []string `json:"companiesIds,omitempty"`
- Reminder *TaskReminder `json:"reminder,omitempty"`
+ // Contact ids for contacts to be linked with deal
+ LinkContactIds []int64 `json:"linkContactIds,omitempty"`
+ // Contact ids for contacts to be unlinked from deal
+ UnlinkContactIds []int64 `json:"unlinkContactIds,omitempty"`
+ // Company ids to be linked with deal
+ LinkCompanyIds []string `json:"linkCompanyIds,omitempty"`
+ // Company ids to be unlinked from deal
+ UnlinkCompanyIds []string `json:"unlinkCompanyIds,omitempty"`
}
diff --git a/lib/model_body_6.go b/lib/model_body_6.go
index 6d6e449..3e95182 100644
--- a/lib/model_body_6.go
+++ b/lib/model_body_6.go
@@ -16,13 +16,13 @@ import (
type Body6 struct {
// Name of task
- Name string `json:"name,omitempty"`
+ Name string `json:"name"`
// Duration of task in milliseconds [1 minute = 60000 ms]
- Duration int32 `json:"duration,omitempty"`
+ Duration int64 `json:"duration,omitempty"`
// Id for type of task e.g Call / Email / Meeting etc.
- TaskTypeId string `json:"taskTypeId,omitempty"`
- // Task date/time
- Date time.Time `json:"date,omitempty"`
+ TaskTypeId string `json:"taskTypeId"`
+ // Task due date and time
+ Date time.Time `json:"date"`
// Notes added to a task
Notes string `json:"notes,omitempty"`
// Task marked as done
@@ -34,5 +34,6 @@ type Body6 struct {
// Deal ids for deals a task is linked to
DealsIds []string `json:"dealsIds,omitempty"`
// Companies ids for companies a task is linked to
- CompaniesIds []string `json:"companiesIds,omitempty"`
+ CompaniesIds []string `json:"companiesIds,omitempty"`
+ Reminder *TaskReminder `json:"reminder,omitempty"`
}
diff --git a/lib/model_body_7.go b/lib/model_body_7.go
new file mode 100644
index 0000000..66d9837
--- /dev/null
+++ b/lib/model_body_7.go
@@ -0,0 +1,38 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+import (
+ "time"
+)
+
+type Body7 struct {
+ // Name of task
+ Name string `json:"name,omitempty"`
+ // Duration of task in milliseconds [1 minute = 60000 ms]
+ Duration int32 `json:"duration,omitempty"`
+ // Id for type of task e.g Call / Email / Meeting etc.
+ TaskTypeId string `json:"taskTypeId,omitempty"`
+ // Task date/time
+ Date time.Time `json:"date,omitempty"`
+ // Notes added to a task
+ Notes string `json:"notes,omitempty"`
+ // Task marked as done
+ Done bool `json:"done,omitempty"`
+ // User id to whom task is assigned
+ AssignToId string `json:"assignToId,omitempty"`
+ // Contact ids for contacts linked to this task
+ ContactsIds []int32 `json:"contactsIds,omitempty"`
+ // Deal ids for deals a task is linked to
+ DealsIds []string `json:"dealsIds,omitempty"`
+ // Companies ids for companies a task is linked to
+ CompaniesIds []string `json:"companiesIds,omitempty"`
+}
diff --git a/lib/model_body_8.go b/lib/model_body_8.go
new file mode 100644
index 0000000..955b225
--- /dev/null
+++ b/lib/model_body_8.go
@@ -0,0 +1,26 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Body8 struct {
+ // visitor’s ID received from a webhook or generated by you to bind existing user account to Conversations
+ VisitorId string `json:"visitorId"`
+ // message text
+ Text string `json:"text"`
+ // agent ID. It can be found on agent’s page or received from a webhook. Alternatively, you can use `agentEmail` + `agentName` + `receivedFrom` instead (all 3 fields required).
+ AgentId string `json:"agentId,omitempty"`
+ // mark your messages to distinguish messages created by you from the others.
+ ReceivedFrom string `json:"receivedFrom,omitempty"`
+ // agent email. When sending messages from a standalone system, it’s hard to maintain a 1-to-1 relationship between the users of both systems. In this case, an agent can be specified by their email address.
+ AgentEmail string `json:"agentEmail,omitempty"`
+ // agent name
+ AgentName string `json:"agentName,omitempty"`
+}
diff --git a/lib/model_body_9.go b/lib/model_body_9.go
new file mode 100644
index 0000000..9a909f6
--- /dev/null
+++ b/lib/model_body_9.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Body9 struct {
+ // edited message text
+ Text string `json:"text"`
+}
diff --git a/lib/model_companies_list.go b/lib/model_companies_list.go
index 6b4fcc9..f842c97 100644
--- a/lib/model_companies_list.go
+++ b/lib/model_companies_list.go
@@ -10,7 +10,7 @@
package lib
-// List of comapnies
+// List of companies
type CompaniesList struct {
// List of compaies
Items []Company `json:"items,omitempty"`
diff --git a/lib/model_company.go b/lib/model_company.go
index 0b37f30..21534f2 100644
--- a/lib/model_company.go
+++ b/lib/model_company.go
@@ -15,7 +15,7 @@ type Company struct {
// Unique company id
Id string `json:"id,omitempty"`
// Company attributes with values
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ Attributes *interface{} `json:"attributes,omitempty"`
// Contact ids for contacts linked to this company
LinkedContactsIds []int32 `json:"linkedContactsIds,omitempty"`
// Deals ids for companies linked to this company
diff --git a/lib/model_conversations_message.go b/lib/model_conversations_message.go
new file mode 100644
index 0000000..a38e782
--- /dev/null
+++ b/lib/model_conversations_message.go
@@ -0,0 +1,34 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+// a Conversations message
+type ConversationsMessage struct {
+ // Message ID. It can be used for further manipulations with the message.
+ Id string `json:"id,omitempty"`
+ // `\"agent\"` for agents’ messages, `\"visitor\"` for visitors’ messages.
+ Type_ string `json:"type,omitempty"`
+ // Message text or name of the attached file
+ Text string `json:"text,omitempty"`
+ // visitor’s ID
+ VisitorId string `json:"visitorId,omitempty"`
+ // ID of the agent on whose behalf the message was sent (only in messages sent by an agent).
+ AgentId string `json:"agentId,omitempty"`
+ // Agent’s name as displayed to the visitor. Only in the messages sent by an agent.
+ AgentName string `json:"agentName,omitempty"`
+ // Timestamp in milliseconds.
+ CreatedAt int64 `json:"createdAt,omitempty"`
+ // `true` for pushed messages
+ IsPushed bool `json:"isPushed,omitempty"`
+ // In two-way integrations, messages sent via REST API can be marked with receivedFrom property and then filtered out when received in a webhook to avoid infinite loop.
+ ReceivedFrom string `json:"receivedFrom,omitempty"`
+ File *ConversationsMessageFile `json:"file,omitempty"`
+}
diff --git a/lib/model_conversations_message_file.go b/lib/model_conversations_message_file.go
new file mode 100644
index 0000000..a9c14e1
--- /dev/null
+++ b/lib/model_conversations_message_file.go
@@ -0,0 +1,23 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type ConversationsMessageFile struct {
+ // Name of the file
+ Filename string `json:"filename,omitempty"`
+ // Size in bytes
+ Size int64 `json:"size,omitempty"`
+ // Whether the file is an image
+ IsImage bool `json:"isImage,omitempty"`
+ // URL of the file
+ Url string `json:"url,omitempty"`
+ ImageInfo *ConversationsMessageFileImageInfo `json:"imageInfo,omitempty"`
+}
diff --git a/lib/model_conversations_message_file_image_info.go b/lib/model_conversations_message_file_image_info.go
new file mode 100644
index 0000000..7ab1ec4
--- /dev/null
+++ b/lib/model_conversations_message_file_image_info.go
@@ -0,0 +1,21 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+// image info is passed in case the file is an image
+type ConversationsMessageFileImageInfo struct {
+ // Width of the image
+ Width int64 `json:"width,omitempty"`
+ // height of the image
+ Height int64 `json:"height,omitempty"`
+ // URL of the preview
+ PreviewUrl string `json:"previewUrl,omitempty"`
+}
diff --git a/lib/model_create_api_key_request.go b/lib/model_create_api_key_request.go
new file mode 100644
index 0000000..6b02f4d
--- /dev/null
+++ b/lib/model_create_api_key_request.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateApiKeyRequest struct {
+ // Id of the sub-account organization
+ Id int64 `json:"id"`
+ // Name of the API key
+ Name string `json:"name,omitempty"`
+}
diff --git a/lib/model_create_api_key_response.go b/lib/model_create_api_key_response.go
new file mode 100644
index 0000000..ef28ec7
--- /dev/null
+++ b/lib/model_create_api_key_response.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateApiKeyResponse struct {
+ // Status of the API operation.
+ Status string `json:"status,omitempty"`
+ // API Key
+ Key string `json:"key,omitempty"`
+}
diff --git a/lib/model_create_attribute.go b/lib/model_create_attribute.go
index 91bef06..f139599 100644
--- a/lib/model_create_attribute.go
+++ b/lib/model_create_attribute.go
@@ -13,6 +13,8 @@ package lib
type CreateAttribute struct {
// Value of the attribute. Use only if the attribute's category is 'calculated' or 'global'
Value string `json:"value,omitempty"`
+ // Type of the calculated attribute. Use only if the attribute's category is 'calculated'
+ IsRecurring bool `json:"isRecurring,omitempty"`
// 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\"}]
Enumeration []CreateAttributeEnumeration `json:"enumeration,omitempty"`
// 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 )
diff --git a/lib/model_create_category_model.go b/lib/model_create_category_model.go
new file mode 100644
index 0000000..eba4bdb
--- /dev/null
+++ b/lib/model_create_category_model.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateCategoryModel struct {
+ // ID of the category when a new category is created
+ Id string `json:"id,omitempty"`
+}
diff --git a/lib/model_create_doi_contact.go b/lib/model_create_doi_contact.go
index 24708af..ba77b71 100644
--- a/lib/model_create_doi_contact.go
+++ b/lib/model_create_doi_contact.go
@@ -14,7 +14,7 @@ type CreateDoiContact struct {
// Email address where the confirmation email will be sent. This email address will be the identifier for all other contact attributes.
Email string `json:"email"`
// Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For eg. {'FNAME':'Elly', 'LNAME':'Roger'}
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ Attributes *interface{} `json:"attributes,omitempty"`
// Lists under user account where contact should be added
IncludeListIds []int64 `json:"includeListIds"`
// Lists under user account where contact should not be added
diff --git a/lib/model_create_email_campaign.go b/lib/model_create_email_campaign.go
index a1c0a93..effb58e 100644
--- a/lib/model_create_email_campaign.go
+++ b/lib/model_create_email_campaign.go
@@ -44,7 +44,7 @@ type CreateEmailCampaign struct {
// Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed
UtmCampaign string `json:"utmCampaign,omitempty"`
// Pass the set of attributes to customize the type classic campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. Only available if 'type' is 'classic'. It's considered only if campaign is in New Template Language format. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField'
- Params map[string]interface{} `json:"params,omitempty"`
+ Params *interface{} `json:"params,omitempty"`
// Set this to true if you want to send your campaign at best time.
SendAtBestTime bool `json:"sendAtBestTime,omitempty"`
// Status of A/B Test. abTesting = false means it is disabled, & abTesting = true means it is enabled. 'subjectA', 'subjectB', 'splitRule', 'winnerCriteria' & 'winnerDelay' will be considered when abTesting is set to true. 'subjectA' & 'subjectB' are mandatory together & 'subject' if passed is ignored. Can be set to true only if 'sendAtBestTime' is 'false'. You will be able to set up two subject lines for your campaign and send them to a random sample of your total recipients. Half of the test group will receive version A, and the other half will receive version B
@@ -65,4 +65,8 @@ type CreateEmailCampaign struct {
InitialQuota int64 `json:"initialQuota,omitempty"`
// Mandatory if ipWarmupEnable is set to true. Set a percentage increase rate for warming up your ip. We recommend you set the increase rate to 30% per day. If you want to send the same number of emails every day, set the daily increase value to 0%.
IncreaseRate int64 `json:"increaseRate,omitempty"`
+ // Enter an unsubscription page id. The page id is a 24 digit alphanumeric id that can be found in the URL when editing the page. If not entered, then the default unsubscription page will be used.
+ UnsubscriptionPageId string `json:"unsubscriptionPageId,omitempty"`
+ // Mandatory if templateId is used containing the {{ update_profile }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric id that can be found in the URL when editing the form. If not entered, then the default update profile form will be used.
+ UpdateFormId string `json:"updateFormId,omitempty"`
}
diff --git a/lib/model_create_email_campaign_recipients.go b/lib/model_create_email_campaign_recipients.go
index c65ba46..5f16afd 100644
--- a/lib/model_create_email_campaign_recipients.go
+++ b/lib/model_create_email_campaign_recipients.go
@@ -10,10 +10,12 @@
package lib
-// List ids to include/exclude from campaign
+// Segment ids and List ids to include/exclude from campaign
type CreateEmailCampaignRecipients struct {
// List ids to exclude from the campaign
ExclusionListIds []int64 `json:"exclusionListIds,omitempty"`
// Mandatory if scheduledAt is not empty. List Ids to send the campaign to
ListIds []int64 `json:"listIds,omitempty"`
+ // Mandatory if listIds are not used. Segment ids to send the campaign to.
+ SegmentIds []int64 `json:"segmentIds,omitempty"`
}
diff --git a/lib/model_create_product_model.go b/lib/model_create_product_model.go
new file mode 100644
index 0000000..2c53cca
--- /dev/null
+++ b/lib/model_create_product_model.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateProductModel struct {
+ // ID of the Product when a new product is created
+ Id string `json:"id,omitempty"`
+}
diff --git a/lib/model_create_sms_campaign.go b/lib/model_create_sms_campaign.go
index 99683dd..fd1d5c5 100644
--- a/lib/model_create_sms_campaign.go
+++ b/lib/model_create_sms_campaign.go
@@ -22,4 +22,8 @@ type CreateSmsCampaign struct {
ScheduledAt string `json:"scheduledAt,omitempty"`
// Format of the message. It indicates whether the content should be treated as unicode or not.
UnicodeEnabled bool `json:"unicodeEnabled,omitempty"`
+ // A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.**
+ OrganisationPrefix string `json:"organisationPrefix,omitempty"`
+ // Instructions to unsubscribe from future communications. Recommended by U.S. carriers. Must include **STOP** keyword. This will be added as instructions after the end of message content. **Prefer verifying maximum length of 160 characters including this instructions in message content to avoid multiple sending of same sms.**
+ UnsubscribeInstruction string `json:"unsubscribeInstruction,omitempty"`
}
diff --git a/lib/model_create_update_batch_category.go b/lib/model_create_update_batch_category.go
new file mode 100644
index 0000000..a65b850
--- /dev/null
+++ b/lib/model_create_update_batch_category.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateBatchCategory struct {
+ // array of categories objects
+ Categories []CreateUpdateCategories `json:"categories"`
+ // Facilitate to update the existing categories in the same request (updateEnabled = true)
+ UpdateEnabled bool `json:"updateEnabled,omitempty"`
+}
diff --git a/lib/model_create_update_batch_category_model.go b/lib/model_create_update_batch_category_model.go
new file mode 100644
index 0000000..6eeabe9
--- /dev/null
+++ b/lib/model_create_update_batch_category_model.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateBatchCategoryModel struct {
+ // Number of the new created categories
+ CreatedCount int64 `json:"createdCount,omitempty"`
+ // Number of the existing categories updated
+ UpdatedCount int64 `json:"updatedCount,omitempty"`
+}
diff --git a/lib/model_create_update_batch_products.go b/lib/model_create_update_batch_products.go
new file mode 100644
index 0000000..d494bc9
--- /dev/null
+++ b/lib/model_create_update_batch_products.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateBatchProducts struct {
+ // array of products objects
+ Products []CreateUpdateProducts `json:"products"`
+ // Facilitate to update the existing categories in the same request (updateEnabled = true)
+ UpdateEnabled bool `json:"updateEnabled,omitempty"`
+}
diff --git a/lib/model_create_update_batch_products_model.go b/lib/model_create_update_batch_products_model.go
new file mode 100644
index 0000000..89ee028
--- /dev/null
+++ b/lib/model_create_update_batch_products_model.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateBatchProductsModel struct {
+ // Number of the new created products
+ CreatedCount int64 `json:"createdCount,omitempty"`
+ // Number of the existing products updated
+ UpdatedCount int64 `json:"updatedCount,omitempty"`
+}
diff --git a/lib/model_create_update_categories.go b/lib/model_create_update_categories.go
new file mode 100644
index 0000000..385d7b9
--- /dev/null
+++ b/lib/model_create_update_categories.go
@@ -0,0 +1,20 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateCategories struct {
+ // Unique Category ID as saved in the shop
+ Id string `json:"id"`
+ // **Mandatory in case of creation**. Name of the Category, as displayed in the shop
+ Name string `json:"name,omitempty"`
+ // URL to the category
+ Url string `json:"url,omitempty"`
+}
diff --git a/lib/model_create_update_category.go b/lib/model_create_update_category.go
new file mode 100644
index 0000000..8d0969d
--- /dev/null
+++ b/lib/model_create_update_category.go
@@ -0,0 +1,22 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateCategory struct {
+ // Unique Category ID as saved in the shop
+ Id string `json:"id"`
+ // **Mandatory in case of creation**. Name of the Category, as displayed in the shop
+ Name string `json:"name,omitempty"`
+ // URL to the category
+ Url string `json:"url,omitempty"`
+ // Facilitate to update the existing category in the same request (updateEnabled = true)
+ UpdateEnabled bool `json:"updateEnabled,omitempty"`
+}
diff --git a/lib/model_create_update_product.go b/lib/model_create_update_product.go
new file mode 100644
index 0000000..63fa4a7
--- /dev/null
+++ b/lib/model_create_update_product.go
@@ -0,0 +1,34 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateProduct struct {
+ // Product ID for which you requested the details
+ Id string `json:"id"`
+ // Mandatory in case of creation**. Name of the product for which you requested the details
+ Name string `json:"name"`
+ // URL to the product
+ Url string `json:"url,omitempty"`
+ // Absolute URL to the cover image of the product
+ ImageUrl string `json:"imageUrl,omitempty"`
+ // Product identifier from the shop
+ Sku string `json:"sku,omitempty"`
+ // Price of the product
+ Price float32 `json:"price,omitempty"`
+ // Category ID-s of the product
+ Categories []string `json:"categories,omitempty"`
+ // Parent product id of the product
+ ParentId string `json:"parentId,omitempty"`
+ // Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 10.
+ MetaInfo map[string]interface{} `json:"metaInfo,omitempty"`
+ // Facilitate to update the existing category in the same request (updateEnabled = true)
+ UpdateEnabled bool `json:"updateEnabled,omitempty"`
+}
diff --git a/lib/model_create_update_products.go b/lib/model_create_update_products.go
new file mode 100644
index 0000000..6044c18
--- /dev/null
+++ b/lib/model_create_update_products.go
@@ -0,0 +1,32 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreateUpdateProducts struct {
+ // Product ID for which you requested the details
+ Id string `json:"id"`
+ // Mandatory in case of creation**. Name of the product for which you requested the details
+ Name string `json:"name"`
+ // URL to the product
+ Url string `json:"url,omitempty"`
+ // Absolute URL to the cover image of the product
+ ImageUrl string `json:"imageUrl,omitempty"`
+ // Product identifier from the shop
+ Sku string `json:"sku,omitempty"`
+ // Price of the product
+ Price float32 `json:"price,omitempty"`
+ // Category ID-s of the product
+ Categories []string `json:"categories,omitempty"`
+ // Parent product id of the product
+ ParentId string `json:"parentId,omitempty"`
+ // Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 10.
+ MetaInfo map[string]interface{} `json:"metaInfo,omitempty"`
+}
diff --git a/lib/model_created_batch_id.go b/lib/model_created_batch_id.go
new file mode 100644
index 0000000..415b495
--- /dev/null
+++ b/lib/model_created_batch_id.go
@@ -0,0 +1,15 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type CreatedBatchId struct {
+ BatchId int64 `json:"batch_id"`
+}
diff --git a/lib/model_deal.go b/lib/model_deal.go
index c193e62..1ca346c 100644
--- a/lib/model_deal.go
+++ b/lib/model_deal.go
@@ -15,7 +15,7 @@ type Deal struct {
// Unique deal id
Id string `json:"id,omitempty"`
// Deal attributes with values
- Attributes map[string]interface{} `json:"attributes,omitempty"`
+ Attributes *interface{} `json:"attributes,omitempty"`
// Contact ids for contacts linked to this deal
LinkedContactsIds []int32 `json:"linkedContactsIds,omitempty"`
// Companies ids for companies linked to this deal
diff --git a/lib/model_file_data.go b/lib/model_file_data.go
new file mode 100644
index 0000000..be353fa
--- /dev/null
+++ b/lib/model_file_data.go
@@ -0,0 +1,33 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+import (
+ "time"
+)
+
+// File data that is uploaded
+type FileData struct {
+ // Name of uploaded file
+ Name string `json:"name,omitempty"`
+ // Account id of user which created the file
+ AuthorId string `json:"authorId,omitempty"`
+ // Contact id of contact on which file is uploaded
+ ContactId int64 `json:"contactId,omitempty"`
+ // Deal id linked to a file
+ DealId string `json:"dealId,omitempty"`
+ // Company id linked to a file
+ CompanyId string `json:"companyId,omitempty"`
+ // Size of file in bytes
+ Size int64 `json:"size,omitempty"`
+ // File created date/time
+ CreatedAt time.Time `json:"createdAt,omitempty"`
+}
diff --git a/lib/model_file_downloadable_link.go b/lib/model_file_downloadable_link.go
new file mode 100644
index 0000000..895aac6
--- /dev/null
+++ b/lib/model_file_downloadable_link.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type FileDownloadableLink struct {
+ // A unique link to download the requested file.
+ FileUrl string `json:"fileUrl"`
+}
diff --git a/lib/model_file_list.go b/lib/model_file_list.go
new file mode 100644
index 0000000..f47ac8c
--- /dev/null
+++ b/lib/model_file_list.go
@@ -0,0 +1,15 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+// List of files
+type FileList struct {
+}
diff --git a/lib/model_get_categories.go b/lib/model_get_categories.go
new file mode 100644
index 0000000..4821544
--- /dev/null
+++ b/lib/model_get_categories.go
@@ -0,0 +1,17 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type GetCategories struct {
+ Categories []interface{} `json:"categories"`
+ // Number of categories
+ Count int64 `json:"count"`
+}
diff --git a/lib/model_get_category_details.go b/lib/model_get_category_details.go
new file mode 100644
index 0000000..031e630
--- /dev/null
+++ b/lib/model_get_category_details.go
@@ -0,0 +1,24 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type GetCategoryDetails struct {
+ // Category ID for which you requested the details
+ Id string `json:"id"`
+ // Name of the category for which you requested the details
+ Name string `json:"name"`
+ // Creation UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ)
+ CreatedAt string `json:"createdAt"`
+ // Last modification UTC date-time of the category (YYYY-MM-DDTHH:mm:ss.SSSZ)
+ ModifiedAt string `json:"modifiedAt"`
+ // URL to the category
+ Url string `json:"url,omitempty"`
+}
diff --git a/lib/model_get_contact_details.go b/lib/model_get_contact_details.go
index 8cabebe..be36ee9 100644
--- a/lib/model_get_contact_details.go
+++ b/lib/model_get_contact_details.go
@@ -26,5 +26,5 @@ type GetContactDetails struct {
ListIds []int64 `json:"listIds"`
ListUnsubscribed []int64 `json:"listUnsubscribed,omitempty"`
// Set of attributes of the contact
- Attributes map[string]interface{} `json:"attributes"`
+ Attributes *interface{} `json:"attributes"`
}
diff --git a/lib/model_get_email_campaign.go b/lib/model_get_email_campaign.go
index 73213bc..0616419 100644
--- a/lib/model_get_email_campaign.go
+++ b/lib/model_get_email_campaign.go
@@ -67,7 +67,7 @@ type GetEmailCampaign struct {
// Sent UTC date-time of the campaign (YYYY-MM-DDTHH:mm:ss.SSSZ). Only available if 'status' of the campaign is 'sent'
SentDate string `json:"sentDate,omitempty"`
// Total number of non-delivered campaigns for a particular campaign id.
- ReturnBounce int64 `json:"returnBounce,omitempty"`
- Recipients map[string]interface{} `json:"recipients"`
- Statistics map[string]interface{} `json:"statistics"`
+ ReturnBounce int64 `json:"returnBounce,omitempty"`
+ Recipients *interface{} `json:"recipients"`
+ Statistics *interface{} `json:"statistics"`
}
diff --git a/lib/model_get_extended_campaign_stats.go b/lib/model_get_extended_campaign_stats.go
index 17557e3..7dce6e0 100644
--- a/lib/model_get_extended_campaign_stats.go
+++ b/lib/model_get_extended_campaign_stats.go
@@ -12,7 +12,7 @@ package lib
type GetExtendedCampaignStats struct {
// Overall statistics of the campaign
- GlobalStats map[string]interface{} `json:"globalStats"`
+ GlobalStats *interface{} `json:"globalStats"`
// List-wise statistics of the campaign.
CampaignStats []interface{} `json:"campaignStats"`
// Number of clicks on mirror link
@@ -20,8 +20,8 @@ type GetExtendedCampaignStats struct {
// Number of remaning emails to send
Remaining int64 `json:"remaining"`
// Statistics about the number of clicks for the links
- LinksStats map[string]interface{} `json:"linksStats"`
- StatsByDomain *GetStatsByDomain `json:"statsByDomain"`
+ LinksStats *interface{} `json:"linksStats"`
+ StatsByDomain *GetStatsByDomain `json:"statsByDomain"`
// Statistics about the campaign on the basis of various devices
StatsByDevice *GetStatsByDevice `json:"statsByDevice"`
// Statistics about the campaign on the basis of various browsers
diff --git a/lib/model_get_extended_contact_details.go b/lib/model_get_extended_contact_details.go
index 5cd6c4b..a8bd130 100644
--- a/lib/model_get_extended_contact_details.go
+++ b/lib/model_get_extended_contact_details.go
@@ -26,6 +26,6 @@ type GetExtendedContactDetails struct {
ListIds []int64 `json:"listIds"`
ListUnsubscribed []int64 `json:"listUnsubscribed,omitempty"`
// Set of attributes of the contact
- Attributes map[string]interface{} `json:"attributes"`
+ Attributes *interface{} `json:"attributes"`
Statistics *GetExtendedContactDetailsStatistics `json:"statistics"`
}
diff --git a/lib/model_get_product_details.go b/lib/model_get_product_details.go
new file mode 100644
index 0000000..0831b50
--- /dev/null
+++ b/lib/model_get_product_details.go
@@ -0,0 +1,40 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type GetProductDetails struct {
+ // Product ID for which you requested the details
+ Id string `json:"id"`
+ // Name of the product for which you requested the details
+ Name string `json:"name"`
+ // Creation UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ)
+ CreatedAt string `json:"createdAt"`
+ // Last modification UTC date-time of the product (YYYY-MM-DDTHH:mm:ss.SSSZ)
+ ModifiedAt string `json:"modifiedAt"`
+ // URL to the product
+ Url string `json:"url,omitempty"`
+ // Absolute URL to the cover image of the product
+ ImageUrl string `json:"imageUrl,omitempty"`
+ // Product identifier from the shop
+ Sku string `json:"sku,omitempty"`
+ // Price of the product
+ Price float32 `json:"price,omitempty"`
+ // Category ID-s of the product
+ Categories []string `json:"categories,omitempty"`
+ // Parent product id of the product
+ ParentId string `json:"parentId,omitempty"`
+ // S3 url of original image
+ S3Original string `json:"s3Original,omitempty"`
+ // S3 thumbnail url of original image in 120x120 dimension for analytics section
+ S3ThumbAnalytics string `json:"s3ThumbAnalytics"`
+ // S3 thumbnail url of original image in 600x400 dimension for editor section
+ S3ThumbEditor string `json:"s3ThumbEditor"`
+}
diff --git a/lib/model_get_products.go b/lib/model_get_products.go
new file mode 100644
index 0000000..0117076
--- /dev/null
+++ b/lib/model_get_products.go
@@ -0,0 +1,17 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type GetProducts struct {
+ Products []interface{} `json:"products"`
+ // Number of products
+ Count int64 `json:"count"`
+}
diff --git a/lib/model_get_sms_campaign.go b/lib/model_get_sms_campaign.go
index ccf67af..58787dd 100644
--- a/lib/model_get_sms_campaign.go
+++ b/lib/model_get_sms_campaign.go
@@ -26,7 +26,7 @@ type GetSmsCampaign struct {
// Creation UTC date-time of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
CreatedAt string `json:"createdAt"`
// UTC date-time of last modification of the SMS campaign (YYYY-MM-DDTHH:mm:ss.SSSZ)
- ModifiedAt string `json:"modifiedAt"`
- Recipients map[string]interface{} `json:"recipients"`
- Statistics map[string]interface{} `json:"statistics"`
+ ModifiedAt string `json:"modifiedAt"`
+ Recipients *interface{} `json:"recipients"`
+ Statistics *interface{} `json:"statistics"`
}
diff --git a/lib/model_get_webhook.go b/lib/model_get_webhook.go
index 4d27e3c..da114bd 100644
--- a/lib/model_get_webhook.go
+++ b/lib/model_get_webhook.go
@@ -18,7 +18,7 @@ type GetWebhook struct {
// Description of the webhook
Description string `json:"description"`
Events []string `json:"events"`
- // Type of webhook (marketing or transac)
+ // Type of webhook (marketing or transactional)
Type_ string `json:"type"`
// Creation UTC date-time of the webhook (YYYY-MM-DDTHH:mm:ss.SSSZ)
CreatedAt string `json:"createdAt"`
diff --git a/lib/model_note.go b/lib/model_note.go
index 650115b..4de2845 100644
--- a/lib/model_note.go
+++ b/lib/model_note.go
@@ -25,7 +25,7 @@ type Note struct {
// Deal ids linked to a note
DealIds []string `json:"dealIds,omitempty"`
// Account details of user which created the note
- AuthorId map[string]interface{} `json:"authorId,omitempty"`
+ AuthorId *interface{} `json:"authorId,omitempty"`
// Note created date/time
CreatedAt time.Time `json:"createdAt,omitempty"`
// Note updated date/time
diff --git a/lib/model_note_data.go b/lib/model_note_data.go
index 64bc4ef..cf06f27 100644
--- a/lib/model_note_data.go
+++ b/lib/model_note_data.go
@@ -18,4 +18,6 @@ type NoteData struct {
ContactIds []int32 `json:"contactIds,omitempty"`
// Deal Ids linked to a note
DealIds []string `json:"dealIds,omitempty"`
+ // Company Ids linked to a note
+ CompanyIds []string `json:"companyIds,omitempty"`
}
diff --git a/lib/model_order.go b/lib/model_order.go
new file mode 100644
index 0000000..1eedacd
--- /dev/null
+++ b/lib/model_order.go
@@ -0,0 +1,30 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type Order struct {
+ // Unique ID of the order.
+ Id string `json:"id"`
+ // Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created.
+ CreatedAt string `json:"createdAt"`
+ // Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated.
+ UpdatedAt string `json:"updatedAt"`
+ // State of the order.
+ Status string `json:"status"`
+ // Total amount of the order, including all shipping expenses, tax and the price of items.
+ Amount float32 `json:"amount"`
+ Products []OrderProducts `json:"products"`
+ // Email of the contact, Mandatory if \"phone\" field is not passed in \"billing\" parameter.
+ Email string `json:"email,omitempty"`
+ Billing *OrderBilling `json:"billing,omitempty"`
+ // Coupons applied to the order. Stored case insensitive.
+ Coupons []string `json:"coupons,omitempty"`
+}
diff --git a/lib/model_order_batch.go b/lib/model_order_batch.go
new file mode 100644
index 0000000..14aa22f
--- /dev/null
+++ b/lib/model_order_batch.go
@@ -0,0 +1,18 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type OrderBatch struct {
+ // array of order objects
+ Orders []Order `json:"orders"`
+ // Notify Url provided by client to get the status of batch request
+ NotifyUrl string `json:"notifyUrl,omitempty"`
+}
diff --git a/lib/model_order_billing.go b/lib/model_order_billing.go
new file mode 100644
index 0000000..964d964
--- /dev/null
+++ b/lib/model_order_billing.go
@@ -0,0 +1,29 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+// Billing details of an order.
+type OrderBilling struct {
+ // Full billing address.
+ Address string `json:"address,omitempty"`
+ // Exact city of the address.
+ City string `json:"city,omitempty"`
+ // Billing country 2-letter ISO code.
+ CountryCode string `json:"countryCode,omitempty"`
+ // Phone number to contact for further details about the order, Mandatory if \"email\" field is not passed.
+ Phone string `json:"phone,omitempty"`
+ // Postcode for delivery and billing.
+ PostCode string `json:"postCode,omitempty"`
+ // How the visitor will pay for the item(s), e.g. paypal, check, etc.
+ PaymentMethod string `json:"paymentMethod,omitempty"`
+ // Exact region (state/province) for delivery and billing.
+ Region string `json:"region,omitempty"`
+}
diff --git a/lib/model_order_products.go b/lib/model_order_products.go
new file mode 100644
index 0000000..4768a47
--- /dev/null
+++ b/lib/model_order_products.go
@@ -0,0 +1,23 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+// Details for the Products in an order.
+type OrderProducts struct {
+ // ID of the product.
+ ProductId string `json:"productId"`
+ // How many pieces of the product the visitor has added to the cart.
+ Quantity float32 `json:"quantity"`
+ // Product ID of the red color shirts.
+ VariantId string `json:"variantId,omitempty"`
+ // The price of a unit of product
+ Price float32 `json:"price"`
+}
diff --git a/lib/model_send_smtp_email.go b/lib/model_send_smtp_email.go
index 2289916..7480e51 100644
--- a/lib/model_send_smtp_email.go
+++ b/lib/model_send_smtp_email.go
@@ -10,10 +10,6 @@
package lib
-import (
- "time"
-)
-
type SendSmtpEmail struct {
Sender *SendSmtpEmailSender `json:"sender,omitempty"`
// Mandatory if messageVersions are not passed, ignored if messageVersions are passed. List of email addresses and names (optional) of the recipients. For example, [{\"name\":\"Jimmy\", \"email\":\"jimmy98@example.com\"}, {\"name\":\"Joe\", \"email\":\"joe@example.com\"}]
@@ -42,7 +38,7 @@ type SendSmtpEmail struct {
// Tag your emails to find them more easily
Tags []string `json:"tags,omitempty"`
// UTC date-time on which the email has to schedule (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for scheduling. There can be an expected delay of +5 minutes in scheduled email delivery. **Please note this feature is currently a public beta**.
- ScheduledAt time.Time `json:"scheduledAt,omitempty"`
+ ScheduledAt string `json:"scheduledAt,omitempty"`
// Valid UUIDv4 batch id to identify the scheduled batches transactional email. If not passed we will create a valid UUIDv4 batch id at our end.
BatchId string `json:"batchId,omitempty"`
}
diff --git a/lib/model_send_transac_sms.go b/lib/model_send_transac_sms.go
index 67e8d58..c993af3 100644
--- a/lib/model_send_transac_sms.go
+++ b/lib/model_send_transac_sms.go
@@ -25,4 +25,6 @@ type SendTransacSms struct {
WebUrl string `json:"webUrl,omitempty"`
// Format of the message. It indicates whether the content should be treated as unicode or not.
UnicodeEnabled bool `json:"unicodeEnabled,omitempty"`
+ // A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.**
+ OrganisationPrefix string `json:"organisationPrefix,omitempty"`
}
diff --git a/lib/model_update_contact.go b/lib/model_update_contact.go
index 3c4df30..847e8b0 100644
--- a/lib/model_update_contact.go
+++ b/lib/model_update_contact.go
@@ -14,7 +14,7 @@ type UpdateContact struct {
// Pass the set of attributes to be updated. These attributes must be present in your account. To update existing email address of a contact with the new one please pass EMAIL in attributes. For example, `{ \"EMAIL\":\"newemail@domain.com\", \"FNAME\":\"Ellie\", \"LNAME\":\"Roger\"}`. The attribute's parameter should be passed in capital letter while updating a contact. Keep in mind transactional attributes can be updated the same way as normal attributes. Mobile Number in \"SMS\" field should be passed with proper country code. For example {\"SMS\":\"+91xxxxxxxxxx\"} or {\"SMS\":\"0091xxxxxxxxxx\"}
Attributes map[string]interface{} `json:"attributes,omitempty"`
// Set/unset this field to blacklist/allow the contact for emails (emailBlacklisted = true)
- EmailBlacklisted bool `json:"emailBlacklisted,omitempty"`
+ EmailBlacklisted *bool `json:"emailBlacklisted,omitempty"`
// Set/unset this field to blacklist/allow the contact for SMS (smsBlacklisted = true)
SmsBlacklisted bool `json:"smsBlacklisted,omitempty"`
// Ids of the lists to add the contact to
diff --git a/lib/model_update_email_campaign.go b/lib/model_update_email_campaign.go
index 5ebe796..a1f01f8 100644
--- a/lib/model_update_email_campaign.go
+++ b/lib/model_update_email_campaign.go
@@ -44,7 +44,7 @@ type UpdateEmailCampaign struct {
// Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed
UtmCampaign string `json:"utmCampaign,omitempty"`
// Pass the set of attributes to customize the type 'classic' campaign. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. The 'params' field will get updated, only if the campaign is in New Template Language, else ignored. The New Template Language is dependent on the values of 'subject', 'htmlContent/htmlUrl', 'sender.name' & 'toField'
- Params map[string]interface{} `json:"params,omitempty"`
+ Params *interface{} `json:"params,omitempty"`
// Set this to true if you want to send your campaign at best time. Note:- if true, warmup ip will be disabled.
SendAtBestTime bool `json:"sendAtBestTime,omitempty"`
// Status of A/B Test. abTesting = false means it is disabled, & abTesting = true means it is enabled. 'subjectA', 'subjectB', 'splitRule', 'winnerCriteria' & 'winnerDelay' will be considered if abTesting is set to true. 'subject' if passed is ignored. Can be set to true only if 'sendAtBestTime' is 'false'. You will be able to set up two subject lines for your campaign and send them to a random sample of your total recipients. Half of the test group will receive version A, and the other half will receive version B
@@ -65,4 +65,8 @@ type UpdateEmailCampaign struct {
InitialQuota int64 `json:"initialQuota,omitempty"`
// Set a percentage increase rate for warming up your ip. We recommend you set the increase rate to 30% per day. If you want to send the same number of emails every day, set the daily increase value to 0%.
IncreaseRate int64 `json:"increaseRate,omitempty"`
+ // Enter an unsubscription page id. The page id is a 24 digit alphanumeric id that can be found in the URL when editing the page.
+ UnsubscriptionPageId string `json:"unsubscriptionPageId,omitempty"`
+ // Mandatory if templateId is used containing the {{ update_profile }} tag. Enter an update profile form id. The form id is a 24 digit alphanumeric id that can be found in the URL when editing the form.
+ UpdateFormId string `json:"updateFormId,omitempty"`
}
diff --git a/lib/model_update_email_campaign_recipients.go b/lib/model_update_email_campaign_recipients.go
index 25170f4..4fb50c3 100644
--- a/lib/model_update_email_campaign_recipients.go
+++ b/lib/model_update_email_campaign_recipients.go
@@ -10,10 +10,12 @@
package lib
-// List ids to include/exclude from campaign
+// Segment ids and List ids to include/exclude from campaign
type UpdateEmailCampaignRecipients struct {
// List ids which have to be excluded from a campaign
ExclusionListIds []int64 `json:"exclusionListIds,omitempty"`
- // Lists Ids to send the campaign to. REQUIRED if already not present in campaign and scheduledAt is not empty
+ // Lists Ids to send the campaign to. Campaign should only be updated with listIds if listIds were used to create it. REQUIRED if already not present in campaign and scheduledAt is not empty
ListIds []int64 `json:"listIds,omitempty"`
+ // Mandatory if listIds are not used. Campaign should only be updated with segmentIds if segmentIds were used to create it. Segment ids to send the campaign to.
+ SegmentIds []int64 `json:"segmentIds,omitempty"`
}
diff --git a/lib/model_update_sms_campaign.go b/lib/model_update_sms_campaign.go
index d939613..6cb4bbf 100644
--- a/lib/model_update_sms_campaign.go
+++ b/lib/model_update_sms_campaign.go
@@ -22,4 +22,8 @@ type UpdateSmsCampaign struct {
ScheduledAt string `json:"scheduledAt,omitempty"`
// Format of the message. It indicates whether the content should be treated as unicode or not.
UnicodeEnabled bool `json:"unicodeEnabled,omitempty"`
+ // A recognizable prefix will ensure your audience knows who you are. Recommended by U.S. carriers. This will be added as your Brand Name before the message content. **Prefer verifying maximum length of 160 characters including this prefix in message content to avoid multiple sending of same sms.**
+ OrganisationPrefix string `json:"organisationPrefix,omitempty"`
+ // Instructions to unsubscribe from future communications. Recommended by U.S. carriers. Must include **STOP** keyword. This will be added as instructions after the end of message content. **Prefer verifying maximum length of 160 characters including this instructions in message content to avoid multiple sending of same sms.**
+ UnsubscribeInstruction string `json:"unsubscribeInstruction,omitempty"`
}
diff --git a/lib/model_upload_image_model.go b/lib/model_upload_image_model.go
new file mode 100644
index 0000000..4764949
--- /dev/null
+++ b/lib/model_upload_image_model.go
@@ -0,0 +1,16 @@
+/*
+ * 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 | | 406 | Error. Not Acceptable |
+ *
+ * API version: 3.0.0
+ * Contact: contact@sendinblue.com
+ * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
+ */
+
+package lib
+
+type UploadImageModel struct {
+ // URL of the image uploaded
+ Url string `json:"url"`
+}