List a deal's offers
Returns every offer on the deal, newest first, each with its versions, newest version first. An offer is a thread of versions: sending a revised version supersedes the one sent before it, and every other offer route acts on one version by its `versionId`. `dealId` is required; leaving it out or sending a malformed id returns 400. A deal from another company returns 404.
Returns every offer on the deal, newest first, each with its versions, newest version first. An offer is a thread of versions: sending a revised version supersedes the one sent before it, and every other offer route acts on one version by its versionId. dealId is required; leaving it out or sending a malformed id returns 400. A deal from another company returns 404.
Authorization
x-api-key Company API key, created under Settings > API Keys.
In: header
Query Parameters
The deal whose offers to list.
^[0-9a-fA-F]{24}$Header Parameters
Optional with an API key or OAuth token: leave it out and the company the key or token belongs to is used. If sent, it must be that same company, otherwise the request is refused with 403 API_KEY_WRONG_COMPANY or OAUTH_WRONG_COMPANY.
^[0-9a-fA-F]{24}$Response Body
application/json
curl -X GET "https://example.com/crm/offers?dealId=string"[ { "id": "string", "latestSentAt": "2019-08-24T14:15:22Z", "number": 0, "title": "string", "versions": [ { "acceptanceDepth": "CLICK", "acceptanceWithdrawnAt": "2019-08-24T14:15:22Z", "authLevel": "LINK_POSSESSION", "decidedAt": "2019-08-24T14:15:22Z", "id": "string", "money": { "incVatOre": 0, "netOre": 0, "vatOre": 0 }, "recipientType": "BUSINESS", "sentAt": "2019-08-24T14:15:22Z", "status": "ACCEPTED", "version": 0 } ] }]List the company's offers GET
Returns one page of the company's offers across every deal, newest first, one row per offer carrying its current version, status, totals, recipient and deal. Without `status` the list leaves out superseded versions. Filter with `search` and `status`, and page with `page` and `pageSize` (at most 100).
Preview an offer draft as a PDF GET
Returns the draft as a PDF watermarked as a preview, so you can check it before sending. Once the version is sent this returns 409 with code `OFFER_NOT_DRAFT`; download the sent document instead.