v2 auth parallel
This commit is contained in:
parent
f1dac94396
commit
e714f663bb
1 changed files with 265 additions and 22 deletions
287
openapi.json
287
openapi.json
|
|
@ -1282,16 +1282,16 @@
|
|||
"/api/v1/auth/login": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"v1",
|
||||
"auth"
|
||||
"v2",
|
||||
"auth-v2"
|
||||
],
|
||||
"summary": "Login and set user_id cookie",
|
||||
"operationId": "login",
|
||||
"summary": "Login",
|
||||
"operationId": "loginV2",
|
||||
"requestBody": {
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/LoginBody"
|
||||
"$ref": "#/components/schemas/api__auth_v2__LoginBody"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
@ -1303,14 +1303,11 @@
|
|||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/Person"
|
||||
"$ref": "#/components/schemas/TokenResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"404": {
|
||||
"$ref": "#/components/responses/Problem404"
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
|
|
@ -1372,6 +1369,119 @@
|
|||
]
|
||||
}
|
||||
},
|
||||
"/api/v1/auth/register": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"v2",
|
||||
"auth-v2"
|
||||
],
|
||||
"summary": "Register",
|
||||
"operationId": "register",
|
||||
"requestBody": {
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/RegisterBody"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": true
|
||||
},
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "Successful Response",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/TokenResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/users/me/households": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"v2",
|
||||
"households"
|
||||
],
|
||||
"summary": "List My Households",
|
||||
"operationId": "list_my_households_api_v1_users_me_households_get",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "Successful Response",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"items": {
|
||||
"$ref": "#/components/schemas/HouseholdResponse"
|
||||
},
|
||||
"type": "array",
|
||||
"title": "Response List My Households Api V1 Users Me Households Get"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"$ref": "#/components/responses/Problem422"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/households": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"v2",
|
||||
"households"
|
||||
],
|
||||
"summary": "Create Household",
|
||||
"operationId": "create_household_api_v1_households_post",
|
||||
"requestBody": {
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/CreateHouseholdBody"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": true
|
||||
},
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "Successful Response",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HouseholdResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/healthz": {
|
||||
"get": {
|
||||
"summary": "Healthz",
|
||||
|
|
@ -1393,6 +1503,19 @@
|
|||
},
|
||||
"components": {
|
||||
"schemas": {
|
||||
"CreateHouseholdBody": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"title": "Name"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"name"
|
||||
],
|
||||
"title": "CreateHouseholdBody"
|
||||
},
|
||||
"CurrentShoppingList": {
|
||||
"properties": {
|
||||
"outstandingItems": {
|
||||
|
|
@ -1484,6 +1607,29 @@
|
|||
"type": "object",
|
||||
"title": "HealthStatus"
|
||||
},
|
||||
"HouseholdResponse": {
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "integer",
|
||||
"title": "Id"
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"title": "Name"
|
||||
},
|
||||
"slug": {
|
||||
"type": "string",
|
||||
"title": "Slug"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"id",
|
||||
"name",
|
||||
"slug"
|
||||
],
|
||||
"title": "HouseholdResponse"
|
||||
},
|
||||
"Ingredient": {
|
||||
"properties": {
|
||||
"id": {
|
||||
|
|
@ -1706,19 +1852,6 @@
|
|||
],
|
||||
"title": "ListIngredientItem"
|
||||
},
|
||||
"LoginBody": {
|
||||
"properties": {
|
||||
"username": {
|
||||
"type": "string",
|
||||
"title": "Username"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"username"
|
||||
],
|
||||
"title": "LoginBody"
|
||||
},
|
||||
"Meal-Input": {
|
||||
"properties": {
|
||||
"id": {
|
||||
|
|
@ -2669,6 +2802,29 @@
|
|||
],
|
||||
"title": "RecipeOut"
|
||||
},
|
||||
"RegisterBody": {
|
||||
"properties": {
|
||||
"email": {
|
||||
"type": "string",
|
||||
"title": "Email"
|
||||
},
|
||||
"password": {
|
||||
"type": "string",
|
||||
"title": "Password"
|
||||
},
|
||||
"displayName": {
|
||||
"type": "string",
|
||||
"title": "Displayname"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"email",
|
||||
"password",
|
||||
"displayName"
|
||||
],
|
||||
"title": "RegisterBody"
|
||||
},
|
||||
"RequestedMealItem": {
|
||||
"properties": {
|
||||
"kind": {
|
||||
|
|
@ -2769,6 +2925,62 @@
|
|||
],
|
||||
"title": "StoreEnum"
|
||||
},
|
||||
"TokenResponse": {
|
||||
"properties": {
|
||||
"accessToken": {
|
||||
"type": "string",
|
||||
"title": "Accesstoken"
|
||||
},
|
||||
"tokenType": {
|
||||
"type": "string",
|
||||
"title": "Tokentype",
|
||||
"default": "bearer"
|
||||
},
|
||||
"user": {
|
||||
"$ref": "#/components/schemas/User"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"accessToken",
|
||||
"user"
|
||||
],
|
||||
"title": "TokenResponse"
|
||||
},
|
||||
"User": {
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "integer",
|
||||
"title": "Id",
|
||||
"default": -1
|
||||
},
|
||||
"email": {
|
||||
"type": "string",
|
||||
"title": "Email"
|
||||
},
|
||||
"displayName": {
|
||||
"type": "string",
|
||||
"title": "Displayname"
|
||||
},
|
||||
"profilePhotoUrl": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"type": "null"
|
||||
}
|
||||
],
|
||||
"title": "Profilephotourl"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"email",
|
||||
"displayName"
|
||||
],
|
||||
"title": "User"
|
||||
},
|
||||
"ValidationError": {
|
||||
"properties": {
|
||||
"loc": {
|
||||
|
|
@ -2802,6 +3014,37 @@
|
|||
],
|
||||
"title": "ValidationError"
|
||||
},
|
||||
"api__auth__LoginBody": {
|
||||
"properties": {
|
||||
"username": {
|
||||
"type": "string",
|
||||
"title": "Username"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"username"
|
||||
],
|
||||
"title": "LoginBody"
|
||||
},
|
||||
"api__auth_v2__LoginBody": {
|
||||
"properties": {
|
||||
"email": {
|
||||
"type": "string",
|
||||
"title": "Email"
|
||||
},
|
||||
"password": {
|
||||
"type": "string",
|
||||
"title": "Password"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"email",
|
||||
"password"
|
||||
],
|
||||
"title": "LoginBody"
|
||||
},
|
||||
"StoreNameOut": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
|
|
|
|||
Loading…
Reference in a new issue