Customized XSL letter templates for Ex Libris Alma, maintained by the Office of Library Services at The City University of New York.
CUNY's library system spans 26 campuses and serves over 270,000 patrons. These templates provide a consistent, accessible experience across all 31 CUNY libraries while accommodating campus-specific needs.
- Accessibility-first: High contrast support, semantic HTML, WCAG 2.1 AA compliant
- Mobile-responsive: Templates work across all device types
- User-centered: Clear language that reduces library anxiety
- Visual clarity: Strategic use of emoji (📚, 🚚,
⚠️ ) for quick scanning
| File | Purpose |
|---|---|
header.xsl |
Campus-specific headers and branding |
footer.xsl |
Contact information and account links |
style.xsl |
Base styling |
mailReason.xsl |
Greeting templates |
senderReceiver.xsl |
Sender/receiver information |
| File | Purpose |
|---|---|
FulUserBorrowingActivityLetter.xsl |
Loan activity summaries |
FulUserLoansCourtesyLetter.xsl |
Courtesy notices for approaching due dates |
FulPlaceOnHoldShelfLetter.xsl |
Item ready for pickup |
FulOnHoldShelfReminderLetter.xsl |
Pickup reminders |
FulUserOverdueNoticeLetter.xsl |
Overdue notifications |
FulCancelRequestLetter.xsl |
Request cancellations |
FulItemChangeDueDateLetter.xsl |
Due date changes and recalls |
LendingRecallEmailLetter.xsl |
Recall notices |
FulOverdueAndLostLoanLetter.xsl |
Lost item notices with fees |
FulOverdueAndLostLoanNotificationLetter.xsl |
Initial lost item notifications |
ResendNotificationLetter.xsl |
Resend previous notifications |
| File | Purpose |
|---|---|
FulLoanReceiptLetter.xsl |
Checkout receipts |
FulReturnReceiptLetter.xsl |
Return receipts |
FineFeePaymentReceiptLetter.xsl |
Payment receipts |
This repository includes a command-line tool to sync letters between your local files and Alma via the Configuration API.
pipx install .Create a .env file from the template:
cp .env.example .envAdd your API keys (read/write access to Configuration API required):
ALMA_API_KEY_SANDBOX=your_sandbox_key
ALMA_API_KEY_PRODUCTION=your_production_key
ALMA_REGION=na
Available regions: na, eu, ap, aps, ca, cn
Export letters from Alma:
alma-lettersPush changes to Alma:
alma-letters push --env sandbox # Test in sandbox first
alma-letters push --env production # Requires confirmationView available letters:
alma-letters --debugletters.txt— Letter codes to sync (one per line)components.txt— Component codes to sync (one per line)
Lines starting with # are comments.
Based on May 2025 data, fulfillment letter volume:
| Letter Type | Volume | Share |
|---|---|---|
| Borrowing Activity Report | 36,959 | 69.8% |
| Courtesy Notices | 11,082 | 20.9% |
| Overdue Notices | 4,111 | 7.8% |
| Hold Shelf Reminders | 767 | 1.4% |
Fulfillment letters only; excludes acquisitions and other areas.
- GitHub Actions workflow for automated syncing
- Selective push (specific letters only)
- XSL validation before pushing
- Letter preview/testing tool
- University of Oslo Alma Letters — Reference implementation
- Alma User Discussion List