API Contract Writer: Weekly for Real Estate
What is the API Contract Writer: Weekly for Real Estate prompt?
Copy the prompt below into ChatGPT, Gemini, Claude or any capable LLM, replace the bracketed variables with your own values, and run it.
Prompt
ROLE: You are a Senior API Architect and Technical Product Manager specializing in PropTech and Real Estate Data Systems. Your expertise lies in designing robust, RESTful, and scalable API contracts that bridge the gap between complex real estate legacy systems and modern frontend applications. GOAL: Your objective is to generate a comprehensive API Contract for a new weekly real estate data synchronization feature. You must transform business requirements into a technical specification that developers can immediately use to build endpoints. CONTEXT: We are developing a recurring data integration platform. You will be provided with the following variables to guide the contract design: - FEATURES TO INCLUDE: [FEATURES TO INCLUDE] - TARGET DATABASE/SCHEMA: [TARGET DATABASE/SCHEMA] - SECURITY PROTOCOLS: [SECURITY PROTOCOLS] INSTRUCTIONS: 1. DESIGN SPECIFICATION: Create a detailed API contract (OpenAPI/Swagger style) that covers the weekly data exchange for properties, listings, and agent metrics. Ensure the design follows REST best practices. 2. ENDPOINT MAPPING: Based on [FEATURES TO INCLUDE], define the necessary GET, POST, and PATCH endpoints. Include specific paths such as /v1/listings/weekly-sync or /v1/reports/performance. 3. DATA MODELING: Map the request and response bodies to the [TARGET DATABASE/SCHEMA]. Specify data types (e.g., UUIDs for property IDs, ISO 8601 for dates, decimals for pricing) and indicate which fields are required versus optional. 4. ERROR HANDLING: Define standard error responses (400, 401, 403, 404, 500) with specific error codes related to real estate data validation (e.g., INVALID_MLS_ID). 5. SECURITY IMPLEMENTATION: Detail how the [SECURITY PROTOCOLS] are applied. This includes header requirements, token expiration policies, and scopes required for the weekly sync. 6. QUERY PARAMETERS: Include filtering and pagination logic (e.g., ?zip_code=, ?limit=, ?offset=) to ensure high performance when fetching large weekly datasets. OUTPUT FORMAT: The output must be structured as follows: - OVERVIEW: A brief description of the API's purpose. - BASE URL & AUTHENTICATION: Specific security requirements based on [SECURITY PROTOCOLS]. - ENDPOINT DEFINITIONS: A list of endpoints, including Method, Path, Description, Headers, Request Body (JSON), and Success Response (JSON). - DATA DICTIONARY: A table mapping the fields to the [TARGET DATABASE/SCHEMA]. QUALITY BAR: The contract must be technically precise enough for a backend engineer to implement and a QA engineer to test. It must account for real estate edge cases like null values in historical price data or multi-unit property structures. Do not use generic field names; use industry-standard naming conventions (e.g., mls_number, list_price, status_change_timestamp).
