I encounter a 404 error when attempting to delete a page using Curl. However, I can successfully delete the page through the Confluence interface in the browser, utilizing the same user ID.
I can get/put/post with the same user and API token. But not Delete, why?
I use this curl syntax:
curl --request DELETE \ --url 'https://{your-domain}/wiki/api/v2/pages/{id}' \ --user 'email@example.com:<api_token>'
Hi @srini nall
I tested with the same REST API as documented below, and it works:
https://developer.atlassian.com/cloud/confluence/rest/v2/api-group-page/#api-pages-id-delete
As a side note, I think you might need to correct the backslash usage in your command:
\
) is used to indicate that a space follows a line continuation. This space will break the command.
Thank you.
Hi @Victor Law
Update:
1. I can delete a page from my account(free & personal)
2. But when I delete a page from my work account, I get 404 status code. But GET works fine and the page status is "current". Do you think, my admin who created the account in Confluence didn't give the Delete permission for the account I use?
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @srini nall
I suggest you check with the space admin, as permission to delete is granted on the Confluence space level.
https://support.atlassian.com/confluence-cloud/docs/assign-space-permissions/
Thank you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I use this curl syntax:
curl --request DELETE \ --url 'https://{your-domain}/wiki/api/v2/pages/{id}' \ --user 'email@example.com:<api_token>'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.