Connect Cloudflare R2 to PD Object Storage in WHMCS
Connect the intended Cloudflare account to sell R2-backed storage through PD Object Storage. The module needs a management API token, while customer applications receive a separate S3-compatible key pair.
Prepare the account token
Install PD Modules, connect the account holding your licence and install PD Object Storage from its Store. Prepare a dedicated host credential for the intended account; customers receive separate service credentials. Keep host credentials out of customer tools, screenshots and tickets.
Ask the Cloudflare account administrator to prepare an account-owned management token for the intended account with Account API Tokens: Edit, Workers R2 Storage: Edit and Account Analytics: Read. These serve customer-token management, buckets/settings and usage respectively. R2 must be enabled for the account.
The customer-facing Access Key ID and Secret Access Key from an R2 S3 setup are different from the management bearer token entered here. Review Cloudflare’s R2 authentication documentation and account-token API when checking token type and permissions; permission wording can differ between interfaces.
Save and associate the account
- Open System Settings → Products/Services → Servers.
- Add a server of type PD Object Storage.
- Put the Cloudflare Account ID in Username and the management token in Password.
- Save and give this backend its own intended server group.
- On the product’s Module Settings, choose Cloudflare R2 as Backend, select that group and save.
- Review its data-location choice before provisioning.
Check the named test result
Use PD Object Storage → Settings → Test Connection. For R2 it reads account-token permission groups and lists buckets; it does not create a customer token or bucket. A passing result is not proof of every token-management, analytics or settings write.
If a scope check fails, have the administrator review the intended account/token and named permission. Do not substitute a customer S3 pair or change unrelated Cloudflare security settings. See placement and endpoint checks before using a jurisdiction-specific service.
See the PD Object Storage WHMCS guide for related tasks, or explore PD Object Storage.