> For the complete documentation index, see [llms.txt](https://partner-docs.covergenius.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://partner-docs.covergenius.com/offers/vertical-examples/parcel-shipping/confirm-offer.md).

# Confirm Offer

## Confirm Offer

> Finalize the purchase of shipping protection from a previously created Offer. Converts the selected Offer into a confirmed booking after payment has been collected.\
> \
> \## Idempotency\
> \
> This endpoint supports idempotency keys via the \`x-idempotency-key\` header to prevent duplicate transactions.

```json
{"openapi":"3.0.0","info":{"title":"Offers API - Logistics","version":"1.0.0"},"servers":[{"url":"https://api.xcover.com/x"}],"security":[{"CustomAPISignature":[]}],"components":{"securitySchemes":{"CustomAPISignature":{"type":"apiKey","name":"Authorization","in":"header","description":"**Composite Authentication Scheme (Client Key, Date, and Signature)**\n\nThis scheme requires the client to provide **three** mandatory headers in every request:\n\n### 1. X-Api-Key (Client Key)\n* **Purpose:** Public identifier for the API consumer.\n\n### 2. Date (Timestamp)\n* **Purpose:** Timestamp used for generating the signature and preventing replay attacks.\n* **Format:** RFC 7231 format (e.g., in GMT).\n\n### 3. Authorization (Computed Signature)\n* **Purpose:** Cryptographic signature that verifies the request's authenticity and integrity.\n* **Format:** `SIGNATURE [authHeader]`\n\nThe `authHeader` value is derived from a cryptographic hash (e.g., HMAC-SHA256) of canonical request components (HTTP Method, Path, and the contents of the `Date` header), signed with the private **Client Secret**.\n"}}},"paths":{"/partners/{partner_code}/offers/{offer_id}/confirm/":{"post":{"summary":"Confirm Offer","description":"Finalize the purchase of shipping protection from a previously created Offer. Converts the selected Offer into a confirmed booking after payment has been collected.\n\n## Idempotency\n\nThis endpoint supports idempotency keys via the `x-idempotency-key` header to prevent duplicate transactions.","tags":["Confirm Offer"],"parameters":[{"name":"x-idempotency-key","in":"header","required":false,"description":"A unique identifier to ensure idempotent request processing. Keys are stored for 48 hours.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"quotes":{"type":"array","description":"Array of quote objects to confirm","items":{"type":"object","properties":{"id":{"type":"string","description":"The product ID (quote ID) from the offer response"}},"required":["id"]}},"policyholder":{"type":"object","description":"Policyholder information. For logistics, this is typically the shipment receiver.","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"email":{"type":"string","format":"email"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postcode":{"type":"string"},"region":{"type":"string"},"country":{"type":"string"}},"required":["first_name","last_name","email","country"]}},"required":["quotes","policyholder"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string"},"currency":{"type":"string"},"total_price":{"type":"number"},"total_price_formatted":{"type":"string"},"partner_transaction_id":{"type":"string","nullable":true},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"pds_url":{"type":"string","format":"uri"},"security_token":{"type":"string"},"quotes":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"policy_start_date":{"type":"string","format":"date-time"},"policy_end_date":{"type":"string","format":"date-time","nullable":true},"status":{"type":"string"},"price":{"type":"number"},"price_formatted":{"type":"string"},"policy":{"type":"object","properties":{"policy_type":{"type":"string"},"policy_type_version":{"type":"string"},"policy_type_slug":{"type":"string"},"policy_type_group_name":{"type":"string"},"policy_name":{"type":"string"},"policy_code":{"type":"string"},"policy_version":{"type":"string"},"category":{"type":"string"},"policy_currency":{"type":"string"}}},"tax":{"type":"object","properties":{"total_tax":{"type":"number","nullable":true},"total_amount_without_tax":{"type":"number","nullable":true},"total_tax_formatted":{"type":"string","nullable":true},"total_amount_without_tax_formatted":{"type":"string","nullable":true}}},"benefits":{"type":"array","items":{"type":"object","additionalProperties":true}},"commission":{"type":"object","properties":{"partner_commission":{"type":"number","nullable":true},"total_commission":{"type":"number","nullable":true},"partner_commission_formatted":{"type":"string","nullable":true},"total_commission_formatted":{"type":"string","nullable":true}}},"created_at":{"type":"string","format":"date-time"},"confirmed_at":{"type":"string","format":"date-time"},"pds_url":{"type":"string","format":"uri"},"can_be_cancelled":{"type":"boolean"}}}},"coi":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"pdf":{"type":"string","format":"uri"}}},"policyholder":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"email":{"type":"string","format":"email"},"country":{"type":"string"}}},"total_tax":{"type":"number"},"total_tax_formatted":{"type":"string"},"total_premium":{"type":"number"},"total_premium_formatted":{"type":"string"},"fnol_link":{"type":"string","format":"uri"}}}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string"},"message":{"type":"string"}}}}}},"409":{"description":"Conflict - Duplicate Request (Idempotent)","content":{"application/json":{"schema":{"type":"object"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string"},"message":{"type":"string"},"errors":{"type":"array","items":{"type":"string"}}}}}}},"423":{"description":"Locked - Request In Progress","content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string"},"message":{"type":"string"}}}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://partner-docs.covergenius.com/offers/vertical-examples/parcel-shipping/confirm-offer.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
