Skip to content

Commit 5ec5e2a

Browse files
Muhamad RidwanMuhamad Ridwan
authored andcommitted
feat: update models
1 parent 6977fa0 commit 5ec5e2a

37 files changed

+2383
-337
lines changed

.openapi-generator/FILES

Lines changed: 12 additions & 141 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,12 @@ docs/MarkAllMessagesAsReadRequest.md
7171
docs/MarkChannelMessagesAsReadRequest.md
7272
docs/MessageApi.md
7373
docs/MetadataApi.md
74+
docs/MigrateMessagesAdminMessageRequest.md
75+
docs/MigrateMessagesFileMessageRequest.md
76+
docs/MigrateMessagesFileMessageRequestThumbnailsInner.md
77+
docs/MigrateMessagesRequest.md
78+
docs/MigrateMessagesRequestMessagesInner.md
79+
docs/MigrateMessagesTextMessageRequest.md
7480
docs/ModerationApi.md
7581
docs/OpenChannelApi.md
7682
docs/RegisterOperatorsToAGroupChannelRequest.md
@@ -225,6 +231,12 @@ sendbird_platform_sdk/model/list_registration_or_device_tokens_response.py
225231
sendbird_platform_sdk/model/list_users_response.py
226232
sendbird_platform_sdk/model/mark_all_messages_as_read_request.py
227233
sendbird_platform_sdk/model/mark_channel_messages_as_read_request.py
234+
sendbird_platform_sdk/model/migrate_messages_admin_message_request.py
235+
sendbird_platform_sdk/model/migrate_messages_file_message_request.py
236+
sendbird_platform_sdk/model/migrate_messages_file_message_request_thumbnails_inner.py
237+
sendbird_platform_sdk/model/migrate_messages_request.py
238+
sendbird_platform_sdk/model/migrate_messages_request_messages_inner.py
239+
sendbird_platform_sdk/model/migrate_messages_text_message_request.py
228240
sendbird_platform_sdk/model/register_operators_to_a_group_channel_request.py
229241
sendbird_platform_sdk/model/remove_a_registration_or_device_token_from_an_owner_response.py
230242
sendbird_platform_sdk/model/remove_a_registration_or_device_token_response.py
@@ -300,145 +312,4 @@ setup.cfg
300312
setup.py
301313
test-requirements.txt
302314
test/__init__.py
303-
test/test_accept_an_invitation_request.py
304-
test/test_accept_an_invitation_response.py
305-
test/test_add_a_registration_or_device_token_request.py
306-
test/test_add_a_registration_or_device_token_response.py
307-
test/test_add_extra_data_to_a_message_request.py
308-
test/test_add_extra_data_to_a_message_response.py
309-
test/test_announcement_api.py
310-
test/test_block_a_user_request.py
311-
test/test_block_a_user_response.py
312-
test/test_bot_api.py
313-
test/test_check_if_member_response.py
314-
test/test_choose_a_push_notification_content_template_request.py
315-
test/test_choose_a_push_notification_content_template_response.py
316-
test/test_create_a_bot_request.py
317-
test/test_create_a_bot_response.py
318-
test/test_create_a_bot_response_bot.py
319-
test/test_create_a_bot_response_bot_style.py
320-
test/test_create_a_channel_metadata_request.py
321-
test/test_create_a_channel_metadata_response.py
322-
test/test_create_a_group_channel_request.py
323-
test/test_create_a_group_channel_response.py
324-
test/test_create_a_user_request.py
325-
test/test_create_a_user_response.py
326-
test/test_create_an_open_channel_request.py
327-
test/test_create_an_open_channel_response.py
328-
test/test_create_user_token_request.py
329-
test/test_create_user_token_response.py
330-
test/test_freeze_a_group_channel_request.py
331-
test/test_freeze_a_group_channel_response.py
332-
test/test_freeze_an_open_channel_request.py
333-
test/test_freeze_an_open_channel_response.py
334-
test/test_get_a_group_channel_response.py
335-
test/test_get_a_group_channel_response_all_of.py
336-
test/test_get_a_message_response.py
337-
test/test_get_an_open_channel_response.py
338-
test/test_get_channel_invitation_preference_response.py
339-
test/test_get_total_number_of_messages_in_a_channel_response.py
340-
test/test_group_channel_api.py
341-
test/test_group_channel_list_members_response.py
342-
test/test_group_chat_list_channels_response.py
343-
test/test_hide_a_channel_request.py
344-
test/test_invite_as_members_request.py
345-
test/test_invite_as_members_response.py
346-
test/test_invite_as_members_response_all_of.py
347-
test/test_join_a_channel_request.py
348-
test/test_join_a_channel_response.py
349-
test/test_join_channels_request.py
350-
test/test_leave_a_channel_request.py
351-
test/test_leave_my_group_channels_request.py
352-
test/test_list_blocked_users_response.py
353-
test/test_list_bots_response.py
354-
test/test_list_bots_response_bots_inner.py
355-
test/test_list_bots_response_bots_inner_ai.py
356-
test/test_list_bots_response_bots_inner_bot.py
357-
test/test_list_bots_response_bots_inner_bot_style.py
358-
test/test_list_bots_response_bots_inner_bot_style_color.py
359-
test/test_list_bots_response_bots_inner_first_messages_inner.py
360-
test/test_list_bots_response_bots_inner_first_messages_inner_data.py
361-
test/test_list_bots_response_bots_inner_safeguard.py
362-
test/test_list_messages_response.py
363-
test/test_list_my_group_channels_response.py
364-
test/test_list_open_channels_response.py
365-
test/test_list_operators_response.py
366-
test/test_list_registration_or_device_tokens_response.py
367-
test/test_list_users_response.py
368-
test/test_mark_all_messages_as_read_request.py
369-
test/test_mark_channel_messages_as_read_request.py
370-
test/test_message_api.py
371-
test/test_metadata_api.py
372-
test/test_moderation_api.py
373-
test/test_open_channel_api.py
374-
test/test_register_operators_to_a_group_channel_request.py
375-
test/test_remove_a_registration_or_device_token_from_an_owner_response.py
376-
test/test_remove_a_registration_or_device_token_response.py
377-
test/test_remove_all_registration_or_device_token_response.py
378-
test/test_reset_chat_history_request.py
379-
test/test_reset_chat_history_response.py
380-
test/test_schedule_an_announcement_request.py
381-
test/test_schedule_an_announcement_request_create_channel_options.py
382-
test/test_schedule_an_announcement_request_message.py
383-
test/test_schedule_an_announcement_response.py
384-
test/test_schedule_an_announcement_response_message.py
385-
test/test_send_a_bot_message_request.py
386-
test/test_send_a_bot_message_response.py
387-
test/test_send_a_message_request.py
388-
test/test_send_a_message_response.py
389-
test/test_send_admin_message_request_body.py
390-
test/test_send_file_message_request_body.py
391-
test/test_send_text_message_request_body.py
392-
test/test_send_text_message_request_body_push_message_template.py
393-
test/test_send_text_message_request_body_push_message_template_one_of.py
394-
test/test_sendbird_basic_user_info.py
395-
test/test_sendbird_disappearing_message.py
396-
test/test_sendbird_extended_message_payload.py
397-
test/test_sendbird_file.py
398-
test/test_sendbird_group_channel.py
399-
test/test_sendbird_group_channel_detail.py
400-
test/test_sendbird_group_channel_detail_channel.py
401-
test/test_sendbird_member.py
402-
test/test_sendbird_message_response.py
403-
test/test_sendbird_message_response_message_events.py
404-
test/test_sendbird_open_channel.py
405-
test/test_sendbird_parent_message_info.py
406-
test/test_sendbird_push_trigger_option.py
407-
test/test_sendbird_reaction.py
408-
test/test_sendbird_sms_fallback.py
409-
test/test_sendbird_sorted_metaarray.py
410-
test/test_sendbird_sorted_metaarray_inner.py
411-
test/test_sendbird_thumbnail.py
412-
test/test_sendbird_user.py
413-
test/test_start_typing_indicators_request.py
414-
test/test_statistics_api.py
415-
test/test_update_a_channel_metadata_request.py
416-
test/test_update_a_group_channel_request.py
417-
test/test_update_a_group_channel_response.py
418-
test/test_update_a_message_request.py
419-
test/test_update_a_message_response.py
420-
test/test_update_a_user_request.py
421-
test/test_update_a_user_response.py
422-
test/test_update_an_open_channel_request.py
423-
test/test_update_an_open_channel_response.py
424-
test/test_update_channel_invitation_preference_request.py
425-
test/test_update_channel_invitation_preference_response.py
426-
test/test_update_count_preference_of_a_channel_request.py
427-
test/test_update_count_preference_of_channel_by_url_response.py
428-
test/test_update_extra_data_in_a_message_request.py
429-
test/test_update_extra_data_in_a_message_response.py
430-
test/test_update_push_preferences_for_a_channel_request.py
431-
test/test_update_push_preferences_for_a_channel_response.py
432-
test/test_update_push_preferences_request.py
433-
test/test_update_push_preferences_response.py
434-
test/test_user_api.py
435-
test/test_view_a_user_response.py
436-
test/test_view_count_preference_of_a_channel_response.py
437-
test/test_view_number_of_channels_with_unread_messages_response.py
438-
test/test_view_number_of_daily_active_users_response.py
439-
test/test_view_number_of_monthly_active_users_response.py
440-
test/test_view_number_of_unread_messages_response.py
441-
test/test_view_push_preferences_for_a_channel_response.py
442-
test/test_view_push_preferences_response.py
443-
test/test_view_who_owns_a_registration_or_device_token_response.py
444315
tox.ini

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55

66
[![link to docs](https://img.shields.io/badge/SDK-docs-green)](/docs)
7+
[![PYPI](https://img.shields.io/pypi/v/sendbird-platform-sdk.svg)](https://pypi.org/project/sendbird-platform-sdk)
8+
79

810
This is a python library that makes talking to the [Sendbird Platform API](https://sendbird.com/docs/chat/v3/platform-api/getting-started/prepare-to-use-api) easier. With this library you can extend your Sendbird integration to include advanced features like channel automation and user management.
911

README.md-e

Lines changed: 0 additions & 70 deletions
This file was deleted.

docs/GroupChannelApi.md

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -969,12 +969,6 @@ with sendbird_platform_sdk.ApiClient() as api_client:
969969
metacounter_value_lt = "metacounter_value_lt_example" # str | Searches for group channels with metacounter containing an item with the key specified by the metadata_key parameter, where the value of that item is lower than the value specified by this parameter. To use this parameter, the metacounter_key parameter should be specified. (optional)
970970
metacounter_value_lte = "metacounter_value_lte_example" # str | Searches for group channels with metacounter containing an item with the key specified by the metadata_key parameter, where the value of that item is lower than or equal to the value specified by this parameter. To use this parameter, the metacounter_key parameter should be specified. (optional)
971971
include_sorted_metaarray_in_last_message = False # bool | Determines whether to include the sorted_metaarray as one of the last_message’s properties in the response. (optional)
972-
custom_type = "ANNOUNCEMENT" # str | (Deprecated) Returns channels whose custom_type matches the given value. If this field is not specified, all channels are returned, regardless of their custom type. The string passed here must be urlencoded. (optional)
973-
read_receipt = False # bool | (Deprecated) Superseded by show_read_receipt. (optional)
974-
member = True # bool | (Deprecated) Superseded by show_member. (optional)
975-
is_distinct = True # bool | (Deprecated) Superseded by distinct_mode. (optional)
976-
members_in = "members_in_example" # str | (Deprecated) Superseded by members_exactly_in. (optional)
977-
user_id = "user_id_example" # str | (Deprecated) Restricts the search scope to only retrieve the target user's group channels. It's recommended to use the list group channels by user action instead. (optional)
978972

979973
# example passing only required values which don't have defaults set
980974
try:
@@ -988,7 +982,7 @@ with sendbird_platform_sdk.ApiClient() as api_client:
988982
# and optional values
989983
try:
990984
# List channels
991-
api_response = api_instance.list_channels(api_token, token=token, limit=limit, distinct_mode=distinct_mode, public_mode=public_mode, super_mode=super_mode, created_after=created_after, created_before=created_before, show_empty=show_empty, show_member=show_member, show_delivery_receipt=show_delivery_receipt, show_read_receipt=show_read_receipt, show_metadata=show_metadata, show_frozen=show_frozen, order=order, metadata_order_key=metadata_order_key, custom_types=custom_types, custom_type_startswith=custom_type_startswith, channel_urls=channel_urls, name=name, name_contains=name_contains, name_startswith=name_startswith, members_exactly_in=members_exactly_in, members_include_in=members_include_in, query_type=query_type, members_nickname=members_nickname, members_nickname_contains=members_nickname_contains, metadata_key=metadata_key, metadata_values=metadata_values, metadata_value_startswith=metadata_value_startswith, metacounter_key=metacounter_key, metacounter_values=metacounter_values, metacounter_value_gt=metacounter_value_gt, metacounter_value_gte=metacounter_value_gte, metacounter_value_lt=metacounter_value_lt, metacounter_value_lte=metacounter_value_lte, include_sorted_metaarray_in_last_message=include_sorted_metaarray_in_last_message, custom_type=custom_type, read_receipt=read_receipt, member=member, is_distinct=is_distinct, members_in=members_in, user_id=user_id)
985+
api_response = api_instance.list_channels(api_token, token=token, limit=limit, distinct_mode=distinct_mode, public_mode=public_mode, super_mode=super_mode, created_after=created_after, created_before=created_before, show_empty=show_empty, show_member=show_member, show_delivery_receipt=show_delivery_receipt, show_read_receipt=show_read_receipt, show_metadata=show_metadata, show_frozen=show_frozen, order=order, metadata_order_key=metadata_order_key, custom_types=custom_types, custom_type_startswith=custom_type_startswith, channel_urls=channel_urls, name=name, name_contains=name_contains, name_startswith=name_startswith, members_exactly_in=members_exactly_in, members_include_in=members_include_in, query_type=query_type, members_nickname=members_nickname, members_nickname_contains=members_nickname_contains, metadata_key=metadata_key, metadata_values=metadata_values, metadata_value_startswith=metadata_value_startswith, metacounter_key=metacounter_key, metacounter_values=metacounter_values, metacounter_value_gt=metacounter_value_gt, metacounter_value_gte=metacounter_value_gte, metacounter_value_lt=metacounter_value_lt, metacounter_value_lte=metacounter_value_lte, include_sorted_metaarray_in_last_message=include_sorted_metaarray_in_last_message)
992986
pprint(api_response)
993987
except sendbird_platform_sdk.ApiException as e:
994988
print("Exception when calling GroupChannelApi->list_channels: %s\n" % e)
@@ -1036,12 +1030,6 @@ Name | Type | Description | Notes
10361030
**metacounter_value_lt** | **str**| Searches for group channels with metacounter containing an item with the key specified by the metadata_key parameter, where the value of that item is lower than the value specified by this parameter. To use this parameter, the metacounter_key parameter should be specified. | [optional]
10371031
**metacounter_value_lte** | **str**| Searches for group channels with metacounter containing an item with the key specified by the metadata_key parameter, where the value of that item is lower than or equal to the value specified by this parameter. To use this parameter, the metacounter_key parameter should be specified. | [optional]
10381032
**include_sorted_metaarray_in_last_message** | **bool**| Determines whether to include the sorted_metaarray as one of the last_message’s properties in the response. | [optional]
1039-
**custom_type** | **str**| (Deprecated) Returns channels whose custom_type matches the given value. If this field is not specified, all channels are returned, regardless of their custom type. The string passed here must be urlencoded. | [optional]
1040-
**read_receipt** | **bool**| (Deprecated) Superseded by show_read_receipt. | [optional]
1041-
**member** | **bool**| (Deprecated) Superseded by show_member. | [optional]
1042-
**is_distinct** | **bool**| (Deprecated) Superseded by distinct_mode. | [optional]
1043-
**members_in** | **str**| (Deprecated) Superseded by members_exactly_in. | [optional]
1044-
**user_id** | **str**| (Deprecated) Restricts the search scope to only retrieve the target user's group channels. It's recommended to use the list group channels by user action instead. | [optional]
10451033

10461034
### Return type
10471035

docs/MessageApi.md

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -580,6 +580,7 @@ Migrate messages
580580
import time
581581
import sendbird_platform_sdk
582582
from sendbird_platform_sdk.api import message_api
583+
from sendbird_platform_sdk.model.migrate_messages_request import MigrateMessagesRequest
583584
from pprint import pprint
584585
# Defining the host is optional and defaults to https://api-APP_ID.sendbird.com
585586
# See configuration.py for a list of all supported configuration parameters.
@@ -594,7 +595,13 @@ with sendbird_platform_sdk.ApiClient() as api_client:
594595
api_instance = message_api.MessageApi(api_client)
595596
target_channel_url = "target_channel_url_example" # str | (Required)
596597
api_token = "{{API_TOKEN}}" # str | (optional)
597-
body = {} # {str: (bool, date, datetime, dict, float, int, list, str, none_type)} | (optional)
598+
migrate_messages_request = MigrateMessagesRequest(
599+
messages=[
600+
MigrateMessagesRequestMessagesInner(None),
601+
],
602+
update_read_ts=True,
603+
rewind_read_ts=True,
604+
) # MigrateMessagesRequest | (optional)
598605

599606
# example passing only required values which don't have defaults set
600607
try:
@@ -608,7 +615,7 @@ with sendbird_platform_sdk.ApiClient() as api_client:
608615
# and optional values
609616
try:
610617
# Migrate messages
611-
api_response = api_instance.migrate_messages(target_channel_url, api_token=api_token, body=body)
618+
api_response = api_instance.migrate_messages(target_channel_url, api_token=api_token, migrate_messages_request=migrate_messages_request)
612619
pprint(api_response)
613620
except sendbird_platform_sdk.ApiException as e:
614621
print("Exception when calling MessageApi->migrate_messages: %s\n" % e)
@@ -621,7 +628,7 @@ Name | Type | Description | Notes
621628
------------- | ------------- | ------------- | -------------
622629
**target_channel_url** | **str**| (Required) |
623630
**api_token** | **str**| | [optional]
624-
**body** | **{str: (bool, date, datetime, dict, float, int, list, str, none_type)}**| | [optional]
631+
**migrate_messages_request** | [**MigrateMessagesRequest**](MigrateMessagesRequest.md)| | [optional]
625632

626633
### Return type
627634

0 commit comments

Comments
 (0)