{"info":{"_postman_id":"cae037ec-ef21-4318-899c-deaf8ed053d3","name":"Spring POS","description":"<html><head></head><body><p>The <strong>Spring-POS</strong> is a powerful RESTful API built using the Spring Framework, designed to streamline the management of a Point of Sale (POS) system. This API provides comprehensive CRUD operations and advanced transactional management for essential entities such as <strong>customers</strong>, <strong>items</strong>, <strong>orders</strong>, and <strong>order details</strong>.</p>\n<p>With a focus on robust data handling, the Spring-POS ensures efficient processing and data integrity through well-defined transactional operations. Developers can easily interact with the POS system using various endpoints that allow for the creation, retrieval, updating, and deletion of records, while ensuring consistency throughout the system.</p>\n<p>This documentation offers in-depth details on each endpoint, including the request and response formats, helping developers seamlessly integrate the API into their applications. Whether you’re managing customers, tracking inventory, or processing orders, the Spring-POS is built to support scalable and reliable POS operations.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"35385442","collectionId":"cae037ec-ef21-4318-899c-deaf8ed053d3","publishedId":"2sAXxV4p5T","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2024-10-16T06:01:37.000Z"},"item":[{"name":"Customer","item":[{"name":"Save Customer","id":"e2a0d43f-90e9-4631-837c-59647915eedb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"name","value":"Torvald","type":"text"},{"key":"address","value":"United Sates","type":"text"},{"key":"contact","value":"0123456444","type":"text"}]},"url":"http://localhost:8080/app/api/v1/customer","description":"<p>This endpoint allows you to save a new customer. The request must include the customer's name, address and contact. The data is validated before being persisted.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","customer"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"e2a0d43f-90e9-4631-837c-59647915eedb"},{"name":"Get All Customers","id":"db88833e-fae1-48ce-816c-dfc68e25fa33","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/customer","description":"<p>This endpoint fetches the details of all customers. It returns a list of customer data, or an error message if no customers are found.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","customer"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"db88833e-fae1-48ce-816c-dfc68e25fa33"},{"name":"Get Selected Customer","id":"779794cc-d93b-4e0d-83ae-67754878981f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/customer/CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18","description":"<p>This endpoint retrieves the details of a specific customer by their ID. If the customer is found, their details are returned; otherwise, an error message is provided.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","customer","CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"779794cc-d93b-4e0d-83ae-67754878981f"},{"name":"Update Customer","id":"284f9d76-3783-45e0-9ca2-4d1e68f04a3e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[],"body":{"mode":"formdata","formdata":[{"key":"updateName","value":"Torvaldx","type":"text"},{"key":"updateAddress","value":"United Satesx","type":"text"},{"key":"updateContact","value":"0123488888","type":"text"}]},"url":"http://localhost:8080/app/api/v1/customer/CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18","description":"<p>This endpoint updates the details of an existing customer identified by their ID. The request must include the updated name, address and contact. The data is validated before being updated.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","customer","CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18"],"host":["localhost"],"query":[{"disabled":true,"key":"updateName","value":"Ericx"},{"disabled":true,"key":"updateAddress","value":"Australliax\n"}],"variable":[]}},"response":[],"_postman_id":"284f9d76-3783-45e0-9ca2-4d1e68f04a3e"},{"name":"Delete Customer","id":"78b20abc-6f2f-4aeb-b50b-f5d2a6fd8193","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"http://localhost:8080/app/api/v1/customer/CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18","description":"<p>This endpoint deletes a specific customer by their ID. If the customer is part of an existing order, the deletion is not allowed, and an error message is returned.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","customer","CUSTOMER-8e1e46cb-5140-4218-a2ea-2ef42536bd18"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"78b20abc-6f2f-4aeb-b50b-f5d2a6fd8193"}],"id":"53f8dd40-6360-46bb-a8ef-f4f77512989f","description":"<p>The <strong>Customer</strong> section of the <strong>Spring-POS</strong> offers a set of endpoints dedicated to managing customer data efficiently. These endpoints support <strong>creating</strong>, <strong>retrieving</strong>, <strong>updating</strong>, and <strong>deleting</strong> customer records, ensuring smooth customer management operations within the POS system.</p>\n","_postman_id":"53f8dd40-6360-46bb-a8ef-f4f77512989f"},{"name":"Health Check","item":[{"name":"Health Test","id":"9f3ebc13-ec07-404d-81b9-b1b5940c8972","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/healthtest","description":"<p>The Health Check endpoint is designed to verify the operational status of the Spring-POS. When a GET request is made to this endpoint, it responds with a success message indicating that the API is running and accessible. This endpoint is useful for monitoring and ensuring the health of the application.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","healthtest"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"9f3ebc13-ec07-404d-81b9-b1b5940c8972"}],"id":"ac294bff-e379-43ef-8fd7-f402631eee64","description":"<p>The <strong>Health Check</strong> folder contains an endpoint designed to verify the operational status of the <strong>Spring-POS</strong>. By sending a simple GET request, this endpoint responds with a success message, confirming that the API is running and accessible. This feature is crucial for monitoring the health of the application and ensuring that it is functioning as expected.</p>\n<p>This health check endpoint is useful for regular API status verification and can be integrated into monitoring tools for automated uptime checks.</p>\n","_postman_id":"ac294bff-e379-43ef-8fd7-f402631eee64"},{"name":"Item","item":[{"name":"Save Item","id":"9de3f5dc-da22-41ee-ac2e-00b620a8c095","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"name","value":"Patriot 32GB Ram","description":"","type":"text"},{"key":"price","value":"20000","type":"text"},{"key":"qty","value":"200","type":"text"}]},"url":"http://localhost:8080/app/api/v1/item","description":"<p>Creates a new item in the inventory.The request must contain the item details in form-data format. The item will be saved to the database if the data is valid.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","item"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"9de3f5dc-da22-41ee-ac2e-00b620a8c095"},{"name":"Update Item","id":"5cfc5d37-f7ce-41f5-af77-21c5980913a0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[],"body":{"mode":"formdata","formdata":[{"key":"updateName","value":"Patriotx 64GB Ram","type":"text"},{"key":"updatePrice","value":"28000","type":"text"},{"key":"updateQty","value":"200","type":"text"}]},"url":"http://localhost:8080/app/api/v1/item/ITEM-509f4bec-a5ee-4011-8166-71d6c3727206","description":"<p>Updates the details of a specific item by its ID. The request must contain the item details in form-data format. The item will be saved to the database if the data is valid.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","item","ITEM-509f4bec-a5ee-4011-8166-71d6c3727206"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"5cfc5d37-f7ce-41f5-af77-21c5980913a0"},{"name":"Get All Items","id":"214aa221-8c87-4d9a-bdb0-0ae477d0f638","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/item","description":"<p>Retrieves a list of all items in the inventory. The item details are returned in JSON format.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","item"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"214aa221-8c87-4d9a-bdb0-0ae477d0f638"},{"name":"Get Selected Item","id":"a4d7958c-0590-45a7-b569-8759a16602b4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/item/ITEM-509f4bec-a5ee-4011-8166-71d6c3727206","description":"<p>Retrieves the details of a specific item by its ID. The item details are returned in JSON format.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","item","ITEM-509f4bec-a5ee-4011-8166-71d6c3727206"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"a4d7958c-0590-45a7-b569-8759a16602b4"},{"name":"Delete Item","id":"b97ebb1e-8a25-4069-ba68-ed4d6b02a9f0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"http://localhost:8080/app/api/v1/item/ITEM-509f4bec-a5ee-4011-8166-71d6c3727206","description":"<p>Deletes a specific item by its ID. The item will be removed from the database if it is not part of an existing order.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","item","ITEM-509f4bec-a5ee-4011-8166-71d6c3727206"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"b97ebb1e-8a25-4069-ba68-ed4d6b02a9f0"}],"id":"41e11607-060f-4b75-a52f-deaba614b75c","description":"<p>The <strong>Item</strong> folder includes endpoints for managing item data within the Spring-POS. These endpoints facilitate the creation, retrieval, updating, and deletion of item records. The endpoints are structured to ensure accurate data handling and validation, supporting the overall inventory management functionality of the application.</p>\n","_postman_id":"41e11607-060f-4b75-a52f-deaba614b75c"},{"name":"Order","item":[{"name":"Save Order","id":"de833355-b8b5-48a0-9ef9-7193e44cc57e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"date\": \"2024-10-16\",\n    \"customerId\": \"CUSTOMER-50a36457-6da4-4265-a669-78e7592bc22d\",\n    \"items\": [\n        {\n            \"code\": \"ITEM-0b3b1df8-ed57-4e51-baa5-f7cde8be3e43\",\n            \"qty\": 4\n        },\n        {\n            \"code\": \"ITEM-d3d6ff50-87b2-4a27-989f-40cb2d6596ae\",\n            \"qty\": 5\n        }\n    ],\n    \"total\": 290,\n    \"discount\": 5,\n    \"subTotal\": 275.5,\n    \"cash\": 500,\n    \"balance\": 224.5\n}","options":{"raw":{"language":"json"}}},"url":"http://localhost:8080/app/api/v1/order","description":"<p>Creates a new order in the system. The order details, including customer information and items, must be provided in the request body.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","order"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"de833355-b8b5-48a0-9ef9-7193e44cc57e"},{"name":"Get Selected Order","id":"34e1472b-59d9-4373-a5b2-bb9be07b5dc2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/order/4","description":"<p>Retrieves the details of a specific order by its ID.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","order","4"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"34e1472b-59d9-4373-a5b2-bb9be07b5dc2"},{"name":"Get All Orders","id":"f87599d7-cb3d-4e32-81c6-65a9d67d1693","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:8080/app/api/v1/order","description":"<p>Fetches a list of all orders in the system.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["app","api","v1","order"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"f87599d7-cb3d-4e32-81c6-65a9d67d1693"}],"id":"eb870ab4-fd05-44b1-9fe3-5cae20bff3f1","description":"<p>The <strong>Order</strong> folder encompasses endpoints for managing order data within the Spring-POS. These endpoints enable the creation, retrieval, and listing of orders, along with their associated details. The endpoints are designed to maintain the integrity of order transactions, including customer and item associations, ensuring a seamless order management process.</p>\n","_postman_id":"eb870ab4-fd05-44b1-9fe3-5cae20bff3f1"}]}