Server Overview
Comprehensive backend server for the Solana App Kit, providing token management, social features, real-time messaging, and various API endpoints for interacting with the Solana blockchain.
Overview
This backend server is built with Express.js and TypeScript, offering a robust API for Solana blockchain interactions, social features, real-time messaging, and comprehensive token management. It serves as the core backend for the Solana App Kit, providing modular, reusable, and easily customizable components for developers.
Features
Token Management
- Token creation via TokenMill
- Market creation and management
- Setting bonding curves
- Token swapping (buy/sell)
- Staking and vesting
- Market graduation and funding
DEX Integrations
- Jupiter DEX swapping
- Raydium swap integration
- Meteora DBC (Dynamic Bonding Curve)
- PumpFun token launches
- Cross-platform swap quotes
Social Features
- Thread creation and management
- User profiles and authentication
- Follow system and user interactions
- Image upload and management
- User reactions and engagement
Real-time Features
- WebSocket-based chat system
- Global chat functionality
- Real-time message delivery
- Chat image support
- Push notifications via Expo
Storage Solutions
- IPFS integration via Pinata
- Google Cloud Storage
- Image processing and optimization
- Metadata management
- File upload handling
Wallet & Security
- Turnkey API integration
- Secure wallet management
- Transaction signing
- Admin authentication system
- Multi-signature support
NFT Operations
- NFT minting and management
- Metadata handling
- Collection management
Aura System
- Aura-based interactions
- User reputation management
- Community engagement tracking
Prerequisites
Quick Start
Clone and Navigate
Install Dependencies
Environment Setup
Configure all required environment variables in your .env
file. See the Configuration section for details.
Start Development Server
The server will start on port 8080 (or the port specified in your environment variables) with WebSocket support enabled.
Architecture Overview
The server follows a modular, service-oriented architecture:
Core Services
Capabilities:
- Token creation and market management
- Setting bonding curves for dynamic pricing
- Token swapping with optimal rates
- Staking mechanisms for rewards
- Vesting schedules for token distribution
- Market graduation and funding
Key Features:
- Integration with Solana programs
- Real-time price calculations
- Transaction optimization
Capabilities:
- Token creation and market management
- Setting bonding curves for dynamic pricing
- Token swapping with optimal rates
- Staking mechanisms for rewards
- Vesting schedules for token distribution
- Market graduation and funding
Key Features:
- Integration with Solana programs
- Real-time price calculations
- Transaction optimization
Features:
- Socket.IO integration
- Global chat functionality
- Real-time message delivery
- Connection management
- Transport optimization
Implementation:
- Cross-platform compatibility
- Health monitoring
- Debugging endpoints
IPFS Integration:
- Metadata storage via Pinata
- Decentralized content hosting
- Gateway management
Cloud Storage:
- Google Cloud Storage for images
- Image processing and optimization
- CDN integration
Turnkey Integration:
- Secure key management
- Hardware-backed security
- Multi-signature support
Features:
- Wallet creation and recovery
- Transaction signing
- Address management
Push Notifications:
- Expo integration
- Real-time delivery
- User targeting
Features:
- Notification scheduling
- Custom payload support
- Delivery tracking
API Endpoints Overview
TokenMill Endpoints
Endpoint | Method | Description |
---|---|---|
/api/config | POST | Create TokenMill configuration |
/api/quote-token-badge | POST | Get token badge quote |
/api/markets | POST | Create token market |
/api/free-market | POST | Free market from restrictions |
/api/tokens | POST | Create new token |
/api/swap | POST | Execute token swap |
/api/stake | POST | Create staking position |
/api/vesting | POST | Create vesting schedule |
DEX Integration Endpoints
Endpoint | Method | Description |
---|---|---|
/api/jupiter/* | Various | Jupiter DEX integration |
/api/raydium/swap/* | Various | Raydium swap operations |
/api/meteora/* | Various | Meteora DBC operations |
/api/pump-swap/* | Various | PumpSwap functionality |
Social & Real-time Features
Endpoint | Method | Description |
---|---|---|
/api/thread | Various | Thread management |
/api/profile | Various | User profiles |
/api/chat | Various | Real-time messaging |
/api/notifications | Various | Push notifications |
For detailed API documentation, see the API Reference section.
Security Measures
Important Security Considerations
- All transactions require proper signature verification
- Environment variables store sensitive credentials
- Database queries use parameterized statements
- Error messages are sanitized
- CORS configuration for API access
- WebSocket connection validation
Development Workflow
Next Steps
Installation Guide
Complete setup instructions with detailed environment configuration
API Documentation
Comprehensive API reference with examples and responses
Deployment
Production deployment guides for various platforms
Integration Examples
Real-world examples of client-server integration
Need Help? Check out our support channels or open an issue in the GitHub repository.