Files
Simon Law f3ec43d7dd cmd/tailscale/tsdnsjsonv0: extract a new package for tailscale dns --json (#20017)
This patch extracts all the DNS related JSON handling from the
cmd/tailscale/jsonoutput package into a new tsdnsjsonv0 package.

It adds package documentation for tsdnsjsonv0 with a big WARNING that
this is an unstable format with no backwards compatibility guarantees.
When we stabilize this format, we should spin off a new tsdnsjsonv1
package that uses jsonoutput.ResponseEnvelope to declare version 1.

Updates #13326
Updates #18750

Signed-off-by: Simon Law <[email protected]>
2026-07-27 13:59:29 -07:00

15 lines
532 B
Go

// Copyright (c) Tailscale Inc & contributors
// SPDX-License-Identifier: BSD-3-Clause
// Package tsdnsjsonv0 provides types for unmarshalling the JSON output of the
// "tailscale dns --json" command:
//
// - [QueryResponse] will unmarshal the output of "tailscale dns query --json=1"
// - [StatusResponse] will unmarshal the output of "tailscale dns status --json=1".
//
// # WARNING: unstable
//
// Format is "v0" and is subject to change.
// There is no guarantee of backwards or forwards compatibility.
package tsdnsjsonv0