Use appropriately scoped Api class in executable