Skip to content

feat(contact-center): Add ability to Skip/Remove Campaigns#4808

Open
cmullenx wants to merge 1 commit intowebex:nextfrom
cmullenx:next
Open

feat(contact-center): Add ability to Skip/Remove Campaigns#4808
cmullenx wants to merge 1 commit intowebex:nextfrom
cmullenx:next

Conversation

@cmullenx
Copy link
Copy Markdown
Contributor

COMPLETES

https://jira-eng-sjc12.cisco.com/jira/browse/CAI-7658
https://jira-eng-sjc12.cisco.com/jira/browse/CAI-7659

This pull request addresses

The ability to skip and remove campaigns

by making the following changes

  • adds skip and remove APIs
  • adds appropriate events & metrics
  • adds unit tests

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Tooling change
  • Internal code refactor

The following scenarios were tested

  • Unit Tests
  • Manually tested ability to skip/remove campaigns

The GAI Coding Policy And Copyright Annotation Best Practices

  • GAI was not used (or, no additional notation is required)
  • Code was generated entirely by GAI
  • GAI was used to create a draft that was subsequently customized or modified
  • Coder created a draft manually that was non-substantively modified by GAI (e.g., refactoring was performed by GAI on manually written code)
  • Tool used for AI assistance (GitHub Copilot / Other - specify)
    • Github Copilot
    • Other - Windsurf
  • This PR is related to
    • Feature
    • Defect fix
    • Tech Debt
    • Automation

I certified that

  • I have read and followed contributing guidelines
  • I discussed changes with code owners prior to submitting this pull request
  • I have not skipped any automated checks
  • All existing and new tests passed
  • I have updated the documentation accordingly

Make sure to have followed the contributing guidelines before submitting.

@cmullenx cmullenx requested a review from a team as a code owner March 26, 2026 11:44
@cmullenx cmullenx added the validated If the pull request is validated for automation. label Mar 26, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2ed41591ff

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

notifFail: {
bind: {
type: TASK_MESSAGE_TYPE,
data: {type: CC_EVENTS.CAMPAIGN_PREVIEW_SKIP_FAILED, campaignId: p.data.campaignId},
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Correlate preview-failure binds with interactionId

The new skip/remove request matchers only key failure notifications on campaignId, so two pending preview operations in the same campaign can consume each other’s failure event and reject the wrong promise. aqm-reqs matches whichever bind fits, and this bind is currently not unique per operation. This becomes observable with parallel sessions/tabs or rapid retries on the same campaign; include interactionId in the failure bind to keep correlation deterministic.

Useful? React with 👍 / 👎.

break;
case CC_EVENTS.CAMPAIGN_PREVIEW_ACCEPT_FAILED:
if (task) {
task = this.updateTaskData(task, payload.data);
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Preserve task state when preview actions fail

These failure handlers call updateTaskData(task, payload.data), but task reconciliation deletes fields that are missing in the incoming payload. The new failure payloads in this change are sparse (type/ids/reason), so handling a preview failure can strip previously stored interaction details from task.data and mutate the task away from reservation state, which can break retry/UI flows that still need task.data.interaction.callProcessingDetails. Emit the failure event without destructive reconciliation (or merge only failure fields) to avoid data loss.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown

@brain-frog brain-frog left a comment

Choose a reason for hiding this comment

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

LGTM

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

Labels

validated If the pull request is validated for automation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants