added api for outside apps