Look at the following snippet. There was a small bug in xotcl-core (using the not-fully qualified attribute name "package_id" clashed for this case) which i have fixed just now in cvs head.
set package_id 1762
::xo::db::Class get_class_from_db -object_type apm_package
::xo::db::Class get_instance_from_db -id $package_id
Btw, the best way to query all the available methods of an XOTcl object is e.g.
$package_id info methods
I am not sure, why you want to create package-objects in your code, for most applications this is not needed. For creating xowiki/s5/.. instances you should use e.g. "::xowiki::Package initialize ...", which does much more than just the simple object fetch.