Fluid Commerce APIs (1.0)

The Fluid Commerce APIs provides a comprehensive set of APIs designed to integrate Fluid's powerful services into your applications seamlessly. This bundle offers robust functionality for enhancing messaging solutions, streamlining data management, and improving customer interactions. With detailed documentation, secure authentication, and flexible integration options, the Fluid Public API Bundle is engineered to help you leverage our services efficiently and effectively, unlocking new potentials and achieving greater connectivity within your systems.

Download OpenAPI description
Overview
E-mail support@fluid.app
License MIT
Languages
Servers
Mock server
https://docs.fluid.app/_mock/docs/apis/swagger/
Production server with company subdomain
https://{company}.fluid.app/
Local development server
http://fluid.lvh.me:{port}/

Agreements

Operations

ApplePay

Operations

Application Themes

Operations

ApplicationThemeTemplates

Operations

Authentication

Operations

Callback Definitions

Operations

Callback Registrations

Operations

Carts

Operations

Creates a cart

Request

Create a cart. Items, attribution, immutable_items, order_confirmation_url, and enrollment_pack_id are optional.

Headers
Cookiestring

Session cookie (_fluid_session)

Bodyapplication/json

Cart params

country_codestringrequired

ISO 2-letter country code

Example: "US"
visitor_tokenstring

Visitor token. DEPRECATED: Will be removed in a future version; please use session_uuid instead

Example: "vt_2a3v3f9s8xRCN"
session_uuidstring

Session UUID

Example: "0195ff0f-9a6c-70e1-9037-f42bfd23b5fb"
itemsArray of objects
immutable_itemsboolean

Whether the cart is immutable

Default false
Example: true
fluid_shopstringrequired

The domain of your Fluid shop (excluding the scheme)

Example: "myco.fluid.app"
attributionobject or object or object or object or object
Default {"id":456,"share_guid":"james-bond007"}
One of:
order_confirmation_urlstring

The URL of a custom Order Confirmation Page to send customers to after the order is approved.

Example: "https://myco.fluid.app/pages/order-confirmation?token={order_token}"
curl -i -X POST \
  https://docs.fluid.app/_mock/docs/apis/swagger/api/carts \
  -H 'Content-Type: application/json' \
  -H 'Cookie: string' \
  -d '{
    "country_code": "US",
    "visitor_token": "vt_2a3v3f9s8xRCN",
    "session_uuid": "0195ff0f-9a6c-70e1-9037-f42bfd23b5fb",
    "items": [
      {
        "variant_id": 90,
        "quantity": 2,
        "display_to_customer": true
      }
    ],
    "immutable_items": true,
    "fluid_shop": "myco.fluid.app",
    "attribution": {
      "id": 456,
      "share_guid": "james-bond007"
    },
    "order_confirmation_url": "https://myco.fluid.app/pages/order-confirmation?token={order_token}"
  }'

Responses

cart created with enrollment_pack_id

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Updates cart address

Request

Path
cart_tokenstringrequired
Bodyapplication/json
typestring
Enum"ship_to""bill_to"
Example: "bill_to"
jwtstring or null
Example: "eyJhbGciO1NiJ9.eyJhdXcyNjN9.AZ-4PAgFwVyGp"
address_idinteger or null
Example: 456
addressobject or null
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/address' \
  -H 'Content-Type: application/json' \
  -d '{
    "type": "bill_to",
    "jwt": "eyJhbGciO1NiJ9.eyJhdXcyNjN9.AZ-4PAgFwVyGp",
    "address_id": 456,
    "address": {
      "id": 456,
      "first_name": "John",
      "last_name": "Doe",
      "address1": "123 Main St",
      "city": "Anytown",
      "state": "CA",
      "postal_code": "12345",
      "country_code": "US"
    }
  }'

Responses

address updated with address id

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Retrieves a cart

Request

Path
cart_tokenstringrequired
Query
payment_methods_includesstring
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}?payment_methods_includes=string'

Responses

cart found

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Updates a cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
emailstring(email)
phonestring
Example: "4035551212"
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}' \
  -H 'Content-Type: application/json' \
  -d '{
    "email": "user@example.com",
    "phone": "4035551212"
  }'

Responses

cart updated with phone number validation

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Applies a discount to the cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
discount_codestring
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/discount' \
  -H 'Content-Type: application/json' \
  -d '{
    "discount_code": "string"
  }'

Responses

discount code not found

Bodyapplication/json
error_messagestring
Example: "not found"
errorsobject
metaobject
Response
application/json
{ "error_message": "not found", "errors": { "property1": [], "property2": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Remove discount from the cart

Request

Path
cart_tokenstringrequired
discount_codestringrequired
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/discount/{discount_code}'

Responses

discount removed

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Adds items to cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
itemsArray of objectsrequired

Either send in [variant_id, quantity] - or [title, price, quantity]

items[].​variant_idinteger

ID of the variant to add to cart

items[].​quantityintegerrequired

Quantity of the item to add

items[].​titlestring

Title for custom items without variants

items[].​pricenumber or string

Price for custom items without variants

items[].​subscriptionboolean

allow subscription for item

Example: false
items[].​enrollment_pack_idinteger

ID of the enrollment pack to add to cart item

curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/items' \
  -H 'Content-Type: application/json' \
  -d '{
    "items": [
      {
        "variant_id": 0,
        "quantity": 0,
        "title": "string",
        "price": 0,
        "subscription": false,
        "enrollment_pack_id": 0
      }
    ]
  }'

Responses

item does not remove enrollment_pack_id if edited

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Removes items from cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
itemsArray of objectsrequired
items[].​variant_idintegerrequired
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/items' \
  -H 'Content-Type: application/json' \
  -d '{
    "items": [
      {
        "variant_id": 0
      }
    ]
  }'

Responses

items removed from cart

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Removes item from cart

Request

Path
cart_tokenstringrequired
item_idstringrequired
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/items/{item_id}'

Responses

item removed from cart

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Retrieves enroll for cart

Request

Path
cart_tokenstringrequired
Query
placementstring
Default "all"
Enum"pre_purchase""post_purchase""all"
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/enroll?placement=pre_purchase'

Responses

enroll fields found

Bodyapplication/json
enrollobject
metaobject
Response
application/json
{ "enroll": { "id": 1, "active": true, "default": false, "title": "Customer Details", "fields": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Sets cart payment method

Request

Path
cart_tokenstringrequired
typestringrequired

Type of payment method

Value"credit_card"
Query
jwtstring

JWT token to authenticate (Optional, if payment method id is not provided)

payment_method_idinteger

Payment Method id (Optional)

Bodyapplication/jsonrequired
billing_postal_codestring

Billing postal code

Example: "123"
payment_methodobjectrequired
payment_method.​tokenstring

Payment method token from Spreedly

payment_method.​last_fourstring

Last 4 digits of credit card

payment_method.​card_typestring

Type of credit card (visa, mastercard, etc)

payment_method.​exp_monthstring

Expiration month (MM)

payment_method.​exp_yearstring

Expiration year (YYYY)

curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/payment_methods/{type}?jwt=string&payment_method_id=0' \
  -H 'Content-Type: application/json' \
  -d '{
    "billing_postal_code": "123",
    "payment_method": {
      "token": "string",
      "last_four": "string",
      "card_type": "string",
      "exp_month": "string",
      "exp_year": "string"
    }
  }'

Responses

payment method added

Bodyapplication/json
cardobjectrequired
card.​user_idstring or null
Example: "123"
card.​spreedly_tokenstring
Example: "01JKFTVM6Z44YFPSS9KK36KMSV"
card.​full_namestring
Example: "John Doe"
card.​monthinteger
Example: 3
card.​yearinteger
Example: 2032
card.​numberstring
Example: "XXXX-XXXX-XXXX-4444"
card.​last_four_digitsstring
Example: "4444"
card.​first_six_digitsstring or null
Example: "555555"
card.​card_typestring
Example: "master"
card.​address_idstring or null
Example: "123"
card.​fingerprintstring or null
Example: "6eb05c4c7fc52fec38ef6e0651e8225be41c"
card.​defaultboolean
Example: false
card.​activeboolean
Example: true
card.​created_atstring(date-time)
Example: "2021-01-01T00:00:00Z"
card.​updated_atstring(date-time)
Example: "2021-01-01T00:00:00Z"
card.​fluidboolean
Example: true
card.​testboolean or null
Example: true
card.​emailstring or null
Example: "john@example.com"
card.​customer_idstring or null
Example: "123"
card.​fluid_pay_account_idstring or null
Example: "123"
Response
application/json
{ "card": { "user_id": "123", "spreedly_token": "01JKFTVM6Z44YFPSS9KK36KMSV", "full_name": "John Doe", "month": 3, "year": 2032, "number": "XXXX-XXXX-XXXX-4444", "last_four_digits": "4444", "first_six_digits": "555555", "card_type": "master", "address_id": "123", "fingerprint": "6eb05c4c7fc52fec38ef6e0651e8225be41c", "default": false, "active": true, "created_at": "2021-01-01T00:00:00Z", "updated_at": "2021-01-01T00:00:00Z", "fluid": true, "test": true, "email": "john@example.com", "customer_id": "123", "fluid_pay_account_id": "123" } }

Sets cart shipping method

Request

Path
cart_tokenstringrequired
Bodyapplication/json
shipping_method_idintegerrequired

ID of the shipping method to use

Example: 10
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/shipping_method' \
  -H 'Content-Type: application/json' \
  -d '{
    "shipping_method_id": 10
  }'

Responses

shipping method set

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Completes cart checkout

Request

Path
cart_tokenstringrequired
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/checkout'

Responses

checkout completed

Bodyapplication/json
orderobject
metaobject
Response
application/json
{ "order": { "id": 0, "first_name": "string", "last_name": "string", "email": "string", "phone": "string", "order_number": "string", "token": "string", "status": "string", "order_type": "string", "amount": "string", "refundable_amount": 10.5, "note": {}, "recurring": [], "order_confirmation_url": "string", "currency_code": "string", "created_at": "string", "updated_at": "string", "metadata": {} }, "meta": { "request_id": "f5473a8c-8a86-4e0e-b3e8-95392003921b", "timestamp": "2024-12-10T08:04:10Z", "shop_url": "https://example.com" } }

Retrieves cart company information

Request

Path
cart_tokenstringrequired
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/cart_info'

Responses

company info found

Bodyapplication/json
languagesArray of objects
countriesArray of objects
Response
application/json
{ "languages": [ {} ], "countries": [ {} ] }

Updates the language of a cart

Request

Path
cart_tokenstringrequired
Bodyapplication/jsonrequired

List of valid iso are at /api/carts/{cart_token}/cart_info

language_isostring
Example: "en"
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/change_language' \
  -H 'Content-Type: application/json' \
  -d '{
    "language_iso": "en"
  }'

Responses

cart's language_iso changed

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Updates the country of a cart, also updates the currency code

Request

Path
cart_tokenstringrequired
Bodyapplication/json

ISO country code to update the cart to

country_codestringrequired
Example: "US"
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/update_country' \
  -H 'Content-Type: application/json' \
  -d '{
    "country_code": "US"
  }'

Responses

cart's country and currency code changed

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Add enrollment to existing cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
enrollment_pack_idintegerrequired
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/enrollment' \
  -H 'Content-Type: application/json' \
  -d '{
    "enrollment_pack_id": 0
  }'

Responses

Enrollment pack added to cart

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Adds subscribe:true to cart item

Request

Path
cart_tokenstringrequired
item_idstringrequired
Query
subscription_plan_idinteger

ID of the subscription plan to use

Example: subscription_plan_id=123
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/items/{item_id}/subscribe?subscription_plan_id=0'

Responses

subscription true updated

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Updates subscribe:false to cart item

Request

Path
cart_tokenstringrequired
item_idstringrequired
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/items/{item_id}/subscribe'

Responses

subscription false updated

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Removes rep_buyer and customer for the cart

Request

Path
cart_tokenstringrequired
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/logout'

Responses

Logout sucessful

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z", "checkout_url": "https://checkout.fluid.com/checkout?jwt=abc123", "shop_url": "https://myco.fluid.app" } }

Updates cart attribution

Request

Updates attribution data for a cart

Path
cart_tokenstringrequired
Bodyapplication/json
attributionobject or object or object or objectrequired
One of:
attribution.​share_guidstringrequired
Example: "james-bond007"
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/attribution' \
  -H 'Content-Type: application/json' \
  -d '{
    "attribution": {
      "share_guid": "james-bond007"
    }
  }'

Responses

attribution updated

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Updates the buyer rep for the cart

Request

Updates the buyer rep of a cart based on the provided customer_id

Path
cart_tokenstringrequired
Bodyapplication/json
customer_idintegerrequired

ID of the customer to set as buyer rep

Example: 123
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/swagger/api/carts/{cart_token}/buyer_rep' \
  -H 'Content-Type: application/json' \
  -d '{
    "customer_id": 123
  }'

Responses

buyer rep updated

Bodyapplication/json
cartobject
metaobject
Response
application/json
{ "cart": { "id": 123, "state": "start", "processed": false, "valid_for_checkout": true, "buyer_rep_id": 1, "currency_symbol": "$", "currency_code": "USD", "shipping_total_for_display": "Free", "phone": "4035551212", "attribution": {}, "agreements": [], "amount_total": "121.65", "amount_total_in_currency": "$121.65 (USD)", "sub_total": "100.00", "sub_total_in_currency": "$100.00 (USD)", "tax_total": "20.00", "tax_total_in_currency": "$20.00 (USD)", "shipping_total": "1.65", "shipping_total_in_currency": "$1.65 (USD)", "discount_total": "2.99", "discount_total_in_currency": "$2.99 (USD)", "transaction_fee": "1.90", "transaction_fee_in_currency": "$1.90 (USD)", "cv_total": 10, "qv_total": 15, "company": {}, "payment_method": {}, "email": "user@example.com", "enrollment_fee": "10.45", "enrollment_fee_in_currency": "$10.45", "discount_code": "DISCOUNT10", "language_iso": "en", "cart_token": "abc123", "immutable_items": false, "digital_only": false, "items": [], "ship_to": {}, "bill_to": {}, "shipping_method": {}, "available_shipping_methods": [], "available_payment_methods": [], "country": {}, "type": "regular", "enrollment_pack_id": 1, "enrollment_pack": {}, "recurring": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Company Custom Catch Ups

Operations

Company Discounts

Operations

Company Droplets

Operations

Company Pages

Operations

Company Popups

Operations

Company Settings - Checkout

Operations

Company Settings - Countries

Operations

Company Settings - Languages

Operations

Company Settings - Social Media

Operations

Company Settings - Warehouses

Operations

Contacts

Operations

Currencies

Operations

Customer Orders

Operations

CustomerNotes

Operations

Customers

Operations

Domains

Operations

Drop Zones

Operations

Droplets

Operations

Enrollment Packs

Operations

Enrollments

Operations

Fantasy Points

Operations

Fluid Pay

Operations

GlobalEmbeds

Operations

Inventory Levels

Operations

Multi-Factor Authentications

Operations

Notifications

Operations

Order Fulfillments

Operations

Orders

Operations

Pages

Operations

Payment

Operations

Payment Accounts

Operations

Payments

Operations

Paypal

Operations

Products

Operations

Public Companies

Operations

Redirects

Operations

Refunds

Operations

Roles

Operations

Shares

Operations

Subscription Orders

Operations

Subscription Plans

Operations

Subscriptions

Operations

Tracking Informations

Operations

Tree Nodes

Operations

Trees

Operations

Users

Operations

Variant Countries

Operations

Webhooks

Operations

returns a list of all droplet categories

Request

curl -i -X GET \
  https://docs.fluid.app/_mock/docs/apis/swagger/api/droplet_categories \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

returns a list of droplet categories

Bodyapplication/json
droplet_categoriesArray of objects(DropletCategory)
metaobject
Response
application/json
{ "droplet_categories": [ {} ], "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }