Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.xreatlabs.space/llms.txt

Use this file to discover all available pages before exploring further.

NexAuth Developer Documentation

Technical documentation for developers building with NexAuth, creating integrations, or contributing to the project.

Getting Started

1

Prerequisites

Before developing with NexAuth, ensure you have:
  • Java 17 or higher
  • Maven 3.6+ or Gradle 7.0+
  • Git for version control
  • IDE (IntelliJ IDEA recommended)
  • Basic understanding of Minecraft server development
2

Clone Repository

Clone the NexAuth repository from GitHub.
git clone https://github.com/XreatLabs/NexAuth.git
cd NexAuth
3

Build Project

Build the project using Maven or Gradle.
# Using Maven
./mvnw clean install

# Using Gradle
./gradlew clean build
4

Explore Codebase

Familiarize yourself with the project structure and key components.Explore architecture →

Documentation

Architecture

Understand NexAuth’s internal architecture, design patterns, and component organization.

Building

Complete build guide for compiling, testing, and packaging NexAuth.

Contributing

Guidelines for contributing code, reporting issues, and submitting pull requests.

Platform Support

Technical details about multiplatform support and platform-specific implementations.

Integration Guides

API Reference

Complete API documentation for integrating NexAuth with your plugins and applications.
NexAuth provides a comprehensive event system for reacting to authentication events:
@EventHandler
public void onPlayerLogin(PlayerLoginEvent event) {
    // Handle player login
}

@EventHandler  
public void onPlayerRegister(PlayerRegisterEvent event) {
    // Handle player registration
}
View event documentation →
Create custom authentication providers for specialized use cases:
public class CustomAuthProvider implements AuthProvider {
    @Override
    public AuthResult authenticate(String username, String password) {
        // Custom authentication logic
    }
}
View provider documentation →
NexAuth supports multiple database backends through its abstraction layer:
  • MySQL/MariaDB - Recommended for production
  • PostgreSQL - Advanced features and performance
  • H2 - Testing and development
  • SQLite - Lightweight embedded database
View database documentation →

Development Tools

Testing Framework

Comprehensive test suite with unit tests, integration tests, and mock server support.

Debugging Tools

Built-in debugging tools, verbose logging, and development mode for easier troubleshooting.

Specialized Topics

Limbo Integration

Advanced integration with Limbo servers for pre-authentication player handling and state management.

Best Practices

When developing with NexAuth:
  • Never store plaintext passwords - Always use the crypto utilities
  • Validate all input - Prevent injection attacks through proper validation
  • Use parameterized queries - Avoid SQL injection in database operations
  • Follow principle of least privilege - Minimize permissions for database users
  • Keep dependencies updated - Regularly update for security patches
View security documentation →
Optimize your integrations for performance:
  • Use async operations - Don’t block the main server thread
  • Implement caching - Cache frequently accessed data
  • Batch database operations - Reduce database round trips
  • Profile and test - Use profiling tools to identify bottlenecks
  • Monitor resource usage - Track memory and CPU usage
Follow our coding standards:
  • Java code conventions - Follow standard Java naming and formatting
  • Javadoc comments - Document public APIs with Javadoc
  • Meaningful names - Use descriptive variable and method names
  • Small methods - Keep methods focused and concise
  • Error handling - Proper exception handling and logging

Contributing

We welcome contributions from the community! Here’s how to get involved:
1

Check Existing Issues

Browse GitHub Issues to find open issues or feature requests.
2

Fork and Branch

Fork the repository and create a feature branch for your changes.
git checkout -b feature/your-feature-name
3

Make Changes

Implement your changes following our contributing guidelines.
4

Test Thoroughly

Ensure all tests pass and add new tests for your features.
./mvnw clean test
5

Submit Pull Request

Create a pull request with a clear description of your changes.

Resources

Source Code

Browse the source code on GitHub.

Issue Tracker

Report bugs and request features.

Discussions

Join community discussions and ask questions.

CI/CD Pipeline

View build and test status on GitHub Actions.

Support

If you need help with development:
  1. Check documentation - Review existing docs first
  2. Search issues - See if your question has been answered
  3. Ask in discussions - Post your question in GitHub Discussions
  4. Join Discord - Connect with other developers (coming soon)
  5. Create issue - Report bugs or feature requests
When reporting bugs, include:
  • NexAuth version - The specific version you’re using
  • Platform and version - Velocity/Paper version
  • Java version - Output of java -version
  • Steps to reproduce - Clear reproduction steps
  • Expected vs actual - What you expected vs what happened
  • Error logs - Relevant server logs and stack traces
  • Configuration - Sanitized configuration files

License

NexAuth is released under the MIT License. Contributions are accepted under the same license.

Ready to contribute?

Read our full contribution guidelines and start contributing today.