Skip to main content
Solved

Delete Folder Lock Fails 404 Not Found

  • December 12, 2024
  • 2 replies
  • 26 views

Forum|alt.badge.img
  • New Participant
  • 1 reply

Delete Folder Lock fails with 404 Not Found.

{

    "type": "error",

    "status": 404,

    "code": "not_found",

    "help_url": "http://developers.box.com/docs/#errors",

    "message": "Authorization Failed",

    "request_id": "0b3a714efe5a6f7110fc3281c015b0d2c"

}

I’ve authenticated with the Owner as well as made myself Co-Owner.

I’ve reviewed: API [Content API] - 404 "not_found" Errors from the Box API – Box Support but doesn’t seem to help.

curl --location --request DELETE 'https://api.box.com/2.0/folder_locks/297778732113' \
--header 'content-type: application/json' \
--header 'Authorization: Bearer ----------------------------------------------' \
--header 'Cookie: box_visitor_id=66ec80484d6913.85943221'

 

 

 

Best answer by mike.curry

Hi Gabe,

 

It appears that in your API request, you are supplying a 12-digit Box Folder ID rather than a 10-digit Folder Lock ID in the path parameter.

You can retrieve the Folder Lock ID by querying GET https://api.box.com/2.0/folder_locks?folder_id=297778732113

 

From that you will see a response similar to:


{
    "entries": [
        {
            "folder": {
                "type": "folder",
                "id": "297778732113",
                "sequence_id": "0",
                "etag": "0",
                "name": "Example Folder Name"
            },
            "id": "<some 10-digit ID>",
            "type": "folder_lock",

 

 

Use the 10-digit Folder Lock ID in conjunction with the DELETE endpoint from your previous request and the folder lock will be deleted. 

View original
Did this topic help you find an answer to your question?

2 replies

mike.curry
  • Known Participant
  • 11 replies
  • Answer
  • December 16, 2024

Hi Gabe,

 

It appears that in your API request, you are supplying a 12-digit Box Folder ID rather than a 10-digit Folder Lock ID in the path parameter.

You can retrieve the Folder Lock ID by querying GET https://api.box.com/2.0/folder_locks?folder_id=297778732113

 

From that you will see a response similar to:


{
    "entries": [
        {
            "folder": {
                "type": "folder",
                "id": "297778732113",
                "sequence_id": "0",
                "etag": "0",
                "name": "Example Folder Name"
            },
            "id": "<some 10-digit ID>",
            "type": "folder_lock",

 

 

Use the 10-digit Folder Lock ID in conjunction with the DELETE endpoint from your previous request and the folder lock will be deleted. 


Forum|alt.badge.img
  • Author
  • New Participant
  • 1 reply
  • December 16, 2024

Thanks Mike, that was the issue.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings