Overview

Namespaces

  • None
  • PHP

Classes

  • Mailchimp
  • Mailchimp_Campaigns
  • Mailchimp_Ecomm
  • Mailchimp_Folders
  • Mailchimp_Gallery
  • Mailchimp_Helper
  • Mailchimp_Lists
  • Mailchimp_Mobile
  • Mailchimp_Neapolitan
  • Mailchimp_Reports
  • Mailchimp_Templates
  • Mailchimp_Users
  • Mailchimp_Vip

Exceptions

  • Mailchimp_Absplit_UnknownError
  • Mailchimp_Absplit_UnknownSplitTest
  • Mailchimp_Absplit_UnknownTestType
  • Mailchimp_Absplit_UnknownWaitUnit
  • Mailchimp_Absplit_UnknownWinnerType
  • Mailchimp_Absplit_WinnerNotSelected
  • Mailchimp_Avesta_Db_Exception
  • Mailchimp_Campaign_BounceMissing
  • Mailchimp_Campaign_DoesNotExist
  • Mailchimp_Campaign_InvalidAbsplit
  • Mailchimp_Campaign_InvalidAuto
  • Mailchimp_Campaign_InvalidContent
  • Mailchimp_Campaign_InvalidOption
  • Mailchimp_Campaign_InvalidRss
  • Mailchimp_Campaign_InvalidSegment
  • Mailchimp_Campaign_InvalidStatus
  • Mailchimp_Campaign_InvalidTemplate
  • Mailchimp_Campaign_NotSaved
  • Mailchimp_Campaign_StatsNotAvailable
  • Mailchimp_Email_AlreadySubscribed
  • Mailchimp_Email_AlreadyUnsubscribed
  • Mailchimp_Email_NotExists
  • Mailchimp_Email_NotSubscribed
  • Mailchimp_Error
  • Mailchimp_HttpError
  • Mailchimp_Invalid_Analytics
  • Mailchimp_Invalid_ApiKey
  • Mailchimp_Invalid_AppKey
  • Mailchimp_Invalid_DateTime
  • Mailchimp_Invalid_EcommOrder
  • Mailchimp_Invalid_Email
  • Mailchimp_Invalid_Folder
  • Mailchimp_Invalid_IP
  • Mailchimp_Invalid_Options
  • Mailchimp_Invalid_PagingLimit
  • Mailchimp_Invalid_PagingStart
  • Mailchimp_Invalid_SendType
  • Mailchimp_Invalid_Template
  • Mailchimp_Invalid_TrackingOptions
  • Mailchimp_Invalid_URL
  • Mailchimp_List_AlreadySubscribed
  • Mailchimp_List_CannotRemoveEmailMerge
  • Mailchimp_List_DoesNotExist
  • Mailchimp_List_InvalidBounceMember
  • Mailchimp_List_InvalidImport
  • Mailchimp_List_InvalidInterestFieldType
  • Mailchimp_List_InvalidInterestGroup
  • Mailchimp_List_InvalidMergeField
  • Mailchimp_List_InvalidOption
  • Mailchimp_List_InvalidUnsubMember
  • Mailchimp_List_Merge_InvalidMergeID
  • Mailchimp_List_MergeFieldRequired
  • Mailchimp_List_NotSubscribed
  • Mailchimp_List_TooManyInterestGroups
  • Mailchimp_List_TooManyMergeFields
  • Mailchimp_Max_Size_Reached
  • Mailchimp_MC_ContentImport_InvalidArchive
  • Mailchimp_MC_InvalidPayment
  • Mailchimp_MC_PastedList_Duplicate
  • Mailchimp_MC_PastedList_InvalidImport
  • Mailchimp_MC_SearchException
  • Mailchimp_Module_Unknown
  • Mailchimp_MonthlyPlan_Unknown
  • Mailchimp_Order_TypeUnknown
  • Mailchimp_Parse_Exception
  • Mailchimp_PDOException
  • Mailchimp_Request_TimedOut
  • Mailchimp_ServerError_InvalidParameters
  • Mailchimp_ServerError_MethodUnknown
  • Mailchimp_Too_Many_Connections
  • Mailchimp_Unknown_Exception
  • Mailchimp_User_CannotSendCampaign
  • Mailchimp_User_Disabled
  • Mailchimp_User_DoesExist
  • Mailchimp_User_DoesNotExist
  • Mailchimp_User_InvalidAction
  • Mailchimp_User_InvalidRole
  • Mailchimp_User_MissingEmail
  • Mailchimp_User_MissingModuleOutbox
  • Mailchimp_User_ModuleAlreadyPurchased
  • Mailchimp_User_ModuleNotPurchased
  • Mailchimp_User_NotApproved
  • Mailchimp_User_NotEnoughCredit
  • Mailchimp_User_UnderMaintenance
  • Mailchimp_User_Unknown
  • Mailchimp_ValidationError
  • Mailchimp_XML_RPC2_Exception
  • Mailchimp_XML_RPC2_FaultException
  • Mailchimp_Zend_Uri_Exception
  • Overview
  • Namespace
  • Class
  • Tree
  1: <?php
  2: 
  3: class Mailchimp_Users {
  4:     public function __construct(Mailchimp $master) {
  5:         $this->master = $master;
  6:     }
  7: 
  8:     /**
  9:      * Invite a user to your account
 10:      * @param string $email
 11:      * @param string $role
 12:      * @param string $msg
 13:      * @return associative_array the method completion status
 14:      *     - status string The status (success) of the call if it completed. Otherwise an error is thrown.
 15:      */
 16:     public function invite($email, $role='viewer', $msg='') {
 17:         $_params = array("email" => $email, "role" => $role, "msg" => $msg);
 18:         return $this->master->call('users/invite', $_params);
 19:     }
 20: 
 21:     /**
 22:      * Resend an invite a user to your account. Note, if the same address has been invited multiple times, this will simpy re-send the most recent invite
 23:      * @param string $email
 24:      * @return associative_array the method completion status
 25:      *     - status string The status (success) of the call if it completed. Otherwise an error is thrown.
 26:      */
 27:     public function inviteResend($email) {
 28:         $_params = array("email" => $email);
 29:         return $this->master->call('users/invite-resend', $_params);
 30:     }
 31: 
 32:     /**
 33:      * Revoke an invitation sent to a user to your account. Note, if the same address has been invited multiple times, this will simpy revoke the most recent invite
 34:      * @param string $email
 35:      * @return associative_array the method completion status
 36:      *     - status string The status (success) of the call if it completed. Otherwise an error is thrown.
 37:      */
 38:     public function inviteRevoke($email) {
 39:         $_params = array("email" => $email);
 40:         return $this->master->call('users/invite-revoke', $_params);
 41:     }
 42: 
 43:     /**
 44:      * Retrieve the list of pending users invitations have been sent for.
 45:      * @return array structs for each invitation, including:
 46:      *     - email string the email address the invitation was sent to
 47:      *     - role string the role that will be assigned if they accept
 48:      *     - sent_at string the time the invitation was sent. this will change if it's resent.
 49:      *     - expiration string the expiration time for the invitation. this will change if it's resent.
 50:      *     - msg string the welcome message included with the invitation
 51:      */
 52:     public function invites() {
 53:         $_params = array();
 54:         return $this->master->call('users/invites', $_params);
 55:     }
 56: 
 57:     /**
 58:      * Revoke access for a specified login
 59:      * @param string $username
 60:      * @return associative_array the method completion status
 61:      *     - status string The status (success) of the call if it completed. Otherwise an error is thrown.
 62:      */
 63:     public function loginRevoke($username) {
 64:         $_params = array("username" => $username);
 65:         return $this->master->call('users/login-revoke', $_params);
 66:     }
 67: 
 68:     /**
 69:      * Retrieve the list of active logins.
 70:      * @return array structs for each user, including:
 71:      *     - id int the login id for this login
 72:      *     - username string the username used to log in
 73:      *     - name string a display name for the account - empty first/last names will return the username
 74:      *     - email string the email tied to the account used for passwords resets and the ilk
 75:      *     - role string the role assigned to the account
 76:      *     - avatar string if available, the url for the login's avatar
 77:      */
 78:     public function logins() {
 79:         $_params = array();
 80:         return $this->master->call('users/logins', $_params);
 81:     }
 82: 
 83:     /**
 84:      * Retrieve the profile for the login owning the provided API Key
 85:      * @return associative_array the current user's details, including:
 86:      *     - id int the login id for this login
 87:      *     - username string the username used to log in
 88:      *     - name string a display name for the account - empty first/last names will return the username
 89:      *     - email string the email tied to the account used for passwords resets and the ilk
 90:      *     - role string the role assigned to the account
 91:      *     - avatar string if available, the url for the login's avatar
 92:      */
 93:     public function profile() {
 94:         $_params = array();
 95:         return $this->master->call('users/profile', $_params);
 96:     }
 97: 
 98: }
 99: 
100: 
101: 
API documentation generated by ApiGen 2.8.0