From c0bd5edf03d8310af989c7eb744e512e3cc874d8 Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Fri, 11 Dec 2020 12:13:48 +0100 Subject: [PATCH 1/5] :bug: Show API_VERSION and GIT_SHA on component dashboard issue: https://github.com/VNG-Realisatie/gemma-zaken/issues/1706 --- src/brc/utils/context_processors.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/brc/utils/context_processors.py b/src/brc/utils/context_processors.py index 398d642..863b738 100644 --- a/src/brc/utils/context_processors.py +++ b/src/brc/utils/context_processors.py @@ -8,6 +8,8 @@ def settings(request): "SHOW_ALERT", "PROJECT_NAME", "SITE_TITLE", + "API_VERSION", + "GIT_SHA", ) return { From de24f12b13dafc21c26b85ccad8a6789674899a8 Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Fri, 11 Dec 2020 12:15:10 +0100 Subject: [PATCH 2/5] :arrow_up: Bump vng-api-common to 1.0.53 --- requirements/base.txt | 2 +- requirements/jenkins.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/requirements/base.txt b/requirements/base.txt index fac0d6d..5c7a2df 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -61,4 +61,4 @@ sqlparse==0.3.0 # via django unidecode==1.0.22 # via vng-api-common uritemplate==3.0.0 # via coreapi, drf-yasg urllib3==1.24.3 # via requests -vng-api-common==1.0.34 +vng-api-common==1.0.53 diff --git a/requirements/jenkins.txt b/requirements/jenkins.txt index d38305b..298c945 100644 --- a/requirements/jenkins.txt +++ b/requirements/jenkins.txt @@ -75,5 +75,5 @@ text-unidecode==1.2 # via faker unidecode==1.0.22 uritemplate==3.0.0 urllib3==1.24.3 -vng-api-common==1.0.34 +vng-api-common==1.0.53 wrapt==1.10.11 # via astroid From 694da6762b9035829cff8fb0c13fc518a341639c Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Fri, 11 Dec 2020 12:16:46 +0100 Subject: [PATCH 3/5] :wrench: Add necessary settings for autorisaties/notificaties.md generation issue: https://github.com/VNG-Realisatie/gemma-zaken/issues/1706 --- src/brc/conf/api.py | 5 +++++ src/brc/utils/context_processors.py | 3 +++ 2 files changed, 8 insertions(+) diff --git a/src/brc/conf/api.py b/src/brc/conf/api.py index 3e8c012..20344cd 100644 --- a/src/brc/conf/api.py +++ b/src/brc/conf/api.py @@ -1,3 +1,4 @@ +import os from vng_api_common.conf.api import * # noqa - imports white-listed API_VERSION = "1.0.1" @@ -41,3 +42,7 @@ zrc_repo = "vng-Realisatie/gemma-zaakregistratiecomponent" zrc_commit = "8ea1950fe4ec2ad99504d345eba60a175eea3edf" ZRC_API_SPEC = f"https://raw.githubusercontent.com/{zrc_repo}/{zrc_commit}/src/openapi.yaml" # noqa + +SELF_REPO = "VNG-Realisatie/gemma-besluitregistratiecomponent" +SELF_BRANCH = os.getenv("SELF_BRANCH") or API_VERSION +GITHUB_API_SPEC = f"https://raw.githubusercontent.com/{SELF_REPO}/{SELF_BRANCH}/src/openapi.yaml" # noqa diff --git a/src/brc/utils/context_processors.py b/src/brc/utils/context_processors.py index 863b738..913e6e2 100644 --- a/src/brc/utils/context_processors.py +++ b/src/brc/utils/context_processors.py @@ -10,6 +10,9 @@ def settings(request): "SITE_TITLE", "API_VERSION", "GIT_SHA", + "GITHUB_API_SPEC", + "SELF_REPO", + "SELF_BRANCH", ) return { From 02db155fd02f2a02e85706001de3d250e60256e0 Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Fri, 11 Dec 2020 12:17:59 +0100 Subject: [PATCH 4/5] :wrench: Add autorisaties.md and notificaties.md --- src/autorisaties.md | 65 +++++++++++++++++++++++++++++++++++++++++++++ src/notificaties.md | 35 ++++++++++++++++++++++++ 2 files changed, 100 insertions(+) create mode 100644 src/autorisaties.md create mode 100644 src/notificaties.md diff --git a/src/autorisaties.md b/src/autorisaties.md new file mode 100644 index 0000000..6663d22 --- /dev/null +++ b/src/autorisaties.md @@ -0,0 +1,65 @@ + +# Autorisaties +## Scopes voor Besluiten API + +Scopes worden typisch per component gedefinieerd en geven aan welke rechten er zijn. +Zie de repository van de [Autorisaties API](https://github.com/VNG-Realisatie/autorisaties-api) + + +### audittrails.lezen + +**Scope** +`audittrails.lezen` + + +**Laat toe om**: + +* audittrails op te lijsten +* audittrail details op te vragen + + +### besluiten.aanmaken + +**Scope** +`besluiten.aanmaken` + + +**Laat toe om**: + +* besluiten aan te maken + + +### besluiten.bijwerken + +**Scope** +`besluiten.bijwerken` + + +**Laat toe om**: + +* attributen van een besluit te wijzingen + + +### besluiten.lezen + +**Scope** +`besluiten.lezen` + + +**Laat toe om**: + +* besluiten te lezen +* besluitdetails op te vragen + + +### besluiten.verwijderen + +**Scope** +`besluiten.verwijderen` + + +**Laat toe om**: + +* besluiten te verwijderen + + diff --git a/src/notificaties.md b/src/notificaties.md new file mode 100644 index 0000000..09fca65 --- /dev/null +++ b/src/notificaties.md @@ -0,0 +1,35 @@ +## Notificaties +## Berichtkenmerken voor Besluiten API + +Kanalen worden typisch per component gedefinieerd. Producers versturen berichten op bepaalde kanalen, +consumers ontvangen deze. Consumers abonneren zich via een notificatiecomponent (zoals https://notificaties-api.vng.cloud/api/v1/schema/) op berichten. + +Hieronder staan de kanalen beschreven die door deze component gebruikt worden, met de kenmerken bij elk bericht. + +De architectuur van de notificaties staat beschreven op https://github.com/VNG-Realisatie/notificaties-api. + + +### besluiten + +**Kanaal** +`besluiten` + +**Main resource** + +`besluit` + + + +**Kenmerken** + +* `verantwoordelijke_organisatie`: Het RSIN van de niet-natuurlijk persoon zijnde de organisatie die het besluit heeft vastgesteld. +* `besluittype`: URL-referentie naar het BESLUITTYPE (in de Catalogi API). + +**Resources en acties** + + +* besluit: create, update, destroy + +* besluitinformatieobject: create, destroy + + From 78eb39a3afd9667fafaabef888a4698410185c74 Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Fri, 11 Dec 2020 12:20:39 +0100 Subject: [PATCH 5/5] :memo: Link to autorisaties.md and notificaties.md in README --- README.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.rst b/README.rst index 6668c5a..b1bb0a7 100644 --- a/README.rst +++ b/README.rst @@ -19,18 +19,18 @@ API specificaties |lint-oas| |generate-sdks| |generate-postman-collection| -========== ============== ============================= -Versie Release datum API specificatie -========== ============== ============================= -1.0.x n.v.t. `ReDoc `_, +========== ============== ==================================================================================================================================================================================================== ======================================================================================================================= ================================================================================================================================= +Versie Release datum API specificatie Autorisaties Notificaties +========== ============== ==================================================================================================================================================================================================== ======================================================================================================================= ================================================================================================================================= +1.0.x n.v.t. `ReDoc `_, `Scopes `_ `Berichtkenmerken `_ `Swagger `_ (`verschillen `_) -1.0.1 2019-12-16 `ReDoc `_, +1.0.1 2019-12-16 `ReDoc `_, `Scopes `_ `Berichtkenmerken `_ `Swagger `_ (`verschillen `_) -1.0.0 2019-11-18 `ReDoc `_, +1.0.0 2019-11-18 `ReDoc `_, `Scopes `_ `Berichtkenmerken `_ `Swagger `_ -========== ============== ============================= +========== ============== ==================================================================================================================================================================================================== ======================================================================================================================= ================================================================================================================================= Zie ook: `Alle versies en wijzigingen `_