Skip to main content

System requirements

WordPress

Version 6.0 or later

WooCommerce

Version 8.0 or later

PHP

Version 8.0 or later (7.4 minimum)

Database

MySQL 5.7+ or MariaDB 10.3+
If WooCommerce is not active when the plugin initializes, all plugin functionality is suppressed and an admin notice is displayed: UTB Product Builder requiere que WooCommerce esté instalado y activo.

Installation steps

1

Upload the ZIP

In the WordPress admin, go to Plugins → Add New → Upload Plugin and select the utb-product-builder.zip file. Click Install Now.Alternatively, extract the ZIP and upload the utb-product-builder/ folder to wp-content/plugins/ via FTP/SFTP.
2

Activate the plugin

Go to Plugins → Installed Plugins and click Activate next to UTB Product Builder.On activation, the plugin:
  • Creates the six database tables (see below).
  • Sets default option utb_pb_table_config.
  • Initializes utb_pb_flow_assignments as an empty array.
  • Creates the private uploads directory at WP_CONTENT_DIR/utb-private-uploads/ with .htaccess protection.
  • Calls flush_rewrite_rules().
3

Add required constants to wp-config.php

Open wp-config.php and add the following constants before the /* That's all, stop editing! */ line:
// UTB Product Builder
define( 'UTB_API_KEY', 'your-api-key-here' );        // Used for X-UTB-API-Key header auth on /wp-json/utb/v1/orders
define( 'UTB_WEBHOOK_SECRET', 'your-secret-here' );  // HMAC secret for outbound webhook signatures
define( 'UTB_API_LOGGING', true );                   // Enable access/auth-failure logging (disable in production if not needed)
ConstantRequiredDescription
UTB_API_KEYYesAuthenticates external requests to the REST API (X-UTB-API-Key header).
UTB_WEBHOOK_SECRETRecommendedSigns outbound webhook payloads with HMAC. Falls back to wp_salt('auth') if not set.
UTB_API_LOGGINGOptionalWhen true, logs successful API accesses to WP_CONTENT_DIR/utb-api-access.log and failed auth attempts to WP_CONTENT_DIR/utb-api-failed-auth.log.
4

Verify database tables were created

Go to UTB Builder → Dashboard. The plugin creates these tables on activation:
TablePurpose
wp_utb_certificatesAcademic certificate catalog
wp_utb_certificate_pricesCertificate pricing matrix (level × format)
wp_utb_programsAcademic programs for certificate requests
wp_utb_cep_programsCEP continuing education programs
wp_utb_cep_inscriptionsCEP enrollment log
wp_utb_webhook_logsOutbound webhook audit trail
If the tables are missing (e.g., after a ZIP upload that bypassed the activation hook), the plugin automatically re-creates them on the next plugins_loaded call when it detects utb_pb_db_version < 3.0.1.

Web server configuration for private uploads

Uploaded identity documents are stored in WP_CONTENT_DIR/utb-private-uploads/ and must not be publicly accessible.

Apache

The plugin writes an .htaccess file to the private uploads directory on activation:
# UTB Product Builder - Protección de archivos privados
Order Deny,Allow
Deny from all

# Bloquear listado de directorios
Options -Indexes
This is automatic on Apache servers. Verify by attempting to access a URL under /wp-content/utb-private-uploads/ directly — it must return a 403.

Nginx

Nginx does not read .htaccess files. You must add a location block to your site configuration. The plugin writes an example to WP_CONTENT_DIR/utb-private-uploads/nginx.conf.example:
location ~ ^/wp-content/utb-private-uploads/ {
    deny all;
    return 404;
}
Add this block to your server block, then reload Nginx:
sudo nginx -t
sudo systemctl reload nginx
On Nginx, if you skip this step, uploaded identity documents (PDFs, images) will be publicly accessible by URL. Always configure this block before going live.

Verify installation checklist

  • Admin notice absent — No “WooCommerce required” banner on the WordPress admin dashboard.
  • Tables created — All six wp_utb_* tables visible in the database.
  • Constants definedUTB_API_KEY and UTB_WEBHOOK_SECRET in wp-config.php.
  • Private uploads protected — Direct HTTP access to /wp-content/utb-private-uploads/ returns 403 (Apache) or 404 (Nginx).
  • REST API accessibleGET /wp-json/utb/v1/orders with X-UTB-API-Key: {UTB_API_KEY} returns 200.
  • CEP form renders — A product assigned to the utb_cep_programs flow displays the enrollment form.
  • Certificates form renders — A product assigned to certificados_academicos displays the certificate request form.
  • db_version option setutb_pb_db_version option equals 3.0.1 (check via Tools → Site Health → Info or wp option get utb_pb_db_version).

Build docs developers (and LLMs) love