title: How to call GET api to send data in BODY using axios?
body: <p>I'm trying to send data in a body using the GET method.
  It's working fine when i try to run using POSTMAN/cURL/Python but it's not working using AXIOS(ReactJS).</p>
  
  <p>cURL:</p>
  
  <pre><code>curl -X GET \
    http://127.0.0.1:8000/xyz/xyz/ayx-api/ \
    -H 'Authorization: Token 980e4e673a9cfb4c99cb35313f65a446aa44faf7' \
    -H 'Content-Type: application/json' \
    -H 'Postman-Token: 1ee27393-b4b0-446a-b613-bd319e02e3c8' \
    -H 'cache-control: no-cache' \
    -d '{"dataId": 1, "date": "2018-03-01", "days": 9 }'
  </code></pre>
  
  <p>this curl working fine</p>
  
  <p>Using Axios:</p>
  
  <pre><code>import axios from 'axios';
  
  const baseUrl = process.env.BACKEND_SERVER_URL;
  
  export const fetchDataObjects = async() =&gt; {
      const header = {
              'Content-Type': 'application/json',
              'Authorization': `Token ${localStorage.token}`,
  
          }
      const data ={"dataId": 1, "date": "2018-03-01", "days": 9 }
      const res= await axios.get(`${baseUrl}/ayx-api/`,{data:JSON.stringify(data)}, {headers: header})
      // above line need to helop
      return res.data;
    }
  </code></pre>
  
  <p>How can i send data in body using axios in get method?</p>
  
  <p>Thanks in advance.</p>