Skip to content

Commit

Permalink
add dummy api requests for receiver (#61)
Browse files Browse the repository at this point in the history
* add dummy api requests for receiver

* dotnet format

* small fix with return documentation

---------

Co-authored-by: Hammerbeck <andreas.hammerbeck@digdir.no>
  • Loading branch information
Andreass2 and Hammerbeck authored May 22, 2024
1 parent 8113c44 commit a304a20
Show file tree
Hide file tree
Showing 7 changed files with 403 additions and 35 deletions.
251 changes: 225 additions & 26 deletions altinn-correspondence-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@
"$ref": "#/components/schemas/InitializeAttachmentExt"
}
},
"text/json": {
"schema": {
"$ref": "#/components/schemas/InitializeAttachmentExt"
}
},
"application/*+json": {
"schema": {
"$ref": "#/components/schemas/InitializeAttachmentExt"
Expand Down Expand Up @@ -208,11 +203,6 @@
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
}
},
"text/json": {
"schema": {
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
}
},
"application/*+json": {
"schema": {
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
Expand All @@ -232,6 +222,69 @@
}
}
}
},
"get": {
"tags": [
"Correspondence"
],
"parameters": [
{
"name": "offset",
"in": "query",
"style": "form",
"schema": {
"type": "integer",
"format": "int32"
}
},
{
"name": "limit",
"in": "query",
"style": "form",
"schema": {
"type": "integer",
"format": "int32"
}
},
{
"name": "from",
"in": "query",
"style": "form",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "to",
"in": "query",
"style": "form",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "status",
"in": "query",
"style": "form",
"schema": {
"$ref": "#/components/schemas/CorrespondenceStatusExt"
}
}
],
"responses": {
"200": {
"description": "Success",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CorrespondencesExt"
}
}
}
}
}
}
},
"/correspondence/api/v1/correspondence/upload": {
Expand All @@ -246,11 +299,6 @@
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
}
},
"text/json": {
"schema": {
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
}
},
"application/*+json": {
"schema": {
"$ref": "#/components/schemas/InitializeCorrespondenceExt"
Expand Down Expand Up @@ -333,6 +381,112 @@
}
}
}
},
"/correspondence/api/v1/correspondence/{correspondenceId}/markasread": {
"post": {
"tags": [
"Correspondence"
],
"parameters": [
{
"name": "correspondenceId",
"in": "path",
"required": true,
"style": "simple",
"schema": {
"type": "string",
"format": "uuid"
}
}
],
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/correspondence/api/v1/correspondence/{correspondenceId}/confirm": {
"post": {
"tags": [
"Correspondence"
],
"parameters": [
{
"name": "correspondenceId",
"in": "path",
"required": true,
"style": "simple",
"schema": {
"type": "string",
"format": "uuid"
}
}
],
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/correspondence/api/v1/correspondence/{correspondenceId}/archive": {
"post": {
"tags": [
"Correspondence"
],
"parameters": [
{
"name": "correspondenceId",
"in": "path",
"required": true,
"style": "simple",
"schema": {
"type": "string",
"format": "uuid"
}
}
],
"responses": {
"200": {
"description": "Success"
}
}
},
"delete": {
"tags": [
"Correspondence"
],
"parameters": [
{
"name": "correspondenceId",
"in": "path",
"required": true,
"style": "simple",
"schema": {
"type": "string",
"format": "uuid"
}
}
],
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/health": {
"get": {
"tags": [
"Health"
],
"responses": {
"200": {
"description": "Success"
}
}
}
}
},
"components": {
Expand Down Expand Up @@ -599,7 +753,8 @@
"type": "object",
"properties": {
"language": {
"$ref": "#/components/schemas/LanguageTypeExt"
"type": "string",
"nullable": true
},
"messageTitle": {
"type": "string",
Expand All @@ -615,6 +770,14 @@
"$ref": "#/components/schemas/CorrespondenceAttachmentOverviewExt"
},
"nullable": true
},
"attachmentIds": {
"type": "array",
"items": {
"type": "string",
"format": "uuid"
},
"nullable": true
}
},
"additionalProperties": false
Expand Down Expand Up @@ -910,6 +1073,7 @@
"enum": [
"Initialized",
"Published",
"Fetched",
"Read",
"Replied",
"Confirmed",
Expand All @@ -921,6 +1085,23 @@
],
"type": "string"
},
"CorrespondencesExt": {
"type": "object",
"properties": {
"ids": {
"type": "array",
"items": {
"type": "string",
"format": "uuid"
},
"nullable": true
},
"pagination": {
"$ref": "#/components/schemas/PaginationMetaDataExt"
}
},
"additionalProperties": false
},
"ExternalReferenceExt": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -1053,7 +1234,8 @@
"type": "object",
"properties": {
"language": {
"$ref": "#/components/schemas/LanguageTypeExt"
"type": "string",
"nullable": true
},
"messageTitle": {
"type": "string",
Expand All @@ -1069,6 +1251,14 @@
"$ref": "#/components/schemas/InitializeCorrespondenceAttachmentExt"
},
"nullable": true
},
"attachmentIds": {
"type": "array",
"items": {
"type": "string",
"format": "uuid"
},
"nullable": true
}
},
"additionalProperties": false
Expand Down Expand Up @@ -1189,15 +1379,6 @@
],
"type": "string"
},
"LanguageTypeExt": {
"enum": [
"English",
"NorwegianNO",
"Sami",
"NorwegianNN"
],
"type": "string"
},
"NotificationChannelExt": {
"enum": [
"Email",
Expand All @@ -1223,6 +1404,24 @@
},
"additionalProperties": false
},
"PaginationMetaDataExt": {
"type": "object",
"properties": {
"TotalItems": {
"type": "integer",
"format": "int32"
},
"Page": {
"type": "integer",
"format": "int32"
},
"Pages": {
"type": "integer",
"format": "int32"
}
},
"additionalProperties": false
},
"ReferenceTypeExt": {
"enum": [
"Generic",
Expand Down
Loading

0 comments on commit a304a20

Please # to comment.