{"openapi":"3.0.0","info":{"title":"Ball Watch API","version":"0.1"},"paths":{"\/product\/limited_group":{"get":{"tags":["Limited Group"],"summary":"Get all limited groups","description":"Retrieve a list of all limited groups.","operationId":"59dfff677f356d2dfc26649c2d175750","responses":{"200":{"description":"List of limited groups"},"401":{"description":"Unauthenticated"}},"security":[{"apiKey":[]}]},"post":{"tags":["Limited Group"],"summary":"Create a new limited group","description":"Create a new limited group with the provided details.","operationId":"b10f8c69fb084db0006e5cf3ad3c2b43","requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"name":{"type":"string"},"range_from":{"type":"integer","format":"int64"},"range_to":{"type":"integer","format":"int64"}},"type":"object"}}}},"responses":{"201":{"description":"Limited group created successfully"},"401":{"description":"Unauthenticated"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]}},"\/product\/limited_group\/{id}":{"get":{"tags":["Limited Group"],"summary":"Get limited group by ID","description":"Retrieve details of a limited group by its ID.","operationId":"e8307a93874942a318c1d360330396cf","parameters":[{"name":"id","in":"path","description":"ID of the limited group","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"200":{"description":"Limited group details"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited group not found"}},"security":[{"apiKey":[]}]},"put":{"tags":["Limited Group"],"summary":"Update an existing limited group","description":"Update an existing limited group with the provided details.","operationId":"6745d211e57d0d46891edf6de5160ddd","parameters":[{"name":"id","in":"path","description":"ID of the limited group","required":true,"schema":{"type":"integer","format":"int64"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"name":{"type":"string"},"range_from":{"type":"integer","format":"int64"},"range_to":{"type":"integer","format":"int64"}},"type":"object"}}}},"responses":{"200":{"description":"Limited group updated successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited group not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]},"delete":{"tags":["Limited Group"],"summary":"Delete a limited group by ID","description":"Delete a limited group by its ID.","operationId":"c6c818c294a45827acaf70ab6d3eb333","parameters":[{"name":"id","in":"path","description":"ID of the limited group","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"204":{"description":"Limited group deleted successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited group not found"}},"security":[{"apiKey":[]}]}},"\/product\/limited_group\/{limited_group_id}\/{number}":{"put":{"tags":["Limited Group"],"summary":"Reserve a number within a limited group","description":"Reserve a number within a specific limited group with the provided details.","operationId":"f33541ebe538e2e7a88ef3cacb7da469","parameters":[{"name":"limited_group_id","in":"path","description":"ID of the limited group","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"number","in":"path","description":"Number to reserve","required":true,"schema":{"type":"integer","format":"int64"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"comment":{"type":"string"}},"type":"object"}}}},"responses":{"200":{"description":"Number reserved successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited group not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]},"delete":{"tags":["Limited Group"],"summary":"Release a reserved number within a limited group","description":"Release a reserved number within a specific limited group.","operationId":"1f283b412e5408056d30b93a95742116","parameters":[{"name":"limited_group_id","in":"path","description":"ID of the limited group","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"number","in":"path","description":"Number to release","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"200":{"description":"Number released successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited group not found"}},"security":[{"apiKey":[]}]}},"\/product\/limited\/{product_id}\/{model}":{"get":{"tags":["Limited Group Numbers"],"summary":"Get all limited numbers for the product","description":"Retrieve a list of all limited numbers for the specified product and model.","operationId":"df07208125d0273c4216bd1ba3e6cf41","parameters":[{"name":"product_id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"List of limited numbers for the product"},"401":{"description":"Unauthenticated"},"404":{"description":"Product not found"}}}},"\/product\/limited\/{product_id}\/{model}\/{number}":{"get":{"tags":["Limited Group Numbers"],"summary":"Get details of a limited number","description":"Retrieve details of a limited number for the specified product and model.","operationId":"b9f8937750f1a8a03de21947ee25c183","parameters":[{"name":"product_id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to retrieve details for","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Details of the limited number"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"}}},"put":{"tags":["Limited Group Numbers"],"summary":"Reserve a limited number permanently","description":"Reserve a limited number permanently for the specified product and model.","operationId":"a88a354fc107b629084eb09182fb708b","parameters":[{"name":"product_id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to reserve permanently","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"order_id":{"type":"integer","format":"int64"},"order_product_id":{"type":"integer","format":"int64"},"comment":{"type":"string"}},"type":"object"}}}},"responses":{"200":{"description":"Limited number reserved permanently"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]},"post":{"tags":["Limited Group Numbers"],"summary":"Reserve a limited number temporarily for 15 minutes","description":"Reserve a limited number temporarily for the specified product and model.","operationId":"4d54f75b7f318930fd8208b031bb0f11","parameters":[{"name":"product_id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to reserve temporarily","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Limited number reserved temporarily"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]}},"\/len\/{model}":{"get":{"tags":["Limited Group Numbers (External)"],"summary":"Get all reserved numbers for the model","description":"Retrieve a list of all reserved numbers for the specified model.","operationId":"9ebf95fce3f598c28c458915d516f659","parameters":[{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"List of reserved numbers for the model","content":{"application\/json":{"schema":{"type":"array","items":{"type":"string"}}}}},"401":{"description":"Unauthenticated"}},"security":[{"apiKey_external":[]}]}},"\/len\/{model}\/{number}":{"get":{"tags":["Limited Group Numbers (External)"],"summary":"Get details of a limited number","description":"Retrieve details of a limited number for the specified model.","operationId":"0954a71c117d859cd13c99a857411bbd","parameters":[{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to retrieve details for","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Details of the limited number"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"}},"security":[{"apiKey_external":[]}]},"put":{"tags":["Limited Group Numbers (External)"],"summary":"Reserve a limited number permanently","description":"Reserve a limited number permanently for the specified model.","operationId":"9db3b944d480f5e1421c091879f5b5c7","parameters":[{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to reserve permanently","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"order_id":{"type":"integer","format":"int64"},"comment":{"type":"string"}},"type":"object"}}}},"responses":{"200":{"description":"Limited number reserved permanently"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey_external":[]}]},"post":{"tags":["Limited Group Numbers (External)"],"summary":"Reserve a limited number temporarily for 15 minutes","description":"Reserve a limited number temporarily for the specified model.","operationId":"a421428967c20a00f7b0493ce352eb20","parameters":[{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Limited number to reserve temporarily","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Limited number reserved temporarily"},"401":{"description":"Unauthenticated"},"404":{"description":"Limited number not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey_external":[]}]}},"\/product\/order\/{order_id}":{"get":{"tags":["Product Order"],"summary":"Get product order by ID","description":"Retrieve details of a product order by its ID.","operationId":"796941193692dcdc0c0e6a08a8faf6f1","parameters":[{"name":"order_id","in":"path","description":"ID of the product order","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"200":{"description":"Product order details"},"401":{"description":"Unauthenticated"},"404":{"description":"Product order not found"}},"security":[{"apiKey":[]}]},"delete":{"tags":["Product Order"],"summary":"Delete a product order by ID","description":"Delete a product order by its ID.","operationId":"fbabc644546d1131279c7c1c5b455fbb","parameters":[{"name":"order_id","in":"path","description":"ID of the product order","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"204":{"description":"Product order deleted successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Product order not found"}},"security":[{"apiKey":[]}]}},"\/product\/order\/{product_id}\/{model}\/{number}":{"put":{"tags":["Product Order"],"summary":"Update a product order","description":"Update a product order with the provided details.","operationId":"fae2edb102745564de110fbced030ea4","parameters":[{"name":"product_id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}},{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}},{"name":"number","in":"path","description":"Number of the product","required":true,"schema":{"type":"integer","format":"int64"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"order_id":{"type":"integer","format":"int64"},"order_product_id":{"type":"integer","format":"int64"}},"type":"object"}}}},"responses":{"200":{"description":"Product order updated successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Product order not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]}},"\/product":{"get":{"tags":["Product"],"summary":"Get all products","description":"Retrieve a list of all products.","operationId":"22905e1f44768d097e237b248ae28fdc","responses":{"200":{"description":"List of products"},"401":{"description":"Unauthenticated"}},"security":[{"apiKey":[]}]},"post":{"tags":["Product"],"summary":"Create a new product","description":"Create a new product with the provided details.","operationId":"06b7daeb9d561c7a65b00f309b5ed31b","requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"product_id":{"type":"integer","format":"int64"},"model":{"type":"string"},"limited_group_id":{"type":"integer","format":"int64"},"quantity":{"type":"integer","format":"int64"}},"type":"object"}}}},"responses":{"201":{"description":"Product created successfully"},"401":{"description":"Unauthenticated"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]}},"\/product\/{id}":{"get":{"tags":["Product"],"summary":"Get product by ID","description":"Retrieve details of a product by its ID.","operationId":"25d1f844c5dbbed34761f4f3b7333485","parameters":[{"name":"id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"200":{"description":"Product details"},"401":{"description":"Unauthenticated"},"404":{"description":"Product not found"}},"security":[{"apiKey":[]}]},"put":{"tags":["Product"],"summary":"Update an existing product","description":"Update an existing product with the provided details.","operationId":"0e409631b231751d093cfd6dab8da07d","parameters":[{"name":"id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}}],"requestBody":{"required":true,"content":{"application\/json":{"schema":{"properties":{"product_id":{"type":"integer","format":"int64"},"model":{"type":"string"},"limited_group_id":{"type":"integer","format":"int64"},"quantity":{"type":"integer","format":"int64"}},"type":"object"}}}},"responses":{"200":{"description":"Product updated successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Product not found"},"422":{"description":"Unprocessable Entity"}},"security":[{"apiKey":[]}]},"delete":{"tags":["Product"],"summary":"Delete a product by ID","description":"Delete a product by its ID.","operationId":"2fd881f872846a3e1323c56fab67c048","parameters":[{"name":"id","in":"path","description":"ID of the product","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"204":{"description":"Product deleted successfully"},"401":{"description":"Unauthenticated"},"404":{"description":"Product not found"}},"security":[{"apiKey":[]}]}},"\/product\/stock\/{model}":{"get":{"tags":["Product"],"summary":"Get stock for a specific product model","description":"Retrieve stock details for the specified product model.","operationId":"6bef6e28f4e04087282f57ea8f65842d","parameters":[{"name":"model","in":"path","description":"Model of the product","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Stock details for the product model"},"404":{"description":"Product not found"}}}}},"components":{"securitySchemes":{"apiKey":{"type":"apiKey","description":"API Key","name":"Auth","in":"header"},"apiKey_external":{"type":"apiKey","description":"API External Key","name":"Auth","in":"header"}}}}