甜牙 / 甜牙PHP
此包已被废弃,不再维护。未建议替代包。
甜牙PHP库
dev-master
2014-08-20 16:36 UTC
Requires
- php: >=5.2
- ext-curl: *
- ext-json: *
- ext-mbstring: *
Requires (Dev)
This package is not auto-updated.
Last update: 2020-03-02 07:42:23 UTC
README
使用以下方式获取甜牙PHP库的最新版本
git clone https://github.com/sweettooth/sweettooth-php
要开始使用,请将以下代码添加到您的PHP脚本中
require_once("/path/to/sweettooth-php/lib/SweetTooth.php");
简单用法如下
SweetTooth::setApiKey('sk_gUjtToMzKybHZ3yGg3C4Sv4L'); $newCustomerData = array( 'first_name' => 'Wayne', 'last_name' => 'Rooney', 'email' => 'wrooney@example.com' ); $customer = SweetTooth_Customer::create($newCustomerData); echo $customer;
文档
请参阅https://www.sweettoothrewards.com/api以获取最新文档。
致谢
灵感来源于Stripe PHP