Fluid Company APIs (1.0)

The Fluid Company APIs provide a comprehensive set of APIs designed to integrate Fluid's powerful services into your applications seamlessly. These APIs use Company API tokens for authentication and provide full access to manage your company's resources including users, orders, products, media, and more.

For APIs that authenticate with User tokens, see the Rep APIs documentation.

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

Activities

Operations

Admins

Operations

Agreements

Operations

Announcements

Operations

ApplePay

Operations

Application Theme Resources

Operations

Application Theme Templates

Operations

Application Themes

Operations

Authentication

Operations

Bank Accounts

Operations

Brand Guidelines

Operations

Business Types

Operations

Callback Definitions

Operations

Callback Registrations

Operations

Callback Schemas

Operations

Carts

Operations

Catch Ups

Operations

Categories

Operations

Checkout

Operations

Collections

Operations

Companies

Operations

Company Countries

Operations

Contacts

Operations

Conversations

Operations

Countries

Operations

Currencies

Operations

Customer Notes

Operations

Customer Orders

Operations

Customers

Operations

DAM Query

Operations

Dam

Operations

Default MySites

Operations

Devices

Operations

Discounts

Operations

Display Settings

Operations

Domains

Operations

Drop Zones

Operations

Droplet Categories

Operations

Droplet Installations

Operations

Droplets

Operations

Enrollment Packs

Operations

Enrollments

Operations

Entities

Operations

Events

Operations

FairShare Order Journey

Operations

Feature Flags

Operations

File Resources

Operations

Fluid Pay

Operations

Form Elements

Operations

Forms

Operations

Global Embeds

Operations

Inventory Levels

Operations

Labels

Operations

Languages

Operations

Libraries

Operations

MCC Codes

Operations

Media

Operations

Messages

Operations

Metafield Definitions

Operations

Metafields

Operations

Mobile Widgets

Operations

Multi-Factor Authentications

Operations

Notifications

Operations

Onboarding

Operations

Onboarding Info

Operations

Order Fulfillments

Operations

Orders

Operations

Owners

Operations

Pages

Operations

Payment

Operations

Payment Accounts

Operations

Payment Integrations

Operations

Payments

Operations

Paypal

Operations

Points

Operations

Points Ledgers

Operations

Points Values

Operations

Posts

Operations

Product Bundles

Operations

Product Images

Operations

Product Subscription Plans

Operations

Products

Operations

Prompts

Operations

Public Assets

Operations

Public Companies

Operations

Public Drop Zones

Operations

Ranks

Operations

Recipients

Operations

Redirects

Operations

Refunds

Operations

Reps

Operations

Roles

Operations

Root Themes

Operations

Shares

Operations

Shop

Operations

Sitemap

Operations

Social Media

Operations

Subscription Plans

Operations

Subscriptions

Operations

System Monitoring

Operations

Tags

Operations

Tax Categories

Operations

Theme Region Rules

Operations

Tiles

Operations

Tracking Informations

Operations

Tree Nodes

Operations

Trees

Operations

Users

Operations

Variant Countries

Operations

Variant Images

Operations

Variant Inventory Levels

Operations

Variants

Operations

Warehouses

Operations

Webhook Events

Operations

Webhook Schemas

Operations

Webhooks

Operations

Webhooks Resources

Operations

affiliate

Operations

carts

Operations

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
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/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_id": 1,
      "country_code": "US"
    },
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

address updated with address id

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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/company.api/api/public/v2025-06/commerce/carts/{cart_token}/checkout'

Responses

checkout completed

Bodyapplication/json
orderobject(CheckoutOrder)
metaobject(CartShopMetadata)
Response
application/json
{ "order": { "id": 0, "first_name": "string", "last_name": "string", "email": "string", "phone": "string", "order_number": "string", "token": "string", "status": "string", "order_status": "string", "financial_status": "string", "fulfillment_status": "string", "warehouse_id": 0, "order_type": "string", "amount": "string", "amount_in_base": "string", "base_to_currency_rate": "string", "refundable_amount": 0, "note": "string", "recurring": [], "order_confirmation_url": "https://myco.fluid.app/pages/order-confirmation?token={order_token}", "currency_code": "string", "created_at": "string", "updated_at": "string", "metadata": {}, "external_id": "string", "enrollment_pack": {}, "source": "web", "split_payment": {}, "points_applied": 500, "points_applied_amount_in_currency": 5, "order_total_after_points_redemption": 95, "free_shipping": false, "discount_codes": [] }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "shop_url": "https://myco.fluid.app", "timestamp": "2021-01-01T00:00:00Z" } }

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"
metadataobject(RequestMetadataOptional)
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/update_country' \
  -H 'Content-Type: application/json' \
  -d '{
    "country_code": "US",
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

cart's country and currency code changed

Bodyapplication/json
cartobject(Cart)
metaobject(CartMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Applies a discount to the cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
discount_codestring
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/discount' \
  -H 'Content-Type: application/json' \
  -d '{
    "discount_code": "string",
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

discount applied

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
Enum"pre_purchase""post_purchase""all"
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/enroll?fluid_session=string&fluid_shop=string&placement=pre_purchase'

Responses

enroll fields found

Bodyapplication/json
enrollobject
metaobject(CartMetadata)
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" } }

Add enrollment to existing cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
enrollment_pack_idintegerrequired
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/enrollment' \
  -H 'Content-Type: application/json' \
  -d '{
    "enrollment_pack_id": 0,
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

Enrollment pack added to cart

Bodyapplication/json
cartobject(Cart)
metaobject(CartMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "meta": { "request_id": "123e4567-e89b-12d3-a456-426614174000", "timestamp": "2021-01-01T00:00:00Z" } }

Retrieves cart company information

Request

Path
cart_tokenstringrequired
Query
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/cart_info?fluid_session=string&fluid_shop=string'

Responses

company info found

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

Adds items to cart

Request

Path
cart_tokenstringrequired
Bodyapplication/json
itemsArray of objectsrequired
items[].​variant_idintegerrequired
items[].​quantityintegerrequired
items[].​subscriptionboolean
Default false
items[].​subscription_plan_idinteger or null
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/items' \
  -H 'Content-Type: application/json' \
  -d '{
    "items": [
      {
        "variant_id": 0,
        "quantity": 0,
        "subscription": false,
        "subscription_plan_id": 0
      }
    ],
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

items added to cart

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
Query
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/items/{item_id}?fluid_session=string&fluid_shop=string'

Responses

cart item removed from cart

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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 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
Bodyapplication/json
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/items/{item_id}/subscribe?subscription_plan_id=0' \
  -H 'Content-Type: application/json' \
  -d '{
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

subscription true updated

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
Query
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/items/{item_id}/subscribe?fluid_session=string&fluid_shop=string'

Responses

subscription false updated

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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 language of a cart

Request

Path
cart_tokenstringrequired
Bodyapplication/jsonrequired

List of valid iso are at /api/public/v2025-06/commerce/carts/{cart_token}/cart_info

language_isostringrequired
Example: "en"
metadataobject(RequestMetadataOptional)
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/change_language' \
  -H 'Content-Type: application/json' \
  -d '{
    "language_iso": "en",
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

cart's language_iso changed

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
Query
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X DELETE \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/logout?fluid_session=string&fluid_shop=string'

Responses

Logout successful

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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" } }

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/json
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)

metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/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"
    },
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

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_idinteger 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"
card.​token_providerstring or null
Example: "vgs"
card.​tokenstring or null
Example: "01JKFTVM6Z44YFPSS9KK36KMSV"
card.​cvv_tokenstring or null
Example: "411"
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", "token_provider": "vgs", "token": "01JKFTVM6Z44YFPSS9KK36KMSV", "cvv_token": "411" } }

Sets cart shipping method

Request

Path
cart_tokenstringrequired
Bodyapplication/json
shipping_method_idstringrequired

ID of the shipping method to use

Example: "fluid-shipping"
metadataobject(RequestMetadataOptional)
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/shipping_method' \
  -H 'Content-Type: application/json' \
  -d '{
    "shipping_method_id": "fluid-shipping",
    "metadata": {
      "fluid_shop": "myshop",
      "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
      "fluid_locale": "en_US",
      "attribution": {
        "email": "salesrep@example.com"
      }
    }
  }'

Responses

shipping method set

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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 item's variant

Request

Updates a cart item to use a different variant. If the target variant already exists in another cart item, the quantities are consolidated.

Consolidation behavior:

  • If cart already has an item with the target variant_id, the source item's quantity is added to the existing item
  • The source item is then removed
  • Otherwise, the cart item's variant is updated directly

Optional quantity parameter:

  • If provided, uses this quantity instead of the current cart item quantity when updating to a new variant
  • When consolidating, this quantity is added to the existing item's quantity (not replacing it)
Path
cart_tokenstringrequired

The cart token

Example: abc123def456
item_idintegerrequired

The cart item ID

Example: 123
Bodyapplication/jsonrequired

Variant update parameters

variant_idintegerrequired

The new variant ID to assign to this cart item

Example: 456
quantityinteger

Optional: Override the quantity (must be >= 1)

Example: 2
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}/items/{item_id}/variant' \
  -H 'Content-Type: application/json' \
  -d '{
    "variant_id": 456,
    "quantity": 2
  }'

Responses

Variant updated successfully

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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" } }

Creates a cart

Request

Create a cart. Items, attribution and enrollment_pack_id are optional. Buyer rep assignment follows this priority: 1. If JWT is provided, extracts user from JWT and assigns as the rep. 2. If session cookie is present, extracts user from session and assigns it as the rep. 3. If no authentication is provided, cart is created without a rep. When authenticated as a rep, the cart will include rep-specific pricing.

Query
jwtstring

JWT token for user authentication. When provided, extracts user and assigns it as the rep to the cart.

Example: jwt=eyJhbGciOiJIUzI1NiJ9.eyJhdXRoX3R5cGUiOiJ1c2VyX2NvbXBhbnkiLCJpZCI6MTIzfQ...
Headers
Cookiestring

Session cookie (_fluid_session)

Bodyapplication/json

Cart params

country_codestringrequired

ISO 2-letter country code

Example: "US"
fluid_shopstringrequired

The domain of your Fluid shop (excluding the scheme)

Example: "myco.fluid.app"
fluid_sessionstring

Session token

Example: "fs_szwdDuRbqEe7AV7sXk7vVq"
visitor_tokenstring

Visitor token

Example: "vt_2a3v3f9s8xRCN"
sourcestring

The source that created the cart

Enum"web""mobile""external""admin"
Example: "web"
itemsArray of objects
attributionAttributionEmail (object) or AttributionUsername (object) or AttributionSharedGuid (object) or AttributionFluidRepId (object) or AttributionExternalId (object)(Attribution)
Default {"share_guid":"james-bond007"}
Any of:
curl -i -X POST \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts?jwt=string' \
  -H 'Content-Type: application/json' \
  -H 'Cookie: string' \
  -d '{
    "country_code": "US",
    "fluid_shop": "myco.fluid.app",
    "fluid_session": "fs_szwdDuRbqEe7AV7sXk7vVq",
    "visitor_token": "vt_2a3v3f9s8xRCN",
    "source": "web",
    "items": [
      {
        "variant_id": 90,
        "quantity": 2
      }
    ],
    "attribution": {
      "email": "salesrep@example.com"
    }
  }'

Responses

cart created with JWT authentication and buyer_rep assignment

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
curl -i -X GET \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}?fluid_session=string&fluid_shop=string'

Responses

cart found

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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
Query
fluid_shopstring

The domain of your Fluid shop (excluding the scheme)

Example: fluid_shop=myco.fluid.app
fluid_sessionstring

Session token

Example: fluid_session=fs_szwdDuRbqEe7AV7sXk7vVq
Bodyapplication/json
emailstring(email)
phonestring
Example: "4035551212"
curl -i -X PATCH \
  'https://docs.fluid.app/_mock/docs/apis/company.api/api/public/v2025-06/commerce/carts/{cart_token}?fluid_session=string&fluid_shop=string' \
  -H 'Content-Type: application/json' \
  -d '{
    "email": "user@example.com",
    "phone": "4035551212"
  }'

Responses

cart updated with phone number validation

Bodyapplication/json
cartobject(Cart)
metaobject(CartCheckoutMetadata)
Response
application/json
{ "cart": { "date": "2023-12-19T09:01:17.190Z", "customer_code": 7319, "currency_code": "USD", "country_code": "USA", "ip": "139.5.71.59", "abandoned": null, "source": "web", "total": "38.23", "sub_total": "20.0", "tax_total": "10.23", "shipping_total": "0.0", "enrollment_fee": 0, "discount_total": 0, "cv_total": 0, "fulfillment": "fedex-ground", "payment_token": null, "payment_total": "28.0", "subscription": false, "customer": {}, "sponsor": {}, "addresses": {}, "lines": [], "cart_token": "HuSmS99wrjLfeehQgYLMjKHG", "cart_id": 6583 }, "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" } }

checkout

Operations

enrollment-packs

Operations

events

Operations

fingerprint

Operations

lead

Operations

media

Operations

page

Operations

playlist

Operations

product

Operations

session

Operations

settings

Operations

url

Operations

widgets

Operations