Base URL
https://app.dmu.email/api/v1
Authentication
Bearer dmk_… API key
Rate limit
120 requests a minute per key

Stop an import

DELETE/mailboxes/{id}/imports

Stops an import once it finishes the batch it’s on. Everything imported by then stays.

Needs the permissionimports:stop

It asks the import to stop rather than cutting it off, so the import shows stopping for a few seconds and then done. Imports go newest first, so stopping early leaves you the most recent mail.

Path parameters

idstringrequired
The mailbox.

Query parameters

runIdstringrequired
The import to stop, from Import history or List imports.

Returns

idstring
The import.
stoppingboolean
Always true.

Errors

400run_id_required
There’s no runId in the query.
401invalid_key
The key is wrong, expired or revoked. With no Authorization header at all, the code is missing_credentials.
403missing_scope
The key doesn’t have imports:stop. The X-Required-Scope header names what’s missing.
429rate_limited
More than 120 requests a minute from this key. Wait for Retry-After seconds.
curl "https://app.dmu.email/api/v1/mailboxes/9e53e6ba/imports?runId=c90f3a17" \
  -X DELETE \
  -H "Authorization: Bearer dmk_7f3a9c2e1b4d_Xq8v…"

Response

200 OK

{
  "data": {
    "id": "c90f3a17",
    "stopping": true
  }
}

Every response wraps its result in data. A page of threads adds nextCursor, which is null on the last page.