GitXplorerGitXplorer
z

photo-order-service

public
0 stars
0 forks
0 issues

Commits

List of commits on branch main.
Verified
25c9d24417e2a1fa7613a0802ab577e4834c86ec

Update Get Random Photos.postman_collection.json

zzaherkassem committed 6 months ago
Unverified
d28f5d2adcb293dce1945b4d31ddb25898910cb7

add readme

zzaherkassem committed 6 months ago
Unverified
a52d478567e003384e3db2f5d04f75e153ce4a1e

add postman endpoints

zzaherkassem committed 6 months ago
Unverified
8c8f941038136ccb94f631c0afe559ac92c1c725

init

zzaherkassem committed 6 months ago
Verified
1934575341da71b7e8d18dd1b58e04bd66b10029

Initial commit

zzaherkassem committed 6 months ago

README

The README file for this repository.

Photo Order Service

Description

A Node.js service with TypeScript that allows users to:

  1. Get a list of random photo URLs from Unsplash.
  2. Create an order with details including photo URLs and user information.
  3. Retrieve all orders of a specific user.

Technologies

  • Node.js
  • TypeScript
  • Express
  • MongoDB
  • Mongoose
  • Axios

Setup

  1. Clone the repository:
    git clone https://github.com/zaherkassem/photo-order-service.git
    cd photo-order-service
    
    
    

For Test

Please use Get Random Photos.postman_collection.json

API EndPoints:

Get Random Photos URL: /api/photos/:count Method: GET Description: Retrieves a list of random photo URLs. Params: count (number): The number of random photo URLs to retrieve. Create Order URL: /api/orders Method: POST Description: Creates a new order with the provided details. Body: json Copy code { "email": "user@example.com", "fullName": "John Doe", "fullAddress": "123 Main St, City, Country", "imageUrls": ["url1", "url2"], "frameColor": "black", "user": "userId" } Get User Orders URL: /api/orders/:userId Method: GET Description: Retrieves all orders of a specific user. Params: userId (string): The ID of the user whose orders to retrieve.