Summary
- Implements GET /xrpc/com.atproto.server.describeServer — the ATProto service discovery endpoint Bluesky clients hit first during login
- Extends Config with available_user_domains (required), invite_code_required (default true), optional server_did, [links], and [contact] sections
- Handler derives did:web: from public_url as a placeholder when server_did is not configured; Wave 3 will replace this with a real did:plc DID
- Optional links and contact fields are omitted from the JSON response entirely when not configured (not serialized as null)
- Updated relay.dev.toml with documented stubs for all new fields
Test plan
- cargo test --workspace passes (63 tests, 0 failures)
- cargo clippy --workspace -- -D warnings passes clean
- curl http://localhost:8080/xrpc/com.atproto.server.describeServer returns valid JSON with availableUserDomains, inviteCodeRequired, phoneVerificationRequired, and a did field
- Setting server_did in config returns that DID verbatim; leaving it unset returns did:web:
- Setting [links] / [contact] in config includes them in the response; omitting them excludes those keys entirely