declarative api definition for REST and real time apis