Skip to content

Update generated SDKs #651

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import io.vrap.rmf.base.client.utils.Generated;

/**
* <p>This update action results in the <code>taxedPrice</code> field being added to the Cart when the <code>ExternalAmount</code> TaxMode is used.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action adds the <code>taxedPrice</code> field to the Cart and must be used after any price-affecting change occurs within the Cart.</p>
*
* <hr>
* Example to create an instance using the builder pattern
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import org.apache.commons.lang3.builder.ToStringStyle;

/**
* <p>This update action results in the <code>taxedPrice</code> field being added to the Cart when the <code>ExternalAmount</code> TaxMode is used.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action adds the <code>taxedPrice</code> field to the Cart and must be used after any price-affecting change occurs within the Cart.</p>
*/
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen")
public class CartSetCartTotalTaxActionImpl implements CartSetCartTotalTaxAction, ModelBase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import io.vrap.rmf.base.client.utils.Generated;

/**
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action sets the <code>taxedPrice</code> and <code>taxRate</code> on a Line Item and must be used after any price-affecting change occurs.</p>
*
* <hr>
* Example to create an instance using the builder pattern
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import org.apache.commons.lang3.builder.ToStringStyle;

/**
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action sets the <code>taxedPrice</code> and <code>taxRate</code> on a Line Item and must be used after any price-affecting change occurs.</p>
*/
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen")
public class CartSetLineItemTaxAmountActionImpl implements CartSetLineItemTaxAmountAction, ModelBase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,39 @@
public interface TaxMode extends JsonEnum {

/**
<p>Tax Rates are selected automatically from the TaxCategories based on the Cart <code>shippingAddress</code>. This is the default tax mode for a new Cart.</p>
<p><code>totalNet</code>, <code>totalGross</code>, and <code>taxPortions</code> fields are calculated based on the <code>taxRoundingMode</code>.</p> */
<ul>
<li><p>Tax Rates are selected automatically from the TaxCategories based on the Cart <code>shippingAddress</code>. This is the default tax mode for a new Cart.</p></li>
<li><p>The <code>totalNet</code>, <code>totalGross</code>, and <code>taxPortions</code> fields are calculated based on the <code>taxRoundingMode</code>.</p></li>
</ul> */
TaxMode PLATFORM = TaxModeEnum.PLATFORM;
/**
<p>Tax Rates are set externally per ExternalTaxRateDraft. A Cart can be ordered only if all Line Items, Custom Line Items, and the Shipping Method have an external Tax Rate set.</p>
<p><code>totalNet</code>, <code>totalGross</code>, and <code>taxPortions</code> fields are calculated based on the <code>taxRoundingMode</code>.</p> */
<ul>
<li><p>Tax Rates are set externally with ExternalTaxRateDraft. A Cart can be ordered only if all Line Items, Custom Line Items, and the Shipping Method have an external Tax Rate set.</p></li>
<li><p>The <code>totalNet</code>, <code>totalGross</code>, and <code>taxPortions</code> fields are calculated based on the <code>taxRoundingMode</code>.</p></li>
</ul> */
TaxMode EXTERNAL = TaxModeEnum.EXTERNAL;
/**
<p>Tax amounts, Tax Rates, and tax portions are set externally per ExternalTaxAmountDraft. A Cart can be ordered only if the Cart and all Line Items, Custom Line Items, and the Shipping Method have an external tax amount and rate set.</p>
<p>Price-specific update actions on Carts require external recalculation of the total gross price. Hence, the <code>externalTaxAmount</code> is removed in these cases and must be reset with Set LineItem TaxAmount, Set CustomLineItem TaxAmount, or Set ShippingMethod TaxAmount update actions. Also the Cart <code>taxedPrice</code> field must be explicitly set via Set Cart Total Tax. Since the API currently does not offer an update action for setting the <code>taxedShippingPrice</code> field of a Cart with <code>ExternalAmount</code> tax mode, it will always be empty.</p> */
<ul>
<li><p>Tax amounts, Tax Rates, and tax portions are set externally with ExternalTaxAmountDraft. A Cart can be ordered only if the Cart and all Line Items, Custom Line Items, and the Shipping Method have an external tax amount and rate set.</p></li>
<li><p>The Cart <code>taxedPrice</code> field must be set using Set Cart Total Tax. The Cart <code>taxedShippingPrice</code> field is always empty in this tax mode.</p></li>
<li><p>Price-affecting update actions on Carts require external recalculation of the total gross price. In these cases, <code>taxedPrice</code> and <code>taxRate</code> are removed and must be set again. The order in which the individual update actions are issued is important:</p>
<ol>
<li><p>Issue the price-affecting update action(s).</p></li>
<li><p>Update the tax amounts using Set LineItem TaxAmount, Set CustomLineItem TaxAmount, or Set ShippingMethod TaxAmount.</p>
<ul>
<li><p>If the update action changes the Line Item price, for Line Items with <code>Platform</code> LineItemPriceMode, you must issue Set LineItem TaxAmount in a <em>separate</em> request.</p></li>
<li><p>If the update action removes the externally set tax amount for the Shipping Method, you must issue Set ShippingMethod TaxAmount in a <em>separate</em> request.</p></li>
</ul></li>
<li><p>Update the <code>taxedPrice</code> on Cart using Set Cart Total Tax.</p></li>
</ol></li>
<li><p>Tax-inclusive pricing should be avoided when using TaxMode <code>ExternalAmount</code> because <code>taxedItemPrice.totalNet</code> is automatically set by the platform to the Line Item's <code>totalPrice</code>.</p></li>
</ul> */
TaxMode EXTERNAL_AMOUNT = TaxModeEnum.EXTERNAL_AMOUNT;
/**
<p>No taxes are added to the Cart.</p>
<p>Note that this tax mode cannot be set on the My Carts API.</p> */
<ul>
<li>No taxes are added to the Cart.</li>
<li>This tax mode cannot be set on the My Carts API.</li>
</ul> */
TaxMode DISABLED = TaxModeEnum.DISABLED;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import io.vrap.rmf.base.client.utils.Generated;

/**
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action sets the <code>taxedPrice</code> and <code>taxRate</code> on a Line Item and must be used after any price-affecting change occurs.</p>
*
* <hr>
* Example to create an instance using the builder pattern
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import org.apache.commons.lang3.builder.ToStringStyle;

/**
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode.</p>
* <p>Can be used if the Cart has the <code>ExternalAmount</code> TaxMode. This update action sets the <code>taxedPrice</code> and <code>taxRate</code> on a Line Item and must be used after any price-affecting change occurs.</p>
*/
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen")
public class StagedOrderSetLineItemTaxAmountActionImpl implements StagedOrderSetLineItemTaxAmountAction, ModelBase {
Expand Down
1 change: 1 addition & 0 deletions references.txt
Original file line number Diff line number Diff line change
Expand Up @@ -238,3 +238,4 @@ cdb527e0fe5524d6c7411066fca556e1b3403003
f1d13dc3acf6960cda08494da701d04a46f9eb3f
eac13cfcb88a83f4f4e977ba51c0b11e458cff61
6abab3f555aab9f5aa5b8a1b551235188fbb9201
1b650bc8eb1a78c3487484900b1e36d06226c6e2
Loading