So basically I have an access token that expires in 300 seconds, I need to add 30 minutes to the current date time and save that date time to check whether the access token is expired or not
>Solution :
You can use add() to add some time to DateTime, like this:
var result = DateTime.now().add(Duration(minutes: 30));
print("now + 30 min = ${result}");