Skip to content

Commit 92fd3db

Browse files
committed
feat(API): add pr_branch param to repo-sync export #SCD-594
1 parent 5519e1b commit 92fd3db

File tree

3 files changed

+26
-3
lines changed

3 files changed

+26
-3
lines changed

doc/compiled.json

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4886,6 +4886,16 @@
48864886
},
48874887
"example": "my-feature-branch"
48884888
},
4889+
"pr_branch": {
4890+
"name": "pr_branch",
4891+
"in": "query",
4892+
"description": "Source branch to open a pull request from",
4893+
"required": false,
4894+
"schema": {
4895+
"type": "string"
4896+
},
4897+
"example": "my-feature-branch"
4898+
},
48894899
"page": {
48904900
"in": "query",
48914901
"name": "page",
@@ -22603,6 +22613,9 @@
2260322613
},
2260422614
{
2260522615
"$ref": "#/components/parameters/id"
22616+
},
22617+
{
22618+
"$ref": "#/components/parameters/pr_branch"
2260622619
}
2260722620
],
2260822621
"responses": {
@@ -22640,11 +22653,11 @@
2264022653
"x-code-samples": [
2264122654
{
2264222655
"lang": "Curl",
22643-
"source": "curl \"https://api.phrase.com/v2/accounts/ab12cd34/repo_syncs/45ef6789/export\"\\\n -u USERNAME_OR_ACCESS_TOKEN \\\n -X POST \\\n -H 'Content-Type: application/json'"
22656+
"source": "curl \"https://api.phrase.com/v2/accounts/ab12cd34/repo_syncs/45ef6789/export?pr_branch=my-feature-branch\"\\\n -u USERNAME_OR_ACCESS_TOKEN \\\n -X POST \\\n -H 'Content-Type: application/json'"
2264422657
},
2264522658
{
2264622659
"lang": "CLI v2",
22647-
"source": "phrase repo_syncs export \\\n--id <repo_sync_id> \\\n--access_token <token>"
22660+
"source": "phrase repo_syncs export \\\n--id <repo_sync_id> \\\n--pr_branch my-feature-branch \\\n--access_token <token>"
2264822661
}
2264922662
],
2265022663
"x-cli-version": "2.24"

parameters.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,14 @@ branch:
214214
schema:
215215
type: string
216216
example: my-feature-branch
217+
pr_branch:
218+
name: pr_branch
219+
in: query
220+
description: Source branch to open a pull request from
221+
required: false
222+
schema:
223+
type: string
224+
example: my-feature-branch
217225
page:
218226
in: query
219227
name: page

paths/repo_syncs/export.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ parameters:
1212
- "$ref": "../../parameters.yaml#/X-PhraseApp-OTP"
1313
- "$ref": "../../parameters.yaml#/account_id"
1414
- "$ref": "../../parameters.yaml#/id"
15+
- "$ref": "../../parameters.yaml#/pr_branch"
1516
responses:
1617
'200':
1718
description: OK
@@ -35,13 +36,14 @@ responses:
3536
x-code-samples:
3637
- lang: Curl
3738
source: |-
38-
curl "https://api.phrase.com/v2/accounts/ab12cd34/repo_syncs/45ef6789/export"\
39+
curl "https://api.phrase.com/v2/accounts/ab12cd34/repo_syncs/45ef6789/export?pr_branch=my-feature-branch"\
3940
-u USERNAME_OR_ACCESS_TOKEN \
4041
-X POST \
4142
-H 'Content-Type: application/json'
4243
- lang: CLI v2
4344
source: |-
4445
phrase repo_syncs export \
4546
--id <repo_sync_id> \
47+
--pr_branch my-feature-branch \
4648
--access_token <token>
4749
x-cli-version: '2.24'

0 commit comments

Comments
 (0)