Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to CloudCart

Scalekit connector
Open markdown

The CloudCart connector lets your AI agent act in each user's CloudCart account. Each user connects their own CloudCart API key once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 58 tools.

Tools
58
What they doRead · write · destructive
30 · 19 · 930 read19 write9 destructive
Users sign in with

Setup

  1. Install the SDK

    Terminal window
    npm install @scalekit-sdk/node dotenv
  2. Set your credentials

    Add your Scalekit credentials to your .env file. Find values in app.scalekit.com > Developers > API Credentials.

    .env
    SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
    SCALEKIT_CLIENT_ID=<your-client-id>
    SCALEKIT_CLIENT_SECRET=<your-client-secret>
  3. Create the CloudCart connection

    In AgentKit > Connections, create a CloudCart connection. The name you give it is the connection_name your code passes. See Configure connections.

  4. Authorize a user and make your first call

    quickstart.mts
    import { ScalekitClient } from '@scalekit-sdk/node'
    import 'dotenv/config'
    import { createInterface } from 'node:readline/promises'
    const scalekit = new ScalekitClient(
    process.env.SCALEKIT_ENVIRONMENT_URL,
    process.env.SCALEKIT_CLIENT_ID,
    process.env.SCALEKIT_CLIENT_SECRET,
    )
    const actions = scalekit.actions
    const connector = 'cloudcart'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize CloudCart:', link)
    const rl = createInterface({ input: process.stdin, output: process.stdout })
    await rl.question('Press Enter after authorizing...')
    rl.close()
    // Make your first call
    const result = await actions.executeTool({
    connector,
    identifier,
    toolName: 'cloudcart_categories_list',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user opens the link once and enters their CloudCart credentials there. See Authorize a user for the full flow and statuses.

Tools

Pass the exact name to execute_tool
Try in PlaygroundRequest a tool
  • cloudcart_categories_listList the product categories of a CloudCart store.Read-only

    List Categories

    List the product categories of a CloudCart store. Returns categories with name, slug, description, order and parent ID. Use this to find category IDs for products and discounts.

    Inputs

    filter_parent_idstring
    Only children of this category ID. Example: 3.
    page_numberinteger
    Page number, starting at 1. Example: 1.
    page_sizeinteger
    Results per page, up to 100. Example: 25.
    sortstring
    Sort field, with a leading - for descending. Allowed: name, order, id. Example: -name.
  • cloudcart_category_getGet one CloudCart category.Read-only

    Get Category

    Get one CloudCart category. Returns the category's name, slug, description, image and parent. Use this for a category's details.

    Inputs

    idstringrequired
    ID of the category, from cloudcart_categories_list. Example: 1042.
  • cloudcart_customer_getGet one CloudCart customer.Read-only

    Get Customer

    Get one CloudCart customer. Returns the customer's details; include adds orders, addresses and group. Use this for a customer's details.

    Inputs

    idstringrequired
    ID of the customer, from cloudcart_customers_list. Example: 1042.
    includestring
    Related resources to include, comma-separated: orders, shipping-addresses, billing-addresses, group. Example: orders.
  • cloudcart_customer_groups_listList the customer groups of a CloudCart store.Read-only

    List Customer Groups

    List the customer groups of a CloudCart store. Returns groups with name and discount percent. Use this to find group IDs.

    Inputs

    page_numberinteger
    Page number, starting at 1. Example: 1.
    page_sizeinteger
    Results per page, up to 100. Example: 25.
  • cloudcart_customer_shipping_addresses_listList saved customer shipping addresses in CloudCart, optionally for one customer.Read-only

    List Customer Shipping Addresses

    List saved customer shipping addresses in CloudCart, optionally for one customer. Returns addresses with name, phone, street, city, postcode and country. Use this to read a customer's addresses.

    Inputs

    filter_customer_idstring
    Only addresses of this customer ID. Example: 1201.
    page_numberinteger
    Page number, starting at 1. Example: 1.
    page_sizeinteger
    Results per page, up to 100. Example: 25.
  • cloudcart_customers_listList the customers of a CloudCart store, filtered by any column such as email.Read-only

    List Customers

    List the customers of a CloudCart store, filtered by any column such as email. Returns customers with name, email, phone, company, marketing opt-in and dates. Use this to find a customer.

    Inputs

    filter_emailstring
    Exact email address. Example: jane@example.com.
    includestring
    Related resources to include, comma-separated: orders, shipping-addresses, billing-addresses, group. Example: orders.
    page_numberinteger
    Page number, starting at 1. Example: 1.
    page_sizeinteger
    Results per page, up to 100. Example: 25.
    sortstring
    Sort field, with a leading - for descending. Allowed: date_added, id. Example: -date_added.
  • cloudcart_discount_codes_listList the percentage discount codes of a CloudCart store.Read-only

    List Discount Codes

    List the percentage discount codes of a CloudCart store. Returns codes with code, value (10000 = 100%) and active flag. Use this to review codes.

    Inputs

    filter_codestring
    Exact code. Example: SPRING20.
    page_numberinteger
    Page number, starting at 1. Example: 1.
    page_sizeinteger
    Results per page, up to 100. Example: 25.
  • cloudcart_discount_getGet one CloudCart discount campaign.Read-only

    Get Discount

    Get one CloudCart discount campaign. Returns the discount's type, value, target, dates, code, limits and uses. Use this for a discount's details.

    Inputs

    idstringrequired
    ID of the discount, from cloudcart_discounts_list. Example: 1042.