← ClaudeAtlas

devtolisted

Publish, update and read articles on DEV (dev.to) via the Forem API v1. Use when the user mentions dev.to / DEV Community, publishing a blog post to dev.to, cross-posting an article, updating a published post, or listing their dev.to articles and stats.
AceDataCloud/Skills · ★ 8 · AI & Automation · score 71
Install: claude install-skill AceDataCloud/Skills
Call the **Forem API v1** (dev.to) with `curl + jq`. The user's API key is in `$DEVTO_API_KEY`; every call needs the headers `api-key: $DEVTO_API_KEY` and `Accept: application/vnd.forem.api-v1+json`. Base URL: `https://dev.to/api`. Errors come back as JSON with an `error` / `status` field — show them verbatim. `401` means the API key is invalid → the user must re-connect the DEV connector. **Always start by confirming the key** and learning the account: ```bash curl -sS -H "api-key: $DEVTO_API_KEY" -H "Accept: application/vnd.forem.api-v1+json" \ "https://dev.to/api/users/me" | jq '{username, name}' ``` ## Publish an article **Confirm with the user before publishing publicly.** Default to a draft (`published:false`) unless they explicitly say publish/now. ```bash TITLE="My title" BODY_MD="$(cat article.md)" # full Markdown body jq -n --arg t "$TITLE" --arg b "$BODY_MD" \ '{article:{title:$t, body_markdown:$b, published:false, tags:["ai","webdev"]}}' \ | curl -sS -X POST "https://dev.to/api/articles" \ -H "api-key: $DEVTO_API_KEY" \ -H "Accept: application/vnd.forem.api-v1+json" \ -H "Content-Type: application/json" \ -d @- \ | jq '{id, url, published}' ``` To publish a draft later (or edit), `PUT /api/articles/{id}` with the same shape (set `published:true`). Front-matter inside `body_markdown` (a `---` block) can also carry `title`, `tags`, `series`, `canonical_url`, `cover_image`. - **Canonical URL:** when cross-posting, set `"canonical_url":