Skip to content

This article will teach you how to build a simple CRUD API with Rust using the Rocket framework. We'll create a RESTful API that runs on a Rocket HTTP server and persists data in an in-memory database.

Notifications You must be signed in to change notification settings

wpcodevo/simple-api-rocket

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build a Simple API with Rust and Rocket

This article will teach you how to build a simple CRUD API with Rust using the Rocket framework. We'll create a RESTful API that runs on a Rocket HTTP server and persists data in an in-memory database.

Build a Simple API with Rust and Rocket

Topics Covered

  • Run the Rocket API Project Locally
  • Setup the Rust Project with Cargo
  • Setup the In-memory Database
  • Define the API Response Structs
  • Implement the CRUD API
    • Create the Health Checker Handler
    • Get a List of Records Handler
    • Add New Record Handler
    • Get a Single Record Handler
    • Edit Record Handler
    • Delete a Record Handler
  • Create Route Paths with Rocket
  • Test the Rust Rocket API
    • Perform CREATE Operation
    • Perform UPDATE Operation
    • Perform GET Operation
    • Perform DELETE Operation

Read the entire article here: https://codevoweb.com/build-a-simple-api-with-rust-and-rocket/

About

This article will teach you how to build a simple CRUD API with Rust using the Rocket framework. We'll create a RESTful API that runs on a Rocket HTTP server and persists data in an in-memory database.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published