This web app shows how to manage stickes using CRUD (create, read, update, delete) methods on a Miro board.
nodeStickiesDemo.mov
- Included Features
- Tools and Technologies
- Prerequisites
- Associated Developer Tutorial
- Run the app locally
- Folder Structure
- Contributing
- License
- You have a Miro account.
- You're signed in to Miro.
- Your Miro account has a Developer team.
- Your development environment includes Node.js 14.13 or a later version.
- All examples use
npm
as a package manager andnpx
as a package runner.
- Rename the
.sample.env
file to.env
and then add in your environmental variables. Once completed your.env
file should look something like this:
MIRO_CLIENT_ID=<YOUR_CLIENT_ID>
MIRO_CLIENT_SECRET=<YOUR_CLIENT_SECRET>
MIRO_REDIRECT_URL=http://localhost:8000/authorized
MIRO_BOARD_ID=<YOUR_MIRO_BOARD_ID>
MIRO_BOARD_ID can be found here.
- Run
npm install
to install dependencies. - Run
npm start
to start developing.
Your URL should be similar to this example:http://localhost:8000
- Open the app manifest editor by clicking Edit in Manifest. \
In the app manifest editor, configure the app as follows and click save:
# See https://developers.miro.com/docs/app-manifest on how to use this
appName: Node Stickes CSV
sdkVersion: SDK_V2
sdkUri: http://localhost:8000
redirectUris: http://localhost:8000/authorized/
scopes:
- boards:read
- boards:write
- Go back to your app home page, and under the
Permissions
section, you will see a blue button that saysInstall app and get OAuth token
. Click that button. Then click onAdd
as shown in the video below. In the video we install a different app, but the process is the same regardless of the app.
⚠️ We recommend to install your app on a developer team while you are developing or testing apps.⚠️
install-app.mov
- Go to the developer team which you installed the app on, and open the board with the board ID matching your board from the .env file:
MIRO_BOARD_ID=<YOUR_MIRO_BOARD_ID>
.
search-for-app.mov
-
Next, go to
localhost:8000
, and click onAuthorize App
. -
Go through the authorization process, then click on
List Stickies
or any of the other buttons at the top to interact with the app.
.
├── package.json <-- The dependencies for the main app.js
└── app.js <-- The main Node.js script to run the Express server and render our Handlebars app
└── .env <-- File where you are storing your sensitive credentials
└── node_modules <-- Node modules that are installed based on dependencies
└── authorization
└── auth.js
└── package.json <-- The dependencies for auth.js
└── views
└── authorizeApp.hbs <-- Handlebars file to render authorization success page
└── createCard.hbs <-- Handlebars file to render sticky creation page
└── deleteCard.hbs <-- Handlebars file to render sticky deletion page
└── updateCard.hbs <-- Handlebars file to render sticky update page
└── uploadCSV.hbs <-- Handlebars file to render CSV upload page
└── viewCard.hbs <-- Handlebars file to render sticky list page
└── home.hbs <-- main Handlebars file to render universal/root rendering
└── layouts
└── main.hbs <-- the Handlebars 'app' itself
node-stickies-csv-demo-data.csv <-- sample CSV data to create stickies
If you want to contribute to this example, or any other Miro Open Source project, please review Miro's contributing guide.