Categorygithub.com/IsaacHook/APIv3-go-library
module
2.0.2+incompatible
Repository: https://github.com/isaachook/apiv3-go-library.git
Documentation: pkg.go.dev

# README

SendinBlue's API v3 Go Library

SendinBlue's API exposes the entire SendinBlue features via a standardized programmatic interface. Please refer to the full documentation to learn more.

This is the wrapper for the API. It implements all the features of the API v3.

SendinBlue's API matches the OpenAPI v2 definition. The specification can be downloaded here.

This Golang package is automatically generated by the Swagger Codegen project and is reviewed and maintained by SendinBlue:

Installation & Usage

Install the package to your GoLang project.

go get github.com/sendinblue/APIv3-go-library

Getting Started

Please follow the installation procedure and then run the following:

package main
import (
	"fmt"
	"context"
    sendinblue "github.com/sendinblue/APIv3-go-library/lib"
)

func main() {
	var ctx context.Context
	cfg := sendinblue.NewConfiguration()
	//Configure API key authorization: api-key
	cfg.AddDefaultHeader("api-key", "YOUR_API_KEY")
	//Configure API key authorization: partner-key
	cfg.AddDefaultHeader("partner-key","YOUR_API_KEY")

	sib := sendinblue.NewAPIClient(cfg)
	result, resp, err := sib.AccountApi.GetAccount(ctx)
	if err != nil {
		fmt.Println("Error when calling AccountApi->get_account: ",err.Error())
		return
	}
	fmt.Println("GetAccount Object:",result," GetAccount Response: ",resp)
	return 
}

Documentation for API Endpoints

All URIs are relative to https://api.sendinblue.com/v3

ClassMethodHTTP requestDescription
AccountApiGetAccountGet /accountGet your account information, plan and credits details
AttributesApiCreateAttributePost /contacts/attributes/{attributeCategory}/{attributeName}Create contact attribute
AttributesApiDeleteAttributeDelete /contacts/attributes/{attributeCategory}/{attributeName}Delete an attribute
AttributesApiGetAttributesGet /contacts/attributesList all attributes
AttributesApiUpdateAttributePut /contacts/attributes/{attributeCategory}/{attributeName}Update contact attribute
ContactsApiAddContactToListPost /contacts/lists/{listId}/contacts/addAdd existing contacts to a list
ContactsApiCreateAttributePost /contacts/attributes/{attributeCategory}/{attributeName}Create contact attribute
ContactsApiCreateContactPost /contactsCreate a contact
ContactsApiCreateDoiContactPost /contacts/doubleOptinConfirmationCreate Contact via DOI (Double-Opt-In) Flow
ContactsApiCreateFolderPost /contacts/foldersCreate a folder
ContactsApiCreateListPost /contacts/listsCreate a list
ContactsApiDeleteAttributeDelete /contacts/attributes/{attributeCategory}/{attributeName}Delete an attribute
ContactsApiDeleteContactDelete /contacts/{identifier}Delete a contact
ContactsApiDeleteFolderDelete /contacts/folders/{folderId}Delete a folder (and all its lists)
ContactsApiDeleteListDelete /contacts/lists/{listId}Delete a list
ContactsApiGetAttributesGet /contacts/attributesList all attributes
ContactsApiGetContactInfoGet /contacts/{identifier}Get a contact's details
ContactsApiGetContactStatsGet /contacts/{identifier}/campaignStatsGet email campaigns' statistics for a contact
ContactsApiGetContactsGet /contactsGet all the contacts
ContactsApiGetContactsFromListGet /contacts/lists/{listId}/contactsGet contacts in a list
ContactsApiGetFolderGet /contacts/folders/{folderId}Returns a folder's details
ContactsApiGetFolderListsGet /contacts/folders/{folderId}/listsGet lists in a folder
ContactsApiGetFoldersGet /contacts/foldersGet all folders
ContactsApiGetListGet /contacts/lists/{listId}Get a list's details
ContactsApiGetListsGet /contacts/listsGet all the lists
ContactsApiImportContactsPost /contacts/importImport contacts
ContactsApiRemoveContactFromListPost /contacts/lists/{listId}/contacts/removeDelete a contact from a list
ContactsApiRequestContactExportPost /contacts/exportExport contacts
ContactsApiUpdateAttributePut /contacts/attributes/{attributeCategory}/{attributeName}Update contact attribute
ContactsApiUpdateContactPut /contacts/{identifier}Update a contact
ContactsApiUpdateFolderPut /contacts/folders/{folderId}Update a folder
ContactsApiUpdateListPut /contacts/lists/{listId}Update a list
EmailCampaignsApiCreateEmailCampaignPost /emailCampaignsCreate an email campaign
EmailCampaignsApiDeleteEmailCampaignDelete /emailCampaigns/{campaignId}Delete an email campaign
EmailCampaignsApiEmailExportRecipientsPost /emailCampaigns/{campaignId}/exportRecipientsExport the recipients of an email campaign
EmailCampaignsApiGetAbTestCampaignResultGet /emailCampaigns/{campaignId}/abTestCampaignResultGet an A/B test email campaign results
EmailCampaignsApiGetEmailCampaignGet /emailCampaigns/{campaignId}Get an email campaign report
EmailCampaignsApiGetEmailCampaignsGet /emailCampaignsReturn all your created email campaigns
EmailCampaignsApiGetSharedTemplateUrlGet /emailCampaigns/{campaignId}/sharedUrlGet a shared template url
EmailCampaignsApiSendEmailCampaignNowPost /emailCampaigns/{campaignId}/sendNowSend an email campaign immediately, based on campaignId
EmailCampaignsApiSendReportPost /emailCampaigns/{campaignId}/sendReportSend the report of a campaign
EmailCampaignsApiSendTestEmailPost /emailCampaigns/{campaignId}/sendTestSend an email campaign to your test list
EmailCampaignsApiUpdateCampaignStatusPut /emailCampaigns/{campaignId}/statusUpdate an email campaign status
EmailCampaignsApiUpdateEmailCampaignPut /emailCampaigns/{campaignId}Update an email campaign
EmailCampaignsApiUploadImageToGalleryPost /emailCampaigns/imagesUpload an image to your account's image gallery
FoldersApiCreateFolderPost /contacts/foldersCreate a folder
FoldersApiDeleteFolderDelete /contacts/folders/{folderId}Delete a folder (and all its lists)
FoldersApiGetFolderGet /contacts/folders/{folderId}Returns a folder's details
FoldersApiGetFolderListsGet /contacts/folders/{folderId}/listsGet lists in a folder
FoldersApiGetFoldersGet /contacts/foldersGet all folders
FoldersApiUpdateFolderPut /contacts/folders/{folderId}Update a folder
ListsApiAddContactToListPost /contacts/lists/{listId}/contacts/addAdd existing contacts to a list
ListsApiCreateListPost /contacts/listsCreate a list
ListsApiDeleteListDelete /contacts/lists/{listId}Delete a list
ListsApiGetContactsFromListGet /contacts/lists/{listId}/contactsGet contacts in a list
ListsApiGetFolderListsGet /contacts/folders/{folderId}/listsGet lists in a folder
ListsApiGetListGet /contacts/lists/{listId}Get a list's details
ListsApiGetListsGet /contacts/listsGet all the lists
ListsApiRemoveContactFromListPost /contacts/lists/{listId}/contacts/removeDelete a contact from a list
ListsApiUpdateListPut /contacts/lists/{listId}Update a list
ProcessApiGetProcessGet /processes/{processId}Return the informations for a process
ProcessApiGetProcessesGet /processesReturn all the processes for your account
ResellerApiAddCreditsPost /reseller/children/{childIdentifier}/credits/addAdd Email and/or SMS credits to a specific child account
ResellerApiAssociateIpToChildPost /reseller/children/{childIdentifier}/ips/associateAssociate a dedicated IP to the child
ResellerApiCreateChildDomainPost /reseller/children/{childIdentifier}/domainsCreate a domain for a child account
ResellerApiCreateResellerChildPost /reseller/childrenCreates a reseller child
ResellerApiDeleteChildDomainDelete /reseller/children/{childIdentifier}/domains/{domainName}Delete the sender domain of the reseller child based on the childIdentifier and domainName passed
ResellerApiDeleteResellerChildDelete /reseller/children/{childIdentifier}Delete a single reseller child based on the child identifier supplied
ResellerApiDissociateIpFromChildPost /reseller/children/{childIdentifier}/ips/dissociateDissociate a dedicated IP to the child
ResellerApiGetChildAccountCreationStatusGet /reseller/children/{childIdentifier}/accountCreationStatusGet the status of a reseller's child account creation, whether it is successfully created (exists) or not based on the identifier supplied
ResellerApiGetChildDomainsGet /reseller/children/{childIdentifier}/domainsGet all sender domains for a specific child account
ResellerApiGetChildInfoGet /reseller/children/{childIdentifier}Get a child account's details
ResellerApiGetResellerChildsGet /reseller/childrenGet the list of all children accounts
ResellerApiGetSsoTokenGet /reseller/children/{childIdentifier}/authGet session token to access Sendinblue (SSO)
ResellerApiRemoveCreditsPost /reseller/children/{childIdentifier}/credits/removeRemove Email and/or SMS credits from a specific child account
ResellerApiUpdateChildAccountStatusPut /reseller/children/{childIdentifier}/accountStatusUpdate info of reseller's child account status based on the childIdentifier supplied
ResellerApiUpdateChildDomainPut /reseller/children/{childIdentifier}/domains/{domainName}Update the sender domain of reseller's child based on the childIdentifier and domainName passed
ResellerApiUpdateResellerChildPut /reseller/children/{childIdentifier}Update info of reseller's child based on the child identifier supplied
SMSCampaignsApiCreateSmsCampaignPost /smsCampaignsCreates an SMS campaign
SMSCampaignsApiDeleteSmsCampaignDelete /smsCampaigns/{campaignId}Delete an SMS campaign
SMSCampaignsApiGetSmsCampaignGet /smsCampaigns/{campaignId}Get an SMS campaign
SMSCampaignsApiGetSmsCampaignsGet /smsCampaignsReturns the information for all your created SMS campaigns
SMSCampaignsApiRequestSmsRecipientExportPost /smsCampaigns/{campaignId}/exportRecipientsExport an SMS campaign's recipients
SMSCampaignsApiSendSmsCampaignNowPost /smsCampaigns/{campaignId}/sendNowSend your SMS campaign immediately
SMSCampaignsApiSendSmsReportPost /smsCampaigns/{campaignId}/sendReportSend an SMS campaign's report
SMSCampaignsApiSendTestSmsPost /smsCampaigns/{campaignId}/sendTestSend a test SMS campaign
SMSCampaignsApiUpdateSmsCampaignPut /smsCampaigns/{campaignId}Update an SMS campaign
SMSCampaignsApiUpdateSmsCampaignStatusPut /smsCampaigns/{campaignId}/statusUpdate a campaign's status
SendersApiCreateSenderPost /sendersCreate a new sender
SendersApiDeleteSenderDelete /senders/{senderId}Delete a sender
SendersApiGetIpsGet /senders/ipsGet all the dedicated IPs for your account
SendersApiGetIpsFromSenderGet /senders/{senderId}/ipsGet all the dedicated IPs for a sender
SendersApiGetSendersGet /sendersGet the list of all your senders
SendersApiUpdateSenderPut /senders/{senderId}Update a sender
TransactionalEmailsApiBlockNewDomainPost /smtp/blockedDomainsAdd a new domain to the list of blocked domains
TransactionalEmailsApiCreateSmtpTemplatePost /smtp/templatesCreate an email template
TransactionalEmailsApiDeleteBlockedDomainDelete /smtp/blockedDomains/{domain}Unblock an existing domain from the list of blocked domains
TransactionalEmailsApiDeleteHardbouncesPost /smtp/deleteHardbouncesDelete hardbounces
TransactionalEmailsApiDeleteSmtpTemplateDelete /smtp/templates/{templateId}Delete an inactive email template
TransactionalEmailsApiGetAggregatedSmtpReportGet /smtp/statistics/aggregatedReportGet your transactional email activity aggregated over a period of time
TransactionalEmailsApiGetBlockedDomainsGet /smtp/blockedDomainsGet the list of blocked domains
TransactionalEmailsApiGetEmailEventReportGet /smtp/statistics/eventsGet all your transactional email activity (unaggregated events)
TransactionalEmailsApiGetSmtpReportGet /smtp/statistics/reportsGet your transactional email activity aggregated per day
TransactionalEmailsApiGetSmtpTemplateGet /smtp/templates/{templateId}Returns the template information
TransactionalEmailsApiGetSmtpTemplatesGet /smtp/templatesGet the list of email templates
TransactionalEmailsApiGetTransacBlockedContactsGet /smtp/blockedContactsGet the list of blocked or unsubscribed transactional contacts
TransactionalEmailsApiGetTransacEmailContentGet /smtp/emails/{uuid}Get the personalized content of a sent transactional email
TransactionalEmailsApiGetTransacEmailsListGet /smtp/emailsGet the list of transactional emails on the basis of allowed filters
TransactionalEmailsApiSendTemplatePost /smtp/templates/{templateId}/sendSend a template
TransactionalEmailsApiSendTestTemplatePost /smtp/templates/{templateId}/sendTestSend a template to your test list
TransactionalEmailsApiSendTransacEmailPost /smtp/emailSend a transactional email
TransactionalEmailsApiSmtpBlockedContactsEmailDeleteDelete /smtp/blockedContacts/{email}Unblock or resubscribe a transactional contact
TransactionalEmailsApiSmtpLogMessageIdDeleteDelete /smtp/log/{messageId}Delete an SMTP transactional log
TransactionalEmailsApiUpdateSmtpTemplatePut /smtp/templates/{templateId}Update an email template
TransactionalSMSApiGetSmsEventsGet /transactionalSMS/statistics/eventsGet all your SMS activity (unaggregated events)
TransactionalSMSApiGetTransacAggregatedSmsReportGet /transactionalSMS/statistics/aggregatedReportGet your SMS activity aggregated over a period of time
TransactionalSMSApiGetTransacSmsReportGet /transactionalSMS/statistics/reportsGet your SMS activity aggregated per day
TransactionalSMSApiSendTransacSmsPost /transactionalSMS/smsSend SMS message to a mobile number
WebhooksApiCreateWebhookPost /webhooksCreate a webhook
WebhooksApiDeleteWebhookDelete /webhooks/{webhookId}Delete a webhook
WebhooksApiGetWebhookGet /webhooks/{webhookId}Get a webhook details
WebhooksApiGetWebhooksGet /webhooksGet all webhooks
WebhooksApiUpdateWebhookPut /webhooks/{webhookId}Update a webhook

Documentation For Models

Documentation For Authorization

api-key

  • Type: API key
  • API key parameter name: api-key
  • Location: HTTP header

partner-key

  • Type: API key
  • API key parameter name: partner-key
  • Location: HTTP header

Support and Feedback

Be sure to visit the SendinBlue official documentation website for additional information about our API.

If you find a bug, please post the issue on Github.

As always, if you need additional assistance, drop us a note here.

Author

[email protected]

# Packages

* SendinBlue API * * SendinBlue provide a RESTFul API that can be used with any languages.