Try nlapiGetFieldValue('entity') then loading that record ID and logging the output (bearing in mind it'll obviously only work when logged in!). If it doesn't work, you may be able to use lookupFields instead. I found the whole scriptable cart v.restrictive though. I ended up using SSP on the front end and an event script on order submission instead, which seems much more reliable.