Skip to content

Commit

Permalink
Merge pull request #366 from commercetools/gen-sdk-updates
Browse files Browse the repository at this point in the history
Update generated SDKs
  • Loading branch information
kodiakhq[bot] authored Oct 18, 2024
2 parents a0c1ef2 + 4d88add commit cf18dc3
Show file tree
Hide file tree
Showing 5 changed files with 95 additions and 46 deletions.
48 changes: 2 additions & 46 deletions changes.md
Original file line number Diff line number Diff line change
@@ -1,52 +1,8 @@
**Api changes**

<details>
<summary>Added Property(s)</summary>
<summary>Added Method(s)</summary>

- added property `staged` to type `ProductVariantDeletedMessage`
- added property `staged` to type `ProductVariantDeletedMessagePayload`
- added property `warnings` to type `ProductTailoring`
- added property `attributes` to type `ProductVariantTailoring`
- added property `attributes` to type `ProductVariantTailoringDraft`
- added property `attributes` to type `ProductTailoringAddVariantAction`
- added property `warnings` to type `Product`
- added property `customers` to type `SearchIndexingConfiguration`
</details>


<details>
<summary>Added Type(s)</summary>

- added type `SearchNotReadyError`
- added type `GraphQLSearchNotReadyError`
- added type `ProductTailoringAttribute`
- added type `ProductTailoringSetAttributeAction`
- added type `ProductTailoringSetAttributeInAllVariantsAction`
- added type `ImageProcessingOngoingWarning`
- added type `WarningObject`
</details>


<details>
<summary>Removed Type(s)</summary>

- :warning: removed type `ProductSearchStatus`
</details>


<details>
<summary>Added Enum(s)</summary>

- added enum `customer-group` to type `ExtensionResourceTypeId`
- added enum `product-tailoring` to type `MessageSubscriptionResourceTypeId`
- added enum `product-tailoring` to type `ResourceTypeId`
</details>

**Import changes**

<details>
<summary>Added Type(s)</summary>

- added type `InvalidFieldsUpdateError`
- added method `apiRoot.withProjectKey().productTailoring().head()`
</details>

Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,25 @@ public static IEnumerable<object[]> GetData()
"Get",
"/test_projectKey/product-tailoring",
},
new Object[] {
ApiRoot
.WithProjectKey("test_projectKey")
.ProductTailoring()
.Head()
.WithWhere("where")
.Build(),
"Head",
"/test_projectKey/product-tailoring?where=where",
},
new Object[] {
ApiRoot
.WithProjectKey("test_projectKey")
.ProductTailoring()
.Head()
.Build(),
"Head",
"/test_projectKey/product-tailoring",
},
new Object[] {
ApiRoot
.WithProjectKey("test_projectKey")
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
using System.Collections.Generic;
using System.Net.Http;
using System.Threading.Tasks;
using System.Threading;
using commercetools.Base.Client;


// ReSharper disable CheckNamespace
namespace commercetools.Sdk.Api.Client.RequestBuilders.ProductTailoring
{

public partial class ByProjectKeyProductTailoringHead : ApiMethod<ByProjectKeyProductTailoringHead>, IApiMethod<ByProjectKeyProductTailoringHead, string>, commercetools.Sdk.Api.Client.IErrorableTrait<ByProjectKeyProductTailoringHead>, commercetools.Sdk.Api.Client.IDeprecatable200Trait<ByProjectKeyProductTailoringHead>
{


private IClient ApiHttpClient { get; }

public override HttpMethod Method => HttpMethod.Head;

private string ProjectKey { get; }


public ByProjectKeyProductTailoringHead(IClient apiHttpClient, string projectKey)
{
this.ApiHttpClient = apiHttpClient;
this.ProjectKey = projectKey;
this.RequestUrl = $"/{ProjectKey}/product-tailoring";
}

public List<string> GetWhere()
{
return this.GetQueryParam("where");
}

public ByProjectKeyProductTailoringHead WithWhere(string where)
{
return this.AddQueryParam("where", where);
}


public async Task<string> ExecuteAsync(CancellationToken cancellationToken = default)
{

return await ExecuteAsJsonAsync(cancellationToken);

}

public async Task<string> ExecuteAsJsonAsync(CancellationToken cancellationToken = default)
{
var requestMessage = Build();
return await ApiHttpClient.ExecuteAsJsonAsync(requestMessage, cancellationToken);
}

public async Task<IApiResponse<string>> SendAsync(CancellationToken cancellationToken = default)
{

return await SendAsJsonAsync(cancellationToken);

}

public async Task<IApiResponse<string>> SendAsJsonAsync(CancellationToken cancellationToken = default)
{
var requestMessage = Build();
return await ApiHttpClient.SendAsJsonAsync(requestMessage, cancellationToken);
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ public ByProjectKeyProductTailoringGet Get()
return new ByProjectKeyProductTailoringGet(ApiHttpClient, ProjectKey);
}

public ByProjectKeyProductTailoringHead Head()
{
return new ByProjectKeyProductTailoringHead(ApiHttpClient, ProjectKey);
}

public ByProjectKeyProductTailoringPost Post(commercetools.Sdk.Api.Models.ProductTailorings.IProductTailoringDraft productTailoringDraft)
{
return new ByProjectKeyProductTailoringPost(ApiHttpClient, SerializerService, ProjectKey, productTailoringDraft);
Expand Down
1 change: 1 addition & 0 deletions references.txt
Original file line number Diff line number Diff line change
Expand Up @@ -287,3 +287,4 @@ c77ec902f368c2c31505fcb65a835ce148350077
903922e6a2dc0ff9283757645395f5119f61be0e
e985f4b7aa55610705ee49bd3eb645c2fd03eb6c
7b61d389a7b8bd5dac2d780c6b6fbea0b881400c
c27603f949e869148570ebb8bd3ec6db34a985b7

0 comments on commit cf18dc3

Please sign in to comment.