Drupal.org API
Developerwww.drupal.org
Read-only REST access to Drupal.org's own content: project issues and releases, security advisories, case studies, forum and documentation nodes, user profiles, comments, files and taxonomy vocabularies from the Drupal Association's site.
Capabilities (6)
GET /v1/data/drupal/comments1 creditReturns the comments attached to a node, with comment id, subject, body, author, timestamps, parent thread and the node they belong to.
GET /v1/data/drupal/file1 creditReturns one file record: fid, filename, MIME type, size in bytes, public download URL, timestamp and owning user.
GET /v1/data/drupal/node1 creditReturns a single node by nid with its full body, author, timestamps, taxonomy terms, issue metadata and attached files.
GET /v1/data/drupal/nodes1 creditReturns Drupal.org nodes of one content type (project issues, project releases, security advisories, case studies, documentation pages) with title, body, author, timestamps, issue status and priority codes, and taxonomy references.
GET /v1/data/drupal/taxonomy-vocabularies1 creditReturns the taxonomy vocabularies used on Drupal.org with their vid, human name, machine name and description: the reference list for the term ids that appear on nodes.
GET /v1/data/drupal/users1 creditReturns Drupal.org user profiles: uid, name, status, created and access timestamps, organisation, industries and Drupal Association membership fields.
Response example
The shape of data from drupal/comments (Comments on a node). A sample, not live data.
Example truncated, full shape in JSON from the API.
{
"self": "https://www.drupal.org/api-d7/comment?node=2773581&limit=20",
"first": "https://www.drupal.org/api-d7/comment?node=2773581&limit=20&page=0",
"last": "https://www.drupal.org/api-d7/comment?node=2773581&limit=20&page=2",
"next": "https://www.drupal.org/api-d7/comment?node=2773581&limit=20&page=1",
"list": [
{
"comment_body": {
"value": "<p>Changed the nid in the example URL which shows the API output of the current page. I guess this page moved but the nid wasn't changed in the example.</p>",
"format": null
},
"cid": "11519121",
"name": "hussainweb",
"homepage": "",
"subject": "",
"url": "https://www.drupal.org/node/2773581/discuss#comment-11519121",
"edit_url": "https://www.drupal.org/comment/edit/11519121",
"created": "1471411191",
"node": {
"uri": "https://www.drupal.org/api-d7/node/2773581",
"id": "2773581",
"resource": "node"
},
"author": {
"uri": "https://www.drupal.org/api-d7/user/314031",
"id": "314031",
"resource": "user"
},
"feeds_item_guid": null,
"feeds_item_url": null,
"feed_nid": null
},
{
"comment_body": {
"value": "<p>Added a client to interact with drupal.org API (my own) with some explanation.</p>",
"format": null
},
"cid": "11519125",
"name": "hussainweb",
"homepage": "",
"subject": "",
"url": "https://www.drupal.org/node/2773581/discuss#comment-11519125",
"edit_url": "https://www.drupal.org/comment/edit/11519125",
"created": "1471411423",
"node": {
"uri": "https://www.drupal.org/api-d7/node/2773581",
"id": "2773581",
"resource": "node"
},
"author": {
"uri": "https://www.drupal.org/api-d7/user/314031",
"id": "314031",
"resource": "user"
},
"feeds_item_guid": null,
"feeds_item_url": null,
"feed_nid": null
},
{
"comment_body": {
"value": "<p>Reverting unrelated change. I'm not sure how it got in, but it was unintentional.</p>",
"format": null
},
"cid": "11519129",
"name": "hussainweb",
"homepage": "",
"subject": "",
"url": "https://www.drupal.org/node/2773581/discuss#comment-11519129",
"edit_url": "https://www.drupal.org/comment/edit/11519129",
"created": "1471411554",
"node": {
"uri": "https://www.drupal.org/api-d7/node/2773581",
"id": "2773581",
"resource": "node"
},
"author": {
"uri": "https://www.drupal.org/api-d7/user/314031",
"id": "314031",
"resource": "user"
},
"feeds_item_guid": null,
"feeds_item_url": null,
"feed_nid": null
},
{
"comment_body": {
"value": "<p>Restored link in explanation to the client library.</p>",
"format": null
},
"cid": "11519135",
"name": "hussainweb",
"homepage": "",
"subject": "",
"url": "https://www.drupal.org/node/2773581/discuss#comment-11519135",
"edit_url": "https://www.drupal.org/comment/edit/11519135",
"created": "1471411718",
"node": {
"uri": "https://www.drupal.org/api-d7/node/2773581",
"id": "2773581",
"resource": "node"
},
"author": {
"uri": "https://www.drupal.org/api-d7/user/314031",
"id": "314031",
"resource": "user"
},
"feeds_item_guid": null,
"feeds_item_url": null,
"feed_nid": null
},
{
"comment_body": {
"value": "<p>Added example for searching the forums, which is a special case.</p>",
"format": null
},
"cid": "11593673",
"name": "rfay",
"homepage": "",
"subject": "",
"url": "https://www.drupal.org/node/2773581/discuss#comment-11593673",
"edit_url": "https://www.drupal.org/comment/edit/11593673",
"created": "Ask with this source
A prompt for your agent that names this source and how to call it through the crw MCP.
Comments on a node
Use Drupal.org API (drupal) from fastCRW Pergamon, capability "Comments on a node" (comments). You are following a specific issue or discussion and want the conversation beneath it. Example options: nid=2773581, limit=20. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "drupal" and capability "comments". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
File metadata
Use Drupal.org API (drupal) from fastCRW Pergamon, capability "File metadata" (file). You have a fid from an issue attachment and need the patch or archive behind it. Example options: fid=4688627. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "drupal" and capability "file". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
One node
Use Drupal.org API (drupal) from fastCRW Pergamon, capability "One node" (node). You hold a nid - from a link, an issue queue or the nodes capability - and need the full record. Example options: nid=2773581. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "drupal" and capability "node". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Nodes by content type
Use Drupal.org API (drupal) from fastCRW Pergamon, capability "Nodes by content type" (nodes). You want to scan a class of Drupal.org content, such as open issues for a contributed module or the latest security advisories. Example options: type=project_issue. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "drupal" and capability "nodes". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Licence
The Drupal.org Terms of Service split content from code: "Content, including user-generated content like comments and discussions (except for the code) on the Website is licensed under Creative Commons License, Attribution-ShareAlike 2.0 except where the content is shared from a third-party source where the license is cited (e.g. Drupal Planet). It is the user's responsibility to obtain appropriate licensing and attribution for content they post to the site. Content without appropriate licensing or attribution will be removed." And: "All code on Drupal.org is licensed under the GNU General Public License version 2 or later." The API returns content (issue text, comments, profiles) rather than code, so CC BY-SA 2.0 governs: commercial use and redistribution are both permitted with attribution and share-alike. The API docs also impose operational rules: "Please use Drupal.org's APIs respectfully. Use an appropriate user agent string. Make requests from a single thread. Cache results locally whenever possible. Abuse will be blocked as needed."
https://www.drupal.org/termsAttribution
Display this wherever you show the data. It arrives on every response as provenance.attribution_text.
Content from Drupal.org, licensed CC BY-SA 2.0. Drupal is a registered trademark of Dries Buytaert. Not affiliated with or endorsed by the Drupal Association.
Cache: up to 3600s
