Duplicate Segment
duplicate_segmentCreate a duplicate of an existing segment. Preserves the source subtype and all subtype-specific data: filter criteria for filter segments; match results, column mappings, and match counts for matched segments; seed and generated-score references for similarity/propensity segments (underlying computed data is referenced, never recomputed). Lineage is recorded (parent_segment_id, derived_from root ancestor, parent_segment_version pin). Filter duplicates start with record_count null — trigger a recount with count_segment for a fresh count; matched/similarity/propensity duplicates carry the source's counts. Returns 409 SOURCE_MATCH_UNAVAILABLE when a matched source's match data is unavailable (expired/failed/incomplete match), or 409 SOURCE_NOT_READY when a non-matched source is pending or failed. Requires 'creator' scope.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Name for the duplicate. Defaults to "<source name> (copy)" | |
| segment_id | Yes | ID of the segment to duplicate |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| status | Yes | ||
| subtype | Yes | ||
| guidance | No | Interpretation or recovery guidance for this result | |
| count_unit | No | ||
| page_count | No | Number of objects on this page, not the organization total | |
| segment_id | Yes | ||
| upload_url | No | ||
| audience_id | No | ||
| count_state | No | Unknown means no count; available does not guarantee freshness. Recount for a current value. | |
| upload_urls | No | ||
| next_actions | No | Suggested next calls using returned IDs and available scopes. Not executed and not user consent. | |
| record_count | No | Stored count; null means unknown. Call count_segment for a current count. | |
| record_limit | No | Maximum members; null means no explicit cap | |
| filter_groups | No | Complete saved filter definition; one AND group also represents a simple flat filter list | |
| money_display | No | Currency amounts formatted once from source paths ending in _cents. Use verbatim; do not divide again. Null/missing source amounts are omitted, not zero. | |
| current_version | No | ||
| workflow_run_id | No | ||
| population_input | No | Population input used for the preview; IDs refer to their current saved definitions | |
| upload_expires_at | No |