> ## Documentation Index
> Fetch the complete documentation index at: https://developers.firmly.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Configure shipment fulfillment and delivery options

The Shipment Configuration API provides endpoints to manage how shipments are fulfilled and delivered.

## Overview

This API allows you to:

* **Set Fulfillment Type**: Configure how a shipment will be fulfilled (standard shipping, scheduled delivery, or in-store pickup)
* **Set Shipping Method**: Select shipping options for standard delivery
* **Get Availability**: Query available dates and time slots for scheduled delivery

## Available Endpoints

<CardGroup cols={3}>
  <Card title="Set Fulfillment Type" href="/api-reference/shipment-configuration/set-fulfillment-type" icon="building">
    Configure how each shipment will be fulfilled
  </Card>

  <Card title="Set Shipping Method" href="/api-reference/shipment-configuration/set-shipping-method" icon="truck">
    Select shipping method for standard delivery
  </Card>

  <Card title="Get Availability" href="/api-reference/shipment-configuration/get-availability" icon="calendar">
    Check available dates for scheduled delivery
  </Card>
</CardGroup>

## Fulfillment Types

Each shipment can be configured with one of these fulfillment types:

### SHIP\_TO\_ADDRESS

Standard shipping to customer's address. Requires shipping method selection.

### SCHEDULED\_DELIVERY

Delivery with appointment scheduling. Supports date and time slot selection via the availability endpoint.

### IN\_STORE\_PICKUP

Customer pickup at store location (availability depends on merchant support).

## Workflow

<Steps>
  <Step title="Get Cart">
    Retrieve the cart to see current shipments and their fulfillment options
  </Step>

  <Step title="Set Fulfillment Type">
    Configure each shipment's fulfillment type based on available options
  </Step>

  <Step title="Configure Delivery">
    * For `SHIP_TO_ADDRESS`: Set shipping method
    * For `SCHEDULED_DELIVERY`: Get availability, then set delivery date/time
    * For `IN_STORE_PICKUP`: Select pickup location (if applicable)
  </Step>
</Steps>

## Default Selection Behavior

<Info>
  **Automatic Defaults**: When a cart is created or shipping information is set, Firmly automatically:

  * Selects a default fulfillment type for each shipment
  * Chooses the cheapest available shipping method for standard shipping

  This ensures the cart always has valid shipping configuration without requiring explicit selection.
</Info>

## Important Notes

<Warning>
  The **Get Availability** endpoint only works for shipments configured with `SCHEDULED_DELIVERY` fulfillment type. It's not a general availability check endpoint.
</Warning>

<Note>
  Shipments are created and grouped by the merchant's system based on their fulfillment rules. Firmly provides a standardized interface to configure these merchant-defined shipments.
</Note>
