forked from baron/baron-sso
27 lines
725 B
Go
27 lines
725 B
Go
package domain
|
|
|
|
type EnchantedLinkInitRequest struct {
|
|
LoginID string `json:"loginId"`
|
|
URI string `json:"uri,omitempty"` // Redirect URI (optional for polling flow)
|
|
Method string `json:"method,omitempty"` // "email" or "sms"
|
|
}
|
|
|
|
type EnchantedLinkInitResponse struct {
|
|
LinkID string `json:"linkId"`
|
|
PendingRef string `json:"pendingRef"`
|
|
MaskedEmail string `json:"maskedEmail"`
|
|
}
|
|
|
|
type EnchantedLinkPollRequest struct {
|
|
PendingRef string `json:"pendingRef"`
|
|
}
|
|
|
|
type EnchantedLinkPollResponse struct {
|
|
SessionToken string `json:"sessionToken"` // JWT
|
|
RefreshToken string `json:"refreshToken"`
|
|
UserID string `json:"userId,omitempty"`
|
|
}
|
|
|
|
type MagicLinkVerifyRequest struct {
|
|
Token string `json:"token"`
|
|
} |