{
    "info": {
        "_postman_id": "property-api-collection",
        "name": "Property API",
        "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
    },
    "item": [
        {
            "name": "Auth",
            "item": [
                {
                    "name": "Register",
                    "request": {
                        "method": "POST",
                        "header": [],
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"name\": \"Test User\",\n    \"email\": \"test@example.com\",\n    \"password\": \"password\",\n    \"password_confirmation\": \"password\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        },
                        "url": {
                            "raw": "{{base_url}}/api/auth/register",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "auth",
                                "register"
                            ]
                        }
                    },
                    "response": []
                },
                {
                    "name": "Login",
                    "request": {
                        "method": "POST",
                        "header": [],
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"email\": \"test@example.com\",\n    \"password\": \"password\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        },
                        "url": {
                            "raw": "{{base_url}}/api/auth/login",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "auth",
                                "login"
                            ]
                        }
                    },
                    "response": []
                }
            ]
        },
        {
            "name": "Properties",
            "item": [
                {
                    "name": "Create Property",
                    "request": {
                        "auth": {
                            "type": "bearer",
                            "bearer": [
                                {
                                    "key": "token",
                                    "value": "{{token}}",
                                    "type": "string"
                                }
                            ]
                        },
                        "method": "POST",
                        "header": [],
                        "body": {
                            "mode": "formdata",
                            "formdata": [
                                {
                                    "key": "title",
                                    "value": "Luxury Villa",
                                    "type": "text"
                                },
                                {
                                    "key": "description",
                                    "value": "A beautiful villa with sea view",
                                    "type": "text"
                                },
                                {
                                    "key": "price",
                                    "value": "1000000",
                                    "type": "text"
                                },
                                {
                                    "key": "location",
                                    "value": "Malibu",
                                    "type": "text"
                                },
                                {
                                    "key": "status",
                                    "value": "available",
                                    "type": "text"
                                },
                                {
                                    "key": "images[]",
                                    "type": "file",
                                    "src": []
                                }
                            ]
                        },
                        "url": {
                            "raw": "{{base_url}}/api/properties",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "properties"
                            ]
                        }
                    },
                    "response": []
                },
                {
                    "name": "Delete Property",
                    "request": {
                        "auth": {
                            "type": "bearer",
                            "bearer": [
                                {
                                    "key": "token",
                                    "value": "{{token}}",
                                    "type": "string"
                                }
                            ]
                        },
                        "method": "DELETE",
                        "header": [],
                        "url": {
                            "raw": "{{base_url}}/api/properties/{{property_id}}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "properties",
                                "{{property_id}}"
                            ]
                        }
                    },
                    "response": []
                }
            ]
        },
        {
            "name": "Units",
            "item": [
                {
                    "name": "Add Unit",
                    "request": {
                        "auth": {
                            "type": "bearer",
                            "bearer": [
                                {
                                    "key": "token",
                                    "value": "{{token}}",
                                    "type": "string"
                                }
                            ]
                        },
                        "method": "POST",
                        "header": [],
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"name\": \"Unit 101\",\n    \"type\": \"Apartment\",\n    \"price\": 2000,\n    \"bedrooms\": 2,\n    \"bathrooms\": 2,\n    \"size\": 1200,\n    \"status\": \"available\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        },
                        "url": {
                            "raw": "{{base_url}}/api/properties/{{property_id}}/units",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "properties",
                                "{{property_id}}",
                                "units"
                            ]
                        }
                    },
                    "response": []
                },
                {
                    "name": "List Units",
                    "request": {
                        "auth": {
                            "type": "bearer",
                            "bearer": [
                                {
                                    "key": "token",
                                    "value": "{{token}}",
                                    "type": "string"
                                }
                            ]
                        },
                        "method": "GET",
                        "header": [],
                        "url": {
                            "raw": "{{base_url}}/api/properties/{{property_id}}/units",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "properties",
                                "{{property_id}}",
                                "units"
                            ]
                        }
                    },
                    "response": []
                },
                {
                    "name": "Delete Unit",
                    "request": {
                        "auth": {
                            "type": "bearer",
                            "bearer": [
                                {
                                    "key": "token",
                                    "value": "{{token}}",
                                    "type": "string"
                                }
                            ]
                        },
                        "method": "DELETE",
                        "header": [],
                        "url": {
                            "raw": "{{base_url}}/api/units/{{unit_id}}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "api",
                                "units",
                                "{{unit_id}}"
                            ]
                        }
                    },
                    "response": []
                }
            ]
        }
    ],
    "variable": [
        {
            "key": "base_url",
            "value": "http://localhost:8000",
            "type": "string"
        },
        {
            "key": "token",
            "value": "",
            "type": "string"
        },
        {
            "key": "property_id",
            "value": "",
            "type": "string"
        },
        {
            "key": "unit_id",
            "value": "",
            "type": "string"
        }
    ]
}