> For the complete documentation index, see [llms.txt](https://bsv.brc.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bsv.brc.dev/wallet/0164.md).

# Output Identity Tags for BRC-100 Wallets

David Case (<david.case@shruggr.cloud>)

## Abstract

This specification defines a **tag convention** for [BRC-100](/wallet/0100.md): an output tag prefix `id:` that carries a stable list key for a held output. Callers use it with ordinary `listOutputs` tag filters. It does not change the BRC-100 request or response shape, and it does not require special wallet storage behavior beyond normal tags.

## Motivation

Basket profiles and applications often need a stable handle for one wallet output — reload after restart, target a spend, correlate UI to storage — without scanning every row.

Stamping that handle as a normal, **queryable** tag under a short prefix makes `listOutputs` the lookup API, without new BRC-100 fields or pseudo-tag peel paths.

## Specification

### Tag form

This specification uses tags of the form:

```
id:<key>
```

* The prefix is exactly `id:` (lowercase, ASCII).
* `<key>` is a non-empty string chosen by the writer that stamps the tag (wallet or tool).
* Because reference BRC-100 clients commonly **trim and lowercase** tags before store and match, writers SHOULD use a case-insensitive alphabet for `<key>` (e.g. lowercase hex or decimal digits), and readers MUST treat tag equality as case-insensitive.

Tags beginning with `id:` are used for this output list-key role.

### Meaning

* `id:<key>` identifies a **held output row** for list and spend targeting inside that wallet storage.
* It is **not** a global asset id, token id, origin, outpoint, remittance field, or proof of ownership.
* Encoding of `<key>` is defined by the writer (e.g. decimal storage primary key, UUID). Only that writer must round-trip it.
* Uniqueness: `<key>` SHOULD be unique among that wallet’s held outputs (or a documented narrower scope such as per basket).
* Stability: for a given held row, `id:` SHOULD remain stable for the life of that row (including unproven / unmined outputs if they are listable).

### Behavior

`id:` is an ordinary BRC-100 output tag. No special `listOutputs` semantics, peel, inject, or foreign-tag overwrite is required of generic wallet storage.

Conforming **tools and wallets that adopt this profile** SHOULD:

1. Stamp `id:<key>` on the output when the row is created or first taken into custody (same path as any other tag).
2. Query with a full `id:<key>` tag via ordinary `tags` / `tagQueryMode`.
3. Treat `id:` as their own list key vocabulary — not as token id, origin, or on-chain identity. Basket profiles that need those notions use their own tags (e.g. `bsv21:<tokenId>`, `origin:…`).

Applications MAY read `id:<key>` from `listOutputs` (with `includeTags`) and reuse it in later filters or app state.

### Out of scope

* Changing BRC-100 method schemas or WalletWire encodings
* Basket names, token economics, or provenance proofs
* Requiring a particular key generation algorithm (UUID, counter, storage PK encoding, …)
* Mandating peel/inject or other non-tag storage paths in reference wallets

## Security considerations

* **Not authentication** — Knowing `id:<key>` only helps address a row inside a wallet that already authorized `listOutputs` / spend for that basket.
* **Authority** — The tag is only as trustworthy as the storage that stamped it. Counterparty remittance is not a substitute for the holding wallet’s (or tool’s) own stamp.
* **Case folding** — Assume tags are lowercased in storage; do not put case-sensitive secrets in `<key>`.
* **Ambiguity** — `id:` is short and may appear in other informal tag sets. Writers that need a stricter namespace MAY document a longer key form; this BRC does not reserve exclusivity of the two-letter prefix beyond the list-key meaning above for adopters.

## References

1. [BRC-100](/wallet/0100.md) — Unified Open BSV Wallet-to-Application Interface
2. [BRC-37](/outpoints/0037.md) — Basket and Custom Instructions Extension for Bitcoin Outpoints
3. [BRC-46](/wallet/0046.md) — Wallet Transaction Output Tracking (Output Baskets)
4. [BRC-153](/wallet/0153.md) — Action Reference Labels for BRC-100 Wallets
5. [BRC-147](/tokens/0147.md) — 1Sat Ordinals Basket Profile


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://bsv.brc.dev/wallet/0164.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
