Skip to main content
POST
/
carts
Create cart
curl --request POST \
  --url https://api.crevio.co/v1/carts \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "cart": {
    "customerId": 123
  }
}
'
{
  "prefixId": "<string>",
  "currency": "<string>",
  "total": 123,
  "isFree": true,
  "cartItems": [
    {
      "id": 123,
      "quantity": 123,
      "priceVariant": {
        "id": 123,
        "name": "<string>",
        "amount": 123,
        "currency": "<string>",
        "billingType": "one_time",
        "amountType": "<string>",
        "discountedFromAmount": 123,
        "presetAmount": 123,
        "minimumAmount": 123,
        "maximumAmount": 123,
        "recurringInterval": "<string>",
        "intervalCount": 123,
        "trialPeriodDays": 123,
        "revokeAfterDays": 123,
        "hidden": true,
        "archived": true,
        "waitlist": true,
        "position": 123,
        "prefixId": "<string>",
        "benefits": [
          "<string>"
        ],
        "seatQuantity": 123,
        "isDefault": true,
        "isPayWhatYouWant": true,
        "hasFreeTrial": true,
        "isQuantityLimited": true
      },
      "product": {
        "id": 123,
        "name": "<string>",
        "slug": "<string>",
        "prefixId": "<string>",
        "url": "<string>"
      }
    }
  ],
  "sellerAccount": {
    "id": 123,
    "name": "<string>",
    "subdomain": "<string>",
    "avatar": {
      "filename": "<string>",
      "contentType": "<string>",
      "byteSize": 123,
      "createdAt": "2023-11-07T05:31:56Z",
      "signedId": "<string>",
      "src": "<string>",
      "srcSet": "<string>"
    },
    "linkInBioPage": {
      "id": 123,
      "title": "<string>",
      "description": "<string>"
    },
    "socialLinks": [
      {
        "id": 123,
        "name": "<string>",
        "url": "<string>",
        "platform": "<string>",
        "position": 123,
        "active": true
      }
    ],
    "referralUrl": "<string>",
    "availableSupportEmail": "<string>"
  }
}

Authorizations

Authorization
string
header
required

API key in the format: Bearer {api_token}

Body

application/json
cart
object

Response

Cart created

prefixId
string
currency
string | null
total
integer

Total in cents

isFree
boolean
cartItems
object[]
sellerAccount
object