Where is wrong?
I was trying to https://api.dropboxapi.com/2/files/list_folder?access_token=.... but don't run. Where is wrong?
using json on c#.
You're using a URL parameter named "access_token", but per the error message that should instead be named "authorization". (Or, you can use an Authorization header.)
public async Task<Model.Get_Current_Account.RootObject> get_current_account(string _accessToken) { var query = await mainViewModel.Httpclient("https://api.dropboxapi.com/2/users/get_current_account?access_token="+_accessToken); if (query != null) { var get_data = JsonConvert.DeserializeObject<Model.Get_Current_Account.RootObject>(query); return get_data; } else return null; }
public async Task<string> Httpclient(string link) { HttpClient client = new HttpClient(); HttpResponseMessage response= await client.GetAsync(link); return await response.Content.ReadAsStringAsync(); }
Error in call to API function "users/get_current_account": Must provide HTTP header "Authorization" or URL parameter "authorization".
This could be a number of issues. Can you share the code snippet that calls the endpoint, and the full text of the error output?