diff --git a/api-docs/.openapi-generator-ignore b/api-docs/.openapi-generator-ignore new file mode 100644 index 00000000..7484ee59 --- /dev/null +++ b/api-docs/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/api-docs/.openapi-generator/FILES b/api-docs/.openapi-generator/FILES new file mode 100644 index 00000000..9f0d0be5 --- /dev/null +++ b/api-docs/.openapi-generator/FILES @@ -0,0 +1,55 @@ +.openapi-generator-ignore +Apis/AnswersApi.md +Apis/AuthApi.md +Apis/CodeExecutionApi.md +Apis/FeedApi.md +Apis/QuestionsApi.md +Apis/SearchApi.md +Apis/TagsApi.md +Apis/UserApi.md +Apis/UsersApi.md +Models/AnswerDetails.md +Models/AuthToken.md +Models/CodeExecution.md +Models/DifficultyLevel.md +Models/Error.md +Models/ErrorResponseObject.md +Models/ExecutionResult.md +Models/ExperienceLevel.md +Models/NewAnswer.md +Models/NewQuestion.md +Models/NewTag.md +Models/Profile.md +Models/QuestionDetails.md +Models/QuestionSummary.md +Models/SuccessResponseObject.md +Models/SuccessResponseObject_data.md +Models/TagDetails.md +Models/TagSummary.md +Models/TagType.md +Models/UpdateAnswer.md +Models/UpdateProfile.md +Models/UpdateQuestion.md +Models/UserLogin.md +Models/UserProfile.md +Models/UserProfileUpdate.md +Models/UserRegistration.md +Models/UserSummary.md +Models/createAnswer_201_response.md +Models/createQuestion_201_response.md +Models/createTag_201_response.md +Models/executeCode_200_response.md +Models/getQuestionAnswers_200_response.md +Models/getQuestionAnswers_200_response_allOf_data.md +Models/getUserFollowers_200_response.md +Models/getUserProfile_200_response.md +Models/resetPassword_request.md +Models/searchQuestions_200_response.md +Models/searchQuestions_200_response_allOf_data.md +Models/searchTags_200_response.md +Models/searchTags_200_response_allOf_data.md +Models/searchUsers_200_response.md +Models/searchUsers_200_response_allOf_data.md +Models/signUp_201_response.md +Models/verifyEmail_request.md +README.md diff --git a/api-docs/.openapi-generator/VERSION b/api-docs/.openapi-generator/VERSION new file mode 100644 index 00000000..758bb9c8 --- /dev/null +++ b/api-docs/.openapi-generator/VERSION @@ -0,0 +1 @@ +7.10.0 diff --git a/api-docs/Apis/AnswersApi.md b/api-docs/Apis/AnswersApi.md new file mode 100644 index 00000000..f06b23e9 --- /dev/null +++ b/api-docs/Apis/AnswersApi.md @@ -0,0 +1,166 @@ +# AnswersApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**createAnswer**](AnswersApi.md#createAnswer) | **POST** /questions/{questionId}/answers | Create a new answer | +| [**deleteAnswer**](AnswersApi.md#deleteAnswer) | **DELETE** /answers/{answerId} | Delete an answer | +| [**downvoteAnswer**](AnswersApi.md#downvoteAnswer) | **POST** /answers/{answerId}/downvote | Downvote an answer | +| [**getQuestionAnswers**](AnswersApi.md#getQuestionAnswers) | **GET** /questions/{questionId}/answers | Get answers for a question | +| [**updateAnswer**](AnswersApi.md#updateAnswer) | **PUT** /answers/{answerId} | Update an answer | +| [**upvoteAnswer**](AnswersApi.md#upvoteAnswer) | **POST** /answers/{answerId}/upvote | Upvote an answer | + + + +# **createAnswer** +> createAnswer_201_response createAnswer(questionId, NewAnswer) + +Create a new answer + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | +| **NewAnswer** | [**NewAnswer**](../Models/NewAnswer.md)| | | + +### Return type + +[**createAnswer_201_response**](../Models/createAnswer_201_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **deleteAnswer** +> deleteAnswer(answerId) + +Delete an answer + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **answerId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **downvoteAnswer** +> downvoteAnswer(answerId) + +Downvote an answer + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **answerId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getQuestionAnswers** +> getQuestionAnswers_200_response getQuestionAnswers(questionId) + +Get answers for a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +[**getQuestionAnswers_200_response**](../Models/getQuestionAnswers_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **updateAnswer** +> createAnswer_201_response updateAnswer(answerId, UpdateAnswer) + +Update an answer + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **answerId** | **Integer**| | [default to null] | +| **UpdateAnswer** | [**UpdateAnswer**](../Models/UpdateAnswer.md)| | | + +### Return type + +[**createAnswer_201_response**](../Models/createAnswer_201_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **upvoteAnswer** +> upvoteAnswer(answerId) + +Upvote an answer + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **answerId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/AuthApi.md b/api-docs/Apis/AuthApi.md new file mode 100644 index 00000000..367c883f --- /dev/null +++ b/api-docs/Apis/AuthApi.md @@ -0,0 +1,135 @@ +# AuthApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**login**](AuthApi.md#login) | **POST** /auth/login | User login | +| [**logout**](AuthApi.md#logout) | **POST** /auth/logout | User logout | +| [**resetPassword**](AuthApi.md#resetPassword) | **POST** /auth/reset-password | Reset user's password | +| [**signUp**](AuthApi.md#signUp) | **POST** /auth/signup | Register a new user | +| [**verifyEmail**](AuthApi.md#verifyEmail) | **POST** /auth/verify-email | Verify user's email | + + + +# **login** +> signUp_201_response login(UserLogin) + +User login + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **UserLogin** | [**UserLogin**](../Models/UserLogin.md)| | | + +### Return type + +[**signUp_201_response**](../Models/signUp_201_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **logout** +> logout() + +User logout + +### Parameters +This endpoint does not need any parameter. + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **resetPassword** +> resetPassword(resetPassword\_request) + +Reset user's password + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **resetPassword\_request** | [**resetPassword_request**](../Models/resetPassword_request.md)| | | + +### Return type + +null (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **signUp** +> signUp_201_response signUp(UserRegistration) + +Register a new user + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **UserRegistration** | [**UserRegistration**](../Models/UserRegistration.md)| | | + +### Return type + +[**signUp_201_response**](../Models/signUp_201_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **verifyEmail** +> verifyEmail(verifyEmail\_request) + +Verify user's email + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **verifyEmail\_request** | [**verifyEmail_request**](../Models/verifyEmail_request.md)| | | + +### Return type + +null (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + diff --git a/api-docs/Apis/CodeExecutionApi.md b/api-docs/Apis/CodeExecutionApi.md new file mode 100644 index 00000000..185aab0a --- /dev/null +++ b/api-docs/Apis/CodeExecutionApi.md @@ -0,0 +1,34 @@ +# CodeExecutionApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**executeCode**](CodeExecutionApi.md#executeCode) | **POST** /execute-code | Execute a code snippet | + + + +# **executeCode** +> executeCode_200_response executeCode(CodeExecution) + +Execute a code snippet + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **CodeExecution** | [**CodeExecution**](../Models/CodeExecution.md)| | | + +### Return type + +[**executeCode_200_response**](../Models/executeCode_200_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + diff --git a/api-docs/Apis/FeedApi.md b/api-docs/Apis/FeedApi.md new file mode 100644 index 00000000..1f1877fd --- /dev/null +++ b/api-docs/Apis/FeedApi.md @@ -0,0 +1,36 @@ +# FeedApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**getUserFeed**](FeedApi.md#getUserFeed) | **GET** /feed | Get user feed | + + + +# **getUserFeed** +> searchQuestions_200_response getUserFeed(type, page, pageSize) + +Get user feed + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **type** | **String**| Feed type | [default to null] [enum: recent, topRated, recommended] | +| **page** | **Integer**| Page number | [optional] [default to 1] | +| **pageSize** | **Integer**| Number of items per page | [optional] [default to 20] | + +### Return type + +[**searchQuestions_200_response**](../Models/searchQuestions_200_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/QuestionsApi.md b/api-docs/Apis/QuestionsApi.md new file mode 100644 index 00000000..20fcf6a0 --- /dev/null +++ b/api-docs/Apis/QuestionsApi.md @@ -0,0 +1,217 @@ +# QuestionsApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**bookmarkQuestion**](QuestionsApi.md#bookmarkQuestion) | **POST** /questions/{questionId}/bookmark | Bookmark a question | +| [**createQuestion**](QuestionsApi.md#createQuestion) | **POST** /questions | Create a new question | +| [**deleteQuestion**](QuestionsApi.md#deleteQuestion) | **DELETE** /questions/{questionId} | Delete a question | +| [**downvoteQuestion**](QuestionsApi.md#downvoteQuestion) | **POST** /questions/{questionId}/downvote | Downvote a question | +| [**getQuestionDetails**](QuestionsApi.md#getQuestionDetails) | **GET** /questions/{questionId} | Get question details | +| [**removeQuestionBookmark**](QuestionsApi.md#removeQuestionBookmark) | **DELETE** /questions/{questionId}/bookmark | Remove bookmark from a question | +| [**updateQuestion**](QuestionsApi.md#updateQuestion) | **PUT** /questions/{questionId} | Update a question | +| [**upvoteQuestion**](QuestionsApi.md#upvoteQuestion) | **POST** /questions/{questionId}/upvote | Upvote a question | + + + +# **bookmarkQuestion** +> bookmarkQuestion(questionId) + +Bookmark a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **createQuestion** +> createQuestion_201_response createQuestion(NewQuestion) + +Create a new question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **NewQuestion** | [**NewQuestion**](../Models/NewQuestion.md)| | | + +### Return type + +[**createQuestion_201_response**](../Models/createQuestion_201_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **deleteQuestion** +> deleteQuestion(questionId) + +Delete a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **downvoteQuestion** +> downvoteQuestion(questionId) + +Downvote a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getQuestionDetails** +> createQuestion_201_response getQuestionDetails(questionId) + +Get question details + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +[**createQuestion_201_response**](../Models/createQuestion_201_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **removeQuestionBookmark** +> removeQuestionBookmark(questionId) + +Remove bookmark from a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **updateQuestion** +> createQuestion_201_response updateQuestion(questionId, UpdateQuestion) + +Update a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | +| **UpdateQuestion** | [**UpdateQuestion**](../Models/UpdateQuestion.md)| | | + +### Return type + +[**createQuestion_201_response**](../Models/createQuestion_201_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **upvoteQuestion** +> upvoteQuestion(questionId) + +Upvote a question + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **questionId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/SearchApi.md b/api-docs/Apis/SearchApi.md new file mode 100644 index 00000000..9901d6a4 --- /dev/null +++ b/api-docs/Apis/SearchApi.md @@ -0,0 +1,94 @@ +# SearchApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**searchQuestions**](SearchApi.md#searchQuestions) | **GET** /search/questions | Search questions | +| [**searchTags**](SearchApi.md#searchTags) | **GET** /search/tags | Search tags | +| [**searchUsers**](SearchApi.md#searchUsers) | **GET** /search/users | Search users | + + + +# **searchQuestions** +> searchQuestions_200_response searchQuestions(q, tags, difficulty, page, pageSize) + +Search questions + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **q** | **String**| Search query | [default to null] | +| **tags** | **String**| Comma-separated list of tag IDs | [optional] [default to null] | +| **difficulty** | [**DifficultyLevel**](../Models/.md)| Filter by difficulty level | [optional] [default to null] [enum: EASY, MEDIUM, HARD] | +| **page** | **Integer**| Page number | [optional] [default to 1] | +| **pageSize** | **Integer**| Number of items per page | [optional] [default to 20] | + +### Return type + +[**searchQuestions_200_response**](../Models/searchQuestions_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **searchTags** +> searchTags_200_response searchTags(q, page, pageSize) + +Search tags + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **q** | **String**| Search query | [default to null] | +| **page** | **Integer**| Page number | [optional] [default to 1] | +| **pageSize** | **Integer**| Number of items per page | [optional] [default to 20] | + +### Return type + +[**searchTags_200_response**](../Models/searchTags_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **searchUsers** +> searchUsers_200_response searchUsers(q, page, pageSize) + +Search users + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **q** | **String**| Search query | [default to null] | +| **page** | **Integer**| Page number | [optional] [default to 1] | +| **pageSize** | **Integer**| Number of items per page | [optional] [default to 20] | + +### Return type + +[**searchUsers_200_response**](../Models/searchUsers_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/TagsApi.md b/api-docs/Apis/TagsApi.md new file mode 100644 index 00000000..32db1fc6 --- /dev/null +++ b/api-docs/Apis/TagsApi.md @@ -0,0 +1,112 @@ +# TagsApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**createTag**](TagsApi.md#createTag) | **POST** /tags | Create a new tag | +| [**followTag**](TagsApi.md#followTag) | **POST** /tags/{tagId}/follow | Follow a tag | +| [**getTagDetails**](TagsApi.md#getTagDetails) | **GET** /tags/{tagId} | Get tag details | +| [**unfollowTag**](TagsApi.md#unfollowTag) | **DELETE** /tags/{tagId}/follow | Unfollow a tag | + + + +# **createTag** +> createTag_201_response createTag(NewTag) + +Create a new tag + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **NewTag** | [**NewTag**](../Models/NewTag.md)| | | + +### Return type + +[**createTag_201_response**](../Models/createTag_201_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +# **followTag** +> followTag(tagId) + +Follow a tag + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **tagId** | **String**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getTagDetails** +> createTag_201_response getTagDetails(tagId) + +Get tag details + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **tagId** | **String**| | [default to null] | + +### Return type + +[**createTag_201_response**](../Models/createTag_201_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **unfollowTag** +> unfollowTag(tagId) + +Unfollow a tag + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **tagId** | **String**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/UserApi.md b/api-docs/Apis/UserApi.md new file mode 100644 index 00000000..000741e0 --- /dev/null +++ b/api-docs/Apis/UserApi.md @@ -0,0 +1,31 @@ +# UserApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**getMe**](UserApi.md#getMe) | **GET** /users/me | Get own profile | + + + +# **getMe** +> getUserProfile_200_response getMe() + +Get own profile + +### Parameters +This endpoint does not need any parameter. + +### Return type + +[**getUserProfile_200_response**](../Models/getUserProfile_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + diff --git a/api-docs/Apis/UsersApi.md b/api-docs/Apis/UsersApi.md new file mode 100644 index 00000000..d6ef8b70 --- /dev/null +++ b/api-docs/Apis/UsersApi.md @@ -0,0 +1,165 @@ +# UsersApi + +All URIs are relative to *http://localhost:5173/api/v1* + +| Method | HTTP request | Description | +|------------- | ------------- | -------------| +| [**followUser**](UsersApi.md#followUser) | **POST** /users/{userId}/follow | Follow a user | +| [**getUserFollowers**](UsersApi.md#getUserFollowers) | **GET** /users/{userId}/followers | Get user's followers | +| [**getUserFollowing**](UsersApi.md#getUserFollowing) | **GET** /users/{userId}/following | Get users being followed | +| [**getUserProfile**](UsersApi.md#getUserProfile) | **GET** /users/{userId} | Get user profile | +| [**unfollowUser**](UsersApi.md#unfollowUser) | **DELETE** /users/{userId}/unfollow | Unfollow a user | +| [**updateUserProfile**](UsersApi.md#updateUserProfile) | **PUT** /users/{userId} | Update user profile | + + + +# **followUser** +> followUser(userId) + +Follow a user + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getUserFollowers** +> getUserFollowers_200_response getUserFollowers(userId) + +Get user's followers + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | + +### Return type + +[**getUserFollowers_200_response**](../Models/getUserFollowers_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getUserFollowing** +> getUserFollowers_200_response getUserFollowing(userId) + +Get users being followed + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | + +### Return type + +[**getUserFollowers_200_response**](../Models/getUserFollowers_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **getUserProfile** +> getUserProfile_200_response getUserProfile(userId) + +Get user profile + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | + +### Return type + +[**getUserProfile_200_response**](../Models/getUserProfile_200_response.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **unfollowUser** +> unfollowUser(userId) + +Unfollow a user + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | + +### Return type + +null (empty response body) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +# **updateUserProfile** +> getUserProfile_200_response updateUserProfile(userId, UserProfileUpdate) + +Update user profile + +### Parameters + +|Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **userId** | **Integer**| | [default to null] | +| **UserProfileUpdate** | [**UserProfileUpdate**](../Models/UserProfileUpdate.md)| | | + +### Return type + +[**getUserProfile_200_response**](../Models/getUserProfile_200_response.md) + +### Authorization + +[bearerAuth](../README.md#bearerAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + diff --git a/api-docs/Models/AnswerDetails.md b/api-docs/Models/AnswerDetails.md new file mode 100644 index 00000000..e8a69316 --- /dev/null +++ b/api-docs/Models/AnswerDetails.md @@ -0,0 +1,18 @@ +# AnswerDetails +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [default to null] | +| **content** | **String** | | [default to null] | +| **author** | [**UserSummary**](UserSummary.md) | | [default to null] | +| **createdAt** | **Date** | | [default to null] | +| **updatedAt** | **Date** | | [default to null] | +| **rating** | **Integer** | | [default to null] | +| **selfVoted** | **Integer** | | [optional] [default to null] | +| **upvoteCount** | **Integer** | | [optional] [default to null] | +| **downvoteCount** | **Integer** | | [optional] [default to null] | +| **question** | [**QuestionSummary**](QuestionSummary.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/AuthToken.md b/api-docs/Models/AuthToken.md new file mode 100644 index 00000000..6e4484c9 --- /dev/null +++ b/api-docs/Models/AuthToken.md @@ -0,0 +1,9 @@ +# AuthToken +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **token** | **String** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/CodeExecution.md b/api-docs/Models/CodeExecution.md new file mode 100644 index 00000000..7369b909 --- /dev/null +++ b/api-docs/Models/CodeExecution.md @@ -0,0 +1,11 @@ +# CodeExecution +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **code** | **String** | The code snippet to be executed | [default to null] | +| **language** | **String** | The programming language of the code snippet | [default to null] | +| **input** | **String** | Optional input for the code execution | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/DifficultyLevel.md b/api-docs/Models/DifficultyLevel.md new file mode 100644 index 00000000..6f4900b5 --- /dev/null +++ b/api-docs/Models/DifficultyLevel.md @@ -0,0 +1,8 @@ +# DifficultyLevel +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/Error.md b/api-docs/Models/Error.md new file mode 100644 index 00000000..49948b2d --- /dev/null +++ b/api-docs/Models/Error.md @@ -0,0 +1,10 @@ +# Error +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **errorMessage** | **String** | | [optional] [default to null] | +| **stackTrace** | **String** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/ErrorResponseObject.md b/api-docs/Models/ErrorResponseObject.md new file mode 100644 index 00000000..a4fab2d1 --- /dev/null +++ b/api-docs/Models/ErrorResponseObject.md @@ -0,0 +1,10 @@ +# ErrorResponseObject +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **BigDecimal** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **error** | [**Error**](Error.md) | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/ExecutionResult.md b/api-docs/Models/ExecutionResult.md new file mode 100644 index 00000000..2bb3832b --- /dev/null +++ b/api-docs/Models/ExecutionResult.md @@ -0,0 +1,12 @@ +# ExecutionResult +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **output** | **String** | The standard output of the code execution | [optional] [default to null] | +| **errors** | **String** | Any error messages or standard error output | [optional] [default to null] | +| **executionTime** | **BigDecimal** | The time taken to execute the code in milliseconds | [optional] [default to null] | +| **status** | **String** | The status of the code execution | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/ExperienceLevel.md b/api-docs/Models/ExperienceLevel.md new file mode 100644 index 00000000..5d04a32b --- /dev/null +++ b/api-docs/Models/ExperienceLevel.md @@ -0,0 +1,8 @@ +# ExperienceLevel +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/NewAnswer.md b/api-docs/Models/NewAnswer.md new file mode 100644 index 00000000..d6ff30bb --- /dev/null +++ b/api-docs/Models/NewAnswer.md @@ -0,0 +1,9 @@ +# NewAnswer +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **content** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/NewQuestion.md b/api-docs/Models/NewQuestion.md new file mode 100644 index 00000000..31318eaf --- /dev/null +++ b/api-docs/Models/NewQuestion.md @@ -0,0 +1,12 @@ +# NewQuestion +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **title** | **String** | | [default to null] | +| **content** | **String** | | [default to null] | +| **tagIds** | **List** | | [optional] [default to null] | +| **difficultyLevel** | [**DifficultyLevel**](DifficultyLevel.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/NewTag.md b/api-docs/Models/NewTag.md new file mode 100644 index 00000000..287788ae --- /dev/null +++ b/api-docs/Models/NewTag.md @@ -0,0 +1,10 @@ +# NewTag +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **name** | **String** | | [default to null] | +| **description** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/Profile.md b/api-docs/Models/Profile.md new file mode 100644 index 00000000..3f453129 --- /dev/null +++ b/api-docs/Models/Profile.md @@ -0,0 +1,20 @@ +# Profile +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [optional] [default to null] | +| **username** | **String** | | [optional] [default to null] | +| **bio** | **String** | | [optional] [default to null] | +| **reputationPoints** | **Integer** | | [optional] [default to null] | +| **followersCount** | **Integer** | | [optional] [default to null] | +| **followingCount** | **Integer** | | [optional] [default to null] | +| **selfFollowing** | **Boolean** | | [optional] [default to null] | +| **questionCount** | **Integer** | | [optional] [default to null] | +| **questions** | [**List**](QuestionSummary.md) | | [optional] [default to null] | +| **answerCount** | **Integer** | | [optional] [default to null] | +| **answers** | [**List**](AnswerDetails.md) | | [optional] [default to null] | +| **tags** | [**List**](TagSummary.md) | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/QuestionDetails.md b/api-docs/Models/QuestionDetails.md new file mode 100644 index 00000000..522a8136 --- /dev/null +++ b/api-docs/Models/QuestionDetails.md @@ -0,0 +1,21 @@ +# QuestionDetails +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [default to null] | +| **title** | **String** | | [default to null] | +| **content** | **String** | | [default to null] | +| **author** | [**UserSummary**](UserSummary.md) | | [default to null] | +| **createdAt** | **Date** | | [default to null] | +| **updatedAt** | **Date** | | [default to null] | +| **tags** | [**List**](TagSummary.md) | | [default to null] | +| **likeCount** | **Integer** | | [default to null] | +| **dislikeCount** | **Integer** | | [default to null] | +| **commentCount** | **Integer** | | [default to null] | +| **viewCount** | **Integer** | | [optional] [default to null] | +| **bookmarked** | **Boolean** | | [optional] [default to null] | +| **selfVoted** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/QuestionSummary.md b/api-docs/Models/QuestionSummary.md new file mode 100644 index 00000000..e235f557 --- /dev/null +++ b/api-docs/Models/QuestionSummary.md @@ -0,0 +1,18 @@ +# QuestionSummary +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [default to null] | +| **title** | **String** | | [default to null] | +| **questionBody** | **String** | | [optional] [default to null] | +| **author** | [**UserSummary**](UserSummary.md) | | [optional] [default to null] | +| **createdAt** | **Date** | | [default to null] | +| **difficultyLevel** | [**DifficultyLevel**](DifficultyLevel.md) | | [default to null] | +| **tags** | [**List**](TagSummary.md) | | [default to null] | +| **likeCount** | **Integer** | | [default to null] | +| **commentCount** | **Integer** | | [default to null] | +| **viewCount** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/SuccessResponseObject.md b/api-docs/Models/SuccessResponseObject.md new file mode 100644 index 00000000..43ac82e2 --- /dev/null +++ b/api-docs/Models/SuccessResponseObject.md @@ -0,0 +1,10 @@ +# SuccessResponseObject +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**SuccessResponseObject_data**](SuccessResponseObject_data.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/SuccessResponseObject_data.md b/api-docs/Models/SuccessResponseObject_data.md new file mode 100644 index 00000000..bb51f55f --- /dev/null +++ b/api-docs/Models/SuccessResponseObject_data.md @@ -0,0 +1,8 @@ +# SuccessResponseObject_data +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/TagDetails.md b/api-docs/Models/TagDetails.md new file mode 100644 index 00000000..071dfa9f --- /dev/null +++ b/api-docs/Models/TagDetails.md @@ -0,0 +1,23 @@ +# TagDetails +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **tagId** | **String** | | [default to null] | +| **name** | **String** | | [default to null] | +| **tagType** | [**TagType**](TagType.md) | | [optional] [default to null] | +| **description** | **String** | | [default to null] | +| **questionCount** | **Integer** | | [optional] [default to null] | +| **followerCount** | **Integer** | | [optional] [default to null] | +| **following** | **Boolean** | | [optional] [default to null] | +| **highlightedQuestions** | [**List**](QuestionSummary.md) | | [optional] [default to null] | +| **logoImage** | **String** | For Programming Language tags | [default to null] | +| **author** | **String** | For Programming Language tags | [optional] [default to null] | +| **inceptionYear** | **String** | For Programming Language tags | [optional] [default to null] | +| **fileExtension** | **String** | For Programming Language tags | [optional] [default to null] | +| **officialWebsite** | **String** | For Programming Language tags | [default to null] | +| **stackExchangeTag** | **String** | Available for Programming Language, Programming Paradigm and Computer Science Term tags | [optional] [default to null] | +| **relatedQuestions** | [**List**](QuestionSummary.md) | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/TagSummary.md b/api-docs/Models/TagSummary.md new file mode 100644 index 00000000..50324417 --- /dev/null +++ b/api-docs/Models/TagSummary.md @@ -0,0 +1,12 @@ +# TagSummary +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **String** | | [optional] [default to null] | +| **name** | **String** | | [optional] [default to null] | +| **questionCount** | **Integer** | | [optional] [default to null] | +| **photo** | **String** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/TagType.md b/api-docs/Models/TagType.md new file mode 100644 index 00000000..db46c54f --- /dev/null +++ b/api-docs/Models/TagType.md @@ -0,0 +1,8 @@ +# TagType +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UpdateAnswer.md b/api-docs/Models/UpdateAnswer.md new file mode 100644 index 00000000..8fc9712b --- /dev/null +++ b/api-docs/Models/UpdateAnswer.md @@ -0,0 +1,9 @@ +# UpdateAnswer +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **content** | **String** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UpdateProfile.md b/api-docs/Models/UpdateProfile.md new file mode 100644 index 00000000..c24166cc --- /dev/null +++ b/api-docs/Models/UpdateProfile.md @@ -0,0 +1,10 @@ +# UpdateProfile +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **bio** | **String** | | [optional] [default to null] | +| **tags** | **List** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UpdateQuestion.md b/api-docs/Models/UpdateQuestion.md new file mode 100644 index 00000000..d4393e1a --- /dev/null +++ b/api-docs/Models/UpdateQuestion.md @@ -0,0 +1,11 @@ +# UpdateQuestion +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **title** | **String** | | [optional] [default to null] | +| **content** | **String** | | [optional] [default to null] | +| **tags** | **List** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UserLogin.md b/api-docs/Models/UserLogin.md new file mode 100644 index 00000000..925c3d28 --- /dev/null +++ b/api-docs/Models/UserLogin.md @@ -0,0 +1,10 @@ +# UserLogin +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **usernameOrEmail** | **String** | | [default to null] | +| **password** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UserProfile.md b/api-docs/Models/UserProfile.md new file mode 100644 index 00000000..6901036d --- /dev/null +++ b/api-docs/Models/UserProfile.md @@ -0,0 +1,24 @@ +# UserProfile +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [optional] [default to null] | +| **username** | **String** | | [optional] [default to null] | +| **email** | **String** | | [optional] [default to null] | +| **firstName** | **String** | | [optional] [default to null] | +| **lastName** | **String** | | [optional] [default to null] | +| **bio** | **String** | | [optional] [default to null] | +| **country** | **String** | | [optional] [default to null] | +| **reputationPoints** | **Integer** | | [optional] [default to null] | +| **followersCount** | **Integer** | | [optional] [default to null] | +| **followingCount** | **Integer** | | [optional] [default to null] | +| **selfFollowing** | **Boolean** | | [optional] [default to null] | +| **questionCount** | **Integer** | | [optional] [default to null] | +| **experienceLevel** | [**ExperienceLevel**](ExperienceLevel.md) | | [optional] [default to null] | +| **answerCount** | **Integer** | | [optional] [default to null] | +| **answers** | [**List**](AnswerDetails.md) | | [optional] [default to null] | +| **questions** | [**List**](QuestionSummary.md) | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UserProfileUpdate.md b/api-docs/Models/UserProfileUpdate.md new file mode 100644 index 00000000..f394a3d3 --- /dev/null +++ b/api-docs/Models/UserProfileUpdate.md @@ -0,0 +1,11 @@ +# UserProfileUpdate +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **bio** | **String** | | [optional] [default to null] | +| **country** | **String** | | [optional] [default to null] | +| **experienceLevel** | [**ExperienceLevel**](ExperienceLevel.md) | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UserRegistration.md b/api-docs/Models/UserRegistration.md new file mode 100644 index 00000000..0f6f9bc6 --- /dev/null +++ b/api-docs/Models/UserRegistration.md @@ -0,0 +1,15 @@ +# UserRegistration +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **username** | **String** | | [default to null] | +| **email** | **String** | | [default to null] | +| **password** | **String** | | [default to null] | +| **firstName** | **String** | | [default to null] | +| **lastName** | **String** | | [default to null] | +| **country** | **String** | | [default to null] | +| **experienceLevel** | [**ExperienceLevel**](ExperienceLevel.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/UserSummary.md b/api-docs/Models/UserSummary.md new file mode 100644 index 00000000..d83164ee --- /dev/null +++ b/api-docs/Models/UserSummary.md @@ -0,0 +1,13 @@ +# UserSummary +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **id** | **Integer** | | [default to null] | +| **username** | **String** | | [default to null] | +| **reputationPoints** | **Integer** | | [default to null] | +| **profilePicture** | **String** | | [default to null] | +| **name** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/createAnswer_201_response.md b/api-docs/Models/createAnswer_201_response.md new file mode 100644 index 00000000..9b8dc137 --- /dev/null +++ b/api-docs/Models/createAnswer_201_response.md @@ -0,0 +1,10 @@ +# createAnswer_201_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**AnswerDetails**](AnswerDetails.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/createQuestion_201_response.md b/api-docs/Models/createQuestion_201_response.md new file mode 100644 index 00000000..18d19b80 --- /dev/null +++ b/api-docs/Models/createQuestion_201_response.md @@ -0,0 +1,10 @@ +# createQuestion_201_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**QuestionDetails**](QuestionDetails.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/createTag_201_response.md b/api-docs/Models/createTag_201_response.md new file mode 100644 index 00000000..80778042 --- /dev/null +++ b/api-docs/Models/createTag_201_response.md @@ -0,0 +1,10 @@ +# createTag_201_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**TagDetails**](TagDetails.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/executeCode_200_response.md b/api-docs/Models/executeCode_200_response.md new file mode 100644 index 00000000..6d740826 --- /dev/null +++ b/api-docs/Models/executeCode_200_response.md @@ -0,0 +1,10 @@ +# executeCode_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**ExecutionResult**](ExecutionResult.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/getQuestionAnswers_200_response.md b/api-docs/Models/getQuestionAnswers_200_response.md new file mode 100644 index 00000000..0af3bbe1 --- /dev/null +++ b/api-docs/Models/getQuestionAnswers_200_response.md @@ -0,0 +1,10 @@ +# getQuestionAnswers_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**getQuestionAnswers_200_response_allOf_data**](getQuestionAnswers_200_response_allOf_data.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/getQuestionAnswers_200_response_allOf_data.md b/api-docs/Models/getQuestionAnswers_200_response_allOf_data.md new file mode 100644 index 00000000..4b0ab63d --- /dev/null +++ b/api-docs/Models/getQuestionAnswers_200_response_allOf_data.md @@ -0,0 +1,10 @@ +# getQuestionAnswers_200_response_allOf_data +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **items** | [**List**](AnswerDetails.md) | | [optional] [default to null] | +| **totalPages** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/getUserFollowers_200_response.md b/api-docs/Models/getUserFollowers_200_response.md new file mode 100644 index 00000000..ddcc645a --- /dev/null +++ b/api-docs/Models/getUserFollowers_200_response.md @@ -0,0 +1,10 @@ +# getUserFollowers_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**List**](UserSummary.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/getUserProfile_200_response.md b/api-docs/Models/getUserProfile_200_response.md new file mode 100644 index 00000000..9f005dc5 --- /dev/null +++ b/api-docs/Models/getUserProfile_200_response.md @@ -0,0 +1,10 @@ +# getUserProfile_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**UserProfile**](UserProfile.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/resetPassword_request.md b/api-docs/Models/resetPassword_request.md new file mode 100644 index 00000000..74f992e6 --- /dev/null +++ b/api-docs/Models/resetPassword_request.md @@ -0,0 +1,9 @@ +# resetPassword_request +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **email** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchQuestions_200_response.md b/api-docs/Models/searchQuestions_200_response.md new file mode 100644 index 00000000..54b117ca --- /dev/null +++ b/api-docs/Models/searchQuestions_200_response.md @@ -0,0 +1,10 @@ +# searchQuestions_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**searchQuestions_200_response_allOf_data**](searchQuestions_200_response_allOf_data.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchQuestions_200_response_allOf_data.md b/api-docs/Models/searchQuestions_200_response_allOf_data.md new file mode 100644 index 00000000..139dca66 --- /dev/null +++ b/api-docs/Models/searchQuestions_200_response_allOf_data.md @@ -0,0 +1,12 @@ +# searchQuestions_200_response_allOf_data +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **items** | [**List**](QuestionSummary.md) | | [optional] [default to null] | +| **totalItems** | **Integer** | | [optional] [default to null] | +| **currentPage** | **Integer** | | [optional] [default to null] | +| **totalPages** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchTags_200_response.md b/api-docs/Models/searchTags_200_response.md new file mode 100644 index 00000000..306a6171 --- /dev/null +++ b/api-docs/Models/searchTags_200_response.md @@ -0,0 +1,10 @@ +# searchTags_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**searchTags_200_response_allOf_data**](searchTags_200_response_allOf_data.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchTags_200_response_allOf_data.md b/api-docs/Models/searchTags_200_response_allOf_data.md new file mode 100644 index 00000000..488fc10f --- /dev/null +++ b/api-docs/Models/searchTags_200_response_allOf_data.md @@ -0,0 +1,12 @@ +# searchTags_200_response_allOf_data +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **items** | [**List**](TagDetails.md) | | [optional] [default to null] | +| **totalItems** | **Integer** | | [optional] [default to null] | +| **currentPage** | **Integer** | | [optional] [default to null] | +| **totalPages** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchUsers_200_response.md b/api-docs/Models/searchUsers_200_response.md new file mode 100644 index 00000000..98ba1aa3 --- /dev/null +++ b/api-docs/Models/searchUsers_200_response.md @@ -0,0 +1,10 @@ +# searchUsers_200_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**searchUsers_200_response_allOf_data**](searchUsers_200_response_allOf_data.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/searchUsers_200_response_allOf_data.md b/api-docs/Models/searchUsers_200_response_allOf_data.md new file mode 100644 index 00000000..ed33c1bb --- /dev/null +++ b/api-docs/Models/searchUsers_200_response_allOf_data.md @@ -0,0 +1,12 @@ +# searchUsers_200_response_allOf_data +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **items** | [**List**](UserSummary.md) | | [optional] [default to null] | +| **totalItems** | **Integer** | | [optional] [default to null] | +| **currentPage** | **Integer** | | [optional] [default to null] | +| **totalPages** | **Integer** | | [optional] [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/signUp_201_response.md b/api-docs/Models/signUp_201_response.md new file mode 100644 index 00000000..ce62fbe0 --- /dev/null +++ b/api-docs/Models/signUp_201_response.md @@ -0,0 +1,10 @@ +# signUp_201_response +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **status** | **Integer** | Internal status code of the response. An HTTP 200 response with an internal 500 status code is an error response. Prioritize the inner status over the HTTP status. | [default to null] | +| **data** | [**AuthToken**](AuthToken.md) | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/Models/verifyEmail_request.md b/api-docs/Models/verifyEmail_request.md new file mode 100644 index 00000000..cd3319a5 --- /dev/null +++ b/api-docs/Models/verifyEmail_request.md @@ -0,0 +1,9 @@ +# verifyEmail_request +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| **token** | **String** | | [default to null] | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/api-docs/README.md b/api-docs/README.md new file mode 100644 index 00000000..9f7d6913 --- /dev/null +++ b/api-docs/README.md @@ -0,0 +1,103 @@ +# Documentation for Programming Languages Forum + + +## Documentation for API Endpoints + +All URIs are relative to *http://localhost:5173/api/v1* + +| Class | Method | HTTP request | Description | +|------------ | ------------- | ------------- | -------------| +| *AnswersApi* | [**createAnswer**](Apis/AnswersApi.md#createanswer) | **POST** /questions/{questionId}/answers | Create a new answer | +*AnswersApi* | [**deleteAnswer**](Apis/AnswersApi.md#deleteanswer) | **DELETE** /answers/{answerId} | Delete an answer | +*AnswersApi* | [**downvoteAnswer**](Apis/AnswersApi.md#downvoteanswer) | **POST** /answers/{answerId}/downvote | Downvote an answer | +*AnswersApi* | [**getQuestionAnswers**](Apis/AnswersApi.md#getquestionanswers) | **GET** /questions/{questionId}/answers | Get answers for a question | +*AnswersApi* | [**updateAnswer**](Apis/AnswersApi.md#updateanswer) | **PUT** /answers/{answerId} | Update an answer | +*AnswersApi* | [**upvoteAnswer**](Apis/AnswersApi.md#upvoteanswer) | **POST** /answers/{answerId}/upvote | Upvote an answer | +| *AuthApi* | [**login**](Apis/AuthApi.md#login) | **POST** /auth/login | User login | +*AuthApi* | [**logout**](Apis/AuthApi.md#logout) | **POST** /auth/logout | User logout | +*AuthApi* | [**resetPassword**](Apis/AuthApi.md#resetpassword) | **POST** /auth/reset-password | Reset user's password | +*AuthApi* | [**signUp**](Apis/AuthApi.md#signup) | **POST** /auth/signup | Register a new user | +*AuthApi* | [**verifyEmail**](Apis/AuthApi.md#verifyemail) | **POST** /auth/verify-email | Verify user's email | +| *CodeExecutionApi* | [**executeCode**](Apis/CodeExecutionApi.md#executecode) | **POST** /execute-code | Execute a code snippet | +| *FeedApi* | [**getUserFeed**](Apis/FeedApi.md#getuserfeed) | **GET** /feed | Get user feed | +| *QuestionsApi* | [**bookmarkQuestion**](Apis/QuestionsApi.md#bookmarkquestion) | **POST** /questions/{questionId}/bookmark | Bookmark a question | +*QuestionsApi* | [**createQuestion**](Apis/QuestionsApi.md#createquestion) | **POST** /questions | Create a new question | +*QuestionsApi* | [**deleteQuestion**](Apis/QuestionsApi.md#deletequestion) | **DELETE** /questions/{questionId} | Delete a question | +*QuestionsApi* | [**downvoteQuestion**](Apis/QuestionsApi.md#downvotequestion) | **POST** /questions/{questionId}/downvote | Downvote a question | +*QuestionsApi* | [**getQuestionDetails**](Apis/QuestionsApi.md#getquestiondetails) | **GET** /questions/{questionId} | Get question details | +*QuestionsApi* | [**removeQuestionBookmark**](Apis/QuestionsApi.md#removequestionbookmark) | **DELETE** /questions/{questionId}/bookmark | Remove bookmark from a question | +*QuestionsApi* | [**updateQuestion**](Apis/QuestionsApi.md#updatequestion) | **PUT** /questions/{questionId} | Update a question | +*QuestionsApi* | [**upvoteQuestion**](Apis/QuestionsApi.md#upvotequestion) | **POST** /questions/{questionId}/upvote | Upvote a question | +| *SearchApi* | [**searchQuestions**](Apis/SearchApi.md#searchquestions) | **GET** /search/questions | Search questions | +*SearchApi* | [**searchTags**](Apis/SearchApi.md#searchtags) | **GET** /search/tags | Search tags | +*SearchApi* | [**searchUsers**](Apis/SearchApi.md#searchusers) | **GET** /search/users | Search users | +| *TagsApi* | [**createTag**](Apis/TagsApi.md#createtag) | **POST** /tags | Create a new tag | +*TagsApi* | [**followTag**](Apis/TagsApi.md#followtag) | **POST** /tags/{tagId}/follow | Follow a tag | +*TagsApi* | [**getTagDetails**](Apis/TagsApi.md#gettagdetails) | **GET** /tags/{tagId} | Get tag details | +*TagsApi* | [**unfollowTag**](Apis/TagsApi.md#unfollowtag) | **DELETE** /tags/{tagId}/follow | Unfollow a tag | +| *UserApi* | [**getMe**](Apis/UserApi.md#getme) | **GET** /users/me | Get own profile | +| *UsersApi* | [**followUser**](Apis/UsersApi.md#followuser) | **POST** /users/{userId}/follow | Follow a user | +*UsersApi* | [**getUserFollowers**](Apis/UsersApi.md#getuserfollowers) | **GET** /users/{userId}/followers | Get user's followers | +*UsersApi* | [**getUserFollowing**](Apis/UsersApi.md#getuserfollowing) | **GET** /users/{userId}/following | Get users being followed | +*UsersApi* | [**getUserProfile**](Apis/UsersApi.md#getuserprofile) | **GET** /users/{userId} | Get user profile | +*UsersApi* | [**unfollowUser**](Apis/UsersApi.md#unfollowuser) | **DELETE** /users/{userId}/unfollow | Unfollow a user | +*UsersApi* | [**updateUserProfile**](Apis/UsersApi.md#updateuserprofile) | **PUT** /users/{userId} | Update user profile | + + + +## Documentation for Models + + - [AnswerDetails](./Models/AnswerDetails.md) + - [AuthToken](./Models/AuthToken.md) + - [CodeExecution](./Models/CodeExecution.md) + - [DifficultyLevel](./Models/DifficultyLevel.md) + - [Error](./Models/Error.md) + - [ErrorResponseObject](./Models/ErrorResponseObject.md) + - [ExecutionResult](./Models/ExecutionResult.md) + - [ExperienceLevel](./Models/ExperienceLevel.md) + - [NewAnswer](./Models/NewAnswer.md) + - [NewQuestion](./Models/NewQuestion.md) + - [NewTag](./Models/NewTag.md) + - [Profile](./Models/Profile.md) + - [QuestionDetails](./Models/QuestionDetails.md) + - [QuestionSummary](./Models/QuestionSummary.md) + - [SuccessResponseObject](./Models/SuccessResponseObject.md) + - [SuccessResponseObject_data](./Models/SuccessResponseObject_data.md) + - [TagDetails](./Models/TagDetails.md) + - [TagSummary](./Models/TagSummary.md) + - [TagType](./Models/TagType.md) + - [UpdateAnswer](./Models/UpdateAnswer.md) + - [UpdateProfile](./Models/UpdateProfile.md) + - [UpdateQuestion](./Models/UpdateQuestion.md) + - [UserLogin](./Models/UserLogin.md) + - [UserProfile](./Models/UserProfile.md) + - [UserProfileUpdate](./Models/UserProfileUpdate.md) + - [UserRegistration](./Models/UserRegistration.md) + - [UserSummary](./Models/UserSummary.md) + - [createAnswer_201_response](./Models/createAnswer_201_response.md) + - [createQuestion_201_response](./Models/createQuestion_201_response.md) + - [createTag_201_response](./Models/createTag_201_response.md) + - [executeCode_200_response](./Models/executeCode_200_response.md) + - [getQuestionAnswers_200_response](./Models/getQuestionAnswers_200_response.md) + - [getQuestionAnswers_200_response_allOf_data](./Models/getQuestionAnswers_200_response_allOf_data.md) + - [getUserFollowers_200_response](./Models/getUserFollowers_200_response.md) + - [getUserProfile_200_response](./Models/getUserProfile_200_response.md) + - [resetPassword_request](./Models/resetPassword_request.md) + - [searchQuestions_200_response](./Models/searchQuestions_200_response.md) + - [searchQuestions_200_response_allOf_data](./Models/searchQuestions_200_response_allOf_data.md) + - [searchTags_200_response](./Models/searchTags_200_response.md) + - [searchTags_200_response_allOf_data](./Models/searchTags_200_response_allOf_data.md) + - [searchUsers_200_response](./Models/searchUsers_200_response.md) + - [searchUsers_200_response_allOf_data](./Models/searchUsers_200_response_allOf_data.md) + - [signUp_201_response](./Models/signUp_201_response.md) + - [verifyEmail_request](./Models/verifyEmail_request.md) + + + +## Documentation for Authorization + + +### bearerAuth + +- **Type**: HTTP Bearer Token authentication (JWT) + diff --git a/reports/m2_group1.md b/reports/m2_group1.md new file mode 100644 index 00000000..e69de29b