Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/guidesmiths/dotnetcore-api

A .NET Core API example
https://github.com/guidesmiths/dotnetcore-api

Last synced: about 1 month ago
JSON representation

A .NET Core API example

Awesome Lists containing this project

README

        

# .Net Core API

This is a sample project of how to use .Net Core for a Web API.
It uses MongoDB as a data storage service, it also uses `Swashbuckle` to autogenerate the API docs in Swagger format.

## How to run it
1. Execute `docker-compose up` on the `Docker` directory
2. Execute `dotnet build`
3. Execute `dotnet run`

## Usage
- Retrieve some books `curl --insecure https://localhost:5001/api/books`
- Get API docs `https://localhost:5001/swagger/index.html`

## How to run it (Docker)
1. Execute `docker build -t SampleAPI .`
2. Execute `docker run -p 8080:80 SampleAPI`