Skip to content

[DAS 336] - Update ACC Admin models to ensure uniformity across models #119

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

Open
wants to merge 4 commits into
base: development
Choose a base branch
from

Conversation

Arrotech
Copy link
Contributor

What does this PR do?

Update ACC Admin models to ensure uniformity across models

Branch Name?

DAS-336-update-acc-admin-models

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR standardizes and updates several ACC Admin models to improve consistency across the codebase. Key changes include renaming and updating types (e.g. changing “CompanyImportResponse” to “CompanyImport”), adjusting API endpoint return types to their new uniform naming, and replacing legacy payload interfaces with their updated counterparts.

Reviewed Changes

Copilot reviewed 33 out of 33 changed files in this pull request and generated no comments.

File Description
construction/accountadmin/source/model/*.ts Added new constant enums and updated type aliases to improve model uniformity
construction/accountadmin/source/api/*.ts and custom-code/adminClient.ts Updated API endpoint return types and request payload types to reflect new naming
construction/accountadmin/source/api/businessUnitsApi.ts Replaced “BusinessUnitsRequestPyload” with “BusinessUnitsPayload” for clarity
Comments suppressed due to low confidence (2)

construction/accountadmin/source/api/businessUnitsApi.ts:27

  • Renaming the payload parameter from BusinessUnitsRequestPyload to BusinessUnitsPayload improves clarity. Verify that all references to this parameter are updated consistently throughout the code.
createBusinessUnits: async (accessToken: string, accountId: string, region?: Region, businessUnitsPayload?: BusinessUnitsPayload,  options: ApsServiceRequestConfig = {}): Promise<RequestArgs> => {

construction/accountadmin/source/custom-code/adminClient.ts:221

  • Changing the return type from CompanyImportResponse to CompanyImport represents a breaking change that consumers must be aware of. Please ensure that this change is clearly documented in the release notes and communicated to API users.
public async importCompanies(accountId: string, companyPayload: Array<CompanyPayload>, optionalArgs?: { region?: Region, accessToken?: string, options?: ApsServiceRequestConfig }): Promise<CompanyImport> {




localVarHeaderParameter['User-Agent'] = 'APS SDK/CONSTRUCTIONACCOUNTADMIN/TypeScript/1.0.0';
Copy link
Contributor

Choose a reason for hiding this comment

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

user-agent should be 'APS SDK/CONSTRUCTION-ACCOUNT-ADMIN/TypeScript/1.0.0'

@Arrotech Arrotech requested a review from nishchhaldagar June 3, 2025 09:18
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