Hi ramitaherwahdan1978,
You are using JSON.stringify which converts JavaScript object into a JSON string. So you cannot access the values as you do with JSON object.
You need to keep it as JavaScript object or if it is in JSON string format, then you have to convert it into a JavaScript object.
To convert JSON string into a JavaScript object, you can use built-in method of JavaScript which is JSON.parse.
Once you have converted it into a JavaScript object then you can access the value using its key.
To get the value of id only, you can simply access it without using JSON.parse method as it is already in JavaScript object format.
const theID = data.id
For more details on JSON.parse and JSON.stringify, please refer to the link below.
https://stackoverflow.com/questions/17785592/difference-between-json-stringify-and-json-parse