{ "openapi": "3.0.0", "components": { "examples": {}, "headers": {}, "parameters": {}, "requestBodies": {}, "responses": {}, "schemas": { "User": { "properties": { "id": { "type": "string" }, "orgId": { "type": "string" }, "fullName": { "type": "string" }, "email": { "type": "string" }, "role": { "type": "string" }, "timezone": { "type": "string" } }, "required": [ "id", "orgId", "fullName", "email", "role", "timezone" ], "type": "object", "additionalProperties": true }, "UsersEnvelope": { "properties": { "users": { "items": { "$ref": "#/components/schemas/User" }, "type": "array" } }, "required": [ "users" ], "type": "object", "additionalProperties": true }, "UserEnvelope": { "properties": { "user": { "$ref": "#/components/schemas/User" } }, "required": [ "user" ], "type": "object", "additionalProperties": true }, "Record_string.unknown_": { "properties": {}, "additionalProperties": {}, "type": "object", "description": "Construct a type with a set of properties K of type T" }, "ErrorResponse": { "properties": { "error": { "type": "string" }, "details": { "$ref": "#/components/schemas/Record_string.unknown_" } }, "required": [ "error" ], "type": "object", "additionalProperties": true }, "CreateUserRequest": { "properties": { "orgId": { "type": "string" }, "fullName": { "type": "string" }, "email": { "type": "string" }, "role": { "type": "string" }, "timezone": { "type": "string" } }, "required": [ "orgId", "fullName", "email", "role", "timezone" ], "type": "object", "additionalProperties": true }, "TaskListItem": { "properties": { "id": { "type": "string" }, "orgId": { "type": "string" }, "projectId": { "type": "string" }, "assigneeUserId": { "type": "string", "nullable": true }, "title": { "type": "string" }, "description": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "storyPoints": { "type": "number", "format": "double", "nullable": true }, "dueDate": { "type": "string", "nullable": true }, "createdAt": { "type": "string" }, "updatedAt": { "type": "string" }, "projectName": { "type": "string" }, "projectKey": { "type": "string" }, "assigneeName": { "type": "string", "nullable": true } }, "required": [ "id", "orgId", "projectId", "assigneeUserId", "title", "description", "status", "priority", "storyPoints", "dueDate", "createdAt", "updatedAt", "projectName", "projectKey", "assigneeName" ], "type": "object", "additionalProperties": true }, "TasksEnvelope": { "properties": { "tasks": { "items": { "$ref": "#/components/schemas/TaskListItem" }, "type": "array" } }, "required": [ "tasks" ], "type": "object", "additionalProperties": true }, "Label": { "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "color": { "type": "string" } }, "required": [ "id", "name", "color" ], "type": "object", "additionalProperties": true }, "Comment": { "properties": { "id": { "type": "string" }, "authorUserId": { "type": "string" }, "authorName": { "type": "string" }, "body": { "type": "string" }, "createdAt": { "type": "string" } }, "required": [ "id", "authorUserId", "authorName", "body", "createdAt" ], "type": "object", "additionalProperties": true }, "TaskDetail": { "properties": { "id": { "type": "string" }, "orgId": { "type": "string" }, "projectId": { "type": "string" }, "assigneeUserId": { "type": "string", "nullable": true }, "title": { "type": "string" }, "description": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "storyPoints": { "type": "number", "format": "double", "nullable": true }, "dueDate": { "type": "string", "nullable": true }, "createdAt": { "type": "string" }, "updatedAt": { "type": "string" }, "projectName": { "type": "string" }, "projectKey": { "type": "string" }, "assigneeName": { "type": "string", "nullable": true }, "labels": { "items": { "$ref": "#/components/schemas/Label" }, "type": "array" }, "comments": { "items": { "$ref": "#/components/schemas/Comment" }, "type": "array" } }, "required": [ "id", "orgId", "projectId", "assigneeUserId", "title", "description", "status", "priority", "storyPoints", "dueDate", "createdAt", "updatedAt", "projectName", "projectKey", "assigneeName", "labels", "comments" ], "type": "object", "additionalProperties": true }, "TaskEnvelope": { "properties": { "task": { "$ref": "#/components/schemas/TaskDetail" } }, "required": [ "task" ], "type": "object", "additionalProperties": true }, "CreateTaskRequest": { "properties": { "orgId": { "type": "string" }, "projectId": { "type": "string" }, "assigneeUserId": { "type": "string", "nullable": true }, "title": { "type": "string" }, "description": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "storyPoints": { "type": "number", "format": "double", "nullable": true }, "dueDate": { "type": "string", "nullable": true } }, "required": [ "orgId", "projectId", "title" ], "type": "object", "additionalProperties": true }, "UpdateTaskRequest": { "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "assigneeUserId": { "type": "string", "nullable": true }, "storyPoints": { "type": "number", "format": "double", "nullable": true }, "dueDate": { "type": "string", "nullable": true } }, "type": "object", "additionalProperties": true }, "Project": { "properties": { "id": { "type": "string" }, "orgId": { "type": "string" }, "key": { "type": "string" }, "name": { "type": "string" }, "status": { "type": "string" }, "ownerUserId": { "type": "string" }, "ownerName": { "type": "string", "nullable": true }, "dueDate": { "type": "string", "nullable": true }, "taskCount": { "type": "number", "format": "double" } }, "required": [ "id", "orgId", "key", "name", "status", "ownerUserId", "ownerName", "dueDate", "taskCount" ], "type": "object", "additionalProperties": true }, "ProjectsEnvelope": { "properties": { "projects": { "items": { "$ref": "#/components/schemas/Project" }, "type": "array" } }, "required": [ "projects" ], "type": "object", "additionalProperties": true }, "ProjectEnvelope": { "properties": { "project": { "$ref": "#/components/schemas/Project" } }, "required": [ "project" ], "type": "object", "additionalProperties": true }, "CreateProjectRequest": { "properties": { "orgId": { "type": "string" }, "key": { "type": "string" }, "name": { "type": "string" }, "status": { "type": "string" }, "ownerUserId": { "type": "string" }, "dueDate": { "type": "string", "nullable": true } }, "required": [ "orgId", "key", "name", "status", "ownerUserId" ], "type": "object", "additionalProperties": true }, "OrganizationSummaryListItem": { "properties": { "id": { "type": "string" }, "slug": { "type": "string" }, "name": { "type": "string" }, "plan": { "type": "string" }, "industry": { "type": "string" }, "createdAt": { "type": "string" }, "projectCount": { "type": "number", "format": "double" }, "taskCount": { "type": "number", "format": "double" }, "openTaskCount": { "type": "number", "format": "double" } }, "required": [ "id", "slug", "name", "plan", "industry", "createdAt", "projectCount", "taskCount", "openTaskCount" ], "type": "object", "additionalProperties": true }, "OrganizationsEnvelope": { "properties": { "organizations": { "items": { "$ref": "#/components/schemas/OrganizationSummaryListItem" }, "type": "array" } }, "required": [ "organizations" ], "type": "object", "additionalProperties": true }, "StatusBreakdownItem": { "properties": { "status": { "type": "string" }, "count": { "type": "number", "format": "double" } }, "required": [ "status", "count" ], "type": "object", "additionalProperties": true }, "OrganizationDetail": { "properties": { "id": { "type": "string" }, "slug": { "type": "string" }, "name": { "type": "string" }, "plan": { "type": "string" }, "industry": { "type": "string" }, "createdAt": { "type": "string" }, "projectCount": { "type": "number", "format": "double" }, "taskCount": { "type": "number", "format": "double" }, "openTaskCount": { "type": "number", "format": "double" }, "userCount": { "type": "number", "format": "double" }, "statusBreakdown": { "items": { "$ref": "#/components/schemas/StatusBreakdownItem" }, "type": "array" } }, "required": [ "id", "slug", "name", "plan", "industry", "createdAt", "projectCount", "taskCount", "openTaskCount", "userCount", "statusBreakdown" ], "type": "object", "additionalProperties": true }, "OrganizationEnvelope": { "properties": { "organization": { "$ref": "#/components/schemas/OrganizationDetail" } }, "required": [ "organization" ], "type": "object", "additionalProperties": true }, "CreateOrganizationRequest": { "properties": { "slug": { "type": "string" }, "name": { "type": "string" }, "plan": { "type": "string" }, "industry": { "type": "string" } }, "required": [ "slug", "name", "plan", "industry" ], "type": "object", "additionalProperties": true }, "HealthResponse": { "properties": { "status": { "type": "string", "enum": [ "ok" ], "nullable": false } }, "required": [ "status" ], "type": "object", "additionalProperties": true } }, "securitySchemes": {} }, "info": { "title": "poc-mock-task-api", "contact": {} }, "paths": { "/users": { "get": { "operationId": "ListUsers", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UsersEnvelope" } } } } }, "tags": [ "Users" ], "security": [], "parameters": [ { "in": "query", "name": "orgId", "required": false, "schema": { "type": "string" } } ] }, "post": { "operationId": "CreateUser", "responses": { "201": { "description": "Created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserEnvelope" } } } }, "400": { "description": "Invalid payload", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Users" ], "security": [], "parameters": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateUserRequest" } } } } } }, "/tasks": { "get": { "operationId": "ListTasks", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TasksEnvelope" } } } } }, "tags": [ "Tasks" ], "security": [], "parameters": [ { "in": "query", "name": "orgId", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "projectId", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "status", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "priority", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "assigneeUserId", "required": false, "schema": { "type": "string" } } ] }, "post": { "operationId": "CreateTask", "responses": { "201": { "description": "Created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TaskEnvelope" } } } }, "400": { "description": "Invalid payload", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Tasks" ], "security": [], "parameters": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateTaskRequest" } } } } } }, "/tasks/{taskId}": { "get": { "operationId": "GetTask", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TaskEnvelope" } } } }, "404": { "description": "Task not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Tasks" ], "security": [], "parameters": [ { "in": "path", "name": "taskId", "required": true, "schema": { "type": "string" } } ] }, "patch": { "operationId": "UpdateTask", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TaskEnvelope" } } } }, "404": { "description": "Task not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Tasks" ], "security": [], "parameters": [ { "in": "path", "name": "taskId", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateTaskRequest" } } } } } }, "/projects": { "get": { "operationId": "ListProjects", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectsEnvelope" } } } } }, "tags": [ "Projects" ], "security": [], "parameters": [ { "in": "query", "name": "orgId", "required": false, "schema": { "type": "string" } } ] }, "post": { "operationId": "CreateProject", "responses": { "201": { "description": "Created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectEnvelope" } } } }, "400": { "description": "Invalid payload", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Projects" ], "security": [], "parameters": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateProjectRequest" } } } } } }, "/orgs": { "get": { "operationId": "ListOrganizations", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrganizationsEnvelope" } } } } }, "tags": [ "Organizations" ], "security": [], "parameters": [] }, "post": { "operationId": "CreateOrganization", "responses": { "201": { "description": "Created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrganizationEnvelope" } } } }, "400": { "description": "Invalid payload", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Organizations" ], "security": [], "parameters": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateOrganizationRequest" } } } } } }, "/orgs/{orgId}": { "get": { "operationId": "GetOrganization", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrganizationEnvelope" } } } }, "404": { "description": "Organization not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "Organizations" ], "security": [], "parameters": [ { "in": "path", "name": "orgId", "required": true, "schema": { "type": "string" } } ] } }, "/orgs/{orgId}/projects": { "get": { "operationId": "ListOrganizationProjects", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectsEnvelope" } } } } }, "tags": [ "Organizations" ], "security": [], "parameters": [ { "in": "path", "name": "orgId", "required": true, "schema": { "type": "string" } } ] } }, "/orgs/{orgId}/tasks": { "get": { "operationId": "ListOrganizationTasks", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TasksEnvelope" } } } } }, "tags": [ "Organizations" ], "security": [], "parameters": [ { "in": "path", "name": "orgId", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "projectId", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "status", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "priority", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "assigneeUserId", "required": false, "schema": { "type": "string" } } ] } }, "/health": { "get": { "operationId": "GetHealth", "responses": { "200": { "description": "Ok", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HealthResponse" } } } } }, "tags": [ "Health" ], "security": [], "parameters": [] } } }, "servers": [ { "url": "/" } ] }