# YouGot REST API Documentation > **Base URL:** `https://www.yougot.ai` > **Authentication:** Bearer token via `Authorization` header > **Available to:** Business tier subscribers Integrate YouGot reminders directly into your applications. Create, schedule, and manage reminders delivered via email, SMS, WhatsApp, web push, or webhooks. Support for recurring schedules, nag mode, live data fetching, natural language parsing, tags, sharing, and analytics is included. --- ## Table of Contents 1. [Authentication](#authentication) 2. [Quick Start](#quick-start) 3. [Endpoints](#endpoints) - [Create a Reminder](#create-a-reminder) — POST - [List Reminders](#list-reminders) — GET - [Get a Reminder](#get-a-reminder) — GET - [Update a Reminder](#update-a-reminder) — PATCH - [Delete a Reminder](#delete-a-reminder) — DELETE - [Snooze a Reminder](#snooze-a-reminder) — POST - [Pause a Reminder](#pause-a-reminder) — POST - [Resume a Reminder](#resume-a-reminder) — POST - [Skip Next Occurrence](#skip-next-occurrence) — POST - [Unskip](#unskip) — POST - [Stop Recurring](#stop-recurring) — POST - [Acknowledge (Nag Mode)](#acknowledge-nag-mode) — POST - [Toggle Nag Mode](#toggle-nag-mode) — POST - [Add a Tag](#add-a-tag) — POST - [Remove a Tag](#remove-a-tag) — DELETE - [Share a Reminder](#share-a-reminder) — POST - [Unshare a Reminder](#unshare-a-reminder) — DELETE - [Search Reminders](#search-reminders) — GET - [Delivery History](#delivery-history) — GET - [Statistics](#statistics) — GET - [Delivery Rate](#delivery-rate) — GET - [Parse Natural Language](#parse-natural-language) — POST 4. [Webhooks](#webhooks) - [List Webhooks](#list-webhooks) — GET - [Create Webhook](#create-webhook) — POST - [Delete Webhook](#delete-webhook) — DELETE - [Webhook Payload and Signatures](#webhook-payload-and-signatures) 5. [Phone Numbers](#phone-numbers) - [List Verified Phone Numbers](#list-verified-phone-numbers) — GET 6. [Object Reference](#object-reference) - [Recurrence Object](#recurrence-object) - [Nag Mode Object](#nag-mode-object) - [Data Fetch Object](#data-fetch-object) 7. [Error Reference](#error-reference) --- ## Authentication All requests require a valid API key sent as a Bearer token in the `Authorization` header. 1. Go to **Dashboard -> API Keys** to generate a key. 2. Include the key in every request. 3. Monitor usage via the `X-RateLimit-Remaining` response header. ```bash curl https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch("https://www.yougot.ai/api/v1/reminders", { headers: { Authorization: "Bearer yg_your_api_key_here", }, }); const data = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders", headers={"Authorization": "Bearer yg_your_api_key_here"}, ) data = res.json() ``` --- ## Quick Start ### Step 1 — Get your API key Navigate to **Dashboard -> API Keys** and create a new key. Copy it somewhere safe — it is only shown once. ### Step 2 — Create your first reminder ```bash curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Review pull request from Anna", "scheduledAt": "2026-04-01T10:00:00Z", "channel": "email" }' ``` ```javascript const res = await fetch("https://www.yougot.ai/api/v1/reminders", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ message: "Review pull request from Anna", scheduledAt: "2026-04-01T10:00:00Z", channel: "email", }), }); const reminder = await res.json(); console.log(reminder.id); ``` ```python import requests res = requests.post( "https://www.yougot.ai/api/v1/reminders", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, json={ "message": "Review pull request from Anna", "scheduledAt": "2026-04-01T10:00:00Z", "channel": "email", }, ) reminder = res.json() print(reminder["id"]) ``` ### Step 3 — Verify it was created ```bash curl https://www.yougot.ai/api/v1/reminders?status=pending \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders?status=pending", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { data, count } = await res.json(); console.log(`${count} pending reminders`); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"status": "pending"}, ) data = res.json() print(f"{data['count']} pending reminders") ``` --- ## Endpoints ### Create a Reminder **POST** `/api/v1/reminders` Create a new reminder. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | message | string | Yes | The reminder message text | | scheduledAt | number \| string | Yes | Unix timestamp (ms) or ISO 8601 string | | channel | string | No | "email", "sms", "whatsapp", "webhook", "web_push", "calendar". Defaults to user's default. "calendar" needs Plus and a connected Google Calendar | | additionalChannels | string[] | No | Extra channels to deliver on simultaneously | | recurrence | object | No | Recurring schedule (see Recurrence Object) | | tags | string[] | No | Tags for organization, e.g. ["work", "meeting"] | | metadata | object | No | Arbitrary key-value metadata | | nagMode | object | No | Persistent nagging until acknowledged (see Nag Mode Object) | | targetPhone | string | No | Phone number for SMS/WhatsApp delivery (must be verified) | | targetWebhookId | string | No | Webhook endpoint ID for webhook delivery | | dataFetch | object | No | Live data to include at delivery time (see Data Fetch Object) | | notifyBeforeMs | number | No | Send notification early by this many milliseconds | | recipientIds | string[] | No | User IDs to receive this reminder. Omit for a personal reminder (delivered only to you). Any non-self recipient must be an active member of your group and requires a Plus or Business plan. | #### Example ```bash # One-time email reminder curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Call the dentist", "scheduledAt": "2026-04-01T14:00:00Z", "channel": "email" }' # Daily recurring with nag mode curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Take your medication", "scheduledAt": "2026-04-01T08:00:00Z", "channel": "email", "recurrence": { "type": "daily", "description": "Daily at 8am" }, "nagMode": {"enabled": true, "intervalMs": 600000}, "tags": ["health"] }' # Weekday recurring via cron with live data curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Check Bitcoin price", "scheduledAt": "2026-04-01T09:00:00Z", "channel": "email", "recurrence": { "type": "custom", "cronExpression": "0 9 * * 1-5", "description": "Weekdays at 9am" }, "dataFetch": {"type": "crypto", "query": "bitcoin"} }' # Send to another group member (Plus or Business plan) curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Take your blood pressure medication", "scheduledAt": "2026-04-01T09:00:00Z", "channel": "sms", "recipientIds": ["jd72n90trzymythbqr3xw62d6s82284k"] }' # Send to the whole group (creator + every active member) curl -X POST https://www.yougot.ai/api/v1/reminders \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "message": "Trash night", "scheduledAt": "2026-04-01T19:00:00Z", "channel": "email", "recipientIds": [ "jd7ffzb3r1hdd28ffxvdeacbcs836cep", "jd72n90trzymythbqr3xw62d6s82284k" ] }' ``` ```javascript const res = await fetch("https://www.yougot.ai/api/v1/reminders", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ message: "Call the dentist", scheduledAt: "2026-04-01T14:00:00Z", channel: "email", }), }); const reminder = await res.json(); // reminder.id, reminder.status === "pending" // Daily recurring with nag mode const recurring = await fetch("https://www.yougot.ai/api/v1/reminders", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ message: "Take your medication", scheduledAt: "2026-04-01T08:00:00Z", channel: "email", recurrence: { type: "daily", description: "Daily at 8am" }, nagMode: { enabled: true, intervalMs: 600000 }, tags: ["health"], }), }); ``` ```python import requests # One-time reminder res = requests.post( "https://www.yougot.ai/api/v1/reminders", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, json={ "message": "Call the dentist", "scheduledAt": "2026-04-01T14:00:00Z", "channel": "email", }, ) reminder = res.json() # Daily recurring with nag mode res = requests.post( "https://www.yougot.ai/api/v1/reminders", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, json={ "message": "Take your medication", "scheduledAt": "2026-04-01T08:00:00Z", "channel": "email", "recurrence": {"type": "daily", "description": "Daily at 8am"}, "nagMode": {"enabled": True, "intervalMs": 600000}, "tags": ["health"], }, ) ``` #### Response ```json { "id": "j97ekxp8040amr2hzfss...", "message": "Call the dentist", "scheduledAt": 1743519600000, "channel": "email", "status": "pending", "recipientIds": ["jd7ffzb3r1hdd28ffxvdeacbcs836cep"], "userId": "jd7ffzb3r1hdd28ffxvdeacbcs836cep" } ``` > `recipientIds` echoes who will receive the reminder. When you omit it on create, it defaults to `[userId]` (personal reminder). When you send to other group members, both the creator and each recipient see it and each gets an independent acknowledgement state. #### Error responses | HTTP | `error` | When | |------|----------|------| | 400 | `Sending reminders to other people requires a Plus or Business plan.` | Free/Pro caller passed non-self `recipientIds` | | 400 | `You are not part of a group. Invite members before sending reminders to others.` | Caller has no active group membership but tried to add other recipients | | 400 | `One or more recipients are not active members of your group.` | A recipient id is not in the caller's group (or was removed) | | 400 | `Invalid value "..." for field "recipientIds[0]"` | A recipient id is not a valid Convex user id | --- ### List Reminders **GET** `/api/v1/reminders` List your reminders. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | status | string | No | Filter: pending, delivered, failed, snoozed, cancelled, paused, stopped | | limit | number | No | Max results (default: 50, max: 100) | #### Example ```bash curl "https://www.yougot.ai/api/v1/reminders?status=pending&limit=10" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders?status=pending&limit=10", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { data, count } = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"status": "pending", "limit": 10}, ) data = res.json() ``` #### Response ```json { "data": [ { "_id": "j974w117n0pz76e5kbhg7ma11n84fdfa", "message": "Take your blood pressure medication", "scheduledAt": 1743519600000, "channel": "sms", "status": "pending", "recipientIds": [ "jd7ffzb3r1hdd28ffxvdeacbcs836cep", "jd72n90trzymythbqr3xw62d6s82284k" ], "userId": "jd7ffzb3r1hdd28ffxvdeacbcs836cep", "tags": ["health"] } ], "count": 15 } ``` > Each row includes `recipientIds` (who gets this reminder) and `userId` (the creator). Personal reminders have `recipientIds: [userId]`. The list returns reminders where you are the creator; to see reminders sent to you, use a client-side filter on `userId !== me && recipientIds.includes(me)` or query the Sent-by-me view in the dashboard. --- ### Get a Reminder **GET** `/api/v1/reminder?id=REMINDER_ID` Get a single reminder by ID. #### Example ```bash curl "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const reminder = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminder", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"id": "REMINDER_ID"}, ) reminder = res.json() ``` --- ### Update a Reminder **PATCH** `/api/v1/reminder?id=REMINDER_ID` Update a reminder. Only include fields you want to change. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | message | string | No | Updated message text | | scheduledAt | number \| string | No | New delivery time (reschedules the job) | | channel | string | No | Change primary channel | | additionalChannels | string[] | No | Change additional channels | | tags | string[] | No | Replace all tags | | metadata | object | No | Replace metadata | | nagMode | object | No | Enable/disable nag mode | | notifyBeforeMs | number | No | Early notification offset | #### Example ```bash curl -X PATCH "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"message": "Updated: call the dentist at 3pm", "tags": ["urgent"]}' ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID", { method: "PATCH", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ message: "Updated: call the dentist at 3pm", tags: ["urgent"], }), } ); ``` ```python import requests res = requests.patch( "https://www.yougot.ai/api/v1/reminder", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, json={"message": "Updated: call the dentist at 3pm", "tags": ["urgent"]}, ) ``` --- ### Delete a Reminder **DELETE** `/api/v1/reminder?id=REMINDER_ID` Cancel and delete a reminder. #### Example ```bash curl -X DELETE "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminder?id=REMINDER_ID", { method: "DELETE", headers: { Authorization: "Bearer yg_your_api_key_here" }, } ); ``` ```python import requests res = requests.delete( "https://www.yougot.ai/api/v1/reminder", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"id": "REMINDER_ID"}, ) ``` #### Response ```json {"success": true} ``` --- ### Snooze a Reminder **POST** `/api/v1/reminder/snooze?id=REMINDER_ID` Snooze a reminder to a later time. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | duration | string \| number | Yes | "15m", "1h", "3h", "tomorrow", or a number (minutes) | #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/snooze?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"duration": "1h"}' ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminder/snooze?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ duration: "1h" }), } ); const { newScheduledAt } = await res.json(); ``` ```python import requests res = requests.post( "https://www.yougot.ai/api/v1/reminder/snooze", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, json={"duration": "1h"}, ) print(res.json()["newScheduledAt"]) ``` #### Response ```json {"success": true, "newScheduledAt": 1743523200000} ``` --- ### Pause a Reminder **POST** `/api/v1/reminder/pause?id=REMINDER_ID` Pause a pending reminder or all pending occurrences in a recurring series. No request body needed. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/pause?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/pause?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/pause", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Resume a Reminder **POST** `/api/v1/reminder/resume?id=REMINDER_ID` Resume a paused or stopped reminder. Reschedules future occurrences. No request body needed. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/resume?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/resume?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/resume", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Skip Next Occurrence **POST** `/api/v1/reminder/skip?id=REMINDER_ID` Skip the next recurring occurrence. Only works on recurring reminders with status `pending` or `paused`. Skips the next occurrence and schedules the one after. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/skip?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/skip?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/skip", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Unskip **POST** `/api/v1/reminder/unskip?id=REMINDER_ID` Re-enable a previously skipped (cancelled) recurring occurrence, if it is still in the future. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/unskip?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/unskip?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/unskip", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Stop Recurring **POST** `/api/v1/reminder/stop?id=REMINDER_ID` Stop all future recurring occurrences. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/stop?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/stop?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/stop", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Acknowledge (Nag Mode) **POST** `/api/v1/reminder/acknowledge?id=REMINDER_ID` Stops nag mode for a reminder. The reminder is marked as delivered and nagging stops. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/acknowledge?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/acknowledge?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/acknowledge", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) ``` --- ### Toggle Nag Mode **POST** `/api/v1/reminder/nag?id=REMINDER_ID` Enable or disable nag mode on a reminder. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | enabled | boolean | Yes | true to enable, false to disable | | intervalMs | number | No | Nag interval in ms (default: 300000 = 5 min) | #### Example ```bash # Enable nag mode curl -X POST "https://www.yougot.ai/api/v1/reminder/nag?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"enabled": true, "intervalMs": 600000}' # Disable nag mode curl -X POST "https://www.yougot.ai/api/v1/reminder/nag?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"enabled": false}' ``` ```javascript // Enable nag mode await fetch( "https://www.yougot.ai/api/v1/reminder/nag?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ enabled: true, intervalMs: 600000 }), } ); // Disable nag mode await fetch( "https://www.yougot.ai/api/v1/reminder/nag?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ enabled: false }), } ); ``` ```python import requests # Enable nag mode requests.post( "https://www.yougot.ai/api/v1/reminder/nag", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, json={"enabled": True, "intervalMs": 600000}, ) # Disable nag mode requests.post( "https://www.yougot.ai/api/v1/reminder/nag", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, json={"enabled": False}, ) ``` --- ### Add a Tag **POST** `/api/v1/reminder/tag?id=REMINDER_ID` Add a tag to a reminder. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | tag | string | Yes | Tag name (auto-lowercased, duplicates ignored) | #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/tag?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"tag": "work"}' ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/tag?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ tag: "work" }), } ); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/reminder/tag", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, json={"tag": "work"}, ) ``` --- ### Remove a Tag **DELETE** `/api/v1/reminder/tag?id=REMINDER_ID&tag=TAG_NAME` Remove a tag from a reminder. #### Example ```bash curl -X DELETE "https://www.yougot.ai/api/v1/reminder/tag?id=REMINDER_ID&tag=work" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/tag?id=REMINDER_ID&tag=work", { method: "DELETE", headers: { Authorization: "Bearer yg_your_api_key_here" }, } ); ``` ```python import requests requests.delete( "https://www.yougot.ai/api/v1/reminder/tag", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"id": "REMINDER_ID", "tag": "work"}, ) ``` --- ### Share a Reminder **POST** `/api/v1/reminder/share?id=REMINDER_ID` Generate a shareable link. Idempotent — returns the existing code if already shared. #### Example ```bash curl -X POST "https://www.yougot.ai/api/v1/reminder/share?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminder/share?id=REMINDER_ID", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, } ); const { shareCode, shareUrl } = await res.json(); ``` ```python import requests res = requests.post( "https://www.yougot.ai/api/v1/reminder/share", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, params={"id": "REMINDER_ID"}, ) data = res.json() print(data["shareUrl"]) ``` #### Response ```json { "shareCode": "9efea664", "shareUrl": "https://www.yougot.ai/r/9efea664" } ``` --- ### Unshare a Reminder **DELETE** `/api/v1/reminder/share?id=REMINDER_ID` Deactivate the share link. #### Example ```bash curl -X DELETE "https://www.yougot.ai/api/v1/reminder/share?id=REMINDER_ID" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/reminder/share?id=REMINDER_ID", { method: "DELETE", headers: { Authorization: "Bearer yg_your_api_key_here" }, } ); ``` ```python import requests requests.delete( "https://www.yougot.ai/api/v1/reminder/share", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"id": "REMINDER_ID"}, ) ``` --- ### Search Reminders **GET** `/api/v1/reminders/search` Full-text search across reminders. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | q | string | Yes | Search text (matches message and tags) | | status | string | No | Filter by status | | limit | number | No | Max results (default: 50, max: 100) | #### Example ```bash curl "https://www.yougot.ai/api/v1/reminders/search?q=dentist&status=pending" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders/search?q=dentist&status=pending", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { data, count } = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders/search", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"q": "dentist", "status": "pending"}, ) data = res.json() ``` --- ### Delivery History **GET** `/api/v1/reminders/history` Get delivery history. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | limit | number | No | Max results (default: 50, max: 200) | #### Example ```bash curl "https://www.yougot.ai/api/v1/reminders/history?limit=20" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders/history?limit=20", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { data } = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders/history", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"limit": 20}, ) data = res.json() ``` --- ### Statistics **GET** `/api/v1/reminders/stats` Get reminder statistics. #### Example ```bash curl https://www.yougot.ai/api/v1/reminders/stats \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders/stats", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const stats = await res.json(); // { total, pending, delivered, failed, cancelled, paused } ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders/stats", headers={"Authorization": "Bearer yg_your_api_key_here"}, ) stats = res.json() ``` #### Response ```json { "total": 50, "pending": 15, "delivered": 14, "failed": 9, "cancelled": 8, "paused": 4 } ``` --- ### Delivery Rate **GET** `/api/v1/reminders/delivery-rate` Get delivery success rate. #### Example ```bash curl https://www.yougot.ai/api/v1/reminders/delivery-rate \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/reminders/delivery-rate", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { successful, total, rate } = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/reminders/delivery-rate", headers={"Authorization": "Bearer yg_your_api_key_here"}, ) data = res.json() print(f"Delivery rate: {data['rate']}%") ``` #### Response ```json { "successful": 14, "total": 23, "rate": 61 } ``` --- ### Parse Natural Language **POST** `/api/v1/parse` Parse natural language into structured reminder data without creating the reminder. Supports any language. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | text | string | Yes | Natural language input, e.g. "remind me tomorrow at 9am to call mom" | | timezone | string | No | IANA timezone, e.g. "America/New_York". Defaults to user's stored timezone | #### Example ```bash curl -X POST https://www.yougot.ai/api/v1/parse \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"text": "every weekday at 9am review priorities", "timezone": "America/New_York"}' ``` ```javascript const res = await fetch("https://www.yougot.ai/api/v1/parse", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ text: "every weekday at 9am review priorities", timezone: "America/New_York", }), }); const parsed = await res.json(); // { message, scheduledAt, recurrence, channel, tags, ... } ``` ```python import requests res = requests.post( "https://www.yougot.ai/api/v1/parse", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, json={ "text": "every weekday at 9am review priorities", "timezone": "America/New_York", }, ) parsed = res.json() ``` #### Response ```json { "message": "review priorities", "scheduledAt": "2026-03-24T14:00:00.000Z", "recurrence": { "type": "custom", "cronExpression": "0 9 * * 1-5", "description": "Every weekday at 9am" }, "channel": null, "tags": ["work"], "nagMode": null, "dataFetch": null } ``` --- ## Webhooks Register endpoints, then create reminders with `channel: "webhook"`. When one fires, YouGot sends a signed `reminder.fired` request to the endpoint in `targetWebhookId`, or to every active endpoint if you leave it out. Webhooks are scheduled delivery targets — there are no delivery, failure or acknowledgement event subscriptions. ### List Webhooks **GET** `/api/v1/webhooks` List all registered webhooks. #### Example ```bash curl https://www.yougot.ai/api/v1/webhooks \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/webhooks", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const webhooks = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/webhooks", headers={"Authorization": "Bearer yg_your_api_key_here"}, ) webhooks = res.json() ``` --- ### Create Webhook **POST** `/api/v1/webhooks` Register a new webhook endpoint. #### Parameters | Field | Type | Required | Description | |-------|------|----------|-------------| | url | string | Yes | The URL to receive webhook POST requests | Returns `201` with `{ "id": "…", "secret": "…" }`. Store the secret now — it is the key for verifying `X-YouGot-Signature`. #### Example ```bash curl -X POST https://www.yougot.ai/api/v1/webhooks \ -H "Authorization: Bearer yg_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{"url": "https://your-server.com/webhook"}' ``` ```javascript const res = await fetch("https://www.yougot.ai/api/v1/webhooks", { method: "POST", headers: { Authorization: "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, body: JSON.stringify({ url: "https://your-server.com/webhook" }), }); ``` ```python import requests requests.post( "https://www.yougot.ai/api/v1/webhooks", headers={ "Authorization": "Bearer yg_your_api_key_here", "Content-Type": "application/json", }, json={"url": "https://your-server.com/webhook"}, ) ``` --- ### Delete Webhook **DELETE** `/api/v1/webhooks?id=WEBHOOK_ID` Remove a webhook endpoint. #### Example ```bash curl -X DELETE "https://www.yougot.ai/api/v1/webhooks?id=WEBHOOK_ID" \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript await fetch( "https://www.yougot.ai/api/v1/webhooks?id=WEBHOOK_ID", { method: "DELETE", headers: { Authorization: "Bearer yg_your_api_key_here" }, } ); ``` ```python import requests requests.delete( "https://www.yougot.ai/api/v1/webhooks", headers={"Authorization": "Bearer yg_your_api_key_here"}, params={"id": "WEBHOOK_ID"}, ) ``` ### Webhook Payload and Signatures POST with `Content-Type: application/json`. The only event values are `reminder.fired` and `webhook.test` (sent by the dashboard's test button, with only `data.message`). ```json { "event": "reminder.fired", "timestamp": "2026-04-09T17:00:00.000Z", "data": { "reminderId": "j97ekxp8040amr2hzfss8v9k1h7e2a3r", "message": "Submit expense report", "scheduledAt": 1775754000000, "isRecurring": true, "recurrence": { "type": "weekly", "interval": 1, "intervalMs": 604800000, "description": "Every Thursday at 10am", "endDate": null, "nextOccurrenceAt": 1776358800000 }, "metadata": { "team": "finance" }, "recipientIds": ["u_2h8fk3lmn0pqrs"] } } ``` | Field | Type | Description | |-------|------|-------------| | event | string | "reminder.fired" or "webhook.test" | | timestamp | string | ISO 8601 time this request was built. A retry gets a new timestamp | | data.reminderId | string | The reminder that fired. Retries resend the same reminderId and scheduledAt; a snoozed reminder fires again with the same reminderId and a new scheduledAt | | data.message | string | The reminder text | | data.scheduledAt | number | Unix timestamp (ms) the reminder was scheduled for | | data.isRecurring | boolean | Whether the reminder repeats | | data.recurrence | object \| null | type, interval, intervalMs, description, endDate and nextOccurrenceAt (ms or null). null for one-off reminders | | data.metadata | object \| null | Endpoint metadata merged with reminder metadata (reminder wins). null when both are empty | | data.recipientIds | string[] | Who the reminder is for. Defaults to the creator for personal reminders | **Smart calendar reminders.** When a reminder was created automatically from an event on the user's connected Google Calendar, `data` also carries `source: "google_calendar"` and `calendarEvent: { id, title, start }` (`start` is the event's own Unix ms time). Both fields are absent on every other reminder. Treat `calendarEvent.title` as untrusted display text. #### Verifying the signature Every POST carries `X-YouGot-Signature`: the lowercase hex HMAC-SHA256 of the exact raw request body, keyed with your endpoint secret. Use the secret string as-is (it is not hex-decoded). Compute the HMAC before parsing the JSON and compare in constant time. No timestamp is signed, so de-duplicate on `reminderId` + `scheduledAt` — not `timestamp`, which changes on every retry. ```javascript import { createHmac, timingSafeEqual } from "node:crypto"; // rawBody: the request body as a Buffer/string, before JSON.parse function isValidYouGotSignature(rawBody, header, secret) { const expected = createHmac("sha256", secret).update(rawBody).digest("hex"); const given = String(header ?? ""); return given.length === expected.length && timingSafeEqual(Buffer.from(given), Buffer.from(expected)); } ``` ```python import hashlib, hmac def is_valid_yougot_signature(raw_body: bytes, header: str, secret: str) -> bool: expected = hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest() return hmac.compare_digest(expected, header or "") ``` #### Retries and GET endpoints Any 2xx response counts as delivered. A non-2xx response, a redirect, or no response within 10 seconds is retried — up to 4 attempts in total, roughly 1, 5 and 30 minutes apart. Endpoints set to GET in the dashboard receive `event`, `reminderId`, `message`, `scheduledAt`, optional `metadata` (JSON string) and `signature` as query parameters. That signature is computed over the JSON body a POST would carry, which a GET receiver never sees — use POST if you need to verify requests. --- ## Phone Numbers ### List Verified Phone Numbers **GET** `/api/v1/phones` List all verified phone numbers for the authenticated user. Use the `phone` value as `targetPhone` when creating SMS/WhatsApp reminders. #### Example ```bash curl https://www.yougot.ai/api/v1/phones \ -H "Authorization: Bearer yg_your_api_key_here" ``` ```javascript const res = await fetch( "https://www.yougot.ai/api/v1/phones", { headers: { Authorization: "Bearer yg_your_api_key_here" } } ); const { data } = await res.json(); ``` ```python import requests res = requests.get( "https://www.yougot.ai/api/v1/phones", headers={"Authorization": "Bearer yg_your_api_key_here"}, ) phones = res.json()["data"] ``` #### Response ```json { "data": [ { "_id": "abc123", "phone": "+12025551234", "label": "Personal", "countryCode": "US", "isPrimary": true, "verifiedAt": 1711375200000 } ] } ``` --- ## Object Reference ### Recurrence Object Used in the `recurrence` field when creating a reminder. | Field | Type | Required | Description | |-------|------|----------|-------------| | type | string | Yes | "daily", "weekly", "monthly", or "custom" | | interval | number | No | Repeat every N periods (e.g. 2 = every other day) | | dayOfWeek | number | No | Day of week for weekly: 0=Sun, 1=Mon, ... 6=Sat | | dayOfMonth | number | No | Day of month for monthly: 1-31 | | cronExpression | string | No | Cron expression for custom schedules, e.g. "0 9 * * 1-5" | | intervalMs | number | No | Interval in ms for sub-daily recurrence | | endDate | number | No | Unix timestamp (ms) when recurrence stops | | description | string | No | Human-readable label, e.g. "Every weekday at 9am" | **Note:** The API automatically sanitizes recurrence input. If you pass `dayOfWeek` as an array, it will be converted to a cron expression using the hour from `scheduledAt`. For best results, use explicit `cronExpression` values. --- ### Nag Mode Object Used in the `nagMode` field when creating or updating a reminder. | Field | Type | Required | Description | |-------|------|----------|-------------| | enabled | boolean | Yes | Enable persistent nagging | | intervalMs | number | No | Nag interval in ms (default: 300000 = 5 minutes) | --- ### Data Fetch Object Used in the `dataFetch` field when creating a reminder. Attaches live data at delivery time. | Field | Type | Required | Description | |-------|------|----------|-------------| | type | string | Yes | "crypto", "weather", "stock", or "web_search" | | query | string | Yes | What to look up, e.g. "bitcoin", "New York", "AAPL" | --- ## Error Reference All errors return JSON in the format: `{"error": "Description"}` | Status | Meaning | |--------|---------| | 400 | Bad request -- missing or invalid parameters | | 401 | Unauthorized -- missing or invalid API key | | 403 | Forbidden -- not authorized for this resource, or tier too low | | 404 | Not found | | 429 | Rate limit exceeded (retry after Retry-After header) | | 500 | Server error |