The Server SDK is currently experimental and not ready for production use. Reach out to partnerships@phantom.com for access.
Overview
Message signing is a crucial feature for authentication, proof of ownership, and creating verifiable statements. This guide covers how to sign messages using the Phantom Server SDK. The SDK provides a simple interface for signing messages:Basic message signing
Simple example
Network-specific signing
Different networks use different signing algorithms:Examples
Timestamped messages
Sign messages with timestamps for audit trails:Best practices
- Always include unique data in messages to prevent replay attacks (nonce, timestamp).
- Store message-signature pairs for audit and verification purposes.
- Use structured messages (JSON) for complex data that needs signing.
- Verify signatures server-side before processing any authenticated actions.