Add back API hashes
Add mostly-correct (albeit leaky) string marshaling
Update to get the reference counting correct