Skip to content

Latest commit

 

History

History
120 lines (87 loc) · 4.23 KB

UserApi.md

File metadata and controls

120 lines (87 loc) · 4.23 KB

Brevo\Client\UserApi

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

Method HTTP request Description
getInvitedUsersList GET /organization/invited/users Get the list of all your users
getUserPermission GET /organization/user/{email}/permissions Check user permission

getInvitedUsersList

\Brevo\Client\Model\GetInvitedUsersList getInvitedUsersList()

Get the list of all your users

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: api-key
$config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKey('api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('api-key', 'Bearer');
// Configure API key authorization: partner-key
$config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKey('partner-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('partner-key', 'Bearer');

$apiInstance = new Brevo\Client\Api\UserApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);

try {
    $result = $apiInstance->getInvitedUsersList();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->getInvitedUsersList: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

This endpoint does not need any parameter.

Return type

\Brevo\Client\Model\GetInvitedUsersList

Authorization

api-key, partner-key

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getUserPermission

\Brevo\Client\Model\GetUserPermission getUserPermission($email)

Check user permission

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: api-key
$config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKey('api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('api-key', 'Bearer');
// Configure API key authorization: partner-key
$config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKey('partner-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Brevo\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('partner-key', 'Bearer');

$apiInstance = new Brevo\Client\Api\UserApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$email = "email_example"; // string | Email of the invited user.

try {
    $result = $apiInstance->getUserPermission($email);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->getUserPermission: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
email string Email of the invited user.

Return type

\Brevo\Client\Model\GetUserPermission

Authorization

api-key, partner-key

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]