apply_feedback_changes
Changes data
Correct a product's feedback: the only way to change an insight's type, sentiment or place and to rename or merge topics. Send an ordered list of steps, each an object with op and that kind's fields; a single correction is a list of one step:
update_insight:insightIdand atype, asentiment, or both; any insight of the product, linked or not.move_insight:insightIdand exactly one offeatureId(a live feature: the insight leaves its topic and the AI groups it into a topic there after the save),newOpportunity: true(likewise, for feedback matching no feature) ortopicId(a topic not merged away: the insight joins it and so its feature). Only insights of processed records linked to a feature or New opportunity can move.rename_topic:topicIdandname, 1 to 50 characters on one line, trimmed.merge_topic:topicIdintointoId, a topic under the same feature (or both under New opportunity), not the topic itself: its insights move intointoId, and reading the merged topic answersintoId. To bring feedback from another feature, move its insights. Each step runs on the feedback as the earlier steps left it. A step that would change nothing is skipped, not refused: the type, sentiment or name it already has, or a move to where the insight already reads. A topic can't move as a whole: move its insights, one step each (more than 50 take several changes). Work in two calls. Find the ids withsearch,list_topics,list_topic_insightsorlist_source_records, then send the steps withdryRun: trueand the read'smeta.feedbackVersionasexpectedVersion: nothing is saved, and the answer lists each step'schanges(edited fields with their valuebefore),skippedsteps,problems(each step that would be refused, with the reason and rule) and each named topic as it would be after them (topics). Show the person the outcome. Then send the same steps withoutdryRun: all are saved or none. The first refused step stops the call and saves nothing: its refusal is the answer, the message starting "Step <n>: " anddetails.stepnaming it. A save answers the feedback change it stored and the newversion; when every step was skipped nothing is stored andchangeis null. Background work (grouping, linking, new feedback) leaves the version as it is, so topic counts may differ from the preview. Oneundo_changewith areafeedbackreverses it all; it can't be redone. At most 50 steps per call.expectedVersionrefuses the call (conflict) when anyone stored a feedback change since your read: read again, check the plan, send the new version. A retry is safe: the same save again answers the first result while it is the product's newest feedback change, yours and not undone. Product Owners and Admins only; Viewers are refused, also for a preview.
Inputs
- Who can use it
- Admins and the product's Owners
- Hints
- Changes dataCan remove dataSafe to repeat
- Runs
apply_feedback_changes- Inputs
productIdstring, requiredFrom
read_productwith actionlistorget_me.bodyobject, requiredAn ordered list of feedback changes, previewed with
dryRunor saved as one change.stepsarray of objects, requiredThe changes to make, in order, 1 to 50. Each is one object:
opnames the kind of change and the other fields are its inputs, its insight or topic id included.One of:op:update_insightinsightIdstring, requiredThe insight to change.
typestringWhat kind of feedback it is: feature_request, bug, praise, complaint or question.
Allowed values:feature_request,bug,praise,complaint,questionsentimentstringHow the customer feels: positive, neutral or negative.
Allowed values:positive,neutral,negative
op:move_insightinsightIdstring, requiredThe insight to change.
featureIdstringMove it to this feature; the AI then groups it into a topic there.
newOpportunitybooleantrue: move it to New opportunity, for feedback that matches no feature.
Allowed values:truetopicIdstringMove it into this topic, and so to the topic's feature.
op:rename_topictopicIdstring, requiredThe topic to change.
namestring, requiredThe topic's new name, 1 to 50 characters on one line.
op:merge_topictopicIdstring, requiredThe topic to merge away.
intoIdstring, requiredThe topic to merge into.
dryRunbooleantrue: save nothing and answer the outcome (changes, skipped and refused steps, the topics touched).
expectedVersionstringThe
meta.feedbackVersionfrom the read you planned from (or a dry run'sversion); refused when the feedback changed since.