Can I create a metric to give the time spent working on each ticket during last month?
Yes, you can do this by using the Time Tracking app and Explore. To create custom metrics to report on time tracking in Explore, see the article: Time Tracking app: metrics you need to be measuring.
To build this report in Explore, use the Support: Updates history dataset, add a Filter for Update Date and filter it to only include time spent during the last month.
For all our Explore recipes, see the article: Explore recipes reference.