this

setState

({

_ipAddress

responseJson

origin

});

})

catch

error

=>

console

error

error

);

});

};

Flutter uses the http package. To install the http package,
add it to the dependencies’ section of our pubspec.yaml.

dependencies

flutter

sdk

flutter

http

<latest_version>

Flutter uses the dart:io core HTTP support client.
To create an HTTP Client, import dart:io.

The client supports the following HTTP operations:
GET, POST, PUT, and DELETE.

Form input