Skip to content

Commit 5f82b47

Browse files
Update generated SDKs (#1153)
* build(codegen): updating SDK * build(codegen): updating SDK --------- Co-authored-by: ct-sdks[bot] <153784748+ct-sdks[bot]@users.noreply.github.com> Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
1 parent 0a6ea36 commit 5f82b47

File tree

8 files changed

+134
-22
lines changed

8 files changed

+134
-22
lines changed

.changeset/changes_api.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@
44

55
**Api changes**
66

7+
<details>
8+
<summary>Added Property(s)</summary>
9+
10+
- added property `minCartQuantity` to type `InventoryEntry`
11+
- added property `maxCartQuantity` to type `InventoryEntry`
12+
- added property `minCartQuantity` to type `InventoryEntryDraft`
13+
- added property `maxCartQuantity` to type `InventoryEntryDraft`
14+
</details>
15+
716
<details>
817
<summary>Added Type(s)</summary>
918

@@ -17,12 +26,10 @@
1726
</details>
1827

1928
<details>
20-
<summary>Added Property(s)</summary>
29+
<summary>Added Method(s)</summary>
2130

22-
- added property `minCartQuantity` to type `InventoryEntry`
23-
- added property `maxCartQuantity` to type `InventoryEntry`
24-
- added property `minCartQuantity` to type `InventoryEntryDraft`
25-
- added property `maxCartQuantity` to type `InventoryEntryDraft`
31+
- added method `apiRoot.withProjectKey().recurrencePolicies().withKey().delete()`
32+
- added method `apiRoot.withProjectKey().recurrencePolicies().withId().delete()`
2633
</details>
2734

2835
<details>

.changeset/changes_import.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,6 @@
2323
- added type `DivisionBusinessUnitImport`
2424
</details>
2525

26-
<details>
27-
<summary>Added Method(s)</summary>
28-
29-
- added method `apiRoot.withProjectKeyValue().businessUnits().importContainers().withImportContainerKeyValue().post()`
30-
</details>
31-
3226
<details>
3327
<summary>Added Resource(s)</summary>
3428

@@ -37,6 +31,12 @@
3731
- added resource `/{projectKey}/business-units/import-containers/{importContainerKey}`
3832
</details>
3933

34+
<details>
35+
<summary>Added Method(s)</summary>
36+
37+
- added method `apiRoot.withProjectKeyValue().businessUnits().importContainers().withImportContainerKeyValue().post()`
38+
</details>
39+
4040
<details>
4141
<summary>Added Enum(s)</summary>
4242

changes.md

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
**Api changes**
22

3+
<details>
4+
<summary>Added Property(s)</summary>
5+
6+
- added property `minCartQuantity` to type `InventoryEntry`
7+
- added property `maxCartQuantity` to type `InventoryEntry`
8+
- added property `minCartQuantity` to type `InventoryEntryDraft`
9+
- added property `maxCartQuantity` to type `InventoryEntryDraft`
10+
</details>
11+
312
<details>
413
<summary>Added Type(s)</summary>
514

@@ -13,12 +22,10 @@
1322
</details>
1423

1524
<details>
16-
<summary>Added Property(s)</summary>
25+
<summary>Added Method(s)</summary>
1726

18-
- added property `minCartQuantity` to type `InventoryEntry`
19-
- added property `maxCartQuantity` to type `InventoryEntry`
20-
- added property `minCartQuantity` to type `InventoryEntryDraft`
21-
- added property `maxCartQuantity` to type `InventoryEntryDraft`
27+
- added method `apiRoot.withProjectKey().recurrencePolicies().withKey().delete()`
28+
- added method `apiRoot.withProjectKey().recurrencePolicies().withId().delete()`
2229
</details>
2330

2431
<details>
@@ -48,12 +55,6 @@
4855
- added type `DivisionBusinessUnitImport`
4956
</details>
5057

51-
<details>
52-
<summary>Added Method(s)</summary>
53-
54-
- added method `apiRoot.withProjectKeyValue().businessUnits().importContainers().withImportContainerKeyValue().post()`
55-
</details>
56-
5758
<details>
5859
<summary>Added Resource(s)</summary>
5960

@@ -62,6 +63,12 @@
6263
- added resource `/{projectKey}/business-units/import-containers/{importContainerKey}`
6364
</details>
6465

66+
<details>
67+
<summary>Added Method(s)</summary>
68+
69+
- added method `apiRoot.withProjectKeyValue().businessUnits().importContainers().withImportContainerKeyValue().post()`
70+
</details>
71+
6572
<details>
6673
<summary>Added Enum(s)</summary>
6774

packages/platform-sdk/src/generated/client/recurrence-policies/by-project-key-recurrence-policies-by-id-request-builder.ts

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,34 @@ export class ByProjectKeyRecurrencePoliciesByIDRequestBuilder {
101101
this.args.executeRequest
102102
)
103103
}
104+
/**
105+
* Deletes a Recurrence Policy in the Project.
106+
*
107+
* A Recurrence Policy can be deleted only if it is not referenced by any Embedded Price, Standalone Price, or (Custom) Line Item, otherwise a [ReferenceExists](ctp:api:type:ReferenceExistsError) error is returned.
108+
*
109+
*/
110+
public delete(methodArgs: {
111+
queryArgs: {
112+
version: number
113+
expand?: string | string[]
114+
[key: string]: QueryParam
115+
}
116+
headers?: {
117+
[key: string]: string | string[]
118+
}
119+
}): ApiRequest<RecurrencePolicy> {
120+
return new ApiRequest<RecurrencePolicy>(
121+
{
122+
baseUri: this.args.baseUri,
123+
method: 'DELETE',
124+
uriTemplate: '/{projectKey}/recurrence-policies/{ID}',
125+
pathVariables: this.args.pathArgs,
126+
headers: {
127+
...methodArgs?.headers,
128+
},
129+
queryParams: methodArgs?.queryArgs,
130+
},
131+
this.args.executeRequest
132+
)
133+
}
104134
}

packages/platform-sdk/src/generated/client/recurrence-policies/by-project-key-recurrence-policies-key-by-key-request-builder.ts

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,34 @@ export class ByProjectKeyRecurrencePoliciesKeyByKeyRequestBuilder {
101101
this.args.executeRequest
102102
)
103103
}
104+
/**
105+
* Deletes a Recurrence Policy in the Project.
106+
*
107+
* A Recurrence Policy can be deleted only if it is not referenced by any Embedded Price, Standalone Price, or (Custom) Line Item, otherwise a [ReferenceExists](ctp:api:type:ReferenceExistsError) error is returned.
108+
*
109+
*/
110+
public delete(methodArgs: {
111+
queryArgs: {
112+
version: number
113+
expand?: string | string[]
114+
[key: string]: QueryParam
115+
}
116+
headers?: {
117+
[key: string]: string | string[]
118+
}
119+
}): ApiRequest<RecurrencePolicy> {
120+
return new ApiRequest<RecurrencePolicy>(
121+
{
122+
baseUri: this.args.baseUri,
123+
method: 'DELETE',
124+
uriTemplate: '/{projectKey}/recurrence-policies/key={key}',
125+
pathVariables: this.args.pathArgs,
126+
headers: {
127+
...methodArgs?.headers,
128+
},
129+
queryParams: methodArgs?.queryArgs,
130+
},
131+
this.args.executeRequest
132+
)
133+
}
104134
}

packages/platform-sdk/test/generated/client/recurrence-policies/by-project-key-recurrence-policies-by-id-request-builder.test.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,24 @@ export function getRequestsWithMethodParameters(): RequestWithMethod[] {
5656
.withId({ ID: 'test_ID' })
5757
.post({ body: null, headers: null }),
5858
},
59+
{
60+
method: 'delete',
61+
uri: '/test_projectKey/recurrence-policies/test_ID?version=2',
62+
request: apiRoot
63+
.withProjectKey({ projectKey: 'test_projectKey' })
64+
.recurrencePolicies()
65+
.withId({ ID: 'test_ID' })
66+
.delete({ queryArgs: { version: 2 } }),
67+
},
68+
{
69+
method: 'delete',
70+
uri: '/test_projectKey/recurrence-policies/test_ID?expand=expand&version=2',
71+
request: apiRoot
72+
.withProjectKey({ projectKey: 'test_projectKey' })
73+
.recurrencePolicies()
74+
.withId({ ID: 'test_ID' })
75+
.delete({ queryArgs: { expand: 'expand', version: 2 } }),
76+
},
5977
]
6078
}
6179

packages/platform-sdk/test/generated/client/recurrence-policies/by-project-key-recurrence-policies-key-by-key-request-builder.test.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,24 @@ export function getRequestsWithMethodParameters(): RequestWithMethod[] {
5656
.withKey({ key: 'test_key' })
5757
.post({ body: null, headers: null }),
5858
},
59+
{
60+
method: 'delete',
61+
uri: '/test_projectKey/recurrence-policies/key=test_key?version=2',
62+
request: apiRoot
63+
.withProjectKey({ projectKey: 'test_projectKey' })
64+
.recurrencePolicies()
65+
.withKey({ key: 'test_key' })
66+
.delete({ queryArgs: { version: 2 } }),
67+
},
68+
{
69+
method: 'delete',
70+
uri: '/test_projectKey/recurrence-policies/key=test_key?expand=expand&version=2',
71+
request: apiRoot
72+
.withProjectKey({ projectKey: 'test_projectKey' })
73+
.recurrencePolicies()
74+
.withKey({ key: 'test_key' })
75+
.delete({ queryArgs: { expand: 'expand', version: 2 } }),
76+
},
5977
]
6078
}
6179

references.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -449,3 +449,5 @@ d084ab15a8dfa7bd18efa10417a0bb263c08f269
449449
89f530b1e54b0b03f530d64a8c36e901b6d020c1
450450
48dc5d57bbfede103bdf01023deea4f649dc5cae
451451
291e2569b7c0e4f1db3bb99761c7b23e0cc1659f
452+
b6d7def74db12344b0e0821407b45a3f214b8bd9
453+
f8b027c8e1b5ba61ace3d3d358b9efc7ad4b93eb

0 commit comments

Comments
 (0)