package clinic_internal_api

import "context"

// BYOCDiagnosisTarget is the capability-neutral name for the server-resolved
// BYOC O11y diagnosis target. It remains an alias of SlowQueryTarget so new
// diagnosis readers reuse the already validated wire contract without changing
// existing Slow Query behavior.
type BYOCDiagnosisTarget = SlowQueryTarget

// BYOCDiagnosisTargetHeaders is the complete allowlist of server-resolved BYOC
// routing values that a diagnosis reader may send to O11y.
type BYOCDiagnosisTargetHeaders = SlowQueryTargetHeaders

// GetBYOCDiagnosisTarget resolves the shared BYOC O11y diagnosis target for an
// owned organization and cluster. The internal endpoint keeps its established
// slow-query path for wire compatibility; target validation is delegated to the
// existing typed client contract.
func (c *Client) GetBYOCDiagnosisTarget(
	ctx context.Context,
	orgID uint64,
	clusterID string,
) (*BYOCDiagnosisTarget, error) {
	return c.GetSlowQueryTarget(ctx, orgID, clusterID)
}
