Docs: Import / Export formats Google-Tasks to Microsoft-Teams: what each feature is, how to use it, how its numbers are calculated, how it works, and its commits.

Each format page now has the one structure: What it is, Read more (with
the Wikipedia page of the tool or format), How to use it (the import and
export steps and the REST API as its subsections), How the numbers are
calculated (the format's own limits and the limits every import has),
How it works in WeKan (the import method, the export routes, the format's
own code and tests, then the format details) and Commits. The import path
is All Boards / Add Board / Import / Import board, as the code draws it;
dead links are replaced or unlinked.

Thanks to xet7 !
This commit is contained in:
Lauri Ojansivu committed 2026-11-22 18:16:51 +02:00
1 parent 80b45a4c58
commit bea184b2ea
20 files changed
+2498 -862

No files matched your search

@@ -1,12 +1,32 @@
# Google Tasks
## What it is
WeKan imports [Google Tasks](https://tasks.google.com/) straight from Google's
[Tasks API](https://developers.google.com/workspace/tasks), with an access
token. Each task list becomes a list and each task a card, with its notes,
links, due date and subtasks; completed tasks are imported archived. Google
Tasks has no export file, so there is nothing to paste.
## How to import
## Read more
- [Wikipedia: Google Tasks](https://en.wikipedia.org/wiki/Google_Tasks)
- [Google Tasks API](https://developers.google.com/workspace/tasks): overview
- [REST reference](https://developers.google.com/workspace/tasks/reference/rest):
the `TaskList` and `Task` resources, `tasklists.list` and `tasks.list`
- [OAuth 2.0 Playground](https://developers.google.com/oauthplayground/):
where to get an access token
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
First get an access token. The token is used for that one fetch only and is
not stored.
@@ -21,7 +41,7 @@ not stored.
Then import:
1. In WeKan, go to **All Boards → New → Import → Google Tasks**.
1. In WeKan, go to **All Boards → Add Board → Import → Import board → Google Tasks**.
2. Paste the access token and click **List**.
3. Choose **Google Tasks (all lists)** or one task list, then click **Fetch**.
4. Continue as with any import: map the members, then click **Import**.
@@ -31,22 +51,104 @@ Then import:
The token only reads: the scope `tasks.readonly` cannot change anything in
Google Tasks.
## How to import many boards at once
### How to import many boards at once
Choose **Google Tasks (all lists)**: every task list comes on one WeKan board,
one list each. Google Tasks has no swimlanes, so every card is in the swimlane
**Default**. To get one board per task list, import each list on its own.
## How to export
### How to export
WeKan does not export to Google Tasks. Google Tasks has no import file, and
WeKan does not write to Google.
## How to export all boards at once
### How to export all boards at once
There is no Google Tasks export, so there is none for all boards either.
## Format details
### REST API
```bash
python3 api.py importboardfrom googletasks tasks.json # POST /api/boards/import/googletasks
```
The HTTP route is `POST /api/boards/import/googletasks` with the fetched JSON
(`{ "googletasks": true, "lists": [...] }`) as `board`. Fetch it yourself
with the API calls above, or with the client.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 100 lists. (`MAX_LISTS` in
[models/lib/apiImport/googletasks.js](../../../../../../models/lib/apiImport/googletasks.js#L8))
- At most 200 pages. More stops the import with an error. (`MAX_PAGES` in
[models/lib/apiImport/googletasks.js](../../../../../../models/lib/apiImport/googletasks.js#L9))
- At most 20,000 tasks. (`MAX_TASKS` in
[models/lib/apiImport/googletasks.js](../../../../../../models/lib/apiImport/googletasks.js#L10))
- At most 20,000 tasks. More stops the import with an error. (`MAX_GOOGLE_TASKS`
in
[models/lib/googletasksApiFormat.js](../../../../../../models/lib/googletasksApiFormat.js#L6))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
- **Reading from the service's API**: each request may take 30 seconds and
answer at most 32 MB, with no redirects followed
([server/lib/apiImportRequest.js](../../../../../../server/lib/apiImportRequest.js));
each text field read is cut to 4,096 characters
([models/lib/apiImportServices.js](../../../../../../models/lib/apiImportServices.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
This format's own code:
[models/lib/apiImport/googletasks.js](../../../../../../models/lib/apiImport/googletasks.js),
[models/lib/googletasksApiFormat.js](../../../../../../models/lib/googletasksApiFormat.js),
[releases/live-tests/googletasks-import.mjs](../../../../../../releases/live-tests/googletasks-import.mjs).
The tests that pin it:
[tests/googletasksApiImport.test.cjs](../../../../../../tests/googletasksApiImport.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
The client (`models/lib/apiImport/googletasks.js`) sends
`Authorization: Bearer <token>` and reads:
@@ -79,7 +181,7 @@ The parser (`models/lib/googletasksApiFormat.js`):
- a completed task is archived, with `completed` as its end date;
- `links` are added to the description as `description: link` lines.
## What is kept
### What is kept
| Google Tasks | WeKan |
| --- | --- |
@@ -94,7 +196,7 @@ The parser (`models/lib/googletasksApiFormat.js`):
| `position` | Card and checklist item order |
| Hidden (cleared) completed tasks | Archived cards |
## What is not kept
### What is not kept
The import reports these on the loss report:
@@ -110,17 +212,7 @@ Not imported and not reported: `updated`, `webViewLink`, `etag` and the
time of `due`, which Google does not keep. Google Tasks has no members,
labels, comments or attachments.
## REST API
```bash
python3 api.py importboardfrom googletasks tasks.json # POST /api/boards/import/googletasks
```
The HTTP route is `POST /api/boards/import/googletasks` with the fetched JSON
(`{ "googletasks": true, "lists": [...] }`) as `board`. Fetch it yourself
with the API calls above, or with the client.
## How it is built and tested
### How it is built and tested
- `models/lib/apiImportServices.js` lists the service and its one field,
`token`. `models/lib/apiImport/googletasks.js` lists and fetches,
@@ -137,13 +229,7 @@ with the API calls above, or with the client.
reads. Run it from **build.sh → Tests → Live tests**, or with
`node releases/live-tests/googletasks-import.mjs`.
## Sources
## Commits
- [Google Tasks API](https://developers.google.com/workspace/tasks): overview
- [REST reference](https://developers.google.com/workspace/tasks/reference/rest):
the `TaskList` and `Task` resources, `tasklists.list` and `tasks.list`
- [OAuth 2.0 Playground](https://developers.google.com/oauthplayground/):
where to get an access token
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Imported subtasks keep their due date and person: a checklist item has both](https://github.com/wekan/wekan/commit/cf6f67e789ac404866d4b51591820570850baaa3)
- [Import: Planka, Microsoft To Do, KanbanFlow, Basecamp, Google Tasks and Google Keep from their APIs](https://github.com/wekan/wekan/commit/46e30f01e48f2676a47c0052007f5c4ea951a923)
@@ -1,23 +1,41 @@
# HTML
## What it is
WeKan exports a board as an HTML archive: a `.zip` with a web page of the
board as it is shown on the screen, the files the page needs to open without
the WeKan server, and the board's WeKan JSON export. The page can be opened
in any web browser, offline, to read the board. HTML is export only.
## How to import
## Read more
- [Wikipedia: HTML, the markup language](https://en.wikipedia.org/wiki/HTML)
- [HTML Living Standard](https://html.spec.whatwg.org/): the page format
- [File System Access API, `showSaveFilePicker`](https://developer.mozilla.org/en-US/docs/Web/API/Window/showSaveFilePicker):
how the browser asks where to save the archive
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
There is no HTML import. The web page is a picture of the board made of the
screen's HTML, not a data format, so WeKan does not read it back. The archive
also holds the board's WeKan JSON export, under `data/`; that file can be
imported with **All Boards → New → Import → WeKan** (see
imported with **All Boards → Add Board → Import → Import board → WeKan** (see
[WeKan JSON](../WeKan/From-Previous-Export.md)).
## How to import many boards at once
### How to import many boards at once
There is nothing to import: HTML has no import.
## How to export
### How to export
1. In WeKan, open the board, and show it the way you want it in the page:
the view, filters and collapsed lists are taken as they are on the
@@ -30,14 +48,37 @@ There is nothing to import: HTML has no import.
the `.zip`; otherwise it downloads.
4. Unzip the archive and open `index.html` in a web browser.
## How to export all boards at once
### How to export all boards at once
This is not available for HTML. The archive is a document of one board, made
from the board on the screen, so **Export all boards** does not offer it.
Export each board from its own menu, or use **Export all boards** with WeKan
JSON instead.
## Format details
### REST API
There is no REST route for the HTML archive: it is built in the browser from
the board on the screen. The JSON inside it is the board's WeKan JSON export,
`GET /api/boards/BOARDID/export?authToken=TOKEN`.
## How the numbers are calculated
This format has no numbers of its own: it has no limits, counts or defaults
beyond those of the export it belongs to.
## How it works in WeKan
This format's own code:
[client/lib/exportHTML.js](../../../../../../client/lib/exportHTML.js).
The tests that pin it:
[tests/clientLazyLoading.test.cjs](../../../../../../tests/clientLazyLoading.test.cjs),
[tests/exportBoardPopupOrder.test.cjs](../../../../../../tests/exportBoardPopupOrder.test.cjs),
[tests/exportHTMLXss.test.cjs](../../../../../../tests/exportHTMLXss.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
From the [format coverage](../Format-Coverage.md) audit, for PDF, HTML and SVG:
@@ -72,7 +113,7 @@ The step that adds `data/BOARDID.json` fetches the board's JSON export
off a JSON link in the export popup that the shared export popup no longer
has, which stopped the export at that step; it builds the URL itself now.
## What is kept
### What is kept
| WeKan | HTML archive |
| --- | --- |
@@ -81,7 +122,7 @@ has, which stopped the export at that step; it builds the URL itself now.
| The board's styles and icons | `style/`, `webfonts/` |
| The whole board as data | `data/BOARDID.json` (WeKan JSON) |
## What is not kept
### What is not kept
- Anything not on the screen when the export starts: a filtered-out card, a
view that is not open, and the opened-card details beyond what the minicard
@@ -90,13 +131,7 @@ has, which stopped the export at that step; it builds the URL itself now.
- Web fonts other than Font Awesome.
- The page cannot be imported back; use the JSON file in `data/` for that.
## REST API
There is no REST route for the HTML archive: it is built in the browser from
the board on the screen. The JSON inside it is the board's WeKan JSON export,
`GET /api/boards/BOARDID/export?authToken=TOKEN`.
## How it is built and tested
### How it is built and tested
- `client/lib/exportHTML.js` builds the archive; it is loaded only when
**HTML** is clicked (`client/components/sidebar/sidebar.js`,
@@ -108,11 +143,30 @@ the board on the screen. The JSON inside it is the board's WeKan JSON export,
click), `tests/exportBoardPopupOrder.test.cjs` (the menu entry).
- There is no Playwright case for the HTML archive.
## Sources
## Commits
- [HTML Living Standard](https://html.spec.whatwg.org/): the page format
- [File System Access API, `showSaveFilePicker`](https://developer.mozilla.org/en-US/docs/Web/API/Window/showSaveFilePicker):
how the browser asks where to save the archive
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Website: import and export WordPress, Ghost, Blogger, static and HTML sites, and the board as a website at a public ](https://github.com/wekan/wekan/commit/2e8549032ea4b44e90a96eb53a4e1941f53a5261)
- [Asana: html_notes, approval states and comment likes come across](https://github.com/wekan/wekan/commit/57a657445ef63cc979530f04585227d778c01845)
- [Fix GitHub code scanning code-quality findings](https://github.com/wekan/wekan/commit/582a22c2914e5eaaeea84f29a3c75970195bf5e5)
- [Text exports such as OPML are made from checked values, not stripped as HTML](https://github.com/wekan/wekan/commit/62eb9c5c297b71265c849726022194f9b68dfa69)
- [Stream a Trello .zip import from a temporary file, its attachments into storage](https://github.com/wekan/wekan/commit/cd75f8c47630cf5ed714f8f223d23e1cf87c06de)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Fix board JSON exports containing HTML card text](https://github.com/wekan/wekan/commit/49eaade957243ec6f83c3d138c044efda5de8747)
- [Revert Legacy HTML4 browser interface and parity changes](https://github.com/wekan/wekan/commit/828fc2d7186f485ce3df056849442f9cdcf5828d)
- [Add shared HTML4 import source picker](https://github.com/wekan/wekan/commit/ca008534fae653d57617bd1513609401ec93fbd5)
- [Share the server ZIP reader with Trello imports](https://github.com/wekan/wekan/commit/cda021ba21b5db9ceda0ce6472adec6d83dde361)
- [Lazy-load browser export code](https://github.com/wekan/wekan/commit/d1b262d29af1185475427ba294ed4f5d9b304272)
- [Security tests: say which vulnerability you guard, and check the list](https://github.com/wekan/wekan/commit/a4a9c03b1fc75d61760a35c87decbaf7a3081973)
- [Board bar: a long board title moves ALL the buttons to the second row](https://github.com/wekan/wekan/commit/9df568c0c2ed5137444c318308be90dfdad76e7e)
- [Fix ExportBleed: stored XSS in HTML board exports via a card-title second parse](https://github.com/wekan/wekan/commit/2d32e34621d340b00be4f66a6a2106ab4575cc70)
- [Export board to HTML .zip: stream to disk and include every card](https://github.com/wekan/wekan/commit/ae9be62ef31014f5f452d32808c55b96d4e97f54)
- [Fix Impersonate User. Show/Edit Avatar at Admin Panel/People/People](https://github.com/wekan/wekan/commit/ce3e51b14755b9c0a7c655d7a96c4f01386b4efc)
- [Fix client runtime regressions after Meteor 3 migration](https://github.com/wekan/wekan/commit/ddd873c7a07d530b03fdb1cde9a335ef9d1f006c)
- [Feat: download webfonts as well](https://github.com/wekan/wekan/commit/4d6e6a85e083b44774ca5e400763b6c9713bcd14)
- [Fix: export HTML currently exports JS popups](https://github.com/wekan/wekan/commit/fe887b7b5e8105df5c806f51fcf5ce089911db68)
- [Card Details Popup, every "Sub-Popup" must use .back() instead of .close()](https://github.com/wekan/wekan/commit/a59dfa8fc0d1280c35375c33f6d10a736acbf4b8)
- [Fix(scrollbar): remove custom scrollbar](https://github.com/wekan/wekan/commit/d887e553ce79830aa4830d2e1b4669a9e1d3f100)
- [Exports now work at #3173 at least for small boards. TODO: Fix EdgeHTML to work, before I can release this](https://github.com/wekan/wekan/commit/1624fc82f7c319e84a78f29445c7867f7da15c32)
- [Added an API to get the cards for a specific custom field value](https://github.com/wekan/wekan/commit/c9a28db3ab5650178c933fc3d2284958dd0fd84d)
- [Prettifier fixes](https://github.com/wekan/wekan/commit/05349a5deb3f85bb2ecc40457ff12413e0a830d1)
- [Export Board to Zip file](https://github.com/wekan/wekan/commit/5ef83ab236c633528ffe992b3b73aa86fe86090f)
@@ -1,5 +1,7 @@
# Jira
## What it is
WeKan imports boards from [Jira](https://www.atlassian.com/software/jira) and
exports a board in the same shape. It reads the JSON of Jira's REST API issue
search, `{ "issues": [...] }`: statuses become lists and issues become cards.
@@ -7,399 +9,15 @@ Comments, sub-tasks, custom fields, time tracking, estimates, issue types,
status categories, sprints, fix versions, rank, epics and issue links are
mapped as described below.
## How to import
1. In Jira, save the issues of the project from the REST API issue search.
On Jira Cloud this is
[`GET /rest/api/3/search/jql`](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/).
Ask for every field and for the field names and schema, for example
`?jql=project=KEY&fields=*all&expand=names,schema`: without `fields` the
search returns only issue ids, and the schema is what lets WeKan find the
Sprint, Rank, Epic Link and story points fields.
2. The search is paged with `nextPageToken`. Put every page's `issues` into
one `issues` array: WeKan imports what is in the file, and reports when the
file says more pages exist.
3. In WeKan, go to **All Boards → New → Import → Jira**.
4. Paste the JSON into the text box. Tick the parts to import. Optionally
enter the Scrum estimate field and its unit (see
[Explicit Scrum estimate mapping](#explicit-scrum-estimate-mapping)).
5. Click **Import**. WeKan then asks you to map the Jira assignees to WeKan
users. Map them and click **Done**, or click **Import without mapping
members (map later)**.
6. Read the loss report on the import page. It is also kept in **Admin Panel →
Problems → Recovery**.
The import page's instruction text names the current search,
`GET /rest/api/3/search/jql` with `fields=*all&expand=names,schema`; without
`fields` it returns only issue ids. A large project comes in pages, each with a
`nextPageToken` for the next: join the pages' `issues` into one array, or
import each page as its own board with **Import many boards**. The older
`/rest/api/2/search` answer, `{ "issues": [...] }` with `startAt` and `total`,
is read too. The file may also carry an `automationRules` array, which is
imported as rules (see Format details).
### Large exports
A Jira issue carries some 250 values even without comments, most of them null
custom fields, so a search export is large: 858 issues are about 5 MB. An
import of that size used to fail ([#6792](https://github.com/wekan/wekan/issues/6792)):
the import boundary refused documents over 250,000 values, and the import was
stopped after two minutes whatever its size. The boundary now allows four
million values, and the deadline is `WEKAN_IMPORT_TIMEOUT_MS` (default two
minutes) plus half a second per issue. A file over the boundary is refused
with "The file is too large to import at once" - split it into smaller
searches, for example by project or by date, and import each one.
## How to import many boards at once
- On the import page, under **Import many boards**, choose several Jira JSON
files, or one `.zip` that holds them. Each file becomes its own board,
imported without member mapping. Members can be mapped later. Click **Import**
to import them.
- The checkbox **One board per project** is not offered for Jira: Jira is
imported by its own importer, and a Jira file is always one board, in one
swimlane. To get one board per Jira project, search each project into its
own file and import the files together.
- From a script:
`python3 api.py importboardsfrom jira FILE_OR_DIR ...` takes files,
directories of files, or `.zip` files.
## How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include:**, tick the parts to export. **Dates**
controls spent time, **Custom Fields** the estimates, and **Scrum
settings** the issue types, status categories and fix versions.
3. Under **JSON**, choose **Jira**. The board downloads as a `.json` file in
the issue search shape.
4. Jira does not import this file. Jira Cloud's External System Import reads
CSV and a JSON layout of its own, not search results
([Import and export your data](https://support.atlassian.com/jira-cloud-administration/docs/import-and-export-your-data-to-and-from-jira-cloud/)).
The file is what WeKan's own Jira import reads, so a board round-trips
through it.
## How to export all boards at once
1. **All Boards → sidebar → Export all boards**, then choose **Jira**.
This downloads one `.zip` with one Jira file per board you can
export: boards you are a member of, that are not archived and are not
templates. A board you may not export is left out and named in
`skipped.txt` in the `.zip`.
2. To export only some boards, use **Multi-Selection** in the All Boards
sidebar, select the boards, then **Export**.
From a script: `python3 api.py exportallboards jira boards.zip`.
## Format details
From the [format coverage](../Format-Coverage.md) audit:
- **Current authoritative shape:**
[REST API v3 issue search](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/)
and per-project/type schemas.
- **Required import coverage:** ADF or string descriptions, status, type,
priority, reporter/assignee, labels, components, versions, sprint/epic/parent
links, subtasks, dates, estimates, comments, attachments and
schema-described custom fields.
- Jira is one of the external adapters that map the listed fields that have a
WeKan equivalent: comments (posted by the mapped user, otherwise by the
importer with the source author's name leading the text), sub-tasks as child
cards when they are imported too and as a checklist otherwise, parent
hierarchy and dependencies between issues of the same import, custom-field
values as typed board custom fields, source order, and the attachment
files, downloaded with the sign-in the import page asks for (below).
What the current code does (`models/jiraCreator.js`,
`models/lib/jiraIssueExtras.js`):
- The board is named after `board.name`, else the first issue's project.
- A card's title is `[KEY] summary`. Atlassian Document Format descriptions
and comments become plain text, keeping paragraph breaks.
- Labels, the priority (`priority:<name>`), components and fix versions
(`version:<name>`) become black board labels.
- Sub-tasks that are not in the file become a checklist **Sub-tasks**; a
sub-task whose status category is `done` is a finished item. A sub-task or
child issue that is in the file keeps its parent.
- `customfield_NNNNN` values become custom fields, named from the search
response's `names` map when it is there.
- The reporter is kept as **Requested by**, as text, so it survives an import
from a Jira nobody on the board has an account on.
- Issues are kept in search order, which is the JQL's `ORDER BY`.
- `automationRules`: rules that already use, or closely resemble, WeKan's
`{ title, trigger, action }` shape are imported. Jira's native automation
export is proprietary; rules that cannot be mapped are skipped.
### Native JSON time-tracking import
The native Jira JSON import reuses WeKan's spent-time field (hours) and
numeric custom fields for original and remaining estimates (hours). It creates
only fields supplied by the export, hides them from minicards by
default, and allows selecting the original estimate through existing Scrum
estimate settings.
It accepts numeric second values from `fields.timetracking`, or the equivalent
flat issue fields when the nested value is absent. Explicit zeroes are preserved.
Validation runs before creating the board. Localized duration strings are not
parsed, partial worklog pages are not summed, and no historical sessions are
fabricated. Native WeKan export retains these values. Jira sprint mapping and
synchronization remain separate implementation work.
The numeric fields follow [Atlassian's issue API](https://developer.atlassian.com/cloud/jira/software/rest/api-group-issue/).
The two numeric custom fields are named `Jira original estimate (hours)` and
`Jira remaining estimate (hours)`. Native WeKan custom-field settings control
their visibility; no new permission or external service is introduced.
On the import page, Dates selects spent time and Custom Fields selects
original/remaining estimates. Both nested and flat source values are removed
when their section is excluded, so fallback values cannot restore them.
Jira JSON export converts these hours back to integer seconds. Dates selection
controls spent time; Custom Fields controls original/remaining estimates.
Imported estimate fields carry `settings.jiraTimeField` markers, so renaming
one does not break export. Export does not infer meaning from matching names.
Older fields without markers, duplicate mappings and invalid values are omitted.
Native WeKan export/import and whole-board duplication retain the markers,
remap custom-field IDs and preserve Scrum's selected estimate field. Browser
regression coverage exports the resulting boards back to Jira and verifies
the original numeric seconds. This preserves time totals, not
individual worklog entries or all Jira Scrum data.
### Explicit Scrum estimate mapping
On the Jira import page, optionally enter the numeric estimate field ID
(for example `customfield_10016`) and its unit (for example `points`). Both
Scrum and Custom Fields must be selected. The importer uses this exact field,
never a guessed field name or a fixed installation-specific field number.
It creates one hidden numeric custom field and selects it as the board's Scrum
estimate source. Scrum remains disabled and its optional fields remain hidden.
The JSON equivalent is `wekanScrumMapping: { estimateFieldId:
"customfield_10016", estimateUnit: "points" }` at the document root.
Missing/null estimates stay unknown and explicit zero is preserved. Non-numeric,
negative or excessive values fail before board creation. The selected field must
occur in the issues or have a numeric entry in the root `schema`; an included
schema entry must declare it numeric. Jira export retains the original field ID
and mapping. Native export and board duplication retain the custom-field markers
and remap the local estimate field. Duplicate export mappings are omitted.
This mapping does not reconstruct historical sprint estimates or enable Sync.
When the export includes its field schema (search with `expand=names,schema`),
the field box offers the numeric fields it declares, story points first. If
exactly one field has Jira Software's story points type
(`com.pyxis.greenhopper.jira:jsw-story-points`) and no field is entered, that
field is used, in points - it is identified by its type, not by its name. With
two such fields, or none, nothing is chosen for you.
### Scrum issue types and workflow categories
The Jira importer maps `fields.issuetype.name` to the existing hidden Scrum
issue-type field. It maps stable `status.statusCategory.key` values `new`,
`indeterminate` and `done` to list categories `todo`, `doing` and `done`.
It never infers completion from translated status names. Board administrators
can select the existing done-list completion policy in Scrum settings; import
does not enable Scrum or change the default completion policy or visibility.
The Scrum import selection controls both mappings. Invalid issue-type values
and conflicting known categories for statuses merged into the same named list
are rejected before creating the board. Unknown category keys remain unmapped.
Jira export includes the same fields when Scrum is selected. A WeKan `backlog`
list category has no distinct Jira status category and is omitted.
Status names are treated as literal text, including names such as `constructor`
or `__proto__`. Dependency references resolve only to issue keys present in
the imported file; missing keys cannot resolve to JavaScript object properties.
These mappings follow the [Jira issue field representation](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/)
and [stable status category keys](https://docs.atlassian.com/DAC/javadoc/jira/reference/com/atlassian/jira/issue/status/category/StatusCategory.html).
Sprint snapshots, multiple fix versions, epic relationships and
automatic schema mapping remain separate implementation work. In particular,
an external sprint's current membership cannot reconstruct its original
commitment snapshot. Native WeKan export retains imported issue types and list
categories through the existing Scrum transfer format.
### Sprints, fix versions, rank and epics
Search with `expand=names,schema` so the export says which custom fields are
the Sprint, Rank and Epic Link fields. WeKan finds them by their schema type
(`gh-sprint`, `gh-lexo-rank`, `gh-epic-link`) or, without a schema, by those
names; it never guesses a `customfield_*` number. Then:
| Jira | WeKan |
| --- | --- |
| Future sprint | Planned sprint with its goal and dates; the card's sprint |
| Active sprint | Planned sprint, reported in Admin Panel → Problems → Recovery: issue search has no commitment snapshot, so start it in WeKan to begin measuring |
| Closed sprint | A closed sprint, with its start and close snapshots rebuilt from the issues and marked partial (below); one without a start and completion date is reported instead |
| Fix version | Release, released with its date or planned. Every fix version is one of the card's releases (a card can be in several since 2026-10-08). Versions still also become `version:` labels |
| Rank | Backlog order: backlog rank 1, 2, ... in Jira's rank order |
| Epic Link | The card's parent when the epic is imported too; otherwise reported. Newer Jira's `parent` was already followed |
Both of Jira's sprint forms are read: sprint objects, and the older
`com.atlassian.greenhopper.service.sprint.Sprint@...[id=...,state=...]`
strings. The board's Scrum settings are turned on when sprints or releases are
imported. These fields are not also imported as text custom fields.
Jira export writes each of a card's releases as one of its `fixVersions` when
Scrum is selected: the original Jira version id when the release came from
Jira (the WeKan release id otherwise), whether it is released, its planned end
as `releaseDate` and its notes as `description`. Importing that file gives the
card the same releases again.
### Duplicate issue links
Standard Jira `Duplicate` issue links now import as `duplicates` for
`outwardIssue` and `is-duplicated-by` for `inwardIssue`, following the
[Atlassian issue-link model](https://developer.atlassian.com/cloud/jira/platform/issue-linking-model/)
and [Data Center link types](https://developer.atlassian.com/server/jira/platform/rest/v11000/api-group-issuelink/).
Both endpoints must be included in the imported board. Self-links and missing
targets are skipped; the existing one-relation-per-target rule still applies.
The names `Duplicate` and `Duplicates` are recognized case-insensitively.
Custom/localized link names retain the existing generic relation fallback.
The relation is editable in card details and survives native WeKan board
export/import and History restoration. It does not merge duplicate cards or
change blocker analytics. The separate Jira JSON exporter currently omits
issue links; native WeKan export is the supported transfer path for these links.
Other issue links: a link type whose name contains `block` becomes blocks
(outward) or is-blocked-by (inward); any other type becomes related-to.
## What is kept
| Jira | WeKan |
| --- | --- |
| `board.name`, else the project name | Board title |
| `status.name` | List |
| `status.statusCategory.key` | List category (with Scrum) |
| `key`, `summary` | Card title `[KEY] summary` |
| `description` (ADF or text) | Description |
| `labels`, `priority`, `components`, `fixVersions` | Labels |
| `assignee` | Card member, when mapped |
| `reporter` | Requested by |
| `created`, `duedate`, `updated` | Creation date, due date, modified date |
| `timetracking` (or flat time fields) | Spent time; original and remaining estimate fields |
| Chosen estimate field | Hidden number field, the Scrum estimate |
| `issuetype.name` | Scrum issue type (with Scrum) |
| `parent`, Epic Link | Parent card |
| `subtasks` not in the file | Checklist **Sub-tasks** |
| `issuelinks` | Dependencies |
| `comment.comments` | Comments |
| `customfield_NNNNN` | Custom fields |
| Sprint, fix version, Rank | Scrum sprint, release, backlog rank |
| `automationRules` | Rules |
The export writes `board.name`, and per card an issue `WEKAN-1`, `WEKAN-2`...
with `summary`, `description`, `status` (the list, with its category when
Scrum is selected), `issuetype` and `fixVersions` (with Scrum), `labels`,
`duedate`, `timetracking`, `created`, the owner as `assignee`, Requested by
(else the creator) as `reporter`, `parent`, every checklist item as a
`subtasks` entry, the comments and the custom fields as `customfield_90001`, `customfield_90002`...
with a `names` map. With an estimate mapping it also writes
`wekanScrumMapping` and `schema`.
## Attachment files
The search carries each attachment's `content` address,
`/rest/api/3/attachment/content/<id>`, which Jira's REST API documents as the
attachment's contents. Under **Attachment files** on the import page, give the
Jira address (`https://your-site.atlassian.net`), the account's email and an
[API token](https://id.atlassian.com/manage-profile/security/api-tokens); the
import downloads each file with them. Jira answers with a redirect to its media
store, which is followed without the sign-in.
The address and the sign-in go with that one import: they are sent only to the
address typed there (an export file names any URL it likes, and one pointing
an attachment elsewhere gets no sign-in), never stored and never logged, and
the token field is emptied when Import is pressed. Every download goes through
the import's SSRF guard, which checks each redirect and drops the sign-in on a
redirect to another host, and lands in Admin Panel → Attachments → Default
Storage like any upload. A file that cannot be fetched is on the loss report
with the reason, and the import goes on. Leaving the fields empty imports the
board without its files. Unticking **Attachments** under what to include
leaves them out too. A service on a private address is refused by the same
guard. `models/lib/importAttachmentAuth.js` decides what is asked of whom.
Through the REST API (`POST /api/boards/import/<source>`), send the same as
`"attachmentAuth": { "url": ..., "username": ..., "token": ... }` beside
`"board"`.
## What is not kept
A closed sprint's report: Jira's sprint report has no documented API, so the
import rebuilds it from documented issue data. Committed at the start are the
issues whose Sprint field named the sprint at its start date; at the close,
those naming it at its completion, each done when its status was in Jira's
Done category then. Both come from each issue's change history - export with
`expand=changelog` (`GET /rest/api/3/search/jql?fields=*all&expand=changelog`)
for that; without it, the issues naming the sprint now, done when resolved by
the close. The list is the status then, or the status now when that one has no
list on the board, and the estimate is the estimate now. The snapshots are
marked partial, because a rebuilt one cannot see what changed between two
history entries.
The import reports these on the loss report:
- an attachment that could not be downloaded, and why (no sign-in given, a
refused address, an HTTP error);
- a parent or Epic Link to an issue that is not in the file;
- more result pages than the file holds (`nextPageToken`, or a `total`
larger than the issues in the file);
- active sprints (imported as planned), closed sprints rebuilt from the issues,
and closed sprints without dates (not imported);
- more than 50 custom fields.
Invalid estimate values, invalid issue types and conflicting status categories
stop the import before the board is created.
Assignees who are not mapped do not become card members. Only the first
assignee is read.
The export leaves out archived cards and lists, swimlanes, issue links,
attachments and checklists other than as sub-task entries. Several checklists
are flattened into one sub-task list.
## REST API
```bash
python3 api.py importboardfrom jira issues.json # POST /api/boards/import/jira
python3 api.py importboardsfrom jira a.json b.json dir/ # one board per file
python3 api.py exportboardformat BOARDID jira issues.json # GET /api/boards/BOARDID/export/jira?authToken=TOKEN
python3 api.py exportallboards jira boards.zip # GET /api/export-all-boards/jira?authToken=TOKEN
```
`GET /api/export-all-boards/jira?authToken=TOKEN&boardIds=ID1,ID2` exports
only the boards listed.
Jira is also a source for list Sync, which re-fetches issues into an existing
list; see [Sync](../Sync.md).
## How it is built and tested
- `models/jiraCreator.js` creates the board. `models/lib/jiraIssueExtras.js`,
`models/lib/jiraTimeTracking.js`, `models/lib/jiraEstimateMapping.js`,
`models/lib/jiraScrumMetadata.js` and `models/lib/jiraScrumPlanning.js`
read the parts of an issue. `client/components/import/jiraMembersMapper.js`
lists the assignees to map.
- `models/lib/externalExportFormatters.js` (`jira`) writes the export, from
what `models/lib/externalExporters.js` collects.
- Unit tests: `tests/jiraIssueExtras.test.cjs`,
`tests/jiraTimeTracking.test.cjs`, `tests/jiraEstimateMapping.test.cjs`,
`tests/jiraScrumMetadata.test.cjs`, `tests/jiraScrumPlanning.test.cjs`,
`tests/kanboardJiraCreator.import.test.cjs` and
`tests/externalExportRoundTrip.test.cjs`. The fixture is
`tests/fixtures/import-formats/jira.json`.
- Playwright: `tests/playwright/specs/import-export-format-audit.e2e.js`
(importing the fixture through the page, refusing malformed JSON),
`jira-time-import.e2e.js`, `jira-estimate-import.e2e.js`,
`jira-scrum-import.e2e.js`, `duplicate-dependencies.e2e.js` (Jira duplicate
links through native board transfer), and the `list-sync-*.e2e.js` cases
for Sync, all in `tests/playwright/specs/`.
## Sources
## Read more
- [Wikipedia: Jira, the issue tracker](https://en.wikipedia.org/wiki/Jira_(software))
- [Issue search](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/):
`GET /rest/api/3/search/jql`, its `fields`, `expand` and `nextPageToken`
- [Issues](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/)
and [Jira Software issue API](https://developer.atlassian.com/cloud/jira/software/rest/api-group-issue/):
the issue fields and estimates
- [StatusCategory](https://docs.atlassian.com/DAC/javadoc/jira/reference/com/atlassian/jira/issue/status/category/StatusCategory.html):
- [StatusCategory](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-workflow-status-categories/):
the stable status category keys
- [Issue-linking model](https://developer.atlassian.com/cloud/jira/platform/issue-linking-model/)
and [Data Center link types](https://developer.atlassian.com/server/jira/platform/rest/v11000/api-group-issuelink/):
@@ -407,8 +25,6 @@ list; see [Sync](../Sync.md).
- [Import and export your data](https://support.atlassian.com/jira-cloud-administration/docs/import-and-export-your-data-to-and-from-jira-cloud/):
what Jira Cloud imports
## More
### Migrate from Jira Server (Atlassian) to Wekan
Originally from @webenefits at https://github.com/wekan/wekan/discussions/3504
@@ -448,3 +64,484 @@ Alexander
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md), [Trello](../Trello/Trello.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Jira, save the issues of the project from the REST API issue search.
On Jira Cloud this is
[`GET /rest/api/3/search/jql`](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/).
Ask for every field and for the field names and schema, for example
`?jql=project=KEY&fields=*all&expand=names,schema`: without `fields` the
search returns only issue ids, and the schema is what lets WeKan find the
Sprint, Rank, Epic Link and story points fields.
2. The search is paged with `nextPageToken`. Put every page's `issues` into
one `issues` array: WeKan imports what is in the file, and reports when the
file says more pages exist.
3. In WeKan, go to **All Boards → Add Board → Import → Import board → Jira**.
4. Paste the JSON into the text box. Tick the parts to import. Optionally
enter the Scrum estimate field and its unit (see
[Explicit Scrum estimate mapping](#explicit-scrum-estimate-mapping)).
5. Click **Import**. WeKan then asks you to map the Jira assignees to WeKan
users. Map them and click **Done**, or click **Import without mapping
members (map later)**.
6. Read the loss report on the import page. It is also kept in **Admin Panel →
Problems → Recovery**.
The import page's instruction text names the current search,
`GET /rest/api/3/search/jql` with `fields=*all&expand=names,schema`; without
`fields` it returns only issue ids. A large project comes in pages, each with a
`nextPageToken` for the next: join the pages' `issues` into one array, or
import each page as its own board with **Import many boards**. The older
`/rest/api/2/search` answer, `{ "issues": [...] }` with `startAt` and `total`,
is read too. The file may also carry an `automationRules` array, which is
imported as rules (see Format details).
#### Large exports
A Jira issue carries some 250 values even without comments, most of them null
custom fields, so a search export is large: 858 issues are about 5 MB. An
import of that size used to fail ([#6792](https://github.com/wekan/wekan/issues/6792)):
the import boundary refused documents over 250,000 values, and the import was
stopped after two minutes whatever its size. The boundary now allows four
million values, and the deadline is `WEKAN_IMPORT_TIMEOUT_MS` (default two
minutes) plus half a second per issue. A file over the boundary is refused
with "The file is too large to import at once" - split it into smaller
searches, for example by project or by date, and import each one.
### How to import many boards at once
- On the import page, under **Import many boards**, choose several Jira JSON
files, or one `.zip` that holds them. Each file becomes its own board,
imported without member mapping. Members can be mapped later. Click **Import**
to import them.
- The checkbox **One board per project** is not offered for Jira: Jira is
imported by its own importer, and a Jira file is always one board, in one
swimlane. To get one board per Jira project, search each project into its
own file and import the files together.
- From a script:
`python3 api.py importboardsfrom jira FILE_OR_DIR ...` takes files,
directories of files, or `.zip` files.
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include:**, tick the parts to export. **Dates**
controls spent time, **Custom Fields** the estimates, and **Scrum
settings** the issue types, status categories and fix versions.
3. Under **JSON**, choose **Jira**. The board downloads as a `.json` file in
the issue search shape.
4. Jira does not import this file. Jira Cloud's External System Import reads
CSV and a JSON layout of its own, not search results
([Import and export your data](https://support.atlassian.com/jira-cloud-administration/docs/import-and-export-your-data-to-and-from-jira-cloud/)).
The file is what WeKan's own Jira import reads, so a board round-trips
through it.
### How to export all boards at once
1. **All Boards → sidebar → Export all boards**, then choose **Jira**.
This downloads one `.zip` with one Jira file per board you can
export: boards you are a member of, that are not archived and are not
templates. A board you may not export is left out and named in
`skipped.txt` in the `.zip`.
2. To export only some boards, use **Multi-Selection** in the All Boards
sidebar, select the boards, then **Export**.
From a script: `python3 api.py exportallboards jira boards.zip`.
### REST API
```bash
python3 api.py importboardfrom jira issues.json # POST /api/boards/import/jira
python3 api.py importboardsfrom jira a.json b.json dir/ # one board per file
python3 api.py exportboardformat BOARDID jira issues.json # GET /api/boards/BOARDID/export/jira?authToken=TOKEN
python3 api.py exportallboards jira boards.zip # GET /api/export-all-boards/jira?authToken=TOKEN
```
`GET /api/export-all-boards/jira?authToken=TOKEN&boardIds=ID1,ID2` exports
only the boards listed.
Jira is also a source for list Sync, which re-fetches issues into an existing
list; see [Sync](../Sync.md).
## How the numbers are calculated
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/jiraCreator.js](../../../../../../models/jiraCreator.js),
[models/lib/jiraEstimateMapping.js](../../../../../../models/lib/jiraEstimateMapping.js),
[models/lib/jiraIssueExtras.js](../../../../../../models/lib/jiraIssueExtras.js),
[models/lib/jiraScrumMetadata.js](../../../../../../models/lib/jiraScrumMetadata.js),
[models/lib/jiraScrumPlanning.js](../../../../../../models/lib/jiraScrumPlanning.js),
[models/lib/jiraTimeTracking.js](../../../../../../models/lib/jiraTimeTracking.js).
The tests that pin it:
[tests/externalExportRoundTrip.test.cjs](../../../../../../tests/externalExportRoundTrip.test.cjs),
[tests/jiraEstimateMapping.test.cjs](../../../../../../tests/jiraEstimateMapping.test.cjs),
[tests/jiraIssueExtras.test.cjs](../../../../../../tests/jiraIssueExtras.test.cjs),
[tests/jiraScrumMetadata.test.cjs](../../../../../../tests/jiraScrumMetadata.test.cjs),
[tests/jiraScrumPlanning.test.cjs](../../../../../../tests/jiraScrumPlanning.test.cjs),
[tests/jiraTimeTracking.test.cjs](../../../../../../tests/jiraTimeTracking.test.cjs),
[tests/kanboardJiraCreator.import.test.cjs](../../../../../../tests/kanboardJiraCreator.import.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
From the [format coverage](../Format-Coverage.md) audit:
- **Current authoritative shape:**
[REST API v3 issue search](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/)
and per-project/type schemas.
- **Required import coverage:** ADF or string descriptions, status, type,
priority, reporter/assignee, labels, components, versions, sprint/epic/parent
links, subtasks, dates, estimates, comments, attachments and
schema-described custom fields.
- Jira is one of the external adapters that map the listed fields that have a
WeKan equivalent: comments (posted by the mapped user, otherwise by the
importer with the source author's name leading the text), sub-tasks as child
cards when they are imported too and as a checklist otherwise, parent
hierarchy and dependencies between issues of the same import, custom-field
values as typed board custom fields, source order, and the attachment
files, downloaded with the sign-in the import page asks for (below).
What the current code does (`models/jiraCreator.js`,
`models/lib/jiraIssueExtras.js`):
- The board is named after `board.name`, else the first issue's project.
- A card's title is `[KEY] summary`. Atlassian Document Format descriptions
and comments become plain text, keeping paragraph breaks.
- Labels, the priority (`priority:<name>`), components and fix versions
(`version:<name>`) become black board labels.
- Sub-tasks that are not in the file become a checklist **Sub-tasks**; a
sub-task whose status category is `done` is a finished item. A sub-task or
child issue that is in the file keeps its parent.
- `customfield_NNNNN` values become custom fields, named from the search
response's `names` map when it is there.
- The reporter is kept as **Requested by**, as text, so it survives an import
from a Jira nobody on the board has an account on.
- Issues are kept in search order, which is the JQL's `ORDER BY`.
- `automationRules`: rules that already use, or closely resemble, WeKan's
`{ title, trigger, action }` shape are imported. Jira's native automation
export is proprietary; rules that cannot be mapped are skipped.
#### Native JSON time-tracking import
The native Jira JSON import reuses WeKan's spent-time field (hours) and
numeric custom fields for original and remaining estimates (hours). It creates
only fields supplied by the export, hides them from minicards by
default, and allows selecting the original estimate through existing Scrum
estimate settings.
It accepts numeric second values from `fields.timetracking`, or the equivalent
flat issue fields when the nested value is absent. Explicit zeroes are preserved.
Validation runs before creating the board. Localized duration strings are not
parsed, partial worklog pages are not summed, and no historical sessions are
fabricated. Native WeKan export retains these values. Jira sprint mapping and
synchronization remain separate implementation work.
The numeric fields follow [Atlassian's issue API](https://developer.atlassian.com/cloud/jira/software/rest/api-group-issue/).
The two numeric custom fields are named `Jira original estimate (hours)` and
`Jira remaining estimate (hours)`. Native WeKan custom-field settings control
their visibility; no new permission or external service is introduced.
On the import page, Dates selects spent time and Custom Fields selects
original/remaining estimates. Both nested and flat source values are removed
when their section is excluded, so fallback values cannot restore them.
Jira JSON export converts these hours back to integer seconds. Dates selection
controls spent time; Custom Fields controls original/remaining estimates.
Imported estimate fields carry `settings.jiraTimeField` markers, so renaming
one does not break export. Export does not infer meaning from matching names.
Older fields without markers, duplicate mappings and invalid values are omitted.
Native WeKan export/import and whole-board duplication retain the markers,
remap custom-field IDs and preserve Scrum's selected estimate field. Browser
regression coverage exports the resulting boards back to Jira and verifies
the original numeric seconds. This preserves time totals, not
individual worklog entries or all Jira Scrum data.
#### Explicit Scrum estimate mapping
On the Jira import page, optionally enter the numeric estimate field ID
(for example `customfield_10016`) and its unit (for example `points`). Both
Scrum and Custom Fields must be selected. The importer uses this exact field,
never a guessed field name or a fixed installation-specific field number.
It creates one hidden numeric custom field and selects it as the board's Scrum
estimate source. Scrum remains disabled and its optional fields remain hidden.
The JSON equivalent is `wekanScrumMapping: { estimateFieldId:
"customfield_10016", estimateUnit: "points" }` at the document root.
Missing/null estimates stay unknown and explicit zero is preserved. Non-numeric,
negative or excessive values fail before board creation. The selected field must
occur in the issues or have a numeric entry in the root `schema`; an included
schema entry must declare it numeric. Jira export retains the original field ID
and mapping. Native export and board duplication retain the custom-field markers
and remap the local estimate field. Duplicate export mappings are omitted.
This mapping does not reconstruct historical sprint estimates or enable Sync.
When the export includes its field schema (search with `expand=names,schema`),
the field box offers the numeric fields it declares, story points first. If
exactly one field has Jira Software's story points type
(`com.pyxis.greenhopper.jira:jsw-story-points`) and no field is entered, that
field is used, in points - it is identified by its type, not by its name. With
two such fields, or none, nothing is chosen for you.
#### Scrum issue types and workflow categories
The Jira importer maps `fields.issuetype.name` to the existing hidden Scrum
issue-type field. It maps stable `status.statusCategory.key` values `new`,
`indeterminate` and `done` to list categories `todo`, `doing` and `done`.
It never infers completion from translated status names. Board administrators
can select the existing done-list completion policy in Scrum settings; import
does not enable Scrum or change the default completion policy or visibility.
The Scrum import selection controls both mappings. Invalid issue-type values
and conflicting known categories for statuses merged into the same named list
are rejected before creating the board. Unknown category keys remain unmapped.
Jira export includes the same fields when Scrum is selected. A WeKan `backlog`
list category has no distinct Jira status category and is omitted.
Status names are treated as literal text, including names such as `constructor`
or `__proto__`. Dependency references resolve only to issue keys present in
the imported file; missing keys cannot resolve to JavaScript object properties.
These mappings follow the [Jira issue field representation](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/)
and [stable status category keys](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-workflow-status-categories/).
Sprint snapshots, multiple fix versions, epic relationships and
automatic schema mapping remain separate implementation work. In particular,
an external sprint's current membership cannot reconstruct its original
commitment snapshot. Native WeKan export retains imported issue types and list
categories through the existing Scrum transfer format.
#### Sprints, fix versions, rank and epics
Search with `expand=names,schema` so the export says which custom fields are
the Sprint, Rank and Epic Link fields. WeKan finds them by their schema type
(`gh-sprint`, `gh-lexo-rank`, `gh-epic-link`) or, without a schema, by those
names; it never guesses a `customfield_*` number. Then:
| Jira | WeKan |
| --- | --- |
| Future sprint | Planned sprint with its goal and dates; the card's sprint |
| Active sprint | Planned sprint, reported in Admin Panel → Problems → Recovery: issue search has no commitment snapshot, so start it in WeKan to begin measuring |
| Closed sprint | A closed sprint, with its start and close snapshots rebuilt from the issues and marked partial (below); one without a start and completion date is reported instead |
| Fix version | Release, released with its date or planned. Every fix version is one of the card's releases (a card can be in several since 2026-10-08). Versions still also become `version:` labels |
| Rank | Backlog order: backlog rank 1, 2, ... in Jira's rank order |
| Epic Link | The card's parent when the epic is imported too; otherwise reported. Newer Jira's `parent` was already followed |
Both of Jira's sprint forms are read: sprint objects, and the older
`com.atlassian.greenhopper.service.sprint.Sprint@...[id=...,state=...]`
strings. The board's Scrum settings are turned on when sprints or releases are
imported. These fields are not also imported as text custom fields.
Jira export writes each of a card's releases as one of its `fixVersions` when
Scrum is selected: the original Jira version id when the release came from
Jira (the WeKan release id otherwise), whether it is released, its planned end
as `releaseDate` and its notes as `description`. Importing that file gives the
card the same releases again.
#### Duplicate issue links
Standard Jira `Duplicate` issue links now import as `duplicates` for
`outwardIssue` and `is-duplicated-by` for `inwardIssue`, following the
[Atlassian issue-link model](https://developer.atlassian.com/cloud/jira/platform/issue-linking-model/)
and [Data Center link types](https://developer.atlassian.com/server/jira/platform/rest/v11000/api-group-issuelink/).
Both endpoints must be included in the imported board. Self-links and missing
targets are skipped; the existing one-relation-per-target rule still applies.
The names `Duplicate` and `Duplicates` are recognized case-insensitively.
Custom/localized link names retain the existing generic relation fallback.
The relation is editable in card details and survives native WeKan board
export/import and History restoration. It does not merge duplicate cards or
change blocker analytics. The separate Jira JSON exporter currently omits
issue links; native WeKan export is the supported transfer path for these links.
Other issue links: a link type whose name contains `block` becomes blocks
(outward) or is-blocked-by (inward); any other type becomes related-to.
### What is kept
| Jira | WeKan |
| --- | --- |
| `board.name`, else the project name | Board title |
| `status.name` | List |
| `status.statusCategory.key` | List category (with Scrum) |
| `key`, `summary` | Card title `[KEY] summary` |
| `description` (ADF or text) | Description |
| `labels`, `priority`, `components`, `fixVersions` | Labels |
| `assignee` | Card member, when mapped |
| `reporter` | Requested by |
| `created`, `duedate`, `updated` | Creation date, due date, modified date |
| `timetracking` (or flat time fields) | Spent time; original and remaining estimate fields |
| Chosen estimate field | Hidden number field, the Scrum estimate |
| `issuetype.name` | Scrum issue type (with Scrum) |
| `parent`, Epic Link | Parent card |
| `subtasks` not in the file | Checklist **Sub-tasks** |
| `issuelinks` | Dependencies |
| `comment.comments` | Comments |
| `customfield_NNNNN` | Custom fields |
| Sprint, fix version, Rank | Scrum sprint, release, backlog rank |
| `automationRules` | Rules |
The export writes `board.name`, and per card an issue `WEKAN-1`, `WEKAN-2`...
with `summary`, `description`, `status` (the list, with its category when
Scrum is selected), `issuetype` and `fixVersions` (with Scrum), `labels`,
`duedate`, `timetracking`, `created`, the owner as `assignee`, Requested by
(else the creator) as `reporter`, `parent`, every checklist item as a
`subtasks` entry, the comments and the custom fields as `customfield_90001`, `customfield_90002`...
with a `names` map. With an estimate mapping it also writes
`wekanScrumMapping` and `schema`.
### What is not kept
A closed sprint's report: Jira's sprint report has no documented API, so the
import rebuilds it from documented issue data. Committed at the start are the
issues whose Sprint field named the sprint at its start date; at the close,
those naming it at its completion, each done when its status was in Jira's
Done category then. Both come from each issue's change history - export with
`expand=changelog` (`GET /rest/api/3/search/jql?fields=*all&expand=changelog`)
for that; without it, the issues naming the sprint now, done when resolved by
the close. The list is the status then, or the status now when that one has no
list on the board, and the estimate is the estimate now. The snapshots are
marked partial, because a rebuilt one cannot see what changed between two
history entries.
The import reports these on the loss report:
- an attachment that could not be downloaded, and why (no sign-in given, a
refused address, an HTTP error);
- a parent or Epic Link to an issue that is not in the file;
- more result pages than the file holds (`nextPageToken`, or a `total`
larger than the issues in the file);
- active sprints (imported as planned), closed sprints rebuilt from the issues,
and closed sprints without dates (not imported);
- more than 50 custom fields.
Invalid estimate values, invalid issue types and conflicting status categories
stop the import before the board is created.
Assignees who are not mapped do not become card members. Only the first
assignee is read.
The export leaves out archived cards and lists, swimlanes, issue links,
attachments and checklists other than as sub-task entries. Several checklists
are flattened into one sub-task list.
### Attachment files
The search carries each attachment's `content` address,
`/rest/api/3/attachment/content/<id>`, which Jira's REST API documents as the
attachment's contents. Under **Attachment files** on the import page, give the
Jira address (`https://your-site.atlassian.net`), the account's email and an
[API token](https://id.atlassian.com/manage-profile/security/api-tokens); the
import downloads each file with them. Jira answers with a redirect to its media
store, which is followed without the sign-in.
The address and the sign-in go with that one import: they are sent only to the
address typed there (an export file names any URL it likes, and one pointing
an attachment elsewhere gets no sign-in), never stored and never logged, and
the token field is emptied when Import is pressed. Every download goes through
the import's SSRF guard, which checks each redirect and drops the sign-in on a
redirect to another host, and lands in Admin Panel → Attachments → Default
Storage like any upload. A file that cannot be fetched is on the loss report
with the reason, and the import goes on. Leaving the fields empty imports the
board without its files. Unticking **Attachments** under what to include
leaves them out too. A service on a private address is refused by the same
guard. `models/lib/importAttachmentAuth.js` decides what is asked of whom.
Through the REST API (`POST /api/boards/import/<source>`), send the same as
`"attachmentAuth": { "url": ..., "username": ..., "token": ... }` beside
`"board"`.
### How it is built and tested
- `models/jiraCreator.js` creates the board. `models/lib/jiraIssueExtras.js`,
`models/lib/jiraTimeTracking.js`, `models/lib/jiraEstimateMapping.js`,
`models/lib/jiraScrumMetadata.js` and `models/lib/jiraScrumPlanning.js`
read the parts of an issue. `client/components/import/jiraMembersMapper.js`
lists the assignees to map.
- `models/lib/externalExportFormatters.js` (`jira`) writes the export, from
what `models/lib/externalExporters.js` collects.
- Unit tests: `tests/jiraIssueExtras.test.cjs`,
`tests/jiraTimeTracking.test.cjs`, `tests/jiraEstimateMapping.test.cjs`,
`tests/jiraScrumMetadata.test.cjs`, `tests/jiraScrumPlanning.test.cjs`,
`tests/kanboardJiraCreator.import.test.cjs` and
`tests/externalExportRoundTrip.test.cjs`. The fixture is
`tests/fixtures/import-formats/jira.json`.
- Playwright: `tests/playwright/specs/import-export-format-audit.e2e.js`
(importing the fixture through the page, refusing malformed JSON),
`jira-time-import.e2e.js`, `jira-estimate-import.e2e.js`,
`jira-scrum-import.e2e.js`, `duplicate-dependencies.e2e.js` (Jira duplicate
links through native board transfer), and the `list-sync-*.e2e.js` cases
for Sync, all in `tests/playwright/specs/`.
## Commits
- [Jira and Taskwarrior exports carry the card dependencies; the round trip of every export checks them](https://github.com/wekan/wekan/commit/d613a00030a7827d4d6318c50d6feb5d80d008ce)
- [JSON exports whose cards are one array are written a page at a time: Trello, Jira, Asana, Zenkit, OpenProject, GitHub ](https://github.com/wekan/wekan/commit/f293ae4076092a387505b1909053cd66a62441c8)
- [Jira and CSV / TSV files are uploaded too; their people and columns are read from the file on the server](https://github.com/wekan/wekan/commit/60bbf69164766746718c1792f228b6f2809cd715)
- [Large Jira exports import, and an existing board can be saved as a board template](https://github.com/wekan/wekan/commit/14a43da557985bb85e8a73134eda6b243e8521c7)
- [Import: attachment files of Jira, Nextcloud Deck, OpenProject, Asana and GitLab](https://github.com/wekan/wekan/commit/51238ed8ad80179fa54517ab429b7a14c31510e8)
- [Jira import: closed sprints, rebuilt from the issues](https://github.com/wekan/wekan/commit/cc0b8c60ba3c4b815d1689683fe088fd02c73226)
- [Discover the Jira estimate field from the export's schema](https://github.com/wekan/wekan/commit/47a603a63f9d66716a1a92d0bf4c69a0e124e13d)
- [Import Jira sprints, fix versions, rank and epic links as Scrum planning data](https://github.com/wekan/wekan/commit/b0803ffeaa09e4f7cf3ab2fc4bded0f3229dba7d)
- [Import Jira comments, sub-tasks, parents, custom fields and more labels](https://github.com/wekan/wekan/commit/be13dd663a1adee0332b019011bf51ba9203a05a)
- [Add directed duplicate card relationships and Jira import mapping](https://github.com/wekan/wekan/commit/eb527dd13fee74de89381cfd9b07e088c641eaaa)
- [Map explicit Jira numeric estimates to existing Scrum custom fields](https://github.com/wekan/wekan/commit/a76c97461ded0fd107b4d165b59e78a196e72416)
- [Treat Jira status names and issue keys as dictionary data](https://github.com/wekan/wekan/commit/9d60f7bf0df73306a3d74fb5bd53a327a48b3f2a)
- [Preserve Jira issue types and workflow categories in Scrum transfers](https://github.com/wekan/wekan/commit/59a13f40d6731acbaeb875bec8cf6ce369c4ce5c)
- [Add opt-in Jira spent-time synchronization](https://github.com/wekan/wekan/commit/4aa61c6d56878562a199687ec70e14e3e07ef176)
- [Honor Jira time sections in the import selector](https://github.com/wekan/wekan/commit/1ebc4e3b841d834e6539f1ac4d58278171f15691)
- [Verify Jira estimate mappings across native import and board copies](https://github.com/wekan/wekan/commit/14a4d62fb9899b9a53f4f486a2c4c1b4cc9f451d)
- [Round-trip Jira time tracking through external export](https://github.com/wekan/wekan/commit/c72b9a4a0681556d7e92bb456c7101fa15803e95)
- [Preserve Jira time tracking through existing WeKan fields](https://github.com/wekan/wekan/commit/ef5c7d00c73a7026cf38c2fb3b23c081faffdbee)
- [Add a list-sync job that keeps a list up to date from Jira (and GitHub/GitLab/Gitea)](https://github.com/wekan/wekan/commit/a01e8478c30cce9569c6e68f5eb374031b162191)
- [Add regression tests for CSV, Kanboard and Jira import parsing](https://github.com/wekan/wekan/commit/baec475febba98a6fff15e342d8830d2bc0d0009)
@@ -1,17 +1,37 @@
# KanbanFlow
## What it is
WeKan imports a board from [KanbanFlow](https://kanbanflow.com) through
KanbanFlow's [API](https://kanbanflow.com/api). KanbanFlow has no board export
KanbanFlow's API. KanbanFlow has no board export
file, so WeKan fetches the board with the board's API token. Columns become
lists, swimlanes stay swimlanes, and tasks keep their description, color,
labels, due date, subtasks, time spent, estimate, people and comments.
## How to import
## Read more
- [Wikipedia: kanban boards](https://en.wikipedia.org/wiki/Kanban_board)
- KanbanFlow API: the board, tasks, users and
comments endpoints, Basic auth with `apiToken`, and paging with
`tasksLimited`/`nextTaskId`
- [KanbanFlow](https://kanbanflow.com): the app; the API token is under the
board's **Settings → API & Webhooks**
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In KanbanFlow, open the board, then the board menu → **Settings → API &
Webhooks**, and create (or copy) an **API token**. A token belongs to that
one board.
2. In WeKan, go to **All Boards → New → Import → KanbanFlow**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → KanbanFlow**.
3. Paste the token, then click **List**. The board the token belongs to is
listed.
4. Choose it and click **Fetch**. WeKan reads the board, its tasks, its users
@@ -26,7 +46,7 @@ once sent, and WeKan does not keep it on the board, the user or the server.
Requests go to `https://kanbanflow.com` only, with the token in the HTTP Basic
`Authorization` header, never in a URL.
## How to import many boards at once
### How to import many boards at once
A KanbanFlow API token belongs to one board, so each board is fetched with its
own token: repeat **How to import** once per board.
@@ -39,7 +59,7 @@ KanbanFlow is imported through the generalized importer
project**: each KanbanFlow swimlane then becomes its own WeKan board, named
after that swimlane.
## How to export
### How to export
WeKan has no KanbanFlow export. KanbanFlow has no board file to import, and
its API token belongs to a board that already exists, so there is nothing for
@@ -47,15 +67,105 @@ WeKan to write. To take a WeKan board elsewhere, use one of the other export
formats (**Board Settings → Export**), such as CSV or Trello JSON, if the
target reads it.
## How to export all boards at once
### How to export all boards at once
There is no KanbanFlow export, so there is none for all boards either. **All
Boards → Export all boards → CSV** writes a CSV file per board.
## Format details
### REST API
```bash
python3 api.py importboardfrom kanbanflow board.json # POST /api/boards/import/kanbanflow
```
The HTTP route:
- `POST /api/boards/import/kanbanflow` with the fetched JSON (the
`{ kanbanflow: true, board, tasks, users, comments }` document) as `board`.
The REST API does not take a KanbanFlow token: fetch the board first (the
import page, or the KanbanFlow API itself) and post what was fetched.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 20,000 tasks. More stops the import with an error.
(`MAX_KANBANFLOW_FETCH_TASKS` in
[models/lib/apiImport/kanbanflow.js](../../../../../../models/lib/apiImport/kanbanflow.js#L16))
- Comments are one request per task, for the first 5,000 tasks only.
(`MAX_KANBANFLOW_COMMENT_TASKS` in
[models/lib/apiImport/kanbanflow.js](../../../../../../models/lib/apiImport/kanbanflow.js#L17))
- Tasks are fetched 100 per request. (`PAGE_SIZE` in
[models/lib/apiImport/kanbanflow.js](../../../../../../models/lib/apiImport/kanbanflow.js#L18))
- Comments are fetched with 4 requests at a time. (`COMMENT_CONCURRENCY` in
[models/lib/apiImport/kanbanflow.js](../../../../../../models/lib/apiImport/kanbanflow.js#L20))
- At most 20,000 tasks. More stops the import with an error.
(`MAX_KANBANFLOW_TASKS` in
[models/lib/kanbanflowApiFormat.js](../../../../../../models/lib/kanbanflowApiFormat.js#L34))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
- **Reading from the service's API**: each request may take 30 seconds and
answer at most 32 MB, with no redirects followed
([server/lib/apiImportRequest.js](../../../../../../server/lib/apiImportRequest.js));
each text field read is cut to 4,096 characters
([models/lib/apiImportServices.js](../../../../../../models/lib/apiImportServices.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
This format's own code:
[models/lib/apiImport/kanbanflow.js](../../../../../../models/lib/apiImport/kanbanflow.js),
[models/lib/kanbanflowApiFormat.js](../../../../../../models/lib/kanbanflowApiFormat.js),
[releases/live-tests/kanbanflow-import.mjs](../../../../../../releases/live-tests/kanbanflow-import.mjs).
The tests that pin it:
[tests/kanbanflowApiImport.test.cjs](../../../../../../tests/kanbanflowApiImport.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
What is read is the KanbanFlow API's own JSON
([API documentation](https://kanbanflow.com/api)), which
(API documentation), which
`models/lib/apiImport/kanbanflow.js` fetches and puts together:
- `GET /api/v1/board`: `_id`, `name`, `columns: [{ uniqueId, name }]`,
@@ -102,7 +212,7 @@ What the current code does:
- Limits: 20,000 tasks; comments are fetched for the first 5,000 tasks
(reported when there are more).
## What is kept
### What is kept
| KanbanFlow | WeKan |
| --- | --- |
@@ -122,7 +232,7 @@ What the current code does:
| `subTasks` (`name`, `finished`, `dueDate`, `userId`) | Checklist "Subtasks", with each item's due date and assignee |
| Comments | Comments, with author and date |
## What is not kept
### What is not kept
The import reports these on the loss report:
@@ -139,21 +249,7 @@ Not read at all: attachments, time entries (only their total is kept),
recurring task settings, the task number, WIP limits and the board's
webhooks.
## REST API
```bash
python3 api.py importboardfrom kanbanflow board.json # POST /api/boards/import/kanbanflow
```
The HTTP route:
- `POST /api/boards/import/kanbanflow` with the fetched JSON (the
`{ kanbanflow: true, board, tasks, users, comments }` document) as `board`.
The REST API does not take a KanbanFlow token: fetch the board first (the
import page, or the KanbanFlow API itself) and post what was fetched.
## How it is built and tested
### How it is built and tested
- `models/lib/apiImportServices.js` declares the service (`kanbanflow`, one
secret field `token`). `models/lib/apiImport/kanbanflow.js` is the client:
@@ -172,13 +268,7 @@ import page, or the KanbanFlow API itself) and post what was fetched.
the columns, and checks that a wrong token is refused. Without the variable
it is skipped.
## Sources
## Commits
- [KanbanFlow API](https://kanbanflow.com/api): the board, tasks, users and
comments endpoints, Basic auth with `apiToken`, and paging with
`tasksLimited`/`nextTaskId`
- [KanbanFlow](https://kanbanflow.com): the app; the API token is under the
board's **Settings → API & Webhooks**
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Imported subtasks keep their due date and person: a checklist item has both](https://github.com/wekan/wekan/commit/cf6f67e789ac404866d4b51591820570850baaa3)
- [Import: Planka, Microsoft To Do, KanbanFlow, Basecamp, Google Tasks and Google Keep from their APIs](https://github.com/wekan/wekan/commit/46e30f01e48f2676a47c0052007f5c4ea951a923)
@@ -1,5 +1,7 @@
# Kanboard
## What it is
WeKan imports boards from [Kanboard](https://kanboard.org/) and exports a board
in the same Kanboard JSON shape, so a board round-trips through it.
@@ -8,7 +10,35 @@ is assembled from Kanboard's JSON-RPC API, or written by hand:
`{ board, columns, swimlanes, categories, tasks }`. Columns become lists,
swimlanes stay swimlanes and tasks become cards.
## How to import
## Read more
- [Wikipedia: Kanboard, the kanban project management software](https://en.wikipedia.org/wiki/Kanboard)
- [Kanboard API](https://docs.kanboard.org/v1/api/): the JSON-RPC procedures
the import shape is built from
- [API authentication](https://docs.kanboard.org/v1/api/authentication/): the
endpoint, user name and token
- [Task procedures](https://docs.kanboard.org/v1/api/task_procedures/):
`getAllTasks` and `createTask`
- [Internal task link procedures](https://docs.kanboard.org/v1/api/internal_task_link_procedures/):
`createTaskLink`, `getTaskLinkById` and `getAllTaskLinks`
- Kanboard's source: the built-in link types in `app/Schema/Sql/mysql.sql`
(the `links` table), and
[`app/Model/TaskLinkModel.php`](https://github.com/kanboard/kanboard/blob/main/app/Model/TaskLinkModel.php),
which stores each link from both tasks and lists the other task as
`task_id`
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md),
[CSV/TSV import](../CSV/CSV.md), [Excel import](../Excel/Excel-and-VBA.md),
[Trello](../Trello/Trello.md), [Jira](../Jira/Jira.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Kanboard, find the API token on the settings page. The API is at
`https://YOUR_SERVER/jsonrpc.php`, with the user name `jsonrpc` and that
@@ -20,7 +50,7 @@ swimlanes stay swimlanes and tasks become cards.
`getAllComments`, `getTaskTags`, `getAllTaskLinks`) on the task as
`subtasks`, `comments`, `tags` and `links`. Keep each task's `id`: links
name the other task by it. See the shape below.
3. In WeKan, go to **All Boards → New → Import → Kanboard**.
3. In WeKan, go to **All Boards → Add Board → Import → Import board → Kanboard**.
4. Paste the JSON into the text box. Tick the parts to import.
5. Click **Import**. WeKan then asks you to map the task owners to WeKan users.
Map them and click **Done**, or click **Import without mapping members (map
@@ -62,7 +92,7 @@ A task may name its column, swimlane and category by `column_id`,
`swimlane_id` and `category_id` instead; the ids are looked up in the
`columns`, `swimlanes` and `categories` arrays.
## How to import many boards at once
### How to import many boards at once
- On the import page, under **Import many boards**, choose several Kanboard JSON
files, or one `.zip` that holds them. Each file becomes its own board,
@@ -77,7 +107,7 @@ A task may name its column, swimlane and category by `column_id`,
`python3 api.py importboardsfrom kanboard FILE_OR_DIR ...` takes files,
directories of files, or `.zip` files.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include:**, tick the parts to export.
@@ -92,7 +122,7 @@ A task may name its column, swimlane and category by `column_id`,
row itself, so create only one of the two rows of each link. The file is
also what WeKan's own Kanboard import reads.
## How to export all boards at once
### How to export all boards at once
1. **All Boards → sidebar → Export all boards**, then choose **Kanboard**.
This downloads one `.zip` with one Kanboard file per board you can
@@ -104,7 +134,87 @@ A task may name its column, swimlane and category by `column_id`,
From a script: `python3 api.py exportallboards kanboard boards.zip`.
## Format details
### REST API
```bash
python3 api.py importboardfrom kanboard board.json # POST /api/boards/import/kanboard
python3 api.py importboardsfrom kanboard a.json b.json dir/ # one board per file
python3 api.py exportboardformat BOARDID kanboard board.json # GET /api/boards/BOARDID/export/kanboard?authToken=TOKEN
python3 api.py exportallboards kanboard boards.zip # GET /api/export-all-boards/kanboard?authToken=TOKEN
```
`GET /api/export-all-boards/kanboard?authToken=TOKEN&boardIds=ID1,ID2` exports
only the boards listed.
## How the numbers are calculated
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
The tests that pin it:
[tests/externalExportRoundTrip.test.cjs](../../../../../../tests/externalExportRoundTrip.test.cjs),
[tests/importedTaskPlan.test.cjs](../../../../../../tests/importedTaskPlan.test.cjs),
[tests/kanboardImport.test.cjs](../../../../../../tests/kanboardImport.test.cjs),
[tests/kanboardJiraCreator.import.test.cjs](../../../../../../tests/kanboardJiraCreator.import.test.cjs),
[tests/kanboardLinksGithubComments.test.cjs](../../../../../../tests/kanboardLinksGithubComments.test.cjs),
[tests/playwright/specs/external-export-extras.e2e.js](../../../../../../tests/playwright/specs/external-export-extras.e2e.js),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
From the [format coverage](../Format-Coverage.md) audit:
@@ -162,7 +272,7 @@ What the current code does (`parseKanboard` in
The shared creator's typed custom fields (number, checkbox, text) apply only
to sources that send custom field values.
## What is kept
### What is kept
| Kanboard | WeKan |
| --- | --- |
@@ -204,7 +314,7 @@ the second time with the opposite label, and the import folds the two back
into one. The parent is written when **Subtasks** is selected, dependencies
when **Dependencies** is.
## What is not kept
### What is not kept
The import reports these on the loss report:
@@ -231,19 +341,7 @@ fields. A parent or dependency pointing at a card that is not exported
(archived, or on another board) is left out. Several checklists are flattened
into one subtask list.
## REST API
```bash
python3 api.py importboardfrom kanboard board.json # POST /api/boards/import/kanboard
python3 api.py importboardsfrom kanboard a.json b.json dir/ # one board per file
python3 api.py exportboardformat BOARDID kanboard board.json # GET /api/boards/BOARDID/export/kanboard?authToken=TOKEN
python3 api.py exportallboards kanboard boards.zip # GET /api/export-all-boards/kanboard?authToken=TOKEN
```
`GET /api/export-all-boards/kanboard?authToken=TOKEN&boardIds=ID1,ID2` exports
only the boards listed.
## How it is built and tested
### How it is built and tested
- `models/lib/externalParsers.js` (`parseKanboard`) reads the file.
`models/kanboardCreator.js` creates the board; it is the shared creator of
@@ -266,23 +364,12 @@ only the boards listed.
`tests/playwright/specs/external-export-extras.e2e.js` (the export carries
comments and checklists, and the selection removes them).
## Sources
## Commits
- [Kanboard API](https://docs.kanboard.org/v1/api/): the JSON-RPC procedures
the import shape is built from
- [API authentication](https://docs.kanboard.org/v1/api/authentication/): the
endpoint, user name and token
- [Task procedures](https://docs.kanboard.org/v1/api/task_procedures/):
`getAllTasks` and `createTask`
- [Internal task link procedures](https://docs.kanboard.org/v1/api/internal_task_link_procedures/):
`createTaskLink`, `getTaskLinkById` and `getAllTaskLinks`
- Kanboard's source: the built-in link types in `app/Schema/Sql/mysql.sql`
(the `links` table), and
[`app/Model/TaskLinkModel.php`](https://github.com/kanboard/kanboard/blob/main/app/Model/TaskLinkModel.php),
which stores each link from both tasks and lists the other task as
`task_id`
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md),
[CSV/TSV import](../CSV/CSV.md), [Excel import](../Excel/Excel-and-VBA.md),
[Trello](../Trello/Trello.md), [Jira](../Jira/Jira.md).
- [Every export is held to what its own import reads back: Asana time tracking, Deck's done tick, Kanboard colors](https://github.com/wekan/wekan/commit/1a02de4b5b398018bbe2076d98cba10b01639e5a)
- [Kanboard keeps its task recurrence, estimate, score, reference and external links, both ways](https://github.com/wekan/wekan/commit/28891103f6bec2d51e1dd1531103235d95a1a70c)
- [Board View / Version Control, issue files and synced issue details](https://github.com/wekan/wekan/commit/326d9bbf619ed811e9db92896a67f0ea6fa60b24)
- [Import Kanboard task links as parent cards and dependencies, and GitHub comments as card comments](https://github.com/wekan/wekan/commit/594867bab71e249f559eb6590286027d4be38d07)
- [Import Kanboard subtasks, comments, categories, colors and dates](https://github.com/wekan/wekan/commit/ba4157ec188e1900000e2b8a5f8984c14e1ae7e5)
- [Add regression tests for CSV, Kanboard and Jira import parsing](https://github.com/wekan/wekan/commit/baec475febba98a6fff15e342d8830d2bc0d0009)
- [Fix Sandstorm export board from web. - Fix Error when logging in to Wekan REST API when using Sandstorm Wekan. ](https://github.com/wekan/wekan/commit/32f896f19d31f92b5c2e540d0960d00fbf1bf9c3)
@@ -1,19 +1,42 @@
# Kanri
## What it is
WeKan imports and exports a board as the JSON of [Kanri](https://github.com/kanriapp/kanri),
the offline desktop kanban app. Kanri writes two files: a single board, and
all data with the app settings and every board. WeKan reads both and writes a
single board. Columns become lists and cards keep their description, due
date, tags, colors and tasks.
## How to import
## Read more
- [Wikipedia: kanban boards](https://en.wikipedia.org/wiki/Kanban_board)
- [Kanri](https://github.com/kanriapp/kanri): the app
- [kanban-types.d.ts](https://github.com/kanriapp/kanri/blob/main/types/kanban-types.d.ts):
the board, column, card and tag types
- [json-schemas.ts](https://github.com/kanriapp/kanri/blob/main/types/json-schemas.ts):
what Kanri's import accepts
- [pages/import.vue](https://github.com/kanriapp/kanri/blob/main/pages/import.vue)
and [the English strings](https://github.com/kanriapp/kanri/blob/main/i18n/locales/en.json):
the Import/Export page, its Partial and Full export and import
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Kanri, choose **Import/Export** in the sidebar. Under **Export Data**:
- **Partial Export (individual board)**: click **Export individual board**,
select the board and save the `.json` file;
- **Full Export**: click **Export all data** to save all boards, themes and
preferences in one `.json` file.
2. In WeKan, go to **All Boards → New → Import → Kanri**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Kanri**.
3. Open the `.json` file in a text editor, copy all of it and paste it into
the text box.
4. Click **Import**.
@@ -24,7 +47,7 @@ An all-data export brings in every board. Each Kanri board becomes a swimlane
named after it, on one WeKan board. Tick **One board per project** (below) to
make each Kanri board its own WeKan board instead.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Kanri**, then under **Import many boards**
choose several `.json` files, or one `.zip` that holds them.
@@ -55,7 +78,7 @@ python3 api.py importboardsfrom kanri FILE_OR_DIR ...
Each argument is a file, a directory of files, or a `.zip` file.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Choose what to include, then under **JSON** choose **Kanri**. The board
@@ -70,7 +93,7 @@ data with what it imports, and expects an all-data file.
The Kanri entry is offered for a whole board only, not for a swimlane or a
list.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Kanri**.
@@ -89,7 +112,98 @@ From a script:
python3 api.py exportallboards kanri boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom kanri board.json # POST /api/boards/import/kanri
python3 api.py importboardsfrom kanri FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID kanri board.json
python3 api.py exportallboards kanri boards.zip
```
The HTTP routes:
- `POST /api/boards/import/kanri` with the file's JSON as `board`;
- `GET /api/boards/:boardId/export/kanri?authToken=…` returns the board as
JSON;
- `GET /api/export-all-boards/kanri?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 20,000 cards. More stops the import with an error. (`MAX_KANRI_CARDS`
in
[models/lib/kanriFormat.js](../../../../../../models/lib/kanriFormat.js#L35))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/kanriFormat.js](../../../../../../models/lib/kanriFormat.js).
The tests that pin it:
[tests/boardExportScope.test.cjs](../../../../../../tests/boardExportScope.test.cjs),
[tests/importLossReport.test.cjs](../../../../../../tests/importLossReport.test.cjs),
[tests/kanriFormat.test.cjs](../../../../../../tests/kanriFormat.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
The format is the JSON that [Kanri](https://github.com/kanriapp/kanri)'s
Import & Export page writes and its **Import from Kanri** reads, as its
@@ -159,7 +273,7 @@ What the export writes (`formatKanri` in the same module):
Archived cards and archived lists are not exported.
## What is kept
### What is kept
| Kanri | WeKan |
| --- | --- |
@@ -174,7 +288,7 @@ Archived cards and archived lists are not exported.
| Card `color` | Card color |
| `boards[0]` of an all-data export | The imported board |
## What is not kept
### What is not kept
The import reports these on the loss report:
@@ -194,24 +308,7 @@ dates, custom fields or swimlanes: Kanri has no place for them. Several
checklists become one task list. Kanri's own import does not read
`isDueDateCompleted`.
## REST API
```bash
python3 api.py importboardfrom kanri board.json # POST /api/boards/import/kanri
python3 api.py importboardsfrom kanri FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID kanri board.json
python3 api.py exportallboards kanri boards.zip
```
The HTTP routes:
- `POST /api/boards/import/kanri` with the file's JSON as `board`;
- `GET /api/boards/:boardId/export/kanri?authToken=…` returns the board as
JSON;
- `GET /api/export-all-boards/kanri?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How it is built and tested
### How it is built and tested
- `models/lib/kanriFormat.js` reads and writes the JSON. `models/import.js`
sends the document to the parser, and `models/kanboardCreator.js` creates
@@ -227,16 +324,10 @@ The HTTP routes:
project; other documents are refused", and the export menu link for every
format.
## Sources
## Commits
- [Kanri](https://github.com/kanriapp/kanri): the app
- [kanban-types.d.ts](https://github.com/kanriapp/kanri/blob/main/types/kanban-types.d.ts):
the board, column, card and tag types
- [json-schemas.ts](https://github.com/kanriapp/kanri/blob/main/types/json-schemas.ts):
what Kanri's import accepts
- [pages/import.vue](https://github.com/kanriapp/kanri/blob/main/pages/import.vue)
and [the English strings](https://github.com/kanriapp/kanri/blob/main/i18n/locales/en.json):
the Import/Export page, its Partial and Full export and import
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Deck and Kanri exports are written a page at a time, each list around its cards](https://github.com/wekan/wekan/commit/21c64e092d8b067a9416a09a92c0ca1424b9da26)
- [Themes: every board theme and every color a member chooses is readable](https://github.com/wekan/wekan/commit/8b2114cd0f9501867c01521c7a6f78a02e44d549)
- [Read every import source through one path and one file chooser, from one description of the sources](https://github.com/wekan/wekan/commit/c80a656901103bfd29b41843c7e255b4ed3bfa17)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Import and export boards as Kanri JSON](https://github.com/wekan/wekan/commit/eec53eb322f6cee14b61f1fd1f9d1ca0ee26d74e)
@@ -1,17 +1,37 @@
# Leo
## What it is
WeKan imports and exports a board as an outline of the
[Leo](https://leo-editor.github.io/leo-editor/) literate editor: a `.leo`
file, which is XML. Top-level nodes are lists, their children are cards, and
deeper nodes are checklists. A node's body is the card's description, and a
marked node is a done card.
## How to import
## Read more
- [Wikipedia: Leo, the outlining editor](https://en.wikipedia.org/wiki/Leo_(text_editor))
- [Wikipedia: outliners](https://en.wikipedia.org/wiki/Outliner)
- [Leo](https://leo-editor.github.io/leo-editor/): the editor and its `.leo`
outline
- [Leo commands reference](https://leo-editor.github.io/leo-editor/commands.html):
open-outline, save-file, and that `.leo` files are XML
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Leo, open or create the outline and save it as a `.leo` file
(**save-file**, Ctrl-S, or **save-file-as**). Leo's outlines are stored as
XML `.leo` files.
2. In WeKan, go to **All Boards → New → Import → Leo**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Leo**.
3. Open the `.leo` file in a text editor, copy all of it and paste it into the
text box.
4. Click **Import**.
@@ -21,7 +41,7 @@ marked node is a done card.
Text that is not a Leo outline (no `<leo_file>` with `<vnodes>`) is refused,
and no board is created.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Leo**, then under **Import many boards**
choose several `.leo` files, or one `.zip` that holds them.
@@ -47,7 +67,7 @@ python3 api.py importboardsfrom leo FILE_OR_DIR ...
Each argument is a file, a directory of files, or a `.zip` file.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Choose what to include, then under **JSON** choose **Leo**. The board
@@ -56,7 +76,7 @@ Each argument is a file, a directory of files, or a `.zip` file.
The Leo entry is offered for a whole board only, not for a swimlane or a list.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Leo**.
@@ -72,7 +92,105 @@ From a script:
python3 api.py exportallboards leo boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom leo board.leo # POST /api/boards/import/leo
python3 api.py importboardsfrom leo FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID leo board.leo
python3 api.py exportallboards leo boards.zip
```
The HTTP routes:
- `POST /api/boards/import/leo` with the file's text as `board`;
- `GET /api/boards/:boardId/export/leo?authToken=…` returns the file as
`application/xml`;
- `GET /api/export-all-boards/leo?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- The Leo file: at most 16,777,216 characters (16 MB of text). More stops the
import with an error. (`MAX_LEO_LENGTH` in
[models/lib/leoOutline.js](../../../../../../models/lib/leoOutline.js#L33))
- Nesting deeper than 64 levels is not followed. (`MAX_LEO_DEPTH` in
[models/lib/leoOutline.js](../../../../../../models/lib/leoOutline.js#L36))
- At most 100,000 outline nodes. More stops the import with an error.
(`MAX_LEO_NODES` in
[models/lib/leoOutline.js](../../../../../../models/lib/leoOutline.js#L39))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/leoOutline.js](../../../../../../models/lib/leoOutline.js),
[models/lib/leoOutlineFormat.js](../../../../../../models/lib/leoOutlineFormat.js),
[server/lib/leoImport.js](../../../../../../server/lib/leoImport.js).
The tests that pin it:
[tests/importLossReport.test.cjs](../../../../../../tests/importLossReport.test.cjs),
[tests/leoOutline.test.cjs](../../../../../../tests/leoOutline.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js),
[tests/playwright/specs/leo-outline-import.e2e.js](../../../../../../tests/playwright/specs/leo-outline-import.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
The format is the [Leo](https://leo-editor.github.io/leo-editor/) literate
editor's XML outline: nested `<v>` nodes with `<vh>` headlines, and bodies in
@@ -125,7 +243,7 @@ What the export writes (`models/lib/leoOutlineFormat.js`):
Archived cards and archived lists are not exported.
## What is kept
### What is kept
| Leo | WeKan |
| --- | --- |
@@ -139,7 +257,7 @@ Archived cards and archived lists are not exported.
| Level 3 node without children | Item of a checklist named after the card |
| Marked item node | Finished checklist item |
## What is not kept
### What is not kept
The import reports these on the loss report:
@@ -152,24 +270,7 @@ creation date and checklists. It does not write swimlanes, labels, other
dates, members, comments,
custom fields or attachments.
## REST API
```bash
python3 api.py importboardfrom leo board.leo # POST /api/boards/import/leo
python3 api.py importboardsfrom leo FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID leo board.leo
python3 api.py exportallboards leo boards.zip
```
The HTTP routes:
- `POST /api/boards/import/leo` with the file's text as `board`;
- `GET /api/boards/:boardId/export/leo?authToken=…` returns the file as
`application/xml`;
- `GET /api/export-all-boards/leo?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How it is built and tested
### How it is built and tested
- `models/lib/leoOutline.js` reads the outline; `server/lib/leoImport.js`
loads it on the server only, so the XML parser is not sent to browsers.
@@ -184,12 +285,19 @@ The HTTP routes:
not a Leo outline is refused) and the export menu link in
`tests/playwright/specs/import-export-format-audit.e2e.js`.
## Sources
## Commits
- [Leo](https://leo-editor.github.io/leo-editor/): the editor and its `.leo`
outline
- [Leo commands reference](https://leo-editor.github.io/leo-editor/commands.html):
open-outline, save-file, and that `.leo` files are XML
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Import and export Rocket.Chat and Fizzy](https://github.com/wekan/wekan/commit/dffbafd30fd16978dbae49a4e0d576bb1ff017ec)
- [Leo: a node's id stamp is the card's creation date, both ways; plugin data is reported](https://github.com/wekan/wekan/commit/3be07b147b46bcbe42f64da1170eda5fafcfe2ad)
- [Leo outlines are written a page of cards at a time too](https://github.com/wekan/wekan/commit/e1261ef5fb9f233e60352ee28a8e4e16eb44a4c7)
- [Read every import source through one path and one file chooser, from one description of the sources](https://github.com/wekan/wekan/commit/c80a656901103bfd29b41843c7e255b4ed3bfa17)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Import boards from Plane issue exports](https://github.com/wekan/wekan/commit/d21a26339363181807908e26c2a5155e732b745e)
- [Import and export boards as Notion Markdown & CSV exports](https://github.com/wekan/wekan/commit/b7d3274780989c8169549507e416c60316d70ccf)
- [Import and export boards as Vikunja data exports](https://github.com/wekan/wekan/commit/a8e73adf4837fc349f2105818a580c048a85cd28)
- [Import and export boards as OPML outlines](https://github.com/wekan/wekan/commit/e6c8f85518a752b2b3f310907afc2485b11a948a)
- [Fill the Cherokee Leo instruction and cover all locales](https://github.com/wekan/wekan/commit/9afc5bf221138091c8ec718d8a898dd05725787b)
- [Add Tigre and Wolaytta Leo import instructions](https://github.com/wekan/wekan/commit/598893c70b7402fd96597ece006ce6be1d31f1a1)
- [Add Nahuatl and Tamazight Leo import instructions](https://github.com/wekan/wekan/commit/09429dcfed399dde73c2226b94c8bdaa97473fc5)
- [Add Greenlandic and Inuktitut Leo import instructions](https://github.com/wekan/wekan/commit/48d3e716484edffde1fa4abbefda10b68f986a8b)
- [Import and export Leo .leo outlines](https://github.com/wekan/wekan/commit/286ed906a93a40d750ff66d0344d189fd446f055)
@@ -1,12 +1,33 @@
# Linear
## What it is
WeKan imports boards from [Linear](https://linear.app) and exports boards to
it as Linear's issues CSV file. Statuses become lists, teams become swimlanes,
and issues become cards with their assignee, labels, dates, parent issue,
priority, estimate, project and cycle. The export writes Linear's own columns
in Linear's order.
## How to import
## Read more
- [Wikipedia: issue tracking systems](https://en.wikipedia.org/wiki/Issue_tracking_system)
- [Exporting data](https://linear.app/docs/exporting-data): the export steps,
limits and columns
- [LinearCsvImporter.ts](https://github.com/linear/linear/blob/master/packages/import/src/importers/linearCsv/LinearCsvImporter.ts):
how Linear's own importer reads the values
- [Import issues](https://linear.app/docs/import-issues): Linear's import
assistants and CLI importer
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Linear, export the issues as CSV, in one of these ways:
- the whole workspace: **Settings → Administration → Import / Export**,
@@ -17,14 +38,14 @@ in Linear's order.
CSV…**, or press `Ctrl`/`Cmd` + `K` and choose the export option. Members
can export up to 250 issues, admins and owners up to 2,000.
2. Open the CSV file in a text editor and copy all of it.
3. In WeKan, go to **All Boards → New → Import → Linear**.
3. In WeKan, go to **All Boards → Add Board → Import → Import board → Linear**.
4. Paste the text into the box and click **Import**. A **Map members** step
follows with nobody to map: click **Done**. (**Import without mapping
members (map later)** skips that step.)
5. Read the loss report on the import page. It is also kept in **Admin Panel →
Problems → Recovery**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Linear**, then under **Import many boards**
choose several CSV files, or one `.zip` that holds them. Each file becomes
@@ -48,7 +69,7 @@ python3 api.py importboardsfrom linear FILE_OR_DIR ...
The arguments are files, directories of files, or `.zip` files.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include**, choose what to export, then click
@@ -60,7 +81,7 @@ The arguments are files, directories of files, or `.zip` files.
[import documentation](https://linear.app/docs/import-issues) for the
steps.
## How to export all boards at once
### How to export all boards at once
In **All Boards**, open the sidebar and choose **Export all boards**, then
**Linear**. This downloads one `.zip` with one `.csv` file per board you can
@@ -75,7 +96,90 @@ From a script:
python3 api.py exportallboards linear boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom linear issues.csv
python3 api.py importboardsfrom linear issues1.csv issues2.csv
python3 api.py exportboardformat BOARDID linear issues.csv
python3 api.py exportallboards linear boards.zip
```
The HTTP routes:
- `POST /api/boards/import/linear`: the body is `{"board": "<CSV text>"}`.
- `GET /api/boards/:boardId/export/linear?authToken=…`
- `GET /api/export-all-boards/linear?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How the numbers are calculated
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/linearCsvFormat.js](../../../../../../models/lib/linearCsvFormat.js).
The tests that pin it:
[tests/externalExportRoundTrip.test.cjs](../../../../../../tests/externalExportRoundTrip.test.cjs),
[tests/linearCsv.test.cjs](../../../../../../tests/linearCsv.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
What WeKan reads is Linear's
[CSV export](https://linear.app/docs/exporting-data) (workspace or view),
@@ -151,7 +255,7 @@ are empty. In the others:
- Due Date is a day (`2026-10-08`); the other dates are ISO 8601;
- a `,` inside a label becomes a space, and labels are joined by `, `.
## What is kept
### What is kept
| Linear | WeKan |
| --- | --- |
@@ -176,7 +280,7 @@ The assignee becomes a card member only when that name is mapped to a WeKan
user, through the REST API's `membersMapping`. The import page maps no one, so
there it is not kept.
## What is not kept
### What is not kept
The import reports these on the loss report, rather than dropping them
silently:
@@ -195,23 +299,7 @@ The export leaves out checklists, comments, attachments, archived cards,
assignees other than the owner, and every column WeKan has no value for (see
above).
## REST API
```bash
python3 api.py importboardfrom linear issues.csv
python3 api.py importboardsfrom linear issues1.csv issues2.csv
python3 api.py exportboardformat BOARDID linear issues.csv
python3 api.py exportallboards linear boards.zip
```
The HTTP routes:
- `POST /api/boards/import/linear`: the body is `{"board": "<CSV text>"}`.
- `GET /api/boards/:boardId/export/linear?authToken=…`
- `GET /api/export-all-boards/linear?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How it is built and tested
### How it is built and tested
- `models/lib/linearCsvFormat.js` reads and writes the CSV, with the CSV
reader of `models/lib/todoistCsvFormat.js`. `models/lib/externalParsers.js`
@@ -228,14 +316,10 @@ The HTTP routes:
and *every external export menu link returns text and refuses an unrelated
user*.
## Sources
## Commits
- [Exporting data](https://linear.app/docs/exporting-data): the export steps,
limits and columns
- [LinearCsvImporter.ts](https://github.com/linear/linear/blob/master/packages/import/src/importers/linearCsv/LinearCsvImporter.ts):
how Linear's own importer reads the values
- [Import issues](https://linear.app/docs/import-issues): Linear's import
assistants and CLI importer
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
- [Linear cycles become Scrum sprints and project milestones Scrum releases](https://github.com/wekan/wekan/commit/75694ac644d71016b092c0543a62fb63aef817ee)
- [Ten more exports are written a page of cards at a time, their references read in a light first pass](https://github.com/wekan/wekan/commit/e2cbbe510457940b6db26c90b45307a6c539a0e7)
- [Read every import source through one path and one file chooser, from one description of the sources](https://github.com/wekan/wekan/commit/c80a656901103bfd29b41843c7e255b4ed3bfa17)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Import and export boards as Linear CSV](https://github.com/wekan/wekan/commit/fb7cbc66e6c942760de73873fb5fb2f6f66b2a8f)
@@ -1,5 +1,7 @@
# Mail
## What it is
WeKan imports mail as a board for **Board View → Email**, and exports a
board as an `.mbox` file. The import reads an **mbox** (RFC 4155) - the file
Thunderbird, Apple Mail, mutt and Gmail through Google Takeout write - or a
@@ -7,7 +9,21 @@ single **.eml** message (RFC 5322 / MIME). Each conversation becomes one card
in the list **Inbox**, with its sender, recipients and subject, so it is mail in
the Email view; the replies become the card's comments.
## How to import
## Read more
- [Wikipedia: mbox, the mailbox file format](https://en.wikipedia.org/wiki/Mbox)
- [Wikipedia: email](https://en.wikipedia.org/wiki/Email)
- [RFC 4155 - the application/mbox media type](https://www.rfc-editor.org/rfc/rfc4155)
- [RFC 5322 - Internet Message Format](https://www.rfc-editor.org/rfc/rfc5322)
- [mailparser](https://nodemailer.com/extras/mailparser)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. Get the file: in Thunderbird, save the folder with an add-on such as
ImportExportTools NG as `.mbox`, or save one message as `.eml`; in Apple
@@ -15,13 +31,13 @@ the Email view; the replies become the card's comments.
[Google Takeout](../Google-Takeout/Google-Takeout.md) (**Mail**) and take the
`.mbox` from the zip; mutt and other Unix mail programs keep mbox files
already.
2. In WeKan, go to **All Boards → New → Import → Mail (mbox, .eml)**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Mail (mbox, .eml)**.
3. Choose the `.mbox` or `.eml` file, or paste its text.
4. Map the senders to WeKan members, or leave them as they are: a sender who
is not mapped is named at the start of the comment.
5. Click **Import**, and read the loss report.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Mail (mbox, .eml)**, then under **Import many boards**
choose several files, or one `.zip` that holds them.
@@ -38,7 +54,7 @@ From a script:
python3 api.py importboardsfrom mail FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**.
2. Under the tools, choose **Mail (mbox)**. The board downloads as
@@ -51,7 +67,7 @@ description as the text; its comments follow as replies (`In-Reply-To`). A card
that came from mail keeps its sender, recipients and Message-ID - unless Admin
Panel anonymizes exports, which leaves them out because they name people.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Mail (mbox)**.
@@ -63,7 +79,94 @@ From a script:
python3 api.py exportallboards mbox boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/mail` with the file's text, or a
`.zip` as `{ "zipBase64": "..." }`, as for every source of the import page.
- Export: `GET /api/boards/:boardId/export/mbox`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- The mbox file: at most 268,435,456 characters (256 MB of text). More stops the
import with an error. (`MAX_MBOX_LENGTH` in
[models/lib/mboxSplit.js](../../../../../../models/lib/mboxSplit.js#L5))
- At most 20,000 messages. Anything past it is left out. (`MAX_MAIL_MESSAGES` in
[models/lib/mboxSplit.js](../../../../../../models/lib/mboxSplit.js#L6))
- One mail message: at most 32 MB. Anything past it is left out.
(`MAX_MESSAGE_BYTES` in
[server/lib/mailImport.js](../../../../../../server/lib/mailImport.js#L12))
- One message's text is cut to 100,000 characters (its HTML is read up to ten
times that). (`MAX_TEXT` in
[server/lib/mailImport.js](../../../../../../server/lib/mailImport.js#L13))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/mailFormat.js](../../../../../../models/lib/mailFormat.js),
[models/lib/mboxSplit.js](../../../../../../models/lib/mboxSplit.js),
[server/lib/mailImport.js](../../../../../../server/lib/mailImport.js).
The tests that pin it:
[tests/mailFormat.test.cjs](../../../../../../tests/mailFormat.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
- **mbox**: messages separated by a `From ` line; a body line starting `From `
is escaped as `>From ` (mboxrd) and unescaped when read
@@ -80,27 +183,23 @@ python3 api.py exportallboards mbox boards.zip
labels. A conversation labelled **Sent** is outgoing mail, in the Email view's
Sent folder.
## What is kept
### What is kept
Subject, text, sender, To and Cc, date (the received date), Message-IDs of the thread (so a later reply sent to the board joins it), Gmail labels, replies as comments by their sender.
## What is not kept
### What is not kept
Attachments (counted in the loss report), Bcc, HTML formatting, and mail headers other than the ones above. At most 20,000 messages are read from one file. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/mail` with the file's text, or a
`.zip` as `{ "zipBase64": "..." }`, as for every source of the import page.
- Export: `GET /api/boards/:boardId/export/mbox`.
## How it is built and tested
### How it is built and tested
`tests/mailFormat.test.cjs` decodes an mbox with a thread, an encoded subject, Gmail labels and an HTML-only message with mailparser, checks that a malformed sender or a header injection does not become mail, sends the result through the import sanitizer, and exports a board to `.mbox` and reads it back.
## Sources
## Commits
- [RFC 4155 - the application/mbox media type](https://www.rfc-editor.org/rfc/rfc4155)
- [RFC 5322 - Internet Message Format](https://www.rfc-editor.org/rfc/rfc5322)
- [mailparser](https://nodemailer.com/extras/mailparser/)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
- [The .mbox export carries the card labels as Gmail's; the round trip of every export checks labels and due dates](https://github.com/wekan/wekan/commit/c0b3d9013d68ae4ac787655183233935766c5997)
- [WeKan and Trello .zip imports use the shared upload, limit and disk check; .mbox and .enex export a page at a time](https://github.com/wekan/wekan/commit/3b1c7ce7bb430834e024d7684734f7586a07b007)
- [Import page uploads stream to the server's disk, checked against the free space and an Admin Panel limit](https://github.com/wekan/wekan/commit/32c24ed84e9d6c8080e89bdd4097f87a3b0b4b04)
- [Import and export mail, calendars, chats and notes: mbox/.eml, iCalendar, Google Takeout, Slack, Mattermost, Telegram ](https://github.com/wekan/wekan/commit/ccfa6cf362e9b1eb812804d38e4d85653c5b0b0a)
@@ -1,5 +1,7 @@
# Markdown
## What it is
WeKan imports and exports a board as a Markdown task list: the convention that
markdown-kanban tools such as Obsidian Kanban use. A `## List` heading starts a
list, and `- [ ]` / `- [x]` items under it are its cards. An ordinary bulleted
@@ -10,19 +12,36 @@ For the Obsidian Kanban plugin's own board file, with its lane limits, dates
and settings, use [Obsidian Kanban](../Obsidian-Kanban/Obsidian-Kanban.md)
instead.
## How to import
## Read more
- [Wikipedia: Markdown, the markup language](https://en.wikipedia.org/wiki/Markdown)
- [Obsidian Kanban plugin](https://github.com/mgmeyers/obsidian-kanban): the
markdown-kanban convention of `##` lists and `- [ ]` cards
- [GitHub Flavored Markdown: task list items](https://github.github.com/gfm/#task-list-items-extension-):
the `- [ ]` / `- [x]` syntax
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. Get the Markdown file. Any `.md` file written in this shape works, for
example one written by hand, a WeKan Markdown export, or a markdown-kanban
tool's board file opened in a text editor.
2. In WeKan, go to **All Boards → New → Import → Markdown**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Markdown**.
3. Open the file in a text editor, copy all of it and paste it into the text
box.
4. Click **Import**.
5. Read the loss report on the import page. It is also kept in **Admin Panel →
Problems → Recovery**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Markdown**, then under **Import many boards**
choose several `.md` files, or one `.zip` that holds them.
@@ -47,7 +66,7 @@ python3 api.py importboardsfrom markdown FILE_OR_DIR ...
Each argument is a file, a directory of files, or a `.zip` file.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Choose what to include, then under **JSON** choose **Markdown**. The board
@@ -58,7 +77,7 @@ Each argument is a file, a directory of files, or a `.zip` file.
The Markdown entry is offered for a whole board only, not for a swimlane or a
list.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Markdown**.
@@ -74,7 +93,92 @@ From a script:
python3 api.py exportallboards markdown boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom markdown board.md # POST /api/boards/import/markdown
python3 api.py importboardsfrom markdown FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID markdown board.md
python3 api.py exportallboards markdown boards.zip
```
The HTTP routes:
- `POST /api/boards/import/markdown` with the file's text as `board`;
- `GET /api/boards/:boardId/export/markdown?authToken=…` returns the file as
`text/markdown`;
- `GET /api/export-all-boards/markdown?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How the numbers are calculated
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/markdownKanbanFormat.js](../../../../../../models/lib/markdownKanbanFormat.js).
The tests that pin it:
[tests/boardExportScope.test.cjs](../../../../../../tests/boardExportScope.test.cjs),
[tests/importLossReport.test.cjs](../../../../../../tests/importLossReport.test.cjs),
[tests/markdownImportExport.test.cjs](../../../../../../tests/markdownImportExport.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
The format is the convention markdown-kanban tools (for example Obsidian
Kanban) use: `## List` headings with `- [ ]` / `- [x]` items.
@@ -122,7 +226,7 @@ What the export writes (`formatMarkdownKanban` in
- Each checklist item as an indented `- [ ]` / `- [x]` line.
- Archived cards and archived lists are not exported.
## What is kept
### What is kept
| Markdown | WeKan |
| --- | --- |
@@ -135,7 +239,7 @@ What the export writes (`formatMarkdownKanban` in
| `@{day}` `@@{time}`, `📅 day`, `due:day` | Due date |
| Indented `- [ ]` / `- [x]` under an item | Checklist item |
## What is not kept
### What is not kept
The import reports, on the loss report, every non-blank line that is not a
heading, a card or an indented line under a card (for example a numbered list
@@ -149,24 +253,7 @@ letter, other dates, members, comments, custom fields, attachments, blank
lines inside a description, or lists without cards. A card's checklists come
back as one checklist.
## REST API
```bash
python3 api.py importboardfrom markdown board.md # POST /api/boards/import/markdown
python3 api.py importboardsfrom markdown FILE_OR_DIR ... # several boards
python3 api.py exportboardformat BOARDID markdown board.md
python3 api.py exportallboards markdown boards.zip
```
The HTTP routes:
- `POST /api/boards/import/markdown` with the file's text as `board`;
- `GET /api/boards/:boardId/export/markdown?authToken=…` returns the file as
`text/markdown`;
- `GET /api/export-all-boards/markdown?authToken=…` returns the `.zip`; add
`&boardIds=ID1,ID2` for only those boards.
## How it is built and tested
### How it is built and tested
- `parseMarkdownKanban` in `models/lib/externalParsers.js` reads the file.
`models/lib/markdownKanbanFormat.js` writes it.
@@ -180,12 +267,9 @@ The HTTP routes:
link for every format, and "markdown: multiline Unicode text survives real
file or text import".
## Sources
## Commits
- [Obsidian Kanban plugin](https://github.com/mgmeyers/obsidian-kanban): the
markdown-kanban convention of `##` lists and `- [ ]` cards
- [GitHub Flavored Markdown: task list items](https://github.github.com/gfm/#task-list-items-extension-):
the `- [ ]` / `- [x]` syntax
See also: [format coverage](../Format-Coverage.md),
[all formats](../External-Tools.md).
- [Markdown: #tags, due dates and indented checkboxes are labels, due dates and checklists, both ways](https://github.com/wekan/wekan/commit/10caa20b094beae76ce941e609c7f130e6dd7d5f)
- [The Markdown, Obsidian, OPML and Org mode outlines and the Notion CSV are written a page of cards at a time](https://github.com/wekan/wekan/commit/ce40b56abdf5b166f523dab98a14414907809b1f)
- [Import and export boards as Notion Markdown & CSV exports](https://github.com/wekan/wekan/commit/b7d3274780989c8169549507e416c60316d70ccf)
- [Add Markdown import/export and give GitHub-style import loss reporting](https://github.com/wekan/wekan/commit/237b4f3f883b9e0bcf3a05a82eb7325cb9c00439)
@@ -1,19 +1,33 @@
# Mattermost
## What it is
WeKan imports a Mattermost bulk export as a board for **Board View →
Chat**, and exports a board as a bulk import file Mattermost reads. A channel
is a card and its posts are the card's comments.
## How to import
## Read more
- [Wikipedia: Mattermost, the chat app](https://en.wikipedia.org/wiki/Mattermost)
- [Mattermost bulk export](https://docs.mattermost.com/manage/bulk-export-tool.html)
- [Mattermost bulk loading data](https://docs.mattermost.com/onboard/bulk-loading-data.html)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. On the Mattermost server, run `mmctl export create`, then
`mmctl export download` and take the `.jsonl` file from the zip.
2. In WeKan, go to **All Boards → New → Import → Mattermost**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Mattermost**.
3. Choose the `.jsonl` file, or paste its text.
4. Map the users to WeKan members, or leave them as they are.
5. Click **Import**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Mattermost**, then under **Import many boards**
choose several files, or one `.zip` that holds them.
@@ -30,7 +44,7 @@ From a script:
python3 api.py importboardsfrom mattermost FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Mattermost**.
The board downloads as `<board>.jsonl`.
@@ -42,7 +56,7 @@ list as the purpose), the card's description and comments as posts, and a user
per author with the address `<username>@wekan.invalid`, so the import never
joins them to existing accounts by e-mail.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Mattermost**.
@@ -54,7 +68,88 @@ From a script:
python3 api.py exportallboards mattermost boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/mattermost` with the file's text, or a
`.zip` as `{ "zipBase64": "..." }`, as for every source of the import page.
- Export: `GET /api/boards/:boardId/export/mattermost`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 200,000 messages. Anything past it is left out. (`MAX_CHAT_MESSAGES`
in
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js#L38))
- The chat export text: at most 134,217,728 characters (128 MB of text). More
stops the import with an error. (`MAX_CHAT_TEXT_LENGTH` in
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js#L39))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js),
[models/lib/importedReactions.js](../../../../../../models/lib/importedReactions.js).
The tests that pin it:
[tests/chatExportFormats.test.cjs](../../../../../../tests/chatExportFormats.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
Bulk export JSONL: a `version` line, then `team`, `channel`, `user`, `post`
and `direct_channel` / `direct_post` lines; a post carries its `replies`
@@ -62,18 +157,23 @@ and `direct_channel` / `direct_post` lines; a post carries its `replies`
the list **Channels**, private ones **Groups**, direct messages **Direct
messages**; a reply starts with `↳`.
## What is kept
### What is kept
Channels with header and purpose, posts and replies with author and time, teams.
## Replies
### What is not kept
Attachments (counted), custom emoji, users' profiles and preferences. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
### Replies
A reply, found by the post it is nested in, is a reply to the comment of the message it answers,
one level deep as WeKan's replies are: a reply to a reply goes under the same
comment. A reply to a message that is not in the file is a comment of its own,
starting with "↳".
## Reactions
### Reactions
A message's reactions become the comment's reactions, read from Mattermost's `emoji_name`, such as `+1` or `tada`.
WeKan keeps a reaction by who reacted, so a reaction is kept for each person
@@ -83,22 +183,14 @@ store: a shortcode WeKan does not know, a server's or a chat's own emoji, or an
emoji of several code points (a skin tone, a flag). See
`models/lib/importedReactions.js`.
## What is not kept
Attachments (counted), custom emoji, users' profiles and preferences. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/mattermost` with the file's text, or a
`.zip` as `{ "zipBase64": "..." }`, as for every source of the import page.
- Export: `GET /api/boards/:boardId/export/mattermost`.
## How it is built and tested
### How it is built and tested
`tests/chatExportFormats.test.cjs` reads a bulk export with a team, a channel, a reply and a direct post, refuses a file without a version line and a line that is not JSON, and exports a board and reads it back.
## Sources
## Commits
- [Mattermost bulk export](https://docs.mattermost.com/manage/bulk-export-tool.html)
- [Mattermost bulk loading data](https://docs.mattermost.com/onboard/bulk-loading-data.html)
- [Chat imports keep reactions: Slack, Mattermost, Telegram and Discord reactions become the comments' reactions](https://github.com/wekan/wekan/commit/f467e31d176a2be66cfffecd87d9ac9938ff0d93)
- [Focalboard and Mattermost exports are written a page of cards at a time](https://github.com/wekan/wekan/commit/bad71f9a1e80f54472c87eb8605d5a4206185ea4)
- [Uploaded JSON is parsed from the file a chunk at a time; a Mattermost export a line at a time](https://github.com/wekan/wekan/commit/640e4925935e3842e00a864057b083b6dc386031)
- [Import and export mail, calendars, chats and notes: mbox/.eml, iCalendar, Google Takeout, Slack, Mattermost, Telegram ](https://github.com/wekan/wekan/commit/ccfa6cf362e9b1eb812804d38e4d85653c5b0b0a)
- [Import and export boards as Focalboard (Mattermost Boards) archive text](https://github.com/wekan/wekan/commit/5d26e9fff8b1a873f032019bfd7cc5c4e68b66d1)
@@ -1,12 +1,31 @@
# MeisterTask
## What it is
WeKan imports boards from [MeisterTask](https://www.meistertask.com) and
exports boards to it as a MeisterTask project CSV file. WeKan reads both CSV
shapes MeisterTask uses: the one its project export writes, and the one its
CSV import reads. WeKan exports the import shape, so MeisterTask can read the
file back. Sections become lists and tasks become cards.
## How to import
## Read more
- [Wikipedia: kanban boards](https://en.wikipedia.org/wiki/Kanban_board)
- [Export Project Data](https://support.meistertask.com/hc/en-us/articles/4403317110290-Export-Project-Data):
the export steps and the export's columns
- [Import Projects Into MeisterTask](https://support.meistertask.com/hc/en-us/articles/4403323243538-Import-Projects-Into-MeisterTask):
the import steps and the sample file's columns
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In MeisterTask, click the project name at the top of the project board and
choose **Export project**.
@@ -15,7 +34,7 @@ file back. Sections become lists and tasks become cards.
3. When the notification on the Dashboard says the file is ready, click
**Download Now**.
4. Open the CSV file in a text editor and copy all of it.
5. In WeKan, go to **All Boards → New → Import → MeisterTask**.
5. In WeKan, go to **All Boards → Add Board → Import → Import board → MeisterTask**.
6. Paste the text into the box and click **Import**. A **Map members** step
follows with nobody to map: click **Done**. (**Import without mapping
members (map later)** skips that step.)
@@ -25,7 +44,7 @@ file back. Sections become lists and tasks become cards.
A CSV file written for MeisterTask's own import, such as its sample file,
imports the same way.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **MeisterTask**, then under **Import many
boards** choose several CSV files, or one `.zip` that holds them. Each file
@@ -48,7 +67,7 @@ python3 api.py importboardsfrom meistertask FILE_OR_DIR ...
The arguments are files, directories of files, or `.zip` files.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include**, choose what to export, then click
@@ -60,7 +79,7 @@ The arguments are files, directories of files, or `.zip` files.
the exact steps, see
[Import Projects Into MeisterTask](https://support.meistertask.com/hc/en-us/articles/4403323243538-Import-Projects-Into-MeisterTask).
## How to export all boards at once
### How to export all boards at once
In **All Boards**, open the sidebar and choose **Export all boards**, then
**MeisterTask**. This downloads one `.zip` with one `.csv` file per board you
@@ -76,7 +95,91 @@ From a script:
python3 api.py exportallboards meistertask boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom meistertask project.csv
python3 api.py importboardsfrom meistertask project1.csv project2.csv
python3 api.py exportboardformat BOARDID meistertask project.csv
python3 api.py exportallboards meistertask boards.zip
```
The HTTP routes:
- `POST /api/boards/import/meistertask`: the body is
`{"board": "<CSV text>"}`.
- `GET /api/boards/:boardId/export/meistertask?authToken=…`
- `GET /api/export-all-boards/meistertask?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How the numbers are calculated
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/meistertaskCsvFormat.js](../../../../../../models/lib/meistertaskCsvFormat.js).
The tests that pin it:
[tests/externalExportRoundTrip.test.cjs](../../../../../../tests/externalExportRoundTrip.test.cjs),
[tests/meistertaskCsv.test.cjs](../../../../../../tests/meistertaskCsv.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
What WeKan reads is a MeisterTask project CSV in either shape it uses, matched
by header name:
@@ -129,7 +232,7 @@ The export writes `project,section,name,notes,due_date,status,tags`:
- `status` 2 for a card with an end date, 1 otherwise;
- the labels joined with `; ` (a `;` inside a label becomes `,`).
## What is kept
### What is kept
| MeisterTask | WeKan |
| --- | --- |
@@ -149,7 +252,7 @@ The assignee becomes a card member only when that name is mapped to a WeKan
user, through the REST API's `membersMapping`. The import page maps no one, so
there it is not kept.
## What is not kept
### What is not kept
The import reports these on the loss report, rather than dropping them
silently:
@@ -165,24 +268,7 @@ comments, custom fields, attachments, swimlanes and archived cards. A
completed card is written as status 2 without its completion date, because
the import shape has no column for it.
## REST API
```bash
python3 api.py importboardfrom meistertask project.csv
python3 api.py importboardsfrom meistertask project1.csv project2.csv
python3 api.py exportboardformat BOARDID meistertask project.csv
python3 api.py exportallboards meistertask boards.zip
```
The HTTP routes:
- `POST /api/boards/import/meistertask`: the body is
`{"board": "<CSV text>"}`.
- `GET /api/boards/:boardId/export/meistertask?authToken=…`
- `GET /api/export-all-boards/meistertask?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How it is built and tested
### How it is built and tested
- `models/lib/meistertaskCsvFormat.js` reads and writes the CSV, with the CSV
reader of `models/lib/todoistCsvFormat.js`. `models/lib/externalParsers.js`
@@ -198,12 +284,9 @@ The HTTP routes:
project CSV imports with its sections, notes, due date and tags*, and *every
external export menu link returns text and refuses an unrelated user*.
## Sources
## Commits
- [Export Project Data](https://support.meistertask.com/hc/en-us/articles/4403317110290-Export-Project-Data):
the export steps and the export's columns
- [Import Projects Into MeisterTask](https://support.meistertask.com/hc/en-us/articles/4403323243538-Import-Projects-Into-MeisterTask):
the import steps and the sample file's columns
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
- [Ten more exports are written a page of cards at a time, their references read in a light first pass](https://github.com/wekan/wekan/commit/e2cbbe510457940b6db26c90b45307a6c539a0e7)
- [Read every import source through one path and one file chooser, from one description of the sources](https://github.com/wekan/wekan/commit/c80a656901103bfd29b41843c7e255b4ed3bfa17)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Import and export boards as MeisterTask project CSV](https://github.com/wekan/wekan/commit/804c7183a2d5919e176af8c0436978346c962989)
@@ -1,19 +1,34 @@
# Microsoft Lists
## What it is
WeKan imports a list from [Microsoft Lists](https://www.microsoft.com/microsoft-365/microsoft-lists)
(and SharePoint lists), and exports a board as a CSV file Lists makes a new list
from.
## How to import
## Read more
- [Wikipedia: SharePoint, where Microsoft Lists keeps its lists](https://en.wikipedia.org/wiki/Microsoft_SharePoint)
- [Export to Excel from SharePoint or Lists](https://support.microsoft.com/office/export-to-excel-from-sharepoint-or-lists-bfb2ea48-6118-4fa9-abb6-cced9424e5d9)
- [Create a list based on a spreadsheet](https://support.microsoft.com/sharepoint/lists/data-and-lists/create-a-list-based-on-a-spreadsheet)
- [Create a list from CSV and export to CSV with schema](https://supersimple365.com/new-in-microsoft-lists-create-a-list-from-csv-and-export-to-csv/)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Microsoft Lists, open the list, choose the view whose columns you want,
and choose **Export → Export to CSV** (or **Export to CSV with schema**).
2. In WeKan, go to **All Boards → New → Import → Microsoft Lists**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft Lists**.
3. Choose the `.csv` file, or paste its text.
4. Map the people to WeKan members, or leave them as they are.
5. Click **Import**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft Lists**, then under **Import many boards**
choose several files.
@@ -30,7 +45,7 @@ From a script:
python3 api.py importboardsfrom mslists FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Microsoft
Lists**. The board downloads as `<board>.csv`.
@@ -43,7 +58,7 @@ assignees), Start date and Due date (YYYY-MM-DD), Tags (the labels), Description
and a column per custom field of the board, its name without the characters
Lists does not allow in a column name.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Microsoft Lists**.
@@ -55,7 +70,84 @@ From a script:
python3 api.py exportallboards mslists boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/mslists` with the CSV text.
- Export: `GET /api/boards/:boardId/export/mslists`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 100,000 rows. More stops the import with an error.
(`MAX_MS_LISTS_ROWS` in
[models/lib/msListsCsvFormat.js](../../../../../../models/lib/msListsCsvFormat.js#L37))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/microsoftCsvDates.js](../../../../../../models/lib/microsoftCsvDates.js),
[models/lib/msListsCsvFormat.js](../../../../../../models/lib/msListsCsvFormat.js).
The tests that pin it:
[tests/msListsCsv.test.cjs](../../../../../../tests/msListsCsv.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
Export to CSV writes the view's columns by their display names, Title first in
most lists; a Person column is the display name (with schema: the address),
@@ -66,7 +158,7 @@ schema, ISO 8601 (`models/lib/msListsCsvFormat.js`,
by a Choice column; WeKan takes the first of Status, Progress, Stage, State,
Bucket or Board column as the lists.
## What is kept
### What is kept
Items as cards in the lists of their Status (or Progress, ...) column, Title,
Description (or Notes, Details, Comments), Assigned to (or Owner, Assignee) as
@@ -74,7 +166,7 @@ the owner and assignees, Created By as "requested by", the start, due, created
and completed dates, Tags (or Category, Labels) as labels, ID as the card's
reference, and every other column as a custom field (Yes/No as true or false).
## What is not kept
### What is not kept
SharePoint's own columns - Modified, Modified By, Item Type, Path, Content
Type, Version, Attachments, Compliance Asset Id and the retention labels - are
@@ -82,20 +174,13 @@ reported. Attachments, comments and the list's formatting are not in the CSV.
On export: comments, checklists and attachments. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/mslists` with the CSV text.
- Export: `GET /api/boards/:boardId/export/mslists`.
## How it is built and tested
### How it is built and tested
`tests/msListsCsv.test.cjs` reads the Issue tracker template's export with
several people and dates, the Work progress tracker's Progress column with
`;#` people and a Yes/No column, writes a board with custom fields and reads it
back, and refuses a file without items.
## Sources
## Commits
- [Export to Excel from SharePoint or Lists](https://support.microsoft.com/office/export-to-excel-from-sharepoint-or-lists-bfb2ea48-6118-4fa9-abb6-cced9424e5d9)
- [Create a list based on a spreadsheet](https://support.microsoft.com/sharepoint/lists/data-and-lists/create-a-list-based-on-a-spreadsheet)
- [Create a list from CSV and export to CSV with schema](https://supersimple365.com/new-in-microsoft-lists-create-a-list-from-csv-and-export-to-csv/)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
@@ -1,14 +1,30 @@
# Microsoft OneNote
## What it is
WeKan imports a notebook of [Microsoft OneNote](https://www.microsoft.com/microsoft-365/onenote),
fetched from Microsoft Graph, and exports a board as OneNote pages.
## How to import
## Read more
- [Wikipedia: Microsoft OneNote](https://en.wikipedia.org/wiki/Microsoft_OneNote)
- [OneNote API overview](https://learn.microsoft.com/graph/integrate-with-onenote)
- [Get OneNote content and structure](https://learn.microsoft.com/graph/onenote-get-content)
- [Create OneNote pages](https://learn.microsoft.com/graph/onenote-create-page)
- [Use note tags in OneNote pages](https://learn.microsoft.com/graph/onenote-note-tags)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Microsoft Graph Explorer (developer.microsoft.com/graph/graph-explorer),
sign in, consent to the **Notes.Read** permission and copy the token from the
**Access token** tab.
2. In WeKan, go to **All Boards → New → Import → Microsoft OneNote**, paste the
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft OneNote**, paste the
token and click **List**. The token is used for this fetch only and is not
stored.
3. Choose a notebook and click **Fetch**, then **Import**.
@@ -16,7 +32,7 @@ fetched from Microsoft Graph, and exports a board as OneNote pages.
The `.zip` WeKan exports for OneNote, or the JSON a fetch returns, can be
chosen as a file instead.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft OneNote**, then under **Import many boards**
choose several files.
@@ -33,7 +49,7 @@ From a script:
python3 api.py importboardsfrom onenote FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Microsoft
OneNote**. The board downloads as `<board>.zip`.
@@ -46,7 +62,7 @@ A list is a section, a card a page: its title, created time, description as
paragraphs and checklist items as to-do boxes, ticked when done; a subtask is a
subpage of its parent.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Microsoft OneNote**.
@@ -58,7 +74,92 @@ From a script:
python3 api.py exportallboards onenote boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/onenote` with the JSON, or `{ "zipBase64": "..." }` for the `.zip`.
- Export: `GET /api/boards/:boardId/export/onenote`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 5,000 API requests. More stops the import with an error.
(`MAX_ONENOTE_REQUESTS` in
[models/lib/apiImport/onenote.js](../../../../../../models/lib/apiImport/onenote.js#L11))
- At most 20,000 pages. More stops the import with an error.
(`MAX_ONENOTE_PAGES` in
[models/lib/apiImport/onenote.js](../../../../../../models/lib/apiImport/onenote.js#L12))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
- **Reading from the service's API**: each request may take 30 seconds and
answer at most 32 MB, with no redirects followed
([server/lib/apiImportRequest.js](../../../../../../server/lib/apiImportRequest.js));
each text field read is cut to 4,096 characters
([models/lib/apiImportServices.js](../../../../../../models/lib/apiImportServices.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/apiImport/onenote.js](../../../../../../models/lib/apiImport/onenote.js),
[models/lib/onenoteApiFormat.js](../../../../../../models/lib/onenoteApiFormat.js).
The tests that pin it:
[tests/onenoteApiImport.test.cjs](../../../../../../tests/onenoteApiImport.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
Graph lists the notebooks (`/me/onenote/notebooks`), their sections and each
section's pages (title, level, order, createdDateTime); a page's content is its
@@ -68,26 +169,21 @@ files, and a note tag as `data-tag` on an element - `to-do` an open to-do box,
`to-do:completed` a ticked one (`models/lib/onenoteApiFormat.js`,
`models/lib/apiImport/onenote.js`).
## What is kept
### What is kept
Sections as lists, pages as cards in their order, the page's text as the
description, its to-do boxes as the checklist **To-do**, a subpage (level 1 or
2) as a subtask of the page above it, and the page's created time. A board with
several notebooks would have one swimlane per notebook.
## What is not kept
### What is not kept
Images and files on a page (counted), note tags other than to-do, ink,
formatting and the page's layout. On export: comments, labels, dates other than
the created time and attachments. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/onenote` with the JSON, or `{ "zipBase64": "..." }` for the `.zip`.
- Export: `GET /api/boards/:boardId/export/onenote`.
## How it is built and tested
### How it is built and tested
`tests/onenoteApiImport.test.cjs` reads a page as Graph answers it - with
to-do boxes, another note tag, an image and a file - with a subpage and an
@@ -96,9 +192,10 @@ exported `.zip`; fetches through the API client from a fake Graph; and refuses
data that is not a fetch, a next link to another host and a path the export
does not write.
## Sources
## Commits
- [OneNote API overview](https://learn.microsoft.com/graph/integrate-with-onenote)
- [Get OneNote content and structure](https://learn.microsoft.com/graph/onenote-get-content)
- [Create OneNote pages](https://learn.microsoft.com/graph/onenote-create-page)
- [Use note tags in OneNote pages](https://learn.microsoft.com/graph/onenote-note-tags)
- [Fix CodeQL alerts #609 and #610: a OneNote page's removals are one replace](https://github.com/wekan/wekan/commit/cc4a494185bcb947a4195830887c2bf72a0a98e0)
- [Fix CodeQL alerts #605-#608 in the OneNote and Sandstorm grain formats](https://github.com/wekan/wekan/commit/3f5e4f3f14adb42af5eb486fb393ec143833e392)
- [Import and export Sandstorm grain backups](https://github.com/wekan/wekan/commit/6f3f6cc5a83df1b91a40d6afae261a74cf5b6507)
- [Outlook and OneNote exports: the files are written after the export boundary](https://github.com/wekan/wekan/commit/20c67216fe627eedc72a02c3536aef8024aabb8c)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
@@ -1,21 +1,36 @@
# Microsoft Outlook
## What it is
WeKan imports mail saved from [Microsoft Outlook](https://www.microsoft.com/microsoft-365/outlook)
as `.msg` files, and exports a board as `.eml` messages Outlook opens. The mail
shows in **Board View → Email**.
## How to import
## Read more
- [Wikipedia: Microsoft Outlook](https://en.wikipedia.org/wiki/Microsoft_Outlook)
- [\[MS-CFB\]: Compound File Binary File Format](https://learn.microsoft.com/openspecs/windows_protocols/ms-cfb/53989ce4-7b05-4f8d-829b-d08d6148375b)
- [\[MS-OXMSG\]: Outlook Item (.msg) File Format](https://learn.microsoft.com/openspecs/exchange_server_protocols/ms-oxmsg/b046868c-9fbf-41ae-9ffb-8de2bd4eec82)
- [\[MS-OXPROPS\]: Exchange Server Protocols Master Property List](https://learn.microsoft.com/openspecs/exchange_server_protocols/ms-oxprops/f6ab1613-aefe-447d-a49c-18217230b148)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Outlook (classic), drag a message to a folder on your computer, or choose
**File → Save As** with the type **Outlook Message Format (\*.msg)**. Put
several in a `.zip` to import them together; `.eml` files may be in the same
`.zip`.
2. In WeKan, go to **All Boards → New → Import → Microsoft Outlook (.msg)**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft Outlook (.msg)**.
3. Choose the `.msg` or the `.zip` file.
4. Map the people to WeKan members, or leave them as they are.
5. Click **Import**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft Outlook**, then under **Import many boards**
choose several files.
@@ -32,7 +47,7 @@ From a script:
python3 api.py importboardsfrom outlook FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Microsoft
Outlook (.eml)**. The board downloads as `<board>.zip`.
@@ -43,7 +58,7 @@ A card is a message, and each of its comments a reply to it - the messages of
the **Mail (mbox)** export, one per file. A card that came from mail keeps its
sender, recipients and Message-ID.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Microsoft Outlook (.eml)**.
@@ -55,7 +70,84 @@ From a script:
python3 api.py exportallboards outlook boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/outlook` with `{ "binaryBase64": "..." }` for a `.msg`, or `{ "zipBase64": "..." }` for a `.zip`.
- Export: `GET /api/boards/:boardId/export/outlook`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- One .msg file: at most 64 MB. More stops the import with an error.
(`MAX_MSG_BYTES` in
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js#L30))
- One attachment of a .msg file: at most 32 MB. (`MAX_MSG_ATTACHMENT_BYTES` in
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js#L31))
- The compound-file metadata of a .msg file: at most 64 MB. More stops the
import with an error. (`MAX_CFB_METADATA_BYTES` in
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js#L271))
- The compound file is read in pieces of up to 64 KB. (`RUN_BYTES` in
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js#L272))
- A text property (subject, sender and so on) is read up to 1 MB. (`SMALL_PROP`
in
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js#L416))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/mailFormat.js](../../../../../../models/lib/mailFormat.js),
[models/lib/outlookMsgFormat.js](../../../../../../models/lib/outlookMsgFormat.js).
The tests that pin it:
[tests/outlookMsg.test.cjs](../../../../../../tests/outlookMsg.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
A `.msg` is a Compound File Binary file (\[MS-CFB\]): storages and streams in
512- or 4096-byte sectors chained by a FAT, with small streams in a mini stream.
@@ -68,25 +160,20 @@ body (or the HTML body as text) and the attachments. The messages then go
through the same mail import as an `.mbox` (`models/lib/mailFormat.js`), so a
reply joins its thread.
## What is kept
### What is kept
Each thread as a card in the list **Inbox**: the first message's subject,
sender, recipients, time and body, the replies as comments, and the messages'
attachments as the card's files.
## What is not kept
### What is not kept
An attachment that is itself a message (an embedded `.msg`) and an attachment
larger than 32 MB (counted); the RTF body, categories, flags and reminders.
On export: labels, checklists and attachments. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/outlook` with `{ "binaryBase64": "..." }` for a `.msg`, or `{ "zipBase64": "..." }` for a `.zip`.
- Export: `GET /api/boards/:boardId/export/outlook`.
## How it is built and tested
### How it is built and tested
`tests/outlookMsg.test.cjs` writes `.msg` files with a small Compound File
writer - small streams in the mini stream, a large attachment in FAT sectors -
@@ -95,8 +182,12 @@ a board as `.eml` files and reads them back, and refuses a file that is not a
Compound File and one whose sector chain loops. The reader was also checked
against `.msg` files saved by Outlook.
## Sources
## Commits
- [\[MS-CFB\]: Compound File Binary File Format](https://learn.microsoft.com/openspecs/windows_protocols/ms-cfb/53989ce4-7b05-4f8d-829b-d08d6148375b)
- [\[MS-OXMSG\]: Outlook Item (.msg) File Format](https://learn.microsoft.com/openspecs/exchange_server_protocols/ms-oxmsg/b046868c-9fbf-41ae-9ffb-8de2bd4eec82)
- [\[MS-OXPROPS\]: Exchange Server Protocols Master Property List](https://learn.microsoft.com/openspecs/exchange_server_protocols/ms-oxprops/f6ab1613-aefe-447d-a49c-18217230b148)
- [Attachment slideshow: Outlook .msg and OpenDocument are converted once, a piece at a time, into rows read a screen at a ](https://github.com/wekan/wekan/commit/cd74045a9f453527c6f6eea2ba36bd75c3f955ac)
- [Attachment slideshow: Markdown, CSV, code, iCalendar, Outlook .msg, tar and OpenDocument](https://github.com/wekan/wekan/commit/6d842a5e2fe7242ade92ca19e2ce5a4f9081485d)
- [Import and export Sandstorm grain backups](https://github.com/wekan/wekan/commit/6f3f6cc5a83df1b91a40d6afae261a74cf5b6507)
- [Outlook and OneNote exports: the files are written after the export boundary](https://github.com/wekan/wekan/commit/20c67216fe627eedc72a02c3536aef8024aabb8c)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
- [The .mbox export carries the card labels as Gmail's; the round trip of every export checks labels and due dates](https://github.com/wekan/wekan/commit/c0b3d9013d68ae4ac787655183233935766c5997)
- [Import and export mail, calendars, chats and notes: mbox/.eml, iCalendar, Google Takeout, Slack, Mattermost, Telegram ](https://github.com/wekan/wekan/commit/ccfa6cf362e9b1eb812804d38e4d85653c5b0b0a)
@@ -1,5 +1,7 @@
# Microsoft Planner
## What it is
WeKan imports boards from
[Microsoft Planner](https://www.microsoft.com/microsoft-365/planner) and
exports boards in Planner's layout, as the Excel workbook (`.xlsx`) that
@@ -12,19 +14,38 @@ so there is no live import or sync: the Graph API needs credentials, a
Microsoft Entra app registration and a signed-in Microsoft 365 user, which a
WeKan server does not have.
## How to import
## Read more
- [Wikipedia: Microsoft Planner](https://en.wikipedia.org/wiki/Microsoft_Planner)
- [Export a plan to Excel](https://support.microsoft.com/office/4d850c6e-e548-4aab-83b4-b62b68662d2a):
the export steps and what the workbook holds
- [plannr](https://github.com/program--/plannr): the real Planner export used
as test data (`tests/fixtures/planner/`)
- [Planner API overview](https://learn.microsoft.com/graph/api/resources/planner-overview):
the Microsoft Graph API, which needs credentials and is not used
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Planner, open the plan, open the **...** menu next to the plan's name
and choose **Export as Excel** (classic Planner calls it **Export plan to
Excel**). The `.xlsx` file downloads to your Downloads folder.
2. In WeKan, go to **All Boards → New → Import → Microsoft Planner**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft Planner**.
3. Choose the `.xlsx` file and click **Import**. Under **People in the file**, choose whether
Planner's people become existing users you pick, placeholder users with
their own names, or you.
4. Read the loss report on the import page. It is also kept in **Admin Panel →
Problems → Recovery**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft Planner**, then under **Import many
boards** choose several `.xlsx` files, or one `.zip` that holds them. Each
@@ -47,7 +68,7 @@ python3 api.py importboardsfrom planner FILE_OR_DIR ...
The arguments are files, directories of files, or `.zip` files.
## How to export
### How to export
1. In WeKan, open the board, then **Board Settings → Export**.
2. Under **Select what to include**, choose what to export, then click
@@ -58,7 +79,7 @@ The arguments are files, directories of files, or `.zip` files.
imports it back. Creating Planner tasks from it needs a tool outside
Planner's own pages; see Microsoft's Planner documentation.
## How to export all boards at once
### How to export all boards at once
In **All Boards**, open the sidebar and choose **Export all boards**, then
**Microsoft Planner**. This downloads one `.zip` with one `.xlsx` file per
@@ -74,7 +95,99 @@ From a script:
python3 api.py exportallboards planner boards.zip
```
## Format details
### REST API
```bash
python3 api.py importboardfrom planner plan.xlsx
python3 api.py importboardsfrom planner plan1.xlsx plan2.xlsx
python3 api.py exportboardformat BOARDID planner plan.xlsx
python3 api.py exportallboards planner boards.zip
```
The HTTP routes:
- `POST /api/boards/import/planner`: the body is
`{"board": {"excelBase64": "<the .xlsx file in base64>"}}`.
- `GET /api/boards/:boardId/export/planner?authToken=…`
- `GET /api/export-all-boards/planner?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 20,000 rows. More stops the import with an error. (`MAX_PLANNER_ROWS`
in
[models/lib/plannerFormat.js](../../../../../../models/lib/plannerFormat.js#L48))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/plannerFormat.js](../../../../../../models/lib/plannerFormat.js),
[server/lib/plannerWorkbook.js](../../../../../../server/lib/plannerWorkbook.js).
The tests that pin it:
[tests/externalExportRoundTrip.test.cjs](../../../../../../tests/externalExportRoundTrip.test.cjs),
[tests/plannerFormat.test.cjs](../../../../../../tests/plannerFormat.test.cjs),
[tests/plannerInstructionTranslations.test.cjs](../../../../../../tests/plannerInstructionTranslations.test.cjs),
[tests/playwright/specs/import-export-format-audit.e2e.js](../../../../../../tests/playwright/specs/import-export-format-audit.e2e.js).
The details of the format, what is kept and how it is tested are below.
### Format details
What WeKan reads is the workbook Planner's
[Export plan to Excel](https://support.microsoft.com/office/4d850c6e-e548-4aab-83b4-b62b68662d2a)
@@ -146,7 +259,7 @@ The export writes the same sheet:
- the owner, then the other assignees, in **Assigned To**, separated by `;`;
- the creator (or Requested by) as **Created By**.
## What is kept
### What is kept
| Planner | WeKan |
| --- | --- |
@@ -169,7 +282,7 @@ Assigned To becomes card members only when those names are mapped to WeKan
users, through the REST API's `membersMapping`. The import page maps no one,
so there they are not kept.
## What is not kept
### What is not kept
The import reports these on the loss report, rather than dropping them
silently:
@@ -187,24 +300,7 @@ The export leaves out comments, attachments, swimlanes, archived cards, lists
and swimlanes, and custom fields other than Progress, Priority and Completed
By. Several checklists become one list of items.
## REST API
```bash
python3 api.py importboardfrom planner plan.xlsx
python3 api.py importboardsfrom planner plan1.xlsx plan2.xlsx
python3 api.py exportboardformat BOARDID planner plan.xlsx
python3 api.py exportallboards planner boards.zip
```
The HTTP routes:
- `POST /api/boards/import/planner`: the body is
`{"board": {"excelBase64": "<the .xlsx file in base64>"}}`.
- `GET /api/boards/:boardId/export/planner?authToken=…`
- `GET /api/export-all-boards/planner?authToken=…`, with
`&boardIds=ID1,ID2` for selected boards only.
## How it is built and tested
### How it is built and tested
- `models/lib/plannerFormat.js` reads and writes the rows.
`server/lib/plannerWorkbook.js` opens and writes the workbook with ExcelJS.
@@ -223,14 +319,17 @@ The HTTP routes:
unrelated user*, and *Microsoft Planner: an exported plan imports through
the page*.
## Sources
## Commits
- [Export a plan to Excel](https://support.microsoft.com/office/4d850c6e-e548-4aab-83b4-b62b68662d2a):
the export steps and what the workbook holds
- [plannr](https://github.com/program--/plannr): the real Planner export used
as test data (`tests/fixtures/planner/`)
- [Planner API overview](https://learn.microsoft.com/graph/api/resources/planner-overview):
the Microsoft Graph API, which needs credentials and is not used
See also the [format coverage](../Format-Coverage.md) and
[all formats](../External-Tools.md).
- [Planner: the newer "Export as Excel" column names are read too; Linear is checked against its importer](https://github.com/wekan/wekan/commit/d3aa34e7b8f5d579fabb0e4df9f06710493fd1f2)
- [Teamwork and Planner workbooks are written a page of cards at a time with ExcelJS's streaming writer](https://github.com/wekan/wekan/commit/a2257442a855ce930cc3ae3a4a5b9fdb16555aa8)
- [Defer ZIP and Excel initialization until first use](https://github.com/wekan/wekan/commit/3df146c164158d65901d0d29ba123282671d6080)
- [Excel-based tool exports work again, and All Boards offers Export all boards in its bar](https://github.com/wekan/wekan/commit/8834cecea9c3db559ccc92da19bf7a0c20196ed4)
- [Read every import source through one path and one file chooser, from one description of the sources](https://github.com/wekan/wekan/commit/c80a656901103bfd29b41843c7e255b4ed3bfa17)
- [Choose who an import's people become, for every import, and stream imported attachments](https://github.com/wekan/wekan/commit/73db241bd4628070ea95f10a83ace8d4c7cd2497)
- [Import and export many boards at once for every format, and document each format in its own directory](https://github.com/wekan/wekan/commit/7858d84e127c2c6cd92134166352b9a4245d4ec2)
- [Finish import instructions in four Portuguese catalogs](https://github.com/wekan/wekan/commit/a846a7961fd978c668e778b506bda0b6cdc0967f)
- [Finish import instructions in nine Spanish catalogs](https://github.com/wekan/wekan/commit/771127e70bb89a7374f6ad0b75f29bcf103c07db)
- [Finish import instructions in five French catalogs](https://github.com/wekan/wekan/commit/7d52e278f32aee6f8c1e796cb1ad665b884c7484)
- [Import and export boards as monday.com Excel workbooks](https://github.com/wekan/wekan/commit/1ceaad80f48ff5133af4f0dc6a5443761c274e89)
- [Import and export boards as Microsoft Planner Excel workbooks](https://github.com/wekan/wekan/commit/7ef5b875fa24edc99a4a4a7c37d1d2cad2c88c51)
@@ -1,20 +1,34 @@
# Microsoft Project
## What it is
WeKan imports a plan saved by [Microsoft Project](https://www.microsoft.com/microsoft-365/project/project-management-software)
as XML, and exports a board as a plan Project opens. ProjectLibre and
GanttProject read and write the same XML. The `.mpp` file itself is a closed
binary format and is not read.
## How to import
## Read more
- [Wikipedia: Microsoft Project](https://en.wikipedia.org/wiki/Microsoft_Project)
- [Microsoft Project XML schema (MSPDI)](https://learn.microsoft.com/office-project/xml-data-interchange/introduction-to-project-xml-data)
- [Project XML elements: Task](https://learn.microsoft.com/office-project/xml-data-interchange/task-element)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
1. In Microsoft Project, choose **File → Save As**, and as the type **XML
Format (\*.xml)**.
2. In WeKan, go to **All Boards → New → Import → Microsoft Project (XML)**.
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft Project (XML)**.
3. Choose the `.xml` file, or paste its text.
4. Map the people to WeKan members, or leave them as they are.
5. Click **Import**.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft Project (XML)**, then under **Import many boards**
choose several files.
@@ -31,7 +45,7 @@ From a script:
python3 api.py importboardsfrom msproject FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Microsoft
Project (XML)**. The board downloads as `<board>.xml`.
@@ -45,7 +59,7 @@ neither); a card in a list named done or complete is 100 % complete, a card
with the label Milestone a milestone, the people its resources, and what blocks
a card its finish-to-start predecessors.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Microsoft Project (XML)**.
@@ -57,7 +71,92 @@ From a script:
python3 api.py exportallboards msproject boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/msproject` with the XML text.
- Export: `GET /api/boards/:boardId/export/msproject`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- The Project XML file: at most 67,108,864 characters (64 MB of text). More
stops the import with an error. (`MAX_MS_PROJECT_LENGTH` in
[models/lib/msProjectXmlFormat.js](../../../../../../models/lib/msProjectXmlFormat.js#L38))
- At most 100,000 tasks. More stops the import with an error.
(`MAX_MS_PROJECT_TASKS` in
[models/lib/msProjectXmlFormat.js](../../../../../../models/lib/msProjectXmlFormat.js#L39))
- Nesting deeper than 64 levels is not followed. More stops the import with an
error. (`MAX_DEPTH` in
[models/lib/msProjectXmlFormat.js](../../../../../../models/lib/msProjectXmlFormat.js#L41))
- A task with only a finish or only a start date gets a start or finish one day
(86,400,000 ms) from it. (`DAY` in
[models/lib/msProjectXmlFormat.js](../../../../../../models/lib/msProjectXmlFormat.js#L251))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/msProjectXmlFormat.js](../../../../../../models/lib/msProjectXmlFormat.js).
The tests that pin it:
[tests/msProjectXml.test.cjs](../../../../../../tests/msProjectXml.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
The XML is MSPDI, the schema at `http://schemas.microsoft.com/project`:
`<Project>` with its Name and Title, `<Tasks>` with a `<Task>` per row of the
@@ -68,7 +167,7 @@ level 0 is the project's own summary row. WeKan reads it with a small XML
reader of its own that never resolves a DTD or an entity, so nothing in the file
can make it read another file (`models/lib/msProjectXmlFormat.js`).
## What is kept
### What is kept
Summary tasks at outline level 1 as swimlanes, every other task as a card
(a summary task further down is the parent card of the tasks under it), the
@@ -79,7 +178,7 @@ assignees, predecessors as "blocked by" dependencies, the UID as the card's
reference, and Priority (when not 500), the duration in hours, the percent
complete and WBS as custom fields.
## What is not kept
### What is not kept
Calendars, baselines, extended attributes and the work and cost of
assignments; a link type other than finish-to-start is imported as blocked-by,
@@ -87,12 +186,7 @@ and a link's lag is not kept (both reported). On export: comments, checklists,
labels other than Milestone and attachments. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/msproject` with the XML text.
- Export: `GET /api/boards/:boardId/export/msproject`.
## How it is built and tested
### How it is built and tested
`tests/msProjectXml.test.cjs` reads a plan with phases, a milestone, a
completed task, a nested summary task, resources, assignments and links of two
@@ -100,7 +194,6 @@ types; reads Project's durations; writes a board with lanes, subtasks, people
and a dependency and reads it back; and refuses broken XML, and never expands
a DOCTYPE's entity.
## Sources
## Commits
- [Microsoft Project XML schema (MSPDI)](https://learn.microsoft.com/office-project/xml-data-interchange/introduction-to-project-xml-data)
- [Project XML elements: Task](https://learn.microsoft.com/office-project/xml-data-interchange/task-element)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
@@ -1,10 +1,27 @@
# Microsoft Teams
## What it is
WeKan imports chats and channels of [Microsoft Teams](https://www.microsoft.com/microsoft-teams),
fetched from Microsoft Graph or from an export file, and exports a board as
Teams chats. They show in **Board View → Chat**.
## How to import
## Read more
- [Wikipedia: Microsoft Teams](https://en.wikipedia.org/wiki/Microsoft_Teams)
- [chatMessage resource type](https://learn.microsoft.com/graph/api/resources/chatmessage)
- [List messages in a chat](https://learn.microsoft.com/graph/api/chat-list-messages)
- [List channel messages](https://learn.microsoft.com/graph/api/channel-list-messages)
- [Import third-party platform messages to Teams](https://learn.microsoft.com/microsoftteams/platform/graph-api/import-messages/import-external-messages-to-teams)
- [Export options for switching from Microsoft Teams](https://learn.microsoft.com/microsoftteams/migration-from-teams)
## How to use it
Each task has its own steps below: importing one board, importing many
boards at once, exporting one board, exporting all boards at once, and the
same from a script through the REST API.
### How to import
Fetch them (a work or school account):
@@ -12,7 +29,7 @@ Fetch them (a work or school account):
sign in, consent to **Chat.Read** (and, for channels, **Team.ReadBasic.All**,
**Channel.ReadBasic.All** and **ChannelMessage.Read.All**, which needs an
administrator's consent), and copy the token from the **Access token** tab.
2. In WeKan, go to **All Boards → New → Import → Microsoft Teams**, paste the
2. In WeKan, go to **All Boards → Add Board → Import → Import board → Microsoft Teams**, paste the
token and click **List**. The token is used for this fetch only and is not
stored.
3. Choose a chat or a channel and click **Fetch**, then **Import**.
@@ -26,7 +43,7 @@ Or choose a file:
Teams Export API's `messages_<user>.json`;
- the `.json` or `.zip` WeKan exports.
## How to import many boards at once
### How to import many boards at once
1. On the import page, choose **Microsoft Teams**, then under **Import many boards**
choose several files.
@@ -43,7 +60,7 @@ From a script:
python3 api.py importboardsfrom teams FILE_OR_DIR ...
```
## How to export
### How to export
1. Open the board, then **Board Settings → Export**, and choose **Microsoft
Teams**. The board downloads as `<board>.json`.
@@ -56,7 +73,7 @@ A card is a chat, its comments the messages, each a Graph chat message with
its author, time and HTML body; the card's description, list and swimlane are
kept beside the chat.
## How to export all boards at once
### How to export all boards at once
1. In WeKan, go to **All Boards**, open the sidebar and choose **Export all
boards**, then **Microsoft Teams**.
@@ -68,7 +85,105 @@ From a script:
python3 api.py exportallboards teams boards.zip
```
## Format details
### REST API
- Import: `POST /api/boards/import/teams` with the JSON, `{ "binaryBase64": "..." }` for a `.tar`, or `{ "zipBase64": "..." }` for a `.zip`.
- Export: `GET /api/boards/:boardId/export/teams`.
## How the numbers are calculated
The limits and conversions of this format, from its own code:
- At most 2,000 API requests. (`MAX_TEAMS_REQUESTS` in
[models/lib/apiImport/teams.js](../../../../../../models/lib/apiImport/teams.js#L14))
- At most 200,000 messages. (`MAX_TEAMS_MESSAGES` in
[models/lib/apiImport/teams.js](../../../../../../models/lib/apiImport/teams.js#L15))
- At most 200,000 messages. Anything past it is left out. (`MAX_CHAT_MESSAGES`
in
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js#L38))
- The chat export text: at most 134,217,728 characters (128 MB of text). More
stops the import with an error. (`MAX_CHAT_TEXT_LENGTH` in
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js#L39))
- One binary file: at most 64 MB. (`MAX_BINARY_BYTES` in
[server/lib/microsoftArchives.js](../../../../../../server/lib/microsoftArchives.js#L10))
- The .tar file: at most 2 GB. More stops the import with an error.
(`MAX_TAR_BYTES` in
[server/lib/microsoftArchives.js](../../../../../../server/lib/microsoftArchives.js#L11))
- The JSON file: at most 256 MB. More stops the import with an error.
(`MAX_JSON_BYTES` in
[server/lib/microsoftArchives.js](../../../../../../server/lib/microsoftArchives.js#L12))
The numbers every import has, this one included:
- **How long an import may take**: `WEKAN_IMPORT_TIMEOUT_MS` (default 120,000
ms, two minutes; 0 turns the deadline off) plus 500 ms for each record of the
file. A record is an item of a top-level array, a line of a text file, or the
items of all top-level arrays of an object added together
([models/lib/importDeadline.js](../../../../../../models/lib/importDeadline.js),
[models/import.js](../../../../../../models/import.js)).
- **Many boards at once**: at most 500 files and 200 MB together
(`MAX_MANY_FILES`, `MAX_MANY_BYTES` in
[models/lib/importManyFiles.js](../../../../../../models/lib/importManyFiles.js)).
- **One board per project**: at most 200 boards from one file
(`MAX_SPLIT_BOARDS` in
[models/lib/importSplit.js](../../../../../../models/lib/importSplit.js)).
- **The loss report** counts what was not imported and the warnings, and lists
the first 20 of them, each cut to 200 characters, then "and N more"
([models/lib/importLossReport.js](../../../../../../models/lib/importLossReport.js)).
- **Every document** passes the one import and export boundary: at most 40
levels deep, 4,000,000 values, 100,000 items in one array and 4 MB in one
string
([models/lib/importExportBoundary.js](../../../../../../models/lib/importExportBoundary.js)).
- **Reading from the service's API**: each request may take 30 seconds and
answer at most 32 MB, with no redirects followed
([server/lib/apiImportRequest.js](../../../../../../server/lib/apiImportRequest.js));
each text field read is cut to 4,096 characters
([models/lib/apiImportServices.js](../../../../../../models/lib/apiImportServices.js)).
## How it works in WeKan
An import is sent to the `importBoard` Meteor method in
[models/import.js](../../../../../../models/import.js). It checks the types of
every argument first, refuses a caller who is not logged in (and records that
attempt in Admin Panel → Problems), stops when Admin Panel has turned import off
([models/lib/importExportSecurity.js](../../../../../../models/lib/importExportSecurity.js)),
and asks
[server/lib/boardCreationGuard.js](../../../../../../server/lib/boardCreationGuard.js)
whether this user may create a board; an import into the current board replaces
it only for a board admin. The import sources and their file types are described
once, in
[models/lib/importSources.js](../../../../../../models/lib/importSources.js).
The file is read by this format's parser into one Kanboard-shaped board
(`EXTERNAL_PARSERS` in
[models/lib/externalParsers.js](../../../../../../models/lib/externalParsers.js)),
which [models/kanboardCreator.js](../../../../../../models/kanboardCreator.js)
writes as a WeKan board: the Boards, Swimlanes, Lists, Cards, Checklists,
ChecklistItems, CardComments and Attachments collections.
An export is a GET route of the REST API, the ones listed under REST API above:
a board's export is served by
[models/export.js](../../../../../../models/export.js)
(`/api/boards/:boardId/export/<format>` for the formats of other tools) or by
this format's own code below, and all boards at once by
`/api/export-all-boards/<format>`
([server/routes/exportAllBoards.js](../../../../../../server/routes/exportAllBoards.js)).
They stop first when Admin Panel has turned export off, need a logged-in user,
and export only a board that user may see; a member who sees only the cards
assigned to them gets no board-wide export
([models/lib/exportAccess.js](../../../../../../models/lib/exportAccess.js)).
This format's own code:
[models/lib/apiImport/teams.js](../../../../../../models/lib/apiImport/teams.js),
[models/lib/chatExportFormats.js](../../../../../../models/lib/chatExportFormats.js),
[server/lib/microsoftArchives.js](../../../../../../server/lib/microsoftArchives.js).
The tests that pin it:
[tests/teamsApiImport.test.cjs](../../../../../../tests/teamsApiImport.test.cjs).
The details of the format, what is kept and how it is tested are below.
### Format details
A chat message of Microsoft Graph v1.0 has an id, replyToId, messageType
(`message`, the others being system events), createdDateTime, deletedDateTime,
@@ -81,14 +196,14 @@ read as the Skype export it shares its layout with: `conversations`, each with a
(`models/lib/chatExportFormats.js` parseTeamsExport,
`models/lib/apiImport/teams.js`, `server/lib/microsoftArchives.js`).
## What is kept
### What is kept
Each chat or channel as a card in the list Direct messages (oneOnOne), Groups,
Meetings or Channels, in the swimlane of its team; its messages and replies as
comments by their author at their time, the HTML as text, a file attachment as
its name and link, and reactions.
## What is not kept
### What is not kept
System events (calls, members joining) and deleted messages are counted, not
imported; files themselves, mentions as links, and message edits. Graph does
@@ -96,12 +211,7 @@ not serve personal Teams accounts, so their chats come from the personal
export. On export: checklists, labels and attachments. What was left out is listed in the import's loss report, also in
**Admin Panel → Problems → Recovery**.
## REST API
- Import: `POST /api/boards/import/teams` with the JSON, `{ "binaryBase64": "..." }` for a `.tar`, or `{ "zipBase64": "..." }` for a `.zip`.
- Export: `GET /api/boards/:boardId/export/teams`.
## How it is built and tested
### How it is built and tested
`tests/teamsApiImport.test.cjs` reads Graph chat messages with HTML, a file, a
reaction, a system event and a deleted message; a channel with replies; the
@@ -110,10 +220,6 @@ a `.tar`; writes a board and reads it back; and fetches through the API client
from a fake Graph, every page and only from graph.microsoft.com, refusing a next
link to another host.
## Sources
## Commits
- [chatMessage resource type](https://learn.microsoft.com/graph/api/resources/chatmessage)
- [List messages in a chat](https://learn.microsoft.com/graph/api/chat-list-messages)
- [List channel messages](https://learn.microsoft.com/graph/api/channel-list-messages)
- [Import third-party platform messages to Teams](https://learn.microsoft.com/microsoftteams/platform/graph-api/import-messages/import-external-messages-to-teams)
- [Export options for switching from Microsoft Teams](https://learn.microsoft.com/microsoftteams/migration-from-teams)
- [Import and export Azure DevOps Boards, Microsoft Lists, Project, Outlook, Teams and OneNote](https://github.com/wekan/wekan/commit/01e88410cd7440b26c5f845d98ae058f93c16a85)
+10 -2
View File
@@ -208,8 +208,16 @@ async function main() {
await test('the docs page has its sections in order', async () => {
const doc = read('docs/Features/Board-Sidebar/Board-Settings/Import-Export/Google-Tasks/Google-Tasks.md');
const sections = doc.split('\n').filter(line => line.startsWith('## ')).map(line => line.slice(3));
assert.deepEqual(sections, ['How to import', 'How to import many boards at once', 'How to export', 'How to export all boards at once',
'Format details', 'What is kept', 'What is not kept', 'REST API', 'How it is built and tested', 'Sources']);
// Every feature page has the one structure; the steps and the REST API are
// subsections of How to use it, the format details, what is kept and the
// tests subsections of How it works in WeKan, and the sources are under
// Read more (tests/importExportDocsCoverage.test.cjs).
assert.deepEqual(sections, ['What it is', 'Read more', 'How to use it', 'How the numbers are calculated',
'How it works in WeKan', 'Commits']);
const subsections = doc.split('\n').filter(line => line.startsWith('### ')).map(line => line.slice(4));
assert.deepEqual(subsections, ['How to import', 'How to import many boards at once', 'How to export',
'How to export all boards at once', 'REST API', 'Format details', 'What is kept', 'What is not kept',
'How it is built and tested']);
assert.match(doc, /POST \/api\/boards\/import\/googletasks/);
assert.match(read('releases/live-tests/googletasks-import.mjs'), /WEKAN_LIVE_GOOGLE_TASKS_TOKEN/);
assert.doesNotMatch(read('releases/live-tests/googletasks-import.mjs'), /method: '(POST|PUT|PATCH|DELETE)'/, 'the live test only reads');
+3 -1
View File
@@ -271,7 +271,9 @@ async function main() {
assert.match(en['import-board-instruction-kanri'], /Kanri/);
// Its details are on its own page, which the coverage index links.
const docPage = read('docs/Features/Board-Sidebar/Board-Settings/Import-Export/Kanri/Kanri.md');
assert.match(docPage, /^## Format details$/m);
// The format details are a subsection of How it works in WeKan, since every
// feature page took the one structure (tests/importExportDocsCoverage.test.cjs).
assert.match(docPage, /^### Format details$/m);
assert.match(read('docs/Features/Board-Sidebar/Board-Settings/Import-Export/Format-Coverage.md'), /\]\(\.\/Kanri\/Kanri\.md\)/);
});