My app is an integration that connects to an external view that displays particular items that are selected via a status column in the board. The status column has to have specifically named labels. Is there a way to package a column template with my app or otherwise publish a column template? The worst case scenario is the user having to set up the column manually because any mistake will mean the app doesn’t work.
Hello there @Janssen,
You could use a workspace template for this. You would add a workspace template feature to the same app that has the integration feature. You could even have the integration already set in the board of your workspace template if you want.
I hope that helps!
Okay thanks… I should have looked into this before asking but I assumed it wasn’t quite what I wanted. Which it isn’t, but I think it’s a bit better for my users than asking them to create column from scratch according to exacting specifications. At least this way there’s a model they can look at to see what the column should be.
The problem with this is that my app is meant to work with an existing board and people who find utility in my app will already have a lot of items and columns. Asking them to repopulate a board (or worse a workspace) just so they can use my little app is total non-starter. If I may suggest a feature it would be a way for developers to provide custom columns with an app. This would go very well with your existing set of built-in triggers because I was able to come up with a pretty decent UX combining the status column trigger with my own status column labels and logic on my server, and I’m sure many more such possibilities exist.
Since you already have a feature enabling saving column templates for Entrepreneur accounts, maybe this feature wouldn’t be too hard for your team to come up with! That existing feature might actually be useful to me but I can’t check because my developer account doesn’t seem to let me save column templates so maybe you can answer for me: If a user has an Entrepreneur account could they save a column from my workspace template and then use it in their existing boards?
It occurred to me that I may be able to do this with the api, and sure enough!
Looks like I can programmatically build a column just the way I need it. This much better than using a workspace template though it still would be nice to have the option of including a column template with my app.
I’m going to try setting up an app installation page, which I haven’t done yet because I yet needed to, and there the user will provide a board ID. My server will create the column on monday and all that’s left for the user to do is add the integration to the new column. I’ll write back next week and report how it went, but I think this should work.
I meant to post this in the above post: https://community.monday.com/t/released-creating-new-labels-with-the-api/19091/4
I was able to accomplish what I needed to do and for posterity I’ll give an overview of how to do it.
First set up an authorization URL, say to mysite/install.
After a board admin installs your app using the via the “share your app” found in your developer console or the marketplace a user will add your integration feature to a board. This will take them mysite/install with token as a URL query.
Next your site mysite/install redirects to monday.com OAuth with token for the state param and also another page you contro as redirect_uril: mysite/redirect. The user authorizers the feature and monday.com fowards them back to mysite/redirect.
You now have code and state attached to your mysite/recirect url. Make a request to your server with both of those parameters.
On your server use jwt decode/verify to extract boardId and backToUrl from state using your app’s signing secret. Remember, state is first token you got from the initial monday.com feature install event.
Next continue the monday.com OAuth process to exchange code for an access_token using the proper fields. access_token is the API key you need in order to build your column, assuming your scopes are set correctly. Build your column using https://community.monday.com/t/changing-or-deleting-status-column-labels/56275. It’s not elegant, but my process was to first make a new status column; next create a new item assigning a new label to the new status column; then as many change_multiple_column_values using the new item and new column as necessary to make all remaining labels I need. Unfortunately there’s no way to delete labels so your stuck with the default ones, but you can of course delete the item you created to make the labels with.
The column has been built and all that’s left is for the server to return backToUrl (which you got from state) back to your page mysite/recirect. Your page simply redirects to backToUrl and now the user will be back on monday.com at the recipe interaction. What’s very nice is the user can select the new column in the recipe! The only thing they have to worry about is removing the default labels but aside from that is now installed to a new column built exactly to your specifications. Sweet!