PhraseryPhrasery homeGet Phrasery
Documentation21 categories

Generate API reference from this code

A module whose public surface needs documenting properly, not just typed.

Longapireferencegeneration
Produce reference documentation for the public API in the code below.

For each exported function, class, or endpoint:
- **Signature**, exactly as callers see it
- **What it does**, one sentence, starting with a verb
- **Parameters**: name, type, required or optional, default, and what an invalid value does
- **Returns**: type and shape, including what is returned on the empty or no-match case
- **Throws or errors**: every error condition, with the exact error type or status code
- **Example**: a realistic call with realistic values, never `foo` and `bar`
- **Notes**: side effects, idempotency, rate limits, whether it mutates its arguments

Document only what is exported. Do not document internals. Where the code does not make a behaviour clear (error cases, nullability, ordering guarantees), list it as an open question rather than guessing.

Code:

Making it yours

  • Paste your own material where the prompt asks for it. Everything above that line is instruction, not content.
  • Delete any rule that does not apply to you. A shorter prompt that fits beats a thorough one that does not.
  • If the answer comes back vague, add a line saying what you do not want. Constraints work better than encouragement.

Reference and API docs. The lookup layer: function docs, config options, error codes and examples worth copying.

Related prompts

Keep this one

Phrasery saves prompts with a right-click and puts them back the same way. Add this to your own library in one click.

Add to your browser โ€” free