From e9b220462ba0436026076ce1180bc421bdf22d66 Mon Sep 17 00:00:00 2001 From: rzmk <30333942+rzmk@users.noreply.github.com> Date: Tue, 2 Dec 2025 19:20:06 -0500 Subject: [PATCH] feat(docs): add all delete endpoints --- docs/content/docs/api_token_revoke.mdx | 20 + docs/content/docs/dataset_purge.mdx | 39 ++ docs/content/docs/group_delete.mdx | 24 + docs/content/docs/group_member_delete.mdx | 24 + docs/content/docs/group_purge.mdx | 43 ++ docs/content/docs/job_cancel.mdx | 24 + docs/content/docs/job_clear.mdx | 24 + docs/content/docs/member_delete.mdx | 24 + docs/content/docs/organization_delete.mdx | 27 + .../docs/organization_member_delete.mdx | 24 + docs/content/docs/organization_purge.mdx | 45 ++ .../docs/package_collaborator_delete.mdx | 34 ++ docs/content/docs/package_delete.mdx | 31 ++ .../docs/package_relationship_delete.mdx | 26 + docs/content/docs/resource_delete.mdx | 24 + docs/content/docs/resource_view_clear.mdx | 20 + docs/content/docs/resource_view_delete.mdx | 20 + docs/content/docs/tag_delete.mdx | 24 + docs/content/docs/task_status_delete.mdx | 24 + docs/content/docs/unfollow_dataset.mdx | 20 + docs/content/docs/unfollow_group.mdx | 20 + docs/content/docs/unfollow_user.mdx | 20 + docs/content/docs/user_delete.mdx | 24 + docs/content/docs/vocabulary_delete.mdx | 24 + docs/lib/openapi.yml | 477 ++++++++++++++++++ 25 files changed, 1106 insertions(+) create mode 100644 docs/content/docs/api_token_revoke.mdx create mode 100644 docs/content/docs/dataset_purge.mdx create mode 100644 docs/content/docs/group_delete.mdx create mode 100644 docs/content/docs/group_member_delete.mdx create mode 100644 docs/content/docs/group_purge.mdx create mode 100644 docs/content/docs/job_cancel.mdx create mode 100644 docs/content/docs/job_clear.mdx create mode 100644 docs/content/docs/member_delete.mdx create mode 100644 docs/content/docs/organization_delete.mdx create mode 100644 docs/content/docs/organization_member_delete.mdx create mode 100644 docs/content/docs/organization_purge.mdx create mode 100644 docs/content/docs/package_collaborator_delete.mdx create mode 100644 docs/content/docs/package_delete.mdx create mode 100644 docs/content/docs/package_relationship_delete.mdx create mode 100644 docs/content/docs/resource_delete.mdx create mode 100644 docs/content/docs/resource_view_clear.mdx create mode 100644 docs/content/docs/resource_view_delete.mdx create mode 100644 docs/content/docs/tag_delete.mdx create mode 100644 docs/content/docs/task_status_delete.mdx create mode 100644 docs/content/docs/unfollow_dataset.mdx create mode 100644 docs/content/docs/unfollow_group.mdx create mode 100644 docs/content/docs/unfollow_user.mdx create mode 100644 docs/content/docs/user_delete.mdx create mode 100644 docs/content/docs/vocabulary_delete.mdx diff --git a/docs/content/docs/api_token_revoke.mdx b/docs/content/docs/api_token_revoke.mdx new file mode 100644 index 0000000..2d58e59 --- /dev/null +++ b/docs/content/docs/api_token_revoke.mdx @@ -0,0 +1,20 @@ +--- +title: api_token_revoke +full: true +_openapi: + method: DELETE + route: api_token_revoke + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete API Token. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete API Token. + + + \ No newline at end of file diff --git a/docs/content/docs/dataset_purge.mdx b/docs/content/docs/dataset_purge.mdx new file mode 100644 index 0000000..4cd93c2 --- /dev/null +++ b/docs/content/docs/dataset_purge.mdx @@ -0,0 +1,39 @@ +--- +title: dataset_purge +full: true +_openapi: + method: DELETE + route: dataset_purge + toc: [] + structuredData: + headings: [] + contents: + - content: > + Purge a dataset. + + + Purging a dataset cannot be + undone! + + + Purging a dataset completely removes the dataset from the CKAN + database, whereas deleting a dataset simply marks the dataset as + deleted (it will no longer show up in the front-end, but is still in + the db). + + + You must be authorized to purge the dataset. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Purge a dataset. + +Purging a dataset cannot be undone! + +Purging a dataset completely removes the dataset from the CKAN database, whereas deleting a dataset simply marks the dataset as deleted (it will no longer show up in the front-end, but is still in the db). + +You must be authorized to purge the dataset. + + + \ No newline at end of file diff --git a/docs/content/docs/group_delete.mdx b/docs/content/docs/group_delete.mdx new file mode 100644 index 0000000..2b265b3 --- /dev/null +++ b/docs/content/docs/group_delete.mdx @@ -0,0 +1,24 @@ +--- +title: group_delete +full: true +_openapi: + method: DELETE + route: group_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a group. + + You must be authorized to delete the group. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a group. + +You must be authorized to delete the group. + + + \ No newline at end of file diff --git a/docs/content/docs/group_member_delete.mdx b/docs/content/docs/group_member_delete.mdx new file mode 100644 index 0000000..07f1e3c --- /dev/null +++ b/docs/content/docs/group_member_delete.mdx @@ -0,0 +1,24 @@ +--- +title: group_member_delete +full: true +_openapi: + method: DELETE + route: group_member_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Remove a user from a group. + + You must be authorized to edit the group. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Remove a user from a group. + +You must be authorized to edit the group. + + + \ No newline at end of file diff --git a/docs/content/docs/group_purge.mdx b/docs/content/docs/group_purge.mdx new file mode 100644 index 0000000..6cee332 --- /dev/null +++ b/docs/content/docs/group_purge.mdx @@ -0,0 +1,43 @@ +--- +title: group_purge +full: true +_openapi: + method: DELETE + route: group_purge + toc: [] + structuredData: + headings: [] + contents: + - content: > + Purge a group. + + + Purging a group cannot be + undone! + + + Purging a group completely removes the group from the CKAN database, + whereas deleting a group simply marks the group as deleted (it will no + longer show up in the frontend, but is still in the db). + + + Datasets in the group will remain, just not in the purged group. + + + You must be authorized to purge the group. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Purge a group. + +Purging a group cannot be undone! + +Purging a group completely removes the group from the CKAN database, whereas deleting a group simply marks the group as deleted (it will no longer show up in the frontend, but is still in the db). + +Datasets in the group will remain, just not in the purged group. + +You must be authorized to purge the group. + + + \ No newline at end of file diff --git a/docs/content/docs/job_cancel.mdx b/docs/content/docs/job_cancel.mdx new file mode 100644 index 0000000..a2286bd --- /dev/null +++ b/docs/content/docs/job_cancel.mdx @@ -0,0 +1,24 @@ +--- +title: job_cancel +full: true +_openapi: + method: DELETE + route: job_cancel + toc: [] + structuredData: + headings: [] + contents: + - content: | + Cancel a queued background job. + + Removes the job from the queue and deletes it. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Cancel a queued background job. + +Removes the job from the queue and deletes it. + + + \ No newline at end of file diff --git a/docs/content/docs/job_clear.mdx b/docs/content/docs/job_clear.mdx new file mode 100644 index 0000000..a0733a3 --- /dev/null +++ b/docs/content/docs/job_clear.mdx @@ -0,0 +1,24 @@ +--- +title: job_clear +full: true +_openapi: + method: DELETE + route: job_clear + toc: [] + structuredData: + headings: [] + contents: + - content: | + Clear background job queues. + + Does not affect jobs that are already being processed. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Clear background job queues. + +Does not affect jobs that are already being processed. + + + \ No newline at end of file diff --git a/docs/content/docs/member_delete.mdx b/docs/content/docs/member_delete.mdx new file mode 100644 index 0000000..882edde --- /dev/null +++ b/docs/content/docs/member_delete.mdx @@ -0,0 +1,24 @@ +--- +title: member_delete +full: true +_openapi: + method: DELETE + route: member_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Remove an object (e.g. a user, dataset or group) from a group. + + You must be authorized to edit a group to remove objects from it. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Remove an object (e.g. a user, dataset or group) from a group. + +You must be authorized to edit a group to remove objects from it. + + + \ No newline at end of file diff --git a/docs/content/docs/organization_delete.mdx b/docs/content/docs/organization_delete.mdx new file mode 100644 index 0000000..fbbd500 --- /dev/null +++ b/docs/content/docs/organization_delete.mdx @@ -0,0 +1,27 @@ +--- +title: organization_delete +full: true +_openapi: + method: DELETE + route: organization_delete + toc: [] + structuredData: + headings: [] + contents: + - content: > + Delete an organization. + + + You must be authorized to delete the organization and no datasets + should belong to the organization unless + `'ckan.auth.create_unowned_dataset=True'` +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete an organization. + +You must be authorized to delete the organization and no datasets should belong to the organization unless `'ckan.auth.create_unowned_dataset=True'` + + + \ No newline at end of file diff --git a/docs/content/docs/organization_member_delete.mdx b/docs/content/docs/organization_member_delete.mdx new file mode 100644 index 0000000..d681c52 --- /dev/null +++ b/docs/content/docs/organization_member_delete.mdx @@ -0,0 +1,24 @@ +--- +title: organization_member_delete +full: true +_openapi: + method: DELETE + route: organization_member_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Remove a user from an organization. + + You must be authorized to edit the organization. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Remove a user from an organization. + +You must be authorized to edit the organization. + + + \ No newline at end of file diff --git a/docs/content/docs/organization_purge.mdx b/docs/content/docs/organization_purge.mdx new file mode 100644 index 0000000..f63f786 --- /dev/null +++ b/docs/content/docs/organization_purge.mdx @@ -0,0 +1,45 @@ +--- +title: organization_purge +full: true +_openapi: + method: DELETE + route: organization_purge + toc: [] + structuredData: + headings: [] + contents: + - content: > + Purge an organization. + + + Purging an organization cannot + be undone! + + + Purging an organization completely removes the organization from the + CKAN database, whereas deleting a organization simply marks the + organization as deleted (it will no longer show up in the frontend, + but is still in the db). + + + Datasets owned by the organization will remain, just not in an + organization anymore. + + + You must be authorized to purge the organization. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Purge an organization. + +Purging an organization cannot be undone! + +Purging an organization completely removes the organization from the CKAN database, whereas deleting a organization simply marks the organization as deleted (it will no longer show up in the frontend, but is still in the db). + +Datasets owned by the organization will remain, just not in an organization anymore. + +You must be authorized to purge the organization. + + + \ No newline at end of file diff --git a/docs/content/docs/package_collaborator_delete.mdx b/docs/content/docs/package_collaborator_delete.mdx new file mode 100644 index 0000000..525512a --- /dev/null +++ b/docs/content/docs/package_collaborator_delete.mdx @@ -0,0 +1,34 @@ +--- +title: package_collaborator_delete +full: true +_openapi: + method: DELETE + route: package_collaborator_delete + toc: [] + structuredData: + headings: [] + contents: + - content: > + Remove a collaborator from a dataset. + + + Currently you must be an Admin on the dataset owner organization to + manage collaborators. + + + Note: This action requires the collaborators feature to be enabled + with the + [`ckan.auth.allow_dataset_collaborators`](https://docs.ckan.org/en/2.11/maintaining/configuration.html#ckan-auth-allow-dataset-collaborators) + configuration option. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Remove a collaborator from a dataset. + +Currently you must be an Admin on the dataset owner organization to manage collaborators. + +Note: This action requires the collaborators feature to be enabled with the [`ckan.auth.allow_dataset_collaborators`](https://docs.ckan.org/en/2.11/maintaining/configuration.html#ckan-auth-allow-dataset-collaborators) configuration option. + + + \ No newline at end of file diff --git a/docs/content/docs/package_delete.mdx b/docs/content/docs/package_delete.mdx new file mode 100644 index 0000000..dfd71f3 --- /dev/null +++ b/docs/content/docs/package_delete.mdx @@ -0,0 +1,31 @@ +--- +title: package_delete +full: true +_openapi: + method: DELETE + route: package_delete + toc: [] + structuredData: + headings: [] + contents: + - content: > + Delete a dataset (package). + + + This makes the dataset disappear from all web & API views, apart from + the trash. + + + You must be authorized to delete the dataset. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a dataset (package). + +This makes the dataset disappear from all web & API views, apart from the trash. + +You must be authorized to delete the dataset. + + + \ No newline at end of file diff --git a/docs/content/docs/package_relationship_delete.mdx b/docs/content/docs/package_relationship_delete.mdx new file mode 100644 index 0000000..e02bf55 --- /dev/null +++ b/docs/content/docs/package_relationship_delete.mdx @@ -0,0 +1,26 @@ +--- +title: package_relationship_delete +full: true +_openapi: + method: DELETE + route: package_relationship_delete + toc: [] + structuredData: + headings: [] + contents: + - content: > + Delete a dataset (package) relationship. + + + You must be authorised to delete dataset relationships, and to edit + both the subject and the object datasets. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a dataset (package) relationship. + +You must be authorised to delete dataset relationships, and to edit both the subject and the object datasets. + + + \ No newline at end of file diff --git a/docs/content/docs/resource_delete.mdx b/docs/content/docs/resource_delete.mdx new file mode 100644 index 0000000..e8fbcf8 --- /dev/null +++ b/docs/content/docs/resource_delete.mdx @@ -0,0 +1,24 @@ +--- +title: resource_delete +full: true +_openapi: + method: DELETE + route: resource_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a resource from a dataset. + + You must be a sysadmin or the owner of the resource to delete it. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a resource from a dataset. + +You must be a sysadmin or the owner of the resource to delete it. + + + \ No newline at end of file diff --git a/docs/content/docs/resource_view_clear.mdx b/docs/content/docs/resource_view_clear.mdx new file mode 100644 index 0000000..cbb7526 --- /dev/null +++ b/docs/content/docs/resource_view_clear.mdx @@ -0,0 +1,20 @@ +--- +title: resource_view_clear +full: true +_openapi: + method: DELETE + route: resource_view_clear + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete all resource views, or all of a particular type. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete all resource views, or all of a particular type. + + + \ No newline at end of file diff --git a/docs/content/docs/resource_view_delete.mdx b/docs/content/docs/resource_view_delete.mdx new file mode 100644 index 0000000..859934d --- /dev/null +++ b/docs/content/docs/resource_view_delete.mdx @@ -0,0 +1,20 @@ +--- +title: resource_view_delete +full: true +_openapi: + method: DELETE + route: resource_view_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a resource_view. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a resource_view. + + + \ No newline at end of file diff --git a/docs/content/docs/tag_delete.mdx b/docs/content/docs/tag_delete.mdx new file mode 100644 index 0000000..5cd2322 --- /dev/null +++ b/docs/content/docs/tag_delete.mdx @@ -0,0 +1,24 @@ +--- +title: tag_delete +full: true +_openapi: + method: DELETE + route: tag_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a tag. + + You must be a sysadmin to delete tags. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a tag. + +You must be a sysadmin to delete tags. + + + \ No newline at end of file diff --git a/docs/content/docs/task_status_delete.mdx b/docs/content/docs/task_status_delete.mdx new file mode 100644 index 0000000..57df403 --- /dev/null +++ b/docs/content/docs/task_status_delete.mdx @@ -0,0 +1,24 @@ +--- +title: task_status_delete +full: true +_openapi: + method: DELETE + route: task_status_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a task status. + + You must be a sysadmin to delete task statuses. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a task status. + +You must be a sysadmin to delete task statuses. + + + \ No newline at end of file diff --git a/docs/content/docs/unfollow_dataset.mdx b/docs/content/docs/unfollow_dataset.mdx new file mode 100644 index 0000000..439e031 --- /dev/null +++ b/docs/content/docs/unfollow_dataset.mdx @@ -0,0 +1,20 @@ +--- +title: unfollow_dataset +full: true +_openapi: + method: DELETE + route: unfollow_dataset + toc: [] + structuredData: + headings: [] + contents: + - content: | + Stop following a dataset. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Stop following a dataset. + + + \ No newline at end of file diff --git a/docs/content/docs/unfollow_group.mdx b/docs/content/docs/unfollow_group.mdx new file mode 100644 index 0000000..47fbc12 --- /dev/null +++ b/docs/content/docs/unfollow_group.mdx @@ -0,0 +1,20 @@ +--- +title: unfollow_group +full: true +_openapi: + method: DELETE + route: unfollow_group + toc: [] + structuredData: + headings: [] + contents: + - content: | + Stop following a group. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Stop following a group. + + + \ No newline at end of file diff --git a/docs/content/docs/unfollow_user.mdx b/docs/content/docs/unfollow_user.mdx new file mode 100644 index 0000000..01b5d52 --- /dev/null +++ b/docs/content/docs/unfollow_user.mdx @@ -0,0 +1,20 @@ +--- +title: unfollow_user +full: true +_openapi: + method: DELETE + route: unfollow_user + toc: [] + structuredData: + headings: [] + contents: + - content: | + Stop following a user. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Stop following a user. + + + \ No newline at end of file diff --git a/docs/content/docs/user_delete.mdx b/docs/content/docs/user_delete.mdx new file mode 100644 index 0000000..a4eed90 --- /dev/null +++ b/docs/content/docs/user_delete.mdx @@ -0,0 +1,24 @@ +--- +title: user_delete +full: true +_openapi: + method: DELETE + route: user_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a user. + + Only sysadmins can delete users. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a user. + +Only sysadmins can delete users. + + + \ No newline at end of file diff --git a/docs/content/docs/vocabulary_delete.mdx b/docs/content/docs/vocabulary_delete.mdx new file mode 100644 index 0000000..9c7c6cc --- /dev/null +++ b/docs/content/docs/vocabulary_delete.mdx @@ -0,0 +1,24 @@ +--- +title: vocabulary_delete +full: true +_openapi: + method: DELETE + route: vocabulary_delete + toc: [] + structuredData: + headings: [] + contents: + - content: | + Delete a tag vocabulary. + + You must be a sysadmin to delete vocabularies. +--- + +{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} + +Delete a tag vocabulary. + +You must be a sysadmin to delete vocabularies. + + + \ No newline at end of file diff --git a/docs/lib/openapi.yml b/docs/lib/openapi.yml index 972c852..13b3604 100644 --- a/docs/lib/openapi.yml +++ b/docs/lib/openapi.yml @@ -2212,3 +2212,480 @@ paths: name: type: string description: distinctive name for API Token + user_delete: + delete: + operationId: user_delete + summary: user_delete + description: | + Delete a user. + + Only sysadmins can delete users. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + # Original docs say "usernamename" which is a typo that should be fixed + description: the id or name of the user to delete + package_delete: + delete: + operationId: package_delete + summary: package_delete + description: | + Delete a dataset (package). + + This makes the dataset disappear from all web & API views, apart from the trash. + + You must be authorized to delete the dataset. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the dataset to delete + dataset_purge: + delete: + operationId: dataset_purge + summary: dataset_purge + # Original docs say "Purging a database" which may be a typo for "Purging a dataset" + description: | + Purge a dataset. + + Purging a dataset cannot be undone! + + Purging a dataset completely removes the dataset from the CKAN database, whereas deleting a dataset simply marks the dataset as deleted (it will no longer show up in the front-end, but is still in the db). + + You must be authorized to purge the dataset. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the dataset to be purged + resource_delete: + delete: + operationId: resource_delete + summary: resource_delete + description: | + Delete a resource from a dataset. + + You must be a sysadmin or the owner of the resource to delete it. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id of the resource + resource_view_delete: + delete: + operationId: resource_view_delete + summary: resource_view_delete + description: | + Delete a resource_view. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id of the resource_view + resource_view_clear: + delete: + operationId: resource_view_clear + summary: resource_view_clear + description: | + Delete all resource views, or all of a particular type. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + view_types: + type: array + description: specific types to delete + items: + type: string + package_relationship_delete: + delete: + operationId: package_relationship_delete + summary: package_relationship_delete + description: | + Delete a dataset (package) relationship. + + You must be authorised to delete dataset relationships, and to edit both the subject and the object datasets. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + subject: + type: string + description: the id or name of the dataset that is the subject of the relationship + object: + type: string + description: the id or name of the dataset that is the object of the relationship + type: + type: string + description: the type of the relationship + member_delete: + delete: + operationId: member_delete + summary: member_delete + description: | + Remove an object (e.g. a user, dataset or group) from a group. + + You must be authorized to edit a group to remove objects from it. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id of the group + object: + type: string + description: the id or name of the object to be removed + object_type: + type: string + description: the type of the object to be removed, e.g. `package` or `user` + package_collaborator_delete: + delete: + operationId: package_collaborator_delete + summary: package_collaborator_delete + description: | + Remove a collaborator from a dataset. + + Currently you must be an Admin on the dataset owner organization to manage collaborators. + + Note: This action requires the collaborators feature to be enabled with the [`ckan.auth.allow_dataset_collaborators`](https://docs.ckan.org/en/2.11/maintaining/configuration.html#ckan-auth-allow-dataset-collaborators) configuration option. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the dataset + user_id: + type: string + description: the id or name of the user to remove + group_delete: + delete: + operationId: group_delete + summary: group_delete + description: | + Delete a group. + + You must be authorized to delete the group. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the name or id of the group + organization_delete: + delete: + operationId: organization_delete + summary: organization_delete + description: | + Delete an organization. + + You must be authorized to delete the organization and no datasets should belong to the organization unless `'ckan.auth.create_unowned_dataset=True'` + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the name or id of the organization + group_purge: + delete: + operationId: group_purge + summary: group_purge + # Original docs say "Datasets in the organization will remain", however this should probably say "in the group" + description: | + Purge a group. + + Purging a group cannot be undone! + + Purging a group completely removes the group from the CKAN database, whereas deleting a group simply marks the group as deleted (it will no longer show up in the frontend, but is still in the db). + + Datasets in the group will remain, just not in the purged group. + + You must be authorized to purge the group. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the name or id of the group to be purged + organization_purge: + delete: + operationId: organization_purge + summary: organization_purge + # Original docs say "any more" when it should be "anymore" + description: | + Purge an organization. + + Purging an organization cannot be undone! + + Purging an organization completely removes the organization from the CKAN database, whereas deleting a organization simply marks the organization as deleted (it will no longer show up in the frontend, but is still in the db). + + Datasets owned by the organization will remain, just not in an organization anymore. + + You must be authorized to purge the organization. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the name or id of the organization to be purged + task_status_delete: + delete: + operationId: task_status_delete + summary: task_status_delete + description: | + Delete a task status. + + You must be a sysadmin to delete task statuses. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id of the task status to delete + vocabulary_delete: + delete: + operationId: vocabulary_delete + summary: vocabulary_delete + description: | + Delete a tag vocabulary. + + You must be a sysadmin to delete vocabularies. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id of the vocabulary + tag_delete: + delete: + operationId: tag_delete + summary: tag_delete + description: | + Delete a tag. + + You must be a sysadmin to delete tags. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the tag + vocabulary_id: + type: string + description: "the id or name of the vocabulary that the tag belongs to (default: `None`)" + unfollow_user: + delete: + operationId: unfollow_user + summary: unfollow_user + description: | + Stop following a user. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the user to stop following + unfollow_dataset: + delete: + operationId: unfollow_dataset + summary: unfollow_dataset + description: | + Stop following a dataset. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the dataset to stop following + group_member_delete: + delete: + operationId: group_member_delete + summary: group_member_delete + description: | + Remove a user from a group. + + You must be authorized to edit the group. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the group + username: + type: string + description: name or id of the user to be removed + organization_member_delete: + delete: + operationId: organization_member_delete + summary: organization_member_delete + description: | + Remove a user from an organization. + + You must be authorized to edit the organization. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the organization + username: + type: string + description: name or id of the user to be removed + unfollow_group: + delete: + operationId: unfollow_group + summary: unfollow_group + description: | + Stop following a group. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: the id or name of the group to stop following + job_clear: + delete: + operationId: job_clear + summary: job_clear + description: | + Clear background job queues. + + Does not affect jobs that are already being processed. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + queues: + type: array + description: The queues to clear. If not given then ALL queues are cleared. + items: + type: string + job_cancel: + delete: + operationId: job_cancel + summary: job_cancel + description: | + Cancel a queued background job. + + Removes the job from the queue and deletes it. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + id: + type: string + description: The ID of the background job. + api_token_revoke: + delete: + operationId: api_token_revoke + summary: api_token_revoke + description: | + Delete API Token. + requestBody: + required: false + content: + application/json: + schema: + type: object + properties: + token: + type: string + # Original docs don't have a space between remove and ( + description: Token to remove (required if `jti` not specified) + jti: + type: string + # Original docs don't capitalize D in ID and don't have space between remove and ( + description: ID of the token to remove (overrides `token` if specified)