code: func CleanTenant(ctx context.Context, config tenantConfig, remove bool, options ...configuration.HTTPClientOption) error {
  
  	c, err := createClient(ctx, config, options...)
  	if err != nil {
  		return err
  	}
  
  	res, err := c.CleanTenant(goasupport.ForwardContextRequestID(ctx), tenant.CleanTenantPath(), &remove)
  	if err != nil {
  		return err
  	}
  	defer rest.CloseResponse(res)
  
  	// operation failed for some reason
  	if res.StatusCode < 200 || res.StatusCode >= 300 {
  		jsonErr, err := c.DecodeJSONAPIErrors(res)
  		if err == nil && len(jsonErr.Errors) > 0 {
  			return errors.FromStatusCode(res.StatusCode, jsonErr.Errors[0].Detail)
  		}
  		// if failed to decode the response body into a JSON-API error, or if the JSON-API error was empty
  		return errors.FromStatusCode(res.StatusCode, "unknown error")
  	}
  	// operation succeeded
  	return nil
  }
docs: // CleanTenant cleans out a tenant in oso.