| @@ 582-590 (lines=9) @@ | ||
| 579 | * @param int $product_id [Mandatory - Product ID] |
|
| 580 | * @return object |
|
| 581 | */ |
|
| 582 | public function getProduct($product_id){ |
|
| 583 | if(!$product_id){ |
|
| 584 | throw new IsNullOrInvalid("Error Processing Request - Null/Invalid product_id"); |
|
| 585 | } |
|
| 586 | ||
| 587 | $url = "/products/{$product_id}"; |
|
| 588 | ||
| 589 | return $this->sendRequest('get', $url); |
|
| 590 | } |
|
| 591 | ||
| 592 | ||
| 593 | ||
| @@ 651-659 (lines=9) @@ | ||
| 648 | * @param $product_id [Mandatory - Product ID] |
|
| 649 | * @return object |
|
| 650 | */ |
|
| 651 | public function deleteProduct($product_id){ |
|
| 652 | if(!$product_id){ |
|
| 653 | throw new IsNullOrInvalid("Error Processing Request - Null/Invalid Product Id"); |
|
| 654 | } |
|
| 655 | ||
| 656 | $url = "/products/{$product_id}"; |
|
| 657 | ||
| 658 | return $this->sendRequest('delete', $url); |
|
| 659 | } |
|
| 660 | ||
| 661 | ||
| 662 | ||