code: func (wfe *WebFrontEndImpl) prepChallengeForDisplay(request *http.Request, authz core.Authorization, challenge *core.Challenge) {
  	// Update the challenge URL to be relative to the HTTP request Host
  	if authz.V2 {
  		challenge.URL = web.RelativeEndpoint(request, fmt.Sprintf("%sv2/%s/%s", challengePath, authz.ID, challenge.StringID()))
  	} else {
  		challenge.URL = web.RelativeEndpoint(request, fmt.Sprintf("%s%s/%d", challengePath, authz.ID, challenge.ID))
  	}
  	// Ensure the challenge URI and challenge ID aren't written by setting them to
  	// values that the JSON omitempty tag considers empty
  	challenge.URI = ""
  	challenge.ID = 0
  
  	// ACMEv2 never sends the KeyAuthorization back in a challenge object.
  	challenge.ProvidedKeyAuthorization = ""
  
  	// Historically the Type field of a problem was always prefixed with a static
  	// error namespace. To support the V2 API and migrating to the correct IETF
  	// namespace we now prefix the Type with the correct namespace at runtime when
  	// we write the problem JSON to the user. We skip this process if the
  	// challenge error type has already been prefixed with the V1ErrorNS.
  	if challenge.Error != nil && !strings.HasPrefix(string(challenge.Error.Type), probs.V1ErrorNS) {
  		challenge.Error.Type = probs.V2ErrorNS + challenge.Error.Type
  	}
  
  	// If the authz has been marked invalid, consider all challenges on that authz
  	// to be invalid as well.
  	if authz.Status == core.StatusInvalid {
  		challenge.Status = authz.Status
  	}
  }
docs: // prepChallengeForDisplay takes a core.Challenge and prepares it for display to
  // the client by filling in its URL field and clearing its ID and URI fields.