1 | <?php |
||
15 | class User extends Api |
||
16 | { |
||
17 | /** |
||
18 | * User details |
||
19 | */ |
||
20 | public function user() |
||
24 | |||
25 | /** |
||
26 | * Update user |
||
27 | * Update part of your user details |
||
28 | * |
||
29 | * @param string|null $first_name User's first name |
||
30 | * @param string|null $last_name User's last name |
||
31 | * @param string|null $telephone User's telephone number |
||
32 | * @param string|null $country The country in which the user lives. (Full list is here: http://en.wikipedia.org/wiki/List_of_country_calling_codes) |
||
33 | * @param string|null $zipcode The zipcode or postal code where the user lives. |
||
34 | */ |
||
35 | public function update($first_name = null, $last_name = null, $telephone = null, $country = null, $zipcode = null) |
||
47 | |||
48 | /** |
||
49 | * Change your email address. Note: You must provide your current password. |
||
50 | * |
||
51 | * @param string $email Your contact email address |
||
52 | * @param string $confirm_email Your contact email address, repeated |
||
53 | * @param string $password Your current password |
||
54 | */ |
||
55 | public function change_email($email, $confirm_email, $password) |
||
65 | |||
66 | /** |
||
67 | * Change your password |
||
68 | * |
||
69 | * @param string $old_password Your current password |
||
70 | * @param string $new_password Your new password |
||
71 | * @param string $new_password_confirm Your new password, repeated |
||
72 | */ |
||
73 | public function change_password($old_password, $new_password, $new_password_confirm) |
||
83 | |||
84 | /** |
||
85 | * Change your username. Note: You must provide your current password. |
||
86 | * |
||
87 | * @param string $username A username used to access other cloudflare services, like support |
||
88 | * @param string $password Your current password |
||
89 | */ |
||
90 | public function change_username($username, $password) |
||
99 | |||
100 | /** |
||
101 | * Begin setting up CloudFlare two-factor authentication with a given telephone number |
||
102 | * |
||
103 | * @param int $country_code The country code of your mobile phone number |
||
104 | * @param string $mobile_phone_number Your mobile phone number |
||
105 | * @param string $current_password Your current CloudFlare password |
||
106 | */ |
||
107 | public function initialize_two_factor_authentication($country_code, $mobile_phone_number, $current_password) |
||
117 | |||
118 | /** |
||
119 | * Finish setting up CloudFlare two-factor authentication with a given telephone number |
||
120 | * |
||
121 | * @param int $auth_token The token provided by the two-factor authenticator |
||
122 | */ |
||
123 | public function finalize_two_factor_authentication($auth_token) |
||
131 | |||
132 | /** |
||
133 | * Disable two-factor authentication for your CloudFlare user account |
||
134 | * |
||
135 | * @param int The token provided by the two-factor authenticator |
||
136 | */ |
||
137 | public function disable_two_factor_authentication($auth_token) |
||
145 | } |
||
146 |