# Create Link Creates a delivery link to be sent to a customer. Links are primarily used for Rendr's **Click and Deliver** product, allowing customers to verify their Click and Collect order exists and book their own delivery for collection. Click and Deliver must be enabled on your account before this endpoint can be used. Contact Rendr's implementation team to provision access. *** ## Endpoint ``` POST {{domain}}/{{tenant_id}}/links ``` **Authentication:** Bearer token required via the `Authorization` header. *** ## Request Payload ```json title="POST /rendr/links" { "store_reference": "Rendr Richmond", "reference": "123456", "expires_at": "2022-03-03T10:00:00+10:00", "customer": { "phone": "0400000000", "email": "status@rendr.delivery", "first_name": "Rendr", "last_name": "Delivery" }, "address": { "address": "7 Howard Street", "address2": "Level 3", "city": "Richmond", "state": "VIC", "post_code": "3121" }, "line_items": [ { "code": "sku-code-001", "name": "SKU Item Name #001", "price_cents": 999, "quantity": 2, "packing_instructions": "" }, { "code": "sku-code-002", "name": "SKU Item Name #002", "price_cents": 1999, "quantity": 2 } ], "parcels": [ { "reference": "Carton", "length_cm": 30, "width_cm": 20, "height_cm": 10, "weight_kg": 3, "quantity": 1 } ] } ``` ## Request Fields ### Top-Level Fields | Field | Type | Required | Description | | ----------------- | ----------------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | `store_reference` | String | Yes | The merchant's internal store reference, preconfigured by your Rendr implementation partner. | | `reference` | String | Yes | Your unique identifier for this link — typically an order number. Used to verify the customer's order at the point of delivery booking. | | `expires_at` | String (ISO 8601) | No | The date and time after which the link will no longer be valid. | ### Customer | Field | Type | Required | Description | | --------------------- | ------ | -------- | ---------------------------------------------------------------------------- | | `customer.first_name` | String | Yes | The recipient's first name. | | `customer.last_name` | String | Yes | The recipient's last name. | | `customer.phone` | String | Yes | The recipient's mobile phone number. Used to send the delivery link via SMS. | | `customer.email` | String | No | The recipient's email address. Used to send the delivery link via email. | ### Address | Field | Type | Required | Description | | ------------------- | ------ | -------- | ------------------------------------------------------- | | `address.address` | String | Yes | The street address of the delivery destination. | | `address.address2` | String | No | Secondary address line (e.g. unit or level). | | `address.city` | String | Yes | The city or suburb of the delivery address. | | `address.state` | String | Yes | The abbreviated state or territory (e.g. `VIC`, `NSW`). | | `address.post_code` | String | Yes | The postcode of the delivery address. | ### Line Items | Field | Type | Required | Description | | ----------------------------------- | ------ | -------- | ------------------------------------------------ | | `line_items[].code` | String | Yes | The SKU or product code for the item. | | `line_items[].name` | String | Yes | The human-readable product name. | | `line_items[].price_cents` | Number | Yes | The unit price in cents (e.g. `999` = \$9.99). | | `line_items[].quantity` | Number | Yes | The number of units of this line item. | | `line_items[].packing_instructions` | String | No | Item-level packing instructions for store staff. | ### Parcels | Field | Type | Required | Description | | --------------------- | ------ | -------- | ------------------------------------------------ | | `parcels[].reference` | String | Yes | A reference to identify the parcel. | | `parcels[].length_cm` | Number | Yes | Length of the parcel in centimetres. | | `parcels[].width_cm` | Number | Yes | Width of the parcel in centimetres. | | `parcels[].height_cm` | Number | Yes | Height of the parcel in centimetres. | | `parcels[].weight_kg` | Number | Yes | Weight of the parcel in kilograms. | | `parcels[].quantity` | Number | Yes | Number of identical parcels at these dimensions. | *** ## Sample Response ```json title="201 Created" { "data": { "id": "oVI32gAE1mWaWeuQ0awJ", "link": "https://rendr.link/oVI32gAE1mWaWeuQ0awJ" } } ``` | Field | Type | Description | | ----------- | ------ | -------------------------------------------------------------------------------------------------------------------- | | `data.id` | String | The unique ID for the created link. | | `data.link` | String | The shareable URL to send to the customer. When opened, the customer can verify their order and book their delivery. |