Giter Site home page Giter Site logo

phonebookapi's Introduction

Phonebook API

This is a phonebook API that allows users to manage contact details of individuals, including their full name, mobile number, work number, email, home address, and group ID. Users can perform CRUD operations (Create, Read, Update, Delete) on the contacts and assign them to specific groups.
DancingByTheFireKiGIF

Installation

  1. Clone the repository: git clone <repository-url>
  2. Navigate to the project directory: cd phonebook-api
  3. Install dependencies: npm install


## Database Setup

This project uses SQL Server as the database. Before running the application, make sure you have SQL Server installed and create a new database for the phonebook API.

  1. Open SQL Server Management Studio (SSMS) and connect to your SQL Server instance.
  2. Create a new database: CREATE DATABASE PhonebookDB;

Configuration

  1. Rename the .env.example file to .env.
  2. Open the .env file and update the database connection details with your SQL Server configuration.

Usage

When running in localhost

  1. Start the server: npm start
  2. Access the API at: http://localhost:8081

API Endpoints

  • GET /contacts: Get all contacts
  • GET /contacts/:id: Get contact details by ID
  • POST /contacts: Create a new contact
  • PUT /contacts/:id: Update contact details
  • DELETE /contacts/:id: Delete a contact
  • POST /contacts/:id/groups: Assign a contact to a group
  • GET /groups/:id/contacts: Get contacts belonging to a specific group

Technologies Used

  • Node.js
  • Express.js
  • SQL Server

Authors

GroupChatCnmrlmGIF

  • Lewis Muthaura
  • Evans Ngugi
  • Calvin Shawn
  • Ian Muriuki
  • Judith Muthui

License

Its free licence

Contributing

Contributions are welcome! Feel free to open an issue or submit a pull request. WhiskeyEiSuoiAmiciCoccoleSonoreGIF

phonebookapi's People

Contributors

evanoken avatar judiciousmurich avatar munenecalvin avatar lewistechke avatar

Stargazers

 avatar John Chege avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.