Skip to content

[legalentitymanagement] Code generation: update services and models#1912

Open
AdyenAutomationBot wants to merge 1 commit intomainfrom
sdk-automation/legalentitymanagement
Open

[legalentitymanagement] Code generation: update services and models#1912
AdyenAutomationBot wants to merge 1 commit intomainfrom
sdk-automation/legalentitymanagement

Conversation

@AdyenAutomationBot
Copy link
Copy Markdown
Collaborator

@AdyenAutomationBot AdyenAutomationBot commented Apr 14, 2026

This PR contains the automated changes for the legalentitymanagement service.

The commit history of this PR reflects the adyen-openapi commits that have been applied.

@AdyenAutomationBot AdyenAutomationBot requested review from a team as code owners April 14, 2026 07:38
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the Legal Entity Management SDK by adding the industryCodeDescription field to the BusinessLine, BusinessLineInfo, and BusinessLineInfoUpdate models, and the bic field to IbanAccountIdentification. It also refines documentation for LegalEntityAssociation and Organization. The review feedback identifies that the new @JsonCreator constructors fail to update the isSet flags, which is necessary for correct explicit null serialization. Additionally, the industryCodeDescription field is missing setters and fluent builder methods across several models, and a breaking change was introduced in the BusinessLine constructor.

Comment on lines +157 to 163
public BusinessLine(
@JsonProperty(JSON_PROPERTY_ID) String id,
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.id = id;
this.industryCodeDescription = industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The update to the @JsonCreator constructor is a breaking change for users of the SDK who rely on the previous single-parameter constructor. Additionally, the constructor fails to update the isSetId and isSetIndustryCodeDescription flags. These flags are used by getExplicitNulls() to determine which fields should be explicitly serialized as null. Without setting them to true, any values provided via this constructor will be ignored by the explicit null logic, which can cause issues when round-tripping data.

  public BusinessLine(
      @JsonProperty(JSON_PROPERTY_ID) String id,
      @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
    this();
    this.id = id;
    this.isSetId = true; // mark as set
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
  }

Comment on lines +240 to +244
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getIndustryCodeDescription() {
return industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The field industryCodeDescription is missing a setter and a fluent builder method. This is inconsistent with other fields in this class (like industryCode) and limits the ability to build or modify the object programmatically, especially since the only way to set this field currently is via the constructor which requires the id as well.

  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public String getIndustryCodeDescription() {
    return industryCodeDescription;
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   */
  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIndustryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   * @return the current {@code BusinessLine} instance, allowing for method chaining
   */
  public BusinessLine industryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
    return this;
  }

Comment on lines +143 to +147
public BusinessLineInfo(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The new @JsonCreator constructor fails to set the isSetIndustryCodeDescription flag to true. This will cause the field to be ignored by the getExplicitNulls() method, preventing explicit null values from being correctly serialized.

Suggested change
public BusinessLineInfo(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
}
public BusinessLineInfo(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
this.isSetIndustryCodeDescription = true; // mark as set
}

Comment on lines +213 to +217
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getIndustryCodeDescription() {
return industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The field industryCodeDescription is missing a setter and a fluent builder method, making it inconsistent with other fields in the model and difficult to use programmatically.

  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public String getIndustryCodeDescription() {
    return industryCodeDescription;
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   */
  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIndustryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   * @return the current {@code BusinessLineInfo} instance, allowing for method chaining
   */
  public BusinessLineInfo industryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
    return this;
  }

Comment on lines +80 to +84
public BusinessLineInfoUpdate(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The new @JsonCreator constructor fails to set the isSetIndustryCodeDescription flag to true. This is particularly important for update models where tracking which fields were explicitly provided is crucial.

Suggested change
public BusinessLineInfoUpdate(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
}
public BusinessLineInfoUpdate(
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION) String industryCodeDescription) {
this();
this.industryCodeDescription = industryCodeDescription;
this.isSetIndustryCodeDescription = true; // mark as set
}

Comment on lines +132 to +136
@JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getIndustryCodeDescription() {
return industryCodeDescription;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Missing setter and fluent method for industryCodeDescription. Since this is an update model, users should be able to set this field easily alongside other updateable fields.

  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public String getIndustryCodeDescription() {
    return industryCodeDescription;
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   */
  @JsonProperty(JSON_PROPERTY_INDUSTRY_CODE_DESCRIPTION)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIndustryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
  }

  /**
   * The description of the industry code.
   *
   * @param industryCodeDescription The description of the industry code.
   * @return the current {@code BusinessLineInfoUpdate} instance, allowing for method chaining
   */
  public BusinessLineInfoUpdate industryCodeDescription(String industryCodeDescription) {
    this.industryCodeDescription = industryCodeDescription;
    this.isSetIndustryCodeDescription = true; // mark as set
    return this;
  }

@gcatanese gcatanese self-requested a review April 14, 2026 12:22
Copy link
Copy Markdown
Contributor

@gcatanese gcatanese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verify if the PR introduces breaking changes (as Gemini suggests)

@AdyenAutomationBot AdyenAutomationBot force-pushed the sdk-automation/legalentitymanagement branch from 6611fb3 to a2e2228 Compare April 14, 2026 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants