# Shipping endpoints

# Get shipping rates

Get shipping rates and pickup points available for a specific location.

# Endpoint

GET /cart.js
POST /cart.js

This endpoint is available as both GET and POST. Both has the exact same functionality.

# Parameters

Name Required
country true
zip false

# Examples

Axios request

axios.post('/checkout/shipping.js', {
	country: '208',
	zip: '8660',
})
.then((response) => {
    console.log(response.data)
})
.catch(e => {
    console.log(e.response.data)
})

Successful response

[
    {
        "id": 1655971691228414,
        "name": "Postnord MyPack Home",
        "description": "Postnord MyPack Home",
        "handle": "postnord",
        "price": 3900,
        "price_ex_tax": 3120,
        "min_order_subtotal": null,
        "max_order_subtotal": null,
        "stores": null,
        "countries": [
            {
                "id": 208,
                "name": "Denmark",
                "code": "DK",
                "tax_rate": 2500
            }
        ]
    },
    {
        "id": 1655971502822101,
        "name": "Postnord MyPack Collect",
        "description": "Postnord MyPack Collect",
        "handle": "postnord",
        "price": 1900,
        "price_ex_tax": 1520,
        "min_order_subtotal": null,
        "max_order_subtotal": null,
        "stores": [
            {
                "name": "PAKKEBOKS 672 - SKANDERBORG STATION",
                "longitude": 9.92646,
                "latitude": 56.0436,
                "address_1": "Jernbanevej 9",
                "address_2": "",
                "zip": "8660",
                "city": "Skanderborg",
                "country_code": "DK",
                "state": null,
                "phone": "",
                "drop_point_id": "672",
                "carrier_code": "POSTNORD",
                "created_at": "2020-11-04T01: 01: 00.000Z",
                "updated_at": "2020-11-04T01: 01: 00.000Z",
                "routing_code": null,
                "opening_hours": [
                    {
                        "day": 0,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 1,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 2,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 3,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 4,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 5,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    },
                    {
                        "day": 6,
                        "opens_at": "00: 00",
                        "closes_at": "23: 59"
                    }
                ],
                "carrier": "POSTNORD",
                "country": "DK",
                "id": "672",
                "street": "Jernbanevej 9"
            },
        ],
        "countries": [
            {
                "id": 208,
                "name": "Denmark",
                "code": "DK",
                "tax_rate": 2500
            }
        ]
    }
]