Dio library key working perfectly fine in my case if we pass small case key value
For example,
Dio dio = new Dio(); dio.options.headers['content-Type'] = 'application/json'; dio.options.headers["authorization"] = "token ${token}"; response = await dio.post(url, data: data);