diff --git a/docs/proxy/description.md b/docs/proxy/description.md index 7a7caae185d250b647e7730b1369bcdb80070109..00ed5b98b105bf7cebdb97d10bffb902728115c4 100644 --- a/docs/proxy/description.md +++ b/docs/proxy/description.md @@ -21,7 +21,7 @@ These APIs implement Oauth 2.0 protocol, it requires authentication from the cus Regarding Enedis, two endpoints are exposed: -#### /auth +#### /dataconnect/v1/oauth2/authorize <table> <colgroup> @@ -57,7 +57,7 @@ Regarding Enedis, two endpoints are exposed: !!! important "Important" The response targets the redirect-uri registered with Enedis (the redirect-uri is our proxy and the response will be explained in details further below when explaining the proxy endpoints mechanics). -#### /token +#### /v1/oauth2/token <table> <colgroup> @@ -106,7 +106,32 @@ On success, response will contain **access_token** or **refresh_token**, **usage ### Grdf Adict -#### /access_token +!!! info "grdf documentation" + Visit https://site.grdf.fr/web/grdf-adict/technique to explore all the services exposed by Grdf. + > Prod endpoints are: https://sofit-sso-oidc.grdf.fr/openam/ + +Regarding Grdf Adict Oauth connexion, two endpoints are exposed: + +!!! warning "Oauth connexion still in Beta" + Grdf Adict Oauth service is called Client Connect and is still in early beta. It is currently lacking a *state* parameter in the Oauth dance. + +#### /oauth2/realms/externeGrdf/authorize + +#### /oauth2/realms/externeGrdf/access_token + + +The */access_token* endpoint can be called with two different *grant_type* parameter. + + - *authorization_code* gives an access token and will also retrieve the consents list given by the user in session. + - *client_credentials* gives only the access token allowing us to request the data service. + + The grdf Konnector would only need to call the *client_credentials* to get a refresh token. + +#### Optional: Revoke Consent + +It is possible to cancel a consent that was given from the user to our service (for test or development purpose for instance). + +api.grdf.fr/adict/v1/droit_acces/{id_accreditation} ### Cozy Oauth Protocol @@ -190,11 +215,11 @@ Exemple: With that in mind, the proxy is now the one calling the auth and token provider endpoints. The instance name will be contained in redirect_uri, the stack will insert this parameters by itself in the /auth call. -3 endpoints are created in the proxy: +3 endpoints are created in the proxy for **each energy supplier**: - One for the auth - One for the token -- One for the redirect +- One for the redirect uri #### Proxy flow @@ -208,7 +233,7 @@ stack -> proxy/auth -> provider/auth -> proxy/redirect -> stack -> proxy/token - The proxy is coded in golang. -It is composed of three endpoints as seen above. The first endpoint to be called is **/auth**. +It is composed of six endpoints as seen above. The first endpoint to be called is **/auth**. #### auth