1 | <?php |
||
21 | class AccountApi extends BaseLinodeApi |
||
22 | { |
||
23 | /** |
||
24 | * Estimates the invoice for adding a new Linode or NodeBalancer as well as resizing a Linode. This |
||
25 | * returns two fields: PRICE which is the estimated cost of the invoice, and INVOICE_TO which is the |
||
26 | * date invoice would be though with timezone set to America/New_York. |
||
27 | * |
||
28 | * @param string $mode [required] This is one of the following options: 'linode_new', 'linode_resize', or 'nodebalancer_new'. |
||
29 | * @param int $LinodeID [optional] This is the LinodeID you want to resize and is required for mode 'linode_resize'. |
||
30 | * @param int $PlanID [optional] The desired PlanID available from avail.LinodePlans(). This is required for modes 'linode_new' and 'linode_resize'. |
||
31 | * @param int $PaymentTerm [optional] Subscription term in months. One of: 1, 12, or 24. This is required for modes 'linode_new' and 'nodebalancer_new'. |
||
32 | * |
||
33 | * @return array |
||
34 | */ |
||
35 | 1 | public function estimateInvoice($mode, $LinodeID = null, $PlanID = null, $PaymentTerm = null) |
|
36 | { |
||
37 | 1 | return $this->call('account.estimateinvoice', [ |
|
38 | 1 | 'mode' => $mode, |
|
39 | 1 | 'LinodeID' => $LinodeID, |
|
40 | 1 | 'PlanID' => $PlanID, |
|
41 | 1 | 'PaymentTerm' => $PaymentTerm, |
|
42 | 1 | ]); |
|
43 | } |
||
44 | |||
45 | /** |
||
46 | * Shows information about your account such as the date your account was opened as well as your |
||
47 | * network utilization for the current month in gigabytes. |
||
48 | * |
||
49 | * @return array |
||
50 | */ |
||
51 | 1 | public function info() |
|
55 | |||
56 | /** |
||
57 | * Pays current balance on file, returning it in the response. |
||
58 | * |
||
59 | * @return array |
||
60 | */ |
||
61 | 1 | public function payBalance() |
|
65 | |||
66 | /** |
||
67 | * @param int $ccNumber [required] |
||
68 | * @param int $ccExpMonth [required] |
||
69 | * @param int $ccExpYear [required] |
||
70 | * |
||
71 | * @return array |
||
72 | */ |
||
73 | 1 | public function updateCard($ccNumber, $ccExpMonth, $ccExpYear) |
|
81 | } |
||
82 |