SDKs
Node.js SDK
We have created a Node.js SDK to make it easier for you to interact with our API. This SDK is open-source and can be found on our GitHub.
Installation
npm install --save @passmint/sdk
Initialization
const passmint = new PassMint({
apiKey: 'a1af13cc-cc11-4405-8d3c-471b7197b743', // Replace with your API key
});
Create a Pass
passmint.pass.create({
templateId: 'pass_123',
data: {
barcodeValue: '123456789',
fields: [
{
key: 'header-1',
value: 'Jamie Smith',
},
{
key: 'back-1',
value: new Date().toISOString(),
},
],
},
});