Appearance
Learn how to create, mint, and distribute blockchain-based certificates using Pocketbook. This guide covers both dashboard-based creation and API-based automation.
Overview
Creating a certificate in Pocketbook involves three main steps:
- Design: Define certificate metadata, images, and attributes
- Mint: Issue the certificate on the blockchain (or create a voucher for lazy minting)
- Distribute: Share the certificate with recipients
Certificate Lifecycle
┌──────────────┐
│ Designer │
│ (You create) │
└──────┬───────┘
│
▼
┌──────────────┐ ┌─────────────┐ ┌──────────────┐
│ Certificate │────▶│ Voucher │────▶│ Recipient │
│ Created │ │ Generated │ │ Claims │
└──────────────┘ └─────────────┘ └──────────────┘
│ │
│ ▼
│ ┌──────────────┐
└─────────────────────────────────▶│ Minted on │
│ Blockchain │
└──────────────┘Method 1: Dashboard Creation
Step 1: Log In and Navigate
- Visit pocketbook.studio
- Click "Connect Wallet"
- Select your wallet provider (MetaMask, WalletConnect, etc.)
- Sign the authentication message
- Navigate to "Create Certificate" from the dashboard
Step 2: Fill Certificate Details
Basic Information:
- Name: Certificate title (e.g., "Web Development Certificate")
- Description: Detailed description (e.g., "Awarded for completing...")
- Category: Select from predefined categories or create custom
Image Upload:
- Click "Upload Image" or provide an image URL
- Recommended: 1200x1200 pixels, PNG or JPG format
- Maximum size: 5MB
- The image will be automatically uploaded to IPFS
Step 3: Add Metadata Attributes
Add custom attributes to make your certificate searchable and verifiable:
Attribute Name Value
───────────────────── ──────────────────
Course Name Web Development 101
Completion Date January 15, 2025
Grade A+
Instructor Jane Doe
Duration 40 hoursCommon Attribute Types:
- Education: Course, Institution, Grade, Date
- Employment: Position, Department, Years of Service
- Events: Event Name, Date, Location, Role
- Products: Serial Number, Warranty Period, Purchase Date
Step 4: Choose Distribution Method
Option A: Direct Mint
- Certificate is immediately minted to a specified wallet address
- Gas fees covered by Pocketbook
- Instant delivery to recipient's wallet
Option B: Create Voucher
- Generate a claim link for the recipient
- Recipient mints when ready (gasless)
- Set expiry date (optional)
- Track claiming status
Step 5: Review and Create
- Preview your certificate design
- Review all details for accuracy
- Click "Create Certificate"
- Wait for blockchain confirmation (30-60 seconds)
- Receive certificate ID and claim link
Method 2: API Creation
Quick API Example
javascript
import { ethers } from 'ethers';
// 1. Authenticate
const timestamp = Math.floor(Date.now() / 1000);
const message = `Authenticate with Pocketbook: ${timestamp}`;
const signature = await signer.signMessage(message);
const authResponse = await fetch('https://api.pocketbook.studio/api/certificate/auth', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
signature,
address: await signer.getAddress(),
message,
timestamp: timestamp.toString()
})
});
const { data: authData } = await authResponse.json();
const token = authData.token;
// 2. Create Certificate
const certificateResponse = await fetch('https://api.pocketbook.studio/api/certificate/create', {
method: 'POST',
headers: {
'Authorization': `Bearer ${token}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
name: 'Web Development Certificate',
description: 'Awarded for completing Web Development 101',
imageUrl: 'https://example.com/certificate.png',
metadata: {
category: 'education',
attributes: [
{ trait_type: 'Course', value: 'Web Development 101' },
{ trait_type: 'Date', value: '2025-01-15' },
{ trait_type: 'Grade', value: 'A+' }
]
}
})
});
const { data: certData } = await certificateResponse.json();
console.log('Certificate created:', certData.certificateId);
// 3. Create Voucher for Distribution
const voucherResponse = await fetch('https://api.pocketbook.studio/api/voucher/create', {
method: 'POST',
headers: {
'Authorization': `Bearer ${token}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
certificateId: certData.certificateId,
expiryDays: 30,
metadata: {
recipientEmail: 'student@example.com',
recipientName: 'John Student'
}
})
});
const { data: voucherData } = await voucherResponse.json();
console.log('Claim link:', `https://pocketbook.studio/claim/${voucherData.id}`);Distribution Methods
Method 1: Voucher Claims (Recommended)
Benefits:
- Recipients don't need crypto or wallet initially
- Gasless claiming experience
- Control when minting occurs
- Track who has claimed
Process:
- Create voucher with certificate ID
- Generate unique claim link
- Send link to recipient via email/SMS
- Recipient connects wallet and claims
- Certificate mints to their address
Example Claim Link:
https://pocketbook.studio/claim/vch_abc123xyz789Method 2: Direct Minting
Benefits:
- Instant delivery
- No claim step required
- Good for known wallet addresses
Process:
- Create certificate with recipient's address
- Certificate mints directly to their wallet
- Recipient sees it immediately
Use Cases:
- Existing community members with wallets
- Batch distribution to known addresses
- Internal team recognition
Method 3: Bulk Operations
For issuing many certificates at once:
csv
name,description,imageUrl,category,recipientEmail,recipientName
Certificate 1,Description 1,https://example.com/img1.png,education,student1@example.com,Alice
Certificate 2,Description 2,https://example.com/img2.png,education,student2@example.com,Bob
Certificate 3,Description 3,https://example.com/img3.png,education,student3@example.com,CharlieUpload CSV via:
- Dashboard bulk upload interface
- API
/bulk-mintendpoint - See Bulk Operations Guide
Certificate Design Best Practices
Image Guidelines
Resolution:
- Minimum: 800x800 pixels
- Recommended: 1200x1200 pixels
- Maximum: 2400x2400 pixels
Format:
- PNG (preferred for transparency)
- JPG (good for photographs)
- Avoid GIFs or animated formats
File Size:
- Target: 500KB - 2MB
- Maximum: 5MB
- Optimize images before upload
Design Tips:
- Use high contrast for text readability
- Include organization branding/logo
- Leave space for metadata display
- Test on mobile and desktop
Metadata Structure
Essential Attributes:
javascript
{
category: 'education', // or 'achievement', 'membership', 'product'
attributes: [
{ trait_type: 'Recipient', value: 'John Doe' },
{ trait_type: 'Date Issued', value: '2025-01-15' },
{ trait_type: 'Issuer', value: 'Acme University' }
]
}Advanced Attributes:
javascript
{
category: 'education',
attributes: [
// Core Info
{ trait_type: 'Course', value: 'Advanced Web Development' },
{ trait_type: 'Institution', value: 'Tech Academy' },
{ trait_type: 'Completion Date', value: '2025-01-15' },
// Performance
{ trait_type: 'Final Grade', value: '95/100' },
{ trait_type: 'Ranking', value: 'Top 10%' },
// Details
{ trait_type: 'Duration', value: '12 weeks' },
{ trait_type: 'Credits', value: '3.0' },
{ trait_type: 'Instructor', value: 'Dr. Jane Smith' },
// Verification
{ trait_type: 'Certificate ID', value: 'CERT-2025-001234' },
{ trait_type: 'Verification URL', value: 'https://academy.edu/verify/001234' }
]
}Common Use Cases
Use Case 1: Course Completion
javascript
const courseCertificate = {
name: 'JavaScript Fundamentals Certificate',
description: 'Successfully completed JavaScript Fundamentals course with distinction',
imageUrl: 'https://cdn.academy.com/certificates/js-fundamentals.png',
metadata: {
category: 'education',
attributes: [
{ trait_type: 'Student', value: 'Alice Johnson' },
{ trait_type: 'Course', value: 'JavaScript Fundamentals' },
{ trait_type: 'Institution', value: 'Code Academy' },
{ trait_type: 'Completion Date', value: '2025-01-15' },
{ trait_type: 'Grade', value: 'A (95%)' },
{ trait_type: 'Instructor', value: 'Prof. Bob Wilson' },
{ trait_type: 'Course Duration', value: '8 weeks' },
{ trait_type: 'Total Hours', value: '60 hours' }
]
}
};Use Case 2: Event Attendance
javascript
const eventBadge = {
name: 'Web3 Summit 2025 Attendee',
description: 'Attended Web3 Summit 2025 in San Francisco',
imageUrl: 'https://events.com/web3-summit-2025-badge.png',
metadata: {
category: 'event',
attributes: [
{ trait_type: 'Event', value: 'Web3 Summit 2025' },
{ trait_type: 'Location', value: 'San Francisco, CA' },
{ trait_type: 'Date', value: 'March 15-17, 2025' },
{ trait_type: 'Attendee Type', value: 'General Admission' },
{ trait_type: 'Track', value: 'DeFi & Infrastructure' }
]
}
};Use Case 3: Product Warranty
javascript
const warranty = {
name: 'Premium Laptop Warranty Certificate',
description: 'Extended warranty for MacBook Pro 2025',
imageUrl: 'https://store.com/warranty-certificate.png',
metadata: {
category: 'product',
attributes: [
{ trait_type: 'Product', value: 'MacBook Pro 16" M4' },
{ trait_type: 'Serial Number', value: 'C02XL1234567' },
{ trait_type: 'Purchase Date', value: '2025-01-15' },
{ trait_type: 'Warranty Type', value: 'Extended - 3 Years' },
{ trait_type: 'Warranty Start', value: '2025-01-15' },
{ trait_type: 'Warranty End', value: '2028-01-15' },
{ trait_type: 'Coverage', value: 'Parts and Labor' },
{ trait_type: 'Retailer', value: 'Tech Store Inc.' }
]
}
};Use Case 4: Employee Recognition
javascript
const recognition = {
name: '5 Years of Service Award',
description: 'Recognizing exceptional dedication and 5 years of service',
imageUrl: 'https://company.com/awards/5-year-service.png',
metadata: {
category: 'achievement',
attributes: [
{ trait_type: 'Employee', value: 'Sarah Martinez' },
{ trait_type: 'Award Type', value: 'Years of Service' },
{ trait_type: 'Years', value: '5' },
{ trait_type: 'Department', value: 'Engineering' },
{ trait_type: 'Start Date', value: '2020-01-15' },
{ trait_type: 'Award Date', value: '2025-01-15' },
{ trait_type: 'Issued By', value: 'Acme Corporation' }
]
}
};Verification and Viewing
Public Verification
Once minted, certificates can be verified by anyone:
Via Pocketbook:
https://pocketbook.studio/certificate/{certificateId}Via Blockchain Explorer:
https://polygonscan.com/token/{contractAddress}?a={tokenId}Wallet Display
Recipients can view their certificates in:
- Pocketbook Dashboard: Full metadata and images
- MetaMask: NFT section (mobile app)
- OpenSea: NFT marketplace
- Any NFT Wallet: Standard ERC-721 support
Embedding Certificates
Display certificates on your website:
html
<iframe
src="https://pocketbook.studio/embed/certificate/{id}"
width="600"
height="800"
frameborder="0">
</iframe>Troubleshooting
Common Issues
Issue: Image not displaying
- Ensure image URL is publicly accessible
- Check image format (PNG/JPG recommended)
- Verify image size is under 5MB
- Wait for IPFS upload to complete
Issue: Blockchain transaction failed
- Check wallet has sufficient MATIC for gas
- Verify network connectivity
- Wait for network congestion to clear
- Retry transaction after a few minutes
Issue: Recipient can't claim voucher
- Verify voucher hasn't expired
- Check claim link is complete and correct
- Ensure recipient has connected wallet
- Check voucher hasn't been already claimed
Issue: Certificate not appearing in wallet
- Wait for blockchain confirmation (30-60 seconds)
- Refresh wallet or re-sync
- Verify correct wallet address was used
- Check certificate was successfully minted (not just voucher created)
Next Steps
For Further Learning
- API Integration: Complete API Documentation
- Bulk Operations: Bulk Minting Guide
- Webhooks: Real-time Events
- Templates: Enterprise Templates
Integration Examples
- E-learning Platforms: Integrate with Moodle, Canvas, Coursera
- Event Management: Connect with Eventbrite, Hopin, Luma
- E-commerce: Shopify, WooCommerce product warranties
- HR Systems: BambooHR, Workday employee recognition
Getting Help
- Documentation: docs.pocketbook.studio
- Email Support: seth@pocketbook.studio
- Discord Community: Join our Discord
- GitHub: Report issues
Ready to create your first certificate?
→ Try the Dashboard → Explore API Examples → View Quick Start
