Hi,
I need to use this endpoint to get the parent_shared_folder_id.
The problem is that my json data does not return this info.
I get a response that looks like this:
{'.tag': 'file', 'name': 'testy2.png', 'path_lower': '/test/testy2.png', 'path_display': '/test/testy2.png', 'id': 'id:AYyyfCw5MFkAAAAAAABqCQ', 'client_modified': '2024-03-08T18:02:38Z', 'server_modified': '2024-03-08T18:02:39Z', 'rev': '61329ff5f6a802ad8828f', 'size': 1054078, 'is_downloadable': True, 'has_explicit_shared_members': False, 'content_hash': '7ae9e640d9ba9f51f129f57b67fdf1e5a22bd94c69f825ec5442e81080a6dca9'}
I'm running this request in python.
import requests
# Define the endpoint URL
url = "https://api.dropboxapi.com/2/files/get_metadata"
# Replace '<get access token>' with your actual access token
access_token = 'ACCESS_TOKEN'
# Define the headers
headers = {
"Authorization": f"Bearer {access_token}",
"Content-Type": "application/json"
}
# Define the data payload
data = {
"include_deleted": True,
"include_has_explicit_shared_members": True,
"include_media_info": True,
"path": "/test/testy2.png"
}
# Make the POST request
response = requests.post(url, headers=headers, json=data)
# Print the response
print(response.json())