API Reference

Base URL: https://api.stillhere.life
All authenticated endpoints require Authorization: Bearer TOKEN

Quick Start: Automated Check-in

# 1. Generate an API key (one-time, from dashboard or API)
curl -X POST https://api.stillhere.life/api/auth/generate-api-key \
  -H "Authorization: Bearer YOUR_JWT_TOKEN"

# 2. Set up a cron job (e.g., every week)
# crontab -e
0 9 * * 1 curl -X POST "https://api.stillhere.life/api/auth/check-in/api-key?api_key=YOUR_API_KEY"

Authentication

POST/api/auth/register

Create account with email + password

{"email": "...", "password": "..."}
POST/api/auth/login

Login and get JWT tokens

{"email": "...", "password": "..."}
GET/api/auth/google

Start Google OAuth flow (redirect)

POST/api/auth/refresh

Refresh expired access token

{"refresh_token": "..."}

Check-in (Heartbeat)

POST/api/auth/check-inauth

Check in (requires Bearer token)

GET/api/auth/check-in/{token}

One-click email check-in (no auth needed)

POST/api/auth/check-in/api-key?api_key=KEY

API key check-in (for automation)

POST/api/auth/generate-api-keyauth

Generate API key for automated check-ins

POST/api/auth/generate-check-in-tokenauth

Generate one-click check-in URL

User

GET/api/user/profileauth

Get user profile

GET/api/user/statusauth

Get heartbeat status (escalation state, days remaining)

PUT/api/user/settingsauth

Update check-in interval

{"check_in_interval_days": 14}

Beneficiaries

GET/api/beneficiaries/auth

List all beneficiaries

POST/api/beneficiaries/auth

Add beneficiary

{"name": "...", "email": "...", "phone": "..."}
PUT/api/beneficiaries/{id}auth

Update beneficiary

DELETE/api/beneficiaries/{id}auth

Delete beneficiary

POST/api/beneficiaries/{id}/notifyauth

Send pre-notification (Basic+)

Messages

GET/api/messages/auth

List all messages

POST/api/messages/auth

Create encrypted message

{"beneficiary_id": "...", "content_encrypted": "...", "delivery_channels": ["email", "whatsapp"]}
DELETE/api/messages/{id}auth

Delete message

Files

POST/api/files/uploadauth

Upload encrypted file attachment (multipart)

GET/api/files/download/{file_id}

Download encrypted file (no auth)

Delivery Log

GET/api/delivery/logauth

Full delivery audit trail

GET/api/delivery/log/{message_id}auth

Delivery log for specific message

Payments

POST/api/payments/create-checkout?tier=proauth

Start Stripe checkout

POST/api/payments/portalauth

Open Stripe billing portal

Full interactive docs at api.stillhere.life/docs