PHP code example of yanlongli / app-store-server-api
1. Go to this page and download the library: Download yanlongli/app-store-server-api library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
yanlongli / app-store-server-api example snippets
new \yanlongli\AppStoreServerApi\AppStoreServerApi(
...
'bundleId',
);
$example->subscriptions(...,'bundleId');
mple = new \yanlongli\AppStoreServerApi\AppStoreServerApi(
Environment::ENDPOINT_PRODUCTION,
'private key id',
'private key',
'IssuerID',
'app bundle id',// Optional,可选的,如果仅管理单个应用可以设定默认值。
);
// Get Subscription Status
$example->subscriptions('originalTransactionId','app bundle id'); // app bundle id 是可选的,这里将覆盖构造函数中的设定。
// Get Transaction History
$example->getTransactionHistory('originalTransactionId','revision');
// Consumption Information
$example->sendConsumptionInformation('originalTransactionId','requestBody');
// Order ID Lookup
$example->lookup('orderId');
// Refund Lookup
$example->refundLookup('originalTransactionId');
// Extend a Subscription Renewal Date
$example->extendASubscriptionRenewalDate('originalTransactionId','requestBody')
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.