Group7
  1. phones
Group7
  • phones
    • Get a list of all phones
      GET
    • Get phone by id
      GET
    • Get the 5 phones that will sell out soon
      GET
    • Get the hot 5 mobile phones
      GET
    • Search for mobile phones by title keyword
      GET
    • Shopping Cart Checkout
      POST
    • Post mobile reviews (as a buyer)
      POST
    • Hide/Show Comments (as a buyer)
      PUT
    • Get details and quantities of phones purchased (as a buyer)
      POST
    • Get details of reviewed phones (as a buyer)
      POST
    • Get reviewed phones and corresponding reviews (as a buyer)
      POST
    • View phones for sale and reviews (as a seller)
      POST
    • Enable/disable mobile phones (as a seller)
      PUT
    • Change mobile phone information
      PUT
    • createPhone
      POST
    • Delete phone
      DELETE
    • Sellers view phones for sale
      POST
    • Get phone by id for list
      GET
  • users & auth
    • Registration
      POST
    • Verify email address
      GET
    • Login
      POST
    • Forgot your password (enter your email address)
      POST
    • Reset password
      PUT
    • Obtaining user information
      GET
    • Modify user information
      PUT
    • Reset password
      PUT
  1. phones

Get phone by id

GET
localhost:5001/api/phones/645a0a8ca81a402de8668984

Request

None

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'localhost:5001/api/phones/645a0a8ca81a402de8668984'

Responses

🟢200OK
application/json
Body
_id
string 
required
title
string 
required
brand
string 
required
image
string 
required
stock
integer 
required
seller
string 
required
price
number 
required
reviews
array [object {7}] 
required
_id
string 
required
reviewer
string 
required
rating
integer 
required
comment
string 
required
createdAt
string 
required
updatedAt
string 
required
hidden
string 
optional
Example
{
  "_id": "645a0a8ca81a402de8668984",
  "title": "\"CLEAR CLEAN ESN\" Sprint EPIC 4G Galaxy SPH-D700*FRONT CAMERA*ANDROID*SLIDER*QWERTY KEYBOARD*TOUCH SCREEN",
  "brand": "Samsung",
  "image": "/Samsung.jpeg",
  "stock": 4,
  "price": 199.99,
  "seller": "Gail Patterson",
  "reviews": [
    {
      "_id": "6462814e29bdbd4521a86268",
      "reviewer": "5f5237a4c1beb1523fa3dabf",
      "rating": 5,
      "comment": "I feel so LUCKY to have found this used (phone to us & not used hard at all), phone on line from someone who upgraded and sold this one. My Son liked his old one that finally fell apart after 2.5+ years and didn't want an upgrade!! Thank you Seller, we really appreciate it & your honesty re: said used phone.I recommend this seller very highly & would but from them again!!",
      "createdAt": "2023-05-14T16:28:03.100Z",
      "updatedAt": "2023-05-14T16:28:03.100Z"
    },
    {
      "_id": "6462814e29bdbd4521a86269",
      "reviewer": "5f5237a4c1beb1523fa3dab6",
      "rating": 4,
      "comment": "nice phone, nice up grade from my pantach revue. Very clean set up and easy set up. never had an android phone but they are fantastic to say the least. perfect size for surfing and social media. great phone samsung",
      "createdAt": "2023-05-14T16:28:03.100Z",
      "updatedAt": "2023-05-14T16:28:03.100Z"
    },
    {
      "_id": "6462814e29bdbd4521a8626a",
      "reviewer": "5f5237a4c1beb1523fa3da1f",
      "rating": 5,
      "comment": "Very pleased",
      "createdAt": "2023-05-14T16:28:03.101Z",
      "updatedAt": "2023-05-14T16:28:03.101Z"
    },
    {
      "reviewer": "645d3feb6b2d2ae49ccb50bf",
      "rating": 3,
      "comment": "第1次测试!!!",
      "_id": "64621b34ab5310e6dcffd515",
      "createdAt": "2023-05-15T11:44:52.430Z",
      "updatedAt": "2023-05-15T12:19:50.434Z",
      "hidden": "true"
    }
  ]
}
🔴500Server Error
🟠404Record Not Found
Previous
Get a list of all phones
Next
Get the 5 phones that will sell out soon
Built with