define(["require","exports","../../Errors","../../Validation","./tools","./ArcGisApiVersion"],function(e,t,a,o,c,s){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=(n.prototype.execute=function(e,t){var i=o.validation.urlOrLayer(e,s.isArcGisApiVersion3x).trim(),n=o.validation.number("objectId",e.objectId,o.validation.never),r=o.validation.array("attachmentIds",e.attachmentIds,o.validation.never).join(","),e=o.validation.number("timeout",e.timeout,void 0),n=c.addToPath(i,n+"/deleteAttachments"),e=c.post(n,{attachmentIds:r},e,t.cancellationToken.signal);return c.schedulePromiseCancellation(t,e),c.inline(e,function(e){e=e.deleteAttachmentResults;if(!e)throw new a.GenericActivityError('Error running the "Delete Attachments" activity. The response did not include the required "deleteAttachmentResults" property.');return{results:e}})},n.action="gcx:wf:arcgis::DeleteAttachments",n.suite="gcx:wf:builtin",n);function n(){}t.DeleteAttachments=i});