[TIMOB-16617] Fixed bug with deploy type not being set in the api usage event.
[TIMOB-16617] Only add API usage analytics when building an app for production.