URI Template Builder (RFC 6570)

RFC 6570 URI templates are the standard for defining parameterized URLs (used by GitHub API, OAuth, OpenAPI). Templates like /users/{id}/repos{?type,sort} expand to concrete URLs based on variables. This tool tests templates and their expansions.

How to use the URI Template Builder (RFC 6570)

Enter an RFC 6570 URI template using {variable} expressions, then supply the variable values as JSON. The tool expands the template and shows the resulting URL, handling simple values, query parameters, and list or map expansions according to the spec.

Expanding RFC 6570 URI templates

RFC 6570 URI templates are the standard way APIs describe parameterized URLs — GitHub, OAuth, and OpenAPI all use them. A template like /users/{id}/repos{?type,sort} isn't a plain string with placeholders; the operators (?, #, /, and others) control exactly how variables expand into path segments and query strings.

This builder takes a template and a set of variable values and shows the concrete URL it expands to, including how lists and maps are serialized. It's a fast way to confirm a template behaves before you wire it into client code. To pick apart an existing API spec that uses these templates, see the OpenAPI viewer.

Common use cases

  • API clients — verify a template expands to the URL you expect.
  • Learning RFC 6570 — see how each operator changes expansion.
  • Query building — confirm optional parameters serialize correctly.
  • List and map values — test how arrays and objects expand.
  • Debugging — reproduce a malformed URL from its template.

Frequently asked questions

What is a URI template?

An RFC 6570 string with {variable} expressions that expand into a URL. Operators like {?x} control whether a value becomes a path segment, a query parameter, and so on.

How do I supply values?

As JSON. Strings, lists, and maps are all supported, and the tool serializes each according to the template operator.

Which operators are handled?

The RFC 6570 set — simple expansion plus reserved (+), fragment (#), path (/), and query (?, &) forms.

Where are URI templates used?

In API specs and hypermedia — GitHub's API, OAuth endpoints, and OpenAPI all describe URLs as RFC 6570 templates.
Embed this tool on your site

Free to embed, no attribution required (but appreciated). Paste this where you want the tool to appear: