code: def default_endpoint(ctx, param, value):
      
      if ctx.resilient_parsing:
          return
  
      config = ctx.obj['config']
      endpoint = default_endpoint_from_config(config, option=value)
  
      if endpoint is None:
          raise click.UsageError('No default endpoint found.')
  
      return endpoint
docs: Return default endpoint if specified.