Create a user Programmatically in Drupal 6.22
Looks like you've included the bootstrap.inc but you haven't actually bootstrapped drupal.

Example:

require_once(includes/bootstrap.inc);
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);