Skip to content

Add optional channel attribute to contact_list type#491

Merged
MaxAndDev merged 3 commits intomasterfrom
copilot/extend-contact-list-type
Jan 16, 2026
Merged

Add optional channel attribute to contact_list type#491
MaxAndDev merged 3 commits intomasterfrom
copilot/extend-contact-list-type

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Jan 16, 2026

Task: Extend the contact_list type with an optional channel attribute

Plan

  • Understand the existing contact-list type structure
  • Add channel to ContactListRawPayload interface
  • Add channel to ContactListPayload interface
  • Add channel property to ContactList class
  • Update deserialize method to handle the channel field
  • Update serialize method to include the channel field
  • Install dependencies
  • Build the project to validate TypeScript compilation
  • Run code review
  • Run security scanning
  • Revert package-lock.json format upgrade

Changes Made

  • Added optional channel?: string attribute to ContactListRawPayload interface (line 99)
  • Added optional channel?: ContactListRawPayload['channel'] to ContactListPayload interface (line 128)
  • Added channel property to ContactList class (line 175)
  • Updated deserialize method to assign this.channel = rawPayload.channel (line 218)
  • Updated serialize method to include channel: this.channel in returned object (line 262)
  • Reverted package-lock.json to original lockfileVersion 1 format

Validation

  • ✅ TypeScript compilation successful (no errors)
  • ✅ Code review passed (no issues found)
  • ✅ Security scan passed (0 vulnerabilities)
  • ✅ Type definitions correctly generated in dist/
  • ✅ Package-lock.json reverted to original format

The implementation follows existing patterns in the codebase for optional string attributes and maintains consistency with other fields like broker, proxy_reference_id, etc.

Original prompt

Extend the contact_list type with a optional channel attribute


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.


Summary by cubic

Added an optional channel attribute to the contact_list type to indicate the communication channel associated with a list. This is fully backward-compatible; existing lists work unchanged when channel is omitted.

Written for commit cd78309. Summary will update on new commits.

Co-authored-by: MaxAndDev <36757362+MaxAndDev@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@MaxAndDev MaxAndDev left a comment

Choose a reason for hiding this comment

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

@copilot why do we have such a big change in the package lock ?

Copilot AI changed the title [WIP] Extend contact_list type with optional channel attribute Add optional channel attribute to contact_list type Jan 16, 2026
Copilot AI requested a review from MaxAndDev January 16, 2026 16:06
Co-authored-by: MaxAndDev <36757362+MaxAndDev@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Jan 16, 2026

@copilot why do we have such a big change in the package lock ?

The package-lock.json was accidentally upgraded from lockfileVersion 1 to lockfileVersion 3 when I ran npm install to build the project. This is a format change that happens with newer npm versions but doesn't affect the actual dependencies. I've reverted it back to the original format in commit cd78309.

@MaxAndDev MaxAndDev marked this pull request as ready for review January 16, 2026 16:26
@MaxAndDev MaxAndDev merged commit c3ffe59 into master Jan 16, 2026
6 checks passed
@MaxAndDev MaxAndDev deleted the copilot/extend-contact-list-type branch January 16, 2026 16:27
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

@charles-platform
Copy link
Copy Markdown

🎉 This PR is included in version 4.256.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

4 participants