A community based topic aggregation platform built on atproto
1package identity 2 3import "time" 4 5// ResolutionMethod indicates how an identity was resolved 6type ResolutionMethod string 7 8const ( 9 MethodCache ResolutionMethod = "cache" 10 MethodDNS ResolutionMethod = "dns" 11 MethodHTTPS ResolutionMethod = "https" 12) 13 14// Identity represents a fully resolved atProto identity 15type Identity struct { 16 DID string // Decentralized Identifier (e.g., "did:plc:abc123") 17 Handle string // Human-readable handle (e.g., "alice.bsky.social") 18 PDSURL string // Personal Data Server URL 19 ResolvedAt time.Time // When this identity was resolved 20 Method ResolutionMethod // How it was resolved (cache, DNS, HTTPS) 21} 22 23// DIDDocument represents an AT Protocol DID document 24// For now, we only extract the PDS service endpoint 25type DIDDocument struct { 26 DID string 27 Service []Service 28} 29 30// Service represents a service entry in a DID document 31type Service struct { 32 ID string 33 Type string 34 ServiceEndpoint string 35}