Skip to content

A sample API project built in ASP.NET 7 using MongoDB Database.

Notifications You must be signed in to change notification settings

keithmanilla/NewDotNet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

NewDotNet

A sample API project built in ASP.NET 7 using MongoDB Database.

Running the Project:

dotnet run

Swagger: http://localhost:5269/swagger/index.html

API Routes

Get List of Books

Fetch the list of books with pagination params.

GET {{host}}/api/v1/books?page=1&perPage=10

Get a Book by ID

Fetch a book by it's ID.

GET {{host}}/api/v1/books/{{id}}

Create a Book

Create a new record of the book.

POST {{host}}/api/v1/books

Request Body:
{
    "Name": "Book Name",
    "Price": 9.99,
    "Category": "Category Name",
    "Author": "Author Name"
}

Update a Book

POST {{host}}/api/v1/books/{{id}}

Request Body:
{
    "Name": "Book Name",
    "Price": 9.99,
    "Category": "Category Name",
    "Author": "Author Name"
}

Delete a Book

DELETE {{host}}/api/v1/books/{{id}}

About

A sample API project built in ASP.NET 7 using MongoDB Database.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages