Prepare Your Web Site For Testing

In Optimize, a site identifies a domain under which a collection of web pages are organized.

Add a dedicated site for each unique web domain you want to use for testing.
Note: In order to add or edit a site you must have Site Manager user permissions.
  1. From the navigation menu, click Library.
  2. Select the Sites tab and then click New Site.
  3. Enter a name, description, and the primary domain name where testing will occur. To allow testing of web pages in all subdomains, use the domain root for the primary domain name. For example, instead of or

    A primary domain name can also be a host name with no top level domain designation, if your local DNS can resolve it (http://staging), or an IP address with the appropriate HTTP protocol (

  4. (optional) Enter the location of the web server where you plan to upload the Webtrends Client API file (wt_capi.js). Use the full URL. For example,
  5. (Advanced Settings) Select Use a custom cookie domain if you want to specify a domain within which the cookie applies. Only websites in this domain will be able to retrieve the cookie. Typically this field is left blank and the cookie domain is automatically set to the primary domain you entered earlier.
  6. Enter any additional domain or sub-domain you want to read cookies during testing and click Add Domain to include in the list below.
  7. Click Next.
  8. Click Download and save the code package to your computer. The code package contains the Webtrends Client API file (wt_capi.js), software license agreement, and an HTML file with instructions on how to upload the file to your web server and prepare your web pages for testing.
  9. Unzip the code package, locate the CAPI file (wt_capi.js), and upload it to your web server. The location on the web server does not have to be in the same directory as your test pages. A typical directory is a JavaScript (js) or scripts folder, for example,
  10. Return to Optimize and click Verify to confirm that the CAPI file is working correctly. If you did not enter a location for the CAPI file when you added the site, you will see the error "CAPI location undefined." Return to the Primary Properties section and enter a location.
  11. Click Finish.