← Files GlanceARCHIVED FILE

SKILL.md

3.75 KB · Nov 21, 2026 · 12:23 UTC

↓ Download file

---
name: glance-ingest
description: Push live content to a Glance widget with the ingest tool. XOR template_id vs inline_ui. OAuth only — never HTTP POST a write key.
---

# Glance ingest

Live widget updates from ChatGPT/Claude use the **`ingest` tool** (OAuth). Same class of tool as sending Gmail: the host runs it with the user's Glance token. Do **not** `curl` `/ingest/:feedId`.

## XOR (exactly one layout arm)

**Saved layout**

```json
{
  "feed_id": "<feed uuid>",
  "template_id": "<template uuid>",
  "content": {
    "headline": "Standup in 10 min"
  }
}
```

**UI on Demand (Pro+)** — full tree every ingest. Does not create a Layouts row.

```json
{
  "feed_id": "<feed uuid>",
  "inline_ui": {
    "tree": { "id": "root", "type": "container", "children": [] },
    "widget_size": "medium",
    "views": {
      "revenue": { "id": "rev", "type": "chart", "variant": "line", "x": "{{hours}}", "y": "{{revenue}}" }
    }
  },
  "content": {
    "headline": "Standup in 10 min",
    "hours": [9, 10, 11],
    "revenue": [12, 18, 15]
  }
}
```

Top-level `tree` is an alias for `inline_ui.tree`. Optional `inline_ui.views` is the same named-view map as `create_template`. Never send `template_id` with `inline_ui` or `tree`. If `get_plan.capabilities.ui_on_demand` is false, only `template_id`. Named views / `chart` / `grid` / `table` also need the matching `family_*` flag. `widget_size` may be `extra_large`. It must match the slot from `list_widgets`. If that slot is `extra_large` and `capabilities.extra_large_widget` is false, do not ingest. A template push and an inline layout are both rejected, and the last accepted content stays. Say Pro or Power. Do not retry.

- `content` keys are **binding names** (inside `{{ }}`), not Jira/GitHub field IDs. Arrays (`number[]`, `string[]`, `event[]`) are legal when the layout asked for them.
- Extra keys are dropped. Missing required bindings 400.
- Glance-pull automations: always `template_id`. Public / Discover widgets may use `inline_ui`; subscribers see the last push. Cloneable templates still need a saved layout (`template_id`).
- Do not tell the user you saved a layout when you used `inline_ui`.
- If the widget looks empty: they need the latest Glance app.

## On-device bootstrap (mandatory)

Apple Weather / Calendar / Reminders / Motion, and any later on-device source, **do not** write `feed_state`. After `create_automation`, call `ingest` once with `template_id` and placeholder `content` for every required binding. Live device readers overwrite the placeholders on the phone.

Then tell the user: Connect that source in Glance → Settings → Connected Services (if not already), **open Glance once**, then pin.

```json
{
  "feed_id": "<feed uuid>",
  "template_id": "<template uuid>",
  "content": {
    "events": [{ "start": "2026-09-03T09:00:00Z", "title": "Placeholder" }],
    "current_temp": "—",
    "steps_today": 0
  }
}
```

Include only the bindings that layout actually uses. Missing required keys 400. Do not treat this ingest as the live Calendar/Weather feed.

## Custom URL

A `custom_connection` does write `feed_state` on its schedule. Ingest once so the layout attaches, then do not keep ingesting over it. Do not put the key in `content`. Do not send them to Connected Services to tap Connect. A public feed is already saved. A keyed feed is ready after they paste the key. For JSON, `field_mapping` values are preview paths (`current.temperature_2m`, `c`). An empty JSON map is rejected. RSS may use `{}` when the bindings are the slot ids. Then tell them to **open Glance once** and pin.

## Write key HTTP (not you)

`POST {ingestUrl}` with `Authorization: Bearer <write_key>` is for Shortcuts, Make, n8n, Hermes. Same XOR. The write key is returned **once** from `create_dynamic_widget`. `get_widget_status` never returns it.

SHA-256: 76c82f8cfce16b6ab700b9bb0e27ece4410887097827a841bf13e9193425f1eb