verifying-phoneslisted
Install: claude install-skill SendlyHQ/sendly-skills
# Phone Verification with Sendly
## Quick start
```typescript
import Sendly from "@sendly/node";
const sendly = new Sendly(process.env.SENDLY_API_KEY!);
const verification = await sendly.verify.send({ to: "+15551234567" });
console.log(verification.id); // ver_abc123
const result = await sendly.verify.check(verification.id, { code: "123456" });
console.log(result.status); // "verified" | "failed" | "expired"
```
## REST API
**Base URL:** `https://sendly.live/api/v1`
### Send OTP
```bash
curl -X POST https://sendly.live/api/v1/verify \
-H "Authorization: Bearer $SENDLY_API_KEY" \
-H "Content-Type: application/json" \
-d '{"to": "+15551234567", "app_name": "MyApp", "code_length": 6, "timeout_secs": 300}'
```
**Required:** `to` (E.164 format)
**Optional:** `app_name` (shown in SMS), `code_length` (4–10, default 6), `timeout_secs` (default 300)
**Response:**
```json
{
"id": "ver_abc123",
"status": "pending",
"phone": "+15551234567",
"expires_at": "2026-04-01T10:05:00Z"
}
```
In sandbox mode (`sk_test_*` keys), the response includes `sandbox_code` with the actual code.
### Check code
```bash
curl -X POST https://sendly.live/api/v1/verify/ver_abc123/check \
-H "Authorization: Bearer $SENDLY_API_KEY" \
-H "Content-Type: application/json" \
-d '{"code": "123456"}'
```
**Statuses:** `verified`, `failed` (wrong code), `expired`, `max_attempts_exceeded` (3 attempts max)
### Resend OTP
```bash
curl -X POST https://sendly.live/api/v1/verify/ver_abc123