{"id":20503259,"url":"https://github.com/potlitel/superhero-drf","last_synced_at":"2026-04-13T02:03:26.400Z","repository":{"id":57149906,"uuid":"526737444","full_name":"potlitel/Superhero-DRF","owner":"potlitel","description":"Django REST API Practical Exercise!","archived":false,"fork":false,"pushed_at":"2022-08-23T21:28:21.000Z","size":59,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-16T07:31:14.581Z","etag":null,"topics":["django","django-application","django-framework","django-rest-framework","docker","dockerfile"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/potlitel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-08-19T20:04:03.000Z","updated_at":"2023-08-16T14:53:13.000Z","dependencies_parsed_at":"2022-08-26T09:50:12.942Z","dependency_job_id":null,"html_url":"https://github.com/potlitel/Superhero-DRF","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/potlitel%2FSuperhero-DRF","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/potlitel%2FSuperhero-DRF/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/potlitel%2FSuperhero-DRF/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/potlitel%2FSuperhero-DRF/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/potlitel","download_url":"https://codeload.github.com/potlitel/Superhero-DRF/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242100060,"owners_count":20071654,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["django","django-application","django-framework","django-rest-framework","docker","dockerfile"],"created_at":"2024-11-15T19:29:52.482Z","updated_at":"2026-04-13T02:03:21.353Z","avatar_url":"https://github.com/potlitel.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv id=\"top\"\u003e\u003c/div\u003e\n\u003c!--\n*** Thanks for checking out the Best-README-Template. If you have a suggestion\n*** that would make this better, please fork the repo and create a pull request\n*** or simply open an issue with the tag \"enhancement\".\n*** Don't forget to give the project a star!\n*** Thanks again! Now go create something AMAZING! :D\n--\u003e\n\n\u003c!-- PROJECT SHIELDS --\u003e\n\n\u003c!--\n*** I'm using markdown \"reference style\" links for readability.\n*** Reference links are enclosed in brackets [ ] instead of parentheses ( ).\n*** See the bottom of this document for the declaration of the reference variables\n*** for contributors-url, forks-url, etc. This is an optional, concise syntax you may use.\n*** https://www.markdownguide.org/basic-syntax/#reference-style-links\n--\u003e\n\n\n\u003c!-- PROJECT LOGO --\u003e\n\n\u003cbr /\u003e\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"https://github.com/potlitel/Superhero-DRF\"\u003e\n    \u003cimg src=\"images/django_rest_framework.png\" alt=\"Logo\" width=\"280\" height=\"130\"\u003e\n  \u003c/a\u003e\n\n\u003ch3 align=\"center\"\u003eSuperheros API - Django Rest Framework\u003c/h3\u003e\n\n\u003cp align=\"center\"\u003e\n    project_description\n    \u003cbr /\u003e\n    \u003ca href=\"https://github.com/potlitel/Superhero-DRF\"\u003e\u003cstrong\u003eExplore the docs »\u003c/strong\u003e\u003c/a\u003e\n    \u003cbr /\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"https://github.com/potlitel/Superhero-DRF\"\u003eView Demo\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/potlitel/Superhero-DRF\"\u003eReport Bug\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/potlitel/Superhero-DRF/issues\"\u003eRequest Feature\u003c/a\u003e\n  \u003c/p\u003e\n\u003c/div\u003e\n\n\u003c!-- TABLE OF CONTENTS --\u003e\n\n\u003cdetails\u003e\n  \u003csummary\u003eTable of Contents\u003c/summary\u003e\n  \u003col\u003e\n    \u003cli\u003e\n      \u003ca href=\"#about-the-project\"\u003eAbout The Project\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#built-with\"\u003eBuilt With\u003c/a\u003e\u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\n      \u003ca href=\"#getting-started\"\u003eGetting Started\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#prerequisites\"\u003ePrerequisites\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#installation\"\u003eInstallation\u003c/a\u003e\u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#usage\"\u003eUsage\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#roadmap\"\u003eRoadmap\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#contributing\"\u003eContributing\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#license\"\u003eLicense\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#contact\"\u003eContact\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#acknowledgments\"\u003eAcknowledgments\u003c/a\u003e\u003c/li\u003e\n  \u003c/ol\u003e\n\u003c/details\u003e\n\n\u003c!-- ABOUT THE PROJECT --\u003e\n\n## About The Project\n\n\u003cimg src=\"images/Resume.gif\" alt=\"Logo\" width=\"840\" height=\"480\"\u003e\n\nHere's a blank template to get started: To avoid retyping too much info. Do a search and replace with your text editor for the following: `github_username`, `repo_name`, `twitter_handle`, `linkedin_username`, `email_client`, `email`, `project_title`, `project_description`\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n### Built With\n\n* [Django](https://www.djangoproject.com/)\n* [Django Rest Framework](https://www.django-rest-framework.org/)\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- GETTING STARTED --\u003e\n\n## Getting Started\n\nThis repo is a rich clone of [Creating a REST Web API in C# with ASP.NET Core 5.0 and Visual Studio Code](https://luis-hernandez.medium.com/creating-a-rest-web-api-in-c-with-asp-net-core-5-0-and-visual-studio-code-809ea7b4f815). Is an step-by-step guide to show you how to create a REST Web API in C# with ASP.NET Core 5.0 and Visual Studio Code. And how test it using either Swagger or a REST Client extension..\n\n### Prerequisites\n\n1. First you need to check if you have installed the .NET Core 6.0 SDK with the following .NET CLI (Command-Line Interface) command:\n\n      ```sh\n      dotnet --version\n      ```\n    If your version is not 5 or above, [download the .NET Core 6.0 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/6.0) and install it on your machine.\n\n2. Install Visual Studio Code editor (also know as VSCode).\n\n3. Once Visual Studio Code is open, install the REST Client extension.\n\n4. Finally, install the C# extension to get IntelliSense features in VSCode.\n\n### Installation\n\n1. Clone the repo\n   ```sh\n   git clone https://github.com/potlitel/Superhero-DRF.git\n   ```\n2. Running the project\n   ```js\n   dotnet watch run\n   ```\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n### 🐳 Installation using Docker\n#### Why Docker\n\nDocker helps developers build and ship higher-quality applications, faster.\" -- [What is Docker](https://www.docker.com/what-docker#copy1)\n\n#### Prerequisites\n\n#### Linux\n\nThe 3.10.x kernel is [the minimum requirement](https://docs.docker.com/engine/installation/binaries/#check-kernel-dependencies) for Docker.\n\n#### MacOS\n\n10.8 “Mountain Lion” or newer is required.\n\n#### Windows 10\n\nHyper-V must be enabled in BIOS\n\nVT-D must also be enabled if available (Intel Processors).\n\n#### Windows Server\n\nWindows Server 2016 is the minimum version required to install docker and docker-compose. Limitations exist on this version, such as multiple virtual networks and Linux containers. Windows Server 2019 and later are recommended. \n\n#### Installation\n#### Linux\n\nRun this quick and easy install script provided by Docker:\n\n```sh\ncurl -sSL https://get.docker.com/ | sh\n```\n\nIf you're not willing to run a random shell script, please see the [installation](https://docs.docker.com/engine/installation/linux/) instructions for your distribution.\n\nIf you are a complete Docker newbie, you should follow the [series of tutorials](https://docs.docker.com/engine/getstarted/) now.\n\n#### macOS\n\nDownload and install [Docker Community Edition](https://www.docker.com/community-edition). if you have Homebrew-Cask, just type `brew install --cask docker`. Or Download and install [Docker Toolbox](https://docs.docker.com/toolbox/overview/).  [Docker For Mac](https://docs.docker.com/docker-for-mac/) is nice, but it's not quite as finished as the VirtualBox install.  [See the comparison](https://docs.docker.com/docker-for-mac/docker-toolbox/).\n\n\u003e **NOTE** Docker Toolbox is legacy. You should to use Docker Community Edition, See [Docker Toolbox](https://docs.docker.com/toolbox/overview/).\nOnce you've installed Docker Community Edition, click the docker icon in Launchpad. Then start up a container:\n\n```sh\ndocker run hello-world\n```\n\nThat's it, you have a running Docker container.\n\nIf you are a complete Docker newbie, you should probably follow the [series of tutorials](https://docs.docker.com/engine/getstarted/) now.\n\n#### Windows 10\n\nInstructions to install Docker Desktop for Windows can be found [here](https://docs.docker.com/desktop/windows/install/)\n\nOnce installed, open powershell as administrator and run:\n\n```powershell\n# Display the version of docker installed:\ndocker version\n# Pull, create, and run 'hello-world':\ndocker run hello-world\n```\n\nTo continue with this cheat sheet, right click the Docker icon in the system tray, and go to settings. In order to mount volumes, the C:/ drive will need to be enabled in the settings to that information can be passed into the containers (later described in this article). \n\nTo switch between Windows containers and Linux containers, right click the icon in the system tray and click the button to switch container operating system Doing this will stop the current containers that are running, and make them unaccessible until the container OS is switched back.\n\nAdditionally, if you have WSL or WSL2 installed on your desktop, you might want to install the Linux Kernel for Windows. Instructions can be found [here](https://techcommunity.microsoft.com/t5/windows-dev-appconsult/using-wsl2-in-a-docker-linux-container-on-windows-to-run-a/ba-p/1482133). This requires the Windows Subsystem for Linux feature. This will allow for containers to be accessed by WSL operating systems, as well as the efficiency gain from running WSL operating systems in docker. It is also preferred to use [Windows terminal](https://docs.microsoft.com/en-us/windows/terminal/get-started) for this.\n\n#### Windows Server 2016 / 2019\n\nFollow Microsoft's instructions that can be found [here](https://docs.microsoft.com/en-us/virtualization/windowscontainers/deploy-containers/deploy-containers-on-server#install-docker)\n\nIf using the latest edge version of 2019, be prepared to only work in powershell, as it is only a servercore image (no desktop interface). When starting this machine, it will login and go straight to a powershell window. It is reccomended to install text editors and other tools using [Chocolatey](https://chocolatey.org/install).\n\nAfter installing, these commands will work:\n\n```powershell\n# Display the version of docker installed:\ndocker version\n# Pull, create, and run 'hello-world':\ndocker run hello-world\n```\n\nWindows Server 2016 is not able to run Linux images. \n\nWindows Server Build 2004 is capable of running both linux and windows containers simultaneously through Hyper-V isolation. When running containers, use the ```--isolation=hyperv``` command, which will isolate the container using a seperate kernel instance. \n\n#### 👷‍♀ Let's build the image using Dockerfile\n\nWe can now build this image in a simple way running the followind command\n\n```powershell\ndocker build -t djangosuperheros:1.1 .\n```\n\nNote that djangosuperheros is the name of the image, and using :1.1 can be anything like an example docker build -t djangosuperheros:1.1 .\n\nThis will create an image called djangosuperheros and be version 1.1\n\nNow go get some ☕️ and 💺 while 🐳 does its magic 🐳 = ❤️\n\nOnce this is completed as it can take a bit of time (Normally a few minutes ☕️) then we can run our project using the following command.\n\n```powershell\ndocker run -d -p 8000:8000 djangosuperheros:1.1\n```\nThis tells Docker to run the image djangosuperheros:1.1 or whatever you called your project 🤔 on port 8000, -d means detached and is a fancy word of saying \"Runs in the background\"\n\nCool tip if you want to use this image on a different port while developing you can change first part of the run port to something else like so\n\n```powershell\ndocker run -d -p 9900:8000 djangosuperheros:1.1\n```\nAnd it will now run on port 9900 👍 😏\n\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- USAGE EXAMPLES --\u003e\n\n## Usage\n\nUse this space to show useful examples of how a project can be used. Additional screenshots, code examples and demos work well in this space. You may also link to more resources.\n\n_For more examples, please refer to the [Documentation](https://example.com)_\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- ROADMAP --\u003e\n\n## Roadmap\n\n- [ ] Feature 1\n- [ ] Feature 2\n- [ ] Feature 3\n  - [ ] Nested Feature\n\nSee the [open issues](https://github.com/github_username/repo_name/issues) for a full list of proposed features (and known issues).\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- CONTRIBUTING --\u003e\n\n## Contributing\n\nContributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.\n\nIf you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag \"enhancement\".\nDon't forget to give the project a star! Thanks again!\n\n1. Fork the Project\n2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the Branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- LICENSE --\u003e\n\n## License\n\nDistributed under the MIT License. See `LICENSE.txt` for more information.\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- CONTACT --\u003e\n\n## Contact\n\nYour Name - [@twitter_handle](https://twitter.com/potlitel) - potlitel@gmail.com\n\nProject Link: [https://github.com/potlitel/Superhero-DRF](https://github.com/potlitel/Superhero-DRF)\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- ACKNOWLEDGMENTS --\u003e\n\n## Acknowledgments\n\nList of resources I find helpful and would like to give credit to. I've included a few of my favorites to kick things off!\n\n* [Import \"rest_framework\" could not be resolved. But I have installed djangorestframework, I don't know what is going wrong](https://stackoverflow.com/questions/65369567/import-rest-framework-could-not-be-resolved-but-i-have-installed-djangorestfr)\n* [Lucifer Morningstar](https://www.superherodb.com/lucifer-morningstar/10-10807/#user)\n* [Python Virtual Environments](https://uoa-eresearch.github.io/eresearch-cookbook/recipe/2014/11/26/python-virtual-env/)\n* [How To Set Up a Virtual Python Environment (Windows)](https://mothergeo-py.readthedocs.io/en/latest/development/how-to/venv-win.html)\n* [Model instance reference](https://docs.djangoproject.com/en/4.1/ref/models/instances/)\n* [Model field reference](https://docs.djangoproject.com/en/4.1/ref/models/fields/)\n* [Models](https://docs.djangoproject.com/en/4.1/topics/db/models/)\n* [Django model data types and fields list](https://www.geeksforgeeks.org/django-model-data-types-and-fields-list/)\n* [Lucifer Morningstar](https://lucifer.fandom.com/wiki/Lucifer_Morningstar)\n* [Filtering](https://www.django-rest-framework.org/api-guide/filtering/)\n* [Serializer relations](https://www.django-rest-framework.org/api-guide/relations/)\n* [How to filter your query with params in Django Rest - Part I](https://dev.to/serhatteker/how-to-filter-your-query-with-params-in-django-rest-part-i-45n)\n* [How to filter your query with params in Django REST - Part I](https://tech.serhatteker.com/post/2021-11/django-rest-query-part-1/)\n* [How to filter your query with params in Django REST - Part II](https://tech.serhatteker.com/post/2021-11/django-rest-query-part-2/)\n* [Best method to store list of foreign keys in a model?](https://stackoverflow.com/questions/16554335/best-method-to-store-list-of-foreign-keys-in-a-model)\n* [Model field reference](https://docs.djangoproject.com/en/dev/ref/models/fields/#manytomanyfield)\n* [How to create a list of foreign keys in a Django model?](https://www.reddit.com/r/django/comments/f3tbxd/how_to_create_a_list_of_foreign_keys_in_a_django/)\n* [DJANGO MODEL FIELD : ORDERED LIST OF FOREIGN KEYS-DJANGO](https://www.appsloveworld.com/django/100/23/django-model-field-ordered-list-of-foreign-keys)\n\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n\n\u003c!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --\u003e\n\n[contributors-shield]: https://img.shields.io/github/contributors/github_username/repo_name.svg?style=for-the-badge\n[contributors-url]: https://github.com/github_username/repo_name/graphs/contributors\n[forks-shield]: https://img.shields.io/github/forks/github_username/repo_name.svg?style=for-the-badge\n[forks-url]: https://github.com/github_username/repo_name/network/members\n[stars-shield]: https://img.shields.io/github/stars/github_username/repo_name.svg?style=for-the-badge\n[stars-url]: https://github.com/github_username/repo_name/stargazers\n[issues-shield]: https://img.shields.io/github/issues/github_username/repo_name.svg?style=for-the-badge\n[issues-url]: https://github.com/github_username/repo_name/issues\n[license-shield]: https://img.shields.io/github/license/github_username/repo_name.svg?style=for-the-badge\n[license-url]: https://github.com/github_username/repo_name/blob/master/LICENSE.txt\n[linkedin-shield]: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge\u0026logo=linkedin\u0026colorB=555\n[linkedin-url]: https://linkedin.com/in/linkedin_username\n[product-screenshot]: images/screenshot.png\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpotlitel%2Fsuperhero-drf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpotlitel%2Fsuperhero-drf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpotlitel%2Fsuperhero-drf/lists"}