abishekrsrikaanth / shirts.io-php-sdk
PHP SDK to integrate with Shirts.io API
1.0
2014-05-19 22:14 UTC
Requires
- php: >=5.3.0
- guzzle/guzzle: 3.8.*@dev
This package is auto-updated.
Last update: 2024-12-14 06:30:04 UTC
README
- Installation
- Setup
- Products
- Quote
- Order
- Status
require: {
....
"abishekrsrikaanth/shirts.io-php-sdk": "1.0"
....
}
##Setup
include("vendor/autoload.php");
use ShirtsIO\ShirtsIO;
$apiKey = "API KEY PROVIDED BY SHIRTS IO"
ShirtsIO::setAPIKey($apiKey);
##Products
###Get Categories ``` $productObj = ShirtsIO::Products(); $categories = $productObj->getCategories(); //This will return an array of Product Categories echo json_encode($categories);
<a name="products" />
###Get Products
$productObj = ShirtsIO::Products(); $products = $productObj->getProducts($categoryId); echo json_encode($products);
<a name="product-info" />
###Get Product Information
$productObj = ShirtsIO::Products(); $productInfo = $productObj->getProductInfo($productId); echo json_encode($productInfo);
**Response: ** https://www.shirts.io/docs/products_reference/#product_id
<a name="quote">
##Quote
###Get Quote
##Order
###Place Order
##Status
###Get Order Status