Skip to content

Commit f2ca099

Browse files
author
Phrase
committed
1 parent 7cb8fac commit f2ca099

13 files changed

Lines changed: 75 additions & 22 deletions

docs/RepoSyncExportParameters.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
Name | Type | Description | Notes
55
------------ | ------------- | ------------- | -------------
66
**pr_branch** | **str** | Source branch to open a pull request from | [optional]
7+
**branch** | **str** | Strings branch to export from | [optional]
78

89
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
910

docs/RepoSyncImportParameters.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
Name | Type | Description | Notes
55
------------ | ------------- | ------------- | -------------
66
**repository_branch** | **str** | Branch to import from | [optional]
7+
**branch** | **str** | Strings branch to import to | [optional]
78

89
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
910

docs/RepoSyncsApi.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ Name | Type | Description | Notes
219219
[[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)
220220

221221
# **repo_sync_import**
222-
> RepoSyncEvent repo_sync_import(account_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch, repo_sync_import_parameters=repo_sync_import_parameters)
222+
> RepoSyncEvent repo_sync_import(account_id, id, x_phrase_app_otp=x_phrase_app_otp, repo_sync_import_parameters=repo_sync_import_parameters)
223223
224224
Import from code repository
225225

@@ -245,12 +245,11 @@ with phrase_api.ApiClient(configuration) as api_client:
245245
account_id = 'account_id_example' # str | Account ID (required)
246246
id = 'id_example' # str | ID (required)
247247
x_phrase_app_otp = 'x_phrase_app_otp_example' # str | Two-Factor-Authentication token (optional)
248-
branch = 'my-feature-branch' # str | Branch to use
249248
repo_sync_import_parameters = phrase_api.RepoSyncImportParameters() # RepoSyncImportParameters |
250249

251250
try:
252251
# Import from code repository
253-
api_response = api_instance.repo_sync_import(account_id, id, x_phrase_app_otp=x_phrase_app_otp, branch=branch, repo_sync_import_parameters=repo_sync_import_parameters)
252+
api_response = api_instance.repo_sync_import(account_id, id, x_phrase_app_otp=x_phrase_app_otp, repo_sync_import_parameters=repo_sync_import_parameters)
254253
pprint(api_response)
255254
except ApiException as e:
256255
print("Exception when calling RepoSyncsApi->repo_sync_import: %s\n" % e)
@@ -264,7 +263,6 @@ Name | Type | Description | Notes
264263
**account_id** | **str**| Account ID |
265264
**id** | **str**| ID |
266265
**x_phrase_app_otp** | **str**| Two-Factor-Authentication token (optional) | [optional]
267-
**branch** | **str**| Branch to use | [optional]
268266
**repo_sync_import_parameters** | [**RepoSyncImportParameters**](RepoSyncImportParameters.md)| | [optional]
269267

270268
### Return type

phrase_api/api/repo_syncs_api.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,6 @@ def repo_sync_import(self, account_id, id, **kwargs): # noqa: E501
441441
:param str account_id: Account ID (required)
442442
:param str id: ID (required)
443443
:param str x_phrase_app_otp: Two-Factor-Authentication token (optional)
444-
:param str branch: Branch to use
445444
:param RepoSyncImportParameters repo_sync_import_parameters:
446445
:param _preload_content: if False, the urllib3.HTTPResponse object will
447446
be returned without reading/decoding response
@@ -470,7 +469,6 @@ def repo_sync_import_with_http_info(self, account_id, id, **kwargs): # noqa: E5
470469
:param str account_id: Account ID (required)
471470
:param str id: ID (required)
472471
:param str x_phrase_app_otp: Two-Factor-Authentication token (optional)
473-
:param str branch: Branch to use
474472
:param RepoSyncImportParameters repo_sync_import_parameters:
475473
:param _return_http_data_only: response data without head status code
476474
and headers
@@ -492,7 +490,6 @@ def repo_sync_import_with_http_info(self, account_id, id, **kwargs): # noqa: E5
492490
'account_id',
493491
'id',
494492
'x_phrase_app_otp',
495-
'branch',
496493
'repo_sync_import_parameters'
497494
]
498495
all_params.extend(
@@ -530,8 +527,6 @@ def repo_sync_import_with_http_info(self, account_id, id, **kwargs): # noqa: E5
530527
path_params['id'] = local_var_params['id'] # noqa: E501
531528

532529
query_params = []
533-
if 'branch' in local_var_params and local_var_params['branch'] is not None: # noqa: E501
534-
query_params.append(('branch', local_var_params['branch'])) # noqa: E501
535530

536531
header_params = {}
537532
if 'x_phrase_app_otp' in local_var_params:

phrase_api/models/repo_sync_export_parameters.py

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,24 +32,29 @@ class RepoSyncExportParameters(object):
3232
and the value is json key in definition.
3333
"""
3434
openapi_types = {
35-
'pr_branch': 'str'
35+
'pr_branch': 'str',
36+
'branch': 'str'
3637
}
3738

3839
attribute_map = {
39-
'pr_branch': 'pr_branch'
40+
'pr_branch': 'pr_branch',
41+
'branch': 'branch'
4042
}
4143

42-
def __init__(self, pr_branch=None, local_vars_configuration=None): # noqa: E501
44+
def __init__(self, pr_branch=None, branch=None, local_vars_configuration=None): # noqa: E501
4345
"""RepoSyncExportParameters - a model defined in OpenAPI""" # noqa: E501
4446
if local_vars_configuration is None:
4547
local_vars_configuration = Configuration()
4648
self.local_vars_configuration = local_vars_configuration
4749

4850
self._pr_branch = None
51+
self._branch = None
4952
self.discriminator = None
5053

5154
if pr_branch is not None:
5255
self.pr_branch = pr_branch
56+
if branch is not None:
57+
self.branch = branch
5358

5459
@property
5560
def pr_branch(self):
@@ -74,6 +79,29 @@ def pr_branch(self, pr_branch):
7479

7580
self._pr_branch = pr_branch
7681

82+
@property
83+
def branch(self):
84+
"""Gets the branch of this RepoSyncExportParameters. # noqa: E501
85+
86+
Strings branch to export from # noqa: E501
87+
88+
:return: The branch of this RepoSyncExportParameters. # noqa: E501
89+
:rtype: str
90+
"""
91+
return self._branch
92+
93+
@branch.setter
94+
def branch(self, branch):
95+
"""Sets the branch of this RepoSyncExportParameters.
96+
97+
Strings branch to export from # noqa: E501
98+
99+
:param branch: The branch of this RepoSyncExportParameters. # noqa: E501
100+
:type: str
101+
"""
102+
103+
self._branch = branch
104+
77105
def to_dict(self):
78106
"""Returns the model properties as a dict"""
79107
result = {}

phrase_api/models/repo_sync_import_parameters.py

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,24 +32,29 @@ class RepoSyncImportParameters(object):
3232
and the value is json key in definition.
3333
"""
3434
openapi_types = {
35-
'repository_branch': 'str'
35+
'repository_branch': 'str',
36+
'branch': 'str'
3637
}
3738

3839
attribute_map = {
39-
'repository_branch': 'repository_branch'
40+
'repository_branch': 'repository_branch',
41+
'branch': 'branch'
4042
}
4143

42-
def __init__(self, repository_branch=None, local_vars_configuration=None): # noqa: E501
44+
def __init__(self, repository_branch=None, branch=None, local_vars_configuration=None): # noqa: E501
4345
"""RepoSyncImportParameters - a model defined in OpenAPI""" # noqa: E501
4446
if local_vars_configuration is None:
4547
local_vars_configuration = Configuration()
4648
self.local_vars_configuration = local_vars_configuration
4749

4850
self._repository_branch = None
51+
self._branch = None
4952
self.discriminator = None
5053

5154
if repository_branch is not None:
5255
self.repository_branch = repository_branch
56+
if branch is not None:
57+
self.branch = branch
5358

5459
@property
5560
def repository_branch(self):
@@ -74,6 +79,29 @@ def repository_branch(self, repository_branch):
7479

7580
self._repository_branch = repository_branch
7681

82+
@property
83+
def branch(self):
84+
"""Gets the branch of this RepoSyncImportParameters. # noqa: E501
85+
86+
Strings branch to import to # noqa: E501
87+
88+
:return: The branch of this RepoSyncImportParameters. # noqa: E501
89+
:rtype: str
90+
"""
91+
return self._branch
92+
93+
@branch.setter
94+
def branch(self, branch):
95+
"""Sets the branch of this RepoSyncImportParameters.
96+
97+
Strings branch to import to # noqa: E501
98+
99+
:param branch: The branch of this RepoSyncImportParameters. # noqa: E501
100+
:type: str
101+
"""
102+
103+
self._branch = branch
104+
77105
def to_dict(self):
78106
"""Returns the model properties as a dict"""
79107
result = {}

test/test_key_create_parameters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def make_instance(self, include_optional):
4646
data_type = 'number',
4747
tags = 'awesome-feature,needs-proofreading',
4848
max_characters_allowed = 140,
49-
screenshot = '[B@46808854',
49+
screenshot = '[B@13666880',
5050
remove_screenshot = True,
5151
unformatted = True,
5252
default_translation_content = 'Default translation content',

test/test_key_update_parameters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def make_instance(self, include_optional):
4646
data_type = 'number',
4747
tags = 'awesome-feature,needs-proofreading',
4848
max_characters_allowed = 140,
49-
screenshot = '[B@59bedf4d',
49+
screenshot = '[B@40ee8512',
5050
remove_screenshot = True,
5151
unformatted = True,
5252
xml_space_preserve = True,

test/test_project_create_parameters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def make_instance(self, include_optional):
4141
main_format = 'yml',
4242
media = 'Python',
4343
shares_translation_memory = True,
44-
project_image = '[B@494e502c',
44+
project_image = '[B@35f9c37c',
4545
remove_project_image = True,
4646
account_id = 'abcd1234',
4747
point_of_contact = 'abcd1234',

test/test_project_update_parameters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def make_instance(self, include_optional):
4343
main_format = 'yml',
4444
media = 'Python',
4545
shares_translation_memory = True,
46-
project_image = '[B@1d904637',
46+
project_image = '[B@18f9745a',
4747
remove_project_image = False,
4848
workflow = 'review',
4949
machine_translation_enabled = True,

0 commit comments

Comments
 (0)