Skip to content

Commit ee7bc11

Browse files
author
APIs and Common Services team
committed
Automated SDK update
This updates the SDK from internal repo commit segmentio/public-api@468a31d2.
1 parent e8f5497 commit ee7bc11

File tree

693 files changed

+1093
-696
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

693 files changed

+1093
-696
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ See the next sections for more information on how to use the Segment Public API.
1111

1212
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
1313

14-
- API version: 60.0.0
15-
- Package version: 60.0.0
14+
- API version: 60.1.0
15+
- Package version: 60.1.0
1616
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
1717

1818
For more information, please visit [https://docs.segmentapis.com](https://docs.segmentapis.com)

docs/AudiencesApi.md

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Method | HTTP request | Description
1515
[**list_audience_schedules_from_space_and_audience**](AudiencesApi.md#list_audience_schedules_from_space_and_audience) | **GET** /spaces/{spaceId}/audiences/{id}/schedules | List Audience Schedules from Space And Audience
1616
[**list_audiences**](AudiencesApi.md#list_audiences) | **GET** /spaces/{spaceId}/audiences | List Audiences
1717
[**remove_audience_from_space**](AudiencesApi.md#remove_audience_from_space) | **DELETE** /spaces/{spaceId}/audiences/{id} | Remove Audience from Space
18+
[**remove_audience_schedule_from_audience**](AudiencesApi.md#remove_audience_schedule_from_audience) | **DELETE** /spaces/{spaceId}/audiences/{id}/schedules/{scheduleId} | Remove Audience Schedule from Audience
1819
[**update_audience_for_space**](AudiencesApi.md#update_audience_for_space) | **PATCH** /spaces/{spaceId}/audiences/{id} | Update Audience for Space
1920
[**update_audience_schedule_for_audience**](AudiencesApi.md#update_audience_schedule_for_audience) | **PATCH** /spaces/{spaceId}/audiences/{id}/schedules/{scheduleId} | Update Audience Schedule for Audience
2021

@@ -869,6 +870,83 @@ Name | Type | Description | Notes
869870
[[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)
870871

871872

873+
## Operation: remove_audience_schedule_from_audience
874+
875+
> RemoveAudienceScheduleFromAudience200Response remove_audience_schedule_from_audience(space_id, id, schedule_id)
876+
877+
Remove Audience Schedule from Audience
878+
879+
Deletes an audience schedule for a Linked Audience (audienceType = LINKED). • This endpoint is in **Alpha** testing. Please submit any feedback by sending an email to [email protected]. • In order to successfully call this endpoint, the specified Workspace needs to have the Audience feature enabled. Please reach out to your customer success manager for more information.
880+
881+
### Example
882+
883+
* Bearer Authentication (token):
884+
```python
885+
import time
886+
import os
887+
import segment_public_api
888+
from segment_public_api.models.remove_audience_schedule_from_audience200_response import RemoveAudienceScheduleFromAudience200Response
889+
from segment_public_api.rest import ApiException
890+
from pprint import pprint
891+
892+
893+
894+
# Configure Bearer authorization: token
895+
configuration = segment_public_api.Configuration(
896+
access_token = os.environ["BEARER_TOKEN"]
897+
)
898+
899+
# Enter a context with an instance of the API client
900+
with segment_public_api.ApiClient(configuration) as api_client:
901+
# Create an instance of the API class
902+
api_instance = segment_public_api.AudiencesApi(api_client)
903+
space_id = '9aQ1Lj62S4bomZKLF4DPqW' # str |
904+
id = 'aud_0ujsszwN8NRY24YaXiTIE2VWDTS' # str |
905+
schedule_id = 'sch_0ujsszwN8NRY24YaXiTIE2VWDTS' # str |
906+
907+
try:
908+
# Remove Audience Schedule from Audience
909+
api_response = api_instance.remove_audience_schedule_from_audience(space_id, id, schedule_id)
910+
print("The response of AudiencesApi->remove_audience_schedule_from_audience:\n")
911+
pprint(api_response)
912+
except Exception as e:
913+
print("Exception when calling AudiencesApi->remove_audience_schedule_from_audience: %s\n" % e)
914+
```
915+
916+
917+
918+
### Parameters
919+
920+
Name | Type | Description | Notes
921+
------------- | ------------- | ------------- | -------------
922+
**space_id** | **str**| |
923+
**id** | **str**| |
924+
**schedule_id** | **str**| |
925+
926+
### Return type
927+
928+
[**RemoveAudienceScheduleFromAudience200Response**](RemoveAudienceScheduleFromAudience200Response.md)
929+
930+
### Authorization
931+
932+
[token](../README.md#token)
933+
934+
### HTTP request headers
935+
936+
- **Content-Type**: Not defined
937+
- **Accept**: application/vnd.segment.v1alpha+json, application/json
938+
939+
### HTTP response details
940+
| Status code | Description | Response headers |
941+
|-------------|-------------|------------------|
942+
**200** | OK | - |
943+
**404** | Resource not found | - |
944+
**422** | Validation failure | - |
945+
**429** | Too many requests | - |
946+
947+
[[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)
948+
949+
872950
## Operation: update_audience_for_space
873951

874952
> UpdateAudienceForSpace200Response update_audience_for_space(space_id, id, update_audience_for_space_beta_input)

segment_public_api/__init__.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77
88
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
99
10-
The version of the OpenAPI document: 60.0.0
10+
The version of the OpenAPI document: 60.1.0
1111
1212
Generated by OpenAPI Generator (https://openapi-generator.tech)
1313
1414
Do not edit the class manually.
1515
""" # noqa: E501
1616

1717

18-
__version__ = "60.0.0"
18+
__version__ = "60.1.0"
1919

2020
# import apis into sdk package
2121
from segment_public_api.api.api_calls_api import APICallsApi
@@ -545,6 +545,8 @@
545545
from segment_public_api.models.remove_audience_from_space200_response1 import RemoveAudienceFromSpace200Response1
546546
from segment_public_api.models.remove_audience_from_space_alpha_output import RemoveAudienceFromSpaceAlphaOutput
547547
from segment_public_api.models.remove_audience_from_space_beta_output import RemoveAudienceFromSpaceBetaOutput
548+
from segment_public_api.models.remove_audience_schedule_from_audience200_response import RemoveAudienceScheduleFromAudience200Response
549+
from segment_public_api.models.remove_audience_schedule_from_audience_alpha_output import RemoveAudienceScheduleFromAudienceAlphaOutput
548550
from segment_public_api.models.remove_computed_trait_from_space200_response import RemoveComputedTraitFromSpace200Response
549551
from segment_public_api.models.remove_computed_trait_from_space_alpha_output import RemoveComputedTraitFromSpaceAlphaOutput
550552
from segment_public_api.models.remove_filter_from_destination200_response import RemoveFilterFromDestination200Response

segment_public_api/api/activations_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
77
8-
The version of the OpenAPI document: 60.0.0
8+
The version of the OpenAPI document: 60.1.0
99
1010
Generated by OpenAPI Generator (https://openapi-generator.tech)
1111

segment_public_api/api/api_calls_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
77
8-
The version of the OpenAPI document: 60.0.0
8+
The version of the OpenAPI document: 60.1.0
99
1010
Generated by OpenAPI Generator (https://openapi-generator.tech)
1111

segment_public_api/api/audiences_api.py

Lines changed: 161 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
77
8-
The version of the OpenAPI document: 60.0.0
8+
The version of the OpenAPI document: 60.1.0
99
1010
Generated by OpenAPI Generator (https://openapi-generator.tech)
1111
@@ -42,6 +42,7 @@
4242
from segment_public_api.models.list_audiences_pagination_input import ListAudiencesPaginationInput
4343
from segment_public_api.models.pagination_input import PaginationInput
4444
from segment_public_api.models.remove_audience_from_space200_response import RemoveAudienceFromSpace200Response
45+
from segment_public_api.models.remove_audience_schedule_from_audience200_response import RemoveAudienceScheduleFromAudience200Response
4546
from segment_public_api.models.update_audience_for_space200_response import UpdateAudienceForSpace200Response
4647
from segment_public_api.models.update_audience_for_space_beta_input import UpdateAudienceForSpaceBetaInput
4748
from segment_public_api.models.update_audience_schedule_for_audience200_response import UpdateAudienceScheduleForAudience200Response
@@ -1813,6 +1814,165 @@ def remove_audience_from_space_with_http_info(self, space_id : constr(strict=Tru
18131814
collection_formats=_collection_formats,
18141815
_request_auth=_params.get('_request_auth'))
18151816

1817+
@validate_arguments
1818+
def remove_audience_schedule_from_audience(self, space_id : constr(strict=True), id : constr(strict=True), schedule_id : constr(strict=True), **kwargs) -> RemoveAudienceScheduleFromAudience200Response: # noqa: E501
1819+
"""Remove Audience Schedule from Audience # noqa: E501
1820+
1821+
Deletes an audience schedule for a Linked Audience (audienceType = LINKED). • This endpoint is in **Alpha** testing. Please submit any feedback by sending an email to [email protected]. • In order to successfully call this endpoint, the specified Workspace needs to have the Audience feature enabled. Please reach out to your customer success manager for more information. # noqa: E501
1822+
This method makes a synchronous HTTP request by default. To make an
1823+
asynchronous HTTP request, please pass async_req=True
1824+
1825+
>>> thread = api.remove_audience_schedule_from_audience(space_id, id, schedule_id, async_req=True)
1826+
>>> result = thread.get()
1827+
1828+
:param space_id: (required)
1829+
:type space_id: str
1830+
:param id: (required)
1831+
:type id: str
1832+
:param schedule_id: (required)
1833+
:type schedule_id: str
1834+
:param async_req: Whether to execute the request asynchronously.
1835+
:type async_req: bool, optional
1836+
:param _request_timeout: timeout setting for this request.
1837+
If one number provided, it will be total request
1838+
timeout. It can also be a pair (tuple) of
1839+
(connection, read) timeouts.
1840+
:return: Returns the result object.
1841+
If the method is called asynchronously,
1842+
returns the request thread.
1843+
:rtype: RemoveAudienceScheduleFromAudience200Response
1844+
"""
1845+
kwargs['_return_http_data_only'] = True
1846+
if '_preload_content' in kwargs:
1847+
message = "Error! Please call the remove_audience_schedule_from_audience_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1848+
raise ValueError(message)
1849+
return self.remove_audience_schedule_from_audience_with_http_info(space_id, id, schedule_id, **kwargs) # noqa: E501
1850+
1851+
@validate_arguments
1852+
def remove_audience_schedule_from_audience_with_http_info(self, space_id : constr(strict=True), id : constr(strict=True), schedule_id : constr(strict=True), **kwargs) -> ApiResponse: # noqa: E501
1853+
"""Remove Audience Schedule from Audience # noqa: E501
1854+
1855+
Deletes an audience schedule for a Linked Audience (audienceType = LINKED). • This endpoint is in **Alpha** testing. Please submit any feedback by sending an email to [email protected]. • In order to successfully call this endpoint, the specified Workspace needs to have the Audience feature enabled. Please reach out to your customer success manager for more information. # noqa: E501
1856+
This method makes a synchronous HTTP request by default. To make an
1857+
asynchronous HTTP request, please pass async_req=True
1858+
1859+
>>> thread = api.remove_audience_schedule_from_audience_with_http_info(space_id, id, schedule_id, async_req=True)
1860+
>>> result = thread.get()
1861+
1862+
:param space_id: (required)
1863+
:type space_id: str
1864+
:param id: (required)
1865+
:type id: str
1866+
:param schedule_id: (required)
1867+
:type schedule_id: str
1868+
:param async_req: Whether to execute the request asynchronously.
1869+
:type async_req: bool, optional
1870+
:param _preload_content: if False, the ApiResponse.data will
1871+
be set to none and raw_data will store the
1872+
HTTP response body without reading/decoding.
1873+
Default is True.
1874+
:type _preload_content: bool, optional
1875+
:param _return_http_data_only: response data instead of ApiResponse
1876+
object with status code, headers, etc
1877+
:type _return_http_data_only: bool, optional
1878+
:param _request_timeout: timeout setting for this request. If one
1879+
number provided, it will be total request
1880+
timeout. It can also be a pair (tuple) of
1881+
(connection, read) timeouts.
1882+
:param _request_auth: set to override the auth_settings for an a single
1883+
request; this effectively ignores the authentication
1884+
in the spec for a single request.
1885+
:type _request_auth: dict, optional
1886+
:type _content_type: string, optional: force content-type for the request
1887+
:return: Returns the result object.
1888+
If the method is called asynchronously,
1889+
returns the request thread.
1890+
:rtype: tuple(RemoveAudienceScheduleFromAudience200Response, status_code(int), headers(HTTPHeaderDict))
1891+
"""
1892+
1893+
_params = locals()
1894+
1895+
_all_params = [
1896+
'space_id',
1897+
'id',
1898+
'schedule_id'
1899+
]
1900+
_all_params.extend(
1901+
[
1902+
'async_req',
1903+
'_return_http_data_only',
1904+
'_preload_content',
1905+
'_request_timeout',
1906+
'_request_auth',
1907+
'_content_type',
1908+
'_headers'
1909+
]
1910+
)
1911+
1912+
# validate the arguments
1913+
for _key, _val in _params['kwargs'].items():
1914+
if _key not in _all_params:
1915+
raise ApiTypeError(
1916+
"Got an unexpected keyword argument '%s'"
1917+
" to method remove_audience_schedule_from_audience" % _key
1918+
)
1919+
_params[_key] = _val
1920+
del _params['kwargs']
1921+
1922+
_collection_formats = {}
1923+
1924+
# process the path parameters
1925+
_path_params = {}
1926+
if _params['space_id']:
1927+
_path_params['spaceId'] = _params['space_id']
1928+
1929+
if _params['id']:
1930+
_path_params['id'] = _params['id']
1931+
1932+
if _params['schedule_id']:
1933+
_path_params['scheduleId'] = _params['schedule_id']
1934+
1935+
1936+
# process the query parameters
1937+
_query_params = []
1938+
# process the header parameters
1939+
_header_params = dict(_params.get('_headers', {}))
1940+
# process the form parameters
1941+
_form_params = []
1942+
_files = {}
1943+
# process the body parameter
1944+
_body_params = None
1945+
# set the HTTP header `Accept`
1946+
_header_params['Accept'] = self.api_client.select_header_accept(
1947+
['application/vnd.segment.v1alpha+json', 'application/json']) # noqa: E501
1948+
1949+
# authentication setting
1950+
_auth_settings = ['token'] # noqa: E501
1951+
1952+
_response_types_map = {
1953+
'200': "RemoveAudienceScheduleFromAudience200Response",
1954+
'404': "RequestErrorEnvelope",
1955+
'422': "RequestErrorEnvelope",
1956+
'429': "RequestErrorEnvelope",
1957+
}
1958+
1959+
return self.api_client.call_api(
1960+
'/spaces/{spaceId}/audiences/{id}/schedules/{scheduleId}', 'DELETE',
1961+
_path_params,
1962+
_query_params,
1963+
_header_params,
1964+
body=_body_params,
1965+
post_params=_form_params,
1966+
files=_files,
1967+
response_types_map=_response_types_map,
1968+
auth_settings=_auth_settings,
1969+
async_req=_params.get('async_req'),
1970+
_return_http_data_only=_params.get('_return_http_data_only'), # noqa: E501
1971+
_preload_content=_params.get('_preload_content', True),
1972+
_request_timeout=_params.get('_request_timeout'),
1973+
collection_formats=_collection_formats,
1974+
_request_auth=_params.get('_request_auth'))
1975+
18161976
@validate_arguments
18171977
def update_audience_for_space(self, space_id : constr(strict=True), id : constr(strict=True), update_audience_for_space_beta_input : UpdateAudienceForSpaceBetaInput, **kwargs) -> UpdateAudienceForSpace200Response: # noqa: E501
18181978
"""Update Audience for Space # noqa: E501

segment_public_api/api/audit_trail_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
77
8-
The version of the OpenAPI document: 60.0.0
8+
The version of the OpenAPI document: 60.1.0
99
1010
Generated by OpenAPI Generator (https://openapi-generator.tech)
1111

segment_public_api/api/catalog_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
77
8-
The version of the OpenAPI document: 60.0.0
8+
The version of the OpenAPI document: 60.1.0
99
1010
Generated by OpenAPI Generator (https://openapi-generator.tech)
1111

0 commit comments

Comments
 (0)