{ "openapi": "3.0.1", "info": { "title": "api Users API", "description": "API for api Users - Test", "contact": { "name": "Addison Waldow", "email": "a.wal.bear@gmail.com" }, "version": "1" }, "paths": { "/api/v1/Households/{householdId}": { "get": { "tags": [ "Households" ], "summary": "GetHouseholdAsync(Guid householdId)", "description": "Returns the Household object for householdId", "operationId": "GetHouseholdAsync", "parameters": [ { "name": "householdId", "in": "path", "description": "Household ID for the Household to get", "required": true, "schema": { "type": "string", "description": "Household ID for the Household to get", "format": "uuid" } } ], "responses": { "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "500": { "description": "Server Error" }, "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Household" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } } } }, "delete": { "tags": [ "Households" ], "operationId": "DeleteHouseholdAsync", "parameters": [ { "name": "householdId", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "500": { "description": "Server Error" }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "204": { "description": "Success" } } } }, "/api/v1/Households": { "post": { "tags": [ "Households" ], "summary": "CreateHouseholdAsync(Household householdToCreate)", "description": "Creates the provided householdToCreate", "operationId": "CreateHouseholdAsync", "requestBody": { "description": "A Household object. See !:api.API.Users.Mediators.CreateHouseholdValidator for validation information", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Household" } } } }, "responses": { "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "500": { "description": "Server Error" }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "201": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Household" } } } } } } }, "/api/v1/Users/{userId}": { "get": { "tags": [ "Users" ], "summary": "GetUserAsync(Guid userId)", "description": "Returns the User object for userId", "operationId": "GetUserAsync", "parameters": [ { "name": "userId", "in": "path", "description": "User ID for the User to get", "required": true, "schema": { "type": "string", "description": "User ID for the User to get", "format": "uuid" } } ], "responses": { "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "500": { "description": "Server Error" }, "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/User" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } } } } }, "/api/v1/Users": { "post": { "tags": [ "Users" ], "summary": "CreateUserAsync(User userToCreate)", "description": "Creates the provided userToCreate", "operationId": "CreateUserAsync", "requestBody": { "description": "A User object. See !:api.API.Users.Mediators.CreateUserValidator for validation information", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/User" } } } }, "responses": { "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "500": { "description": "Server Error" }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProblemDetails" } } } }, "201": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/User" } } } } } } } }, "components": { "schemas": { "ProblemDetails": { "type": "object", "properties": { "type": { "type": "string", "nullable": true }, "title": { "type": "string", "nullable": true }, "status": { "type": "integer", "format": "int32", "nullable": true }, "detail": { "type": "string", "nullable": true }, "instance": { "type": "string", "nullable": true } }, "additionalProperties": {} }, "User": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "householdId": { "type": "string", "format": "uuid" }, "createdAt": { "type": "string", "format": "date-time" }, "modifiedAt": { "type": "string", "format": "date-time" }, "fullName": { "type": "string", "nullable": true }, "email": { "type": "string", "nullable": true }, "identity": { "type": "string", "nullable": true }, "provider": { "type": "string", "nullable": true }, "subscriptionId": { "type": "string", "nullable": true }, "household": { "$ref": "#/components/schemas/Household" } }, "additionalProperties": false }, "Household": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string", "nullable": true }, "headOfHouseholdId": { "type": "string", "format": "uuid" }, "createdAt": { "type": "string", "format": "date-time" }, "modifiedAt": { "type": "string", "format": "date-time" }, "headOfHousehold": { "$ref": "#/components/schemas/User" } }, "additionalProperties": false } } } }