You can check the API of the class on UI on the class page or if it is lightning component then you can check in the developer console.
To set the Salesforce API and Apex version for a class or trigger: >Edit either a class or trigger, and click Version Settings. >Select the Version of the Salesforce API. This is also the version of Apex associated with the class or trigger. >Click Save.
Sometimes,the API version may differ from Sandbox and production during release time.
Kindly mark it as best answer if it helps so that it can help others in the future.
Greetings!
You can check the API of the class on UI on the class page or if it is lightning component then you can check in the developer console.
To set the Salesforce API and Apex version for a class or trigger:
>Edit either a class or trigger, and click Version Settings.
>Select the Version of the Salesforce API. This is also the version of Apex associated with the class or trigger.
>Click Save.
Sometimes,the API version may differ from Sandbox and production during release time.
Kindly mark it as best answer if it helps so that it can help others in the future.
Warm Regards,
Shirisha Pathuri