I am trying to get contents of a text file via
https://api.dropboxapi.com/2/file_requests/get
and I get this error:
"Error in call to API function "file_requests/get": request body: id: 'id:Jc0ALBXAshIAAAAAAAB3tw' did not match pattern '[-_0-9a-zA-Z]+'"
Here is my relevant code:
$fields = array(
"id" => "id:Jc0ALBXAshIAAAAAAAB3tw" );
curl_setopt( $ch, CURLOPT_POSTFIELDS, json_encode( $fields ) );
curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true );
curl_setopt( $ch, CURLOPT_CUSTOMREQUEST, "POST" );
curl_setopt( $ch, CURLOPT_HTTPHEADER, array( 'Authorization: Bearer ' . $auth_token, 'Content-Type: application/json' ) );
curl_setopt( $ch, CURLOPT_URL, 'https://api.dropboxapi.com/2/file_requests/get' );
I got the file id from another api request, so it should exist. What am I doing wrong?