I am using composer for the first time so if I shouldn't be posting here I am very sorry.
I am following a youtube tutorial on the paypal api I have installed composer and created the json file the same as the example. composer.json is saved in the root folder for the website. the structure is below. composer diagnose composer.json: fail and property name is required.
{
"require": {
"paypal/rest-api-php": "1.5.1"
}
}