REST API · v1

API overview

Base path: /api/v1 on the same host as your Mailofly app. All resource routes require a valid API key unless noted. Full endpoint detail lives on each resource page in this section.

Discovery

GET /api/v1 returns JSON describing available resources. No authentication.

Request
GET https://your-deployment.example/api/v1
Accept: application/json

Authentication

Header: Authorization: Bearer <key>. Keys use the mf_live_ prefix. Create keys in the app: API keys.

Example header
Authorization: Bearer mf_live_…
  • 401 when the key is missing, invalid, or expired.
  • Server needs SUPABASE_SERVICE_ROLE_KEY to validate keys.

Responses & errors

Successful reads typically return { "data": … }. Creates return 201 with data. Errors return 4xx/5xx with JSON such as:

{
  "error": "Unauthorized",
  "message": "Invalid API key"
}

Resources