Skip to content

Deleting GRDF konnector also remove consents

Hugo NOUTS requested to merge onDeleteAccount into dev

Delete user's consent when deleting konnector account.

Based on the "onDeleteAction" method advised by cozy to do post delete operation on an account.

For more info, check https://docs.cozy.io/en/tutorials/data/advanced/#revisions

HOW TO TEST

  1. Install konnector on your alpha instance -> yarn build + yarn deploy-test, on alpha ./update_grdf_konnector_dev.sh [instance]

  2. Check that no existing consent are locked on grdf account.

  3. Go on your ecolyo app, plug the grdf konnector.

  4. Go on alpha and turn on the monitoring stack -> cd /monitoring/logs-monitoring ... docker-compose up -d

  5. Plug the easy-cozy logs from your instance on a grafana panel (see existing one to know how to build the query)

  6. Pass your instance on debug mode -> docker-compose exec cozy ./cozy instances debug --domain "hugo.cozy.self-data.alpha.grandlyon.com" true

  7. Go back on your app and delete the konnector

  8. Check that on https://monespace.grdf.fr/client/particulier/donnees-transmises the consent is now gone

  9. Check the log on grafana for any informations

TEST WHEN ACCESS_TOKEN IS EXPIRED :

When you just connected the konnector, go on postman and fetch the account informations.

Replace the oauth.expires_at field with a data earlier than 4 hours ago. (IMPORTANT change the expires_at field only, konnector only checks this field anyway).

Enjoy

Edited by Hugo NOUTS

Merge request reports