-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added doc for download attachment (#1920)
* Added doc for download attachment * Lagt til norsk doc * Rettet i engelsk versjon --------- Co-authored-by: Martin Todorov <>
- Loading branch information
Showing
2 changed files
with
80 additions
and
0 deletions.
There are no files selected for viewing
40 changes: 40 additions & 0 deletions
40
content/correspondence/reference/API endpoints/download attachment/_index.en.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
title: Download attachment | ||
linktitle: Download attachment | ||
description: Endpoint for downloading a correspondence attachment. | ||
|
||
weight: 60 | ||
toc: true | ||
--- | ||
|
||
## Endpoint | ||
|
||
GET /correspondence/api/v1/correspondence/{{correspondenceId}}/attachment/{{attachmentId}}/download | ||
|
||
## Description | ||
|
||
This endpoint enables the download of a specific attachment associated with a correspondence. Prior to utilizing this endpoint, the correspondence status must be set to "Published". The status of a correspondence can be verified by using the overview or details endpoint, as described [here](https://docs.altinn.studio/api/correspondence/spec/#/Correspondence/get_correspondence_api_v1_correspondence__correspondenceId_). | ||
|
||
## Authentication | ||
|
||
This API requires authentication, and the request must also include: | ||
|
||
- Correspondence read scope __altinn:correspondence.read__ (for external system callers) | ||
|
||
See [Authentication and Authorization](/notifications/reference/api/#authentication--authorization) for more information. | ||
|
||
## Response | ||
|
||
### Response codes | ||
- 200 OK: The attachment has been downloaded succesfully. | ||
|
||
Refer to problem details in response body for further information. | ||
- 400 One or more validation errors occurred: Indicates that the correspondenceid or the attachmentid was not found. | ||
|
||
### Content-Type | ||
|
||
- text | ||
|
||
### Response body | ||
|
||
The response body consists of the attachment content. |
40 changes: 40 additions & 0 deletions
40
content/correspondence/reference/API endpoints/download attachment/_index.nb.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
title: Last ned vedlegg | ||
linktitle: Last ned vedlegg | ||
description: Endepunkt for nedlasting av et meldingsevedlegg. | ||
|
||
weight: 60 | ||
toc: true | ||
--- | ||
|
||
## Endepunkt | ||
|
||
GET /correspondence/api/v1/correspondence/{{correspondenceId}}/attachment/{{attachmentId}}/download | ||
|
||
## Beskrivelse | ||
|
||
Dette endepunktet muliggjør nedlasting av et spesifikt vedlegg knyttet til en melding. Før endepunktet kan brukes, må statusen til meldingen være satt til "Publisert". Statusen til en melding kan verifiseres ved å bruke oversikts- eller detaljendepunktet, som beskrevet [her](https://docs.altinn.studio/api/correspondence/spec/#/Correspondence/get_correspondence_api_v1_correspondence__correspondenceId_). | ||
|
||
## Autentisering | ||
|
||
Dette API-et krever autentisering, og forespørselen må også inkludere: | ||
|
||
- Correspondence read scope __altinn:correspondence.read__ (for eksterne kall) | ||
|
||
Se [Autentisering og Autorisasjon](/notifications/reference/api/#authentication--authorization) for mer informasjon. | ||
|
||
## Respons | ||
|
||
### Responskoder | ||
|
||
- 200 OK: Vedlegget har blitt lastet ned vellykket. | ||
|
||
Se problemdetaljer i responskroppen for mer informasjon. | ||
- 400 One or more validation errors occurred: Indikerer at correspondenceid eller attachmentid ikke ble funnet. | ||
|
||
### Innholdstype | ||
- text | ||
|
||
### Response body | ||
|
||
Respons body består av innholdet i vedlegget. |