Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@mondaydotcomorg/api

Package Overview
Dependencies
Maintainers
0
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mondaydotcomorg/api - npm Package Compare versions

Comparing version 7.0.1-beta.8 to 7.0.1

2

dist/cjs/index.js

@@ -1,2 +0,2 @@

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("graphql-tag"),t=require("graphql-request");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o=r(e),n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)};var i,a,s,u,d,l,p,c,m,_,v,I,h,g,x,b,O,f,y,E,C,A,D,N,T,P,B,S,L,R,w,$,k,V,G=function(){return G=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},G.apply(this,arguments)};function F(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{u(o.next(e))}catch(e){i(e)}}function s(e){try{u(o.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((o=o.apply(e,t||[])).next())}))}function M(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[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(r)throw new TypeError("Generator is already executing.");for(;i&&(i=0,s[0]&&(a=0)),a;)try{if(r=1,o&&(n=2&s[0]?o.return:s[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,s[1])).done)return n;switch(o=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,o=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){a=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){a.label=s[1];break}if(6===s[0]&&a.label<n[1]){a.label=n[1],n=s;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(s);break}n[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(e){s=[6,e],o=0}finally{r=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function U(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}"function"==typeof SuppressedError&&SuppressedError,exports.AssetsSource=void 0,(i=exports.AssetsSource||(exports.AssetsSource={})).All="all",i.Columns="columns",i.Gallery="gallery",exports.BoardAttributes=void 0,(a=exports.BoardAttributes||(exports.BoardAttributes={})).Communication="communication",a.Description="description",a.Name="name",exports.BoardEditPermissions=void 0,(s=exports.BoardEditPermissions||(exports.BoardEditPermissions={})).Assignee="assignee",s.Collaborators="collaborators",s.Everyone="everyone",s.Owners="owners",exports.BoardKind=void 0,(u=exports.BoardKind||(exports.BoardKind={})).Private="private",u.Public="public",u.Share="share",exports.BoardObjectType=void 0,(d=exports.BoardObjectType||(exports.BoardObjectType={})).Board="board",d.CustomObject="custom_object",d.Document="document",d.SubItemsBoard="sub_items_board",exports.BoardSubscriberKind=void 0,(l=exports.BoardSubscriberKind||(exports.BoardSubscriberKind={})).Owner="owner",l.Subscriber="subscriber",exports.BoardViewPermissions=void 0,(exports.BoardViewPermissions||(exports.BoardViewPermissions={})).AnyAssigneeColumn="any_assignee_column",exports.BoardsOrderBy=void 0,(p=exports.BoardsOrderBy||(exports.BoardsOrderBy={})).CreatedAt="created_at",p.UsedAt="used_at",exports.ColumnProperty=void 0,(c=exports.ColumnProperty||(exports.ColumnProperty={})).Description="description",c.Title="title",exports.ColumnType=void 0,(m=exports.ColumnType||(exports.ColumnType={})).AutoNumber="auto_number",m.BoardRelation="board_relation",m.Button="button",m.Checkbox="checkbox",m.ColorPicker="color_picker",m.Country="country",m.CreationLog="creation_log",m.Date="date",m.Dependency="dependency",m.Doc="doc",m.Dropdown="dropdown",m.Email="email",m.File="file",m.Formula="formula",m.Group="group",m.Hour="hour",m.Integration="integration",m.ItemAssignees="item_assignees",m.ItemId="item_id",m.LastUpdated="last_updated",m.Link="link",m.Location="location",m.LongText="long_text",m.Mirror="mirror",m.Name="name",m.Numbers="numbers",m.People="people",m.Person="person",m.Phone="phone",m.Progress="progress",m.Rating="rating",m.Status="status",m.Subtasks="subtasks",m.Tags="tags",m.Team="team",m.Text="text",m.TimeTracking="time_tracking",m.Timeline="timeline",m.Unsupported="unsupported",m.Vote="vote",m.Week="week",m.WorldClock="world_clock",exports.CustomActivityColor=void 0,(_=exports.CustomActivityColor||(exports.CustomActivityColor={})).BrinkPink="BRINK_PINK",_.CelticBlue="CELTIC_BLUE",_.CornflowerBlue="CORNFLOWER_BLUE",_.DingyDungeon="DINGY_DUNGEON",_.GoGreen="GO_GREEN",_.Gray="GRAY",_.LightDeepPink="LIGHT_DEEP_PINK",_.LightHotPink="LIGHT_HOT_PINK",_.MayaBlue="MAYA_BLUE",_.MediumTurquoise="MEDIUM_TURQUOISE",_.ParadisePink="PARADISE_PINK",_.PhilippineGreen="PHILIPPINE_GREEN",_.PhilippineYellow="PHILIPPINE_YELLOW",_.SlateBlue="SLATE_BLUE",_.VividCerulean="VIVID_CERULEAN",_.YankeesBlue="YANKEES_BLUE",_.YellowGreen="YELLOW_GREEN",_.YellowOrange="YELLOW_ORANGE",exports.CustomActivityIcon=void 0,(v=exports.CustomActivityIcon||(exports.CustomActivityIcon={})).Ascending="ASCENDING",v.Camera="CAMERA",v.Conference="CONFERENCE",v.Flag="FLAG",v.Gift="GIFT",v.Headphones="HEADPHONES",v.Homekeys="HOMEKEYS",v.Location="LOCATION",v.Notebook="NOTEBOOK",v.Paperplane="PAPERPLANE",v.Plane="PLANE",v.Pliers="PLIERS",v.Tripod="TRIPOD",v.Twoflags="TWOFLAGS",v.Utencils="UTENCILS",exports.DiscountPeriod=void 0,(I=exports.DiscountPeriod||(exports.DiscountPeriod={})).Monthly="MONTHLY",I.Yearly="YEARLY",exports.DocBlockContentType=void 0,(h=exports.DocBlockContentType||(exports.DocBlockContentType={})).BulletedList="bulleted_list",h.CheckList="check_list",h.Code="code",h.Divider="divider",h.Image="image",h.LargeTitle="large_title",h.Layout="layout",h.MediumTitle="medium_title",h.NormalText="normal_text",h.NoticeBox="notice_box",h.NumberedList="numbered_list",h.Quote="quote",h.SmallTitle="small_title",h.Table="table",h.Video="video",exports.DocsOrderBy=void 0,(g=exports.DocsOrderBy||(exports.DocsOrderBy={})).CreatedAt="created_at",g.UsedAt="used_at",exports.DuplicateBoardType=void 0,(x=exports.DuplicateBoardType||(exports.DuplicateBoardType={})).DuplicateBoardWithPulses="duplicate_board_with_pulses",x.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",x.DuplicateBoardWithStructure="duplicate_board_with_structure",exports.FileLinkValueKind=void 0,(b=exports.FileLinkValueKind||(exports.FileLinkValueKind={})).Box="box",b.Dropbox="dropbox",b.GoogleDrive="google_drive",b.Link="link",b.Onedrive="onedrive",exports.FirstDayOfTheWeek=void 0,(O=exports.FirstDayOfTheWeek||(exports.FirstDayOfTheWeek={})).Monday="monday",O.Sunday="sunday",exports.FolderColor=void 0,(f=exports.FolderColor||(exports.FolderColor={})).Aquamarine="AQUAMARINE",f.BrightBlue="BRIGHT_BLUE",f.BrightGreen="BRIGHT_GREEN",f.ChiliBlue="CHILI_BLUE",f.DarkOrange="DARK_ORANGE",f.DarkPurple="DARK_PURPLE",f.DarkRed="DARK_RED",f.DoneGreen="DONE_GREEN",f.Indigo="INDIGO",f.Lipstick="LIPSTICK",f.Null="NULL",f.Purple="PURPLE",f.SofiaPink="SOFIA_PINK",f.StuckRed="STUCK_RED",f.Sunset="SUNSET",f.WorkingOrange="WORKING_ORANGE",exports.FolderCustomIcon=void 0,(y=exports.FolderCustomIcon||(exports.FolderCustomIcon={})).Folder="FOLDER",y.Morebelow="MOREBELOW",y.Morebelowfilled="MOREBELOWFILLED",y.Null="NULL",y.Work="WORK",exports.FolderFontWeight=void 0,(E=exports.FolderFontWeight||(exports.FolderFontWeight={})).FontWeightBold="FONT_WEIGHT_BOLD",E.FontWeightLight="FONT_WEIGHT_LIGHT",E.FontWeightNormal="FONT_WEIGHT_NORMAL",E.FontWeightVeryLight="FONT_WEIGHT_VERY_LIGHT",E.Null="NULL",exports.GroupAttributes=void 0,(C=exports.GroupAttributes||(exports.GroupAttributes={})).Color="color",C.Position="position",C.RelativePositionAfter="relative_position_after",C.RelativePositionBefore="relative_position_before",C.Title="title",exports.ItemsOrderByDirection=void 0,(A=exports.ItemsOrderByDirection||(exports.ItemsOrderByDirection={})).Asc="asc",A.Desc="desc",exports.ItemsQueryOperator=void 0,(D=exports.ItemsQueryOperator||(exports.ItemsQueryOperator={})).And="and",D.Or="or",exports.ItemsQueryRuleOperator=void 0,(N=exports.ItemsQueryRuleOperator||(exports.ItemsQueryRuleOperator={})).AnyOf="any_of",N.Between="between",N.ContainsTerms="contains_terms",N.ContainsText="contains_text",N.EndsWith="ends_with",N.GreaterThan="greater_than",N.GreaterThanOrEquals="greater_than_or_equals",N.IsEmpty="is_empty",N.IsNotEmpty="is_not_empty",N.LowerThan="lower_than",N.LowerThanOrEqual="lower_than_or_equal",N.NotAnyOf="not_any_of",N.NotContainsText="not_contains_text",N.StartsWith="starts_with",N.WithinTheLast="within_the_last",N.WithinTheNext="within_the_next",exports.Kind=void 0,(T=exports.Kind||(exports.Kind={})).Person="person",T.Team="team",exports.NotificationTargetType=void 0,(P=exports.NotificationTargetType||(exports.NotificationTargetType={})).Post="Post",P.Project="Project",exports.NumberValueUnitDirection=void 0,(B=exports.NumberValueUnitDirection||(exports.NumberValueUnitDirection={})).Left="left",B.Right="right",exports.PositionRelative=void 0,(S=exports.PositionRelative||(exports.PositionRelative={})).AfterAt="after_at",S.BeforeAt="before_at",exports.State=void 0,(L=exports.State||(exports.State={})).Active="active",L.All="all",L.Archived="archived",L.Deleted="deleted",exports.UserKind=void 0,(R=exports.UserKind||(exports.UserKind={})).All="all",R.Guests="guests",R.NonGuests="non_guests",R.NonPending="non_pending",exports.VersionKind=void 0,(w=exports.VersionKind||(exports.VersionKind={})).Current="current",w.Deprecated="deprecated",w.Dev="dev",w.Maintenance="maintenance",w.OldMaintenance="old__maintenance",w.OldPreviousMaintenance="old_previous_maintenance",w.PreviousMaintenance="previous_maintenance",w.ReleaseCandidate="release_candidate",exports.WebhookEventType=void 0,($=exports.WebhookEventType||(exports.WebhookEventType={})).ChangeColumnValue="change_column_value",$.ChangeName="change_name",$.ChangeSpecificColumnValue="change_specific_column_value",$.ChangeStatusColumnValue="change_status_column_value",$.ChangeSubitemColumnValue="change_subitem_column_value",$.ChangeSubitemName="change_subitem_name",$.CreateColumn="create_column",$.CreateItem="create_item",$.CreateSubitem="create_subitem",$.CreateSubitemUpdate="create_subitem_update",$.CreateUpdate="create_update",$.DeleteUpdate="delete_update",$.EditUpdate="edit_update",$.ItemArchived="item_archived",$.ItemDeleted="item_deleted",$.ItemMovedToAnyGroup="item_moved_to_any_group",$.ItemMovedToSpecificGroup="item_moved_to_specific_group",$.ItemRestored="item_restored",$.MoveSubitem="move_subitem",$.SubitemArchived="subitem_archived",$.SubitemDeleted="subitem_deleted",exports.WorkspaceKind=void 0,(k=exports.WorkspaceKind||(exports.WorkspaceKind={})).Closed="closed",k.Open="open",exports.WorkspaceSubscriberKind=void 0,(V=exports.WorkspaceSubscriberKind||(exports.WorkspaceSubscriberKind={})).Owner="owner",V.Subscriber="subscriber",exports.WorkspacesOrderBy=void 0,(exports.WorkspacesOrderBy||(exports.WorkspacesOrderBy={})).CreatedAt="created_at";var W,q,K,H,Y,j,Q,J,z,X=o.default(W||(W=U(["\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"]))),Z=o.default(q||(q=U(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),X),ee=o.default(K||(K=U(["\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"]))),te=o.default(H||(H=U(["\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"]))),re=o.default(Y||(Y=U(["\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"]))),oe=o.default(j||(j=U(["\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"]))),ne=o.default(Q||(Q=U(["\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"]))),ie=o.default(J||(J=U(["\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"]))),ae=function(e,t,r,o){return e()};function se(e,t){return void 0===t&&(t=ae),{getMeOp:function(r,o){return t((function(t){return e.request(Z,r,G(G({},o),t))}),"getMeOp","query",r)},changeSimpleColumnValueOp:function(r,o){return t((function(t){return e.request(ee,r,G(G({},o),t))}),"changeSimpleColumnValueOp","mutation",r)},changeColumnValueOp:function(r,o){return t((function(t){return e.request(te,r,G(G({},o),t))}),"changeColumnValueOp","mutation",r)},createItemOp:function(r,o){return t((function(t){return e.request(re,r,G(G({},o),t))}),"createItemOp","mutation",r)},changeMultipleColumnValuesOp:function(r,o){return t((function(t){return e.request(oe,r,G(G({},o),t))}),"changeMultipleColumnValuesOp","mutation",r)},getBoardItemsOp:function(r,o){return t((function(t){return e.request(ne,r,G(G({},o),t))}),"getBoardItemsOp","query",r)},getBoardGroupsOp:function(r,o){return t((function(t){return e.request(ie,r,G(G({},o),t))}),"getBoardGroupsOp","query",r)}}}exports.AvailableVersions=void 0,(z=exports.AvailableVersions||(exports.AvailableVersions={})).DEPRECATED="deprecated",z.MAINTENANCE="maintenance",z.CURRENT="current",z.RELEASE_CANDIDATE="release_candidate",z.DEV="dev",z.CURRENT_VERSION="2024-10";var ue="https://api.monday.com/v2",de=exports.AvailableVersions.CURRENT_VERSION,le="7.0.1-beta.8",pe=function(){function e(e){var r=this;this.request=function(e,t){return F(r,void 0,void 0,(function(){return M(this,(function(r){switch(r.label){case 0:return[4,this.client.request(e,t)];case 1:return[2,r.sent()]}}))}))},this.rawRequest=function(e,t){return F(r,void 0,void 0,(function(){return M(this,(function(r){switch(r.label){case 0:return[4,this.client.rawRequest(e,t)];case 1:return[2,r.sent()]}}))}))};var o=e.token,n=e.apiVersion,i=void 0===n?de:n,a=e.requestConfig,s=void 0===a?{}:a;if(!this.isValidApiVersion(i))throw new Error("Invalid API version format. Expected format is 'yyyy-mm' with month as one of '01', '04', '07', or '10'.");this.apiVersion=i;var u=function(){if(process.env.MONDAY_API_ENDPOINT)return process.env.MONDAY_API_ENDPOINT;var e=process.env.PLATFORM_API;if(e)try{var t=JSON.parse(e);if(t.PLATFORM_API_ENDPOINT)return t.PLATFORM_API_ENDPOINT}catch(e){console.error("Failed to parse PLATFORM_API secret",e)}return ue}();this.client=new t.GraphQLClient(u,G(G({},s),{headers:{"Content-Type":"application/json",Authorization:o,"API-Version":this.apiVersion,"Api-Sdk-Version":le}})),this.operations=se(this.client)}return e.prototype.isValidApiVersion=function(e){return/^\d{4}-(01|04|07|10)$/.test(e)},e}(),ce=function(e){function t(t,r){var o=e.call(this,t)||this;return o.response={errors:r},o.name=o.constructor.name,o.type="SeamlessApiClientError",o}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(t,e),t}(Error),me=function(){function e(e){void 0===e&&(e=de),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e,window.addEventListener("message",this.receiveMessage.bind(this),!1)}return e.prototype.request=function(e,t,r,o){var n=this;return void 0===o&&(o=6e4),new Promise((function(i,a){var s=n.generateRequestId(),u={query:e,variables:t},d=r||n.apiVersion;window.parent.postMessage({method:"api",args:{params:u,apiVersion:d},requestId:s},"*");var l=setTimeout((function(){a(new Error("Request timed out"))}),o),p=n.addListener(s,(function(e){if(clearTimeout(l),p(),e.errorMessage){var t=new ce(e.errorMessage,e.data.errors);a(t)}else i(e)}))}))},e.prototype.addListener=function(e,t){var r=this,o=this.listeners[e]||new Set;return o.add(t),this.listeners[e]=o,function(){o.delete(t),0===o.size&&delete r.listeners[e]}},e.prototype.receiveMessage=function(e){var t=e.data.requestId,r=this.listeners[t];r&&r.forEach((function(t){return t(e.data)}))},e}();Object.defineProperty(exports,"ClientError",{enumerable:!0,get:function(){return t.ClientError}}),exports.ApiClient=pe,exports.ChangeColumnValueOpDocument=te,exports.ChangeMultipleColumnValuesOpDocument=oe,exports.ChangeSimpleColumnValueOpDocument=ee,exports.CreateItemOpDocument=re,exports.DEFAULT_VERSION=de,exports.GetBoardGroupsOpDocument=ie,exports.GetBoardItemsOpDocument=ne,exports.GetMeOpDocument=Z,exports.MONDAY_API_ENDPOINT=ue,exports.SeamlessApiClient=me,exports.SeamlessApiClientError=ce,exports.UserFieldsFragmentDoc=X,exports.getSdk=se;
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("graphql-tag"),t=require("graphql-request");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o=r(e),n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)};var i,a,s,u,d,l,p,c,m,_,v,I,h,g,x,b,O,f,y,E,C,A,D,N,T,P,B,S,L,R,w,$,k,V,G=function(){return G=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},G.apply(this,arguments)};function F(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{u(o.next(e))}catch(e){i(e)}}function s(e){try{u(o.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((o=o.apply(e,t||[])).next())}))}function M(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[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(r)throw new TypeError("Generator is already executing.");for(;i&&(i=0,s[0]&&(a=0)),a;)try{if(r=1,o&&(n=2&s[0]?o.return:s[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,s[1])).done)return n;switch(o=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,o=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){a=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){a.label=s[1];break}if(6===s[0]&&a.label<n[1]){a.label=n[1],n=s;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(s);break}n[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(e){s=[6,e],o=0}finally{r=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function U(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}"function"==typeof SuppressedError&&SuppressedError,exports.AssetsSource=void 0,(i=exports.AssetsSource||(exports.AssetsSource={})).All="all",i.Columns="columns",i.Gallery="gallery",exports.BoardAttributes=void 0,(a=exports.BoardAttributes||(exports.BoardAttributes={})).Communication="communication",a.Description="description",a.Name="name",exports.BoardEditPermissions=void 0,(s=exports.BoardEditPermissions||(exports.BoardEditPermissions={})).Assignee="assignee",s.Collaborators="collaborators",s.Everyone="everyone",s.Owners="owners",exports.BoardKind=void 0,(u=exports.BoardKind||(exports.BoardKind={})).Private="private",u.Public="public",u.Share="share",exports.BoardObjectType=void 0,(d=exports.BoardObjectType||(exports.BoardObjectType={})).Board="board",d.CustomObject="custom_object",d.Document="document",d.SubItemsBoard="sub_items_board",exports.BoardSubscriberKind=void 0,(l=exports.BoardSubscriberKind||(exports.BoardSubscriberKind={})).Owner="owner",l.Subscriber="subscriber",exports.BoardViewPermissions=void 0,(exports.BoardViewPermissions||(exports.BoardViewPermissions={})).AnyAssigneeColumn="any_assignee_column",exports.BoardsOrderBy=void 0,(p=exports.BoardsOrderBy||(exports.BoardsOrderBy={})).CreatedAt="created_at",p.UsedAt="used_at",exports.ColumnProperty=void 0,(c=exports.ColumnProperty||(exports.ColumnProperty={})).Description="description",c.Title="title",exports.ColumnType=void 0,(m=exports.ColumnType||(exports.ColumnType={})).AutoNumber="auto_number",m.BoardRelation="board_relation",m.Button="button",m.Checkbox="checkbox",m.ColorPicker="color_picker",m.Country="country",m.CreationLog="creation_log",m.Date="date",m.Dependency="dependency",m.Doc="doc",m.Dropdown="dropdown",m.Email="email",m.File="file",m.Formula="formula",m.Group="group",m.Hour="hour",m.Integration="integration",m.ItemAssignees="item_assignees",m.ItemId="item_id",m.LastUpdated="last_updated",m.Link="link",m.Location="location",m.LongText="long_text",m.Mirror="mirror",m.Name="name",m.Numbers="numbers",m.People="people",m.Person="person",m.Phone="phone",m.Progress="progress",m.Rating="rating",m.Status="status",m.Subtasks="subtasks",m.Tags="tags",m.Team="team",m.Text="text",m.TimeTracking="time_tracking",m.Timeline="timeline",m.Unsupported="unsupported",m.Vote="vote",m.Week="week",m.WorldClock="world_clock",exports.CustomActivityColor=void 0,(_=exports.CustomActivityColor||(exports.CustomActivityColor={})).BrinkPink="BRINK_PINK",_.CelticBlue="CELTIC_BLUE",_.CornflowerBlue="CORNFLOWER_BLUE",_.DingyDungeon="DINGY_DUNGEON",_.GoGreen="GO_GREEN",_.Gray="GRAY",_.LightDeepPink="LIGHT_DEEP_PINK",_.LightHotPink="LIGHT_HOT_PINK",_.MayaBlue="MAYA_BLUE",_.MediumTurquoise="MEDIUM_TURQUOISE",_.ParadisePink="PARADISE_PINK",_.PhilippineGreen="PHILIPPINE_GREEN",_.PhilippineYellow="PHILIPPINE_YELLOW",_.SlateBlue="SLATE_BLUE",_.VividCerulean="VIVID_CERULEAN",_.YankeesBlue="YANKEES_BLUE",_.YellowGreen="YELLOW_GREEN",_.YellowOrange="YELLOW_ORANGE",exports.CustomActivityIcon=void 0,(v=exports.CustomActivityIcon||(exports.CustomActivityIcon={})).Ascending="ASCENDING",v.Camera="CAMERA",v.Conference="CONFERENCE",v.Flag="FLAG",v.Gift="GIFT",v.Headphones="HEADPHONES",v.Homekeys="HOMEKEYS",v.Location="LOCATION",v.Notebook="NOTEBOOK",v.Paperplane="PAPERPLANE",v.Plane="PLANE",v.Pliers="PLIERS",v.Tripod="TRIPOD",v.Twoflags="TWOFLAGS",v.Utencils="UTENCILS",exports.DiscountPeriod=void 0,(I=exports.DiscountPeriod||(exports.DiscountPeriod={})).Monthly="MONTHLY",I.Yearly="YEARLY",exports.DocBlockContentType=void 0,(h=exports.DocBlockContentType||(exports.DocBlockContentType={})).BulletedList="bulleted_list",h.CheckList="check_list",h.Code="code",h.Divider="divider",h.Image="image",h.LargeTitle="large_title",h.Layout="layout",h.MediumTitle="medium_title",h.NormalText="normal_text",h.NoticeBox="notice_box",h.NumberedList="numbered_list",h.Quote="quote",h.SmallTitle="small_title",h.Table="table",h.Video="video",exports.DocsOrderBy=void 0,(g=exports.DocsOrderBy||(exports.DocsOrderBy={})).CreatedAt="created_at",g.UsedAt="used_at",exports.DuplicateBoardType=void 0,(x=exports.DuplicateBoardType||(exports.DuplicateBoardType={})).DuplicateBoardWithPulses="duplicate_board_with_pulses",x.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",x.DuplicateBoardWithStructure="duplicate_board_with_structure",exports.FileLinkValueKind=void 0,(b=exports.FileLinkValueKind||(exports.FileLinkValueKind={})).Box="box",b.Dropbox="dropbox",b.GoogleDrive="google_drive",b.Link="link",b.Onedrive="onedrive",exports.FirstDayOfTheWeek=void 0,(O=exports.FirstDayOfTheWeek||(exports.FirstDayOfTheWeek={})).Monday="monday",O.Sunday="sunday",exports.FolderColor=void 0,(f=exports.FolderColor||(exports.FolderColor={})).Aquamarine="AQUAMARINE",f.BrightBlue="BRIGHT_BLUE",f.BrightGreen="BRIGHT_GREEN",f.ChiliBlue="CHILI_BLUE",f.DarkOrange="DARK_ORANGE",f.DarkPurple="DARK_PURPLE",f.DarkRed="DARK_RED",f.DoneGreen="DONE_GREEN",f.Indigo="INDIGO",f.Lipstick="LIPSTICK",f.Null="NULL",f.Purple="PURPLE",f.SofiaPink="SOFIA_PINK",f.StuckRed="STUCK_RED",f.Sunset="SUNSET",f.WorkingOrange="WORKING_ORANGE",exports.FolderCustomIcon=void 0,(y=exports.FolderCustomIcon||(exports.FolderCustomIcon={})).Folder="FOLDER",y.Morebelow="MOREBELOW",y.Morebelowfilled="MOREBELOWFILLED",y.Null="NULL",y.Work="WORK",exports.FolderFontWeight=void 0,(E=exports.FolderFontWeight||(exports.FolderFontWeight={})).FontWeightBold="FONT_WEIGHT_BOLD",E.FontWeightLight="FONT_WEIGHT_LIGHT",E.FontWeightNormal="FONT_WEIGHT_NORMAL",E.FontWeightVeryLight="FONT_WEIGHT_VERY_LIGHT",E.Null="NULL",exports.GroupAttributes=void 0,(C=exports.GroupAttributes||(exports.GroupAttributes={})).Color="color",C.Position="position",C.RelativePositionAfter="relative_position_after",C.RelativePositionBefore="relative_position_before",C.Title="title",exports.ItemsOrderByDirection=void 0,(A=exports.ItemsOrderByDirection||(exports.ItemsOrderByDirection={})).Asc="asc",A.Desc="desc",exports.ItemsQueryOperator=void 0,(D=exports.ItemsQueryOperator||(exports.ItemsQueryOperator={})).And="and",D.Or="or",exports.ItemsQueryRuleOperator=void 0,(N=exports.ItemsQueryRuleOperator||(exports.ItemsQueryRuleOperator={})).AnyOf="any_of",N.Between="between",N.ContainsTerms="contains_terms",N.ContainsText="contains_text",N.EndsWith="ends_with",N.GreaterThan="greater_than",N.GreaterThanOrEquals="greater_than_or_equals",N.IsEmpty="is_empty",N.IsNotEmpty="is_not_empty",N.LowerThan="lower_than",N.LowerThanOrEqual="lower_than_or_equal",N.NotAnyOf="not_any_of",N.NotContainsText="not_contains_text",N.StartsWith="starts_with",N.WithinTheLast="within_the_last",N.WithinTheNext="within_the_next",exports.Kind=void 0,(T=exports.Kind||(exports.Kind={})).Person="person",T.Team="team",exports.NotificationTargetType=void 0,(P=exports.NotificationTargetType||(exports.NotificationTargetType={})).Post="Post",P.Project="Project",exports.NumberValueUnitDirection=void 0,(B=exports.NumberValueUnitDirection||(exports.NumberValueUnitDirection={})).Left="left",B.Right="right",exports.PositionRelative=void 0,(S=exports.PositionRelative||(exports.PositionRelative={})).AfterAt="after_at",S.BeforeAt="before_at",exports.State=void 0,(L=exports.State||(exports.State={})).Active="active",L.All="all",L.Archived="archived",L.Deleted="deleted",exports.UserKind=void 0,(R=exports.UserKind||(exports.UserKind={})).All="all",R.Guests="guests",R.NonGuests="non_guests",R.NonPending="non_pending",exports.VersionKind=void 0,(w=exports.VersionKind||(exports.VersionKind={})).Current="current",w.Deprecated="deprecated",w.Dev="dev",w.Maintenance="maintenance",w.OldMaintenance="old__maintenance",w.OldPreviousMaintenance="old_previous_maintenance",w.PreviousMaintenance="previous_maintenance",w.ReleaseCandidate="release_candidate",exports.WebhookEventType=void 0,($=exports.WebhookEventType||(exports.WebhookEventType={})).ChangeColumnValue="change_column_value",$.ChangeName="change_name",$.ChangeSpecificColumnValue="change_specific_column_value",$.ChangeStatusColumnValue="change_status_column_value",$.ChangeSubitemColumnValue="change_subitem_column_value",$.ChangeSubitemName="change_subitem_name",$.CreateColumn="create_column",$.CreateItem="create_item",$.CreateSubitem="create_subitem",$.CreateSubitemUpdate="create_subitem_update",$.CreateUpdate="create_update",$.DeleteUpdate="delete_update",$.EditUpdate="edit_update",$.ItemArchived="item_archived",$.ItemDeleted="item_deleted",$.ItemMovedToAnyGroup="item_moved_to_any_group",$.ItemMovedToSpecificGroup="item_moved_to_specific_group",$.ItemRestored="item_restored",$.MoveSubitem="move_subitem",$.SubitemArchived="subitem_archived",$.SubitemDeleted="subitem_deleted",exports.WorkspaceKind=void 0,(k=exports.WorkspaceKind||(exports.WorkspaceKind={})).Closed="closed",k.Open="open",exports.WorkspaceSubscriberKind=void 0,(V=exports.WorkspaceSubscriberKind||(exports.WorkspaceSubscriberKind={})).Owner="owner",V.Subscriber="subscriber",exports.WorkspacesOrderBy=void 0,(exports.WorkspacesOrderBy||(exports.WorkspacesOrderBy={})).CreatedAt="created_at";var W,q,K,H,Y,j,Q,J,z,X=o.default(W||(W=U(["\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"]))),Z=o.default(q||(q=U(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),X),ee=o.default(K||(K=U(["\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"]))),te=o.default(H||(H=U(["\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"]))),re=o.default(Y||(Y=U(["\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"]))),oe=o.default(j||(j=U(["\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"]))),ne=o.default(Q||(Q=U(["\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"]))),ie=o.default(J||(J=U(["\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"]))),ae=function(e,t,r,o){return e()};function se(e,t){return void 0===t&&(t=ae),{getMeOp:function(r,o){return t((function(t){return e.request(Z,r,G(G({},o),t))}),"getMeOp","query",r)},changeSimpleColumnValueOp:function(r,o){return t((function(t){return e.request(ee,r,G(G({},o),t))}),"changeSimpleColumnValueOp","mutation",r)},changeColumnValueOp:function(r,o){return t((function(t){return e.request(te,r,G(G({},o),t))}),"changeColumnValueOp","mutation",r)},createItemOp:function(r,o){return t((function(t){return e.request(re,r,G(G({},o),t))}),"createItemOp","mutation",r)},changeMultipleColumnValuesOp:function(r,o){return t((function(t){return e.request(oe,r,G(G({},o),t))}),"changeMultipleColumnValuesOp","mutation",r)},getBoardItemsOp:function(r,o){return t((function(t){return e.request(ne,r,G(G({},o),t))}),"getBoardItemsOp","query",r)},getBoardGroupsOp:function(r,o){return t((function(t){return e.request(ie,r,G(G({},o),t))}),"getBoardGroupsOp","query",r)}}}exports.AvailableVersions=void 0,(z=exports.AvailableVersions||(exports.AvailableVersions={})).DEPRECATED="deprecated",z.MAINTENANCE="maintenance",z.CURRENT="current",z.RELEASE_CANDIDATE="release_candidate",z.DEV="dev",z.CURRENT_VERSION="2024-10";var ue="https://api.monday.com/v2",de=exports.AvailableVersions.CURRENT_VERSION,le="7.0.1",pe=function(){function e(e){var r=this;this.request=function(e,t){return F(r,void 0,void 0,(function(){return M(this,(function(r){switch(r.label){case 0:return[4,this.client.request(e,t)];case 1:return[2,r.sent()]}}))}))},this.rawRequest=function(e,t){return F(r,void 0,void 0,(function(){return M(this,(function(r){switch(r.label){case 0:return[4,this.client.rawRequest(e,t)];case 1:return[2,r.sent()]}}))}))};var o=e.token,n=e.apiVersion,i=void 0===n?de:n,a=e.requestConfig,s=void 0===a?{}:a;if(!this.isValidApiVersion(i))throw new Error("Invalid API version format. Expected format is 'yyyy-mm' with month as one of '01', '04', '07', or '10'.");this.apiVersion=i;var u=function(){if(process.env.MONDAY_API_ENDPOINT)return process.env.MONDAY_API_ENDPOINT;var e=process.env.PLATFORM_API;if(e)try{var t=JSON.parse(e);if(t.PLATFORM_API_ENDPOINT)return t.PLATFORM_API_ENDPOINT}catch(e){console.error("Failed to parse PLATFORM_API secret",e)}return ue}();this.client=new t.GraphQLClient(u,G(G({},s),{headers:{"Content-Type":"application/json",Authorization:o,"API-Version":this.apiVersion,"Api-Sdk-Version":le}})),this.operations=se(this.client)}return e.prototype.isValidApiVersion=function(e){return/^\d{4}-(01|04|07|10)$/.test(e)},e}(),ce=function(e){function t(t,r){var o=e.call(this,t)||this;return o.response={errors:r},o.name=o.constructor.name,o.type="SeamlessApiClientError",o}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(t,e),t}(Error),me=function(){function e(e){void 0===e&&(e=de),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e,window.addEventListener("message",this.receiveMessage.bind(this),!1)}return e.prototype.request=function(e,t,r,o){var n=this;return void 0===o&&(o=6e4),new Promise((function(i,a){var s=n.generateRequestId(),u={query:e,variables:t},d=r||n.apiVersion;window.parent.postMessage({method:"api",args:{params:u,apiVersion:d},requestId:s},"*");var l=setTimeout((function(){a(new Error("Request timed out"))}),o),p=n.addListener(s,(function(e){if(clearTimeout(l),p(),e.errorMessage){var t=new ce(e.errorMessage,e.data.errors);a(t)}else i(e)}))}))},e.prototype.addListener=function(e,t){var r=this,o=this.listeners[e]||new Set;return o.add(t),this.listeners[e]=o,function(){o.delete(t),0===o.size&&delete r.listeners[e]}},e.prototype.receiveMessage=function(e){var t=e.data.requestId,r=this.listeners[t];r&&r.forEach((function(t){return t(e.data)}))},e}();Object.defineProperty(exports,"ClientError",{enumerable:!0,get:function(){return t.ClientError}}),exports.ApiClient=pe,exports.ChangeColumnValueOpDocument=te,exports.ChangeMultipleColumnValuesOpDocument=oe,exports.ChangeSimpleColumnValueOpDocument=ee,exports.CreateItemOpDocument=re,exports.DEFAULT_VERSION=de,exports.GetBoardGroupsOpDocument=ie,exports.GetBoardItemsOpDocument=ne,exports.GetMeOpDocument=Z,exports.MONDAY_API_ENDPOINT=ue,exports.SeamlessApiClient=me,exports.SeamlessApiClientError=ce,exports.UserFieldsFragmentDoc=X,exports.getSdk=se;
//# sourceMappingURL=index.js.map

@@ -1,2 +0,2 @@

import e from"graphql-tag";import{GraphQLClient as n}from"graphql-request";export{ClientError}from"graphql-request";var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)Object.prototype.hasOwnProperty.call(n,t)&&(e[t]=n[t])},t(e,n)};var r,i,o,a,u,s,l,c,d,m,p,_,f,h,I,g,v,b,E,O,N,y,A,P,C,L,T,D,S,R,$,w,G,B,M,V,k=function(){return k=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var i in n=arguments[t])Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i]);return e},k.apply(this,arguments)};function q(e,n,t,r){return new(t||(t=Promise))((function(i,o){function a(e){try{s(r.next(e))}catch(e){o(e)}}function u(e){try{s(r.throw(e))}catch(e){o(e)}}function s(e){var n;e.done?i(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(a,u)}s((r=r.apply(e,n||[])).next())}))}function U(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[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,r&&(i=2&u[0]?r.return:u[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,u[1])).done)return i;switch(r=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,r=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==u[0]&&2!==u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=n.call(e,a)}catch(e){u=[6,e],r=0}finally{t=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,s])}}}function x(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"}(r||(r={})),function(e){e.Communication="communication",e.Description="description",e.Name="name"}(i||(i={})),function(e){e.Assignee="assignee",e.Collaborators="collaborators",e.Everyone="everyone",e.Owners="owners"}(o||(o={})),function(e){e.Private="private",e.Public="public",e.Share="share"}(a||(a={})),function(e){e.Board="board",e.CustomObject="custom_object",e.Document="document",e.SubItemsBoard="sub_items_board"}(u||(u={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(s||(s={})),function(e){e.AnyAssigneeColumn="any_assignee_column"}(l||(l={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(c||(c={})),function(e){e.Description="description",e.Title="title"}(d||(d={})),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"}(m||(m={})),function(e){e.BrinkPink="BRINK_PINK",e.CelticBlue="CELTIC_BLUE",e.CornflowerBlue="CORNFLOWER_BLUE",e.DingyDungeon="DINGY_DUNGEON",e.GoGreen="GO_GREEN",e.Gray="GRAY",e.LightDeepPink="LIGHT_DEEP_PINK",e.LightHotPink="LIGHT_HOT_PINK",e.MayaBlue="MAYA_BLUE",e.MediumTurquoise="MEDIUM_TURQUOISE",e.ParadisePink="PARADISE_PINK",e.PhilippineGreen="PHILIPPINE_GREEN",e.PhilippineYellow="PHILIPPINE_YELLOW",e.SlateBlue="SLATE_BLUE",e.VividCerulean="VIVID_CERULEAN",e.YankeesBlue="YANKEES_BLUE",e.YellowGreen="YELLOW_GREEN",e.YellowOrange="YELLOW_ORANGE"}(p||(p={})),function(e){e.Ascending="ASCENDING",e.Camera="CAMERA",e.Conference="CONFERENCE",e.Flag="FLAG",e.Gift="GIFT",e.Headphones="HEADPHONES",e.Homekeys="HOMEKEYS",e.Location="LOCATION",e.Notebook="NOTEBOOK",e.Paperplane="PAPERPLANE",e.Plane="PLANE",e.Pliers="PLIERS",e.Tripod="TRIPOD",e.Twoflags="TWOFLAGS",e.Utencils="UTENCILS"}(_||(_={})),function(e){e.Monthly="MONTHLY",e.Yearly="YEARLY"}(f||(f={})),function(e){e.BulletedList="bulleted_list",e.CheckList="check_list",e.Code="code",e.Divider="divider",e.Image="image",e.LargeTitle="large_title",e.Layout="layout",e.MediumTitle="medium_title",e.NormalText="normal_text",e.NoticeBox="notice_box",e.NumberedList="numbered_list",e.Quote="quote",e.SmallTitle="small_title",e.Table="table",e.Video="video"}(h||(h={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(I||(I={})),function(e){e.DuplicateBoardWithPulses="duplicate_board_with_pulses",e.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",e.DuplicateBoardWithStructure="duplicate_board_with_structure"}(g||(g={})),function(e){e.Box="box",e.Dropbox="dropbox",e.GoogleDrive="google_drive",e.Link="link",e.Onedrive="onedrive"}(v||(v={})),function(e){e.Monday="monday",e.Sunday="sunday"}(b||(b={})),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"}(E||(E={})),function(e){e.Folder="FOLDER",e.Morebelow="MOREBELOW",e.Morebelowfilled="MOREBELOWFILLED",e.Null="NULL",e.Work="WORK"}(O||(O={})),function(e){e.FontWeightBold="FONT_WEIGHT_BOLD",e.FontWeightLight="FONT_WEIGHT_LIGHT",e.FontWeightNormal="FONT_WEIGHT_NORMAL",e.FontWeightVeryLight="FONT_WEIGHT_VERY_LIGHT",e.Null="NULL"}(N||(N={})),function(e){e.Color="color",e.Position="position",e.RelativePositionAfter="relative_position_after",e.RelativePositionBefore="relative_position_before",e.Title="title"}(y||(y={})),function(e){e.Asc="asc",e.Desc="desc"}(A||(A={})),function(e){e.And="and",e.Or="or"}(P||(P={})),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"}(C||(C={})),function(e){e.Person="person",e.Team="team"}(L||(L={})),function(e){e.Post="Post",e.Project="Project"}(T||(T={})),function(e){e.Left="left",e.Right="right"}(D||(D={})),function(e){e.AfterAt="after_at",e.BeforeAt="before_at"}(S||(S={})),function(e){e.Active="active",e.All="all",e.Archived="archived",e.Deleted="deleted"}(R||(R={})),function(e){e.All="all",e.Guests="guests",e.NonGuests="non_guests",e.NonPending="non_pending"}($||($={})),function(e){e.Current="current",e.Deprecated="deprecated",e.Dev="dev",e.Maintenance="maintenance",e.OldMaintenance="old__maintenance",e.OldPreviousMaintenance="old_previous_maintenance",e.PreviousMaintenance="previous_maintenance",e.ReleaseCandidate="release_candidate"}(w||(w={})),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"}(G||(G={})),function(e){e.Closed="closed",e.Open="open"}(B||(B={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(M||(M={})),function(e){e.CreatedAt="created_at"}(V||(V={}));var F,W,H,Y,K,j,J,Q,z,X=e(F||(F=x(["\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"]))),Z=e(W||(W=x(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),X),ee=e(H||(H=x(["\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"]))),ne=e(Y||(Y=x(["\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"]))),te=e(K||(K=x(["\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"]))),re=e(j||(j=x(["\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"]))),ie=e(J||(J=x(["\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"]))),oe=e(Q||(Q=x(["\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"]))),ae=function(e,n,t,r){return e()};function ue(e,n){return void 0===n&&(n=ae),{getMeOp:function(t,r){return n((function(n){return e.request(Z,t,k(k({},r),n))}),"getMeOp","query",t)},changeSimpleColumnValueOp:function(t,r){return n((function(n){return e.request(ee,t,k(k({},r),n))}),"changeSimpleColumnValueOp","mutation",t)},changeColumnValueOp:function(t,r){return n((function(n){return e.request(ne,t,k(k({},r),n))}),"changeColumnValueOp","mutation",t)},createItemOp:function(t,r){return n((function(n){return e.request(te,t,k(k({},r),n))}),"createItemOp","mutation",t)},changeMultipleColumnValuesOp:function(t,r){return n((function(n){return e.request(re,t,k(k({},r),n))}),"changeMultipleColumnValuesOp","mutation",t)},getBoardItemsOp:function(t,r){return n((function(n){return e.request(ie,t,k(k({},r),n))}),"getBoardItemsOp","query",t)},getBoardGroupsOp:function(t,r){return n((function(n){return e.request(oe,t,k(k({},r),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-10"}(z||(z={}));var se="https://api.monday.com/v2",le=z.CURRENT_VERSION,ce="7.0.1-beta.8",de=function(){function e(e){var t=this;this.request=function(e,n){return q(t,void 0,void 0,(function(){return U(this,(function(t){switch(t.label){case 0:return[4,this.client.request(e,n)];case 1:return[2,t.sent()]}}))}))},this.rawRequest=function(e,n){return q(t,void 0,void 0,(function(){return U(this,(function(t){switch(t.label){case 0:return[4,this.client.rawRequest(e,n)];case 1:return[2,t.sent()]}}))}))};var r=e.token,i=e.apiVersion,o=void 0===i?le:i,a=e.requestConfig,u=void 0===a?{}:a;if(!this.isValidApiVersion(o))throw new Error("Invalid API version format. Expected format is 'yyyy-mm' with month as one of '01', '04', '07', or '10'.");this.apiVersion=o;var s=function(){if(process.env.MONDAY_API_ENDPOINT)return process.env.MONDAY_API_ENDPOINT;var e=process.env.PLATFORM_API;if(e)try{var n=JSON.parse(e);if(n.PLATFORM_API_ENDPOINT)return n.PLATFORM_API_ENDPOINT}catch(e){console.error("Failed to parse PLATFORM_API secret",e)}return se}();this.client=new n(s,k(k({},u),{headers:{"Content-Type":"application/json",Authorization:r,"API-Version":this.apiVersion,"Api-Sdk-Version":ce}})),this.operations=ue(this.client)}return e.prototype.isValidApiVersion=function(e){return/^\d{4}-(01|04|07|10)$/.test(e)},e}(),me=function(e){function n(n,t){var r=e.call(this,n)||this;return r.response={errors:t},r.name=r.constructor.name,r.type="SeamlessApiClientError",r}return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,e),n}(Error),pe=function(){function e(e){void 0===e&&(e=le),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e,window.addEventListener("message",this.receiveMessage.bind(this),!1)}return e.prototype.request=function(e,n,t,r){var i=this;return void 0===r&&(r=6e4),new Promise((function(o,a){var u=i.generateRequestId(),s={query:e,variables:n},l=t||i.apiVersion;window.parent.postMessage({method:"api",args:{params:s,apiVersion:l},requestId:u},"*");var c=setTimeout((function(){a(new Error("Request timed out"))}),r),d=i.addListener(u,(function(e){if(clearTimeout(c),d(),e.errorMessage){var n=new me(e.errorMessage,e.data.errors);a(n)}else o(e)}))}))},e.prototype.addListener=function(e,n){var t=this,r=this.listeners[e]||new Set;return r.add(n),this.listeners[e]=r,function(){r.delete(n),0===r.size&&delete t.listeners[e]}},e.prototype.receiveMessage=function(e){var n=e.data.requestId,t=this.listeners[n];t&&t.forEach((function(n){return n(e.data)}))},e}();export{de as ApiClient,r as AssetsSource,z as AvailableVersions,i as BoardAttributes,o as BoardEditPermissions,a as BoardKind,u as BoardObjectType,s as BoardSubscriberKind,l as BoardViewPermissions,c as BoardsOrderBy,ne as ChangeColumnValueOpDocument,re as ChangeMultipleColumnValuesOpDocument,ee as ChangeSimpleColumnValueOpDocument,d as ColumnProperty,m as ColumnType,te as CreateItemOpDocument,p as CustomActivityColor,_ as CustomActivityIcon,le as DEFAULT_VERSION,f as DiscountPeriod,h as DocBlockContentType,I as DocsOrderBy,g as DuplicateBoardType,v as FileLinkValueKind,b as FirstDayOfTheWeek,E as FolderColor,O as FolderCustomIcon,N as FolderFontWeight,oe as GetBoardGroupsOpDocument,ie as GetBoardItemsOpDocument,Z as GetMeOpDocument,y as GroupAttributes,A as ItemsOrderByDirection,P as ItemsQueryOperator,C as ItemsQueryRuleOperator,L as Kind,se as MONDAY_API_ENDPOINT,T as NotificationTargetType,D as NumberValueUnitDirection,S as PositionRelative,pe as SeamlessApiClient,me as SeamlessApiClientError,R as State,X as UserFieldsFragmentDoc,$ as UserKind,w as VersionKind,G as WebhookEventType,B as WorkspaceKind,M as WorkspaceSubscriberKind,V as WorkspacesOrderBy,ue as getSdk};
import e from"graphql-tag";import{GraphQLClient as n}from"graphql-request";export{ClientError}from"graphql-request";var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)Object.prototype.hasOwnProperty.call(n,t)&&(e[t]=n[t])},t(e,n)};var r,i,o,a,u,s,l,c,d,m,p,_,f,h,I,g,v,b,E,O,N,y,A,P,C,L,T,D,S,R,$,w,G,B,M,V,k=function(){return k=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var i in n=arguments[t])Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i]);return e},k.apply(this,arguments)};function q(e,n,t,r){return new(t||(t=Promise))((function(i,o){function a(e){try{s(r.next(e))}catch(e){o(e)}}function u(e){try{s(r.throw(e))}catch(e){o(e)}}function s(e){var n;e.done?i(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(a,u)}s((r=r.apply(e,n||[])).next())}))}function U(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[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,r&&(i=2&u[0]?r.return:u[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,u[1])).done)return i;switch(r=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,r=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==u[0]&&2!==u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=n.call(e,a)}catch(e){u=[6,e],r=0}finally{t=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,s])}}}function x(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"}(r||(r={})),function(e){e.Communication="communication",e.Description="description",e.Name="name"}(i||(i={})),function(e){e.Assignee="assignee",e.Collaborators="collaborators",e.Everyone="everyone",e.Owners="owners"}(o||(o={})),function(e){e.Private="private",e.Public="public",e.Share="share"}(a||(a={})),function(e){e.Board="board",e.CustomObject="custom_object",e.Document="document",e.SubItemsBoard="sub_items_board"}(u||(u={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(s||(s={})),function(e){e.AnyAssigneeColumn="any_assignee_column"}(l||(l={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(c||(c={})),function(e){e.Description="description",e.Title="title"}(d||(d={})),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"}(m||(m={})),function(e){e.BrinkPink="BRINK_PINK",e.CelticBlue="CELTIC_BLUE",e.CornflowerBlue="CORNFLOWER_BLUE",e.DingyDungeon="DINGY_DUNGEON",e.GoGreen="GO_GREEN",e.Gray="GRAY",e.LightDeepPink="LIGHT_DEEP_PINK",e.LightHotPink="LIGHT_HOT_PINK",e.MayaBlue="MAYA_BLUE",e.MediumTurquoise="MEDIUM_TURQUOISE",e.ParadisePink="PARADISE_PINK",e.PhilippineGreen="PHILIPPINE_GREEN",e.PhilippineYellow="PHILIPPINE_YELLOW",e.SlateBlue="SLATE_BLUE",e.VividCerulean="VIVID_CERULEAN",e.YankeesBlue="YANKEES_BLUE",e.YellowGreen="YELLOW_GREEN",e.YellowOrange="YELLOW_ORANGE"}(p||(p={})),function(e){e.Ascending="ASCENDING",e.Camera="CAMERA",e.Conference="CONFERENCE",e.Flag="FLAG",e.Gift="GIFT",e.Headphones="HEADPHONES",e.Homekeys="HOMEKEYS",e.Location="LOCATION",e.Notebook="NOTEBOOK",e.Paperplane="PAPERPLANE",e.Plane="PLANE",e.Pliers="PLIERS",e.Tripod="TRIPOD",e.Twoflags="TWOFLAGS",e.Utencils="UTENCILS"}(_||(_={})),function(e){e.Monthly="MONTHLY",e.Yearly="YEARLY"}(f||(f={})),function(e){e.BulletedList="bulleted_list",e.CheckList="check_list",e.Code="code",e.Divider="divider",e.Image="image",e.LargeTitle="large_title",e.Layout="layout",e.MediumTitle="medium_title",e.NormalText="normal_text",e.NoticeBox="notice_box",e.NumberedList="numbered_list",e.Quote="quote",e.SmallTitle="small_title",e.Table="table",e.Video="video"}(h||(h={})),function(e){e.CreatedAt="created_at",e.UsedAt="used_at"}(I||(I={})),function(e){e.DuplicateBoardWithPulses="duplicate_board_with_pulses",e.DuplicateBoardWithPulsesAndUpdates="duplicate_board_with_pulses_and_updates",e.DuplicateBoardWithStructure="duplicate_board_with_structure"}(g||(g={})),function(e){e.Box="box",e.Dropbox="dropbox",e.GoogleDrive="google_drive",e.Link="link",e.Onedrive="onedrive"}(v||(v={})),function(e){e.Monday="monday",e.Sunday="sunday"}(b||(b={})),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"}(E||(E={})),function(e){e.Folder="FOLDER",e.Morebelow="MOREBELOW",e.Morebelowfilled="MOREBELOWFILLED",e.Null="NULL",e.Work="WORK"}(O||(O={})),function(e){e.FontWeightBold="FONT_WEIGHT_BOLD",e.FontWeightLight="FONT_WEIGHT_LIGHT",e.FontWeightNormal="FONT_WEIGHT_NORMAL",e.FontWeightVeryLight="FONT_WEIGHT_VERY_LIGHT",e.Null="NULL"}(N||(N={})),function(e){e.Color="color",e.Position="position",e.RelativePositionAfter="relative_position_after",e.RelativePositionBefore="relative_position_before",e.Title="title"}(y||(y={})),function(e){e.Asc="asc",e.Desc="desc"}(A||(A={})),function(e){e.And="and",e.Or="or"}(P||(P={})),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"}(C||(C={})),function(e){e.Person="person",e.Team="team"}(L||(L={})),function(e){e.Post="Post",e.Project="Project"}(T||(T={})),function(e){e.Left="left",e.Right="right"}(D||(D={})),function(e){e.AfterAt="after_at",e.BeforeAt="before_at"}(S||(S={})),function(e){e.Active="active",e.All="all",e.Archived="archived",e.Deleted="deleted"}(R||(R={})),function(e){e.All="all",e.Guests="guests",e.NonGuests="non_guests",e.NonPending="non_pending"}($||($={})),function(e){e.Current="current",e.Deprecated="deprecated",e.Dev="dev",e.Maintenance="maintenance",e.OldMaintenance="old__maintenance",e.OldPreviousMaintenance="old_previous_maintenance",e.PreviousMaintenance="previous_maintenance",e.ReleaseCandidate="release_candidate"}(w||(w={})),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"}(G||(G={})),function(e){e.Closed="closed",e.Open="open"}(B||(B={})),function(e){e.Owner="owner",e.Subscriber="subscriber"}(M||(M={})),function(e){e.CreatedAt="created_at"}(V||(V={}));var F,W,H,Y,K,j,J,Q,z,X=e(F||(F=x(["\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"]))),Z=e(W||(W=x(["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"],["\n query getMeOp {\n me {\n ...UserFields\n }\n }\n ","\n"])),X),ee=e(H||(H=x(["\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"]))),ne=e(Y||(Y=x(["\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"]))),te=e(K||(K=x(["\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"]))),re=e(j||(j=x(["\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"]))),ie=e(J||(J=x(["\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"]))),oe=e(Q||(Q=x(["\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"]))),ae=function(e,n,t,r){return e()};function ue(e,n){return void 0===n&&(n=ae),{getMeOp:function(t,r){return n((function(n){return e.request(Z,t,k(k({},r),n))}),"getMeOp","query",t)},changeSimpleColumnValueOp:function(t,r){return n((function(n){return e.request(ee,t,k(k({},r),n))}),"changeSimpleColumnValueOp","mutation",t)},changeColumnValueOp:function(t,r){return n((function(n){return e.request(ne,t,k(k({},r),n))}),"changeColumnValueOp","mutation",t)},createItemOp:function(t,r){return n((function(n){return e.request(te,t,k(k({},r),n))}),"createItemOp","mutation",t)},changeMultipleColumnValuesOp:function(t,r){return n((function(n){return e.request(re,t,k(k({},r),n))}),"changeMultipleColumnValuesOp","mutation",t)},getBoardItemsOp:function(t,r){return n((function(n){return e.request(ie,t,k(k({},r),n))}),"getBoardItemsOp","query",t)},getBoardGroupsOp:function(t,r){return n((function(n){return e.request(oe,t,k(k({},r),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-10"}(z||(z={}));var se="https://api.monday.com/v2",le=z.CURRENT_VERSION,ce="7.0.1",de=function(){function e(e){var t=this;this.request=function(e,n){return q(t,void 0,void 0,(function(){return U(this,(function(t){switch(t.label){case 0:return[4,this.client.request(e,n)];case 1:return[2,t.sent()]}}))}))},this.rawRequest=function(e,n){return q(t,void 0,void 0,(function(){return U(this,(function(t){switch(t.label){case 0:return[4,this.client.rawRequest(e,n)];case 1:return[2,t.sent()]}}))}))};var r=e.token,i=e.apiVersion,o=void 0===i?le:i,a=e.requestConfig,u=void 0===a?{}:a;if(!this.isValidApiVersion(o))throw new Error("Invalid API version format. Expected format is 'yyyy-mm' with month as one of '01', '04', '07', or '10'.");this.apiVersion=o;var s=function(){if(process.env.MONDAY_API_ENDPOINT)return process.env.MONDAY_API_ENDPOINT;var e=process.env.PLATFORM_API;if(e)try{var n=JSON.parse(e);if(n.PLATFORM_API_ENDPOINT)return n.PLATFORM_API_ENDPOINT}catch(e){console.error("Failed to parse PLATFORM_API secret",e)}return se}();this.client=new n(s,k(k({},u),{headers:{"Content-Type":"application/json",Authorization:r,"API-Version":this.apiVersion,"Api-Sdk-Version":ce}})),this.operations=ue(this.client)}return e.prototype.isValidApiVersion=function(e){return/^\d{4}-(01|04|07|10)$/.test(e)},e}(),me=function(e){function n(n,t){var r=e.call(this,n)||this;return r.response={errors:t},r.name=r.constructor.name,r.type="SeamlessApiClientError",r}return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,e),n}(Error),pe=function(){function e(e){void 0===e&&(e=le),this.listeners={},this.generateRequestId=function(){return Math.random().toString(36).substring(2,9)},this.apiVersion=e,window.addEventListener("message",this.receiveMessage.bind(this),!1)}return e.prototype.request=function(e,n,t,r){var i=this;return void 0===r&&(r=6e4),new Promise((function(o,a){var u=i.generateRequestId(),s={query:e,variables:n},l=t||i.apiVersion;window.parent.postMessage({method:"api",args:{params:s,apiVersion:l},requestId:u},"*");var c=setTimeout((function(){a(new Error("Request timed out"))}),r),d=i.addListener(u,(function(e){if(clearTimeout(c),d(),e.errorMessage){var n=new me(e.errorMessage,e.data.errors);a(n)}else o(e)}))}))},e.prototype.addListener=function(e,n){var t=this,r=this.listeners[e]||new Set;return r.add(n),this.listeners[e]=r,function(){r.delete(n),0===r.size&&delete t.listeners[e]}},e.prototype.receiveMessage=function(e){var n=e.data.requestId,t=this.listeners[n];t&&t.forEach((function(n){return n(e.data)}))},e}();export{de as ApiClient,r as AssetsSource,z as AvailableVersions,i as BoardAttributes,o as BoardEditPermissions,a as BoardKind,u as BoardObjectType,s as BoardSubscriberKind,l as BoardViewPermissions,c as BoardsOrderBy,ne as ChangeColumnValueOpDocument,re as ChangeMultipleColumnValuesOpDocument,ee as ChangeSimpleColumnValueOpDocument,d as ColumnProperty,m as ColumnType,te as CreateItemOpDocument,p as CustomActivityColor,_ as CustomActivityIcon,le as DEFAULT_VERSION,f as DiscountPeriod,h as DocBlockContentType,I as DocsOrderBy,g as DuplicateBoardType,v as FileLinkValueKind,b as FirstDayOfTheWeek,E as FolderColor,O as FolderCustomIcon,N as FolderFontWeight,oe as GetBoardGroupsOpDocument,ie as GetBoardItemsOpDocument,Z as GetMeOpDocument,y as GroupAttributes,A as ItemsOrderByDirection,P as ItemsQueryOperator,C as ItemsQueryRuleOperator,L as Kind,se as MONDAY_API_ENDPOINT,T as NotificationTargetType,D as NumberValueUnitDirection,S as PositionRelative,pe as SeamlessApiClient,me as SeamlessApiClientError,R as State,X as UserFieldsFragmentDoc,$ as UserKind,w as VersionKind,G as WebhookEventType,B as WorkspaceKind,M as WorkspaceSubscriberKind,V as WorkspacesOrderBy,ue as getSdk};
//# sourceMappingURL=index.js.map
{
"name": "@mondaydotcomorg/api",
"version": "7.0.1-beta.8",
"version": "7.0.1",
"description": "monday.com API client",

@@ -5,0 +5,0 @@ "main": "dist/cjs/index.js",

@@ -174,8 +174,11 @@ # Monday GraphQL JS SDK

Board,
} from "@mondaycom/api";
} from "@mondaydotcomorg/api";
const { boards } = await SeamlessApiClient.request<{boards: [Board];}>(`query { boards(ids: some_id) { id name } }`);
// Option A - using pre defined types
const seamlessApiClient = new SeamlessApiClient();
const { boards } = await client.request<{boards: [Board];}>(`query { boards(ids: some_id) { id name } }`);
// or using your own types after integrating with @mondaycom/setup-api
// Option B - using your own types after integrating with @mondaydotcomorg/setup-api
import { GetBoardsQueryVariables, GetBoardsQuery } from "./generated/graphql";
const seamlessApiClient = new SeamlessApiClient();
const variables: GetBoardsQueryVariables = { ids: ["some_id"] };

@@ -192,3 +195,9 @@

const data = await SeamlessApiClient.request<GetBoardsQuery>(getBoards, variables);
try {
const data = await seamlessApiClient.request<GetBoardsQuery>(getBoards, variables);
} catch (error) {
// If the error is from SeamlessApiClient, it will be of type SeamlessApiClientError, which you can import from our package. Also, error.type will also 'SeamlessApiClientError'.
console.log(error.response.errors)
}
```

@@ -195,0 +204,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc