PHP and Node.js SDKs now available
Use our PHP or Node.js SDKs to streamline integrating with Paddle Billing. Fully-featured from webhook verification to every API operation.
What's new?
For the past few months, we've been working on SDKs for Paddle Billing for PHP and Node.js. They're now feature complete and publicly available on GitHub.
How it works
SDKs make it easier to work with the Paddle Billing platform. They reduce the amount of boilerplate code you need to write and include helper functions to make it quicker and easier to integrate Paddle Billing.
Today we released SDKs for PHP and Node.js, two of the most popular programming languages in our developer community.
Key features
- Install using popular package or dependency managers.
- Fully feature complete with the Paddle API.
- Includes helper functions to help you verify webhook signatures.
- Released under the Apache 2.0 licence, so anyone in the Paddle community can contribute.
Examples
This example shows initializing a new Paddle client with an API key and iterating through products.
12345678910111use Paddle\SDK\Client;
2use Paddle\SDK\Environment;
3use Paddle\SDK\Options;
4
5$paddle = new Client('API_KEY');
6
7$products = $paddle->products->list();
8
9foreach ($products as $product) {
10 echo $product->id;
11}
For more examples, see @PaddleHQ/paddle-php-sdk or @PaddleHQ/paddle-node-sdk on GitHub.
Next steps
This change is available now.
There are no changes to endpoints or fields in the API as a result of this change.
Go to @PaddleHQ/paddle-php-sdk or @PaddleHQ/paddle-node-sdk on GitHub to get started with our PHP or Node.js SDKs.
Early access program participants
Huge thanks to everyone who was part of our early access program for testing and giving us your feedback. If you used our prerelease SDKs, you’ll need to make a few small changes to switch over to our public versions:
PHP
Import the package from the public Packagist rather than the private one by running
composer require paddlehq/paddle-php-sdk
.Node.js
Remove the
//registry.npmjs.org/:_authToken=$NPM_TOKEN_GOES_HERE
line from the.npmrc
file at the root of any projects, whereNPM_TOKEN_GOES_HERE
is the unique NPM access token that we sent you.
You must do this before January 30th, 2024 to avoid disruption to your integration. You only need to do this once.