fun createPost(token: Token, item: Item): Post { // sends item to the server & waits return post // returns resulting post } 2 Callbacks: after fun requestTokenAsync(cb: (Token) -> Unit) { … } fun createPostAsync(token: Token, item: Item, cb: (Post) -> Unit) { // sends item to the server, invokes callback when done // returns immediately } 2 callback