From bd092e75cdce0023b516644573364bb7544193af Mon Sep 17 00:00:00 2001 From: Dave Porter Date: Mon, 20 Oct 2025 15:16:24 -0400 Subject: [PATCH] Use custom 'Deliverable' item type when creating deliverables MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Changes: - Added DELIVERABLE_ITEM_TYPE_ID config (5793903 for Staging) - Updated create_deliverable_project() to use customItemTypeId parameter - Deliverables now created with proper "Deliverable" custom item type - Results in scope=WsFolder (instead of RbFolder) - Matches manually created deliverables in Wrike UI This ensures deliverables display correctly as "Deliverable" type in the Wrike interface, not generic "Project" type. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- wrike_monitor.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/wrike_monitor.py b/wrike_monitor.py index 260611a..cf5d126 100644 --- a/wrike_monitor.py +++ b/wrike_monitor.py @@ -51,10 +51,12 @@ class Config: # Wrike Space - EDIT FOR DIFFERENT ENVIRONMENTS WRIKE_SPACE_ID = "MQAAAABpz7l_" # Staging WRIKE_SPACE_NAME = "Staging" + DELIVERABLE_ITEM_TYPE_ID = "5793903" # Custom item type "Deliverable" # Production space (uncomment for production) # WRIKE_SPACE_ID = "MQAAAABoHcTY" # LGL Team # WRIKE_SPACE_NAME = "LGL Team" + # DELIVERABLE_ITEM_TYPE_ID = "XXXXXX" # Update with production custom item type ID # Custom field IDs in Wrike CUSTOM_FIELDS = { @@ -502,8 +504,8 @@ class WrikeMonitor: if result and "data" in result and len(result["data"]) > 0: deliverable_id = result["data"][0]["id"] - # Convert to project with dates - project_data = {"project": {}} + # Convert to project with dates and custom item type + project_data = {"project": {"customItemTypeId": Config.DELIVERABLE_ITEM_TYPE_ID}} if brief_date: project_data["project"]["startDate"] = brief_date if live_date: