From f41b3670c1e3517ba710a114470ac10975dceb20 Mon Sep 17 00:00:00 2001
From: hnouts <hnouts@grandlyon.com>
Date: Tue, 25 Oct 2022 11:22:36 +0200
Subject: [PATCH] dataconnect going deprecated

---
 docs/cozystack/local.md                       | 20 +++++++++----------
 docs/easycozy/index.md                        |  6 +-----
 docs/easycozy/tips.md                         |  4 +---
 docs/ecolyo/functionalities/initialization.md |  8 ++++----
 docs/ecolyo/functionalities/profile_type.md   |  2 +-
 .../launch_local_application.md               |  4 ++--
 docs/konnectors/enedis.md                     |  5 ++++-
 docs/konnectors/grdf.md                       |  2 +-
 docs/konnectors/index.md                      | 10 +++++++++-
 docs/proxy/description.md                     | 14 ++++++-------
 docs/proxy/use_cases/enedis.md                |  2 ++
 mkdocs.yml                                    |  4 ++--
 12 files changed, 44 insertions(+), 37 deletions(-)

diff --git a/docs/cozystack/local.md b/docs/cozystack/local.md
index 2c5df0e..24c5650 100644
--- a/docs/cozystack/local.md
+++ b/docs/cozystack/local.md
@@ -1,28 +1,28 @@
 ## Local stack
 
-[Gitlab Repo](https://forge.grandlyon.com/web-et-numerique/llle_project/cozy-stack)
+![gitlab](../img/gitlab-logo.svg)  [cozy-stack](https://forge.grandlyon.com/web-et-numerique/llle_project/cozy-stack)
 
 ### Why are we cloning the official repo ?
 
-Because of some political choice Cozy Cloud are not maintaining there official [docker image](https://hub.docker.com/r/cozy/cozy-app-dev) properly. That's why we have a mirroring version of there official repository with some custom docker configuration improving :
+Cozy Cloud has chosen to not maintain the official [docker image](https://hub.docker.com/r/cozy/cozy-app-dev) properly. This is why we have a mirroring version of their official repository with some custom docker configuration improving:
 	
-* CouchDb version. Officially Cozy Cloud use CouchDb 3.2.2, but in there official image it's not the case yet.
+* CouchDB version 3.2.2
 
-### What change should be done by cozy in order to upgrade there image ?
+### What changes should be done by cozy in order to upgrade their image ?
 
-Cozy should upgrade there CouchDb version inside there image. But unfortunately, the base image `debian:stretch-slim` does not support ERLANG/OTP>=19, and CouchDb need at least a version >=20 for their `3.2.2` version, see [official doc](https://docs.couchdb.org/en/stable/whatsnew/3.2.html#id2).
+Cozy should upgrade their CouchDB version inside their image. But unfortunately, the base image `debian:stretch-slim` does not support ERLANG/OTP>=19, and CouchDB need at least a version >=20 for their `3.2.2` version, see [official doc](https://docs.couchdb.org/en/stable/whatsnew/3.2.html#id2).
 
-As a consequence they should upgrade there base image to at least `debian:buster`. But this add a new issue, the official binary of couch-db cannot be build on this version according to some missing libraries.
+As a consequence they should upgrade their base image to at least `debian:buster`. But this add a new issue, the official binary of CouchDB cannot be built on this version according to some missing libraries.
 
-That's why we took the shortcut of using an official [CouchDb image](https://hub.docker.com/_/couchdb)
+That's why we took the shortcut of using an official [CouchDB image](https://hub.docker.com/_/couchdb)
 
 ### How to build new version of the stack ?
 
-If we want to build a new stack version it's easy ! A manual pipeline has been created. You just need to run the following steps :
+If we want to build a new stack version it's easy! A manual pipeline has been created. You just need to run the following steps:
 
-* Run the manual pipeline in CI/CD part of gitlab
+* Run the manual pipeline attached to our gitlab CI/CD
 * Enter the requested parameter `VERSION` and a value (ex: 1.5.7)
 
 ![Stack Pipeline](/img/stack-pipeline.png)
 
-The image will be automatically build based on the branch and store in the registry.
+The image will be automatically built based on the branch and store in the registry.
diff --git a/docs/easycozy/index.md b/docs/easycozy/index.md
index e907e31..cd139e9 100644
--- a/docs/easycozy/index.md
+++ b/docs/easycozy/index.md
@@ -1,8 +1,4 @@
 ![easycozy](../img/easycozy.png){: .center}
 
-## What is easy-cozy
-
-## Why we use easy-cozy
-
-## How we use it
 
+![gitlab](../img/gitlab-logo.svg) [easy-cozy](https://forge.grandlyon.com/pocs/cozy/easy-cozy)
diff --git a/docs/easycozy/tips.md b/docs/easycozy/tips.md
index 334f751..d64c2c5 100644
--- a/docs/easycozy/tips.md
+++ b/docs/easycozy/tips.md
@@ -55,9 +55,7 @@ This doctypes will be removed.
 
 * com.grandlyon.ecolyo.userchallenge
 
-Type "yes" if ok.
-yes
-```
+Type `yes` to continue.
 
 A browser window will be opened asking for authorization to access to your file. 
 Just click on "Authorize" to keep on with the doctype dropping.
diff --git a/docs/ecolyo/functionalities/initialization.md b/docs/ecolyo/functionalities/initialization.md
index 3c505e0..9f53cec 100644
--- a/docs/ecolyo/functionalities/initialization.md
+++ b/docs/ecolyo/functionalities/initialization.md
@@ -2,7 +2,7 @@ This section explains how to handle data storage.
 
 We handle data storage according to the following process :
 
-The folder `/src/db` contains all the JSON entities that are directly stored in the couchDB during the initialization process that is executed in the splash screen. They are stored under their related doctype.
+The folder `/src/db` contains all the JSON entities that are directly stored in the CouchDB during the initialization process that is executed in the splash screen. They are stored under their related doctype.
 
 ## Initialization and Updating
 
@@ -26,7 +26,7 @@ During the initialization process, we store a hash for each dataEntity that is l
 ]
 ```
 
-This way, once the initialization is launched, we compare the hash we have in the current userProfile with the one generated from the entity located in /db folder, and if they are different we update the couchDB with the new data.
+This way, once the initialization is launched, we compare the hash we have in the current userProfile with the one generated from the entity located in /db folder, and if they are different we update the CouchDB with the new data.
 
 In order to handle this process, each entity that is likely to change has a function that takes the current hash in entry, and execute the following process :
 
@@ -54,7 +54,7 @@ Functions used to init or update the hash :
 
 ### dataEntity vs userData
 
-In the project, you'll see two versions for the same data. The dataEntity (quizEntity, challengeEntity, ...) is the data stored in the db folder and in the couchDB. These data are only edited in the couchDB when we update a challenge/quiz/duel or add a new one.
+In the project, you'll see two versions for the same data. The dataEntity (quizEntity, challengeEntity, ...) is the data stored in the db folder and in the CouchDB. These data are only edited in the CouchDB when we update a challenge/quiz/duel or add a new one.
 
 The userData (userChallenge, userQuiz...) is created from the entity and extended with user's data, such as his progress, his consumption data, goals, fails etc.
 
@@ -89,7 +89,7 @@ You can see more about relationships on [cozy documentation](https://docs.cozy.i
 
 ### UserData creation
 
-We create a userData and store it in the couchDB under the doctype userData name '**com.grandlyon.ecolyo.userDataName'.** During this process, the objects related to the dataEntity will be be converted to an user version which contains information about the user(example: user progress, the fluids connected and so on).
+We create a userData and store it in the CouchDB under the doctype userData name '**com.grandlyon.ecolyo.userDataName'.** During this process, the objects related to the dataEntity will be be converted to an user version which contains information about the user(example: user progress, the fluids connected and so on).
 
 To illustrate this, let's show an example of the conversion of duelEntity to UserDuel :
 
diff --git a/docs/ecolyo/functionalities/profile_type.md b/docs/ecolyo/functionalities/profile_type.md
index dd68542..c04e749 100644
--- a/docs/ecolyo/functionalities/profile_type.md
+++ b/docs/ecolyo/functionalities/profile_type.md
@@ -69,7 +69,7 @@ Here you can see the different methods provided by the profileType service. Thes
 | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------- |
 | getProfileType(date?: DateTime) : Promise-ProfileType, null                                           | Returns a profiletype closest to the given param date. When no param date, returns most recent profiletype          |
 | getAllProfileTypes(timePeriod?: TimePeriod) : Promise-ProfileType[], null                             | Returns all profiletypes for given time period, if no param returns all profiletypes                                |
-| updateProfileType(attributes: Partial-ProfileType): Promise-ProfileType, null                         | Saves profiletype in couchdb                                                                                        |
+| updateProfileType(attributes: Partial-ProfileType): Promise-ProfileType, null                         | Saves profiletype in CouchDB                                                                                        |
 | deleteProfileTypes(profileTypes: ProfileType[]): Promise-boolean                                       | Delete array of profileTypes                                                                                        |
 | parseProfileTypeEntityToProfileType(profileTypeEntity: ProfileType): ProfileType                       | Retrieves ProfileType from the ProfileTypeEntity                                                                    |
 
diff --git a/docs/ecolyo/getting_started/launch_local_application.md b/docs/ecolyo/getting_started/launch_local_application.md
index ab7297e..088b7ae 100644
--- a/docs/ecolyo/getting_started/launch_local_application.md
+++ b/docs/ecolyo/getting_started/launch_local_application.md
@@ -64,7 +64,7 @@ Local database can also be consulted at the following url: [Cozy local DB](http:
 In most case you will use mocked konnectors with mock data, but for some testing goals you will need real accounts.
 In local, it is possible to run EGL en SGE-Enedis konnectors, with real accounts, but it needs some specific manipulation as well as you'll need to use api secrets that are, of course, basically not available in the project. If you need to use konnectors with real accounts in testing goals, please follow the following steps. Otherwise, refer to the next two sections 'Import Mock Data' et 'Simulate konnector connections'. 
 
-First step, make sure your stack is running. Then open your [couchDB](http://localhost:5984/_utils/) and look for the ```secrets/io-cozy-account_types``` entry.
+First step, make sure your stack is running. Then open your [CouchDB](http://localhost:5984/_utils/) and look for the ```secrets/io-cozy-account_types``` entry.
 Then add a new document like this :
 
 EGL Example
@@ -136,7 +136,7 @@ node createDayDataFiles.js
 ```
 
 Json files with data will be created into **scripts/data** folder.
-ACH script "importData.bat" will load the content of the file into your couchDB (database of your dev stack). Launch it using following commands:
+ACH script "importData.bat" will load the content of the file into your CouchDB (database of your dev stack). Launch it using following commands:
 
 ```
 cd scripts
diff --git a/docs/konnectors/enedis.md b/docs/konnectors/enedis.md
index 86e9c78..b965762 100644
--- a/docs/konnectors/enedis.md
+++ b/docs/konnectors/enedis.md
@@ -1,3 +1,7 @@
+## Enedis Konnector
+!!! warning "DEPRECATED"
+    This section of documentation is not relevant anymore, enedis data connect has been replaced with enedis sge
+
 This konnector fetches consumption measures from Enedis API. This is an Oauth Konnector, meaning the authentication performed to access all data is made following an Oauth2 protocol.
 You can clone the project [here](https://forge.grandlyon.com/web-et-numerique/llle_project/enedis-konnector).
 
@@ -5,7 +9,6 @@ You should also check Cozy's official documentations for konnectors :
 [https://docs.cozy.io/en/tutorials/konnector/getting-started/](https://docs.cozy.io/en/tutorials/konnector/getting-started/)
 [https://docs.cozy.io/en/tutorials/konnector/oauth/](https://docs.cozy.io/en/tutorials/konnector/oauth/)
 
-## Enedis Konnector
 
 The Oauth protocol does not take place in the konnector code, therefore it is also important to take a look at the [proxy](/proxy/description/) documentation to fully understand all the interactions that will be told below.
 
diff --git a/docs/konnectors/grdf.md b/docs/konnectors/grdf.md
index 58f4b52..8ab1579 100644
--- a/docs/konnectors/grdf.md
+++ b/docs/konnectors/grdf.md
@@ -25,7 +25,7 @@ This token holds several meta data, including the pce_id (id of user's meter) th
 - Konnector starts, fails to find a pce_id in database on first launch therefore decodes the id_token to store the pce_id in db (see [addData](https://docs.cozy.io/en/cozy-konnector-libs/api/#adddata_1)).
 - Konnector restarts, this time knowing a pce_id, it fails to fetch data because the access_token from oauth call has a reduced scope (only scoping for meta data requests).
 - Konnector launches a refresh call, the proxy knows to answer it with a _client_credentials_ grant_type call to grdf /access_token.
-- Konnector restarts with everything needed in database to fetch data and store them in couchdb.
+- Konnector restarts with everything needed in database to fetch data and store them in CouchDB.
 
 - Further jobs will not need to change scope again and will only ask for refresh tokens.
 
diff --git a/docs/konnectors/index.md b/docs/konnectors/index.md
index 16aa877..2f0157b 100644
--- a/docs/konnectors/index.md
+++ b/docs/konnectors/index.md
@@ -1,5 +1,6 @@
 Konnectors are scripts that import data from a web service and put those data into cozy. Each konnector is an independent application managed by the cozy home application.
 
+
 Ecolyo uses data from 3 web services : 
 
 - Enedis
@@ -11,4 +12,11 @@ Some variation have to be considered :
 
 - When the user launches the konnector manually, it fetches 1 year of data (in order to reduce running time).
 - When a konnector is launched by the cozy stack (at a random time between 10am and 11am), it fetches 3 years of data.
-- When a konnector retrieves a load at the half-hour timeline (ex: enedis), it fetches back to 4 weeks.
\ No newline at end of file
+- When a konnector retrieves a load at the half-hour timeline (ex: enedis), it fetches back to 4 weeks.
+
+## ![gitlab](../img/gitlab-logo.svg) Repositories
+
+- [enedis dataconnect (deprecated)](https://forge.grandlyon.com/web-et-numerique/llle_project/enedis-konnector)
+- [enedis sge](https://forge.grandlyon.com/web-et-numerique/llle_project/enedis-sge-konnector)
+- [grdf](https://forge.grandlyon.com/web-et-numerique/llle_project/grdf-konnector)
+- [egl](https://forge.grandlyon.com/web-et-numerique/llle_project/egl-konnector)
\ No newline at end of file
diff --git a/docs/proxy/description.md b/docs/proxy/description.md
index 6d4cf35..42f9027 100644
--- a/docs/proxy/description.md
+++ b/docs/proxy/description.md
@@ -1,8 +1,8 @@
 This section of documentation refers to the Oauth protocols working hand in hand with our custom proxy and the cozy-stack.
 To fully understand its whereabouts, you should also look at the [enedis konnector](/konnectors/enedis/) and [grdf konnector](/konnectors/grdf/) documentation.
 
-!!! info "proxy code source"
-    Feel free to check the proxy [code](https://forge.grandlyon.com/pocs/cozy/cozy-oauth-proxy) at all time when reading this documentation.
+![gitlab](../img/gitlab-logo.svg) [proxy](https://forge.grandlyon.com/pocs/cozy/cozy-oauth-proxy)
+
 
 ## Oauth Dance
 
@@ -16,9 +16,9 @@ See both **[Enedis](./use_cases/enedis.md)** and **[Grdf](./use_cases/grdfadict.
 !!! info "cozy oauth flow documentation" 
     [https://docs.cozy.io/en/cozy-stack/konnectors-workflow/#reminder-oauth-flow](https://docs.cozy.io/en/cozy-stack/konnectors-workflow/#reminder-oauth-flow)
 
-#### Couchdb
+#### CouchDB
 
-The couchdb database must hold all information needed for the konnector authentication to work properly.
+The CouchDB database must hold all information needed for the konnector authentication to work properly.
 
 Auth information are stored in the **secrets/io-cozy-account_types** database.
 You can create manually the document by entering these parameters for each konnector:
@@ -70,7 +70,7 @@ Once the document is created, when launching the konnector from the cozy-home or
 
 The cozy-stack will request the authorize endpoint, then call the token endpoint with the code received from the auth step.
 
-If the token request is a success. An account/service-name database will be added in couchdb containing all information needed for authentication and the konnector will be free to work on all endpoints within its scope.
+If the token request is a success. An account/service-name database will be added in CouchDB containing all information needed for authentication and the konnector will be free to work on all endpoints within its scope.
 
 ### Why we Need a Proxy
 
@@ -128,7 +128,7 @@ Originally called from a cozy-stack trying to setup its konnector. The proxy get
 
 - client_id
 - duration
-- redirect_uri (auto inserted by the cozy-stack, except if you specify **skip_redirect_uri:true** in the couchdb)
+- redirect_uri (auto inserted by the cozy-stack, except if you specify **skip_redirect_uri:true** in the CouchDB)
 - response_type
 - state (as it was conceived by the cozy-stack)
 
@@ -168,4 +168,4 @@ Finally redirect all these parameters in a query to the cozy-stack (the cozy-sta
 Gathering from query or parameters all params.
 
 Sends a post request to the provider /token endpoint. 
-The stack will store the response params in a *accounts* couchdb database.
+The stack will store the response params in a *accounts* CouchDB database.
diff --git a/docs/proxy/use_cases/enedis.md b/docs/proxy/use_cases/enedis.md
index 59ac641..b835c1a 100644
--- a/docs/proxy/use_cases/enedis.md
+++ b/docs/proxy/use_cases/enedis.md
@@ -1,4 +1,6 @@
 ### Enedis Data Connect
+!!! warning "DEPRECATED"
+    This section of documentation is not relevant anymore, enedis data connect has been replaced with enedis sge
 
 !!! info "enedis documentation"
     Create an account on [https://datahub-enedis.fr/](https://datahub-enedis.fr/) to explore all the services exposed by Enedis.
diff --git a/mkdocs.yml b/mkdocs.yml
index edd4d02..4df2d5b 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -145,7 +145,7 @@ nav:
               - Launch local services: pilote/Pilote - Usager/getting_started/launch_local_services.md
   - Konnectors:
       - Introduction: konnectors/index.md
-      - Enedis: konnectors/enedis.md
+      - Enedis [DEPRECATED]: konnectors/enedis.md
       - Enedis SGE: konnectors/enedis-sge.md
       - GRDF: konnectors/grdf.md
       - Eau du Grand Lyon: konnectors/egl.md
@@ -153,5 +153,5 @@ nav:
       - Description: proxy/description.md
       - Monitoring: proxy/monitoring.md
       - Use cases:
-          - Enedis: proxy/use_cases/enedis.md
+          - Enedis [DEPRECATED]: proxy/use_cases/enedis.md
           - Grdf Adict: proxy/use_cases/grdfadict.md
-- 
GitLab