All URIs are relative to https://api.brevo.com/v3
Method | HTTP request | Description |
---|---|---|
get_account | GET /account | Get your account information, plan and credits details |
get_account_activity | GET /organization/activities | Get user activity logs |
GetAccount get_account
Get your account information, plan and credits details
# load the gem
require 'brevo'
# setup authorization
Brevo.configure do |config|
# Configure API key authorization: api-key
config.api_key['api-key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['api-key'] = 'Bearer'
# Configure API key authorization: partner-key
config.api_key['partner-key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['partner-key'] = 'Bearer'
end
api_instance = Brevo::AccountApi.new
begin
#Get your account information, plan and credits details
result = api_instance.get_account
p result
rescue Brevo::ApiError => e
puts "Exception when calling AccountApi->get_account: #{e}"
end
This endpoint does not need any parameter.
- Content-Type: application/json
- Accept: application/json
GetAccountActivity get_account_activity(opts)
Get user activity logs
# load the gem
require 'brevo'
# setup authorization
Brevo.configure do |config|
# Configure API key authorization: api-key
config.api_key['api-key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['api-key'] = 'Bearer'
# Configure API key authorization: partner-key
config.api_key['partner-key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['partner-key'] = 'Bearer'
end
api_instance = Brevo::AccountApi.new
opts = {
start_date: 'start_date_example', # String | Mandatory if endDate is used. Enter start date in UTC date (YYYY-MM-DD) format to filter the activity in your account. Maximum time period that can be selected is one month. Additionally, you can retrieve activity logs from the past 12 months from the date of your search.
end_date: 'end_date_example', # String | Mandatory if startDate is used. Enter end date in UTC date (YYYY-MM-DD) format to filter the activity in your account. Maximum time period that can be selected is one month.
limit: 10, # Integer | Number of documents per page
offset: 0 # Integer | Index of the first document in the page.
}
begin
#Get user activity logs
result = api_instance.get_account_activity(opts)
p result
rescue Brevo::ApiError => e
puts "Exception when calling AccountApi->get_account_activity: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
start_date | String | Mandatory if endDate is used. Enter start date in UTC date (YYYY-MM-DD) format to filter the activity in your account. Maximum time period that can be selected is one month. Additionally, you can retrieve activity logs from the past 12 months from the date of your search. | [optional] |
end_date | String | Mandatory if startDate is used. Enter end date in UTC date (YYYY-MM-DD) format to filter the activity in your account. Maximum time period that can be selected is one month. | [optional] |
limit | Integer | Number of documents per page | [optional] [default to 10] |
offset | Integer | Index of the first document in the page. | [optional] [default to 0] |
- Content-Type: application/json
- Accept: application/json