added usage function to new API