{
	"info": {
		"_postman_id": "35a5e2cc-d9f4-492c-8e93-7ed2c4f37587",
		"name": "Supply Domain - Goods Receipts API",
		"description": "Complete API collection for Supply Domain Goods Receipts Management with full request/response examples",
		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
		"_exporter_id": "50681087"
	},
	"item": [
		{
			"name": "List All Goods Receipts",
			"request": {
				"method": "GET",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts?per_page=15&page=1",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts"
					],
					"query": [
						{
							"key": "per_page",
							"value": "15"
						},
						{
							"key": "page",
							"value": "1"
						}
					]
				},
				"description": "Get list of all goods receipts with pagination"
			},
			"response": [
				{
					"name": "List All Goods Receipts - Success",
					"originalRequest": {
						"method": "GET",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							},
							{
								"key": "Accept",
								"value": "application/json",
								"type": "text"
							}
						],
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts"
							]
						}
					},
					"status": "OK",
					"code": 200,
					"_postman_previewlanguage": "Text",
					"header": [
						{
							"key": "Content-Type",
							"value": "application/json"
						}
					],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipts retrieved successfully\",\n  \"data\": {\n    \"data\": [\n      {\n        \"id\": 1,\n        \"receipt_number\": \"GR-2025-001\",\n        \"purchase_order_id\": 1,\n        \"supplier_id\": 1,\n        \"receipt_date\": \"2025-12-23\",\n        \"quantity_received\": 100,\n        \"quantity_accepted\": 100,\n        \"quantity_rejected\": 0,\n        \"reference_number\": \"INV-2025-001\",\n        \"status\": \"completed\",\n        \"notes\": \"All items received in good condition\",\n        \"created_at\": \"2025-12-23T10:30:00.000000Z\",\n        \"updated_at\": \"2025-12-23T10:30:00.000000Z\",\n        \"deleted_at\": null\n      },\n      {\n        \"id\": 2,\n        \"receipt_number\": \"GR-2025-002\",\n        \"purchase_order_id\": 2,\n        \"supplier_id\": 2,\n        \"receipt_date\": \"2025-12-24\",\n        \"quantity_received\": 150,\n        \"quantity_accepted\": 145,\n        \"quantity_rejected\": 5,\n        \"reference_number\": \"INV-2025-002\",\n        \"status\": \"partially_accepted\",\n        \"notes\": \"5 units rejected due to packaging damage\",\n        \"created_at\": \"2025-12-24T11:45:00.000000Z\",\n        \"updated_at\": \"2025-12-24T11:45:00.000000Z\",\n        \"deleted_at\": null\n      },\n      {\n        \"id\": 3,\n        \"receipt_number\": \"GR-2025-003\",\n        \"purchase_order_id\": 3,\n        \"supplier_id\": 1,\n        \"receipt_date\": \"2025-12-25\",\n        \"quantity_received\": 75,\n        \"quantity_accepted\": 0,\n        \"quantity_rejected\": 75,\n        \"reference_number\": \"INV-2025-003\",\n        \"status\": \"rejected\",\n        \"notes\": \"All units rejected - quality issues\",\n        \"created_at\": \"2025-12-25T09:15:00.000000Z\",\n        \"updated_at\": \"2025-12-25T09:15:00.000000Z\",\n        \"deleted_at\": null\n      }\n    ],\n    \"links\": {\n      \"first\": \"http://localhost:8000/api/v1/supply/receipts?page=1\",\n      \"last\": \"http://localhost:8000/api/v1/supply/receipts?page=1\",\n      \"prev\": null,\n      \"next\": null\n    },\n    \"meta\": {\n      \"current_page\": 1,\n      \"from\": 1,\n      \"last_page\": 1,\n      \"path\": \"http://localhost:8000/api/v1/supply/receipts\",\n      \"per_page\": 15,\n      \"to\": 3,\n      \"total\": 3\n    }\n  },\n  \"status_code\": 200\n}\n"
				}
			]
		},
		{
			"name": "Get Goods Receipt by ID",
			"request": {
				"method": "GET",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts/1",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts",
						"1"
					]
				},
				"description": "Get a specific goods receipt by ID"
			},
			"response": [
				{
					"name": "Get Goods Receipt - Success",
					"originalRequest": {
						"method": "GET",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							}
						],
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts/1",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts",
								"1"
							]
						}
					},
					"status": "OK",
					"code": 200,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipt retrieved successfully\",\n  \"data\": {\n    \"id\": 1,\n    \"receipt_number\": \"GR-2025-001\",\n    \"purchase_order_id\": 1,\n    \"supplier_id\": 1,\n    \"receipt_date\": \"2025-12-23\",\n    \"quantity_received\": 100,\n    \"quantity_accepted\": 100,\n    \"quantity_rejected\": 0,\n    \"reference_number\": \"INV-2025-001\",\n    \"status\": \"completed\",\n    \"notes\": \"All items received in good condition\",\n    \"created_at\": \"2025-12-23T10:30:00.000000Z\",\n    \"updated_at\": \"2025-12-23T10:30:00.000000Z\",\n    \"deleted_at\": null\n  },\n  \"status_code\": 200\n}\n"
				},
				{
					"name": "Get Goods Receipt - Not Found",
					"originalRequest": {
						"method": "GET",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							}
						],
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts/999",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts",
								"999"
							]
						}
					},
					"status": "Not Found",
					"code": 404,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": false,\n  \"message\": \"No query results found for model [App\\\\Domains\\\\Supply\\\\GoodsReceipts\\\\Models\\\\GoodsReceipt]\",\n  \"status_code\": 404\n}\n"
				}
			]
		},
		{
			"name": "Create Goods Receipt",
			"request": {
				"method": "POST",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Content-Type",
						"value": "application/json",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"body": {
					"mode": "raw",
					"raw": "{\n  \"receipt_number\": \"GR-2025-004\",\n  \"purchase_order_id\": 1,\n  \"received_by\": 1,\n  \"received_at\": \"2025-12-25 10:30:00\",\n  \"status\": \"completed\",\n  \"notes\": \"All items received in good condition\"\n}"
				},
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts"
					]
				},
				"description": "Create a new goods receipt"
			},
			"response": [
				{
					"name": "Create Goods Receipt - Success",
					"originalRequest": {
						"method": "POST",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							},
							{
								"key": "Content-Type",
								"value": "application/json",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\n  \"receipt_number\": \"GR-2025-004\",\n  \"purchase_order_id\": 4,\n  \"supplier_id\": 3,\n  \"receipt_date\": \"2025-12-26\",\n  \"quantity_received\": 200,\n  \"quantity_accepted\": 200,\n  \"quantity_rejected\": 0,\n  \"reference_number\": \"INV-2025-004\",\n  \"status\": \"completed\",\n  \"notes\": \"Standard goods receipt\"\n}"
						},
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts"
							]
						}
					},
					"status": "Created",
					"code": 201,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipt created successfully\",\n  \"data\": {\n    \"id\": 4,\n    \"receipt_number\": \"GR-2025-004\",\n    \"purchase_order_id\": 4,\n    \"supplier_id\": 3,\n    \"receipt_date\": \"2025-12-26\",\n    \"quantity_received\": 200,\n    \"quantity_accepted\": 200,\n    \"quantity_rejected\": 0,\n    \"reference_number\": \"INV-2025-004\",\n    \"status\": \"completed\",\n    \"notes\": \"Standard goods receipt\",\n    \"created_at\": \"2025-12-26T14:30:00.000000Z\",\n    \"updated_at\": \"2025-12-26T14:30:00.000000Z\",\n    \"deleted_at\": null\n  },\n  \"status_code\": 201\n}\n"
				},
				{
					"name": "Create Goods Receipt - Validation Error",
					"originalRequest": {
						"method": "POST",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							},
							{
								"key": "Content-Type",
								"value": "application/json",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\n  \"receipt_number\": \"GR-2025-001\",\n  \"supplier_id\": 3\n}"
						},
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts"
							]
						}
					},
					"status": "Unprocessable Entity",
					"code": 422,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": false,\n  \"message\": \"Validation failed\",\n  \"data\": {\n    \"errors\": {\n      \"receipt_number\": [\n        \"The receipt number has already been taken.\"\n      ],\n      \"purchase_order_id\": [\n        \"The purchase order id field is required.\"\n      ]\n    }\n  },\n  \"status_code\": 422\n}\n"
				}
			]
		},
		{
			"name": "Update Goods Receipt",
			"request": {
				"method": "PUT",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Content-Type",
						"value": "application/json",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"body": {
					"mode": "raw",
					"raw": "{\n  \"receipt_number\": \"GR-2025-004\",\n  \"purchase_order_id\": 1,\n  \"received_by\": 1,\n  \"received_at\": \"2025-12-25 10:30:00\",\n  \"status\": \"completed\",\n  \"notes\": \"All items received in good condition\"\n}"
				},
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts/1",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts",
						"1"
					]
				},
				"description": "Update an existing goods receipt"
			},
			"response": [
				{
					"name": "Update Goods Receipt - Success",
					"originalRequest": {
						"method": "PUT",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							},
							{
								"key": "Content-Type",
								"value": "application/json",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\n  \"status\": \"partially_accepted\",\n  \"quantity_accepted\": 95,\n  \"quantity_rejected\": 5,\n  \"notes\": \"5 units rejected due to defects\"\n}"
						},
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts/1",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts",
								"1"
							]
						}
					},
					"status": "OK",
					"code": 200,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipt updated successfully\",\n  \"data\": {\n    \"id\": 1,\n    \"receipt_number\": \"GR-2025-001\",\n    \"purchase_order_id\": 1,\n    \"supplier_id\": 1,\n    \"receipt_date\": \"2025-12-23\",\n    \"quantity_received\": 100,\n    \"quantity_accepted\": 95,\n    \"quantity_rejected\": 5,\n    \"reference_number\": \"INV-2025-001\",\n    \"status\": \"partially_accepted\",\n    \"notes\": \"5 units rejected due to defects\",\n    \"created_at\": \"2025-12-23T10:30:00.000000Z\",\n    \"updated_at\": \"2025-12-26T15:45:30.000000Z\",\n    \"deleted_at\": null\n  },\n  \"status_code\": 200\n}\n"
				}
			]
		},
		{
			"name": "Delete Goods Receipt",
			"request": {
				"method": "DELETE",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts/1",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts",
						"1"
					]
				},
				"description": "Delete a goods receipt (soft delete)"
			},
			"response": [
				{
					"name": "Delete Goods Receipt - Success",
					"originalRequest": {
						"method": "DELETE",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							}
						],
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts/1",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts",
								"1"
							]
						}
					},
					"status": "OK",
					"code": 200,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipt deleted successfully\",\n  \"status_code\": 200\n}\n"
				}
			]
		},
		{
			"name": "Restore Goods Receipt",
			"request": {
				"method": "POST",
				"header": [
					{
						"key": "Authorization",
						"value": "Bearer {{access_token}}",
						"type": "text"
					},
					{
						"key": "Accept",
						"value": "application/json",
						"type": "text"
					}
				],
				"url": {
					"raw": "{{BASE_URL}}/supply/receipts/1/restore",
					"host": [
						"{{BASE_URL}}"
					],
					"path": [
						"supply",
						"receipts",
						"1",
						"restore"
					]
				},
				"description": "Restore a soft-deleted goods receipt"
			},
			"response": [
				{
					"name": "Restore Goods Receipt - Success",
					"originalRequest": {
						"method": "POST",
						"header": [
							{
								"key": "Authorization",
								"value": "Bearer token",
								"type": "text"
							}
						],
						"url": {
							"raw": "http://localhost:8000/api/v1/supply/receipts/1/restore",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8000",
							"path": [
								"api",
								"v1",
								"supply",
								"receipts",
								"1",
								"restore"
							]
						}
					},
					"status": "OK",
					"code": 200,
					"_postman_previewlanguage": "Text",
					"header": [],
					"cookie": [],
					"body": "{\n  \"success\": true,\n  \"message\": \"Goods receipt restored successfully\",\n  \"data\": {\n    \"id\": 1,\n    \"receipt_number\": \"GR-2025-001\",\n    \"purchase_order_id\": 1,\n    \"supplier_id\": 1,\n    \"receipt_date\": \"2025-12-23\",\n    \"quantity_received\": 100,\n    \"quantity_accepted\": 95,\n    \"quantity_rejected\": 5,\n    \"reference_number\": \"INV-2025-001\",\n    \"status\": \"partially_accepted\",\n    \"notes\": \"5 units rejected due to defects\",\n    \"created_at\": \"2025-12-23T10:30:00.000000Z\",\n    \"updated_at\": \"2025-12-26T15:45:30.000000Z\",\n    \"deleted_at\": null\n  },\n  \"status_code\": 200\n}\n"
				}
			]
		}
	],
	"variable": [
		{
			"key": "BASE_URL",
			"value": "http://localhost:8000/api/v1",
			"type": "string"
		},
		{
			"key": "access_token",
			"value": "your_bearer_token_here",
			"type": "string"
		}
	]
}