All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- Adds message editing via
edit{Simple,Multipart,}Message.
- Support for fetching a message by its message ID, via
fetchMultipartMessage
1.6.2 - 2019-11-19
generateTokennow correctly sets the JWT token expiry on all cases
1.6.1 - 2019-09-06
getOptionalFieldsnow works as expected and returns optionally set values.
1.6.0 - 2019-07-30
- Support for
push_notification_title_overridetocreateRoomandupdateRoom
1.5.0 - 2019-07-04
createRoomnow accepts an optionalidparameter that is then uniquely used to identify the room. If one isn't provided, the server will generate an ID instead.
- The
deleteMessagemethod now requires a room ID parameter,room_idand theidparameter has been renamed tomessage_idto avoid any ambiguity.
1.4.0 - 2019-06-24
- Unread counts. No new methods are added, but
getUserRoomsnow includeunread_countandlast_message_atin the response
1.3.0 - 2019-06-18
- Async deletion methods.
asyncDeleteUser,asyncDeleteRoomandgetDeleteStatus. ThedeleteRoomanddeleteUsermethods should be considered deprecated, and will be removed in a future version.
1.2.0 - 2019-03-08
sendMultipartMessageandsendSimpleMessageusing the new V3 endpoint for message sendingfetchMultipartMessageusing the new V3 endpoint for message fetching
- all methods except
sendMessageandgetRoomMessagesuses new V3 endpoints
1.1.0 - 2018-11-08
custom_dataoption that can be passed tocreateRoomandupdateRoom
1.0.0 - 2018-10-30
getUsersByIdsis nowgetUsersByIdgetUsersnow takes an array with an optionalfrom_timestampkey instead of afrom_tskeygetUserReadCursorsis nowgetReadCursorsForUser
- The following new methods:
generateSuTokencreateUsersgetUserupdateRoomdeleteRoomgetRoomgetRoomsgetUserJoinableRoomsaddUsersToRoomremoveUsersFromRoomcreateGlobalRolecreateRoomRoledeleteGlobalRoledeleteRoomRoleassignGlobalRoleToUserassignRoomRoleToUsergetRolesgetUserRolesremoveGlobalRoleForUserremoveRoomRoleForUsergetPermissionsForGlobalRolegetPermissionsForRoomRoleupdatePermissionsForGlobalRoleupdatePermissionsForRoomRolegetReadCursorgetReadCursorsForRoomapiRequestauthorizerRequestcursorsRequest
0.5.9 - 2018-08-29
getRoomsfunctionality added. #31 by @philipnjuguna66
0.5.8 - 2018-08-21
0.5.7 - 2018-08-14
0.5.6 - 2018-07-30
getUsersByIdsandgetUsersnow properly set query parameters
0.5.5 - 2018-07-30
setReadCursorfunctionality added. #22 by @morrislaptopgetUserReadCursorsfunctionality added. #22 by @morrislaptopgetRoomMessagesnow supports providing aninitial_id, alimit, and adirection. #22 by @morrislaptop
0.5.4 - 2018-06-25
getRoomMessagesfunctionality added #21 by @morrislaptop
0.5.3 - 2018-06-11
deleteRoomfunctionality added #19 by @morrislaptopgetUsersfunctionality added #20 by @morrislaptop
0.5.2 - 2018-06-07
updateUservalidates information properly #18 by @morrislaptop
sendMessagesupports send messages with attachments #18 by @morrislaptop
0.5.1 - 2018-05-25
- User ID is validated to be a string as part of
createUser,authenticate, andgenerateAccessTokencalls
getUserRoomsno longer crashes ifjoinableoption not set
0.5.0 - 2018-05-11
- API calls to Chatkit servers now return an associative array that has the keys
'status'and'body'.
0.4.0 - 2018-04-20
authenticatehas been added. This should be the function you use to authenticate your users for Chatkit.
You need to provide an associative array that has a user_id key with a string value. For example:
$chatkit->authenticate([ 'user_id' => 'ham' ]);It returns an associative array that is structured like this:
[
'status' => 200,
'headers' => [
'Some-Header' => 'some-value'
],
'body' => [
'access_token' => 'an.access.token',
'token_type' => 'bearer',
'expires_in' => 86400
]
]where:
statusis the suggested HTTP response status code,headersare the suggested response headers,bodyholds the token payload.
getTokenPairhas been removed
- Authentication no longer returns refresh tokens.
If your client devices are running the:
- Swift SDK - (breaking change) you must be using version
>= 0.8.0of chatkit-swift. - Android SDK - you won't be affected regardless of which version you are running.
- JS SDK - you won't be affected regardless of which version you are running.
- (Nearly) all functions now take an object (an associative array) as their sole parameter. As examples:
- Constructing a Chatkit object is done like this:
$chatkit = new Chatkit\Chatkit([
'instance_locator' => 'your:instance:locator',
'key' => 'your:key'
]);createUseris now called like this:
$chatkit->createUser([
'id' => 'dr_php',
'name' => 'Dr PHP',
'avatar_url' => 'https://placekitten.com/400/500',
'custom_data' => [
'a' => 'piece of data'
]
]);authenticate(previouslygetTokenPair) is now called like this:
$chatkit->authenticate([
'user_id' => 'dr_php'
]);createRoomis now called like this:
$chatkit->createRoom([
'creator_id' => 'dr_php',
'name' => 'A room with a name',
'private' => false
]);