> **Building with AI coding agents?** Install the authstack plugin with one command. This equips your agent with accurate Scalekit implementation patterns.
>
> **Recommended**:
> ```bash
> npx @scalekit-inc/cli setup
> ```
>
> Global:
> ```bash
> npm install -g @scalekit-inc/cli
> scalekit setup
> ```
>
> Supports Claude Code, Cursor, GitHub Copilot, Codex + skills for 40+ agents.
> Features: full-stack-auth, agent-auth, mcp-auth, modular-sso, modular-scim.
> [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Magic link & OTP

Send and verify passwordless login codes
<div class="sdk-client-page">

Use the passwordless client to send and verify email magic links or one-time codes for sign-in.

Call send, then verify with the code or link token from the user's email to complete login.

### SendPasswordlessEmail
<div class="sdk-method-section">
  
    
      

      SendPasswordlessEmail sends a passwordless authentication email

      
        Request context
      
      
        Email address.
      
      
        Optional request settings.
      
      
        Send passwordless.
      

```go wrap showLineNumbers=false
template := scalekit.TemplateTypeSignin
resp, err := scalekitClient.Passwordless().SendPasswordlessEmail(ctx, "user@example.com", &scalekit.SendPasswordlessOptions{
  Template:         &template,
  MagiclinkAuthUri: "https://myapp.com/auth/callback",
  State:            "state",
  ExpiresIn:        1800,
  TemplateVariables: map[string]string{
    "app_name": "My App",
  },
})
if err != nil {
  // handle
}
_ = resp.AuthRequestId
```

    
  
</div>

### VerifyPasswordlessEmail
<div class="sdk-method-section">
  
    
      

      VerifyPasswordlessEmail verifies a passwordless authentication

      
        Request context
      
      
        Optional request settings.
      
      
        Verified claims or result.
      

```go wrap showLineNumbers=false
verified, err := scalekitClient.Passwordless().VerifyPasswordlessEmail(ctx, &scalekit.VerifyPasswordlessOptions{
  Code:          "123456",
  AuthRequestId: "auth_req_123",
})
if err != nil {
  // handle
}
_ = verified
```

    
  
</div>

### ResendPasswordlessEmail
<div class="sdk-method-section">
  
    
      

      ResendPasswordlessEmail resends a passwordless authentication email

      
        Request context
      
      
        Auth request id.
      
      
        Send passwordless.
      

```go wrap showLineNumbers=false
resp, err := scalekitClient.Passwordless().ResendPasswordlessEmail(ctx, "auth_req_123")
if err != nil {
  // handle
}
_ = resp.AuthRequestId
```

    
  
</div>

</div>


---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
