As bike-sharing systems gain popularity, understanding their roles in urban transportation, such as the first/last mile problem and the replacement of public transit, is crucial to comprehensively promote urban transport systems. Due to the Internet of Things (IoT) technique, copious data from public bike trips worldwide are available to urban researchers. In this study, we examine how public bikes function not just as a means of transportation, but also for leisure. The leisure function was ignored in previous empirical studies using data mining techniques, an oversight that could skew results in places like Seoul where leisure trips constitute a significant portion of the trips. We investigate when, where, and to what degree bike-sharing serves as a leisure tool and substitutes for, integrates with, or complements the public transit system. We propose an integrated data-mining approach to identify the above four categories of public bike trips. Our method combines multiple sources of real-world data, the distributed density-based spatial clustering of applications with noise (DBSCAN), and spatial feature engineering. The results reveal that the distribution of each category shows substantial spatial–temporal heterogeneity. Longitudinal analysis reveals that the use of public bicycles as a transportation mode primarily contributes to the growth observed from 2018 to 2021, compared to use for leisure. The determining factors and non-linear functions of each type of bike trip were interpreted by explainable machine learning methods, Shapley additive explanations (SHAP), and partial dependence plot (PDP). We discovered that lower slopes, higher residential densities, and more commercial neighborhoods consistently attract users across all categories. Additionally, rivers and green areas attract more leisure trips, while areas with denser transit routes see more substitution trips and fewer complementary trips. By understanding the characteristics, spatial–temporal distribution, and determining factors of public bike trips across these four categories, city planners and operators can tailor services to meet the diverse needs of citizens, fostering a more convenient, sustainable, and accessible urban transport system.