Skip to content

Commit caba19f

Browse files
James RobertsonJames Robertson
authored andcommitted
version 1.0.11
1 parent cfb9f02 commit caba19f

File tree

13 files changed

+2130
-55
lines changed

13 files changed

+2130
-55
lines changed

.openapi-generator/FILES

Lines changed: 306 additions & 0 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 559 additions & 51 deletions
Large diffs are not rendered by default.

docs/Api/UserApi.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Method | HTTP request | Description
77
[**addRegistrationOrDeviceToken()**](UserApi.md#addRegistrationOrDeviceToken) | **POST** /v3/users/{user_id}/push/{token_type} | Add a registration or device token
88
[**choosePushNotificationContentTemplate()**](UserApi.md#choosePushNotificationContentTemplate) | **PUT** /v3/users/{user_id}/push/template | Choose a push notification content template
99
[**createUser()**](UserApi.md#createUser) | **POST** /v3/users | Create a user
10+
[**createUserToken()**](UserApi.md#createUserToken) | **POST** /v3/users/{user_id}/token | Create user token
1011
[**deleteUserById()**](UserApi.md#deleteUserById) | **DELETE** /v3/users/{user_id} | Delete a user
1112
[**leaveMyGroupChannels()**](UserApi.md#leaveMyGroupChannels) | **PUT** /v3/users/{user_id}/my_group_channels/leave | Leave my group channels
1213
[**listMyGroupChannels()**](UserApi.md#listMyGroupChannels) | **GET** /v3/users/{user_id}/my_group_channels | List my group channels
@@ -215,6 +216,66 @@ No authorization required
215216
[[Back to Model list]](../../README.md#models)
216217
[[Back to README]](../../README.md)
217218

219+
## `createUserToken()`
220+
221+
```php
222+
createUserToken($api_token, $user_id, $create_user_token_data): \Sendbird\Model\CreateUserTokenResponse
223+
```
224+
225+
Create user token
226+
227+
## Create user token
228+
229+
### Example
230+
231+
```php
232+
<?php
233+
require_once(__DIR__ . '/vendor/autoload.php');
234+
235+
236+
237+
$apiInstance = new Sendbird\Api\UserApi(
238+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
239+
// This is optional, `GuzzleHttp\Client` will be used as default.
240+
new GuzzleHttp\Client()
241+
);
242+
$api_token = {{API_TOKEN}}; // string
243+
$user_id = 'user_id_example'; // string
244+
$create_user_token_data = new \Sendbird\Model\CreateUserTokenData(); // \Sendbird\Model\CreateUserTokenData
245+
246+
try {
247+
$result = $apiInstance->createUserToken($api_token, $user_id, $create_user_token_data);
248+
print_r($result);
249+
} catch (Exception $e) {
250+
echo 'Exception when calling UserApi->createUserToken: ', $e->getMessage(), PHP_EOL;
251+
}
252+
```
253+
254+
### Parameters
255+
256+
Name | Type | Description | Notes
257+
------------- | ------------- | ------------- | -------------
258+
**api_token** | **string**| |
259+
**user_id** | **string**| |
260+
**create_user_token_data** | [**\Sendbird\Model\CreateUserTokenData**](../Model/CreateUserTokenData.md)| | [optional]
261+
262+
### Return type
263+
264+
[**\Sendbird\Model\CreateUserTokenResponse**](../Model/CreateUserTokenResponse.md)
265+
266+
### Authorization
267+
268+
No authorization required
269+
270+
### HTTP request headers
271+
272+
- **Content-Type**: `application/json`
273+
- **Accept**: `application/json`
274+
275+
[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
276+
[[Back to Model list]](../../README.md#models)
277+
[[Back to README]](../../README.md)
278+
218279
## `deleteUserById()`
219280

220281
```php

docs/Model/CreateUserTokenData.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# # CreateUserTokenData
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**expires_at** | **float** | Specifies the expiration time of the new session token in Unix milliseconds format. By default, the expiration time of a session token is seven days from the timestamp when the token was issued. | [optional]
8+
9+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# # CreateUserTokenResponse
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**token** | **string** | | [optional]
8+
**expires_at** | **float** | | [optional]
9+
10+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)

docs/Model/SendBirdUser.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Name | Type | Description | Notes
1313
**last_seen_at** | **int** | | [optional]
1414
**nickname** | **string** | | [optional]
1515
**discovery_keys** | **string[]** | | [optional]
16-
**session_tokens** | **string[]** | | [optional]
16+
**session_tokens** | **object[]** | | [optional]
1717
**preferred_languages** | **string[]** | | [optional]
1818
**profile_url** | **string** | | [optional]
1919
**created_at** | **int** | | [optional]

0 commit comments

Comments
 (0)