Fixes for typos

Fixes the function call to json_encode and use the correct packagist name in the composer settings.