{
  "info": {
    "_postman_id": "8b51d02c-55c3-42e1-8bb2-9b2f679e0bf5",
    "name": "Qvoo CRM Public API Collection",
    "description": "Postman Collection for Qvoo CRM Public Integrations, Webhook Management, Schema Discovery, and Authentication endpoints.",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "item": [
    {
      "name": "Authentication & System",
      "item": [
        {
          "name": "Generate Access Token (OAuth 2.0)",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"client_id\": \"{{client_id}}\",\n  \"client_secret\": \"{{client_secret}}\",\n  \"grant_type\": \"client_credentials\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/oauth/token",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "oauth",
                "token"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Token Generated",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"access_token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnRJZCI6IjFhMmIzYyIsIndvcmtzcGFjZUlkIjoiNjA3ZjRmOGEzYzMzIiwic2NvcGVzIjpbXSwiaWF0IjoxNTE2MjM5MDIyLCJleHAiOjE1MTYyNDI2MjJ9.signature\",\n  \"refresh_token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnRJZCI6IjFhMmIzYyIsIndvcmtzcGFjZUlkIjoiNjA3ZjRmOGEzYzMzIiwiaXNSZWZyZXNoVG9rZW4iOnRydWUsImV4cCI6MTU5OTk5OTk5OX0.signature\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 3600,\n  \"scope\": \"read write\"\n}"
            }
          ]
        },
        {
          "name": "Refresh Access Token",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"refresh_token\": \"{{refresh_token}}\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/oauth/refresh",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "oauth",
                "refresh"
              ]
            }
          },
          "response": [
            {
              "name": "200 Token Refreshed",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"access_token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnRJZCI6IjFhMmIzYyIsIndvcmtzcGFjZUlkIjoiNjA3ZjRmOGEzYzMzIiwic2NvcGVzIjpbXSwiaWF0IjoxNTE2MjM5MDIyLCJleHAiOjE1MTYyNDI2MjJ9.signature\",\n  \"refresh_token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnRJZCI6IjFhMmIzYyIsIndvcmtzcGFjZUlkIjoiNjA3ZjRmOGEzYzMzIiwiaXNSZWZyZXNoVG9rZW4iOnRydWUsImV4cCI6MTU5OTk5OTk5OX0.signature\",\n  \"expires_in\": 3600\n}"
            }
          ]
        },
        {
          "name": "Revoke OAuth Credentials",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"client_id\": \"{{client_id}}\",\n  \"client_secret\": \"{{client_secret}}\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/oauth/revoke",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "oauth",
                "revoke"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Revoked",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"success\": true,\n  \"message\": \"Credentials revoked successfully\"\n}"
            }
          ]
        },
        {
          "name": "API Health Check",
          "request": {
            "method": "GET",
            "url": {
              "raw": "{{base_url}}/api/v1/health",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "health"
              ]
            }
          },
          "response": [
            {
              "name": "200 API Healthy",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"status\": \"healthy\",\n  \"version\": \"1.0.0\",\n  \"timestamp\": \"2026-06-12T08:00:00.000Z\"\n}"
            }
          ]
        }
      ]
    },
    {
      "name": "Workspace API",
      "item": [
        {
          "name": "Get Workspace Info",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Workspace Info",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"workspaceName\": \"SNB Innovations\",\n    \"timezone\": \"Asia/Kolkata\",\n    \"currency\": \"INR\",\n    \"modules\": [\"developer\", \"properties\", \"leads\"]\n  }\n}"
            }
          ]
        },
        {
          "name": "Workspace Schema Discovery",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/schema",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "schema"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Schema Discovered",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"leadFields\": [\n      {\n        \"fieldKey\": \"customField_123\",\n        \"displayName\": \"Secondary Phone\",\n        \"type\": \"text\",\n        \"required\": false,\n        \"isCustom\": true,\n        \"options\": []\n      }\n    ],\n    \"contactFields\": [\n      {\n        \"fieldKey\": \"company_name\",\n        \"displayName\": \"Company\",\n        \"type\": \"text\",\n        \"required\": false,\n        \"isCustom\": false,\n        \"options\": []\n      }\n    ],\n    \"customerFields\": [\n      {\n        \"fieldKey\": \"customField_123\",\n        \"displayName\": \"Secondary Phone\",\n        \"type\": \"text\",\n        \"required\": false,\n        \"isCustom\": true,\n        \"options\": []\n      }\n    ]\n  }\n}"
            }
          ]
        }
      ]
    },
    {
      "name": "Leads API",
      "item": [
        {
          "name": "List Leads",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads?limit=10",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads"
              ],
              "query": [
                {
                  "key": "limit",
                  "value": "10"
                }
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Paginated Leads List",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"607f4f8a3c33\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"name\": \"John Doe\",\n      \"status\": \"new\",\n      \"leadStage\": \"unassigned\",\n      \"fields\": {\n        \"mobileNumber\": \"+919876543210\",\n        \"emailId\": \"johndoe@example.com\"\n      },\n      \"tags\": [\"portal-inbound\"],\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": \"eyJ1IjoiMjAyNi0wNi0xMlQxMzowOTowM1oiLCJpIjoiNjA3ZjRmOGEzYzMzIn0\"\n}"
            }
          ]
        },
        {
          "name": "Create Lead",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"John Doe\",\n  \"status\": \"new\",\n  \"leadStage\": \"unassigned\",\n  \"fields\": {\n    \"mobileNumber\": \"+919876543210\",\n    \"emailId\": \"johndoe@example.com\"\n  }\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads"
              ]
            }
          },
          "response": [
            {
              "name": "201 Created Success",
              "status": "Created",
              "code": 201,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"607f4f8a3c33\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"John Doe\",\n    \"status\": \"new\",\n    \"leadStage\": \"unassigned\",\n    \"fields\": {\n      \"mobileNumber\": \"+919876543210\",\n      \"emailId\": \"johndoe@example.com\"\n    },\n    \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Get Lead by ID",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads/{{lead_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads",
                "{{lead_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Lead Found",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"607f4f8a3c33\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"John Doe\",\n    \"status\": \"new\",\n    \"leadStage\": \"unassigned\",\n    \"fields\": {\n      \"mobileNumber\": \"+919876543210\",\n      \"emailId\": \"johndoe@example.com\"\n    }\n  }\n}"
            }
          ]
        },
        {
          "name": "Update Lead",
          "request": {
            "method": "PUT",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"John Doe Updated\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads/{{lead_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads",
                "{{lead_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Updated",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"607f4f8a3c33\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"John Doe Updated\",\n    \"status\": \"new\",\n    \"leadStage\": \"unassigned\",\n    \"fields\": {\n      \"mobileNumber\": \"+919876543210\",\n      \"emailId\": \"johndoe@example.com\"\n    }\n  }\n}"
            }
          ]
        },
        {
          "name": "Sync Leads (Incremental)",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads/sync?limit=20",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads",
                "sync"
              ],
              "query": [
                {
                  "key": "limit",
                  "value": "20"
                }
              ]
            }
          },
          "response": [
            {
              "name": "200 Chronological Sync Success",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"607f4f8a3c33\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"name\": \"John Doe\",\n      \"status\": \"new\",\n      \"updatedAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": \"eyJ1IjoiMjAyNi0wNi0xMlQxMzowOTowM1oiLCJpIjoiNjA3ZjRmOGEzYzMzIn0\"\n}"
            }
          ]
        },
        {
          "name": "Check Duplicate Lead",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"phone\": \"+919876543210\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/leads/check-duplicate",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "leads",
                "check-duplicate"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Check Result",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"exists\": true,\n  \"leadId\": \"607f4f8a3c33\"\n}"
            }
          ]
        }
      ]
    },
    {
      "name": "Properties API",
      "item": [
        {
          "name": "List Properties",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/properties",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "properties"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Paginated Properties",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"608f5f8a3d44\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"title\": \"Luxury Villa\",\n      \"propertyType\": \"Villa\",\n      \"price\": 5000000,\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": null\n}"
            }
          ]
        },
        {
          "name": "Create Property",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"title\": \"Luxury Villa - Hilltop Vista\",\n  \"propertyType\": \"Villa\",\n  \"price\": 5000000,\n  \"currency\": \"INR\",\n  \"salesType\": [\n    \"sale\"\n  ],\n  \"subtype\": \"4BHK Villa\",\n  \"city\": \"Mumbai\",\n  \"state\": \"Maharashtra\",\n  \"country\": \"India\",\n  \"area\": \"Worli\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/properties",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "properties"
              ]
            }
          },
          "response": [
            {
              "name": "201 Created Success",
              "status": "Created",
              "code": 201,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"608f5f8a3d44\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"title\": \"Luxury Villa\",\n    \"propertyType\": \"Villa\",\n    \"price\": 5000000,\n    \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n  }\n}"
            }
          ]
        }
      ]
    },
    {
      "name": "Contacts API",
      "item": [
        {
          "name": "List Contacts",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/contacts",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "contacts"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Paginated Contacts",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"609f6f8a3e55\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"name\": \"Alice Smith\",\n      \"email\": \"alice@example.com\",\n      \"phone\": \"+919876543222\",\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": null\n}"
            }
          ]
        },
        {
          "name": "Create Contact",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"Jane Smith\",\n  \"mobileNumber\": \"+919876543211\",\n  \"fields\": {\n    \"mobileNumber\": \"+919876543211\"\n  }\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/contacts",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "contacts"
              ]
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Customers API",
      "item": [
        {
          "name": "List Customers",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/customers",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "customers"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Paginated Customers",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"60af7f8a3f66\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"name\": \"Bob Brown\",\n      \"email\": \"bob@example.com\",\n      \"phone\": \"+919876543233\",\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": null\n}"
            }
          ]
        },
        {
          "name": "Create Customer",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"leadId\": \"65b8c47f4e2cfc1df3a75111\",\n  \"name\": \"Rahul Sharma\",\n  \"assignedTo\": \"65b8c47f4e2cfc1df3a75222\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/customers",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "customers"
              ]
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Tasks API",
      "item": [
        {
          "name": "List Tasks",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/tasks",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "tasks"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Paginated Tasks",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"60bf8f8a3g77\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"title\": \"Follow up with John\",\n      \"description\": \"Call John regarding property availability\",\n      \"dueDate\": \"2026-06-15T10:00:00.000Z\",\n      \"status\": \"TODO\",\n      \"priority\": \"High\",\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ],\n  \"nextCursor\": null\n}"
            }
          ]
        },
        {
          "name": "Create Task",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"title\": \"Follow up with lead\",\n  \"assignedTo\": \"65b8c47f4e2cfc1df3a75222\",\n  \"status\": \"TODO\",\n  \"priority\": \"Medium\",\n  \"description\": \"Call client to schedule site visit.\"\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/tasks",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "tasks"
              ]
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Webhooks Management API",
      "item": [
        {
          "name": "List Webhook Subscriptions",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success List",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"60cf9f8a3h88\",\n      \"workspaceId\": \"507f1f77bcf86cd799439011\",\n      \"name\": \"My CRM Integration\",\n      \"url\": \"https://my.app/webhook\",\n      \"events\": [\"lead.created\", \"property.updated\"],\n      \"isActive\": true,\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ]\n}"
            }
          ]
        },
        {
          "name": "Subscribe to Webhook",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"My CRM Integration\",\n  \"url\": \"https://my.app/webhook\",\n  \"events\": [\"lead.created\", \"property.updated\"]\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks"
              ]
            }
          },
          "response": [
            {
              "name": "201 Created Success",
              "status": "Created",
              "code": 201,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"60cf9f8a3h88\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"My CRM Integration\",\n    \"url\": \"https://my.app/webhook\",\n    \"events\": [\n      \"lead.created\",\n      \"property.updated\"\n    ],\n    \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Get Webhook Details",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Detail",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"60cf9f8a3h88\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"My CRM Integration\",\n    \"url\": \"https://my.app/webhook\",\n    \"events\": [\"lead.created\", \"property.updated\"],\n    \"isActive\": true,\n    \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Update Webhook Subscription",
          "request": {
            "method": "PUT",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"Updated Integration Name\",\n  \"events\": [\"lead.created\", \"lead.updated\", \"task.completed\"]\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Updated",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"60cf9f8a3h88\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\",\n    \"name\": \"Updated Integration Name\",\n    \"url\": \"https://my.app/webhook\",\n    \"events\": [\"lead.created\", \"lead.updated\", \"task.completed\"],\n    \"isActive\": true,\n    \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Enable Webhook Subscription",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}/enable",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}",
                "enable"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Enabled",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"Webhook subscription activated successfully\"\n}"
            }
          ]
        },
        {
          "name": "Disable Webhook Subscription",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}/disable",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}",
                "disable"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Disabled",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"Webhook subscription deactivated successfully\"\n}"
            }
          ]
        },
        {
          "name": "Send Test Webhook Event",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}/test",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}",
                "test"
              ]
            }
          },
          "response": [
            {
              "name": "200 Test Event Sent",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"Test webhook dispatched successfully\",\n  \"payload\": {\n    \"event\": \"test.ping\",\n    \"timestamp\": \"2026-06-12T08:00:00.000Z\",\n    \"workspaceId\": \"507f1f77bcf86cd799439011\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Get Webhook Delivery Logs",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/webhooks/{{webhook_id}}/deliveries?limit=20&page=1",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "webhooks",
                "{{webhook_id}}",
                "deliveries"
              ],
              "query": [
                {
                  "key": "limit",
                  "value": "20"
                },
                {
                  "key": "page",
                  "value": "1"
                }
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Deliveries Logs",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"60df9f8a3i99\",\n      \"subscriptionId\": \"60cf9f8a3h88\",\n      \"event\": \"lead.created\",\n      \"statusCode\": 200,\n      \"responseBody\": \"{\\\"status\\\":\\\"received\\\"}\",\n      \"timestamp\": \"2026-06-12T07:30:00.000Z\"\n    }\n  ],\n  \"pagination\": {\n    \"page\": 1,\n    \"limit\": 20,\n    \"total\": 1,\n    \"pages\": 1\n  }\n}"
            }
          ]
        }
      ]
    },
    {
      "name": "Developer Portal — API Keys",
      "item": [
        {
          "name": "List API Keys",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{session_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/workspaces/{{workspace_id}}/developer/api-keys",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "workspaces",
                "{{workspace_id}}",
                "developer",
                "api-keys"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Keys List",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"60df9f8a3j99\",\n      \"name\": \"Production Integration Key\",\n      \"clientId\": \"qvoo_id_1a2b3c...\",\n      \"scopes\": [\"lead.read\", \"lead.write\", \"metadata.read\"],\n      \"status\": \"active\",\n      \"createdAt\": \"2026-06-12T07:24:24.000Z\"\n    }\n  ]\n}"
            }
          ]
        },
        {
          "name": "Create API Key",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{session_token}}",
                "type": "text"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"New Developer Integration Key\",\n  \"scopes\": [\n    \"lead.read\",\n    \"lead.write\",\n    \"metadata.read\",\n    \"team.read\"\n  ]\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/workspaces/{{workspace_id}}/developer/api-keys",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "workspaces",
                "{{workspace_id}}",
                "developer",
                "api-keys"
              ]
            }
          },
          "response": [
            {
              "name": "201 Created Success",
              "status": "Created",
              "code": 201,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"API Key created successfully.\",\n  \"data\": {\n    \"_id\": \"60df9f8a3j99\",\n    \"name\": \"New Developer Integration Key\",\n    \"clientId\": \"qvoo_id_888aaa777bbb\",\n    \"clientSecret\": \"qvoo_secret_999ccc888ddd\",\n    \"apiKey\": \"qvoo_live_555eee444fff\",\n    \"scopes\": [\"lead.read\", \"lead.write\", \"webhook.manage\"],\n    \"status\": \"active\",\n    \"createdAt\": \"2026-06-12T08:00:00.000Z\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Rotate API Key Credentials",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{session_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/workspaces/{{workspace_id}}/developer/api-keys/{{api_key_id}}/rotate",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "workspaces",
                "{{workspace_id}}",
                "developer",
                "api-keys",
                "{{api_key_id}}",
                "rotate"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Rotated",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"API credentials rotated successfully. Copy the new secret and key now.\",\n  \"data\": {\n    \"_id\": \"60df9f8a3j99\",\n    \"clientId\": \"qvoo_id_888aaa777bbb\",\n    \"clientSecret\": \"qvoo_secret_rotated111\",\n    \"apiKey\": \"qvoo_live_rotated222\"\n  }\n}"
            }
          ]
        },
        {
          "name": "Delete API Key",
          "request": {
            "method": "DELETE",
            "header": [
              {
                "key": "Authorization",
                "value": "Bearer {{session_token}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/workspaces/{{workspace_id}}/developer/api-keys/{{api_key_id}}",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "workspaces",
                "{{workspace_id}}",
                "developer",
                "api-keys",
                "{{api_key_id}}"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Deleted",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"message\": \"API Key deleted successfully\"\n}"
            }
          ]
        }
      ],
      "description": "Session-authenticated admin routes at /api/workspaces/{workspaceId}/developer. Use Authorization: Bearer {{session_token}}, not X-API-Key."
    },
    {
      "name": "Metadata API",
      "item": [
        {
          "name": "Get Lead Statuses",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/metadata/lead-statuses",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "metadata",
                "lead-statuses"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Statuses",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\"new\", \"contacted\", \"interested\", \"lost\", \"won\"]\n}"
            }
          ]
        },
        {
          "name": "Get Lead Stages",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/metadata/lead-stages",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "metadata",
                "lead-stages"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Stages",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\n    {\n      \"stageKey\": \"unassigned\",\n      \"displayName\": \"Unassigned\",\n      \"color\": \"#gray\",\n      \"position\": 1\n    }\n  ]\n}"
            }
          ]
        },
        {
          "name": "Get Lead Sources",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/metadata/sources",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "metadata",
                "sources"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Sources",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\"website\", \"referral\", \"manual\"]\n}"
            }
          ]
        },
        {
          "name": "Get Lead Tags",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/metadata/tags",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "metadata",
                "tags"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Tags",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\"hot-lead\", \"follow-up\", \"builder-direct\"]\n}"
            }
          ]
        },
        {
          "name": "Get Property Types",
          "request": {
            "method": "GET",
            "header": [
              {
                "key": "X-API-Key",
                "value": "{{api_key}}",
                "type": "text"
              }
            ],
            "url": {
              "raw": "{{base_url}}/api/v1/workspaces/{{workspace_id}}/metadata/property-types",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "workspaces",
                "{{workspace_id}}",
                "metadata",
                "property-types"
              ]
            }
          },
          "response": [
            {
              "name": "200 Success Types",
              "status": "OK",
              "code": 200,
              "_postman_previewlanguage": "json",
              "body": "{\n  \"success\": true,\n  \"data\": [\"Apartment\", \"Villa\", \"Plot\"]\n}"
            }
          ]
        }
      ]
    }
  ],
  "variable": [
    {
      "key": "base_url",
      "value": "http://localhost:5000",
      "type": "string"
    },
    {
      "key": "workspace_id",
      "value": "your_workspace_id_here",
      "type": "string"
    },
    {
      "key": "lead_id",
      "value": "your_lead_id_here",
      "type": "string"
    },
    {
      "key": "api_key",
      "value": "your_api_key_here",
      "type": "string"
    },
    {
      "key": "webhook_id",
      "value": "your_webhook_id_here",
      "type": "string"
    },
    {
      "key": "api_key_id",
      "value": "your_api_key_id_here",
      "type": "string"
    },
    {
      "key": "client_id",
      "value": "your_client_id_here",
      "type": "string"
    },
    {
      "key": "client_secret",
      "value": "your_client_secret_here",
      "type": "string"
    },
    {
      "key": "refresh_token",
      "value": "your_refresh_token_here",
      "type": "string"
    },
    {
      "key": "session_token",
      "value": "your_crm_session_jwt_here",
      "type": "string"
    }
  ]
}
