robo-meister / robo-store-api
PHP SDK for the Robo Meister Store API.
v0.0.1
2026-05-31 14:57 UTC
Requires
- php: >=8.2
- ext-curl: *
- ext-json: *
Requires (Dev)
- phpunit/phpunit: ^10.0 || ^11.0
README
Composer package for integrating PHP services with the Robo Meister Store API.
composer require robo-meister/robo-store-api
Requirements
- PHP 8.2 or newer
ext-curlext-json
Quick start
<?php use RoboMeister\RoboStoreApi\ClientOptions; use RoboMeister\RoboStoreApi\RoboStoreApiClient; $client = new RoboStoreApiClient(new ClientOptions( baseUrl: 'https://store.robo-meister.com', apiToken: getenv('ROBO_STORE_API_TOKEN') ?: null, )); $offers = $client->offers('FLOWBEACON'); $checkoutUrl = $client->checkoutStartUrl('FLOWBEACON_LTD', [ 'owner_type' => 'organisation', 'owner_id' => 'org_123', 'return_url' => 'https://flowbeacon.example/billing/return', 'idempotency_key' => 'checkout-org_123-FLOWBEACON_LTD', ]);
Supported helpers
| Method | Store endpoint | Purpose |
|---|---|---|
offers($product, $filters = []) |
GET /api/store/offers |
Fetch public offers for a product. |
filteredOffers($filters = []) |
GET /api/store/offers/filter |
Fetch locally filtered offers by product/category/tags. |
recommendations($context = []) |
GET /api/store/recommendations |
Fetch compatibility recommendations. |
paymentProviders() |
GET /api/store/payment-providers |
Discover enabled payment providers. |
activateFree($sku, $product, $options = []) |
POST /api/store/activate-free |
Activate a _FREE SKU for an owner. |
checkoutStartUrl($sku, $options = []) |
GET /checkout/start |
Build a browser redirect URL for paid checkout. |
Low-level get(), post(), and buildUrl() methods are also available for endpoints that do not yet have a typed helper.
Publishing checklist
- Push this directory to the public package repository used by Packagist.
- Confirm
composer.jsonhas the package namerobo-meister/robo-store-api. - Tag the first release, for example
v0.1.0. - Submit the repository URL in Packagist and enable GitHub auto-update hooks.
- Verify installation with
composer require robo-meister/robo-store-api:^0.1in a clean project.
Testing
composer install
composer test