Skip to content

Latest commit

 

History

History
1925 lines (1623 loc) · 49.6 KB

ROUTES.md

File metadata and controls

1925 lines (1623 loc) · 49.6 KB
title language_tabs language_clients toc_footers includes search highlight_theme headingLevel
Mercure API v1
false
darkula
2

Mercure API v1

Scroll down for example requests and responses.

Authentication

  • API Key (Bearer)
    • Parameter Name: Authorization, in: header. JWT Authorization header using the Bearer scheme.

Enter 'Bearer' [space] and then your token in the text input below.

Example: "Bearer 1safsfsdfdfd"

Authentification

Permet de se connecter à l'applicaation

Code samples

GET /auth/login/google

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Reçois la requête de microsoft pour la connexion

Code samples

GET /auth/callback/microsoft

Parameters

Name In Type Required Description
code query string false Le code de microsoft concernant la connexion
state query string false Le code qu'on à générer qui permet de protéger contre les Man In The Middle
error query string false Le code erreur s'il y en a une
errorDescription query string false La description de l'erreur

Responses

Status Meaning Description Schema
200 OK Returns the token information None
400 Bad Request Microsoft can't find your account, please contact the owner of the application None
401 Unauthorized You are not authorize None
404 Not Found Can't found your account None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Reçois la requête de google pour la connexion

Code samples

GET /auth/callback/google

Parameters

Name In Type Required Description
code query string false Le code de microsoft concernant la connexion
state query string false Le code qu'on à générer qui permet de protéger contre les Man In The Middle
error query string false Le code erreur s'il y en a une

Responses

Status Meaning Description Schema
200 OK Returns the token information None
400 Bad Request Google can't find your account, please contact the owner of the application None
401 Unauthorized You are not authorize None
404 Not Found Can't found your account None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Return the token for the user saved in the cache with the state

Code samples

GET /auth/logged

Parameters

Name In Type Required Description
state query string false the state code generated when the user logged

Example responses

200 Response

{
  "userId": 0,
  "lastName": "string",
  "firstName": "string",
  "email": "string"
}

Responses

Status Meaning Description Schema
200 OK Success UserDto
404 Not Found Not Found ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Return the current user connected

Code samples

GET /auth/current-user

Example responses

200 Response

{
  "userId": 0,
  "lastName": "string",
  "firstName": "string",
  "email": "string"
}

Responses

Status Meaning Description Schema
200 OK Success UserDto
404 Not Found Not Found ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Cart

Get the cart of the user

Code samples

GET /cart

Parameters

Name In Type Required Description
randomId query string false none

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Add a product to the cart

Code samples

POST /add/{productId}

Parameters

Name In Type Required Description
productId path string true none
randomId query string false none
quantity query string false none

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Remove a product from the cart

Code samples

DELETE /remove/{productId}

Parameters

Name In Type Required Description
productId path string true none
randomId query string false none

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Product

Get the product for the given idq

Code samples

GET /products/{productId}

Parameters

Name In Type Required Description
productId path string true none

Example responses

200 Response

{
  "productId": 0,
  "productBrandName": "string",
  "productName": "string",
  "productDescription": "string",
  "productPrice": 0,
  "productCreationDate": "2019-08-24T14:15:22Z",
  "productLastUpdate": "2019-08-24T14:15:22Z",
  "stock": {
    "quantity": 0
  },
  "categories": [
    {
      "categoryTitle": "string",
      "categoryDescription": "string",
      "products": [
        {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stock": {
            "quantity": 0
          },
          "categories": []
        }
      ]
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK Success ProductDto
400 Bad Request Bad Request ErrorMessage
401 Unauthorized Unauthorized ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Creates a new product.

Code samples

POST /products/create

Body parameter

productName: string
productBrandName: string
productDescription: string
productPrice: 0
stockId: 0
categories: string

Parameters

Name In Type Required Description
body body object false none
» productName body string false none
» productBrandName body string false none
» productDescription body string false none
» productPrice body integer(int32) false none
» stockId body integer(int32) false none
» categories body string false none

Example responses

200 Response

{
  "productId": 0,
  "productBrandName": "string",
  "productName": "string",
  "productDescription": "string",
  "productPrice": 0,
  "productCreationDate": "2019-08-24T14:15:22Z",
  "productLastUpdate": "2019-08-24T14:15:22Z",
  "stock": {
    "quantity": 0
  },
  "categories": [
    {
      "categoryTitle": "string",
      "categoryDescription": "string",
      "products": [
        {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stock": {
            "quantity": 0
          },
          "categories": []
        }
      ]
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK Success ProductDto
400 Bad Request Bad Request ErrorMessage
401 Unauthorized Unauthorized ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Updates an existing product.

Code samples

PUT /products/update/{productId}

Body parameter

productName: string
productBrandName: string
productDescription: string
productPrice: 0
stockId: 0
categories: string

Parameters

Name In Type Required Description
productId path string true The identifier of the product to update.
body body object false none
» productName body string false none
» productBrandName body string false none
» productDescription body string false none
» productPrice body integer(int32) false none
» stockId body integer(int32) false none
» categories body string false none

Example responses

200 Response

{
  "productId": 0,
  "productBrandName": "string",
  "productName": "string",
  "productDescription": "string",
  "productPrice": 0,
  "productCreationDate": "2019-08-24T14:15:22Z",
  "productLastUpdate": "2019-08-24T14:15:22Z",
  "stock": {
    "quantity": 0
  },
  "categories": [
    {
      "categoryTitle": "string",
      "categoryDescription": "string",
      "products": [
        {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stock": {
            "quantity": 0
          },
          "categories": []
        }
      ]
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK Success ProductDto
400 Bad Request Bad Request ErrorMessage
401 Unauthorized Unauthorized ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

delete__products_delete_{productId}

Code samples

DELETE /products/delete/{productId}

Parameters

Name In Type Required Description
productId path string true none

Example responses

200 Response

{
  "message": "string",
  "statuCode": 0
}

Responses

Status Meaning Description Schema
200 OK Success ErrorMessage
400 Bad Request Bad Request ErrorMessage
401 Unauthorized Unauthorized ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Shopping

Get random products for the home page

Code samples

GET /shopping

Example responses

200 Response

[
  {
    "productId": 0,
    "productBrandName": "string",
    "productName": "string",
    "productDescription": "string",
    "productPrice": 0,
    "productCreationDate": "2019-08-24T14:15:22Z",
    "productLastUpdate": "2019-08-24T14:15:22Z",
    "stockId": 0,
    "stock": {
      "stockId": 0,
      "stockQuantityAvailable": 0
    },
    "categories": [
      {
        "categoryId": 0,
        "categoryTitle": "string",
        "categoryDescription": "string",
        "products": [
          {}
        ]
      }
    ]
  }
]

Responses

Status Meaning Description Schema
200 OK Success Inline
404 Not Found Not Found ErrorMessage

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [Product] false none [Product model]
» productId integer(int32) false none none
» productBrandName string¦null false none none
» productName string¦null false none none
» productDescription string¦null false none none
» productPrice integer(int32) false none none
» productCreationDate string(date-time) false none none
» productLastUpdate string(date-time) false none none
» stockId integer(int32) false none none
» stock Stock false none none
»» stockId integer(int32) false none none
»» stockQuantityAvailable integer(int32) false none none
» categories [Category]¦null false none none
»» categoryId integer(int32) false none none
»» categoryTitle string¦null false none none
»» categoryDescription string¦null false none none
»» products [Product]¦null false none Product model
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Get the best seller products

Code samples

GET /shopping/bestSeller

Example responses

200 Response

[
  {
    "orderProductId": 0,
    "productId": 0,
    "product": {
      "productId": 0,
      "productBrandName": "string",
      "productName": "string",
      "productDescription": "string",
      "productPrice": 0,
      "productCreationDate": "2019-08-24T14:15:22Z",
      "productLastUpdate": "2019-08-24T14:15:22Z",
      "stockId": 0,
      "stock": {
        "stockId": 0,
        "stockQuantityAvailable": 0
      },
      "categories": [
        {
          "categoryId": 0,
          "categoryTitle": "string",
          "categoryDescription": "string",
          "products": [
            {}
          ]
        }
      ]
    },
    "orderId": 0,
    "order": {
      "orderId": 0,
      "orderPrice": 0,
      "orderTaxPrice": 0,
      "orderDeliveryPrice": 0,
      "orderDate": "2019-08-24T14:15:22Z",
      "orderStatus": true,
      "userId": 0,
      "user": {
        "userId": 0,
        "serviceId": "string",
        "lastName": "string",
        "firstName": "string",
        "birthDate": "2019-08-24T14:15:22Z",
        "email": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "lastUpdatedAt": "2019-08-24T14:15:22Z",
        "roleId": 0,
        "role": {
          "roleId": 0,
          "roleName": "string",
          "roleNumber": 0
        },
        "orders": [
          {}
        ]
      },
      "products": [
        {}
      ],
      "animals": [
        {
          "animalId": 0,
          "animalBirthDate": "2019-08-24T14:15:22Z",
          "animalColor": "string",
          "animalPrice": 0,
          "animalCreationDate": "2019-08-24T14:15:22Z",
          "animalLastUpdate": "2019-08-24T14:15:22Z",
          "speciesId": 0,
          "species": {
            "speciesId": 0,
            "speciesName": "string"
          }
        }
      ]
    },
    "quantity": 0,
    "shipped": true
  }
]

Responses

Status Meaning Description Schema
200 OK Success Inline
404 Not Found Not Found ErrorMessage

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [OrderProduct] false none none
» orderProductId integer(int32) false none none
» productId integer(int32) false none none
» product Product false none Product model
»» productId integer(int32) false none none
»» productBrandName string¦null false none none
»» productName string¦null false none none
»» productDescription string¦null false none none
»» productPrice integer(int32) false none none
»» productCreationDate string(date-time) false none none
»» productLastUpdate string(date-time) false none none
»» stockId integer(int32) false none none
»» stock Stock false none none
»»» stockId integer(int32) false none none
»»» stockQuantityAvailable integer(int32) false none none
»» categories [Category]¦null false none none
»»» categoryId integer(int32) false none none
»»» categoryTitle string¦null false none none
»»» categoryDescription string¦null false none none
»»» products [Product]¦null false none Product model
» orderId integer(int32) false none none
» order Order false none none
»» orderId integer(int32) false none none
»» orderPrice integer(int32) false none none
»» orderTaxPrice integer(int32) false none none
»» orderDeliveryPrice integer(int32) false none none
»» orderDate string(date-time) false none none
»» orderStatus boolean false none none
»» userId integer(int32) false none none
»» user User false none none
»»» userId integer(int32) false none none
»»» serviceId string true none none
»»» lastName string¦null false none none
»»» firstName string¦null false none none
»»» birthDate string(date-time)¦null false none none
»»» email string true none none
»»» createdAt string(date-time) false none none
»»» lastUpdatedAt string(date-time) false none none
»»» roleId integer(int32) false none none
»»» role Role false none none
»»»» roleId integer(int32) false none none
»»»» roleName string¦null false none none
»»»» roleNumber integer(int32) false none none
»»» orders [Order]¦null false none none
»» products [OrderProduct]¦null false none none
»» animals [Animal]¦null false none none
»»» animalId integer(int32) false none none
»»» animalBirthDate string(date-time) false none none
»»» animalColor string¦null false none none
»»» animalPrice integer(int32) false none none
»»» animalCreationDate string(date-time) false none none
»»» animalLastUpdate string(date-time) false none none
»»» speciesId integer(int32) false none none
»»» species Species false none none
»»»» speciesId integer(int32) false none none
»»»» speciesName string¦null false none none
» quantity integer(int32) false none none
» shipped boolean false none none
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Get the brands of the products

Code samples

GET /shopping/brands

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK Success Inline
404 Not Found Not Found ErrorMessage

Response Schema

To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Get the categories of the products

Code samples

GET /shopping/categories

Example responses

200 Response

[
  {
    "categoryId": 0,
    "categoryTitle": "string",
    "categoryDescription": "string",
    "products": [
      {
        "productId": 0,
        "productBrandName": "string",
        "productName": "string",
        "productDescription": "string",
        "productPrice": 0,
        "productCreationDate": "2019-08-24T14:15:22Z",
        "productLastUpdate": "2019-08-24T14:15:22Z",
        "stockId": 0,
        "stock": {
          "stockId": 0,
          "stockQuantityAvailable": 0
        },
        "categories": [
          {}
        ]
      }
    ]
  }
]

Responses

Status Meaning Description Schema
200 OK Success Inline
404 Not Found Not Found ErrorMessage

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [Category] false none none
» categoryId integer(int32) false none none
» categoryTitle string¦null false none none
» categoryDescription string¦null false none none
» products [Product]¦null false none Product model
»» productId integer(int32) false none none
»» productBrandName string¦null false none none
»» productName string¦null false none none
»» productDescription string¦null false none none
»» productPrice integer(int32) false none none
»» productCreationDate string(date-time) false none none
»» productLastUpdate string(date-time) false none none
»» stockId integer(int32) false none none
»» stock Stock false none none
»»» stockId integer(int32) false none none
»»» stockQuantityAvailable integer(int32) false none none
»» categories [Category]¦null false none none
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Get result from a search

Code samples

GET /shopping/search/{search}

Parameters

Name In Type Required Description
search path string true none
brand query string false none
category query string false none
minPrice query string false none
maxPrice query string false none

Example responses

200 Response

[
  {
    "productId": 0,
    "productBrandName": "string",
    "productName": "string",
    "productDescription": "string",
    "productPrice": 0,
    "productCreationDate": "2019-08-24T14:15:22Z",
    "productLastUpdate": "2019-08-24T14:15:22Z",
    "stockId": 0,
    "stock": {
      "stockId": 0,
      "stockQuantityAvailable": 0
    },
    "categories": [
      {
        "categoryId": 0,
        "categoryTitle": "string",
        "categoryDescription": "string",
        "products": [
          {}
        ]
      }
    ]
  }
]

Responses

Status Meaning Description Schema
200 OK Success Inline
404 Not Found Not Found ErrorMessage

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [Product] false none [Product model]
» productId integer(int32) false none none
» productBrandName string¦null false none none
» productName string¦null false none none
» productDescription string¦null false none none
» productPrice integer(int32) false none none
» productCreationDate string(date-time) false none none
» productLastUpdate string(date-time) false none none
» stockId integer(int32) false none none
» stock Stock false none none
»» stockId integer(int32) false none none
»» stockQuantityAvailable integer(int32) false none none
» categories [Category]¦null false none none
»» categoryId integer(int32) false none none
»» categoryTitle string¦null false none none
»» categoryDescription string¦null false none none
»» products [Product]¦null false none Product model
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Test

Route for test if user is connected

Code samples

GET /dev/test-connected

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Route for test if user database has dev user

Code samples

GET /dev/test-dev-users

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Route that return all dev users to test the roles

Code samples

GET /dev/test-roles

Example responses

200 Response

{
  "roleName": "string",
  "token": "string"
}

Responses

Status Meaning Description Schema
200 OK Success UserRole
400 Bad Request Bad Request ErrorMessage
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Get all roles for dev

Code samples

GET /dev/roles

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Set roles for current user, has to be conneceted

Code samples

POST /dev/roles/{roleNumber}

Parameters

Name In Type Required Description
roleNumber path string true none

Responses

Status Meaning Description Schema
200 OK Success None
To perform this operation, you must be authenticated by means of one of the following methods: Bearer

Schemas

Animal

{
  "animalId": 0,
  "animalBirthDate": "2019-08-24T14:15:22Z",
  "animalColor": "string",
  "animalPrice": 0,
  "animalCreationDate": "2019-08-24T14:15:22Z",
  "animalLastUpdate": "2019-08-24T14:15:22Z",
  "speciesId": 0,
  "species": {
    "speciesId": 0,
    "speciesName": "string"
  }
}

Properties

Name Type Required Restrictions Description
animalId integer(int32) false none none
animalBirthDate string(date-time) false none none
animalColor string¦null false none none
animalPrice integer(int32) false none none
animalCreationDate string(date-time) false none none
animalLastUpdate string(date-time) false none none
speciesId integer(int32) false none none
species Species false none none

Category

{
  "categoryId": 0,
  "categoryTitle": "string",
  "categoryDescription": "string",
  "products": [
    {
      "productId": 0,
      "productBrandName": "string",
      "productName": "string",
      "productDescription": "string",
      "productPrice": 0,
      "productCreationDate": "2019-08-24T14:15:22Z",
      "productLastUpdate": "2019-08-24T14:15:22Z",
      "stockId": 0,
      "stock": {
        "stockId": 0,
        "stockQuantityAvailable": 0
      },
      "categories": [
        {
          "categoryId": 0,
          "categoryTitle": "string",
          "categoryDescription": "string",
          "products": []
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
categoryId integer(int32) false none none
categoryTitle string¦null false none none
categoryDescription string¦null false none none
products [Product]¦null false none [Product model]

CategoryDto

{
  "categoryTitle": "string",
  "categoryDescription": "string",
  "products": [
    {
      "productId": 0,
      "productBrandName": "string",
      "productName": "string",
      "productDescription": "string",
      "productPrice": 0,
      "productCreationDate": "2019-08-24T14:15:22Z",
      "productLastUpdate": "2019-08-24T14:15:22Z",
      "stock": {
        "quantity": 0
      },
      "categories": [
        {
          "categoryTitle": "string",
          "categoryDescription": "string",
          "products": []
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
categoryTitle string¦null false none none
categoryDescription string¦null false none none
products [ProductDto]¦null false none none

ErrorMessage

{
  "message": "string",
  "statuCode": 0
}

Properties

Name Type Required Restrictions Description
message string¦null false none none
statuCode integer(int32) false none none

Order

{
  "orderId": 0,
  "orderPrice": 0,
  "orderTaxPrice": 0,
  "orderDeliveryPrice": 0,
  "orderDate": "2019-08-24T14:15:22Z",
  "orderStatus": true,
  "userId": 0,
  "user": {
    "userId": 0,
    "serviceId": "string",
    "lastName": "string",
    "firstName": "string",
    "birthDate": "2019-08-24T14:15:22Z",
    "email": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "lastUpdatedAt": "2019-08-24T14:15:22Z",
    "roleId": 0,
    "role": {
      "roleId": 0,
      "roleName": "string",
      "roleNumber": 0
    },
    "orders": [
      {
        "orderId": 0,
        "orderPrice": 0,
        "orderTaxPrice": 0,
        "orderDeliveryPrice": 0,
        "orderDate": "2019-08-24T14:15:22Z",
        "orderStatus": true,
        "userId": 0,
        "user": {},
        "products": [
          {
            "orderProductId": 0,
            "productId": 0,
            "product": {
              "productId": 0,
              "productBrandName": "string",
              "productName": "string",
              "productDescription": "string",
              "productPrice": 0,
              "productCreationDate": "2019-08-24T14:15:22Z",
              "productLastUpdate": "2019-08-24T14:15:22Z",
              "stockId": 0,
              "stock": {
                "stockId": 0,
                "stockQuantityAvailable": 0
              },
              "categories": [
                {
                  "categoryId": 0,
                  "categoryTitle": "string",
                  "categoryDescription": "string",
                  "products": [
                    {}
                  ]
                }
              ]
            },
            "orderId": 0,
            "order": {},
            "quantity": 0,
            "shipped": true
          }
        ],
        "animals": [
          {
            "animalId": 0,
            "animalBirthDate": "2019-08-24T14:15:22Z",
            "animalColor": "string",
            "animalPrice": 0,
            "animalCreationDate": "2019-08-24T14:15:22Z",
            "animalLastUpdate": "2019-08-24T14:15:22Z",
            "speciesId": 0,
            "species": {
              "speciesId": 0,
              "speciesName": "string"
            }
          }
        ]
      }
    ]
  },
  "products": [
    {
      "orderProductId": 0,
      "productId": 0,
      "product": {
        "productId": 0,
        "productBrandName": "string",
        "productName": "string",
        "productDescription": "string",
        "productPrice": 0,
        "productCreationDate": "2019-08-24T14:15:22Z",
        "productLastUpdate": "2019-08-24T14:15:22Z",
        "stockId": 0,
        "stock": {
          "stockId": 0,
          "stockQuantityAvailable": 0
        },
        "categories": [
          {
            "categoryId": 0,
            "categoryTitle": "string",
            "categoryDescription": "string",
            "products": [
              {}
            ]
          }
        ]
      },
      "orderId": 0,
      "order": {
        "orderId": 0,
        "orderPrice": 0,
        "orderTaxPrice": 0,
        "orderDeliveryPrice": 0,
        "orderDate": "2019-08-24T14:15:22Z",
        "orderStatus": true,
        "userId": 0,
        "user": {
          "userId": 0,
          "serviceId": "string",
          "lastName": "string",
          "firstName": "string",
          "birthDate": "2019-08-24T14:15:22Z",
          "email": "string",
          "createdAt": "2019-08-24T14:15:22Z",
          "lastUpdatedAt": "2019-08-24T14:15:22Z",
          "roleId": 0,
          "role": {
            "roleId": 0,
            "roleName": "string",
            "roleNumber": 0
          },
          "orders": [
            {}
          ]
        },
        "products": [],
        "animals": [
          {
            "animalId": 0,
            "animalBirthDate": "2019-08-24T14:15:22Z",
            "animalColor": "string",
            "animalPrice": 0,
            "animalCreationDate": "2019-08-24T14:15:22Z",
            "animalLastUpdate": "2019-08-24T14:15:22Z",
            "speciesId": 0,
            "species": {
              "speciesId": 0,
              "speciesName": "string"
            }
          }
        ]
      },
      "quantity": 0,
      "shipped": true
    }
  ],
  "animals": [
    {
      "animalId": 0,
      "animalBirthDate": "2019-08-24T14:15:22Z",
      "animalColor": "string",
      "animalPrice": 0,
      "animalCreationDate": "2019-08-24T14:15:22Z",
      "animalLastUpdate": "2019-08-24T14:15:22Z",
      "speciesId": 0,
      "species": {
        "speciesId": 0,
        "speciesName": "string"
      }
    }
  ]
}

Properties

Name Type Required Restrictions Description
orderId integer(int32) false none none
orderPrice integer(int32) false none none
orderTaxPrice integer(int32) false none none
orderDeliveryPrice integer(int32) false none none
orderDate string(date-time) false none none
orderStatus boolean false none none
userId integer(int32) false none none
user User false none none
products [OrderProduct]¦null false none none
animals [Animal]¦null false none none

OrderProduct

{
  "orderProductId": 0,
  "productId": 0,
  "product": {
    "productId": 0,
    "productBrandName": "string",
    "productName": "string",
    "productDescription": "string",
    "productPrice": 0,
    "productCreationDate": "2019-08-24T14:15:22Z",
    "productLastUpdate": "2019-08-24T14:15:22Z",
    "stockId": 0,
    "stock": {
      "stockId": 0,
      "stockQuantityAvailable": 0
    },
    "categories": [
      {
        "categoryId": 0,
        "categoryTitle": "string",
        "categoryDescription": "string",
        "products": [
          {}
        ]
      }
    ]
  },
  "orderId": 0,
  "order": {
    "orderId": 0,
    "orderPrice": 0,
    "orderTaxPrice": 0,
    "orderDeliveryPrice": 0,
    "orderDate": "2019-08-24T14:15:22Z",
    "orderStatus": true,
    "userId": 0,
    "user": {
      "userId": 0,
      "serviceId": "string",
      "lastName": "string",
      "firstName": "string",
      "birthDate": "2019-08-24T14:15:22Z",
      "email": "string",
      "createdAt": "2019-08-24T14:15:22Z",
      "lastUpdatedAt": "2019-08-24T14:15:22Z",
      "roleId": 0,
      "role": {
        "roleId": 0,
        "roleName": "string",
        "roleNumber": 0
      },
      "orders": [
        {}
      ]
    },
    "products": [
      {
        "orderProductId": 0,
        "productId": 0,
        "product": {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stockId": 0,
          "stock": {
            "stockId": 0,
            "stockQuantityAvailable": 0
          },
          "categories": [
            {
              "categoryId": 0,
              "categoryTitle": "string",
              "categoryDescription": "string",
              "products": [
                {}
              ]
            }
          ]
        },
        "orderId": 0,
        "order": {},
        "quantity": 0,
        "shipped": true
      }
    ],
    "animals": [
      {
        "animalId": 0,
        "animalBirthDate": "2019-08-24T14:15:22Z",
        "animalColor": "string",
        "animalPrice": 0,
        "animalCreationDate": "2019-08-24T14:15:22Z",
        "animalLastUpdate": "2019-08-24T14:15:22Z",
        "speciesId": 0,
        "species": {
          "speciesId": 0,
          "speciesName": "string"
        }
      }
    ]
  },
  "quantity": 0,
  "shipped": true
}

Properties

Name Type Required Restrictions Description
orderProductId integer(int32) false none none
productId integer(int32) false none none
product Product false none Product model
orderId integer(int32) false none none
order Order false none none
quantity integer(int32) false none none
shipped boolean false none none

Product

{
  "productId": 0,
  "productBrandName": "string",
  "productName": "string",
  "productDescription": "string",
  "productPrice": 0,
  "productCreationDate": "2019-08-24T14:15:22Z",
  "productLastUpdate": "2019-08-24T14:15:22Z",
  "stockId": 0,
  "stock": {
    "stockId": 0,
    "stockQuantityAvailable": 0
  },
  "categories": [
    {
      "categoryId": 0,
      "categoryTitle": "string",
      "categoryDescription": "string",
      "products": [
        {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stockId": 0,
          "stock": {
            "stockId": 0,
            "stockQuantityAvailable": 0
          },
          "categories": []
        }
      ]
    }
  ]
}

Product model

Properties

Name Type Required Restrictions Description
productId integer(int32) false none none
productBrandName string¦null false none none
productName string¦null false none none
productDescription string¦null false none none
productPrice integer(int32) false none none
productCreationDate string(date-time) false none none
productLastUpdate string(date-time) false none none
stockId integer(int32) false none none
stock Stock false none none
categories [Category]¦null false none none

ProductDto

{
  "productId": 0,
  "productBrandName": "string",
  "productName": "string",
  "productDescription": "string",
  "productPrice": 0,
  "productCreationDate": "2019-08-24T14:15:22Z",
  "productLastUpdate": "2019-08-24T14:15:22Z",
  "stock": {
    "quantity": 0
  },
  "categories": [
    {
      "categoryTitle": "string",
      "categoryDescription": "string",
      "products": [
        {
          "productId": 0,
          "productBrandName": "string",
          "productName": "string",
          "productDescription": "string",
          "productPrice": 0,
          "productCreationDate": "2019-08-24T14:15:22Z",
          "productLastUpdate": "2019-08-24T14:15:22Z",
          "stock": {
            "quantity": 0
          },
          "categories": []
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
productId integer(int32) false none none
productBrandName string¦null false none none
productName string¦null false none none
productDescription string¦null false none none
productPrice integer(int32) false none none
productCreationDate string(date-time) false none none
productLastUpdate string(date-time) false none none
stock StockDto false none none
categories [CategoryDto]¦null false none none

Role

{
  "roleId": 0,
  "roleName": "string",
  "roleNumber": 0
}

Properties

Name Type Required Restrictions Description
roleId integer(int32) false none none
roleName string¦null false none none
roleNumber integer(int32) false none none

Species

{
  "speciesId": 0,
  "speciesName": "string"
}

Properties

Name Type Required Restrictions Description
speciesId integer(int32) false none none
speciesName string¦null false none none

Stock

{
  "stockId": 0,
  "stockQuantityAvailable": 0
}

Properties

Name Type Required Restrictions Description
stockId integer(int32) false none none
stockQuantityAvailable integer(int32) false none none

StockDto

{
  "quantity": 0
}

Properties

Name Type Required Restrictions Description
quantity integer(int32) false none none

User

{
  "userId": 0,
  "serviceId": "string",
  "lastName": "string",
  "firstName": "string",
  "birthDate": "2019-08-24T14:15:22Z",
  "email": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "lastUpdatedAt": "2019-08-24T14:15:22Z",
  "roleId": 0,
  "role": {
    "roleId": 0,
    "roleName": "string",
    "roleNumber": 0
  },
  "orders": [
    {
      "orderId": 0,
      "orderPrice": 0,
      "orderTaxPrice": 0,
      "orderDeliveryPrice": 0,
      "orderDate": "2019-08-24T14:15:22Z",
      "orderStatus": true,
      "userId": 0,
      "user": {
        "userId": 0,
        "serviceId": "string",
        "lastName": "string",
        "firstName": "string",
        "birthDate": "2019-08-24T14:15:22Z",
        "email": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "lastUpdatedAt": "2019-08-24T14:15:22Z",
        "roleId": 0,
        "role": {
          "roleId": 0,
          "roleName": "string",
          "roleNumber": 0
        },
        "orders": []
      },
      "products": [
        {
          "orderProductId": 0,
          "productId": 0,
          "product": {
            "productId": 0,
            "productBrandName": "string",
            "productName": "string",
            "productDescription": "string",
            "productPrice": 0,
            "productCreationDate": "2019-08-24T14:15:22Z",
            "productLastUpdate": "2019-08-24T14:15:22Z",
            "stockId": 0,
            "stock": {
              "stockId": 0,
              "stockQuantityAvailable": 0
            },
            "categories": [
              {
                "categoryId": 0,
                "categoryTitle": "string",
                "categoryDescription": "string",
                "products": [
                  {}
                ]
              }
            ]
          },
          "orderId": 0,
          "order": {},
          "quantity": 0,
          "shipped": true
        }
      ],
      "animals": [
        {
          "animalId": 0,
          "animalBirthDate": "2019-08-24T14:15:22Z",
          "animalColor": "string",
          "animalPrice": 0,
          "animalCreationDate": "2019-08-24T14:15:22Z",
          "animalLastUpdate": "2019-08-24T14:15:22Z",
          "speciesId": 0,
          "species": {
            "speciesId": 0,
            "speciesName": "string"
          }
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
userId integer(int32) false none none
serviceId string true none none
lastName string¦null false none none
firstName string¦null false none none
birthDate string(date-time)¦null false none none
email string true none none
createdAt string(date-time) false none none
lastUpdatedAt string(date-time) false none none
roleId integer(int32) false none none
role Role false none none
orders [Order]¦null false none none

UserDto

{
  "userId": 0,
  "lastName": "string",
  "firstName": "string",
  "email": "string"
}

Properties

Name Type Required Restrictions Description
userId integer(int32) false none none
lastName string¦null false none none
firstName string¦null false none none
email string¦null false none none

UserRole

{
  "roleName": "string",
  "token": "string"
}

Properties

Name Type Required Restrictions Description
roleName string¦null false none none
token string¦null false none none