Skip to main content

Duplicate Table

Duplicate a Table. Duplicated Tables are added to the source Table's Solution. Note that the name of the duplicated Table must be unique in the Solution.

duplicate_table( tableId: ID, duplicateApplicationRequest: ApplicationDuplicateRequest): Promise<ApplicationDuplicateResponse>;
Parameter NameTypeDescription
ApplicationDuplicateRequestApplicationDuplicateRequest objectParameters for Table duplication. Duplicate Table name must be unique.

SolutionDuplicateRequest Interface

<!--export interface ApplicationDuplicateRequest {
duplicate_records: boolean;
name: string;
}-->
Parameter NameTypeDescription
duplicate_recordsbooleanTrue to copy records.
namestringName of new (duplicated) Table. Must be unique in the Solution.
Example Script - Duplicate Table

<!--duplicate_table( appId: ID, duplicateApplicationRequest: ApplicationDuplicateRequest): Promise<ApplicationDuplicateResponse>;-->

<!--export interface ApplicationDuplicateRequest {
duplicate_records: boolean;
name: string;
}-->

<script>
window.SmartSuite.duplicate_table('673635639c6c4519fd0d7be6', {
duplicate_records: true,
name: 'new name 2',
}).then((res) => {
console.log('result =>>>', res);
});
</script>

Response

200 response
{
"application": {
"id": "6765f05267d08e6360c7cdda",
"name": "new name 2",
"icon": "no-icon",
"solution": "67647d9b7a03fad7da12d9f0",
"slug": "srhjb9lq",
"status": "in_process_of_duplication",
"structure": [
{
"slug": "title",
"label": "Title",
"field_type": "recordtitlefield",
"params": {
"is_auto_generated": false,
"template": "",
"primary": true,
"max_length": null,
"required": true,
"unique": true,
"placeholder": "Enter record title",
"width": 1,
"is_migrating": false,
"valid": true,
"indexed": false,
"help_doc": null,
"help_text_display_format": "tooltip"
}
},
{
"slug": "description",
"label": "Description",
"field_type": "richtextareafield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": {
"data": {},
"html": "",
"preview": ""
},
"width": 2,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "assigned_to",
"label": "Assigned To",
"field_type": "userfield",
"params": {
"include_filter": false,
"field_filter": {},
"display_format": "image_only",
"notifications_enabled": true,
"linked_application": "members",
"entries_allowed": "single",
"linked_field_slug": "status",
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Enter assign to",
"default_value": [],
"width": 1,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "status",
"label": "Status",
"field_type": "statusfield",
"params": {
"choices": [
{
"label": "Backlog",
"value": "backlog",
"value_order": 1,
"value_color": "#6A849B",
"is_complete": false
},
{
"label": "In Process",
"value": "in_progress",
"value_order": 2,
"value_color": "#FFB938"
},
{
"label": "Ready for Review",
"value": "ready_for_review",
"value_order": 3,
"value_color": "#FF9210",
"is_complete": false
},
{
"label": "Complete",
"value": "complete",
"value_order": 4,
"value_color": "#3EAC40",
"is_complete": true
}
],
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": {
"value": "backlog",
"updated_on": null
},
"width": 1,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "due_date",
"label": "Due Date",
"field_type": "duedatefield",
"params": {
"display_format": "standard",
"linked_field": "status",
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false,
"nested": [
{
"slug": "from_date",
"label": "Start Date",
"field_type": "datefield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Select Date Range",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false,
"display_format": "standard"
}
},
{
"slug": "to_date",
"label": "End Date",
"field_type": "datefield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Select Date Range",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false,
"display_format": "standard"
}
}
]
},
"nested": [
{
"slug": "from_date",
"label": "Start Date",
"field_type": "datefield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Select Date Range",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false,
"display_format": "standard"
}
},
{
"slug": "to_date",
"label": "End Date",
"field_type": "datefield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Select Date Range",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false,
"display_format": "standard"
}
}
]
},
{
"slug": "priority",
"label": "Priority",
"field_type": "singleselectfield",
"params": {
"display_format": "importance",
"control_type": "dropdown",
"edit_values": false,
"edit_help_texts": false,
"new_choices_allowed": true,
"choices": [
{
"label": "Urgent",
"value": "urgent",
"value_color": "#FF5757",
"value_order": 0,
"icon_type": "icon",
"weight": 1
},
{
"label": "High",
"value": "high",
"value_color": "#FFB938",
"value_order": 1,
"icon_type": "icon",
"weight": 1
},
{
"label": "Normal",
"value": "normal",
"value_color": "#3EAC40",
"value_order": 2,
"icon_type": "icon",
"weight": 1
},
{
"label": "Low",
"value": "low",
"value_color": "#6A849B",
"value_order": 3,
"icon_type": "icon",
"weight": 1
}
],
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Select Value",
"default_value": "",
"width": 1,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "first_created",
"label": "First Created",
"field_type": "firstcreatedfield",
"params": {
"display_format": "avatar_date",
"date_format": "standard",
"include_time": false,
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": null,
"width": null,
"system": true,
"valid": true,
"is_migrating": false
}
},
{
"slug": "last_updated",
"label": "Last Updated",
"field_type": "lastupdatedfield",
"params": {
"display_format": "avatar_date",
"date_format": "standard",
"include_time": false,
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": null,
"width": null,
"system": true,
"valid": true,
"is_migrating": false
}
},
{
"slug": "followed_by",
"label": "Followed by",
"field_type": "userfield",
"params": {
"include_filter": false,
"field_filter": {},
"display_format": "image_name",
"notifications_enabled": true,
"linked_application": "members",
"entries_allowed": "single",
"linked_field_slug": null,
"required": false,
"unique": false,
"hidden": true,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Enter assign to",
"default_value": [],
"width": 1,
"system": true,
"valid": true,
"is_migrating": false
}
},
{
"slug": "comments_count",
"label": "Open Comments",
"field_type": "commentscountfield",
"params": {
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Enter number",
"default_value": null,
"width": null,
"system": true,
"valid": true,
"is_migrating": false
}
},
{
"slug": "autonumber",
"label": "Auto Number",
"field_type": "autonumberfield",
"params": {
"include_labels": true,
"suffix": "",
"prefix": "#",
"starting_number": 1,
"leading_zeros": 2,
"primary": false,
"required": false,
"unique": true,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": null,
"width": 0,
"system": true,
"valid": true,
"is_migrating": false
}
},
{
"slug": "sab60f5c5b",
"label": "Text",
"field_type": "textfield",
"params": {
"primary": false,
"restore_application_id": null,
"max_length": null,
"composite": null,
"delimiter": ", ",
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Write here",
"default_value": null,
"width": 1,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "s048e67ec8",
"label": "Text Area",
"field_type": "textareafield",
"params": {
"restore_application_id": null,
"max_length": null,
"composite": null,
"delimiter": ", ",
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Write here",
"default_value": null,
"width": 2,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "s8f119717f",
"label": "Files and Images",
"field_type": "filefield",
"params": {
"view_mode": "list",
"items_in_row": 3,
"required": false,
"unique": false,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "Add Attachment",
"default_value": null,
"width": 2,
"system": false,
"valid": true,
"is_migrating": false
}
},
{
"slug": "se0df7d290",
"label": "Record ID",
"field_type": "recordidfield",
"params": {
"required": false,
"unique": true,
"hidden": false,
"help_text_display_format": "tooltip",
"help_doc": null,
"placeholder": "",
"default_value": null,
"width": 1,
"system": true,
"valid": true,
"is_migrating": false,
"primary": false,
"include_labels": false,
"prefix": "",
"suffix": ""
}
}
],
"primary_field": "title",
"order": 219025,
"structure_layout": {
"mode": "fifty_fifty",
"fifty_fifty": {
"rows": [
[
"title",
""
],
[
"description",
""
],
[
"assigned_to",
"status"
],
[
"due_date",
"priority"
],
[
"sab60f5c5b",
""
],
[
"s048e67ec8",
""
],
[
"s8f119717f",
""
],
[
"se0df7d290",
""
]
],
"sections": []
},
"seventy_thirty": {
"seventy": [
"description",
"s048e67ec8",
"s8f119717f"
],
"thirty": [
"title",
"assigned_to",
"status",
"due_date",
"priority",
"sab60f5c5b",
"se0df7d290"
],
"seventy_sections": [],
"thirty_sections": []
},
"hidden_fields": null,
"single_column": {
"rows": [
"title",
"description",
"assigned_to",
"status",
"due_date",
"priority",
"sab60f5c5b",
"s048e67ec8",
"s8f119717f",
"se0df7d290"
],
"sections": []
}
},
"show_all_reports_members": [],
"fields_metadata": {},
"permissions": {
"level": "all_members",
"members": [],
"teams": [],
"permissions_metadata": {}
},
"field_permissions": [],
"first_created": {
"by": "63a1f65723aaf6bcb564b1f1",
"on": "2024-12-20T22:31:46.469000Z"
},
"settings": {
"emails": false,
"meeting_notes": false,
"call_log": false
},
"record_term": "record",
"fields_count": {
"total": 14
},
"record_avatar_field_slug": null,
"hidden": false
},
"reports": []
}