Skip to main content

Prerequisites

Before setting up ABHA integration, ensure you have:
1

ABDM Registration

Register your healthcare facility with ABDM and obtain your facility ID
2

API Credentials

Request API access credentials from the ABDM sandbox or production environment
3

SSL Certificate

Obtain a valid SSL certificate for secure communication with ABDM servers
ABHA integration requires compliance with data protection regulations. Ensure your infrastructure meets ABDM security standards.

Configuration Steps

1. Configure ABDM Credentials

Set up your ABDM API credentials in the Aria configuration:
{
  "abdm": {
    "clientId": "your-client-id",
    "clientSecret": "your-client-secret",
    "facilityId": "your-facility-id",
    "environment": "sandbox" // or "production"
  }
}
Start with the sandbox environment for testing before moving to production.

2. Enable ABHA Authentication

Configure ABHA authentication to allow patients to link their ABHA IDs:
// Enable ABHA login flow
const abhaConfig = {
  enableABHALogin: true,
  authMethods: ['mobile', 'aadhaar', 'abha-number'],
  consentTimeout: 300 // seconds
};

3. Set Up Health Locker Sync

Enable automatic synchronization of prescriptions to patient ABHA health lockers:
1

Configure Webhooks

Set up webhooks to receive notifications when prescriptions are created
2

Enable Auto-Sync

Configure automatic push of digital prescriptions to ABHA health lockers
3

Set Consent Rules

Define consent requirements for accessing patient health records

4. Test the Integration

Verify your ABHA integration is working correctly:
# Test ABHA authentication
curl -X POST https://your-aria-instance/api/abha/verify \
  -H "Content-Type: application/json" \
  -d '{"abhaId": "12-3456-7890-1234"}'

# Test prescription sync
curl -X POST https://your-aria-instance/api/prescriptions/sync \
  -H "Authorization: Bearer your-token" \
  -d '{"prescriptionId": "abc123"}'
Use test ABHA IDs provided in the ABDM sandbox for initial testing.

Patient Onboarding

Guide your patients through linking their ABHA ID:

Option 1: ABHA Number

1

Patient Enters ABHA Number

Patient provides their 14-digit ABHA number
2

OTP Verification

System sends OTP to registered mobile number for verification
3

Account Linking

Upon successful verification, ABHA ID is linked to Aria account

Option 2: Aadhaar-based Creation

1

Aadhaar Entry

Patient provides Aadhaar number (if they don’t have ABHA)
2

OTP Verification

Verify mobile number linked to Aadhaar
3

ABHA Creation

System creates new ABHA ID and links it to patient account

Security Best Practices

Never store ABHA credentials in plain text. Use encrypted storage and secure key management.
  • Encrypt Data in Transit: Always use HTTPS/TLS for API communications
  • Implement Consent Management: Obtain explicit patient consent before accessing health records
  • Audit Logging: Maintain comprehensive logs of all ABHA transactions
  • Regular Security Audits: Conduct periodic security assessments of your ABHA integration
  • Data Retention Policies: Follow ABDM guidelines for data storage and retention

Troubleshooting

Common Issues

Solution: Verify that the ABHA number is correct and the patient’s mobile number is updated in the ABHA system.
Solution: Check your API credentials and ensure the prescription format complies with FHIR standards required by ABDM.
Solution: Increase the consent timeout value in your configuration or check network connectivity to ABDM servers.

Production Checklist

Before going live with ABHA integration:
  • Complete ABDM production environment registration
  • Obtain production API credentials
  • Configure SSL certificates for production
  • Test end-to-end patient flow
  • Verify prescription sync to health lockers
  • Implement error handling and logging
  • Set up monitoring and alerts
  • Train staff on ABHA workflows
  • Prepare patient education materials
Run a pilot program with a small group of patients before full rollout to identify and resolve any issues.

Next Steps

ABDM Integration

Learn about the broader ABDM ecosystem

API Reference

Explore the Aria API documentation

Support

If you encounter issues during setup:
  • Review the ABDM Developer Documentation
  • Contact ABDM support for API-related issues
  • Reach out to Aria support for platform-specific assistance

Build docs developers (and LLMs) love