{"openapi":"3.0.3","info":{"title":"GREM Public API","version":"1.16.0","contact":{"name":"GREM API support","url":"https://docs.grem.capital/en/api/quickstart"},"x-grem-scopes":["ping","tools:valuation","tools:contentgen","tools:avatar","tools:sitegen","tools:pdf","tools:photo","tools:draft","tools:artifacts","tools:chat","tools:rent","tools:review","tools:floorplan","tools:video","tools:text","tools:flyer","webhooks","objects:write","leads:read","leads:write","media:write"],"x-grem-webhook-events":["avatar.completed","avatar.failed","content.completed","content.failed","content.partial","floorplan.completed","floorplan.failed","lead.created","lead.updated","match.lead.matched","match.lead.offer_closed","match.lead.offered","match.lead.unassigned","match.lead.updated","object.created","object.deleted","object.published","object.updated","pdf.completed","pdf.failed","photo.completed","photo.failed","review.completed","review.failed","text.completed","text.failed","valuation.completed","valuation.failed","video.completed","video.failed"],"description":"Programmatic access to GREM real-estate tools, the public object catalog, your CRM leads, and media uploads.\n\n## Quickstart\n\n**1. Base URL**\n\n    https://developers.grem.capital/api/v1\n\n**2. Authenticate** — create a key in the cabinet (Tools -> API -> Keys) and send it as a Bearer token (the `x-api-key` header also works):\n\n    Authorization: Bearer gsk_live_...\n\n**3. First call** — `GET /ping` verifies the key (scope-free, not billed):\n\n```\ncurl https://developers.grem.capital/api/v1/ping \\\n  -H \"Authorization: Bearer gsk_live_...\"\n```\n\n**4. Inspect the key** — `GET /me` returns your scopes, effective rate limit, and expiry (scope-free):\n\n```\ncurl https://developers.grem.capital/api/v1/me -H \"Authorization: Bearer gsk_live_...\"\n```\n\n## Common flows\n\n**Read the catalog** (public, any valid key): `GET /objects?city=Kyiv&kind=property`. **Create a listing** you own (scope `objects:write`): `POST /objects/property` with a JSON body; attach photos by public URL or by File id.\n\n**Upload images** (scope `media:write`) and reference the returned ids in a listing:\n\n```\n# 1) upload bytes -> get File ids\ncurl -X POST https://developers.grem.capital/api/v1/uploads \\\n  -H \"Authorization: Bearer gsk_live_...\" -F \"file=@photo.jpg\"\n# -> { \"files\": [ { \"id\": \"...\", \"url\": \"...\" } ] }\n# 2) then pass the id in a create/edit body: \"photos\": [\"<id>\"]\n```\n\n**Submit an inbound lead** into your CRM (scope `leads:write`): `POST /leads`. **List / update / archive** your leads: `GET /leads`, `PATCH /leads/:id`, `DELETE /leads/:id` (soft-archive; hidden from the list unless `?archived=true`).\n\n## Sandbox (test keys)\n\nA key starting with `gsk_test_` runs in the sandbox: tools, the express valuation and review confirmation are simulated through the same gateway path (validation, idempotency, jobs, files, webhooks) without running the work or charging anything. Jobs go pending -> running -> outcome in about 5 seconds; files are placeholders (PDF and PNG open in a viewer). Choose the outcome with the `Grem-Simulate` header: completed (default), failed, partial, insufficient_funds, service_unavailable, provider_error. `service_unavailable` on a tool listed in GET /tools/status returns exactly the production refusal for a tool reported down (503, Retry-After: 60, nothing created). Sandbox answers carry `Grem-Sandbox: true`. Reads return real data; writes to listings, leads, Swipe Match, uploads and chat are refused (403) with a test key.\n\n## Idempotency\n\nCreating resources is safe to retry: send an `Idempotency-Key` header on `POST /leads` and `POST /objects/{kind}`. A retry with the same key replays the original result instead of creating a duplicate.\n\n## Webhooks\n\nSubscribe with `POST /webhooks` (scope `webhooks`) to receive `object.*` and `lead.*` events. Each delivery is signed with an HMAC over the raw body in the `x-grem-signature` header (verify it with the signing secret returned once at creation). Failed deliveries are retried with backoff.\n\n## Errors\n\nErrors follow RFC 9457 (`application/problem+json`): a stable `title` slug, `status`, a human `detail` and, when known, a machine `code` and field-level `errors[]`. A `requestId` is attached to every response for support.\n\n## Async jobs\n\nLong tools answer `202` with a job. Every job carries a normalized `state`: pending, running, action_required (waits for you), completed, partial or failed. Poll `GET /<tool>/jobs/{jobId}` (free) or subscribe to the tool webhook.\n\n## Rate limits\n\nEvery response carries `RateLimit-Limit`, `RateLimit-Remaining`, and `RateLimit-Reset`. Over the limit returns `429` with `Retry-After` (a throttle, never a billing error).\n\n## Enum values\n\nCategory/condition fields of read responses are returned as codes. Decode them with `GET /dictionaries` (all locales, or `?lang=` for one). Write bodies take the codes listed in their own schema."},"servers":[{"url":"https://developers.grem.capital"}],"tags":[{"name":"meta","description":"Key health + introspection (ping, me)."},{"name":"objects","description":"Public catalog reads + your listings (create/edit/delete) + media uploads."},{"name":"leads","description":"Your CRM leads: read, submit, update, archive."},{"name":"valuation","description":"AI property price estimates."},{"name":"webhooks","description":"Subscribe to object.* and lead.* events (HMAC-signed)."},{"name":"dictionaries","description":"Decode enum codes to labels."},{"name":"catalog","description":"Reference data for tool inputs (voices, avatars, music, endings), tool availability and your work history."},{"name":"ping","description":"Key health check."},{"name":"content","description":"Listing content pack: texts, video, landing, PDF."},{"name":"avatar","description":"Avatar presenter videos."},{"name":"site","description":"Listing landing pages."},{"name":"pdf","description":"Listing PDF presentations."},{"name":"photo","description":"Photo enhancement."},{"name":"draft","description":"Listing drafts from documents or websites."},{"name":"floorplan","description":"Floor plan cleanup."},{"name":"video","description":"Property videos from photos."},{"name":"flyer","description":"Personal broker flyers."},{"name":"text","description":"Listing texts."},{"name":"artifacts","description":"Download generated files."},{"name":"chat","description":"AI assistant chat (sessions, messages, SSE stream)."},{"name":"match","description":"Swipe Match leads for partner brokers."}],"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"API key as a Bearer token (or the x-api-key header)."}},"schemas":{"Problem":{"type":"object","description":"RFC 9457 problem details. Branch on `status` / `title` (stable slug). The slug list may grow — treat an unknown slug as a generic error of its HTTP class.","properties":{"type":{"type":"string","description":"Link to the error description: https://docs.grem.capital/api/errors/<slug>"},"title":{"type":"string","description":"Stable slug.","enum":["invalid_key","forbidden_scope","forbidden","insufficient_funds","rate_limited","validation","business_rule","payload_too_large","range_not_satisfiable","provider_error","service_unavailable","not_found","idempotency_conflict","conflict","internal_error"]},"status":{"type":"integer"},"detail":{"type":"string","description":"Human-readable reason. Do not parse it."},"code":{"type":"string","description":"Machine code of the specific reason when known (e.g. not_enough_input, INSUFFICIENT_FUNDS)."},"errors":{"type":"array","description":"Field-level reasons (validation / business_rule).","items":{"type":"object","properties":{"field":{"type":"string"},"code":{"type":"string"},"message":{"type":"string"}}}},"requestId":{"type":"string"}}},"Job":{"type":"object","additionalProperties":true,"description":"Async job. Tool-specific result fields are returned alongside these.","required":["jobId","state"],"properties":{"jobId":{"type":"string","description":"Job id, the same field for every tool. Poll GET …/jobs/{jobId}. Older per-tool names (`id`, `_id`, `contentGenJobId`) are still returned and deprecated."},"status":{"type":"string","description":"Raw tool-specific status."},"state":{"type":"string","enum":["pending","running","action_required","completed","partial","failed"],"description":"Normalized progress — branch on this. `action_required`: the job waits for you (appraisal review: POST …/confirm). `partial`: finished with part of the artifacts."},"requestId":{"type":"string"}}},"PublicListing":{"type":"object","description":"Public read-contract object (allowlist). Fields marked (property), (rental) or (complex) appear only for that kind; \"Owner only\" fields only for your own objects. Enum values are CODES — decode them via /dictionaries. Areas are { value, unit:\"m2\" }.","additionalProperties":true,"properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["property","rental","complex"]},"name":{"type":"string","nullable":true},"slug":{"type":"string","nullable":true,"description":"(property, rental)"},"description":{"type":"string","nullable":true},"status":{"type":"string","description":"active | sold for other accounts; the owner sees the internal status."},"address":{"type":"object","additionalProperties":true,"description":"Full address incl. street and coordinates."},"constructionYear":{"type":"integer","nullable":true},"photos":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"}},"video":{"type":"array","items":{"type":"string"},"description":"External video links (YouTube etc.)."},"videoFiles":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string","nullable":true,"description":"Playback URL (videos are not watermarked)."},"mimetype":{"type":"string","nullable":true},"duration":{"type":"number","nullable":true},"poster":{"type":"string","nullable":true}}}},"processingStatus":{"type":"string","enum":["ready","processing","failed"]},"promoted":{"type":"boolean"},"nativeAreaUnit":{"type":"string","description":"Unit the owner entered areas in; areas themselves are always m²."},"createdAt":{"type":"string","nullable":true},"hasLanding":{"type":"boolean","description":"(property, rental)"},"author":{"type":"object","additionalProperties":true,"description":"Curated listing author (agent/agency)."},"contract":{"type":"object","additionalProperties":true,"description":"Present when the object has a commission contract. Guests: `{_id, status}`; signed-in non-owners also `author, sideOneReward, currency`; the owner gets the whole contract."},"updatedAt":{"type":"string","nullable":true,"description":"Owner only."},"state":{"type":"object","additionalProperties":true,"description":"Owner only: publication flags."},"number":{"nullable":true,"description":"Owner only (property, rental): internal object number."},"plans":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"},"description":"Owner only (property, rental): floor plans."},"agency":{"type":"object","description":"Owner only, agency objects only (property, rental).","properties":{"id":{"type":"string"},"assignedTo":{"type":"string","nullable":true}}},"documents":{"description":"Owner only (property, complex): legal documents."},"descriptionPresentation":{"type":"string","nullable":true,"description":"Owner only (property)."},"descriptionSocial":{"type":"string","nullable":true,"description":"Owner only (property)."},"contact":{"type":"object","additionalProperties":true,"description":"Owner only (rental)."},"rejectionReasons":{"type":"array","items":{},"description":"Owner only (rental)."},"type":{"type":"string","nullable":true,"description":"Category code — decode via /dictionaries."},"residentialType":{"type":"array","items":{"type":"string"},"description":"(property, rental) Codes — decode via /dictionaries. Always an array."},"commercialType":{"type":"array","items":{"type":"string"},"description":"(property, rental) Codes — decode via /dictionaries. Always an array."},"industrialType":{"type":"array","items":{"type":"string"},"description":"(property, rental) Codes — decode via /dictionaries. Always an array."},"marketSegment":{"type":"string","nullable":true,"enum":["primary","secondary",null],"description":"(property) New build or resale."},"rentalType":{"type":"string","nullable":true,"description":"(rental) short | long."},"floor":{"nullable":true,"description":"(property, rental) Floor."},"buildingFloor":{"nullable":true,"description":"(property) Floors in the building."},"totalFloors":{"nullable":true,"description":"(rental) Floors in the building."},"floors":{"nullable":true,"description":"(complex) Number of floors."},"rooms":{"nullable":true,"description":"(property, rental) Rooms."},"bedrooms":{"nullable":true,"description":"(rental) Bedrooms."},"unitsCount":{"nullable":true,"description":"(property) Units (hotel rooms, offices) — separate from rooms."},"numberWindows":{"nullable":true,"description":"(property) Windows."},"numberOfBathrooms":{"nullable":true,"description":"(property) Bathrooms."},"ceilingHeight":{"nullable":true,"description":"(property, complex) Ceiling height."},"sectionsNumber":{"nullable":true,"description":"(complex) Sections."},"apartmentsNumber":{"nullable":true,"description":"(complex) Apartments."},"parkingSpaces":{"nullable":true,"description":"(complex) Parking spaces."},"spaceAll":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"spaceLiving":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"spaceKitchen":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"effectiveArea":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"auxiliaryArea":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"landPlotArea":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"nativeLandAreaUnit":{"type":"string","description":"(property)"},"totalArea":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}},"description":"(rental)"},"space":{"type":"object","nullable":true,"description":"(complex) Apartment area range.","properties":{"from":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"to":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}}}},"conditions":{"nullable":true,"description":"(property)"},"condition":{"nullable":true,"description":"(rental)"},"typeBuilding":{"nullable":true,"description":"(property, complex)"},"wallMaterial":{"nullable":true,"description":"(property, complex)"},"houseClass":{"nullable":true,"description":"(complex)"},"apartType":{"type":"array","items":{"type":"string"},"description":"(complex) Codes — decode via /dictionaries. Always an array."},"apartmentStatus":{"nullable":true,"description":"(complex)"},"utilitySystem":{"type":"array","items":{"type":"string"},"description":"(property, rental) Codes — decode via /dictionaries. Always an array."},"windowView":{"nullable":true,"description":"(property) a code; (rental) an array of codes."},"heating":{"nullable":true,"description":"(property, complex)"},"interiorFeatures":{"nullable":true,"description":"(property)"},"internalFeature":{"nullable":true,"description":"(rental)"},"designatedUse":{"nullable":true,"description":"(property)"},"equipment":{"nullable":true,"description":"(property)"},"amenities":{"type":"array","items":{"type":"string"},"description":"(rental) Codes — decode via /dictionaries. Always an array."},"onsiteAmenities":{"type":"array","items":{"type":"string"},"description":"(rental) Codes — decode via /dictionaries. Always an array."},"furnitureList":{"nullable":true,"description":"(rental)"},"landmark":{"nullable":true,"description":"(property, rental)"},"balcony":{"type":"boolean","description":"(property, rental)"},"parking":{"type":"boolean","description":"(property)"},"furniture":{"type":"boolean","description":"(rental, complex)"},"investmentRequired":{"type":"boolean","description":"(property)"},"safety":{"type":"object","additionalProperties":true,"description":"(property, rental)"},"installmentTerms":{"type":"string","nullable":true,"description":"(complex)"},"territoryDescription":{"type":"string","nullable":true,"description":"(complex)"},"parkingDescription":{"type":"string","nullable":true,"description":"(complex)"},"infrastructureDescription":{"type":"string","nullable":true,"description":"(complex)"},"logo":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"},"description":"(complex)"},"withChildren":{"type":"boolean","description":"(rental)"},"withPets":{"nullable":true,"description":"(rental)"},"minRentTime":{"type":"object","nullable":true,"description":"(rental)","properties":{"value":{"type":"integer"},"unit":{"type":"string","enum":["day","month"]}}},"checkIn":{"type":"object","description":"(rental) Hours of the day, e.g. 15 = 15:00.","properties":{"from":{"type":"integer","nullable":true},"to":{"type":"integer","nullable":true}}},"checkOut":{"type":"object","description":"(rental) Hours of the day, e.g. 15 = 15:00.","properties":{"from":{"type":"integer","nullable":true},"to":{"type":"integer","nullable":true}}},"price":{"nullable":true,"description":"(property, rental) a number in `currency` — for rentals per `pricePeriod`. (complex) a range object `{ from, to, currency }`.","oneOf":[{"type":"number"},{"type":"object","properties":{"from":{"type":"number","nullable":true},"to":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true}}}]},"currency":{"type":"string","nullable":true,"description":"(property, rental) For complexes the currency is inside `price`."},"pricePeriod":{"type":"string","enum":["day","month"],"description":"(rental) day for short-term, month otherwise."},"dayPrice":{"type":"number","nullable":true,"description":"(rental)"},"deposit":{"type":"number","nullable":true,"description":"(rental)"},"checkInPay":{"type":"boolean","description":"(rental)"},"onlinePay":{"type":"boolean","description":"(rental)"},"bankTransfer":{"type":"boolean","description":"(rental)"},"reportingDocuments":{"type":"boolean","description":"(rental)"},"monthRentalRate":{"type":"number","nullable":true,"description":"(property)"},"annualIncome":{"type":"number","nullable":true,"description":"(property)"},"annualYield":{"type":"number","nullable":true,"description":"(property)"},"paybackPeriod":{"type":"number","nullable":true,"description":"(property)"},"apartmentPlans":{"type":"array","description":"(complex)","items":{"type":"object","properties":{"id":{"type":"string"},"apartType":{"nullable":true,"description":"Code — decode via /dictionaries."},"area":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2"]}}},"price":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true,"description":"Inherited from the complex."},"description":{"type":"string","nullable":true},"photos":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"}}}}},"progress":{"type":"array","description":"(complex) Construction progress.","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string","nullable":true},"date":{"type":"integer","nullable":true,"description":"Year."},"description":{"type":"string","nullable":true},"photos":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"}}}}},"requestId":{"type":"string"}}},"PublicPhoto":{"type":"object","properties":{"id":{"type":"string"},"isMain":{"type":"boolean"},"mimetype":{"type":"string","nullable":true},"ready":{"type":"boolean","description":"False until the watermarked variants finish processing."},"variants":{"type":"array","items":{"type":"object","additionalProperties":true}}}},"Paginate":{"type":"object","properties":{"currentPage":{"type":"integer"},"totalPages":{"type":"integer"},"totalCount":{"type":"integer"}}},"ObjectWrite":{"type":"object","description":"Write-contract body for creating/editing an object. Enum fields take the codes listed in this schema. Areas accept a bare m2 number or { value, unit:\"m2\"|\"ft2\" }. `photos` items are public https URLs (server-fetched) or existing File ids. A URL that fails to download is reported in the response `warnings[]` (unless `strictPhotos:true`, which 422s instead). `publish:false` keeps a draft; publishing requires the per-kind minimum photo count. Unknown fields are ignored. Kind-specific fields (rental: rent rate/term; complex: price {from,to}, space {from,to}, apartmentPlans/progress) are additive.","required":["name","type","address","price"],"additionalProperties":true,"properties":{"publish":{"type":"boolean","default":false,"description":"false = draft (not public); true = publish live."},"strictPhotos":{"type":"boolean","default":false,"description":"If true, a photo URL that fails to download makes the whole request fail (422) instead of being dropped with a warning."},"name":{"type":"string"},"type":{"type":"string","description":"Top category code (e.g. Residential/Commercial) — decode via /dictionaries."},"residentialType":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"Enum code(s)."},"description":{"type":"string"},"address":{"type":"object","required":["country","city"],"properties":{"country":{"type":"string"},"city":{"type":"string"},"district":{"type":"string"},"street":{"type":"string"},"streetNumber":{"type":"string"},"postalCode":{"type":"string"},"location":{"type":"object","properties":{"latitude":{"type":"number"},"longitude":{"type":"number"}}}}},"price":{"type":"number"},"currency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"],"default":"USD"},"constructionYear":{"type":"integer","minimum":1700,"maximum":2100,"nullable":true},"spaceAll":{"oneOf":[{"type":"number"},{"type":"object","properties":{"value":{"type":"number"},"unit":{"type":"string","enum":["m2","ft2"]}}}]},"rooms":{"type":"integer","minimum":0},"photos":{"type":"array","maxItems":50,"items":{"type":"string"},"description":"Public https URL to fetch, or an existing File id. Up to 50, as in the cabinet (PhotoLimits)."},"video":{"type":"array","maxItems":10,"items":{"type":"string","format":"uri"}}}},"ObjectWriteProperty":{"type":"object","properties":{"publish":{"default":false,"type":"boolean"},"name":{"type":"string"},"type":{"type":"string","enum":["Residential","Commercial","Industrial","Land plot"]},"residentialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"marketSegment":{"type":"string","enum":["primary","secondary"]},"commercialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"industrialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"description":{"type":"string","maxLength":5000},"address":{"type":"object","properties":{"country":{"type":"string"},"city":{"type":"string"},"district":{"type":"string"},"region":{"type":"string"},"street":{"type":"string"},"streetNumber":{"type":"string"},"postalCode":{"type":"string"},"location":{"type":"object","properties":{"latitude":{"type":"number"},"longitude":{"type":"number"}},"additionalProperties":true},"place_id":{"type":"string"}},"required":["country","city"],"additionalProperties":true},"price":{"type":"number","minimum":0},"currency":{"default":"USD","type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"constructionYear":{"type":"integer","minimum":1700,"maximum":2100,"nullable":true},"spaceAll":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"spaceLiving":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"spaceKitchen":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"effectiveArea":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"auxiliaryArea":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"landPlotArea":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"rooms":{"type":"integer","minimum":0},"unitsCount":{"type":"integer","minimum":0},"floor":{"oneOf":[{"type":"string"},{"type":"number"}]},"buildingFloor":{"type":"integer","minimum":0},"ceilingHeight":{"type":"number","minimum":0},"numberWindows":{"type":"integer","minimum":0},"numberOfBathrooms":{"type":"integer","minimum":0},"conditions":{"type":"string"},"typeBuilding":{"type":"string"},"wallMaterial":{"type":"string"},"utilitySystem":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"windowView":{"type":"string"},"heating":{"type":"string"},"interiorFeatures":{"type":"string"},"designatedUse":{"type":"string"},"equipment":{"type":"string"},"landmark":{"type":"string"},"balcony":{"type":"boolean"},"parking":{"type":"boolean"},"investmentRequired":{"type":"boolean"},"safety":{"type":"object","properties":{"shelterNearby":{"type":"boolean"},"powerBackup":{"type":"boolean"},"autonomousHeating":{"type":"boolean"},"waterReserve":{"type":"boolean"},"starlink":{"type":"boolean"},"gasAvailable":{"type":"boolean"},"internetAvailable":{"type":"boolean"},"elevatorWorks":{"type":"boolean"}},"additionalProperties":true},"bedrooms":{"type":"integer","minimum":0},"condition":{"type":"string","enum":["needsRenovation","partialRenovation","renovated","designer","shellCore","newFromDeveloper"]},"amenities":{"type":"array","items":{"type":"string","enum":["furniture","kitchenFurniture","fridge","stove","oven","dishwasher","washer","dryer","tv","ac","floorHeating","boiler","waterHeater","internet","bathtub","shower","balcony","terrace","fireplace","walkInCloset","alarm","smartHome","generator","ups","inverter"]},"maxItems":25},"balconies":{"type":"integer","minimum":0},"buildingType":{"type":"string","enum":["newBuilding","secondary","stalinka","khrushchevka","brezhnevka","czech","gostinka","prerevolutionary","townhouseRow","detached","other"]},"wallMaterialType":{"type":"string","enum":["brick","monolith","panel","block","wood","mixed","other"]},"constructionTech":{"type":"string","enum":["monolithFrame","brick","panel","block","wood","sip","other"]},"kitchenType":{"type":"string","enum":["separate","studio","kitchenLiving","none"]},"buildingAmenities":{"type":"array","items":{"type":"string","enum":["elevator","freightElevator","parkingUnderground","parkingGround","concierge","security","cctv","gatedArea","playground","sportsGround","gym","pool","shelter","generatorBuilding","solarPanels","ramp","bikeStorage","storageRoom"]},"maxItems":18},"accessibility":{"type":"object","properties":{"ramp":{"type":"boolean"},"groundLevelEntrance":{"type":"boolean"},"wideDoors":{"type":"boolean"},"disabledParking":{"type":"boolean"},"wheelchairElevator":{"type":"boolean"}},"additionalProperties":true},"programs":{"type":"array","items":{"type":"string","enum":["eOselya","eVidnovlennya","mortgageEligible","installment"]},"maxItems":4},"commission":{"type":"object","properties":{"payer":{"type":"string","enum":["buyer","seller","split","none"]},"type":{"type":"string","enum":["percent","fixed"]},"value":{"type":"number","minimum":0}},"additionalProperties":true},"tour":{"type":"object","properties":{"kind":{"type":"string","enum":["matterport","kuula","youtube360","other"]},"url":{"type":"string","format":"uri"}},"additionalProperties":true},"complexId":{"type":"string","pattern":"^[0-9a-fA-F]{24}$"},"complexLinkSource":{"type":"string","enum":["auto","manual"]},"monthRentalRate":{"type":"number","minimum":0},"annualIncome":{"type":"number","minimum":0},"annualYield":{"type":"number","minimum":0},"paybackPeriod":{"type":"number","minimum":0},"propertyTax":{"type":"number","minimum":0},"insuranceCost":{"type":"number","minimum":0},"managementFee":{"type":"number","minimum":0},"repairsReserve":{"type":"number","minimum":0},"photos":{"type":"array","items":{"type":"string"},"maxItems":50},"video":{"type":"array","items":{"type":"string","format":"uri"},"maxItems":10}},"required":["name","type","address","price"],"additionalProperties":true,"description":"Unknown fields are ignored."},"ObjectWriteRental":{"type":"object","properties":{"publish":{"default":false,"type":"boolean"},"name":{"type":"string"},"type":{"type":"string","enum":["Residential","Commercial","Industrial"]},"rentalType":{"default":"long","type":"string","enum":["long","short"]},"residentialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"commercialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"industrialType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"description":{"type":"string","maxLength":5000},"address":{"type":"object","properties":{"country":{"type":"string"},"city":{"type":"string"},"district":{"type":"string"},"region":{"type":"string"},"street":{"type":"string"},"streetNumber":{"type":"string"},"postalCode":{"type":"string"},"location":{"type":"object","properties":{"latitude":{"type":"number"},"longitude":{"type":"number"}},"additionalProperties":true},"place_id":{"type":"string"}},"required":["country","city"],"additionalProperties":true},"price":{"type":"number","minimum":0},"dayPrice":{"type":"number","minimum":0},"deposit":{"type":"number","minimum":0},"currency":{"default":"USD","type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"constructionYear":{"type":"integer","minimum":1700,"maximum":2100,"nullable":true},"totalArea":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"rooms":{"type":"integer","minimum":0},"bedrooms":{"type":"integer","minimum":0},"floor":{"oneOf":[{"type":"string"},{"type":"number"}]},"totalFloors":{"oneOf":[{"type":"string"},{"type":"number"}]},"minRentTime":{"type":"integer","minimum":1,"maximum":100000},"withChildren":{"type":"boolean"},"withPets":{"type":"string","enum":["yes","no","with someone"]},"checkIn":{"type":"object","properties":{"from":{"type":"number"},"to":{"type":"number"}},"additionalProperties":true},"checkOut":{"type":"object","properties":{"from":{"type":"number"},"to":{"type":"number"}},"additionalProperties":true},"balcony":{"type":"boolean"},"furniture":{"type":"boolean"},"furnitureList":{"type":"string"},"condition":{"type":"string"},"windowView":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"utilitySystem":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"amenities":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"onsiteAmenities":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"internalFeature":{"type":"string"},"landmark":{"type":"string"},"safety":{"type":"object","properties":{"shelterNearby":{"type":"boolean"},"powerBackup":{"type":"boolean"},"autonomousHeating":{"type":"boolean"},"waterReserve":{"type":"boolean"},"starlink":{"type":"boolean"},"gasAvailable":{"type":"boolean"},"internetAvailable":{"type":"boolean"},"elevatorWorks":{"type":"boolean"}},"additionalProperties":true},"bathrooms":{"type":"integer","minimum":0},"conditionType":{"type":"string","enum":["needsRenovation","partialRenovation","renovated","designer","shellCore","newFromDeveloper"]},"balconies":{"type":"integer","minimum":0},"buildingType":{"type":"string","enum":["newBuilding","secondary","stalinka","khrushchevka","brezhnevka","czech","gostinka","prerevolutionary","townhouseRow","detached","other"]},"wallMaterialType":{"type":"string","enum":["brick","monolith","panel","block","wood","mixed","other"]},"constructionTech":{"type":"string","enum":["monolithFrame","brick","panel","block","wood","sip","other"]},"kitchenType":{"type":"string","enum":["separate","studio","kitchenLiving","none"]},"buildingAmenities":{"type":"array","items":{"type":"string","enum":["elevator","freightElevator","parkingUnderground","parkingGround","concierge","security","cctv","gatedArea","playground","sportsGround","gym","pool","shelter","generatorBuilding","solarPanels","ramp","bikeStorage","storageRoom"]},"maxItems":18},"accessibility":{"type":"object","properties":{"ramp":{"type":"boolean"},"groundLevelEntrance":{"type":"boolean"},"wideDoors":{"type":"boolean"},"disabledParking":{"type":"boolean"},"wheelchairElevator":{"type":"boolean"}},"additionalProperties":true},"programs":{"type":"array","items":{"type":"string","enum":["eOselya","eVidnovlennya","mortgageEligible","installment"]},"maxItems":4},"commission":{"type":"object","properties":{"payer":{"type":"string","enum":["buyer","seller","split","none"]},"type":{"type":"string","enum":["percent","fixed"]},"value":{"type":"number","minimum":0}},"additionalProperties":true},"tour":{"type":"object","properties":{"kind":{"type":"string","enum":["matterport","kuula","youtube360","other"]},"url":{"type":"string","format":"uri"}},"additionalProperties":true},"complexId":{"type":"string","pattern":"^[0-9a-fA-F]{24}$"},"complexLinkSource":{"type":"string","enum":["auto","manual"]},"minTermMonths":{"type":"integer","minimum":0},"availableFrom":{"type":"string","format":"date-time","nullable":true},"checkInPay":{"type":"boolean"},"onlinePay":{"type":"boolean"},"bankTransfer":{"type":"boolean"},"reportingDocuments":{"type":"boolean"},"utilitiesIncluded":{"type":"boolean"},"utilitiesCost":{"type":"number","minimum":0},"photos":{"type":"array","items":{"type":"string"},"maxItems":50},"video":{"type":"array","items":{"type":"string","format":"uri"},"maxItems":10}},"required":["name","type","address","price"],"additionalProperties":true,"description":"Unknown fields are ignored."},"ObjectWriteComplex":{"type":"object","properties":{"publish":{"default":false,"type":"boolean"},"name":{"type":"string"},"description":{"type":"string","maxLength":3000},"descriptionPresentation":{"type":"string","maxLength":3000},"descriptionSocial":{"type":"string","maxLength":3000},"address":{"type":"object","properties":{"country":{"type":"string"},"city":{"type":"string"},"district":{"type":"string"},"region":{"type":"string"},"street":{"type":"string"},"streetNumber":{"type":"string"},"postalCode":{"type":"string"},"location":{"type":"object","properties":{"latitude":{"type":"number"},"longitude":{"type":"number"}},"additionalProperties":true},"place_id":{"type":"string"}},"required":["country","city"],"additionalProperties":true},"price":{"type":"object","properties":{"from":{"type":"number","minimum":0},"to":{"type":"number","minimum":0},"currency":{"default":"USD","type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]}},"additionalProperties":true},"space":{"type":"object","properties":{"from":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"to":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]}},"additionalProperties":true},"constructionYear":{"type":"integer","minimum":1700,"maximum":2100,"nullable":true},"typeBuilding":{"type":"string","enum":["apartment-house","apart-hotel","townhouse","cottage","villa","hotel"]},"apartType":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"houseClass":{"type":"string"},"apartmentStatus":{"type":"string"},"wallMaterial":{"type":"string"},"heating":{"type":"string"},"ceilingHeight":{"type":"number","minimum":0},"sectionsNumber":{"type":"integer","minimum":0},"floors":{"type":"integer","minimum":0},"apartmentsNumber":{"type":"integer","minimum":0},"parkingSpaces":{"type":"integer","minimum":0},"furniture":{"type":"boolean"},"installmentTerms":{"type":"string","maxLength":3000},"installment":{"type":"object","properties":{"downPaymentPct":{"type":"number","minimum":0,"maximum":100},"termMonths":{"type":"number","minimum":0},"interestRate":{"type":"number","minimum":0}},"additionalProperties":true},"territoryDescription":{"type":"string","maxLength":200},"parkingDescription":{"type":"string","maxLength":200},"infrastructureDescription":{"type":"string","maxLength":200},"stage":{"type":"string","enum":["planning","excavation","construction","finishing","commissioned","delivered"]},"completionQuarter":{"type":"string","pattern":"^\\d{4}-Q[1-4]$"},"queues":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","maxLength":200},"stage":{"type":"string","enum":["planning","excavation","construction","finishing","commissioned","delivered"]},"completionQuarter":{"type":"string","pattern":"^\\d{4}-Q[1-4]$"}},"additionalProperties":true},"maxItems":50},"class":{"type":"string","enum":["economy","comfort","comfortPlus","business","premium","elite"]},"infrastructure":{"type":"array","items":{"type":"string","enum":["kindergarten","school","shops","pharmacy","gym","pool","park","playground","parkingUnderground","parkingMultilevel","shelter","generator","concierge","coworking","lounge","rooftop"]},"maxItems":16},"photos":{"type":"array","items":{"type":"string"},"maxItems":60},"video":{"type":"array","items":{"type":"string","format":"uri"},"maxItems":10},"apartmentPlans":{"type":"array","items":{"type":"object","properties":{"apartType":{"type":"string","enum":["1","2","3","4","5","penthouse","studio"]},"area":{"oneOf":[{"type":"number","minimum":0},{"type":"object","properties":{"value":{"type":"number","minimum":0},"unit":{"default":"m2","type":"string","enum":["m2","ft2"]}},"required":["value"],"additionalProperties":true}]},"price":{"type":"number","minimum":0},"description":{"type":"string","maxLength":600},"photos":{"type":"array","items":{"type":"string"},"maxItems":20}},"additionalProperties":true},"maxItems":50},"progress":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","maxLength":200},"date":{"type":"integer","minimum":1700,"maximum":4102444800000},"description":{"type":"string","maxLength":600},"photos":{"type":"array","items":{"type":"string"},"maxItems":20}},"additionalProperties":true},"maxItems":50}},"required":["name","address"],"additionalProperties":true,"description":"Unknown fields are ignored."},"MatchEventFirstContact":{"type":"object","required":["event"],"properties":{"event":{"type":"string","enum":["FIRST_CONTACT"]},"channel":{"type":"string","enum":["phone","messenger"],"default":"phone"}}},"MatchEventReservation":{"type":"object","required":["event","amount","currency","date"],"properties":{"event":{"type":"string","enum":["RESERVATION"]},"amount":{"type":"number","minimum":0,"exclusiveMinimum":true},"currency":{"type":"string","minLength":3,"maxLength":3,"x-case-insensitive":true,"description":"ISO 4217 (case does not matter: it is upper-cased)"},"date":{"type":"string","format":"date-time"},"documentFileId":{"type":"string","nullable":true,"description":"File id from POST /uploads"}}},"MatchEventReason":{"type":"object","required":["event","reasonCode"],"properties":{"event":{"type":"string","enum":["STAGE_ROLLBACK","LEAD_LOST"]},"reasonCode":{"type":"string","enum":["client_withdrew","seller_withdrew","financing_failed","documents","client_refused","client_unreachable","bought_elsewhere","not_target","other"],"description":"STAGE_ROLLBACK: client_withdrew, seller_withdrew, financing_failed, documents, other. LEAD_LOST: client_refused, client_unreachable, bought_elsewhere, not_target, other."},"text":{"type":"string","maxLength":500,"nullable":true}}},"MatchEventDealClosed":{"type":"object","required":["event","objectId","amount","currency","date","documentFileId"],"properties":{"event":{"type":"string","enum":["DEAL_CLOSED"]},"objectId":{"type":"string"},"amount":{"type":"number","minimum":0,"exclusiveMinimum":true},"currency":{"type":"string","minLength":3,"maxLength":3,"x-case-insensitive":true},"date":{"type":"string","format":"date-time"},"documentFileId":{"type":"string","description":"The deal document, uploaded via POST /uploads"},"commissionReceived":{"type":"number","nullable":true},"commissionCurrency":{"type":"string","nullable":true}}},"PublicLead":{"type":"object","description":"A lead in the read-contract shape. Returned only to the lead owner (the acting user is its sender or recipient). Enum values are codes. The heavier `statusHistory`/`documents` appear only on the item endpoint with `?expand=`.","additionalProperties":true,"properties":{"id":{"type":"string"},"status":{"type":"string","enum":["new","in progress","processing","agreement","closed","not target","failed"]},"type":{"type":"string","enum":["contract","transfer","user","buy","rent","viewing","sell"]},"priority":{"type":"string","nullable":true,"enum":["hot","warm","cold",null]},"source":{"type":"string","nullable":true},"tags":{"type":"array","items":{"type":"string"}},"isArchived":{"type":"boolean"},"agency":{"type":"object","description":"Agency leads only (personal leads omit it): the agency and whether the lead sits in its shared pool.","properties":{"id":{"type":"string"},"inPool":{"type":"boolean"}}},"createdAt":{"type":"string","nullable":true},"updatedAt":{"type":"string","nullable":true},"lastActivityAt":{"type":"string","nullable":true},"customer":{"type":"object","properties":{"name":{"type":"string","nullable":true},"country":{"type":"string","nullable":true},"messenger":{"type":"string","nullable":true},"contact":{"type":"object","properties":{"phone":{"type":"string"},"email":{"type":"string"},"messengerHandle":{"type":"string"},"profileUrl":{"type":"string"}}}}},"budget":{"type":"object","nullable":true,"properties":{"value":{"type":"number"},"currency":{"type":"string"}}},"intent":{"type":"object","additionalProperties":true,"description":"Buyer intent: targetCity, targetAreas, leadIntent, propertyKind, dealKind."},"comments":{"type":"object","properties":{"customer":{"type":"string","nullable":true},"broker":{"type":"string","nullable":true}}},"object":{"type":"object","nullable":true,"description":"List: { id, kind } only. Item: a slim card { id, kind, name, address, photos }."},"requestId":{"type":"string"}}},"WebhookEndpoint":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string","format":"uri"},"events":{"type":"array","items":{"type":"string"}},"status":{"type":"string","x-extensible-enum":["active","disabled"]},"failureCount":{"type":"integer","description":"Consecutive failed deliveries; reset on success or re-enable."},"lastDeliveryAt":{"type":"string","nullable":true}}},"WebhookDelivery":{"type":"object","properties":{"_id":{"type":"string","description":"Delivery id — pass it to …/deliveries/{deliveryId}/resend."},"eventType":{"type":"string"},"attempt":{"type":"integer"},"status":{"type":"string","x-extensible-enum":["pending","delivered","failed"]},"statusCode":{"type":"integer","nullable":true},"latencyMs":{"type":"integer","nullable":true},"error":{"type":"string","nullable":true,"description":"Why the delivery failed (connection error, timeout, non-2xx)."},"responseSnippet":{"type":"string","nullable":true},"payload":{"type":"object","additionalProperties":true,"description":"The event exactly as sent."},"isTest":{"type":"boolean"},"nextRetryAt":{"type":"string","nullable":true},"createdAt":{"type":"string"}}},"ChatSession":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"mode":{"type":"string"},"status":{"type":"string"},"title":{"type":"string","nullable":true},"projectId":{"type":"string","nullable":true},"isArchived":{"type":"boolean"},"lastMessagePreview":{"type":"string","nullable":true},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"messageCount":{"type":"integer"}}},"ArtifactSummary":{"type":"object","additionalProperties":true,"properties":{"artifactId":{"type":"string","description":"Use in the artifact download URL."},"kind":{"type":"string","description":"e.g. text.description, video.mp4."},"mime":{"type":"string"},"size":{"type":"integer"},"etag":{"type":"string"},"taskType":{"type":"string"},"isPrimary":{"type":"boolean"},"variant":{"type":"string"},"downloadFileName":{"type":"string"},"createdAt":{"type":"string"}}},"LeadWrite":{"type":"object","description":"Submit an inbound lead. It lands in YOUR CRM (recipient = your account — never another user; `pool: true` hands it to the platform pool instead) and is marked source=\"api\". Attach it to a listing with objectId. At least one contact channel is required. Unknown fields are dropped (publicLeadWriteDto: Joi stripUnknown).","required":["customer"],"properties":{"customer":{"type":"object","required":["name","contact"],"properties":{"name":{"type":"string","minLength":1,"maxLength":200},"country":{"type":"string"},"messenger":{"type":"string","enum":["telegram","viber","whatsapp","facebook","instagram"]},"contact":{"type":"object","description":"At least one of phone/email/messengerHandle/profileUrl.","properties":{"phone":{"type":"string","maxLength":64},"email":{"type":"string"},"messengerHandle":{"type":"string"},"profileUrl":{"type":"string","format":"uri"}}}}},"budget":{"type":"object","properties":{"value":{"type":"number"},"currency":{"type":"string","enum":["USD","EUR","UAH","AZN","GBP","AED","CNY","TRY","PLN","KZT"]}}},"type":{"type":"string","enum":["buy","rent"],"default":"buy"},"objectId":{"type":"string","description":"Attach the inquiry to a listing (24-hex id)."},"intent":{"type":"object","properties":{"targetCity":{"type":"string"},"targetAreas":{"type":"array","items":{"type":"string","maxLength":200},"maxItems":20},"leadIntent":{"type":"string","enum":["buyer","renter","seller","lessor","unclear"]},"propertyKind":{"type":"string"},"dealKind":{"type":"string"}}},"comments":{"type":"string","maxLength":3000},"priority":{"type":"string","enum":["hot","warm","cold"]},"tags":{"type":"array","items":{"type":"string","maxLength":40},"maxItems":10},"consent":{"type":"boolean","description":"Set true when the buyer consented (GDPR)."},"pool":{"type":"boolean","default":false,"description":"true = hand the lead to the platform pool instead of your own CRM (the agency pool is not reachable this way). Whether and to whom it is distributed is decided by the platform pool rules (lead source, consent, verified phone)."}}},"LeadPatch":{"type":"object","description":"Update a lead you own. At least one field.","minProperties":1,"properties":{"status":{"type":"string","enum":["new","in progress","processing","agreement","closed","not target","failed"],"description":"The cabinet rules apply: a lead with a listing is closed through finalization, a lead waiting for commission collection keeps its status (409 → 422 with the reason in `code`)."},"tags":{"type":"array","items":{"type":"string","maxLength":40},"maxItems":10},"priority":{"type":"string","enum":["hot","warm","cold"]},"brokerComments":{"type":"string","maxLength":3000}}}}},"security":[{"apiKey":[]}],"paths":{"/api/v1/ping":{"get":{"summary":"Ping (key health check)","description":"Verifies your API key and returns your subject id. Does not require any scope and is not billed.","tags":["ping"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Key is valid","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"subjectId":{"type":"string"},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getPing","x-grem-billing":"free"}},"/api/v1/valuation/express":{"post":{"summary":"Express property valuation","description":"Synchronous price estimate: point value and range. Commercial property and complexes are refused (422). `degraded: true` marks a rough fallback that is not charged.\n\n**Key scope:** `tools:valuation`.","x-grem-billing":"api_call+sku:valuation.express","tags":["valuation"],"security":[{"apiKey":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"A repeat with the same key returns the finished valuation without a second charge, also after a timeout."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Give an address (addressText, or country + city, or lat + lon) and the area: totalArea or areaM2 (for land also landPlotArea) is required (400 otherwise). Commercial property and complexes are refused (422).","properties":{"propertyCategory":{"type":"string","enum":["apartment","house","land","commercial"],"default":"apartment","description":"`commercial` is refused with 422 `commercial_unsupported`."},"totalArea":{"type":"number","description":"m². totalArea or areaM2 is required (land: or landPlotArea)."},"areaM2":{"type":"number","description":"Same as totalArea."},"landPlotArea":{"type":"number","description":"m². Counts as the area only for propertyCategory land."},"addressText":{"type":"string","description":"Free-form address."},"country":{"type":"string"},"city":{"type":"string"},"postalCode":{"type":"string"},"lat":{"type":"number"},"lon":{"type":"number"},"rooms":{"type":"number"},"yearBuilt":{"type":"number"},"floor":{"type":"number"},"floorsTotal":{"type":"number"},"houseLevels":{"type":"number"},"heatingType":{"type":"string"},"currency":{"type":"string"},"price":{"type":"number","description":"Asking price, if any."},"language":{"type":"string"},"targetId":{"type":"string","description":"Listing id: repeat estimates of the same listing are cached for 7 days."}}},"example":{"propertyCategory":"apartment","addressText":"Torstraße 12, Berlin","totalArea":64,"rooms":2,"currency":"EUR"}}}},"responses":{"200":{"description":"Estimate","content":{"application/json":{"schema":{"type":"object","properties":{"estimate":{"type":"object","properties":{"pricePoint":{"type":"number","nullable":true},"rangeLow":{"type":"number","nullable":true},"rangeHigh":{"type":"number","nullable":true},"confidence":{"type":"string","nullable":true,"x-extensible-enum":["low","medium","high"],"description":"Level derived from confidenceScore: high ≥ 0.7, medium ≥ 0.45, otherwise low."},"confidenceScore":{"type":"number","nullable":true,"minimum":0,"maximum":1,"description":"How well the market data supports the estimate, 0..1."},"currency":{"type":"string","nullable":true},"analogs":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","nullable":true},"address":{"type":"string","nullable":true},"area":{"type":"number","nullable":true,"description":"m²"},"rooms":{"nullable":true},"floor":{"nullable":true},"yearBuilt":{"nullable":true},"condition":{"nullable":true},"originalPrice":{"type":"number","nullable":true,"description":"Asking price of the listing, in the response currency."},"pricePerM2":{"type":"number","nullable":true},"adjustedPrice":{"type":"number","nullable":true,"description":"Price per m² after adjustments to your property."},"adjustments":{"description":"Adjustments applied (floor, condition, age, …)."},"weight":{"type":"string","nullable":true,"description":"How much the listing counts: high | medium | low."},"provenance":{"type":"string","nullable":true,"x-extensible-enum":["listing","model_estimate"],"description":"`listing`: a real listing; `model_estimate`: a benchmark without a listing behind it."},"source":{"type":"string","nullable":true,"description":"Portal the listing comes from."},"sourceUrl":{"type":"string","nullable":true,"description":"Link to the listing."},"url":{"type":"string","nullable":true,"description":"Link to the listing (older reports)."},"distance":{"nullable":true},"listingDate":{"nullable":true}}},"description":"Comparable listings found for the estimate, prices in `currency`. Only real ones: benchmarks without a listing are not returned."}}},"degraded":{"type":"boolean","description":"Present and true for a rough fallback estimate; not charged."},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postValuationExpress","x-required-scope":"tools:valuation"}},"/api/v1/valuation/report":{"post":{"summary":"Full valuation report","description":"Market valuation with comparables and a PDF report. Residential (apartment, house) and land; commercial property and complexes are refused (422). The body depends on `propertyCategory`: apartment needs apartmentType/houseType/floor/storeys/balcony/elevator/condition, house needs landPlotArea/houseLevels/condition, land needs totalArea or landPlotArea. Send only the fields of your category: fields that do not apply (e.g. `houseLevels` for an apartment, `parking` for a house) are refused with 400. The finished job carries the report; download the PDF via GET /artifacts/v1/ai/appraisal/reports/{id}/pdf. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the valuation.completed / valuation.failed webhook.\n\n**Key scope:** `tools:valuation`.","tags":["valuation"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku:valuation.create","x-grem-webhook-events":["valuation.completed","valuation.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["propertyCategory","address"],"additionalProperties":true,"properties":{"propertyCategory":{"type":"string","enum":["apartment","house","land"]},"address":{"type":"object","required":["country","city","street"],"additionalProperties":true,"properties":{"country":{"type":"string"},"city":{"type":"string"},"street":{"type":"string","minLength":0,"description":"May be empty."},"streetNumber":{"type":"string"},"location":{"type":"object","properties":{"lat":{"type":"number"},"lng":{"type":"number"}}}}},"currency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"language":{"type":"string","enum":["eng","rus","ukr","deu","spa","aze","arb","fra","zho","tur"]},"totalArea":{"type":"number","description":"m². Required for apartment and house."},"landPlotArea":{"type":"number","description":"m². Required for house; land needs this or totalArea."},"rooms":{"type":"number","description":"Apartment, house."},"condition":{"type":"string","description":"Condition code (GET /dictionaries). Required for apartment and house."},"apartmentType":{"type":"string","enum":["Residential","Commercial","Industrial","Land plot","Complex"],"description":"Apartment: required."},"houseType":{"type":"string","description":"Apartment: building type code, required."},"floor":{"type":"number","description":"Apartment: required."},"storeys":{"type":"number","description":"Apartment: floors in the building, required."},"balcony":{"type":"boolean","description":"Apartment: required."},"elevator":{"type":"boolean","description":"Apartment: required."},"houseLevels":{"type":"integer","minimum":1,"maximum":10,"description":"House: required."},"yearConstruction":{"type":"number","description":"Apartment, house."},"livingArea":{"type":"number","description":"Apartment only."},"kitchenArea":{"type":"number","description":"Apartment only."},"bathrooms":{"type":"number","description":"Apartment only."},"ceilingHeight":{"type":"number","description":"Apartment only."},"wallMaterial":{"type":"string","description":"Apartment, house."},"heatingType":{"type":"string","description":"House: central, autonomous, boiler, fireplace, mixed, gas, electric, heat_pump, solid_fuel, underfloor or none."},"furnished":{"type":"boolean","description":"Apartment, house."},"parking":{"type":"boolean","description":"Apartment only."},"zoning":{"type":"string","description":"Land only."},"utilities":{"type":"object","description":"House, land.","properties":{"gas":{"type":"boolean"},"water":{"type":"boolean"},"sewage":{"type":"boolean"},"electricity":{"type":"boolean"}}},"price":{"type":"number","description":"Asking price, if any — compared with the estimate."},"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"comments":{"type":"string"}}},"example":{"propertyCategory":"apartment","address":{"country":"Germany","city":"Berlin","street":"Torstraße","streetNumber":"12"},"currency":"EUR","language":"eng","apartmentType":"Residential","houseType":"panel","totalArea":64,"rooms":2,"floor":3,"storeys":5,"balcony":true,"elevator":false,"condition":"good"}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"id":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"status":{"type":"string","example":"processing"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postValuationReport","x-required-scope":"tools:valuation"}},"/api/v1/valuation/report/jobs/{id}":{"get":{"summary":"Job status: Full valuation report","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:valuation`.","tags":["valuation"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"propertyCategory":{"type":"string"},"criteria":{"type":"object","additionalProperties":true,"description":"The input as the report used it."},"currency":{"type":"string","description":"Currency of every figure."},"errorMessage":{"type":"string","nullable":true},"metrics":{"type":"object","additionalProperties":true,"description":"Valuation figures.","properties":{"potPrice":{"type":"number","nullable":true,"description":"Market value of the property."},"priceRangeLow":{"type":"number","nullable":true},"priceRangeHigh":{"type":"number","nullable":true},"avgPrice":{"type":"number","nullable":true,"description":"Price per m²."},"analogCount":{"type":"integer","nullable":true},"growth":{"type":"number","nullable":true,"description":"Price growth, %."}}},"priceMethod":{"type":"string","x-extensible-enum":["comps","comps_reconciled","market_stats","income","cost","reconciled","llm"]},"confidence":{"type":"string","x-extensible-enum":["high","medium","low","very_low"]},"estimateType":{"type":"string","x-extensible-enum":["point","range","no_data","point_estimate","narrow_range","wide_range"]},"marketCheck":{"type":"object","additionalProperties":true,"description":"Cross-check with market statistics: verdict agree | neutral | disagree | unknown, divergencePct."},"incomeCheck":{"type":"object","additionalProperties":true,"description":"Income approach cross-check (when applicable)."},"residualCheck":{"type":"object","additionalProperties":true,"description":"Land residual cross-check (when applicable)."},"rentalEstimate":{"type":"object","additionalProperties":true,"nullable":true},"analogs":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","nullable":true},"address":{"type":"string","nullable":true},"area":{"type":"number","nullable":true,"description":"m²"},"rooms":{"nullable":true},"floor":{"nullable":true},"yearBuilt":{"nullable":true},"condition":{"nullable":true},"originalPrice":{"type":"number","nullable":true,"description":"Asking price of the listing, in the response currency."},"pricePerM2":{"type":"number","nullable":true},"adjustedPrice":{"type":"number","nullable":true,"description":"Price per m² after adjustments to your property."},"adjustments":{"description":"Adjustments applied (floor, condition, age, …)."},"weight":{"type":"string","nullable":true,"description":"How much the listing counts: high | medium | low."},"provenance":{"type":"string","nullable":true,"x-extensible-enum":["listing","model_estimate"],"description":"`listing`: a real listing; `model_estimate`: a benchmark without a listing behind it."},"source":{"type":"string","nullable":true,"description":"Portal the listing comes from."},"sourceUrl":{"type":"string","nullable":true,"description":"Link to the listing."},"url":{"type":"string","nullable":true,"description":"Link to the listing (older reports)."},"distance":{"nullable":true},"listingDate":{"nullable":true}}},"description":"Comparable listings the value rests on (the same table as in the PDF)."},"dataQuality":{"type":"object","additionalProperties":true,"description":"searchLevel, sourcesDiversity, analogsUsed, uncertaintyFactors."},"dataQualityNote":{"type":"string","nullable":true},"justification":{"description":"Why the value is what it is (text / structured)."},"recommendations":{"description":"Pricing and selling recommendations."},"pdfMeta":{"type":"object","additionalProperties":true,"description":"Report PDF metadata; download via the artifact path."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getValuationReportJobsById","x-required-scope":"tools:valuation"}},"/api/v1/content/generate":{"post":{"summary":"Listing content pack","description":"From property facts and photos: descriptions, social posts, a narrated video, a landing page and a PDF — in one job. At least 4 photos are required: pass their public URLs in `form.media.photos` (upload files first with POST /uploads). Set `form.objectId` to build the pack for an existing listing. `user` may be omitted: the account of the API key is used. Artifacts: GET /artifacts/v1/ai/assistant/announcement/jobs/{jobId}/artifacts/{artifactId}/download. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the content.completed / content.failed webhook.\n\n**Key scope:** `tools:contentgen`.","tags":["content"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","x-grem-webhook-events":["content.completed","content.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["form"],"properties":{"language":{"type":"string","enum":["eng","rus","ukr","deu","spa","aze","arb","fra","zho","tur"]},"form":{"type":"object","required":["media"],"additionalProperties":true,"properties":{"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"objectType":{"type":"string","enum":["property","rental","complex"]},"propertyCategory":{"type":"string","description":"e.g. apartment, house, penthouse, land, warehouse."},"dealType":{"type":"string","enum":["sale","rent"]},"title":{"type":"string"},"description":{"type":"string","description":"Your own words about the property — used as facts."},"customDirection":{"type":"string","maxLength":500,"description":"Wishes for tone and emphasis."},"totalArea":{"type":"number","description":"m²."},"rooms":{"type":"number"},"floor":{"type":"number"},"buildingFloors":{"type":"number"},"landPlotArea":{"type":"number","description":"m² (houses)."},"price":{"type":"number"},"priceCurrency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"addressCountry":{"type":"string"},"addressCity":{"type":"string"},"street":{"type":"string"},"streetNumber":{"type":"string"},"language":{"type":"string","enum":["eng","rus","ukr","deu","spa","aze","arb","fra","zho","tur"]},"voiceId":{"type":"string","description":"From GET /voices."},"enableSubtitles":{"type":"boolean","default":true},"showPhone":{"type":"boolean","default":false},"contactPhone":{"type":"string"},"media":{"type":"object","required":["photos"],"properties":{"photos":{"type":"array","minItems":4,"maxItems":20,"x-lenient":true,"items":{"oneOf":[{"type":"string","format":"uri"},{"type":"object","properties":{"url":{"type":"string","format":"uri"}}}]}}}},"options":{"type":"object","properties":{"music":{"type":"object","properties":{"enabled":{"type":"boolean","default":true},"trackId":{"type":"string","description":"From GET /video/music."},"volume":{"type":"number","minimum":0,"maximum":100}}},"endCard":{"type":"object","properties":{"enabled":{"type":"boolean"},"style":{"type":"string","enum":["photo","solid","split"]}}}}}}},"user":{"type":"object","description":"Optional; ignored for API keys (the key account is used).","additionalProperties":true}}},"example":{"form":{"language":"eng","propertyCategory":"apartment","dealType":"sale","title":"Bright 2-room flat near the park","totalArea":64,"rooms":2,"price":320000,"priceCurrency":"EUR","addressCountry":"Germany","addressCity":"Berlin","media":{"photos":["https://example.com/1.jpg","https://example.com/2.jpg","https://example.com/3.jpg","https://example.com/4.jpg"]}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"contentGenJobId":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"contentGenEntityId":{"type":"string","nullable":true,"description":"Generation entity the pack belongs to."},"propertyId":{"type":"string","nullable":true,"description":"Draft listing created for the pack."},"entityType":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postContentGenerate","x-required-scope":"tools:contentgen"}},"/api/v1/content/generate/jobs/{id}":{"get":{"summary":"Job status: Listing content pack","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:contentgen`.","tags":["content"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"artifacts":{"type":"array","items":{"type":"string"},"description":"Artifact ids; download each via /artifacts/v1/ai/assistant/announcement/jobs/{jobId}/artifacts/{artifactId}/download."},"artifactsSummary":{"type":"array","items":{"$ref":"#/components/schemas/ArtifactSummary"}},"bundle":{"type":"object","additionalProperties":true,"nullable":true,"description":"Landing page and PDF of the pack, when built."},"progress":{"description":"Progress of the generation while it runs."},"masterProfile":{"type":"object","additionalProperties":true,"nullable":true,"description":"The story outline the texts and narration were built on."},"error":{"type":"string","nullable":true,"description":"Set when the job failed (a generic text)."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getContentGenerateJobsById","x-required-scope":"tools:contentgen"}},"/api/v1/avatar/video":{"post":{"summary":"Avatar presenter video","description":"A talking presenter video about one of your listings. Get `avatarId` from GET /avatar/avatars (status ready) and `voiceId` from GET /voices. Script: 100 characters minimum; the maximum is bounded by video length. Download via GET /artifacts/v1/ai/assistant/avatar/jobs/{jobId}/artifacts/{artifactId}/download. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the avatar.completed / avatar.failed webhook.\n\n**Key scope:** `tools:avatar`.","tags":["avatar"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","x-grem-webhook-events":["avatar.completed","avatar.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["avatarId","objectId","scriptText"],"properties":{"avatarId":{"type":"string"},"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"scriptText":{"type":"string","minLength":100,"maxLength":1200,"description":"Text the presenter says: 100 to 1200 characters (AssistantAvatar.controller scriptMaxChars)."},"voiceId":{"type":"string","description":"From GET /voices."},"language":{"type":"string"},"background":{"type":"object","properties":{"type":{"type":"string","enum":["color","photo","slideshow"],"default":"color"},"color":{"type":"string","description":"#RRGGBB"},"photoUrl":{"type":"string"}}},"dimension":{"type":"object","required":["width","height"],"description":"Both or neither.","properties":{"width":{"type":"integer","minimum":100,"maximum":4096},"height":{"type":"integer","minimum":100,"maximum":4096}}},"enableSubtitles":{"type":"boolean"}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"jobId":{"type":"string"},"videoId":{"type":"string"},"deduped":{"type":"boolean","description":"True when an identical request was already running and its job is returned."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postAvatarVideo","x-required-scope":"tools:avatar"}},"/api/v1/avatar/video/jobs/{id}":{"get":{"summary":"Job status: Avatar presenter video","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:avatar`.","tags":["avatar"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"description":"The avatar job.","properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"jobType":{"type":"string"},"avatarId":{"type":"string"},"avatarName":{"type":"string","nullable":true},"objectType":{"type":"string","nullable":true},"scriptText":{"type":"string"},"language":{"type":"string"},"videoUrl":{"type":"string","nullable":true,"description":"When done: a /files/… path, also downloadable via GET /artifacts/files/…."},"thumbnailUrl":{"type":"string","nullable":true},"artifacts":{"type":"array","items":{"type":"string"},"description":"Artifact ids; download the video via /artifacts/v1/ai/assistant/avatar/jobs/{jobId}/artifacts/{artifactId}/download."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getAvatarVideoJobsById","x-required-scope":"tools:avatar"}},"/api/v1/site/create":{"post":{"summary":"Listing landing page","description":"A landing page with a shareable link for a listing — yours or any public one. Synchronous.\n\n**Key scope:** `tools:sitegen`.","tags":["site"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku:siteGenerator.create","parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["objectId"],"properties":{"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"siteName":{"type":"string","description":"Link name in your list."},"language":{"type":"string","enum":["ENG","RUS","UKR","DEU","SPA","AZE","ARB","FRA","ZHO","TUR"],"default":"ENG","x-lenient":true,"x-case-insensitive":true,"description":"Also eng/en in any case; an unknown value becomes ENG."},"coverPhotoId":{"type":"string","description":"Photo id of the listing to show first."},"brandColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"showPhone":{"type":"boolean","default":false,"description":"Show your phone on the page."}}},"example":{"objectId":"6650c1f2a1b2c3d4e5f60718","siteName":"Torstraße 12","language":"ENG"}}}},"responses":{"200":{"description":"Result","content":{"application/json":{"schema":{"type":"object","properties":{"landingId":{"type":"string"},"baseUrl":{"type":"string"},"link":{"type":"object","additionalProperties":true,"description":"The created link (name, language, short code, url)."},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postSiteCreate","x-required-scope":"tools:sitegen"}},"/api/v1/pdf/create":{"post":{"summary":"Listing PDF presentation","description":"A branded PDF for a listing — yours or any public one. When finished, the job has `link`; download via GET /artifacts/v1/ai/pdf-generator/files/{id}/download. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the pdf.completed / pdf.failed webhook.\n\n**Key scope:** `tools:pdf`.","tags":["pdf"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","x-grem-webhook-events":["pdf.completed","pdf.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["pdfName","objectId"],"properties":{"pdfName":{"type":"string","maxLength":200},"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"language":{"type":"string","enum":["ENG","RUS","UKR","DEU","SPA","AZE","ARB","FRA","ZHO","TUR"],"default":"ENG"},"descriptionType":{"type":"string","enum":["presentation","description","social"],"default":"presentation"},"currency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"priceForPdf":{"type":"number","minimum":0,"description":"Override the price printed in the document."},"coverPhotoId":{"type":"string"},"descriptionOverride":{"type":"string","maxLength":3000,"description":"Text for this document only."},"brandColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"}}},"example":{"pdfName":"Torstraße 12 — presentation","objectId":"6650c1f2a1b2c3d4e5f60718","language":"ENG"}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"id":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"name":{"type":"string","description":"The `pdfName` you sent."},"status":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postPdfCreate","x-required-scope":"tools:pdf"}},"/api/v1/pdf/create/jobs/{id}":{"get":{"summary":"Job status: Listing PDF presentation","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:pdf`.","tags":["pdf"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"errorMessage":{"type":"string","nullable":true},"landingId":{"type":"string","nullable":true},"views":{"type":"integer","description":"Opens of the shared PDF link."},"isPublic":{"type":"boolean"},"link":{"type":"string","nullable":true},"pageCount":{"type":"integer","nullable":true},"sizeBytes":{"type":"integer","nullable":true},"coverImageUrl":{"type":"string","nullable":true}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getPdfCreateJobsById","x-required-scope":"tools:pdf"}},"/api/v1/photo/enhance":{"post":{"summary":"Photo enhancement","description":"One photo: `enhance` (light, color, sharpness), `cleanup` (remove objects — describe them in `prompt`; optionally a `mask` part where white marks the area) or `staging` (furnish an empty room). Options go in the `data` part as JSON. Download via GET /artifacts/v1/ai/photo-enhancement/jobs/{jobId}/download/{variant}. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the photo.completed / photo.failed webhook.\n\n**Key scope:** `tools:photo`.","tags":["photo"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","x-grem-webhook-events":["photo.completed","photo.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["image","data"],"properties":{"image":{"type":"string","format":"binary","description":"The photo."},"mask":{"type":"string","format":"binary","description":"cleanup only: PNG mask, white = area to change."},"data":{"type":"string","description":"JSON: { mode, prompt?, intensity?, roomType?, furnitureStyle?, autoMask?, seed? }","x-json-schema":{"type":"object","additionalProperties":false,"x-also-accepts":["provider","removalEditor"],"properties":{"mode":{"type":"string","enum":["cleanup","enhance","staging"],"default":"cleanup"},"prompt":{"type":"string","nullable":true,"maxLength":500,"description":"Required for cleanup and staging (3 to 500 characters); optional for enhance."},"negativePrompt":{"type":"string","nullable":true,"maxLength":300,"description":"What to avoid."},"intensity":{"type":"string","enum":["light","medium","strong"],"default":"medium"},"roomType":{"type":"string","enum":["living","bedroom","kitchen","bathroom","dining","office","outdoor"]},"furnitureStyle":{"type":"string","enum":["modern","scandinavian","industrial","luxury","minimalist","coastal"]},"autoMask":{"type":"boolean","default":false},"seed":{"type":"integer","minimum":0,"maximum":2147483647},"objectId":{"type":"string","nullable":true,"description":"Your listing the photo belongs to."},"objectType":{"type":"string","enum":["property","complex"]},"strength":{"type":"number","minimum":0,"maximum":1,"deprecated":true,"description":"Accepted for old clients, not used; see intensity."}}}}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"jobId":{"type":"string"},"estimatedTime":{"type":"integer","description":"Expected processing time, ms."},"sku":{"type":"string","description":"Price item this call is charged as."},"priceMinor":{"type":"integer","nullable":true,"description":"What this call is charged, in minor units (cents); absent when it is covered by the plan quota."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postPhotoEnhance","x-required-scope":"tools:photo"}},"/api/v1/photo/enhance/jobs/{id}":{"get":{"summary":"Job status: Photo enhancement","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:photo`.","tags":["photo"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"results":{"type":"array","description":"Result variants. Download one via /artifacts/v1/ai/photo-enhancement/jobs/{jobId}/download/{variant}.","items":{"type":"object","properties":{"variant":{"type":"integer"},"url":{"type":"string"},"width":{"type":"integer"},"height":{"type":"integer"},"selected":{"type":"boolean"}}}},"metadata":{"type":"object","properties":{"processingTime":{"type":"integer","description":"ms"},"error":{"type":"string","nullable":true,"description":"Set when processing failed (a generic text)."}}},"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getPhotoEnhanceJobsById","x-required-scope":"tools:photo"}},"/api/v1/draft/extract":{"post":{"summary":"Listing draft from documents or a website","description":"Reads brochures, price lists or a developer website and returns a ready listing draft (fields + images). Send documents as file parts, or only `data` with `site`. Options go in the `data` part as JSON. Limit: 2 drafts a day per account; the next one is refused with 403 until the next day.\n\n**Key scope:** `tools:draft`.","tags":["draft"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call","parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["data"],"properties":{"data":{"type":"string","description":"JSON: { type?: \"property\" | \"complex\", site?: \"https://…\" }. Without `type` (or with another value) a listing for sale is extracted.","x-json-schema":{"type":"object","properties":{"type":{"type":"string","enum":["property","complex"],"default":"property","x-lenient":true},"site":{"type":"string","format":"uri"}}}},"files":{"type":"array","items":{"type":"string","format":"binary"},"description":"PDF, DOC(X), images. Any field names."}}}}}},"responses":{"200":{"description":"Result","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The created draft listing as stored: raw model fields (internal ones removed), not the read contract. Read it in the public shape with GET /objects/{kind}/{_id}.","properties":{"_id":{"type":"string","description":"Id of the new draft object."},"name":{"type":"string","nullable":true},"type":{"type":"string","nullable":true,"description":"Property category (property drafts)."},"status":{"type":"string","description":"`draft` for property drafts."},"address":{"type":"object","additionalProperties":true},"price":{"description":"Property: a number; complex: `{ from, to, currency }`."},"currency":{"type":"string","nullable":true},"photos":{"type":"array","items":{},"description":"Property drafts: photo files."},"complexPhotos":{"type":"array","items":{},"description":"Complex drafts: photo files."},"apartmentPlans":{"type":"array","items":{"type":"object","additionalProperties":true}},"annualIncome":{},"annualYield":{},"apartType":{},"apartmentStatus":{},"apartmentsNumber":{},"auxiliaryArea":{},"balcony":{},"buildingFloor":{},"ceilingHeight":{},"commercialType":{},"conditions":{},"dateConstruction":{},"description":{},"descriptionPresentation":{},"descriptionSocial":{},"designatedUse":{},"documents":{},"effectiveArea":{},"equipment":{},"floor":{},"furniture":{},"heating":{},"houseClass":{},"industrialType":{},"infrastructureDescription":{},"installmentTerms":{},"interiorFeatures":{},"investmentRequired":{},"landPlotArea":{},"landmark":{},"logo":{},"marketSegment":{},"monthRentalRate":{},"nativeAreaUnit":{},"nativeLandAreaUnit":{},"number":{},"numberOfBathrooms":{},"numberWindows":{},"parking":{},"parkingDescription":{},"parkingSpaces":{},"paybackPeriod":{},"plans":{},"progress":{},"residentialType":{},"rooms":{},"safety":{},"sectionsNumber":{},"slug":{},"space":{},"spaceAll":{},"spaceKitchen":{},"spaceLiving":{},"territoryDescription":{},"typeBuilding":{},"unitsCount":{},"utilitySystem":{},"video":{},"videoFiles":{},"wallMaterial":{},"windowView":{},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postDraftExtract","x-required-scope":"tools:draft"}},"/api/v1/valuation/rent":{"post":{"summary":"Rent estimate","description":"Market rent for a property (long-term or daily). Synchronous. Download the PDF via GET /artifacts/v1/ai/appraisal/rent/{id}/pdf.\n\n**Key scope:** `tools:rent`.","tags":["valuation"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"properties":{"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Estimate one of your listings instead of describing the property."},"propertyCategory":{"type":"string"},"country":{"type":"string"},"city":{"type":"string","description":"Required unless objectId is given."},"district":{"type":"string"},"street":{"type":"string"},"totalArea":{"type":"number","description":"m². Required unless objectId is given."},"rooms":{"type":"number"},"currency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"]},"rentTerm":{"type":"string","enum":["long","short"],"description":"long = monthly rent (default), short = daily rent. Two different markets."},"monthRentalRate":{"type":"number","description":"Your monthly rate — the response says how it compares to the market."},"declaredDayRate":{"type":"number","description":"Your nightly rate (daily rent)."},"occupancyPct":{"type":"number","minimum":10,"maximum":100,"description":"Daily rent: expected occupancy, %."},"furnished":{"oneOf":[{"type":"boolean"},{"type":"string","enum":["furnished","unfurnished"]}]},"condition":{"type":"string"},"floor":{"type":"number"}}},"example":{"propertyCategory":"apartment","country":"Germany","city":"Berlin","totalArea":50,"rooms":2,"currency":"EUR"}}}},"responses":{"200":{"description":"Result","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string","description":"Estimate id (PDF: /artifacts/v1/ai/appraisal/rent/{id}/pdf)."},"currency":{"type":"string"},"rent":{"type":"object","additionalProperties":true,"properties":{"monthlyRent":{"type":"number","nullable":true},"low":{"type":"number","nullable":true},"high":{"type":"number","nullable":true},"annualRent":{"type":"number","nullable":true},"pricePerM2":{"type":"number","nullable":true},"grossYieldPct":{"type":"number","nullable":true,"description":"Gross yield vs the property price, %, when the price is known."},"confidence":{"type":"string","nullable":true},"basedOn":{"description":"How many comparable listings the estimate rests on."},"termBasis":{"type":"string","enum":["long","short"]}}},"declared":{"type":"object","additionalProperties":true,"nullable":true,"description":"Your own figures compared with the estimate, when you sent them."},"found":{"description":"How many listings the search found."},"comps":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string"},"area":{"type":"number","nullable":true},"rooms":{"type":"number","nullable":true},"stars":{"type":"number","nullable":true,"description":"Hotels."},"term":{"type":"string","nullable":true,"description":"long | short"},"furnished":{"type":"boolean","nullable":true},"monthlyRent":{"type":"number","nullable":true},"monthlyRentUsd":{"type":"number","nullable":true},"dayRent":{"type":"number","nullable":true},"dayRentUsd":{"type":"number","nullable":true},"effectiveMonthly":{"type":"number","nullable":true,"description":"Monthly equivalent used in the estimate (daily rentals: with occupancy)."},"effectiveMonthlyUsd":{"type":"number","nullable":true},"status":{"type":"string","description":"What the estimate did with the listing (used, outlier, …)."},"usedInEstimate":{"type":"boolean"},"originalCurrency":{"type":"string","nullable":true},"url":{"type":"string"},"source":{"type":"string"}}},"description":"Every listing considered, with its fate in the estimate (`status`, `usedInEstimate`)."},"input":{"type":"object","additionalProperties":true,"description":"The input as the estimate understood it."},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postValuationRent","x-required-scope":"tools:rent"}},"/api/v1/valuation/review":{"post":{"summary":"Check an appraisal report","description":"Upload someone else’s valuation report (PDF, DOCX, DOC, RTF; up to 40 MB). The document is read synchronously and the job comes back in state `action_required` with `extracted` facts — check them and call POST /valuation/review/jobs/{id}/confirm. A document that is not a real-estate valuation comes back `failed` (status `rejected`). Download the result via GET /artifacts/v1/ai/appraisal/reviews/{id}/report.pdf (or .docx). Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the review.completed / review.failed webhook.\n\n**Key scope:** `tools:review`.","tags":["valuation"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku","x-grem-webhook-events":["review.completed","review.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary","description":"The report document. Field `file` (or `document`; otherwise the first file part is taken)."},"language":{"type":"string","enum":["eng","rus","ukr","deu","spa","aze","arb","fra","zho","tur"],"default":"rus"},"currency":{"type":"string","enum":["UAH","USD","EUR","AZN","GBP","AED","CNY","TRY"],"default":"USD"}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"status":{"type":"string","enum":["need_confirm","rejected"]},"extracted":{"type":"object","additionalProperties":true,"description":"Facts read from the document (subject, value, method…)."},"sourceName":{"type":"string","nullable":true,"description":"File name you uploaded."},"language":{"type":"string"},"currency":{"type":"string"},"rejectReason":{"type":"string","nullable":true,"x-extensible-enum":["not_a_report","scan_no_text_layer","too_large","unsupported_format","unreadable","not_checkable","payment_required"]},"error":{"type":"string","nullable":true},"parsed":{"type":"object","additionalProperties":true,"description":"pages, chars, emptyPages, hasTextLayer, ocrUsed, photoPages."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postValuationReview","x-required-scope":"tools:review"}},"/api/v1/valuation/review/jobs/{id}":{"get":{"summary":"Job status: Check an appraisal report","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:review`.","tags":["valuation"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"description":"The review. Texts of findings are keys with params (localized in the PDF/DOCX).","properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"extracted":{"type":"object","additionalProperties":true,"nullable":true},"extractedConfirmedAt":{"type":"string","nullable":true},"ourRange":{"type":"object","nullable":true,"properties":{"low":{"type":"number"},"high":{"type":"number"},"analogCount":{"type":"integer"},"confidence":{"type":"string"}}},"verdict":{"type":"object","nullable":true,"additionalProperties":true,"properties":{"code":{"type":"string","nullable":true,"x-extensible-enum":["consistent","minor_issues","material_issues","not_verifiable"]},"valueInRange":{"type":"boolean","description":"The reported value lies inside our independent range."},"deviationPct":{"type":"number","description":"Distance to the nearest edge of our range, %; 0 = inside."},"marketCheckSkipped":{"type":"boolean"},"marketCheckSkipReason":{"type":"string","nullable":true,"x-extensible-enum":["no_estimate","low_confidence","few_analogs","no_reported_value"]},"marketCheckAnalogCount":{"type":"integer"},"counts":{"type":"object","properties":{"critical":{"type":"integer"},"major":{"type":"integer"},"minor":{"type":"integer"}}}}},"findings":{"type":"array","items":{"type":"object","additionalProperties":true,"properties":{"code":{"type":"string","description":"Finding code, e.g. A01_NO_VALUATION_DATE."},"axis":{"type":"string","x-extensible-enum":["completeness","arithmetic","market"]},"severity":{"type":"string","x-extensible-enum":["critical","major","minor"]},"detailKey":{"type":"string","description":"Text key; the PDF/DOCX show it localized."},"detailParams":{"type":"object","additionalProperties":true},"expected":{"type":"string"},"actual":{"type":"string"},"evidence":{"type":"object","properties":{"page":{"type":"integer"},"quote":{"type":"string"}}}}}},"conclusions":{"type":"array","items":{"type":"object","additionalProperties":true}},"coverage":{"type":"array","items":{"type":"object","additionalProperties":true},"description":"What was checked and what could not be, with reasons."},"comparablesVerification":{"type":"array","items":{"type":"object","additionalProperties":true}},"photoCheck":{"type":"object","additionalProperties":true,"nullable":true},"summary":{"type":"string","nullable":true},"locale":{"type":"string","description":"Language of the localized texts in this response."},"finishedAt":{"type":"string","nullable":true},"sourceName":{"type":"string","nullable":true,"description":"File name you uploaded."},"language":{"type":"string"},"currency":{"type":"string"},"rejectReason":{"type":"string","nullable":true,"x-extensible-enum":["not_a_report","scan_no_text_layer","too_large","unsupported_format","unreadable","not_checkable","payment_required"]},"error":{"type":"string","nullable":true},"parsed":{"type":"object","additionalProperties":true,"description":"pages, chars, emptyPages, hasTextLayer, ocrUsed, photoPages."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getValuationReviewJobsById","x-required-scope":"tools:review"}},"/api/v1/floorplan/create":{"post":{"summary":"Floor plan cleanup","description":"A photo or scan of a floor plan becomes a clean plan with room labels and areas. Processed synchronously: the 202 response already carries the final state (`completed`, or `failed` when the image is not a floor plan). Report: GET /artifacts/v1/ai/floor-plan/jobs/{id}/report.pdf. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the floorplan.completed / floorplan.failed webhook.\n\n**Key scope:** `tools:floorplan`.","tags":["floorplan"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku:floorPlan.create","x-grem-webhook-events":["floorplan.completed","floorplan.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary","description":"Image of the plan (JPEG, PNG, WebP, HEIC; up to 20 MB). Field `file` or `image`."},"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Attach the result to a listing."},"objectType":{"type":"string","enum":["property","rental","complex"]}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"status":{"type":"string","enum":["done","review","rejected","failed"]},"rooms":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"area":{"type":"number","nullable":true},"stable":{"type":"boolean","description":"The label was read the same in every pass."},"placement":{"type":"object","additionalProperties":true,"description":"Where the label sits on the cleaned plan."}}},"description":"Rooms read from the plan."},"totalArea":{"type":"number","nullable":true,"description":"m², when areas are labelled on the plan."},"cleanedFileId":{"type":"object","additionalProperties":true,"nullable":true,"description":"The cleaned plan image (file with variants)."},"sourceFileId":{"type":"object","additionalProperties":true,"nullable":true,"description":"The plan you uploaded."},"objectType":{"type":"string","nullable":true},"error":{"type":"string","nullable":true},"finishedAt":{"type":"string","nullable":true},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postFloorplanCreate","x-required-scope":"tools:floorplan"}},"/api/v1/floorplan/create/jobs/{id}":{"get":{"summary":"Job status: Floor plan cleanup","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:floorplan`.","tags":["floorplan"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"_id":{"type":"string","deprecated":true,"description":"Same as `jobId`; kept for clients built before 1.6.0."},"status":{"type":"string","enum":["done","review","rejected","failed"]},"rooms":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"area":{"type":"number","nullable":true},"stable":{"type":"boolean","description":"The label was read the same in every pass."},"placement":{"type":"object","additionalProperties":true,"description":"Where the label sits on the cleaned plan."}}},"description":"Rooms read from the plan."},"totalArea":{"type":"number","nullable":true,"description":"m², when areas are labelled on the plan."},"cleanedFileId":{"type":"object","additionalProperties":true,"nullable":true,"description":"The cleaned plan image (file with variants)."},"sourceFileId":{"type":"object","additionalProperties":true,"nullable":true,"description":"The plan you uploaded."},"objectType":{"type":"string","nullable":true},"error":{"type":"string","nullable":true},"finishedAt":{"type":"string","nullable":true},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getFloorplanCreateJobsById","x-required-scope":"tools:floorplan"}},"/api/v1/video/create":{"post":{"summary":"Property video from photos","description":"A short narrated video from your photos (`photos` file parts, 1–8) or from a listing (`objectId`, its photos are used). Parameters are separate form fields — not a JSON `data` part. `prompt` is required without objectId. Artifacts: as for content/generate. Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the video.completed / video.failed webhook.\n\n**Key scope:** `tools:video`.","tags":["video"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku:video.render.base|video.render.long","x-grem-webhook-events":["video.completed","video.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"photos":{"type":"array","items":{"type":"string","format":"binary"},"maxItems":8,"x-lenient":true,"description":"Field name `photos` (repeat the part per file). Photos past the 8th are not used."},"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"prompt":{"type":"string","maxLength":500,"x-lenient":true,"description":"Required without objectId (refusal `prompt_required`). Longer text is cut to 500."},"title":{"type":"string","maxLength":120,"x-lenient":true,"description":"Longer text is cut to 120."},"length":{"type":"string","enum":["short","long"],"default":"short","x-lenient":true,"description":"Another value is treated as short. `long` needs at least 4 photos (refusal `long_needs_more_photos`)."},"aspect":{"type":"string","enum":["9:16","1:1","16:9"],"x-lenient":true,"description":"Another value is treated as the default."},"language":{"type":"string","enum":["en","ru","ua","de","es","az","ar","fr","zh","tr"],"x-lenient":true,"description":"Another value is treated as en."},"narration":{"type":"boolean","default":true,"x-lenient":true},"voiceId":{"type":"string","description":"From GET /voices."},"enableSubtitles":{"type":"boolean","default":false,"x-lenient":true},"musicEnabled":{"type":"boolean","x-lenient":true},"musicTrackId":{"type":"string","description":"From GET /video/music."},"musicVolume":{"type":"number","minimum":0,"maximum":100,"x-lenient":true,"description":"Values outside 0-100 are cut into range."},"music":{"type":"string","format":"binary","description":"Your own music file instead of a track."},"endCardEnabled":{"type":"boolean","x-lenient":true},"endCardStyle":{"type":"string","enum":["photo","solid","split"],"x-lenient":true,"description":"Another value is ignored."},"ctaMode":{"type":"string","enum":["auto","manual"],"x-lenient":true,"x-case-insensitive":true,"description":"`auto` (default): the closing phrase is picked for the listing. `manual`: use `ctaIntent` or `ctaText`."},"ctaIntent":{"type":"string","x-lenient":true,"x-case-insensitive":true,"enum":["BOOK_VIEWING","REQUEST_DETAILS","REQUEST_PURCHASE_TERMS","REQUEST_OPTIONS","REQUEST_INVESTMENT_DETAILS","REQUEST_DEAL_DETAILS","REQUEST_PRESENTATION","CONTACT_ME","LEAVE_REQUEST"],"description":"A ready closing phrase: `intent` of an option from GET /video/endings."},"ctaText":{"type":"string","maxLength":60,"x-lenient":true,"description":"Your own closing phrase (`maxCustomChars` in GET /video/endings); longer text is cut."},"ctaMarket":{"type":"string","enum":["local","remote","international"],"x-lenient":true,"x-case-insensitive":true,"description":"Who the video speaks to; tunes the auto phrase."}}}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"jobId":{"type":"string"},"entityId":{"type":"string","nullable":true},"status":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postVideoCreate","x-required-scope":"tools:video"}},"/api/v1/video/create/jobs/{id}":{"get":{"summary":"Job status: Property video from photos","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:video`.","tags":["video"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"artifacts":{"type":"array","items":{"type":"string"},"description":"Artifact ids; download each via /artifacts/v1/ai/assistant/announcement/jobs/{jobId}/artifacts/{artifactId}/download."},"artifactsSummary":{"type":"array","items":{"$ref":"#/components/schemas/ArtifactSummary"}},"bundle":{"type":"object","additionalProperties":true,"nullable":true,"description":"Landing page and PDF of the pack, when built."},"progress":{"description":"Progress of the generation while it runs."},"masterProfile":{"type":"object","additionalProperties":true,"nullable":true,"description":"The story outline the texts and narration were built on."},"error":{"type":"string","nullable":true,"description":"Set when the job failed (a generic text)."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getVideoCreateJobsById","x-required-scope":"tools:video"}},"/api/v1/flyer/create":{"post":{"summary":"Personal broker flyer","description":"A broker flyer (A4, square or story) with your photo, figures and a QR code to your referral link. Synchronous; files are listed in the response, download via GET /artifacts/v1/ai/flyer/file/{name}.\n\n**Key scope:** `tools:flyer`.","tags":["flyer"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call","parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","description":"Unknown fields are dropped.","properties":{"language":{"type":"string","enum":["ENG","RUS","UKR","DEU","SPA","AZE","ARB","FRA","ZHO","TUR"],"default":"ENG","x-case-insensitive":true},"layouts":{"type":"array","minItems":1,"maxItems":5,"items":{"type":"string","enum":["a4","feed45","square","story","link"],"x-case-insensitive":true},"default":["a4"],"description":"a4 is the print format; PDF is produced for a4 only."},"formats":{"type":"array","minItems":1,"maxItems":3,"items":{"type":"string","enum":["png","jpg","pdf"],"x-case-insensitive":true},"default":["png","pdf"]},"name":{"type":"string","maxLength":120},"role":{"type":"string","maxLength":120},"city":{"type":"string","maxLength":80},"kicker":{"type":"string","maxLength":120},"photoRef":{"type":"string","description":"\"avatar\" (your profile photo) or a data:image/… URL."},"ctaUrl":{"type":"string","maxLength":500,"description":"Referral link for the QR code (platform domains only)."},"slogan":{"type":"array","items":{"type":"string","maxLength":120},"maxItems":2},"features":{"type":"array","maxItems":6,"items":{"type":"object","properties":{"icon":{"type":"string","enum":["crm","ai","globe","publisher","marketing","shield","wallet","chart","lock","handshake"],"default":"globe"},"title":{"type":"string","maxLength":80}}}},"joinTitle":{"type":"string","maxLength":120},"joinNote":{"type":"string","maxLength":120},"builtFor":{"type":"array","items":{"type":"string","maxLength":60},"maxItems":6},"footer":{"type":"array","items":{"type":"string","maxLength":160},"maxItems":2},"contacts":{"type":"object","properties":{"phone":{"type":"string","maxLength":80},"email":{"type":"string","maxLength":120},"website":{"type":"string","maxLength":120}}}}},"example":{"language":"ENG","layouts":["a4"],"formats":["pdf"],"name":"Anna Schmidt","role":"Real estate agent","city":"Berlin","photoRef":"avatar"}}}},"responses":{"200":{"description":"Result","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"historyId":{"type":"string","nullable":true},"language":{"type":"string"},"ctaUrl":{"type":"string","description":"The link printed in the QR code."},"isAmbassador":{"type":"boolean"},"stats":{"type":"object","additionalProperties":true,"description":"The figures printed on the flyer."},"expiresAt":{"type":"string","nullable":true,"description":"Null: files are kept."},"files":{"type":"array","items":{"type":"object","properties":{"layout":{"type":"string"},"format":{"type":"string","enum":["png","jpg","pdf","mp4"]},"width":{"type":"integer"},"height":{"type":"integer"},"name":{"type":"string"},"path":{"type":"string","description":"Download via GET /artifacts{path}."},"url":{"type":"string"},"publicUrl":{"type":"string"},"bytes":{"type":"integer"}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postFlyerCreate","x-required-scope":"tools:flyer"}},"/api/v1/text/generate":{"post":{"summary":"Listing texts","description":"Description, presentation and a social post for a property. Give a listing (`objectId`) or at least one of description, city, totalArea (otherwise 422 not_enough_input). Returns 202 with a job; poll GET …/jobs/{jobId} (free) or subscribe to the text.completed / text.failed webhook.\n\n**Key scope:** `tools:text`.","tags":["text"],"security":[{"apiKey":[]}],"x-grem-billing":"api_call+sku:textGenerator.create","x-grem-webhook-events":["text.completed","text.failed"],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Safe retries: a repeat with the same key returns the first result and is not charged again."},{"name":"Grem-Simulate","in":"header","schema":{"type":"string","enum":["completed","failed","partial","insufficient_funds","service_unavailable","provider_error"],"default":"completed"},"description":"Test keys (gsk_test_) only: outcome of the simulated call. Ignored for live keys."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"objectId":{"type":"string","pattern":"^[a-f0-9]{24}$","description":"Id of a listing (GET /objects or POST /objects/{kind})."},"title":{"type":"string","maxLength":120,"x-lenient":true,"description":"Longer text is cut to 120."},"description":{"type":"string","maxLength":2000,"x-lenient":true,"description":"Longer text is cut to 2000."},"city":{"type":"string","maxLength":120,"x-lenient":true,"description":"Longer text is cut to 120."},"language":{"type":"string","enum":["en","ru","ua","de","es","az","ar","fr","zh","tr"],"default":"en","x-lenient":true,"description":"Another value is treated as en."},"totalArea":{"type":"number"},"rooms":{"type":"number"},"price":{"type":"number"},"currency":{"type":"string","maxLength":8,"x-lenient":true,"description":"Longer text is cut to 8."},"propertyCategory":{"type":"string","maxLength":40,"x-lenient":true,"description":"Longer text is cut to 40."},"customDirection":{"type":"string","maxLength":500,"x-lenient":true,"description":"Wishes for tone and emphasis (longer text is cut to 500)."}}},"example":{"city":"Berlin","totalArea":64,"rooms":2,"propertyCategory":"apartment","language":"en","description":"Renovated, quiet courtyard, 5 min to U-Bahn."}}}},"responses":{"202":{"description":"Job accepted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","properties":{"jobId":{"type":"string"},"entityId":{"type":"string","nullable":true,"description":"Generation entity the texts belong to."},"status":{"type":"string"}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postTextGenerate","x-required-scope":"tools:text"}},"/api/v1/text/generate/jobs/{id}":{"get":{"summary":"Job status: Listing texts","description":"Poll the job. Free: not counted as an API call. Only the key that created the job can read it.\n\n**Key scope:** `tools:text`.","tags":["text"],"security":[{"apiKey":[]}],"x-grem-billing":"free","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Job"},{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string","deprecated":true,"description":"Same as `jobId`."},"artifacts":{"type":"array","items":{"type":"string"},"description":"Artifact ids; download each via /artifacts/v1/ai/assistant/announcement/jobs/{jobId}/artifacts/{artifactId}/download."},"artifactsSummary":{"type":"array","items":{"$ref":"#/components/schemas/ArtifactSummary"}},"bundle":{"type":"object","additionalProperties":true,"nullable":true,"description":"Landing page and PDF of the pack, when built."},"progress":{"description":"Progress of the generation while it runs."},"masterProfile":{"type":"object","additionalProperties":true,"nullable":true,"description":"The story outline the texts and narration were built on."},"error":{"type":"string","nullable":true,"description":"Set when the job failed (a generic text)."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getTextGenerateJobsById","x-required-scope":"tools:text"}},"/api/v1/valuation/review/jobs/{id}/confirm":{"post":{"summary":"Confirm extracted facts and start the review","x-grem-billing":"api_call","description":"An appraisal review stops in state `action_required` (status `need_confirm`) once the document is read: check `extracted` in the job and confirm. Send only the fields you correct in `extracted` (shallow merge; `subject` is merged one level deep). Returns 202 with state `running`; the result arrives via polling or the review.completed / review.failed webhook.\n\n**Key scope:** `tools:review`.","tags":["valuation"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"extracted":{"type":"object","additionalProperties":true,"description":"Corrections to the extracted facts."}}}}}},"responses":{"202":{"description":"Analysis started","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Job"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postValuationReviewJobsByIdConfirm","x-required-scope":"tools:review"}},"/api/v1/voices":{"get":{"x-grem-billing":"free","summary":"Narration voices","description":"Voices for avatar/video and video/create (`voiceId`). Any key, free.","tags":["catalog"],"security":[{"apiKey":[]}],"parameters":[{"name":"language","in":"query","schema":{"type":"string"},"description":"ISO 639-1 code: only voices that speak it."}],"responses":{"200":{"description":"Voices","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"voiceId":{"type":"string"},"name":{"type":"string"},"gender":{"type":"string","enum":["male","female"]},"description":{"type":"string"},"languages":{"type":"array","items":{"type":"string"}},"isDefault":{"type":"boolean"}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getVoices"}},"/api/v1/avatar/avatars":{"get":{"x-grem-billing":"free","summary":"Avatars available to your account","description":"Your trained and photo avatars plus the standard presenters. Pass `avatarId` to POST /avatar/video (only `status: ready`). Free.\n\n**Key scope:** `tools:avatar`.","tags":["catalog"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Avatars","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"avatarId":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["custom","photo","standard"]},"status":{"type":"string","enum":["pending","processing","ready","failed"]},"gender":{"type":"string","nullable":true},"thumbnailUrl":{"type":"string","nullable":true}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getAvatarAvatars","x-required-scope":"tools:avatar"}},"/api/v1/video/music":{"get":{"x-grem-billing":"free","summary":"Background music for video/create","description":"Royalty-free tracks; pass `musicTrackId` to video/create. `previewPath` streams the track through the artifact proxy. Free.\n\n**Key scope:** `tools:video`.","tags":["catalog"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Tracks","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"trackId":{"type":"string"},"title":{"type":"string"},"artist":{"type":"string","nullable":true},"license":{"type":"string","nullable":true},"genre":{"type":"string","nullable":true},"durationSec":{"type":"number","nullable":true},"previewPath":{"type":"string","nullable":true}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getVideoMusic","x-required-scope":"tools:video"}},"/api/v1/video/endings":{"get":{"x-grem-billing":"free","summary":"Closing phrases for video/create","description":"Ready-made closing phrases in the video language and the max length of a custom one. Free.\n\n**Key scope:** `tools:video`.","tags":["catalog"],"security":[{"apiKey":[]}],"parameters":[{"name":"language","in":"query","schema":{"type":"string","default":"en"}}],"responses":{"200":{"description":"Options","content":{"application/json":{"schema":{"type":"object","properties":{"language":{"type":"string"},"maxCustomChars":{"type":"integer"},"options":{"type":"array","items":{"type":"object","properties":{"intent":{"type":"string","x-extensible-enum":["BOOK_VIEWING","REQUEST_DETAILS","REQUEST_PURCHASE_TERMS","REQUEST_OPTIONS","REQUEST_INVESTMENT_DETAILS","REQUEST_DEAL_DETAILS","REQUEST_PRESENTATION","CONTACT_ME","LEAVE_REQUEST"],"description":"Pass as `ctaIntent` to POST /video/create."},"text":{"type":"string","description":"The phrase in the requested language."}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getVideoEndings","x-required-scope":"tools:video"}},"/api/v1/tools/status":{"get":{"x-grem-billing":"free","summary":"Tool availability","description":"Which tools are up right now. A tool with `available: false` answers 503 service_unavailable until it recovers — nothing is charged. Tools not listed have no availability gate. Any key, free.","tags":["catalog"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Availability keyed by public tool path","content":{"application/json":{"schema":{"type":"object","properties":{"tools":{"type":"object","additionalProperties":{"type":"object","properties":{"available":{"type":"boolean"}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getToolsStatus"}},"/api/v1/works":{"get":{"x-grem-billing":"free","summary":"Your work history across tools","description":"Results your account produced in any tool (through the API or the cabinet), newest first. Any key, free.","tags":["catalog"],"security":[{"apiKey":[]}],"parameters":[{"name":"tool","in":"query","schema":{"type":"string","enum":["valuation/report","valuation/rent","valuation/review","content/generate","video/create","text/generate","pdf/create","floorplan/create","avatar/video","flyer/create","tour"]},"description":"Public tool path. Photo, site and draft results are not kept in the history."},{"name":"status","in":"query","schema":{"type":"string"}},{"name":"cursor","in":"query","schema":{"type":"string"},"description":"`nextCursor` of the previous page (another value is 400)."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":50,"default":20,"x-clamp":true}},{"name":"from","in":"query","schema":{"type":"string","format":"date"},"description":"Created on or after this date."},{"name":"to","in":"query","schema":{"type":"string","format":"date"},"description":"Created on or before this date."}],"responses":{"200":{"description":"Works","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"tool":{"type":"string"},"status":{"type":"string","nullable":true},"title":{"type":"string"},"language":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"country":{"type":"string","nullable":true},"street":{"type":"string","nullable":true},"streetNumber":{"type":"string","nullable":true},"previewUrl":{"type":"string","nullable":true,"description":"Preview image of the result (a /files/… path: download via GET /artifacts/{path})."},"link":{"type":"string","nullable":true,"description":"The finished document (PDF), when there is one."},"repeatIndex":{"type":"integer","description":"How many times this result was regenerated."},"error":{"type":"string","nullable":true,"description":"Set when the job failed (a generic text)."},"object":{"type":"object","nullable":true,"description":"The listing the result was made for.","properties":{"id":{"type":"string","nullable":true},"kind":{"type":"string","nullable":true,"x-extensible-enum":["property","rental","complex"]},"name":{"type":"string"},"isDraft":{"type":"boolean"},"photoUrl":{"type":"string","nullable":true}}},"createdAt":{"type":"string","format":"date-time","nullable":true}}}},"nextCursor":{"type":"string","nullable":true},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request body or file too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Understood but cannot be processed (business_rule) — see `code` and `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getWorks"}},"/api/v1/webhooks":{"get":{"summary":"List webhooks","tags":["webhooks"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Your webhook endpoints (the signing secret is never returned again).","content":{"application/json":{"schema":{"type":"object","properties":{"webhooks":{"type":"array","items":{"$ref":"#/components/schemas/WebhookEndpoint"}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getWebhooks","x-required-scope":"webhooks","description":"Your webhook endpoints with their events and status. The signing secret is never returned again.\n\n**Key scope:** `webhooks`.","x-grem-billing":"free"},"post":{"summary":"Create webhook","description":"Register a URL to receive job-completion events. The signing secret is returned once.\n\n**Key scope:** `webhooks`.","tags":["webhooks"],"security":[{"apiKey":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["url","events"],"properties":{"url":{"type":"string","format":"uri"},"events":{"type":"array","items":{"type":"string"}}}}}}},"responses":{"201":{"description":"Created (secret shown once)","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/WebhookEndpoint"},{"type":"object","properties":{"secret":{"type":"string","description":"whsec_… — shown only in this response."}}}]}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postWebhooks","x-required-scope":"webhooks","x-grem-billing":"free"}},"/api/v1/webhooks/{id}":{"patch":{"summary":"Update webhook","description":"Change url/events or toggle status (active|disabled). Re-enabling clears the failure counter.\n\n**Key scope:** `webhooks`.","tags":["webhooks"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"events":{"type":"array","items":{"type":"string"}},"status":{"type":"string","enum":["active","disabled"]}}}}}},"responses":{"200":{"description":"Updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpoint"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"patchWebhooksById","x-required-scope":"webhooks","x-grem-billing":"free"},"delete":{"summary":"Delete webhook","tags":["webhooks"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean","description":"False when there was no such webhook."}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"deleteWebhooksById","x-required-scope":"webhooks","description":"Removes the endpoint; pending deliveries are dropped.\n\n**Key scope:** `webhooks`.","x-grem-billing":"free"}},"/api/v1/webhooks/{id}/test":{"post":{"summary":"Send test event","description":"Delivers a signed sample event through the real pipeline. Optional body.eventType picks a realistic payload for that event.\n\n**Key scope:** `webhooks`.","tags":["webhooks"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"eventType":{"type":"string","description":"One of the webhook events; another value is 400. Omitted: a generic webhook.test event."}}}}}},"responses":{"200":{"description":"Delivery result","content":{"application/json":{"schema":{"type":"object","properties":{"delivered":{"type":"boolean"},"statusCode":{"type":"integer","nullable":true,"description":"Your endpoint's HTTP status; null when it could not be reached."},"latencyMs":{"type":"integer","nullable":true},"bodySnippet":{"type":"string","nullable":true,"description":"Start of your endpoint's response body."}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postWebhooksByIdTest","x-required-scope":"webhooks","x-grem-billing":"free"}},"/api/v1/webhooks/{id}/deliveries":{"get":{"summary":"Recent deliveries","description":"Last 50 delivery attempts with payload, response snippet and retry schedule.\n\n**Key scope:** `webhooks`.","tags":["webhooks"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deliveries, newest first","content":{"application/json":{"schema":{"type":"object","properties":{"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getWebhooksByIdDeliveries","x-required-scope":"webhooks","x-grem-billing":"free"}},"/api/v1/webhooks/{id}/deliveries/{deliveryId}/resend":{"post":{"summary":"Resend a delivery","tags":["webhooks"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"deliveryId","in":"path","required":true,"schema":{"type":"string"},"description":"`_id` of a row from GET …/deliveries."}],"responses":{"200":{"description":"Delivery result (a new delivery row is recorded)","content":{"application/json":{"schema":{"type":"object","properties":{"delivered":{"type":"boolean"},"statusCode":{"type":"integer","nullable":true,"description":"Your endpoint's HTTP status; null when it could not be reached."},"latencyMs":{"type":"integer","nullable":true}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postWebhooksByIdDeliveriesByDeliveryIdResend","x-required-scope":"webhooks","description":"Sends the same event again, signed with the current secret.\n\n**Key scope:** `webhooks`.","x-grem-billing":"free"}},"/api/v1/artifacts/{path}":{"get":{"summary":"Download an artifact","tags":["artifacts"],"security":[{"apiKey":[]}],"parameters":[{"name":"path","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"File stream","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"416":{"description":"range_not_satisfiable: the Range is outside the file (`Content-Range: bytes */size`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getArtifactsByPath","x-required-scope":"tools:artifacts","description":"Streams a generated file with your key. `path` is the file path from a tool response: /files/… or a download path under /v1/ai/…. Supports Range. Content-gen artifacts are available only to the key account that created the job.\n\n**Key scope:** `tools:artifacts`.","x-grem-billing":"free"}},"/api/v1/chat/sessions":{"post":{"summary":"Create a chat session","tags":["chat"],"security":[{"apiKey":[]}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"mode":{"type":"string","enum":["chat_consult"],"default":"chat_consult","description":"The API opens consultant sessions only; another value is replaced."},"title":{"type":"string","maxLength":200},"projectId":{"type":"string","nullable":true}}}}}},"responses":{"200":{"description":"Session","content":{"application/json":{"schema":{"type":"object","properties":{"sessionId":{"type":"string"},"status":{"type":"string"},"mode":{"type":"string"},"createdAt":{"type":"string"},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postChatSessions","x-required-scope":"tools:chat","description":"Starts a chat session with the AI assistant.\n\n**Key scope:** `tools:chat`.","x-grem-billing":"api_call"},"get":{"summary":"List chat sessions","tags":["chat"],"security":[{"apiKey":[]}],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":50,"default":20}},{"name":"cursor","in":"query","schema":{"type":"string"},"description":"`nextCursor` of the previous page."},{"name":"q","in":"query","schema":{"type":"string","maxLength":200},"description":"Search in session titles."},{"name":"projectId","in":"query","schema":{"type":"string"}},{"name":"archivedOnly","in":"query","schema":{"type":"boolean"},"description":"The archive instead of the active list."},{"name":"sort","in":"query","schema":{"type":"string","enum":["recent","title"]}}],"responses":{"200":{"description":"Your assistant chat sessions.","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"},"items":{"type":"array","items":{"$ref":"#/components/schemas/ChatSession"}},"nextCursor":{"type":"string","nullable":true,"description":"Opaque cursor of the next page; null on the last page."},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getChatSessions","x-required-scope":"tools:chat","description":"Your chat sessions, newest first.\n\n**Key scope:** `tools:chat`.","x-grem-billing":"free"}},"/api/v1/chat/sessions/{id}":{"patch":{"summary":"Update a chat session","tags":["chat"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","description":"At least one field.","properties":{"title":{"type":"string","maxLength":200},"projectId":{"type":"string","nullable":true},"isPinned":{"type":"boolean"},"isUnread":{"type":"boolean"},"isArchived":{"type":"boolean","enum":[false],"description":"Only `false` (restore); archive with DELETE."}}}}}},"responses":{"200":{"description":"The updated session","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatSession"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"patchChatSessionsById","x-required-scope":"tools:chat","description":"Renames or pins a session.\n\n**Key scope:** `tools:chat`.","x-grem-billing":"api_call"},"delete":{"summary":"Archive a chat session","tags":["chat"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Archived","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"},"archived":{"type":"boolean"},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"deleteChatSessionsById","x-required-scope":"tools:chat","description":"Archives a session.\n\n**Key scope:** `tools:chat`.","x-grem-billing":"api_call"}},"/api/v1/chat/messages":{"post":{"summary":"Send a chat message","description":"Returns a synchronous ACK; the assistant tokens stream over GET /chat/stream. Billed per message.\n\n**Key scope:** `tools:chat`.","tags":["chat"],"security":[{"apiKey":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["sessionId","clientMessageId","text"],"properties":{"sessionId":{"type":"string"},"clientMessageId":{"type":"string","description":"Your id for this message; a repeat with the same id is not answered (or charged) twice."},"text":{"type":"string"},"style":{"type":"string","enum":["short","normal","detailed"],"description":"Answer length."}}}}}},"responses":{"200":{"description":"ACK. `accepted: false` with `error: \"SESSION_BUSY\"` means the session is still answering a previous message — retry after it finishes.","content":{"application/json":{"schema":{"type":"object","properties":{"accepted":{"type":"boolean"},"locked":{"type":"boolean"},"serverMessageId":{"type":"string"},"status":{"type":"string","description":"RUNNING while the answer streams, IDLE when nothing was generated."},"error":{"type":"string","description":"Present when not accepted: SESSION_BUSY."},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postChatMessages","x-required-scope":"tools:chat","x-grem-billing":"api_call+sku:assistant.chat.message"}},"/api/v1/chat/history":{"get":{"summary":"Chat history","tags":["chat"],"security":[{"apiKey":[]}],"parameters":[{"name":"sessionId","in":"query","required":true,"schema":{"type":"string"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":200,"default":50,"x-clamp":true}},{"name":"cursor","in":"query","schema":{"type":"string"},"description":"`nextCursor` of the previous page."}],"responses":{"200":{"description":"Messages, oldest first","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"},"items":{"type":"array","items":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"role":{"type":"string","x-extensible-enum":["user","assistant"]},"text":{"type":"string"},"createdAt":{"type":"string"}}}},"nextCursor":{"type":"string","nullable":true},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getChatHistory","x-required-scope":"tools:chat","description":"Messages of a session.\n\n**Key scope:** `tools:chat`.","x-grem-billing":"free"}},"/api/v1/chat/stream":{"get":{"summary":"Chat event stream (SSE)","description":"Server-Sent Events (text/event-stream). Not counted against your API call quota.\n\n**Key scope:** `tools:chat`.","tags":["chat"],"security":[{"apiKey":[]}],"parameters":[{"name":"sessionId","in":"query","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"text/event-stream","content":{"text/event-stream":{"schema":{"type":"string"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getChatStream","x-required-scope":"tools:chat","x-grem-billing":"free"}},"/api/v1/objects":{"get":{"summary":"List public objects (catalog)","description":"Paginated public listings in the read-contract shape. Enum values are codes — decode via /dictionaries. Filters: price/area are ranges (price in USD via the normalized field; area in m2); rooms/type/residentialType apply to property & rental (ignored for complex). Free (not counted as an API call).","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"query","required":true,"schema":{"type":"string","enum":["property","rental","complex"],"x-case-insensitive":true}},{"name":"city","in":"query","required":false,"schema":{"type":"string"}},{"name":"country","in":"query","required":false,"schema":{"type":"string"}},{"name":"priceMin","in":"query","required":false,"schema":{"type":"number"},"description":"Min price in USD (normalized)."},{"name":"priceMax","in":"query","required":false,"schema":{"type":"number"},"description":"Max price in USD (normalized)."},{"name":"areaMin","in":"query","required":false,"schema":{"type":"number"},"description":"Min area in m2."},{"name":"areaMax","in":"query","required":false,"schema":{"type":"number"},"description":"Max area in m2."},{"name":"rooms","in":"query","required":false,"schema":{"type":"number"},"description":"Exact room count (property/rental)."},{"name":"type","in":"query","required":false,"schema":{"type":"string"},"description":"Top category code, e.g. Residential (property/rental)."},{"name":"residentialType","in":"query","required":false,"schema":{"type":"string"},"description":"Residential subtype code (property/rental)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"x-clamp":true}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":20,"x-clamp":true}},{"name":"sort","in":"query","required":false,"schema":{"type":"string","enum":["newest","oldest"],"default":"newest"}},{"name":"scope","in":"query","required":false,"schema":{"type":"string","enum":["agency","catalog"],"default":"agency"},"description":"Agency keys only: by default the list shows your agency’s objects; `catalog` switches to the public catalog. Ignored for personal keys."}],"responses":{"200":{"description":"Listing page","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PublicListing"}},"paginate":{"oneOf":[{"$ref":"#/components/schemas/Paginate"},{"type":"boolean"}]},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getObjects","x-grem-billing":"free"}},"/api/v1/objects/{kind}/{id}":{"get":{"summary":"Get a public object","description":"A single listing in the read-contract shape. Free (not counted as an API call).","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"scope","in":"query","required":false,"schema":{"type":"string","enum":["agency","catalog"],"default":"agency"},"description":"Agency keys only: `catalog` returns the public view of the object instead of the agency view."}],"responses":{"200":{"description":"Object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicListing"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getObjectsByKindById","x-grem-billing":"free"},"put":{"summary":"Edit an object","description":"Update a listing you own (owner-only; a non-owner gets 404). Omitting `photos` keeps the existing photos. Not billed.\n\n**Key scope:** `objects:write`.","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Fields depend on {kind}: see components ObjectWriteProperty, ObjectWriteRental, ObjectWriteComplex (generated from the server validators). ObjectWrite lists the common core.","x-grem-kind-schemas":{"property":{"$ref":"#/components/schemas/ObjectWriteProperty"},"rental":{"$ref":"#/components/schemas/ObjectWriteRental"},"complex":{"$ref":"#/components/schemas/ObjectWriteComplex"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectWrite"}}}},"responses":{"200":{"description":"Updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicListing"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not owned)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Business rule (e.g. publish below the min photo count)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"putObjectsByKindById","x-required-scope":"objects:write","x-grem-billing":"free"},"delete":{"summary":"Delete or archive an object","description":"Owner-only. A DRAFT is permanently removed; a PUBLISHED object is soft-archived (leaves the public catalog, recoverable by re-publishing). Never a hard delete of a live listing. Emits an object.deleted webhook (payload.mode = \"deleted\" | \"archived\"); archiving a published object sends an object.updated first. Not billed.\n\n**Key scope:** `objects:write`.","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted or archived","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["property","rental","complex"]},"mode":{"type":"string","enum":["deleted","archived"]},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not owned)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"Cannot delete/archive (e.g. an object under an active commission contract)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"deleteObjectsByKindById","x-required-scope":"objects:write","x-grem-billing":"free"}},"/api/v1/objects/{kind}":{"post":{"summary":"Create an object","description":"Create a listing you own. `publish:false` (default) creates a draft; publishing requires the per-kind minimum photos. Requires an account role permitted to list that kind. Not billed. Send an `Idempotency-Key` header to make retries safe — a replay returns the original result instead of creating a duplicate.\n\n**Key scope:** `objects:write`.","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"Idempotency-Key","in":"header","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Fields depend on {kind}: see components ObjectWriteProperty, ObjectWriteRental, ObjectWriteComplex (generated from the server validators). ObjectWrite lists the common core.","x-grem-kind-schemas":{"property":{"$ref":"#/components/schemas/ObjectWriteProperty"},"rental":{"$ref":"#/components/schemas/ObjectWriteRental"},"complex":{"$ref":"#/components/schemas/ObjectWriteComplex"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectWrite"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicListing"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Business rule (e.g. publish below the min photo count)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postObjectsByKind","x-required-scope":"objects:write","x-grem-billing":"free"}},"/api/v1/objects/{kind}/{id}/agency":{"patch":{"summary":"Transfer an object personal↔agency (agency)","description":"Move a listing into your agency, or back to personal (agency key only — 403 with a personal key). Body `{ \"targetAgencyId\": \"<id>\" | null }`; omitted defaults to the acting agency. Cross-agency transfer is blocked (move to personal first). Roles: personal→agency needs the creator; agency→personal needs a manager/owner or the creator. Not billed.\n\n**Key scope:** `objects:write`.","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"targetAgencyId":{"type":"string","nullable":true}}}}}},"responses":{"200":{"description":"Transferred","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Object not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"Cross-agency transfer not supported","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"patchObjectsByKindByIdAgency","x-required-scope":"objects:write","x-grem-billing":"free"}},"/api/v1/objects/{kind}/{id}/assignee":{"patch":{"summary":"Assign an object to a member (agency)","description":"Assign an agency listing to an agency member (agency key only). Manager+ may assign to anyone; an agent may assign to themselves. Body `{ \"assignTo\": \"<memberUserId>\" }`. Not billed.\n\n**Key scope:** `objects:write`.","tags":["objects"],"security":[{"apiKey":[]}],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["property","rental","complex"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["assignTo"],"properties":{"assignTo":{"type":"string"}}}}}},"responses":{"200":{"description":"Assigned","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Object not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"Listing is personal / target not an active member","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"patchObjectsByKindByIdAssignee","x-required-scope":"objects:write","x-grem-billing":"free"}},"/api/v1/leads":{"get":{"summary":"List your leads","description":"Leads where you are the sender or recipient (your own leads only). Filters on the lead itself; no counterparty data. Not billed.\n\n**Key scope:** `leads:read`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["new","in progress","processing","agreement","closed","not target","failed"]}},{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["contract","transfer","user","buy","rent","viewing","sell"]}},{"name":"priority","in":"query","required":false,"schema":{"type":"string","enum":["hot","warm","cold"]}},{"name":"source","in":"query","required":false,"schema":{"type":"string"}},{"name":"role","in":"query","required":false,"schema":{"type":"string","enum":["received","sent"]},"description":"Default: both."},{"name":"archived","in":"query","required":false,"schema":{"type":"boolean"},"description":"Default false: archived leads are hidden. true -> only archived."},{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"description":"createdAt >="},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"description":"createdAt <="},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"x-clamp":true}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":20,"x-clamp":true}},{"name":"sort","in":"query","required":false,"schema":{"type":"string","enum":["newest","oldest"],"default":"newest"}},{"name":"pool","in":"query","required":false,"schema":{"type":"string","enum":["true"]},"description":"Agency keys only: `true` lists the leads in your agency’s shared pool (claim them with POST /leads/{id}/claim)."}],"responses":{"200":{"description":"Lead page","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PublicLead"}},"paginate":{"oneOf":[{"$ref":"#/components/schemas/Paginate"},{"type":"boolean"}]},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getLeads","x-required-scope":"leads:read","x-grem-billing":"free"},"post":{"summary":"Submit an inbound lead","description":"Create a lead in YOUR CRM from an inbound buyer inquiry (e.g. your website form). recipient = your account; marked source=\"api\". Attach it to a listing with objectId. Fires a lead.created webhook. Not billed. Send an `Idempotency-Key` header to make retries safe — a replay returns the original result instead of creating a duplicate lead.\n\n**Key scope:** `leads:write`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadWrite"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postLeads","x-required-scope":"leads:write","x-grem-billing":"free"}},"/api/v1/leads/{id}":{"get":{"summary":"Get one of your leads","description":"A single lead you own (404 if not yours). `?expand=history,documents` adds the heavier fields. Not billed.\n\n**Key scope:** `leads:read`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"schema":{"type":"string"},"description":"Comma list: history, documents."}],"responses":{"200":{"description":"Lead","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getLeadsById","x-required-scope":"leads:read","x-grem-billing":"free"},"patch":{"summary":"Update a lead","description":"Update status/tags/priority/brokerComments on a lead you own (404 if not yours). Fires a lead.updated webhook. Not billed.\n\n**Key scope:** `leads:write`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadPatch"}}}},"responses":{"200":{"description":"Updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"patchLeadsById","x-required-scope":"leads:write","x-grem-billing":"free"},"delete":{"summary":"Archive a lead","description":"Soft-archive a lead you own (404 if not yours). Archived leads are hidden from the list by default (list ?archived=true to see them). This is NOT a hard delete — it stays recoverable from the cabinet. The cabinet rules apply: a lead with an active contract or finalization agreement, a closed lead with a listing that is not finalized, a lead waiting for the commission is not archived (422 with `code` contract_active | agreement | finalize | fee_pending). Not billed.\n\n**Key scope:** `leads:write`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Archived","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"deleteLeadsById","x-required-scope":"leads:write","x-grem-billing":"free"}},"/api/v1/leads/{id}/matches":{"get":{"summary":"Matching inventory for a lead","description":"Demand-based catalog suggestions for a lead you own (404 if not yours). The lead type picks the inventory kind (rent -> rentals, otherwise for-sale properties); city and budget are taken from the lead (metadata.targetCity + budget) or, when absent, from the object the lead is attached to. Returns published catalog cards within ~110% of budget, cheapest-fit first, plus a matchedOn summary. Not billed.\n\n**Key scope:** `leads:read`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"x-clamp":true}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":20,"x-clamp":true}}],"responses":{"200":{"description":"Matches","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["property","rental"]},"name":{"type":"string","nullable":true},"address":{"type":"object","additionalProperties":true,"nullable":true},"price":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true},"priceUsd":{"type":"number","nullable":true},"photos":{"type":"array","items":{"$ref":"#/components/schemas/PublicPhoto"}}}}},"matchedOn":{"type":"object","properties":{"kind":{"type":"string"},"city":{"type":"string","nullable":true},"budgetUsd":{"type":"number","nullable":true}}},"paginate":{"oneOf":[{"$ref":"#/components/schemas/Paginate"},{"type":"boolean"}]},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getLeadsByIdMatches","x-required-scope":"leads:read","x-grem-billing":"free"}},"/api/v1/leads/{id}/claim":{"post":{"summary":"Claim a pool lead (agency)","description":"Claim an unassigned pool lead into the acting agency (agency key only — 403 with a personal key). By default the lead is assigned to the acting agency owner; pass ?assignTo=<memberUserId> (owner/manager) to route it to a specific member. Fires a lead.updated webhook. Not billed.\n\n**Key scope:** `leads:write`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"assignTo","in":"query","required":false,"schema":{"type":"string"},"description":"Member userId to assign the lead to (owner/manager only)."}],"responses":{"200":{"description":"Claimed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Lead not in pool / not found (403 = personal key or insufficient role)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postLeadsByIdClaim","x-required-scope":"leads:write","x-grem-billing":"free"}},"/api/v1/leads/{id}/return-to-pool":{"post":{"summary":"Return a lead to the pool (agency)","description":"Return an assigned lead to the agency pool (agency key only). Allowed for a manager+ or the currently-assigned agent. Optional JSON body `{ \"reason\": \"...\" }`. A lead the pool rules archived is refused with 422 business_rule, code `pool_archived` (restore it in the cabinet first). Fires a lead.updated webhook. Not billed.\n\n**Key scope:** `leads:write`.","tags":["leads"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"reason":{"type":"string"}}}}}},"responses":{"200":{"description":"Returned to pool","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLead"}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Lead not found (403 = personal key or insufficient role)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postLeadsByIdReturnToPool","x-required-scope":"leads:write","x-grem-billing":"free"}},"/api/v1/match/leads":{"get":{"summary":"Incoming leads (Swipe Match)","description":"view=inbox — open offers to you (or to your agency agents with an agency key), without client data; view=active (default) — leads matched to you (agency key: to the agency agents). Not billed.\n\n**Key scope:** `leads:read`.","tags":["match"],"security":[{"apiKey":[]}],"parameters":[{"name":"view","in":"query","required":false,"schema":{"type":"string","enum":["active","inbox"],"default":"active"}},{"name":"stage","in":"query","required":false,"schema":{"type":"string","enum":["new","offered","intro","match","contact","meeting_scheduled","meeting_held","contract","deal","closed","lost"]}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":1000,"default":1}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":20}}],"responses":{"200":{"description":"Leads","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"stage":{"type":"string","enum":["new","offered","intro","match","contact","meeting_scheduled","meeting_held","contract","deal","closed","lost"]},"dealPending":{"type":"boolean"},"kind":{"type":"string","x-extensible-enum":["buyer_object","buyer_request","seller","grem_ads","pool"]},"clientType":{"type":"string","enum":["buyer","seller"]},"country":{"type":"string","nullable":true},"objectId":{"type":"string","nullable":true},"objectIds":{"type":"array","items":{"type":"string"}},"requestParams":{"type":"object","nullable":true,"additionalProperties":true},"answers":{"type":"object","properties":{"budget":{"nullable":true},"timeline":{"nullable":true},"payment":{"nullable":true}}},"budget":{"type":"object","properties":{"min":{"type":"number","nullable":true},"max":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true}}},"qualScore":{"type":"number","nullable":true},"qualBand":{"type":"string","nullable":true},"clientInitial":{"type":"string","nullable":true},"offer":{"type":"object","nullable":true,"properties":{"id":{"type":"string"},"wave":{"type":"integer"},"offeredAt":{"type":"string","format":"date-time"},"deadline":{"type":"string","format":"date-time"}}},"contactDeadline":{"type":"string","format":"date-time","nullable":true},"meetingDeadline":{"type":"string","format":"date-time","nullable":true},"deal":{"type":"object","nullable":true,"additionalProperties":true},"reservation":{"type":"object","nullable":true,"additionalProperties":true},"dealObjects":{"type":"array","items":{"type":"object","additionalProperties":true}},"client":{"type":"object","description":"Only after the match, once the contact is revealed.","properties":{"name":{"type":"string"},"phone":{"type":"string","nullable":true}}},"brokerId":{"type":"string"},"fee":{"type":"object","nullable":true,"description":"The platform's fee on this lead for you: `none`; `percent` — that percent of the commission you receive; `contract` — by your agreement. Never amounts. Absent when it cannot be determined yet.","properties":{"kind":{"type":"string","x-extensible-enum":["none","percent","contract"]},"percent":{"type":"number","description":"kind percent only."}}}},"description":"Broker view of an incoming lead: id, stage, dealPending, kind, clientType, country, objectId(s), answers, budget, offer {id, deadline}, contactDeadline, meetingDeadline, deal, reservation, brokerId, fee (kind of platform fee, never amounts). `client {name, phone}` appears only after the match and only for the lead's broker or their agency; the client's e-mail and platform id are never returned."}},"page":{"type":"integer"},"limit":{"type":"integer"},"view":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"409 with `code`: not_available (module stage < 3), client_event_rejected, invalid_transition","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getMatchLeads","x-required-scope":"leads:read","x-grem-billing":"free"}},"/api/v1/match/leads/{id}":{"get":{"summary":"One incoming lead (Swipe Match)","tags":["match"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Lead","content":{"application/json":{"schema":{"type":"object","properties":{"lead":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"stage":{"type":"string","enum":["new","offered","intro","match","contact","meeting_scheduled","meeting_held","contract","deal","closed","lost"]},"dealPending":{"type":"boolean"},"kind":{"type":"string","x-extensible-enum":["buyer_object","buyer_request","seller","grem_ads","pool"]},"clientType":{"type":"string","enum":["buyer","seller"]},"country":{"type":"string","nullable":true},"objectId":{"type":"string","nullable":true},"objectIds":{"type":"array","items":{"type":"string"}},"requestParams":{"type":"object","nullable":true,"additionalProperties":true},"answers":{"type":"object","properties":{"budget":{"nullable":true},"timeline":{"nullable":true},"payment":{"nullable":true}}},"budget":{"type":"object","properties":{"min":{"type":"number","nullable":true},"max":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true}}},"qualScore":{"type":"number","nullable":true},"qualBand":{"type":"string","nullable":true},"clientInitial":{"type":"string","nullable":true},"offer":{"type":"object","nullable":true,"properties":{"id":{"type":"string"},"wave":{"type":"integer"},"offeredAt":{"type":"string","format":"date-time"},"deadline":{"type":"string","format":"date-time"}}},"contactDeadline":{"type":"string","format":"date-time","nullable":true},"meetingDeadline":{"type":"string","format":"date-time","nullable":true},"deal":{"type":"object","nullable":true,"additionalProperties":true},"reservation":{"type":"object","nullable":true,"additionalProperties":true},"dealObjects":{"type":"array","items":{"type":"object","additionalProperties":true}},"client":{"type":"object","description":"Only after the match, once the contact is revealed.","properties":{"name":{"type":"string"},"phone":{"type":"string","nullable":true}}},"brokerId":{"type":"string"},"fee":{"type":"object","nullable":true,"description":"The platform's fee on this lead for you: `none`; `percent` — that percent of the commission you receive; `contract` — by your agreement. Never amounts. Absent when it cannot be determined yet.","properties":{"kind":{"type":"string","x-extensible-enum":["none","percent","contract"]},"percent":{"type":"number","description":"kind percent only."}}}},"description":"Broker view of an incoming lead: id, stage, dealPending, kind, clientType, country, objectId(s), answers, budget, offer {id, deadline}, contactDeadline, meetingDeadline, deal, reservation, brokerId, fee (kind of platform fee, never amounts). `client {name, phone}` appears only after the match and only for the lead's broker or their agency; the client's e-mail and platform id are never returned."}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"409 with `code`: not_available (module stage < 3), client_event_rejected, invalid_transition","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getMatchLeadsById","x-required-scope":"leads:read","description":"One Swipe Match lead offered to or matched with you. Client name and phone appear only once the lead is matched to you and the contact is revealed; before that only the client initial.\n\n**Key scope:** `leads:read`.","x-grem-billing":"free"}},"/api/v1/match/leads/{id}/events":{"get":{"summary":"Lead event log (Swipe Match)","description":"Events of your assignment and your offers; no money events, client ratings or service events.\n\n**Key scope:** `leads:read`.","tags":["match"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Events","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":true}}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not yours)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"409 with `code`: not_available (module stage < 3), client_event_rejected, invalid_transition","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getMatchLeadsByIdEvents","x-required-scope":"leads:read","x-grem-billing":"free"},"post":{"summary":"Move your lead to the next stage (Swipe Match)","description":"Broker events of YOUR OWN lead only, checked by the module state machine; recorded with source \"api\". event: FIRST_CONTACT {channel: phone|messenger}; RESERVATION {amount, currency, date, documentFileId?}; STAGE_ROLLBACK {reasonCode, text?}; LEAD_LOST {reasonCode, text?}; DEAL_CLOSED {objectId, amount, currency, date, documentFileId, commissionReceived?, commissionCurrency?}. Client events -> 409 client_event_rejected. Send `Idempotency-Key` to make retries safe.\n\n**Key scope:** `leads:write`.","tags":["match"],"security":[{"apiKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"8-128 characters: letters, digits, _ . : - (another format is 400 validation)."}],"requestBody":{"required":true,"x-grem-event-schemas":{"FIRST_CONTACT":{"$ref":"#/components/schemas/MatchEventFirstContact"},"RESERVATION":{"$ref":"#/components/schemas/MatchEventReservation"},"STAGE_ROLLBACK":{"$ref":"#/components/schemas/MatchEventReason"},"LEAD_LOST":{"$ref":"#/components/schemas/MatchEventReason"},"DEAL_CLOSED":{"$ref":"#/components/schemas/MatchEventDealClosed"}},"content":{"application/json":{"schema":{"type":"object","required":["event"],"properties":{"event":{"type":"string","enum":["FIRST_CONTACT","RESERVATION","STAGE_ROLLBACK","LEAD_LOST","DEAL_CLOSED"]}},"additionalProperties":true}}}},"responses":{"200":{"description":"Lead after the transition","content":{"application/json":{"schema":{"type":"object","properties":{"lead":{"type":"object","additionalProperties":true,"properties":{"id":{"type":"string"},"stage":{"type":"string","enum":["new","offered","intro","match","contact","meeting_scheduled","meeting_held","contract","deal","closed","lost"]},"dealPending":{"type":"boolean"},"kind":{"type":"string","x-extensible-enum":["buyer_object","buyer_request","seller","grem_ads","pool"]},"clientType":{"type":"string","enum":["buyer","seller"]},"country":{"type":"string","nullable":true},"objectId":{"type":"string","nullable":true},"objectIds":{"type":"array","items":{"type":"string"}},"requestParams":{"type":"object","nullable":true,"additionalProperties":true},"answers":{"type":"object","properties":{"budget":{"nullable":true},"timeline":{"nullable":true},"payment":{"nullable":true}}},"budget":{"type":"object","properties":{"min":{"type":"number","nullable":true},"max":{"type":"number","nullable":true},"currency":{"type":"string","nullable":true}}},"qualScore":{"type":"number","nullable":true},"qualBand":{"type":"string","nullable":true},"clientInitial":{"type":"string","nullable":true},"offer":{"type":"object","nullable":true,"properties":{"id":{"type":"string"},"wave":{"type":"integer"},"offeredAt":{"type":"string","format":"date-time"},"deadline":{"type":"string","format":"date-time"}}},"contactDeadline":{"type":"string","format":"date-time","nullable":true},"meetingDeadline":{"type":"string","format":"date-time","nullable":true},"deal":{"type":"object","nullable":true,"additionalProperties":true},"reservation":{"type":"object","nullable":true,"additionalProperties":true},"dealObjects":{"type":"array","items":{"type":"object","additionalProperties":true}},"client":{"type":"object","description":"Only after the match, once the contact is revealed.","properties":{"name":{"type":"string"},"phone":{"type":"string","nullable":true}}},"brokerId":{"type":"string"},"fee":{"type":"object","nullable":true,"description":"The platform's fee on this lead for you: `none`; `percent` — that percent of the commission you receive; `contract` — by your agreement. Never amounts. Absent when it cannot be determined yet.","properties":{"kind":{"type":"string","x-extensible-enum":["none","percent","contract"]},"percent":{"type":"number","description":"kind percent only."}}}},"description":"Broker view of an incoming lead: id, stage, dealPending, kind, clientType, country, objectId(s), answers, budget, offer {id, deadline}, contactDeadline, meetingDeadline, deal, reservation, brokerId, fee (kind of platform fee, never amounts). `client {name, phone}` appears only after the match and only for the lead's broker or their agency; the client's e-mail and platform id are never returned."},"replay":{"type":"boolean"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Not found (or not your lead)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"409":{"description":"409 with `code`: not_available (module stage < 3), client_event_rejected, invalid_transition","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postMatchLeadsByIdEvents","x-required-scope":"leads:write","x-grem-billing":"free"}},"/api/v1/me":{"get":{"summary":"Key introspection","description":"Who am I / what can this key do. Returns the key identity (keyId, prefix), subject, granted scopes, effective rate limit (rpm/rpd), and expiry. Scope-free — any valid key may call it. The secret is never returned. Not billed.","tags":["meta"],"security":[{"apiKey":[]}],"responses":{"200":{"description":"Key info","content":{"application/json":{"schema":{"type":"object","properties":{"keyId":{"type":"string"},"prefix":{"type":"string","enum":["gsk_live","gsk_test"]},"subjectType":{"type":"string","enum":["user","agency"]},"subjectId":{"type":"string"},"agencyMemberId":{"type":"string","description":"Agent-scoped agency key: the member it acts as."},"scopes":{"type":"array","items":{"type":"string"}},"rateLimit":{"type":"object","properties":{"rpm":{"type":"integer"},"rpd":{"type":"integer"}}},"expiresAt":{"type":"string","format":"date-time","nullable":true},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getMe","x-grem-billing":"free"}},"/api/v1/uploads":{"post":{"summary":"Upload images","description":"Upload one or more images (multipart/form-data; any field names) and get back File ids you can attach to a listing via `photos:[id]` on object create/edit. Images only (JPG/PNG/WEBP), max 15 MB per file, max 10 files, total request <= 30 MB. Not billed. The returned `url` is your own original (owner preview); once attached to a published listing, the public catalog serves watermarked variants only.\n\n**Key scope:** `media:write`.","tags":["objects"],"security":[{"apiKey":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"file":{"type":"array","items":{"type":"string","format":"binary"},"description":"One or more image files."}}}}}},"responses":{"200":{"description":"Uploaded","content":{"application/json":{"schema":{"type":"object","properties":{"files":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string","nullable":true}}}},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"413":{"description":"Request too large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"postUploads","x-required-scope":"media:write","x-grem-billing":"free"}},"/api/v1/dictionaries":{"get":{"summary":"Enum dictionaries (code -> label)","description":"Decode the enum codes returned by object endpoints. No lang -> all locales (labels object per code); ?lang= -> flattened { code: label }; ?name= -> one dictionary. Versioned + cacheable. New codes may appear before the bundle is regenerated — tolerate an unknown code (fall back to the raw value).","tags":["dictionaries"],"security":[{"apiKey":[]}],"parameters":[{"name":"lang","in":"query","required":false,"schema":{"type":"string","enum":["en","ru","uk","de","es","az","ar","fr","zh","tr"],"x-case-insensitive":true},"description":"Case-insensitive."},{"name":"name","in":"query","required":false,"schema":{"type":"string"},"description":"Return a single dictionary by name."}],"responses":{"200":{"description":"Dictionaries","content":{"application/json":{"schema":{"type":"object","properties":{"version":{"type":"string"},"lang":{"type":"string"},"dictionaries":{"type":"object","additionalProperties":true},"requestId":{"type":"string"}}}}}},"400":{"description":"Validation error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Invalid or missing API key","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"402":{"description":"Insufficient funds or quota","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"403":{"description":"Missing scope (forbidden_scope) or not allowed for this account/resource (forbidden)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Unknown dictionary name","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Rate limit exceeded — see Retry-After","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Tool temporarily unavailable — see Retry-After; nothing is charged","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"5XX":{"description":"Service error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"operationId":"getDictionaries","x-grem-billing":"free"}}}}