Orders

Retrieve order information

GET /order/$id

Query Parameters

Name
Type
Description

id*

String

Order ID

{
    "status": "ok",
    "response": {
        "order": {
            "id": "EA8",
            "store": {
                "name": "My TeSt StOrE",
                "order_id": "000000027"
            },
            "status": {
                "code": "F",
                "label": "Fulfilled",
                "since": "2030-05-11 13:19"
            },
            "addresses": {
                "billing": {
                    "fname": "Chris",
                    "name": "Jansen",
                    "street": "Hoofdstraat",
                    "streetNr": "95",
                    "streetNrExt": "",
                    "postcode": "1234 AB",
                    "city": "Amsterdam",
                    "country": "NL",
                    "email": "[email protected]",
                    "phone": "0000000000"
                },
                "shipping": {
                    "fname": "Chris",
                    "name": "Jansen",
                    "street": "Hoofdstraat",
                    "streetNr": "95",
                    "streetNrExt": "",
                    "postcode": "1234 AB",
                    "city": "Amsterdam",
                    "country": "NL",
                    "email": "[email protected]",
                    "phone": "0000000000"
                }
            },
            "line_items": [
                {
                    "sku": "RS155M-30-L",
                    "name": "RS155M-30-L",
                    "thumb": "",
                    "image": "",
                    "status": "fulfilled",
                    "options": [
                        {
                            "code": "dtg",
                            "attributes": [
                                {
                                    "name": "src",
                                    "value": "https://test1234.com/mydesign.png",
                                    "source": "user"
                                },
                                {
                                    "name": "preview",
                                    "value": "https://test1234.com/a-preview-of-the-design.png",
                                    "source": "user"
                                },
                                {
                                    "name": "position",
                                    "value": "front",
                                    "source": "user"
                                },
                                {
                                    "name": "qty",
                                    "value": 1,
                                    "source": "default"
                                },
                                {
                                    "name": "offsetX",
                                    "value": -1,
                                    "source": "default"
                                },
                                {
                                    "name": "offsetY",
                                    "value": -1,
                                    "source": "default"
                                },
                                {
                                    "name": "dpi",
                                    "value": 150,
                                    "source": "default"
                                },
                                {
                                    "name": "pallet",
                                    "value": "Standard Pallet",
                                    "source": "default"
                                }
                            ],
                            "status": "fulfilled",
                            "source": "api",
                            "sort_order": 2000
                        }
                    ]
                }
            ],
            "transactions": [
             {
                 "items": [
                     {
                         "ID": 47891,
                         "qty": "1.0000",
                         "sku": "RS155M-30-L",
                         "total": "5.7600"
                     },
                     {
                         "ID": 47892,
                         "qty": "1.0000",
                         "sku": "ISF-EU-T-T",
                         "total": "4.7800"
                     }
                 ],
                 "transaction": {
                     "ID": "21895",
                     "date": "07-12-2030 15:30",
                     "orderRef": "EA8",
                     "total": "10.5400"
                 },
                 "invoice": {
                     "ID": 6389
                 }
             }
             ],
                "shipments": [
                {
                    "status": {
                        "code": "N",
                        "label": "New"
                    },
                    "tracking": {
                        "code": "3SCEBU5051344513",
                        "url": "https://jouw.postnl.nl/track-and-trace/3SCEBU5051344513-NL-1234AB"
                    }
                }
            ]
        }
    }
}

Create new order

POST https://api.cottoncast.com/order

This endpoint allows you to create a new order.

Headers

Name
Type
Description

Authentication

string

Basic Authentication

Request Body

Name
Type
Description

items

object

Products you want to order

shipping

object

Shipping address

billing

object

Billing address

order_ref

string

Your order reference

store

string

ID of the sales channel

Last updated

Was this helpful?