@mondaydotcomorg/api
Advanced tools
Comparing version 3.0.1 to 3.0.2
@@ -1,2 +0,2 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("graphql-tag"),t=require("graphql-request");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var r,o,i,a,s,u,d,l,p,c,m,_,b,v,h,g,x,I,f,y,O,D,C,S,$,A,T=n(e),B=function(){return B=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},B.apply(this,arguments)};function N(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))}function E(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(s){return function(u){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,s[0]&&(a=0)),a;)try{if(n=1,r&&(o=2&s[0]?r.return:s[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,s[1])).done)return o;switch(r=0,o&&(s=[2&s[0],o.value]),s[0]){case 0:case 1:o=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,r=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==s[0]&&2!==s[0])){a=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]<o[3])){a.label=s[1];break}if(6===s[0]&&a.label<o[1]){a.label=o[1],o=s;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(s);break}o[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(e){s=[6,e],r=0}finally{n=o=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function V(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}"function"==typeof SuppressedError&&SuppressedError,exports.AssetsSource=void 0,(r=exports.AssetsSource||(exports.AssetsSource={})).All="all",r.Columns="columns",r.Gallery="gallery",exports.BoardAttributes=void 0,(o=exports.BoardAttributes||(exports.BoardAttributes={})).Communication="communication",o.Description="description",o.Name="name",exports.BoardKind=void 0,(i=exports.BoardKind||(exports.BoardKind={})).Private="private",i.Public="public",i.Share="share",exports.BoardObjectType=void 0,(a=exports.BoardObjectType||(exports.BoardObjectType={})).Board="board",a.CustomObject="custom_object",a.Document="document",a.SubItemsBoard="sub_items_board",exports.BoardSubscriberKind=void 0,(s=exports.BoardSubscriberKind||(exports.BoardSubscriberKind={})).Owner="owner",s.Subscriber="subscriber",exports.BoardsOrderBy=void 0,(u=exports.BoardsOrderBy||(exports.BoardsOrderBy={})).CreatedAt="created_at",u.UsedAt="used_at",exports.ColumnProperty=void 0,(d=exports.ColumnProperty||(exports.ColumnProperty={})).Description="description",d.Title="title",exports.ColumnType=void 0,(l=exports.ColumnType||(exports.ColumnType={})).AutoNumber="auto_number",l.BoardRelation="board_relation",l.Button="button",l.Checkbox="checkbox",l.ColorPicker="color_picker",l.Country="country",l.CreationLog="creation_log",l.Date="date",l.Dependency="dependency",l.Doc="doc",l.Dropdown="dropdown",l.Email="email",l.File="file",l.Formula="formula",l.Group="group",l.Hour="hour",l.Integration="integration",l.ItemAssignees="item_assignees",l.ItemId="item_id",l.LastUpdated="last_updated",l.Link="link",l.Location="location",l.LongText="long_text",l.Mirror="mirror",l.Name="name",l.Numbers="numbers",l.People="people",l.Person="person",l.Phone="phone",l.Progress="progress",l.Rating="rating",l.Status="status",l.Subtasks="subtasks",l.Tags="tags",l.Team="team",l.Text="text",l.TimeTracking="time_tracking",l.Timeline="timeline",l.Unsupported="unsupported",l.Vote="vote",l.Week="week",l.WorldClock="world_clock",exports.DuplicateBoardType=void 0,(p=exports.DuplicateBoardType||(exports.DuplicateBoardType={})).DuplicateBoardWithPulses="duplicate_board_with_pulses",p.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",p.DuplicateBoardWithStructure="duplicate_board_with_structure",exports.FileLinkValueKind=void 0,(c=exports.FileLinkValueKind||(exports.FileLinkValueKind={})).Box="box",c.Dropbox="dropbox",c.GoogleDrive="google_drive",c.Link="link",c.Onedrive="onedrive",exports.FirstDayOfTheWeek=void 0,(m=exports.FirstDayOfTheWeek||(exports.FirstDayOfTheWeek={})).Monday="monday",m.Sunday="sunday",exports.FolderColor=void 0,(_=exports.FolderColor||(exports.FolderColor={})).Aquamarine="AQUAMARINE",_.BrightBlue="BRIGHT_BLUE",_.BrightGreen="BRIGHT_GREEN",_.ChiliBlue="CHILI_BLUE",_.DarkOrange="DARK_ORANGE",_.DarkPurple="DARK_PURPLE",_.DarkRed="DARK_RED",_.DoneGreen="DONE_GREEN",_.Indigo="INDIGO",_.Lipstick="LIPSTICK",_.Null="NULL",_.Purple="PURPLE",_.SofiaPink="SOFIA_PINK",_.StuckRed="STUCK_RED",_.Sunset="SUNSET",_.WorkingOrange="WORKING_ORANGE",exports.GroupAttributes=void 0,(b=exports.GroupAttributes||(exports.GroupAttributes={})).Color="color",b.Position="position",b.RelativePositionAfter="relative_position_after",b.RelativePositionBefore="relative_position_before",b.Title="title",exports.ItemsOrderByDirection=void 0,(v=exports.ItemsOrderByDirection||(exports.ItemsOrderByDirection={})).Asc="asc",v.Desc="desc",exports.ItemsQueryOperator=void 0,(h=exports.ItemsQueryOperator||(exports.ItemsQueryOperator={})).And="and",h.Or="or",exports.ItemsQueryRuleOperator=void 0,(g=exports.ItemsQueryRuleOperator||(exports.ItemsQueryRuleOperator={})).AnyOf="any_of",g.Between="between",g.ContainsTerms="contains_terms",g.ContainsText="contains_text",g.EndsWith="ends_with",g.GreaterThan="greater_than",g.GreaterThanOrEquals="greater_than_or_equals",g.IsEmpty="is_empty",g.IsNotEmpty="is_not_empty",g.LowerThan="lower_than",g.LowerThanOrEqual="lower_than_or_equal",g.NotAnyOf="not_any_of",g.NotContainsText="not_contains_text",g.StartsWith="starts_with",g.WithinTheLast="within_the_last",g.WithinTheNext="within_the_next",exports.Kind=void 0,(x=exports.Kind||(exports.Kind={})).Person="person",x.Team="team",exports.NotificationTargetType=void 0,(I=exports.NotificationTargetType||(exports.NotificationTargetType={})).Post="Post",I.Project="Project",exports.NumberValueUnitDirection=void 0,(f=exports.NumberValueUnitDirection||(exports.NumberValueUnitDirection={})).Left="left",f.Right="right",exports.PositionRelative=void 0,(y=exports.PositionRelative||(exports.PositionRelative={})).AfterAt="after_at",y.BeforeAt="before_at",exports.State=void 0,(O=exports.State||(exports.State={})).Active="active",O.All="all",O.Archived="archived",O.Deleted="deleted",exports.UserKind=void 0,(D=exports.UserKind||(exports.UserKind={})).All="all",D.Guests="guests",D.NonGuests="non_guests",D.NonPending="non_pending",exports.VersionKind=void 0,(C=exports.VersionKind||(exports.VersionKind={})).Current="current",C.Deprecated="deprecated",C.Dev="dev",C.Maintenance="maintenance",C.PreviousMaintenance="previous_maintenance",C.ReleaseCandidate="release_candidate",exports.WebhookEventType=void 0,(S=exports.WebhookEventType||(exports.WebhookEventType={})).ChangeColumnValue="change_column_value",S.ChangeName="change_name",S.ChangeSpecificColumnValue="change_specific_column_value",S.ChangeStatusColumnValue="change_status_column_value",S.ChangeSubitemColumnValue="change_subitem_column_value",S.ChangeSubitemName="change_subitem_name",S.CreateColumn="create_column",S.CreateItem="create_item",S.CreateSubitem="create_subitem",S.CreateSubitemUpdate="create_subitem_update",S.CreateUpdate="create_update",S.DeleteUpdate="delete_update",S.EditUpdate="edit_update",S.ItemArchived="item_archived",S.ItemDeleted="item_deleted",S.ItemMovedToAnyGroup="item_moved_to_any_group",S.ItemMovedToSpecificGroup="item_moved_to_specific_group",S.ItemRestored="item_restored",S.MoveSubitem="move_subitem",S.SubitemArchived="subitem_archived",S.SubitemDeleted="subitem_deleted",exports.WorkspaceKind=void 0,($=exports.WorkspaceKind||(exports.WorkspaceKind={})).Closed="closed",$.Open="open",exports.WorkspaceSubscriberKind=void 0,(A=exports.WorkspaceSubscriberKind||(exports.WorkspaceSubscriberKind={})).Owner="owner",A.Subscriber="subscriber",exports.WorkspacesOrderBy=void 0,(exports.WorkspacesOrderBy||(exports.WorkspacesOrderBy={})).CreatedAt="created_at";var k,P,R,w,q,U,G,K,L,M=T.default(k||(k=V(["\n fragment UserFields on User {\n id\n name\n email\n }\n"],["\n fragment UserFields on User {\n id\n name\n email\n }\n"]))),W=T.default(P||(P=V(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),M),F=T.default(R||(R=V(["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),j=T.default(w||(w=V(["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),Q=T.default(q||(q=V(["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"],["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"]))),H=T.default(U||(U=V(["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"],["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"]))),J=T.default(G||(G=V(["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"],["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"]))),z=T.default(K||(K=V(["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"],["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"]))),Y=function(e,t,n,r){return e()};function X(e,t){return void 0===t&&(t=Y),{getMeOp:function(n,r){return t((function(t){return e.request(W,n,B(B({},r),t))}),"getMeOp","query",n)},changeSimpleColumnValueOp:function(n,r){return t((function(t){return e.request(F,n,B(B({},r),t))}),"changeSimpleColumnValueOp","mutation",n)},changeColumnValueOp:function(n,r){return t((function(t){return e.request(j,n,B(B({},r),t))}),"changeColumnValueOp","mutation",n)},createItemOp:function(n,r){return t((function(t){return e.request(Q,n,B(B({},r),t))}),"createItemOp","mutation",n)},changeMultipleColumnValuesOp:function(n,r){return t((function(t){return e.request(H,n,B(B({},r),t))}),"changeMultipleColumnValuesOp","mutation",n)},getBoardItemsOp:function(n,r){return t((function(t){return e.request(J,n,B(B({},r),t))}),"getBoardItemsOp","query",n)},getBoardGroupsOp:function(n,r){return t((function(t){return e.request(z,n,B(B({},r),t))}),"getBoardGroupsOp","query",n)}}}exports.AvailableVersions=void 0,(L=exports.AvailableVersions||(exports.AvailableVersions={})).DEPRECATED="deprecated",L.MAINTENANCE="maintenance",L.CURRENT="current",L.RELEASE_CANDIDATE="release_candidate",L.DEV="dev",L.CURRENT_VERSION="2024-04";var Z="https://api.monday.com/v2",ee=exports.AvailableVersions.CURRENT_VERSION,te="3.0.0",ne=function(e,n){void 0===n&&(n=ee);var r=this;this.query=function(e,t){return N(r,void 0,void 0,(function(){return E(this,(function(n){switch(n.label){case 0:return[4,this.client.request(e,t)];case 1:return[2,n.sent()]}}))}))},this.apiVersion=n;var o=process.env.MONDAY_API_ENDPOINT||Z;this.client=new t.GraphQLClient(o,{headers:{"Content-Type":"application/json",Authorization:e,"API-Version":this.apiVersion,"Api-Sdk-Version":te}}),this.operations=X(this.client)},re=function(){function e(e){void 0===e&&(e=ee),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e}return e.prototype.query=function(e,t,n,r){var o=this;return void 0===r&&(r=6e4),new Promise((function(i,a){var s=o.generateRequestId(),u={query:e,variables:t},d=n||o.apiVersion;window.parent.postMessage({method:"api",args:{params:u,apiVersion:d},requestId:s},"*");var l=setTimeout((function(){a(new Error("Request timed out"))}),r),p=o.addListener(s,(function(e){clearTimeout(l),p(),e.errorMessage?a(new Error("".concat(e.errorMessage," - ").concat(e.data))):i(e)}))}))},e.prototype.addListener=function(e,t){var n=this,r=this.listeners[e]||new Set;return r.add(t),this.listeners[e]=r,function(){r.delete(t),0===r.size&&delete n.listeners[e]}},e}();exports.ApiClient=ne,exports.ChangeColumnValueOpDocument=j,exports.ChangeMultipleColumnValuesOpDocument=H,exports.ChangeSimpleColumnValueOpDocument=F,exports.CreateItemOpDocument=Q,exports.DEFAULT_VERSION=ee,exports.GetBoardGroupsOpDocument=z,exports.GetBoardItemsOpDocument=J,exports.GetMeOpDocument=W,exports.MONDAY_API_ENDPOINT=Z,exports.SeamlessApiClient=re,exports.UserFieldsFragmentDoc=M,exports.getSdk=X; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("graphql-tag"),t=require("graphql-request");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var r,o,i,a,s,u,d,l,p,c,m,_,b,v,h,g,x,I,f,y,O,D,C,S,$,A,T=n(e),B=function(){return B=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},B.apply(this,arguments)};function N(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))}function E(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(s){return function(u){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,s[0]&&(a=0)),a;)try{if(n=1,r&&(o=2&s[0]?r.return:s[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,s[1])).done)return o;switch(r=0,o&&(s=[2&s[0],o.value]),s[0]){case 0:case 1:o=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,r=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==s[0]&&2!==s[0])){a=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]<o[3])){a.label=s[1];break}if(6===s[0]&&a.label<o[1]){a.label=o[1],o=s;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(s);break}o[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(e){s=[6,e],r=0}finally{n=o=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function V(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}"function"==typeof SuppressedError&&SuppressedError,exports.AssetsSource=void 0,(r=exports.AssetsSource||(exports.AssetsSource={})).All="all",r.Columns="columns",r.Gallery="gallery",exports.BoardAttributes=void 0,(o=exports.BoardAttributes||(exports.BoardAttributes={})).Communication="communication",o.Description="description",o.Name="name",exports.BoardKind=void 0,(i=exports.BoardKind||(exports.BoardKind={})).Private="private",i.Public="public",i.Share="share",exports.BoardObjectType=void 0,(a=exports.BoardObjectType||(exports.BoardObjectType={})).Board="board",a.CustomObject="custom_object",a.Document="document",a.SubItemsBoard="sub_items_board",exports.BoardSubscriberKind=void 0,(s=exports.BoardSubscriberKind||(exports.BoardSubscriberKind={})).Owner="owner",s.Subscriber="subscriber",exports.BoardsOrderBy=void 0,(u=exports.BoardsOrderBy||(exports.BoardsOrderBy={})).CreatedAt="created_at",u.UsedAt="used_at",exports.ColumnProperty=void 0,(d=exports.ColumnProperty||(exports.ColumnProperty={})).Description="description",d.Title="title",exports.ColumnType=void 0,(l=exports.ColumnType||(exports.ColumnType={})).AutoNumber="auto_number",l.BoardRelation="board_relation",l.Button="button",l.Checkbox="checkbox",l.ColorPicker="color_picker",l.Country="country",l.CreationLog="creation_log",l.Date="date",l.Dependency="dependency",l.Doc="doc",l.Dropdown="dropdown",l.Email="email",l.File="file",l.Formula="formula",l.Group="group",l.Hour="hour",l.Integration="integration",l.ItemAssignees="item_assignees",l.ItemId="item_id",l.LastUpdated="last_updated",l.Link="link",l.Location="location",l.LongText="long_text",l.Mirror="mirror",l.Name="name",l.Numbers="numbers",l.People="people",l.Person="person",l.Phone="phone",l.Progress="progress",l.Rating="rating",l.Status="status",l.Subtasks="subtasks",l.Tags="tags",l.Team="team",l.Text="text",l.TimeTracking="time_tracking",l.Timeline="timeline",l.Unsupported="unsupported",l.Vote="vote",l.Week="week",l.WorldClock="world_clock",exports.DuplicateBoardType=void 0,(p=exports.DuplicateBoardType||(exports.DuplicateBoardType={})).DuplicateBoardWithPulses="duplicate_board_with_pulses",p.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",p.DuplicateBoardWithStructure="duplicate_board_with_structure",exports.FileLinkValueKind=void 0,(c=exports.FileLinkValueKind||(exports.FileLinkValueKind={})).Box="box",c.Dropbox="dropbox",c.GoogleDrive="google_drive",c.Link="link",c.Onedrive="onedrive",exports.FirstDayOfTheWeek=void 0,(m=exports.FirstDayOfTheWeek||(exports.FirstDayOfTheWeek={})).Monday="monday",m.Sunday="sunday",exports.FolderColor=void 0,(_=exports.FolderColor||(exports.FolderColor={})).Aquamarine="AQUAMARINE",_.BrightBlue="BRIGHT_BLUE",_.BrightGreen="BRIGHT_GREEN",_.ChiliBlue="CHILI_BLUE",_.DarkOrange="DARK_ORANGE",_.DarkPurple="DARK_PURPLE",_.DarkRed="DARK_RED",_.DoneGreen="DONE_GREEN",_.Indigo="INDIGO",_.Lipstick="LIPSTICK",_.Null="NULL",_.Purple="PURPLE",_.SofiaPink="SOFIA_PINK",_.StuckRed="STUCK_RED",_.Sunset="SUNSET",_.WorkingOrange="WORKING_ORANGE",exports.GroupAttributes=void 0,(b=exports.GroupAttributes||(exports.GroupAttributes={})).Color="color",b.Position="position",b.RelativePositionAfter="relative_position_after",b.RelativePositionBefore="relative_position_before",b.Title="title",exports.ItemsOrderByDirection=void 0,(v=exports.ItemsOrderByDirection||(exports.ItemsOrderByDirection={})).Asc="asc",v.Desc="desc",exports.ItemsQueryOperator=void 0,(h=exports.ItemsQueryOperator||(exports.ItemsQueryOperator={})).And="and",h.Or="or",exports.ItemsQueryRuleOperator=void 0,(g=exports.ItemsQueryRuleOperator||(exports.ItemsQueryRuleOperator={})).AnyOf="any_of",g.Between="between",g.ContainsTerms="contains_terms",g.ContainsText="contains_text",g.EndsWith="ends_with",g.GreaterThan="greater_than",g.GreaterThanOrEquals="greater_than_or_equals",g.IsEmpty="is_empty",g.IsNotEmpty="is_not_empty",g.LowerThan="lower_than",g.LowerThanOrEqual="lower_than_or_equal",g.NotAnyOf="not_any_of",g.NotContainsText="not_contains_text",g.StartsWith="starts_with",g.WithinTheLast="within_the_last",g.WithinTheNext="within_the_next",exports.Kind=void 0,(x=exports.Kind||(exports.Kind={})).Person="person",x.Team="team",exports.NotificationTargetType=void 0,(I=exports.NotificationTargetType||(exports.NotificationTargetType={})).Post="Post",I.Project="Project",exports.NumberValueUnitDirection=void 0,(f=exports.NumberValueUnitDirection||(exports.NumberValueUnitDirection={})).Left="left",f.Right="right",exports.PositionRelative=void 0,(y=exports.PositionRelative||(exports.PositionRelative={})).AfterAt="after_at",y.BeforeAt="before_at",exports.State=void 0,(O=exports.State||(exports.State={})).Active="active",O.All="all",O.Archived="archived",O.Deleted="deleted",exports.UserKind=void 0,(D=exports.UserKind||(exports.UserKind={})).All="all",D.Guests="guests",D.NonGuests="non_guests",D.NonPending="non_pending",exports.VersionKind=void 0,(C=exports.VersionKind||(exports.VersionKind={})).Current="current",C.Deprecated="deprecated",C.Dev="dev",C.Maintenance="maintenance",C.PreviousMaintenance="previous_maintenance",C.ReleaseCandidate="release_candidate",exports.WebhookEventType=void 0,(S=exports.WebhookEventType||(exports.WebhookEventType={})).ChangeColumnValue="change_column_value",S.ChangeName="change_name",S.ChangeSpecificColumnValue="change_specific_column_value",S.ChangeStatusColumnValue="change_status_column_value",S.ChangeSubitemColumnValue="change_subitem_column_value",S.ChangeSubitemName="change_subitem_name",S.CreateColumn="create_column",S.CreateItem="create_item",S.CreateSubitem="create_subitem",S.CreateSubitemUpdate="create_subitem_update",S.CreateUpdate="create_update",S.DeleteUpdate="delete_update",S.EditUpdate="edit_update",S.ItemArchived="item_archived",S.ItemDeleted="item_deleted",S.ItemMovedToAnyGroup="item_moved_to_any_group",S.ItemMovedToSpecificGroup="item_moved_to_specific_group",S.ItemRestored="item_restored",S.MoveSubitem="move_subitem",S.SubitemArchived="subitem_archived",S.SubitemDeleted="subitem_deleted",exports.WorkspaceKind=void 0,($=exports.WorkspaceKind||(exports.WorkspaceKind={})).Closed="closed",$.Open="open",exports.WorkspaceSubscriberKind=void 0,(A=exports.WorkspaceSubscriberKind||(exports.WorkspaceSubscriberKind={})).Owner="owner",A.Subscriber="subscriber",exports.WorkspacesOrderBy=void 0,(exports.WorkspacesOrderBy||(exports.WorkspacesOrderBy={})).CreatedAt="created_at";var k,P,R,w,q,U,G,K,L,M=T.default(k||(k=V(["\n fragment UserFields on User {\n id\n name\n email\n }\n"],["\n fragment UserFields on User {\n id\n name\n email\n }\n"]))),W=T.default(P||(P=V(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),M),F=T.default(R||(R=V(["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),j=T.default(w||(w=V(["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),Q=T.default(q||(q=V(["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"],["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"]))),H=T.default(U||(U=V(["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"],["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"]))),J=T.default(G||(G=V(["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"],["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"]))),z=T.default(K||(K=V(["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"],["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"]))),Y=function(e,t,n,r){return e()};function X(e,t){return void 0===t&&(t=Y),{getMeOp:function(n,r){return t((function(t){return e.request(W,n,B(B({},r),t))}),"getMeOp","query",n)},changeSimpleColumnValueOp:function(n,r){return t((function(t){return e.request(F,n,B(B({},r),t))}),"changeSimpleColumnValueOp","mutation",n)},changeColumnValueOp:function(n,r){return t((function(t){return e.request(j,n,B(B({},r),t))}),"changeColumnValueOp","mutation",n)},createItemOp:function(n,r){return t((function(t){return e.request(Q,n,B(B({},r),t))}),"createItemOp","mutation",n)},changeMultipleColumnValuesOp:function(n,r){return t((function(t){return e.request(H,n,B(B({},r),t))}),"changeMultipleColumnValuesOp","mutation",n)},getBoardItemsOp:function(n,r){return t((function(t){return e.request(J,n,B(B({},r),t))}),"getBoardItemsOp","query",n)},getBoardGroupsOp:function(n,r){return t((function(t){return e.request(z,n,B(B({},r),t))}),"getBoardGroupsOp","query",n)}}}exports.AvailableVersions=void 0,(L=exports.AvailableVersions||(exports.AvailableVersions={})).DEPRECATED="deprecated",L.MAINTENANCE="maintenance",L.CURRENT="current",L.RELEASE_CANDIDATE="release_candidate",L.DEV="dev",L.CURRENT_VERSION="2024-04";var Z="https://api.monday.com/v2",ee=exports.AvailableVersions.CURRENT_VERSION,te="3.0.2",ne=function(e,n){void 0===n&&(n=ee);var r=this;this.query=function(e,t){return N(r,void 0,void 0,(function(){return E(this,(function(n){switch(n.label){case 0:return[4,this.client.request(e,t)];case 1:return[2,n.sent()]}}))}))},this.apiVersion=n;var o=process.env.MONDAY_API_ENDPOINT||Z;this.client=new t.GraphQLClient(o,{headers:{"Content-Type":"application/json",Authorization:e,"API-Version":this.apiVersion,"Api-Sdk-Version":te}}),this.operations=X(this.client)},re=function(){function e(e){void 0===e&&(e=ee),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e}return e.prototype.query=function(e,t,n,r){var o=this;return void 0===r&&(r=6e4),new Promise((function(i,a){var s=o.generateRequestId(),u={query:e,variables:t},d=n||o.apiVersion;window.parent.postMessage({method:"api",args:{params:u,apiVersion:d},requestId:s},"*");var l=setTimeout((function(){a(new Error("Request timed out"))}),r),p=o.addListener(s,(function(e){clearTimeout(l),p(),e.errorMessage?a(new Error("".concat(e.errorMessage," - ").concat(e.data))):i(e)}))}))},e.prototype.addListener=function(e,t){var n=this,r=this.listeners[e]||new Set;return r.add(t),this.listeners[e]=r,function(){r.delete(t),0===r.size&&delete n.listeners[e]}},e}();exports.ApiClient=ne,exports.ChangeColumnValueOpDocument=j,exports.ChangeMultipleColumnValuesOpDocument=H,exports.ChangeSimpleColumnValueOpDocument=F,exports.CreateItemOpDocument=Q,exports.DEFAULT_VERSION=ee,exports.GetBoardGroupsOpDocument=z,exports.GetBoardItemsOpDocument=J,exports.GetMeOpDocument=W,exports.MONDAY_API_ENDPOINT=Z,exports.SeamlessApiClient=re,exports.UserFieldsFragmentDoc=M,exports.getSdk=X; | ||
//# sourceMappingURL=index.js.map |
@@ -1,2 +0,2 @@ | ||
import e from"graphql-tag";import{GraphQLClient as n}from"graphql-request";var t,i,r,o,a,u,s,l,d,c,m,p,_,f,g,h,I,b,v,$,O,y,C,D,S,N,A,E=function(){return E=Object.assign||function(e){for(var n,t=1,i=arguments.length;t<i;t++)for(var r in n=arguments[t])Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);return e},E.apply(this,arguments)};function w(e,n,t,i){return new(t||(t=Promise))((function(r,o){function a(e){try{s(i.next(e))}catch(e){o(e)}}function u(e){try{s(i.throw(e))}catch(e){o(e)}}function s(e){var n;e.done?r(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(a,u)}s((i=i.apply(e,n||[])).next())}))}function P(e,n){var t,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(s){return function(u){if(t)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(t=1,i&&(r=2&u[0]?i.return:u[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,u[1])).done)return r;switch(i=0,r&&(u=[2&u[0],r.value]),u[0]){case 0:case 1:r=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,i=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(r=a.trys,(r=r.length>0&&r[r.length-1])||6!==u[0]&&2!==u[0])){a=0;continue}if(3===u[0]&&(!r||u[1]>r[0]&&u[1]<r[3])){a.label=u[1];break}if(6===u[0]&&a.label<r[1]){a.label=r[1],r=u;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(u);break}r[2]&&a.ops.pop(),a.trys.pop();continue}u=n.call(e,a)}catch(e){u=[6,e],i=0}finally{t=r=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,s])}}}function R(e,n){return Object.defineProperty?Object.defineProperty(e,"raw",{value:n}):e.raw=n,e}"function"==typeof SuppressedError&&SuppressedError,function(e){e.All="all",e.Columns="columns",e.Gallery="gallery"}(t||(t={})),function(e){e.Communication="communication",e.Description="description",e.Name="name"}(i||(i={})),function(e){e.Private="private",e.Public="public",e.Share="share"}(r||(r={})),function(e){e.Board="board",e.CustomObject="custom_object",e.Document="document",e.SubItemsBoard="sub_items_board"}(o||(o={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(a||(a={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(u||(u={})),function(e){e.Description="description",e.Title="title"}(s||(s={})),function(e){e.AutoNumber="auto_number",e.BoardRelation="board_relation",e.Button="button",e.Checkbox="checkbox",e.ColorPicker="color_picker",e.Country="country",e.CreationLog="creation_log",e.Date="date",e.Dependency="dependency",e.Doc="doc",e.Dropdown="dropdown",e.Email="email",e.File="file",e.Formula="formula",e.Group="group",e.Hour="hour",e.Integration="integration",e.ItemAssignees="item_assignees",e.ItemId="item_id",e.LastUpdated="last_updated",e.Link="link",e.Location="location",e.LongText="long_text",e.Mirror="mirror",e.Name="name",e.Numbers="numbers",e.People="people",e.Person="person",e.Phone="phone",e.Progress="progress",e.Rating="rating",e.Status="status",e.Subtasks="subtasks",e.Tags="tags",e.Team="team",e.Text="text",e.TimeTracking="time_tracking",e.Timeline="timeline",e.Unsupported="unsupported",e.Vote="vote",e.Week="week",e.WorldClock="world_clock"}(l||(l={})),function(e){e.DuplicateBoardWithPulses="duplicate_board_with_pulses",e.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",e.DuplicateBoardWithStructure="duplicate_board_with_structure"}(d||(d={})),function(e){e.Box="box",e.Dropbox="dropbox",e.GoogleDrive="google_drive",e.Link="link",e.Onedrive="onedrive"}(c||(c={})),function(e){e.Monday="monday",e.Sunday="sunday"}(m||(m={})),function(e){e.Aquamarine="AQUAMARINE",e.BrightBlue="BRIGHT_BLUE",e.BrightGreen="BRIGHT_GREEN",e.ChiliBlue="CHILI_BLUE",e.DarkOrange="DARK_ORANGE",e.DarkPurple="DARK_PURPLE",e.DarkRed="DARK_RED",e.DoneGreen="DONE_GREEN",e.Indigo="INDIGO",e.Lipstick="LIPSTICK",e.Null="NULL",e.Purple="PURPLE",e.SofiaPink="SOFIA_PINK",e.StuckRed="STUCK_RED",e.Sunset="SUNSET",e.WorkingOrange="WORKING_ORANGE"}(p||(p={})),function(e){e.Color="color",e.Position="position",e.RelativePositionAfter="relative_position_after",e.RelativePositionBefore="relative_position_before",e.Title="title"}(_||(_={})),function(e){e.Asc="asc",e.Desc="desc"}(f||(f={})),function(e){e.And="and",e.Or="or"}(g||(g={})),function(e){e.AnyOf="any_of",e.Between="between",e.ContainsTerms="contains_terms",e.ContainsText="contains_text",e.EndsWith="ends_with",e.GreaterThan="greater_than",e.GreaterThanOrEquals="greater_than_or_equals",e.IsEmpty="is_empty",e.IsNotEmpty="is_not_empty",e.LowerThan="lower_than",e.LowerThanOrEqual="lower_than_or_equal",e.NotAnyOf="not_any_of",e.NotContainsText="not_contains_text",e.StartsWith="starts_with",e.WithinTheLast="within_the_last",e.WithinTheNext="within_the_next"}(h||(h={})),function(e){e.Person="person",e.Team="team"}(I||(I={})),function(e){e.Post="Post",e.Project="Project"}(b||(b={})),function(e){e.Left="left",e.Right="right"}(v||(v={})),function(e){e.AfterAt="after_at",e.BeforeAt="before_at"}($||($={})),function(e){e.Active="active",e.All="all",e.Archived="archived",e.Deleted="deleted"}(O||(O={})),function(e){e.All="all",e.Guests="guests",e.NonGuests="non_guests",e.NonPending="non_pending"}(y||(y={})),function(e){e.Current="current",e.Deprecated="deprecated",e.Dev="dev",e.Maintenance="maintenance",e.PreviousMaintenance="previous_maintenance",e.ReleaseCandidate="release_candidate"}(C||(C={})),function(e){e.ChangeColumnValue="change_column_value",e.ChangeName="change_name",e.ChangeSpecificColumnValue="change_specific_column_value",e.ChangeStatusColumnValue="change_status_column_value",e.ChangeSubitemColumnValue="change_subitem_column_value",e.ChangeSubitemName="change_subitem_name",e.CreateColumn="create_column",e.CreateItem="create_item",e.CreateSubitem="create_subitem",e.CreateSubitemUpdate="create_subitem_update",e.CreateUpdate="create_update",e.DeleteUpdate="delete_update",e.EditUpdate="edit_update",e.ItemArchived="item_archived",e.ItemDeleted="item_deleted",e.ItemMovedToAnyGroup="item_moved_to_any_group",e.ItemMovedToSpecificGroup="item_moved_to_specific_group",e.ItemRestored="item_restored",e.MoveSubitem="move_subitem",e.SubitemArchived="subitem_archived",e.SubitemDeleted="subitem_deleted"}(D||(D={})),function(e){e.Closed="closed",e.Open="open"}(S||(S={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(N||(N={})),function(e){e.CreatedAt="created_at"}(A||(A={}));var T,q,V,k,B,U,G,x,L,M=e(T||(T=R(["\n fragment UserFields on User {\n id\n name\n email\n }\n"],["\n fragment UserFields on User {\n id\n name\n email\n }\n"]))),W=e(q||(q=R(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),M),j=e(V||(V=R(["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),F=e(k||(k=R(["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),K=e(B||(B=R(["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"],["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"]))),H=e(U||(U=R(["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"],["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"]))),J=e(G||(G=R(["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"],["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"]))),z=e(x||(x=R(["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"],["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"]))),Q=function(e,n,t,i){return e()};function Y(e,n){return void 0===n&&(n=Q),{getMeOp:function(t,i){return n((function(n){return e.request(W,t,E(E({},i),n))}),"getMeOp","query",t)},changeSimpleColumnValueOp:function(t,i){return n((function(n){return e.request(j,t,E(E({},i),n))}),"changeSimpleColumnValueOp","mutation",t)},changeColumnValueOp:function(t,i){return n((function(n){return e.request(F,t,E(E({},i),n))}),"changeColumnValueOp","mutation",t)},createItemOp:function(t,i){return n((function(n){return e.request(K,t,E(E({},i),n))}),"createItemOp","mutation",t)},changeMultipleColumnValuesOp:function(t,i){return n((function(n){return e.request(H,t,E(E({},i),n))}),"changeMultipleColumnValuesOp","mutation",t)},getBoardItemsOp:function(t,i){return n((function(n){return e.request(J,t,E(E({},i),n))}),"getBoardItemsOp","query",t)},getBoardGroupsOp:function(t,i){return n((function(n){return e.request(z,t,E(E({},i),n))}),"getBoardGroupsOp","query",t)}}}!function(e){e.DEPRECATED="deprecated",e.MAINTENANCE="maintenance",e.CURRENT="current",e.RELEASE_CANDIDATE="release_candidate",e.DEV="dev",e.CURRENT_VERSION="2024-04"}(L||(L={}));var X="https://api.monday.com/v2",Z=L.CURRENT_VERSION,ee="3.0.0",ne=function(e,t){void 0===t&&(t=Z);var i=this;this.query=function(e,n){return w(i,void 0,void 0,(function(){return P(this,(function(t){switch(t.label){case 0:return[4,this.client.request(e,n)];case 1:return[2,t.sent()]}}))}))},this.apiVersion=t;var r=process.env.MONDAY_API_ENDPOINT||X;this.client=new n(r,{headers:{"Content-Type":"application/json",Authorization:e,"API-Version":this.apiVersion,"Api-Sdk-Version":ee}}),this.operations=Y(this.client)},te=function(){function e(e){void 0===e&&(e=Z),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e}return e.prototype.query=function(e,n,t,i){var r=this;return void 0===i&&(i=6e4),new Promise((function(o,a){var u=r.generateRequestId(),s={query:e,variables:n},l=t||r.apiVersion;window.parent.postMessage({method:"api",args:{params:s,apiVersion:l},requestId:u},"*");var d=setTimeout((function(){a(new Error("Request timed out"))}),i),c=r.addListener(u,(function(e){clearTimeout(d),c(),e.errorMessage?a(new Error("".concat(e.errorMessage," - ").concat(e.data))):o(e)}))}))},e.prototype.addListener=function(e,n){var t=this,i=this.listeners[e]||new Set;return i.add(n),this.listeners[e]=i,function(){i.delete(n),0===i.size&&delete t.listeners[e]}},e}();export{ne as ApiClient,t as AssetsSource,L as AvailableVersions,i as BoardAttributes,r as BoardKind,o as BoardObjectType,a as BoardSubscriberKind,u as BoardsOrderBy,F as ChangeColumnValueOpDocument,H as ChangeMultipleColumnValuesOpDocument,j as ChangeSimpleColumnValueOpDocument,s as ColumnProperty,l as ColumnType,K as CreateItemOpDocument,Z as DEFAULT_VERSION,d as DuplicateBoardType,c as FileLinkValueKind,m as FirstDayOfTheWeek,p as FolderColor,z as GetBoardGroupsOpDocument,J as GetBoardItemsOpDocument,W as GetMeOpDocument,_ as GroupAttributes,f as ItemsOrderByDirection,g as ItemsQueryOperator,h as ItemsQueryRuleOperator,I as Kind,X as MONDAY_API_ENDPOINT,b as NotificationTargetType,v as NumberValueUnitDirection,$ as PositionRelative,te as SeamlessApiClient,O as State,M as UserFieldsFragmentDoc,y as UserKind,C as VersionKind,D as WebhookEventType,S as WorkspaceKind,N as WorkspaceSubscriberKind,A as WorkspacesOrderBy,Y as getSdk}; | ||
import e from"graphql-tag";import{GraphQLClient as n}from"graphql-request";var t,i,r,o,a,u,s,l,d,c,m,p,_,f,g,h,I,b,v,$,O,y,C,D,S,N,A,E=function(){return E=Object.assign||function(e){for(var n,t=1,i=arguments.length;t<i;t++)for(var r in n=arguments[t])Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);return e},E.apply(this,arguments)};function w(e,n,t,i){return new(t||(t=Promise))((function(r,o){function a(e){try{s(i.next(e))}catch(e){o(e)}}function u(e){try{s(i.throw(e))}catch(e){o(e)}}function s(e){var n;e.done?r(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(a,u)}s((i=i.apply(e,n||[])).next())}))}function P(e,n){var t,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(s){return function(u){if(t)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(t=1,i&&(r=2&u[0]?i.return:u[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,u[1])).done)return r;switch(i=0,r&&(u=[2&u[0],r.value]),u[0]){case 0:case 1:r=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,i=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(r=a.trys,(r=r.length>0&&r[r.length-1])||6!==u[0]&&2!==u[0])){a=0;continue}if(3===u[0]&&(!r||u[1]>r[0]&&u[1]<r[3])){a.label=u[1];break}if(6===u[0]&&a.label<r[1]){a.label=r[1],r=u;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(u);break}r[2]&&a.ops.pop(),a.trys.pop();continue}u=n.call(e,a)}catch(e){u=[6,e],i=0}finally{t=r=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,s])}}}function R(e,n){return Object.defineProperty?Object.defineProperty(e,"raw",{value:n}):e.raw=n,e}"function"==typeof SuppressedError&&SuppressedError,function(e){e.All="all",e.Columns="columns",e.Gallery="gallery"}(t||(t={})),function(e){e.Communication="communication",e.Description="description",e.Name="name"}(i||(i={})),function(e){e.Private="private",e.Public="public",e.Share="share"}(r||(r={})),function(e){e.Board="board",e.CustomObject="custom_object",e.Document="document",e.SubItemsBoard="sub_items_board"}(o||(o={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(a||(a={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(u||(u={})),function(e){e.Description="description",e.Title="title"}(s||(s={})),function(e){e.AutoNumber="auto_number",e.BoardRelation="board_relation",e.Button="button",e.Checkbox="checkbox",e.ColorPicker="color_picker",e.Country="country",e.CreationLog="creation_log",e.Date="date",e.Dependency="dependency",e.Doc="doc",e.Dropdown="dropdown",e.Email="email",e.File="file",e.Formula="formula",e.Group="group",e.Hour="hour",e.Integration="integration",e.ItemAssignees="item_assignees",e.ItemId="item_id",e.LastUpdated="last_updated",e.Link="link",e.Location="location",e.LongText="long_text",e.Mirror="mirror",e.Name="name",e.Numbers="numbers",e.People="people",e.Person="person",e.Phone="phone",e.Progress="progress",e.Rating="rating",e.Status="status",e.Subtasks="subtasks",e.Tags="tags",e.Team="team",e.Text="text",e.TimeTracking="time_tracking",e.Timeline="timeline",e.Unsupported="unsupported",e.Vote="vote",e.Week="week",e.WorldClock="world_clock"}(l||(l={})),function(e){e.DuplicateBoardWithPulses="duplicate_board_with_pulses",e.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",e.DuplicateBoardWithStructure="duplicate_board_with_structure"}(d||(d={})),function(e){e.Box="box",e.Dropbox="dropbox",e.GoogleDrive="google_drive",e.Link="link",e.Onedrive="onedrive"}(c||(c={})),function(e){e.Monday="monday",e.Sunday="sunday"}(m||(m={})),function(e){e.Aquamarine="AQUAMARINE",e.BrightBlue="BRIGHT_BLUE",e.BrightGreen="BRIGHT_GREEN",e.ChiliBlue="CHILI_BLUE",e.DarkOrange="DARK_ORANGE",e.DarkPurple="DARK_PURPLE",e.DarkRed="DARK_RED",e.DoneGreen="DONE_GREEN",e.Indigo="INDIGO",e.Lipstick="LIPSTICK",e.Null="NULL",e.Purple="PURPLE",e.SofiaPink="SOFIA_PINK",e.StuckRed="STUCK_RED",e.Sunset="SUNSET",e.WorkingOrange="WORKING_ORANGE"}(p||(p={})),function(e){e.Color="color",e.Position="position",e.RelativePositionAfter="relative_position_after",e.RelativePositionBefore="relative_position_before",e.Title="title"}(_||(_={})),function(e){e.Asc="asc",e.Desc="desc"}(f||(f={})),function(e){e.And="and",e.Or="or"}(g||(g={})),function(e){e.AnyOf="any_of",e.Between="between",e.ContainsTerms="contains_terms",e.ContainsText="contains_text",e.EndsWith="ends_with",e.GreaterThan="greater_than",e.GreaterThanOrEquals="greater_than_or_equals",e.IsEmpty="is_empty",e.IsNotEmpty="is_not_empty",e.LowerThan="lower_than",e.LowerThanOrEqual="lower_than_or_equal",e.NotAnyOf="not_any_of",e.NotContainsText="not_contains_text",e.StartsWith="starts_with",e.WithinTheLast="within_the_last",e.WithinTheNext="within_the_next"}(h||(h={})),function(e){e.Person="person",e.Team="team"}(I||(I={})),function(e){e.Post="Post",e.Project="Project"}(b||(b={})),function(e){e.Left="left",e.Right="right"}(v||(v={})),function(e){e.AfterAt="after_at",e.BeforeAt="before_at"}($||($={})),function(e){e.Active="active",e.All="all",e.Archived="archived",e.Deleted="deleted"}(O||(O={})),function(e){e.All="all",e.Guests="guests",e.NonGuests="non_guests",e.NonPending="non_pending"}(y||(y={})),function(e){e.Current="current",e.Deprecated="deprecated",e.Dev="dev",e.Maintenance="maintenance",e.PreviousMaintenance="previous_maintenance",e.ReleaseCandidate="release_candidate"}(C||(C={})),function(e){e.ChangeColumnValue="change_column_value",e.ChangeName="change_name",e.ChangeSpecificColumnValue="change_specific_column_value",e.ChangeStatusColumnValue="change_status_column_value",e.ChangeSubitemColumnValue="change_subitem_column_value",e.ChangeSubitemName="change_subitem_name",e.CreateColumn="create_column",e.CreateItem="create_item",e.CreateSubitem="create_subitem",e.CreateSubitemUpdate="create_subitem_update",e.CreateUpdate="create_update",e.DeleteUpdate="delete_update",e.EditUpdate="edit_update",e.ItemArchived="item_archived",e.ItemDeleted="item_deleted",e.ItemMovedToAnyGroup="item_moved_to_any_group",e.ItemMovedToSpecificGroup="item_moved_to_specific_group",e.ItemRestored="item_restored",e.MoveSubitem="move_subitem",e.SubitemArchived="subitem_archived",e.SubitemDeleted="subitem_deleted"}(D||(D={})),function(e){e.Closed="closed",e.Open="open"}(S||(S={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(N||(N={})),function(e){e.CreatedAt="created_at"}(A||(A={}));var T,q,V,k,B,U,G,x,L,M=e(T||(T=R(["\n fragment UserFields on User {\n id\n name\n email\n }\n"],["\n fragment UserFields on User {\n id\n name\n email\n }\n"]))),W=e(q||(q=R(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),M),j=e(V||(V=R(["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeSimpleColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: String!) {\n change_simple_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),F=e(k||(k=R(["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"],["\n mutation changeColumnValueOp($boardId: ID!, $itemId: ID!, $columnId: String!, $value: JSON!) {\n change_column_value(board_id: $boardId, item_id: $itemId, column_id: $columnId, value: $value) {\n id\n }\n }\n"]))),K=e(B||(B=R(["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"],["\n mutation createItemOp($boardId: ID!, $groupId: String!, $itemName: String!) {\n create_item(board_id: $boardId, group_id: $groupId, item_name: $itemName) {\n id\n name\n }\n }\n"]))),H=e(U||(U=R(["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"],["\n mutation changeMultipleColumnValuesOp($boardId: ID!, $itemId: ID!, $columnValues: JSON!) {\n change_multiple_column_values(board_id: $boardId, item_id: $itemId, column_values: $columnValues) {\n id\n name\n column_values {\n id\n value\n }\n }\n }\n"]))),J=e(G||(G=R(["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"],["\n query getBoardItemsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n items_page {\n items {\n id\n name\n column_values {\n id\n type\n value\n }\n }\n }\n }\n }\n"]))),z=e(x||(x=R(["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"],["\n query getBoardGroupsOp($ids: [ID!]!) {\n boards(ids: $ids) {\n groups {\n id\n title\n }\n }\n }\n"]))),Q=function(e,n,t,i){return e()};function Y(e,n){return void 0===n&&(n=Q),{getMeOp:function(t,i){return n((function(n){return e.request(W,t,E(E({},i),n))}),"getMeOp","query",t)},changeSimpleColumnValueOp:function(t,i){return n((function(n){return e.request(j,t,E(E({},i),n))}),"changeSimpleColumnValueOp","mutation",t)},changeColumnValueOp:function(t,i){return n((function(n){return e.request(F,t,E(E({},i),n))}),"changeColumnValueOp","mutation",t)},createItemOp:function(t,i){return n((function(n){return e.request(K,t,E(E({},i),n))}),"createItemOp","mutation",t)},changeMultipleColumnValuesOp:function(t,i){return n((function(n){return e.request(H,t,E(E({},i),n))}),"changeMultipleColumnValuesOp","mutation",t)},getBoardItemsOp:function(t,i){return n((function(n){return e.request(J,t,E(E({},i),n))}),"getBoardItemsOp","query",t)},getBoardGroupsOp:function(t,i){return n((function(n){return e.request(z,t,E(E({},i),n))}),"getBoardGroupsOp","query",t)}}}!function(e){e.DEPRECATED="deprecated",e.MAINTENANCE="maintenance",e.CURRENT="current",e.RELEASE_CANDIDATE="release_candidate",e.DEV="dev",e.CURRENT_VERSION="2024-04"}(L||(L={}));var X="https://api.monday.com/v2",Z=L.CURRENT_VERSION,ee="3.0.2",ne=function(e,t){void 0===t&&(t=Z);var i=this;this.query=function(e,n){return w(i,void 0,void 0,(function(){return P(this,(function(t){switch(t.label){case 0:return[4,this.client.request(e,n)];case 1:return[2,t.sent()]}}))}))},this.apiVersion=t;var r=process.env.MONDAY_API_ENDPOINT||X;this.client=new n(r,{headers:{"Content-Type":"application/json",Authorization:e,"API-Version":this.apiVersion,"Api-Sdk-Version":ee}}),this.operations=Y(this.client)},te=function(){function e(e){void 0===e&&(e=Z),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e}return e.prototype.query=function(e,n,t,i){var r=this;return void 0===i&&(i=6e4),new Promise((function(o,a){var u=r.generateRequestId(),s={query:e,variables:n},l=t||r.apiVersion;window.parent.postMessage({method:"api",args:{params:s,apiVersion:l},requestId:u},"*");var d=setTimeout((function(){a(new Error("Request timed out"))}),i),c=r.addListener(u,(function(e){clearTimeout(d),c(),e.errorMessage?a(new Error("".concat(e.errorMessage," - ").concat(e.data))):o(e)}))}))},e.prototype.addListener=function(e,n){var t=this,i=this.listeners[e]||new Set;return i.add(n),this.listeners[e]=i,function(){i.delete(n),0===i.size&&delete t.listeners[e]}},e}();export{ne as ApiClient,t as AssetsSource,L as AvailableVersions,i as BoardAttributes,r as BoardKind,o as BoardObjectType,a as BoardSubscriberKind,u as BoardsOrderBy,F as ChangeColumnValueOpDocument,H as ChangeMultipleColumnValuesOpDocument,j as ChangeSimpleColumnValueOpDocument,s as ColumnProperty,l as ColumnType,K as CreateItemOpDocument,Z as DEFAULT_VERSION,d as DuplicateBoardType,c as FileLinkValueKind,m as FirstDayOfTheWeek,p as FolderColor,z as GetBoardGroupsOpDocument,J as GetBoardItemsOpDocument,W as GetMeOpDocument,_ as GroupAttributes,f as ItemsOrderByDirection,g as ItemsQueryOperator,h as ItemsQueryRuleOperator,I as Kind,X as MONDAY_API_ENDPOINT,b as NotificationTargetType,v as NumberValueUnitDirection,$ as PositionRelative,te as SeamlessApiClient,O as State,M as UserFieldsFragmentDoc,y as UserKind,C as VersionKind,D as WebhookEventType,S as WorkspaceKind,N as WorkspaceSubscriberKind,A as WorkspacesOrderBy,Y as getSdk}; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@mondaydotcomorg/api", | ||
"version": "3.0.1", | ||
"version": "3.0.2", | ||
"description": "monday.com API client", | ||
@@ -18,9 +18,5 @@ "main": "dist/cjs/index.js", | ||
"watch": "rollup -c -w", | ||
"update-versions": "tsc scripts/update-versions.ts || true; node scripts/update-versions.js" | ||
"update-versions": "npm run build && node dist/scripts/update-versions.js", | ||
"prepublish": "npm version patch && npm run build" | ||
}, | ||
"dependencies": { | ||
"graphql-request": "^6.1.0", | ||
"graphql-tag": "^2.12.6", | ||
"moment": "^2.30.1" | ||
}, | ||
"engines": { | ||
@@ -40,3 +36,8 @@ "node": ">= 16.20.0" | ||
}, | ||
"dependencies": { | ||
"graphql-request": "^6.1.0", | ||
"graphql-tag": "^2.12.6" | ||
}, | ||
"devDependencies": { | ||
"moment": "^2.30.1", | ||
"@rollup/plugin-commonjs": "^25.0.7", | ||
@@ -43,0 +44,0 @@ "@rollup/plugin-json": "^6.1.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
769458
2
30
16303
14
3
3
- Removedmoment@^2.30.1
- Removedmoment@2.30.1(transitive)