@@ -39,6 +39,24 @@ export const createLinkTool: ToolConfig<DubCreateLinkParams, DubCreateLinkRespon
3939 visibility : 'user-or-llm' ,
4040 description : 'External ID for the link in your database' ,
4141 } ,
42+ tenantId : {
43+ type : 'string' ,
44+ required : false ,
45+ visibility : 'user-or-llm' ,
46+ description : 'Tenant ID for grouping links created on behalf of a customer/tenant' ,
47+ } ,
48+ folderId : {
49+ type : 'string' ,
50+ required : false ,
51+ visibility : 'user-or-llm' ,
52+ description : 'Folder ID to organize the link into' ,
53+ } ,
54+ trackConversion : {
55+ type : 'boolean' ,
56+ required : false ,
57+ visibility : 'user-or-llm' ,
58+ description : 'Whether to track conversions (leads/sales) for the short link' ,
59+ } ,
4260 tagIds : {
4361 type : 'string' ,
4462 required : false ,
@@ -131,6 +149,9 @@ export const createLinkTool: ToolConfig<DubCreateLinkParams, DubCreateLinkRespon
131149 if ( params . domain ) body . domain = params . domain
132150 if ( params . key ) body . key = params . key
133151 if ( params . externalId ) body . externalId = params . externalId
152+ if ( params . tenantId ) body . tenantId = params . tenantId
153+ if ( params . folderId ) body . folderId = params . folderId
154+ if ( params . trackConversion !== undefined ) body . trackConversion = params . trackConversion
134155 if ( params . tagIds ) body . tagIds = params . tagIds . split ( ',' ) . map ( ( id ) => id . trim ( ) )
135156 if ( params . comments ) body . comments = params . comments
136157 if ( params . expiresAt ) body . expiresAt = params . expiresAt
@@ -169,8 +190,12 @@ export const createLinkTool: ToolConfig<DubCreateLinkParams, DubCreateLinkRespon
169190 title : data . title ?? null ,
170191 description : data . description ?? null ,
171192 tags : data . tags ?? [ ] ,
193+ folderId : data . folderId ?? null ,
194+ tenantId : data . tenantId ?? null ,
195+ trackConversion : data . trackConversion ?? false ,
172196 clicks : data . clicks ?? 0 ,
173197 leads : data . leads ?? 0 ,
198+ conversions : data . conversions ?? 0 ,
174199 sales : data . sales ?? 0 ,
175200 saleAmount : data . saleAmount ?? 0 ,
176201 lastClicked : data . lastClicked ?? null ,
@@ -197,8 +222,12 @@ export const createLinkTool: ToolConfig<DubCreateLinkParams, DubCreateLinkRespon
197222 title : { type : 'string' , description : 'OG title' , optional : true } ,
198223 description : { type : 'string' , description : 'OG description' , optional : true } ,
199224 tags : { type : 'json' , description : 'Tags assigned to the link (id, name, color)' } ,
225+ folderId : { type : 'string' , description : 'Folder the link is organized into' , optional : true } ,
226+ tenantId : { type : 'string' , description : 'Tenant ID associated with the link' , optional : true } ,
227+ trackConversion : { type : 'boolean' , description : 'Whether conversion tracking is enabled' } ,
200228 clicks : { type : 'number' , description : 'Number of clicks' } ,
201229 leads : { type : 'number' , description : 'Number of leads' } ,
230+ conversions : { type : 'number' , description : 'Number of conversions' } ,
202231 sales : { type : 'number' , description : 'Number of sales' } ,
203232 saleAmount : { type : 'number' , description : 'Total sale amount in cents' } ,
204233 lastClicked : { type : 'string' , description : 'Last clicked timestamp' , optional : true } ,
0 commit comments