test API functionality