Developers often have difficulties using APIs. To aid developers in efficiently using APIs, API usage patterns can be extracted from source code stored in software repositories. Previous approaches have mined repositories to extract API usage patterns by simply applying a data mining technique to the collection of method invocations of API objects. However, respective roles of invoked methods within API objects are not considered in these approaches. This paper proposes an improved approach that extracts API usage patterns at a higher-level abstraction rather than mining the actual method invocations. Our approach embraces a multilevel sequential mining technique and uses categorization of method invocations to define their concept hierarchy. In the categorization, the method invocations are categorized based on their roles. The extracted API usage patterns represent recurring usages of API objects. Therefore, they are useful to recommend typical usages of APIs. The experimental results show that our approach is practical to discover patterns that reveal characteristics of usages.