Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreasFischer1985 committed Sep 9, 2023
1 parent 45c0ba8 commit da0b0b2
Show file tree
Hide file tree
Showing 2 changed files with 140 additions and 124 deletions.
35 changes: 32 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,39 @@

API zum DiGA-Verzeichnis https://diga.bfarm.de/de/ des Bundesinstituts für Arzneimittel und Medizinprodukte BfArM. Das Verzeichnis bietet eine Auswahl an digitalen Gesundheitsanwendungen (DiGA), die vom BfArM gemäß § 139e SGB V bewertet wurden.

Anfragen sind als GET-requests zu stellen, wobei zur Authorisierung ein Bearer Token im Header "authorization" anzugeben ist, der wiederum einem GET-request an https://diga.bfarm.de/de/verzeichnis zu entnehmen ist (Im contetn von meta name="host-app/config/environment" unter "APP"/"fhir"/"token").

## Beispiel

```bash
apps=$(curl 'https://diga-api.bfarm.de/diga-vz/apps')
appDetails=$(curl 'https://diga-api.bfarm.de/diga-vz/apps/961')
appPrescription=$(curl 'https://diga-api.bfarm.de/diga-vz/prescriptions?filter%5Bapp%5D=961')
token="116b0a73-6e3b-4a88-9313-9947a4fed9ef"

devDef1=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/DeviceDefinition?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthApp')

devDev2=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/DeviceDefinition?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppModule')

catalogEntry=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/CatalogEntry?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppCatalogEntry')

organization=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/Organization?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppManufacturer')

chargeItemDefinition=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/ChargeItemDefinition?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppPrescriptionUnit')

questionnaire=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/Questionnaire?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppQuestionnaire')

questionnaireResponse=$(curl -m 60 \
-H "authorization: Bearer $token" \
'https://diga.bfarm.de/api/fhir/v2.0/QuestionnaireResponse?_count=1000&_profile=https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppQuestionnaireResponse')

```
229 changes: 108 additions & 121 deletions openapi.yaml
Original file line number Diff line number Diff line change
@@ -1,158 +1,145 @@
openapi: "3.0.0"
info:
description: "API zum DiGA-Verzeichnis https://diga.bfarm.de/de/ des Bundesinstituts für Arzneimittel und Medizinprodukte BfArM. Das Verzeichnis bietet eine Auswahl an digitalen Gesundheitsanwendungen (DiGA), die vom BfArM gemäß § 139e SGB V bewertet wurden."
version: "1.0.0"
description: |
API zum DiGA-Verzeichnis https://diga.bfarm.de/de/ des Bundesinstituts für Arzneimittel und Medizinprodukte BfArM. Das Verzeichnis bietet eine Auswahl an digitalen Gesundheitsanwendungen (DiGA), die vom BfArM gemäß § 139e SGB V bewertet wurden.
Anfragen sind als GET-requests zu stellen, wobei zur Authorisierung ein Bearer Token im Header "authorization" anzugeben ist, der wiederum einem GET-request an https://diga.bfarm.de/de/verzeichnis zu entnehmen ist (Im contetn von meta name="host-app/config/environment" unter "APP"/"fhir"/"token").
version: "2.0.0"
title: "DiGA API"
contact:
name: "AndreasFischer1985"
email: "andreasfischer1985@web.de"
url: "https://github.com/AndreasFischer1985/diga-api"
servers:
- url: "https://diga-api.bfarm.de/diga-vz"
- url: "https://diga.bfarm.de/api/fhir/v2.0"
externalDocs:
description: "Weiterführende Dokumentation"
url: "https://github.com/AndreasFischer1985/diga-api"

paths:

/apps:
/DeviceDefinition:
get:

Check warning on line 22 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.

Check warning on line 22 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".

Check warning on line 22 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.
summary: "Liste aller DiGAs"
summary: "DeviceDefinition"
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/digalist'

/apps/{id}:
parameters:
- in: query
name: _count
example: 1000
required: true
schema:
type: integer
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthApp
required: true
schema:
type: string
/CatalogEntry:
get:

Check warning on line 41 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".

Check warning on line 41 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.

Check warning on line 41 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.
summary: "CatalogEntry"
responses:
'200':
description: OK
parameters:
- in: query
name: _count
example: 1000
required: true
schema:
type: integer
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppCatalogEntry
required: true
schema:
type: string
/Organization:
get:

Check warning on line 60 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".

Check warning on line 60 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.

Check warning on line 60 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.
summary: "Detail-Informationen zu einer DiGa."
description: "Detail-Informationen zu einer DiGa."
summary: "Organization"
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/digadetails'
parameters:
- in: path
name: id
example: 961
- in: query
name: _count
example: 1000
required: true
schema:
type: integer
/prescriptions:
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppManufacturer
required: true
schema:
type: string
/ChargeItemDefinition:
get:

Check warning on line 79 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.

Check warning on line 79 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.

Check warning on line 79 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".
summary: "Technische Informationen zu einer DiGa."
description: "Detail-Informationen zu einer DiGa."
summary: "ChargeItemDefinition"
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/digaprescription'
parameters:
- in: query
name: filter%5Bapp%5D
example: 961
name: _count
example: 1000
required: true
schema:
type: integer
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppPrescriptionUnit
required: true
schema:
type: string
/Questionnaire:
get:

Check warning on line 98 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".

Check warning on line 98 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.

Check warning on line 98 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.
summary: "Questionnaire"
responses:
'200':
description: OK
parameters:
- in: query
name: _count
example: 1000
required: true
schema:
type: integer
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppQuestionnaire
required: true
schema:
type: string
/QuestionnaireResponse:
get:

Check warning on line 117 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-description

Operation "description" must be present and non-empty string.

Check warning on line 117 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-operationId

Operation must have "operationId".

Check warning on line 117 in openapi.yaml

View workflow job for this annotation

GitHub Actions / Lint (push)

operation-tags

Operation must have non-empty "tags" array.
summary: "Questionnaire"
responses:
'200':
description: OK
parameters:
- in: query
name: _count
example: 1000
required: true
schema:
type: integer
- in: query
name: _profile
example: https%3A%2F%2Ffhir.bfarm.de%2FStructureDefinition%2FHealthAppQuestionnaireResponse
required: true
schema:
type: string


components:
schemas:
digalist:
type: object
properties:
data:
type: array
items:
type: object
properties:
id:
type: integer
example: 294
type:
type: string
example: apps
attributes:
type: object
relationships:
type: object
included:
type: array
items:
type: object
properties:
id:
type: integer
example: 294
type:
type: string
example: app-answer
attributes:
type: object
relationships:
type: object
meta:
type: object
properties:
id:
type: string
example: "1659011258436:wl0-l-web0:35304:l61ldvti:21666"

digadetails:
type: object
properties:
data:
type: array
items:
type: object
properties:
id:
type: integer
example: 294
type:
type: string
example: apps
attributes:
type: object
relationships:
type: object
meta:
type: object
properties:
id:
type: string
example: "1659009146573:wl0-l-web0:35304:l61ldvti:20170"

digaprescription:
type: object
properties:
data:
type: array
items:
type: object
properties:
id:
type: integer
example: 27
type:
type: string
example: prescriptions
attributes:
type: object
relationships:
type: object
meta:
type: object
properties:
id:
type: string
example: "1659009146572:wl0-l-web0:35304:l61ldvti:20169"


securitySchemes:
bearerAuth:
type: http
scheme: bearer
description: "Bearer Token"

security:
- bearerAuth: []

0 comments on commit da0b0b2

Please sign in to comment.