added some examples
small fixes
refacor on rest methods