Installing Coinbase Pay SDK
This page explains how to install and upgrade Coinbase Pay SDK with yarn or npm.
info
The Coinbase Pay public GitHub can be found at @coinbase/cbpay-js.
Installing Coinbase Pay SDK
Yarn
- Check available versions of Coinbase Pay SDK:
yarn info @coinbase/cbpay-js versions
- Install a specific version or the latest version:
Install specific version:
yarn add @coinbase/cbpay-js@1.0.0
Install latest version:
yarn add @coinbase/cbpay-js
- Check your installed version:
yarn list @coinbase/cbpay-js
Npm
- Check available versions of Coinbase Pay SDK:
npm view @coinbase/cbpay-js versions
- Install a specific version or the latest version:
Install specific version:
npm install @coinbase/cbpay-js@1.0.0
Install latest version:
npm install @coinbase/cbpay-js
- Check your installed version:
npm list @coinbase/cbpay-js
Upgrading Coinbase Pay SDK
Yarn
- Compare your installed version of Coinbase Pay SDK with the latest available version:
yarn outdated @coinbase/cbpay-js
- Update Coinbase Pay SDK to the latest:
yarn upgrade @coinbase/cbpay-js --latest
- Check your version:
yarn list @coinbase/cbpay-js
Npm
- Compare your installed version of Coinbase Pay SDK with the latest available version:
npm outdated @coinbase/cbpay-js
- If necessary, update
package.json
with the latest version (or major version), for example:
{
"dependencies": {
"@coinbase/cbpay-js": "./coinbase-cbpay-js-[paysdk-version-latest].tgz"
}
}
- Update Coinbase Pay SDK to the latest available version:
npm update @coinbase/cbpay-js
See Also: