Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions activitysmith_openapi/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,21 @@
from activitysmith_openapi.exceptions import ApiException

# import models into sdk package
from activitysmith_openapi.models.alert_payload import AlertPayload
from activitysmith_openapi.models.bad_request_error import BadRequestError
from activitysmith_openapi.models.channel_target import ChannelTarget
from activitysmith_openapi.models.content_state_end import ContentStateEnd
from activitysmith_openapi.models.content_state_start import ContentStateStart
from activitysmith_openapi.models.content_state_update import ContentStateUpdate
from activitysmith_openapi.models.forbidden_error import ForbiddenError
from activitysmith_openapi.models.live_activity_end_request import LiveActivityEndRequest
from activitysmith_openapi.models.live_activity_end_response import LiveActivityEndResponse
from activitysmith_openapi.models.live_activity_limit_error import LiveActivityLimitError
from activitysmith_openapi.models.live_activity_start_request import LiveActivityStartRequest
from activitysmith_openapi.models.live_activity_start_response import LiveActivityStartResponse
from activitysmith_openapi.models.live_activity_update_request import LiveActivityUpdateRequest
from activitysmith_openapi.models.live_activity_update_response import LiveActivityUpdateResponse
from activitysmith_openapi.models.no_recipients_error import NoRecipientsError
from activitysmith_openapi.models.push_notification_request import PushNotificationRequest
from activitysmith_openapi.models.push_notification_response import PushNotificationResponse
from activitysmith_openapi.models.rate_limit_error import RateLimitError
Expand Down
21 changes: 18 additions & 3 deletions activitysmith_openapi/api/live_activities_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ def end_live_activity(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityEndResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -164,6 +165,7 @@ def end_live_activity_with_http_info(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityEndResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -232,6 +234,7 @@ def end_live_activity_without_preload_content(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityEndResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -335,7 +338,7 @@ def start_live_activity(
) -> LiveActivityStartResponse:
"""Start a Live Activity

Starts a Live Activity on all registered devices and returns an activity_id.
Starts a Live Activity on devices matched by API key scope and optional target channels.

:param live_activity_start_request: (required)
:type live_activity_start_request: LiveActivityStartRequest
Expand Down Expand Up @@ -371,6 +374,9 @@ def start_live_activity(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityStartResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -403,7 +409,7 @@ def start_live_activity_with_http_info(
) -> ApiResponse[LiveActivityStartResponse]:
"""Start a Live Activity

Starts a Live Activity on all registered devices and returns an activity_id.
Starts a Live Activity on devices matched by API key scope and optional target channels.

:param live_activity_start_request: (required)
:type live_activity_start_request: LiveActivityStartRequest
Expand Down Expand Up @@ -439,6 +445,9 @@ def start_live_activity_with_http_info(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityStartResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -471,7 +480,7 @@ def start_live_activity_without_preload_content(
) -> RESTResponseType:
"""Start a Live Activity

Starts a Live Activity on all registered devices and returns an activity_id.
Starts a Live Activity on devices matched by API key scope and optional target channels.

:param live_activity_start_request: (required)
:type live_activity_start_request: LiveActivityStartRequest
Expand Down Expand Up @@ -507,6 +516,9 @@ def start_live_activity_without_preload_content(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityStartResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -646,6 +658,7 @@ def update_live_activity(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityUpdateResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -714,6 +727,7 @@ def update_live_activity_with_http_info(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityUpdateResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -782,6 +796,7 @@ def update_live_activity_without_preload_content(

_response_types_map: Dict[str, Optional[str]] = {
'200': "LiveActivityUpdateResponse",
'403': "ForbiddenError",
'429': "RateLimitError",
}
response_data = self.api_client.call_api(
Expand Down
15 changes: 12 additions & 3 deletions activitysmith_openapi/api/push_notifications_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def send_push_notification(
) -> PushNotificationResponse:
"""Send a push notification

Sends a push notification to every paired device in your account.
Sends a push notification to devices matched by API key scope and optional target channels.

:param push_notification_request: (required)
:type push_notification_request: PushNotificationRequest
Expand Down Expand Up @@ -92,6 +92,9 @@ def send_push_notification(

_response_types_map: Dict[str, Optional[str]] = {
'200': "PushNotificationResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "SendPushNotification429Response",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -124,7 +127,7 @@ def send_push_notification_with_http_info(
) -> ApiResponse[PushNotificationResponse]:
"""Send a push notification

Sends a push notification to every paired device in your account.
Sends a push notification to devices matched by API key scope and optional target channels.

:param push_notification_request: (required)
:type push_notification_request: PushNotificationRequest
Expand Down Expand Up @@ -160,6 +163,9 @@ def send_push_notification_with_http_info(

_response_types_map: Dict[str, Optional[str]] = {
'200': "PushNotificationResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "SendPushNotification429Response",
}
response_data = self.api_client.call_api(
Expand Down Expand Up @@ -192,7 +198,7 @@ def send_push_notification_without_preload_content(
) -> RESTResponseType:
"""Send a push notification

Sends a push notification to every paired device in your account.
Sends a push notification to devices matched by API key scope and optional target channels.

:param push_notification_request: (required)
:type push_notification_request: PushNotificationRequest
Expand Down Expand Up @@ -228,6 +234,9 @@ def send_push_notification_without_preload_content(

_response_types_map: Dict[str, Optional[str]] = {
'200': "PushNotificationResponse",
'400': "BadRequestError",
'403': "ForbiddenError",
'404': "NoRecipientsError",
'429': "SendPushNotification429Response",
}
response_data = self.api_client.call_api(
Expand Down
30 changes: 30 additions & 0 deletions activitysmith_openapi/docs/AlertPayload.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# AlertPayload


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**title** | **str** | | [optional]
**body** | **str** | | [optional]

## Example

```python
from activitysmith_openapi.models.alert_payload import AlertPayload

# TODO update the JSON string below
json = "{}"
# create an instance of AlertPayload from a JSON string
alert_payload_instance = AlertPayload.from_json(json)
# print the JSON string representation of the object
print(AlertPayload.to_json())

# convert the object into a dict
alert_payload_dict = alert_payload_instance.to_dict()
# create an instance of AlertPayload from a dict
alert_payload_from_dict = AlertPayload.from_dict(alert_payload_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


30 changes: 30 additions & 0 deletions activitysmith_openapi/docs/BadRequestError.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# BadRequestError


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**error** | **str** | |
**message** | **str** | |

## Example

```python
from activitysmith_openapi.models.bad_request_error import BadRequestError

# TODO update the JSON string below
json = "{}"
# create an instance of BadRequestError from a JSON string
bad_request_error_instance = BadRequestError.from_json(json)
# print the JSON string representation of the object
print(BadRequestError.to_json())

# convert the object into a dict
bad_request_error_dict = bad_request_error_instance.to_dict()
# create an instance of BadRequestError from a dict
bad_request_error_from_dict = BadRequestError.from_dict(bad_request_error_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


29 changes: 29 additions & 0 deletions activitysmith_openapi/docs/ChannelTarget.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# ChannelTarget


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**channels** | **List[str]** | Channel slugs. When omitted, API key scope determines recipients. |

## Example

```python
from activitysmith_openapi.models.channel_target import ChannelTarget

# TODO update the JSON string below
json = "{}"
# create an instance of ChannelTarget from a JSON string
channel_target_instance = ChannelTarget.from_json(json)
# print the JSON string representation of the object
print(ChannelTarget.to_json())

# convert the object into a dict
channel_target_dict = channel_target_instance.to_dict()
# create an instance of ChannelTarget from a dict
channel_target_from_dict = ChannelTarget.from_dict(channel_target_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


30 changes: 30 additions & 0 deletions activitysmith_openapi/docs/ForbiddenError.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# ForbiddenError


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**error** | **str** | |
**message** | **str** | |

## Example

```python
from activitysmith_openapi.models.forbidden_error import ForbiddenError

# TODO update the JSON string below
json = "{}"
# create an instance of ForbiddenError from a JSON string
forbidden_error_instance = ForbiddenError.from_json(json)
# print the JSON string representation of the object
print(ForbiddenError.to_json())

# convert the object into a dict
forbidden_error_dict = forbidden_error_instance.to_dict()
# create an instance of ForbiddenError from a dict
forbidden_error_from_dict = ForbiddenError.from_dict(forbidden_error_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


7 changes: 6 additions & 1 deletion activitysmith_openapi/docs/LiveActivitiesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ Name | Type | Description | Notes
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Live Activity ended | - |
**403** | Forbidden (activity not owned by this API key account) | - |
**429** | Rate limit exceeded | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
Expand All @@ -94,7 +95,7 @@ Name | Type | Description | Notes

Start a Live Activity

Starts a Live Activity on all registered devices and returns an activity_id.
Starts a Live Activity on devices matched by API key scope and optional target channels.

### Example

Expand Down Expand Up @@ -165,6 +166,9 @@ Name | Type | Description | Notes
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Live Activity started | - |
**400** | Bad request (invalid payload or channel targeting input) | - |
**403** | Forbidden (API key scope or channel assignment violation) | - |
**404** | No recipients found for effective channel target | - |
**429** | Rate limit exceeded | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
Expand Down Expand Up @@ -245,6 +249,7 @@ Name | Type | Description | Notes
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Live Activity updated (or queued) | - |
**403** | Forbidden (activity not owned by this API key account) | - |
**429** | Rate limit exceeded | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
Expand Down
2 changes: 2 additions & 0 deletions activitysmith_openapi/docs/LiveActivityStartRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**content_state** | [**ContentStateStart**](ContentStateStart.md) | |
**alert** | [**AlertPayload**](AlertPayload.md) | | [optional]
**target** | [**ChannelTarget**](ChannelTarget.md) | | [optional]

## Example

Expand Down
1 change: 1 addition & 0 deletions activitysmith_openapi/docs/LiveActivityStartResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**devices_notified** | **int** | | [optional]
**users_notified** | **int** | | [optional]
**activity_id** | **str** | |
**effective_channel_slugs** | **List[str]** | | [optional]
**timestamp** | **datetime** | |

## Example
Expand Down
31 changes: 31 additions & 0 deletions activitysmith_openapi/docs/NoRecipientsError.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# NoRecipientsError


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**error** | **str** | |
**message** | **str** | |
**effective_channel_slugs** | **List[str]** | | [optional]

## Example

```python
from activitysmith_openapi.models.no_recipients_error import NoRecipientsError

# TODO update the JSON string below
json = "{}"
# create an instance of NoRecipientsError from a JSON string
no_recipients_error_instance = NoRecipientsError.from_json(json)
# print the JSON string representation of the object
print(NoRecipientsError.to_json())

# convert the object into a dict
no_recipients_error_dict = no_recipients_error_instance.to_dict()
# create an instance of NoRecipientsError from a dict
no_recipients_error_from_dict = NoRecipientsError.from_dict(no_recipients_error_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


Loading