openmhealth / omh-dsu-ri

An application for storing mobile health data and authorizing access to it.
http://www.openmhealth.org/documentation/#/store-data/storage-overview
Apache License 2.0
39 stars 32 forks source link

Validate Token For Access #14

Open luistduarte opened 7 years ago

luistduarte commented 7 years ago

Is it possible to have a rest call to check if token is still valid?

Thanks

emersonf commented 7 years ago

I think /check_token in the Spring Security OAuth framework should do that for you. The docs aren't too clear, let me know how it goes.

luistduarte commented 7 years ago

i tryied to use it, but without success, for now when i want to validate token i did a get rest call like this

If it returns response code 200, token is valid "http://localhost:8083/v1.0.M1/dataPoints?schema_namespace=omh&schema_name=physical-activity&schema_version=1.0"