Introduction
This guide covers setting up the Null Pass development environment, running the API locally, and testing endpoints. This is internal documentation for developers working on the Null Pass system.Prerequisites
- Node.js 18+ installed
- PostgreSQL database
- Git access to the repository
- Environment variables configured
Step 1: Register a User
First, let’s create a new user account. This endpoint will create a user and return a JWT token for authentication.The created user object
JWT token for authentication. Store this securely!
Step 2: Login
Now let’s authenticate an existing user:If the user has 2FA enabled, you’ll receive a
requires2FA: true response. You’ll need to prompt for the verification code and include it in a subsequent request.Step 3: Get User Profile
Use the token from login/register to fetch the authenticated user’s profile:Step 4: Update Profile
Update the user’s display name or avatar:Step 5: Manage Sessions
View and manage active sessions:Step 6: Enable Two-Factor Authentication
Secure your account with 2FA:Next Steps
Now that you have the basics working, explore these advanced features:Service Management
Learn how to manage service entitlements for DROP, MAILS, VAULT, and DB
Webhooks
Set up webhooks to receive real-time notifications
Error Handling
Understand error responses and how to handle them
Rate Limiting
Learn about rate limits and best practices
Common Issues
Getting 401 Unauthorized errors
Getting 401 Unauthorized errors
Rate limiting errors (403)
Rate limiting errors (403)
Null Pass uses Arcjet for rate limiting. If you’re hitting limits, implement exponential backoff and consider caching responses where appropriate.
2FA not working
2FA not working
Ensure your system clock is synchronized (NTP). TOTP codes are time-sensitive and require accurate time.
CORS issues
CORS issues
The API supports CORS. Make sure you’re making requests from an allowed origin or include proper CORS headers in your requests.
Need more help? Check out our API Reference or contact support.