Skip to content

SalZaki/AlphaTravel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AlphaTravel

Alpha travel and tourism project showcases CQRS and clean architecture of RESTful Web Api.

Version

V1.0

Swagger UI

GET all customers
Request Url

https://localhost:44351/api/v1/customers

Response Body
{
  "href": "https://localhost:44351/api/v1/customers",
  "method": "GET",
  "rel": [
    "collection"
  ],
  "offset": 0,
  "limit": 25,
  "total": 5,
  "first": {
    "href": "https://localhost:44351/api/v1/customers",
    "method": "GET",
    "rel": [
      "collection"
    ]
  },
  "data": [
    {
      "href": null,
      "method": "GET",
      "id": 1,
      "firstname": "John",
      "surname": "Richard",
      "password": "password123",
      "email": "[email protected]",
      "created_on": "2019-03-18T12:49:44Z",
      "created_by": "SeedDataService",
      "modified_on": "0001-01-01T00:00:00Z"
    },.......

GET all customers with pagging, offset and limit
Request Url

https://localhost:44351/api/v1/customers?Offset=0&Limit=50

Response Body
{
  "href": "https://localhost:44351/api/v1/customers",
  "method": "GET",
  "rel": [
    "collection"
  ],
  "offset": 0,
  "limit": 50,
  "total": 5,
  "first": {
    "href": "https://localhost:44351/api/v1/customers",
    "method": "GET",
    "rel": [
      "collection"
    ]
  },
  "data": [
    {
      "href": null,
      "method": "GET",
      "id": 1,
      "firstname": "John",
      "surname": "Richard",
      "password": "password123",
      "email": "[email protected]",
      "created_on": "2019-03-18T12:49:44Z",
      "created_by": "SeedDataService",
      "modified_on": "0001-01-01T00:00:00Z"
    },......

GET a single customer
Request Url

https://localhost:44351/api/v1/customers/22

Request Body
{
      "id": "22"
      "firstname": "John",
      "surname": "Richard",
      "password": "password123",
      "email": "[email protected]",
      "created_on": "2019-03-18T12:49:44Z",
      "created_by": "WebApi"
}

POST a customer
Request Url

https://localhost:44351/api/v1/customers

Request Body
{
      "id": "22"
      "firstname": "John",
      "surname": "Richard",
      "password": "password123",
      "email": "[email protected]",
      "modified_on": "2019-03-18T12:49:44Z",
      "modified_by": "WebApi"
}

DELETE a customer
Request Url

https://localhost:44351/api/v1/customers/1

PUT a customer
Request Url

https://localhost:44351/api/v1/customers/1

Request Body
{
      "firstname": "John",
      "surname": "Richard",
      "password": "password123",
      "email": "[email protected]",
      "modified_on": "2019-03-18T12:49:44Z",
      "modified_by": "WebApi"
}

About

Alpha travel and tourism

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages