DIRAC has evolved from a framework for distributed computing matters operated by the final user, to a platform that can also be used from third-party Virtual Research Environments (VRE), Science Gateways (SG) or distributed computing applications. Therefore, DIRAC has become a platform providing distributed computing interoperability and high level services for science. For this purpose, DIRAC supports several Application Programming Interfaces (API) designed for a versatile programming model in different developing scenarios. This paper presents such scenarios categorized by the location of the API client. Thus, a first scenario is an application server powered by DIRAC services. Second, a web browser running embedded DIRAC calls, for dynamic web client composition. Third scenario is a DIRAC Platform as a Service (PaaS) powering distributed applications with High Throughput Computing (HTC) on the client side. This paper describes the underlying DIRAC architecture and the main functionalities of each API and developing scenario. Overall DIRAC is a coherent toolkit that enables a wide range of component developments like service for scientific applications, web plugs or PaaS agents.