complete chat api