first stab at api reference, made a few methods private.