---
title: "คู่มือการเชื่อมต่อ BigCommerce"
description: "คู่มือฉบับสมบูรณ์สำหรับการเชื่อมต่อ Tajo เข้ากับร้าน BigCommerce ของคุณ เพื่อซิงค์ข้อมูลลูกค้า ทำโปรแกรมสะสมแต้ม และทำการตลาดอัตโนมัติ"
url: https://tajo.io/th/docs/ecommerce-platforms/bigcommerce/
markdown: https://tajo.io/th/docs/ecommerce-platforms/bigcommerce.md
lang: th-TH
robots: noindex
---

ขอสิทธิ์ใช้งานล่วงหน้า

กรอกชื่อและที่อยู่อีเมลที่ทำงานของคุณ เราจะส่งลิงก์เพื่อยืนยันคำขอเข้าใช้งาน Tajo ทางอีเมล

# คู่มือการเชื่อมต่อ BigCommerce

คู่มือนี้จะพาคุณเชื่อมต่อ Tajo เข้ากับร้าน BigCommerce ของคุณ เพื่อเปิดใช้งานความสามารถด้านการสร้างความผูกพันกับลูกค้า โปรแกรมสะสมแต้ม และการตลาดอัตโนมัติ

## ภาพรวม

การเชื่อมต่อ Tajo กับ BigCommerce ช่วยให้คุณทำสิ่งต่อไปนี้ได้

- **ซิงค์ข้อมูลลูกค้า** จากร้าน BigCommerce ของคุณโดยอัตโนมัติ
- **ติดตามออเดอร์และสินค้า** เพื่อทำการตลาดแบบเฉพาะบุคคล
- **ทำโปรแกรมสะสมแต้ม** พร้อมคะแนน ระดับสมาชิก และของรางวัล
- **ทำแคมเปญการตลาดอัตโนมัติ** ผ่าน Brevo (อีเมล SMS WhatsApp)
- **แบ่งกลุ่มลูกค้า** ตามพฤติกรรมการซื้อและระดับความผูกพัน
- **รองรับหลายหน้าร้าน** ในการดำเนินงาน

## สิ่งที่ต้องเตรียม

ก่อนเริ่มการเชื่อมต่อ ตรวจสอบให้แน่ใจว่าคุณมีสิ่งต่อไปนี้

- **ร้าน BigCommerce** ในแพ็กเกจใดก็ได้ (Standard, Plus, Pro หรือ Enterprise)
- **บัญชี Tajo** ที่มีการสมัครใช้งานอยู่
- **บัญชี Brevo** (ไม่บังคับ ใช้สำหรับการตลาดอัตโนมัติ)
- **ข้อมูลรับรอง API ของร้าน** (บัญชี API ที่มีขอบเขตสิทธิ์เหมาะสม)

## ขั้นที่ 1: ติดตั้งแอป Tajo

### จาก BigCommerce App Marketplace

1. เข้าไปที่แผงควบคุม BigCommerce ของคุณ
2. ไปที่ **Apps → Marketplace**
3. ค้นหาคำว่า “Tajo”
4. คลิก **Get This App**
5. ตรวจสอบสิทธิ์การเข้าถึงแล้วคลิก **Install**
6. ทำตามตัวช่วยติดตั้งเพื่อเชื่อมต่อบัญชี Tajo ของคุณ

### การตั้งค่า API

หลังติดตั้งเสร็จ ให้ตั้งค่าการเข้าถึง API

```json
{
  "api_credentials": {
    "client_id": "your_client_id",
    "client_secret": "your_client_secret",
    "access_token": "your_access_token",
    "store_hash": "your_store_hash"
  },
  "scopes": [
    "store_v2_customers",
    "store_v2_orders",
    "store_v2_products",
    "store_cart",
    "store_checkout"
  ]
}
```

## ขั้นที่ 2: ตั้งค่าการซิงค์ข้อมูล

### การตั้งค่าซิงค์ข้อมูลลูกค้า

กำหนดว่าจะซิงค์ข้อมูลลูกค้าส่วนใดบ้าง

```json
{
  "sync_settings": {
    "customers": {
      "enabled": true,
      "sync_frequency": "real-time",
      "fields": [
        "email",
        "first_name",
        "last_name",
        "phone",
        "company",
        "customer_group_id",
        "store_credit",
        "addresses",
        "date_created"
      ]
    },
    "orders": {
      "enabled": true,
      "sync_frequency": "real-time",
      "include_products": true,
      "include_shipping": true,
      "include_coupons": true
    },
    "products": {
      "enabled": true,
      "sync_frequency": "hourly",
      "include_variants": true,
      "include_images": true,
      "include_custom_fields": true
    }
  }
}
```

### การตั้งค่า Webhook

Tajo จะลงทะเบียน Webhook ของ BigCommerce ต่อไปนี้

| Webhook | วัตถุประสงค์ |
| --- | --- |
| `store/customer/created` | ซิงค์ลูกค้าใหม่ไปยัง Tajo และ Brevo |
| `store/customer/updated` | รักษาข้อมูลโปรไฟล์ลูกค้าให้เป็นปัจจุบัน |
| `store/order/created` | ติดตามการซื้อ และมอบคะแนนสะสม |
| `store/order/statusUpdated` | เริ่มแคมเปญตามสถานะออเดอร์ |
| `store/cart/created` | ติดตามตะกร้าสินค้าเพื่อดูการละทิ้ง |
| `store/cart/updated` | อัปเดตลำดับข้อความติดตามตะกร้าที่ถูกละทิ้ง |
| `store/product/updated` | รักษาแคตตาล็อกสินค้าให้ซิงค์อยู่เสมอ |

### การรองรับหลายหน้าร้าน

สำหรับ BigCommerce Enterprise ที่มีหลายหน้าร้าน

```json
{
  "multi_storefront": {
    "enabled": true,
    "storefronts": [
      {
        "channel_id": 1,
        "name": "Main Store",
        "loyalty_program": "default"
      },
      {
        "channel_id": 2,
        "name": "Wholesale",
        "loyalty_program": "b2b_program"
      },
      {
        "channel_id": 3,
        "name": "International",
        "loyalty_program": "global_program"
      }
    ],
    "sync_across_channels": true
  }
}
```

## ขั้นที่ 3: ตั้งค่าโปรแกรมสะสมแต้ม

### กำหนดระบบคะแนน

```javascript
const pointsConfig = {
  // Points per dollar spent
  purchasePoints: {
    enabled: true,
    rate: 1, // 1 point per $1
    roundingMode: 'floor'
  },

  // Bonus actions
  bonusPoints: {
    accountCreation: 100,
    firstPurchase: 200,
    reviewSubmitted: 50,
    referralMade: 500,
    birthdayBonus: 100,
    newsletterSignup: 25
  },

  // Customer group multipliers
  customerGroupMultipliers: {
    'Retail': 1.0,
    'VIP': 1.5,
    'Wholesale': 0.5,
    'Platinum': 2.0
  }
};
```

### ระดับสมาชิกของโปรแกรมสะสมแต้ม

```javascript
const loyaltyTiers = [
  {
    name: 'Bronze',
    minPoints: 0,
    benefits: [
      '1 point per $1 spent',
      'Birthday bonus points',
      'Member-only promotions'
    ]
  },
  {
    name: 'Silver',
    minPoints: 1000,
    benefits: [
      '1.25x points multiplier',
      'Free shipping on orders $50+',
      'Early access to sales'
    ]
  },
  {
    name: 'Gold',
    minPoints: 5000,
    benefits: [
      '1.5x points multiplier',
      'Free shipping on all orders',
      'Exclusive product access',
      'Priority support'
    ]
  },
  {
    name: 'Platinum',
    minPoints: 15000,
    benefits: [
      '2x points multiplier',
      'Free express shipping',
      'VIP experiences',
      'Dedicated account manager'
    ]
  }
];
```

## ขั้นที่ 4: การจัดการลูกค้าแบบ B2B

### บัญชีองค์กร

BigCommerce รองรับฟีเจอร์ B2B ที่ทำงานร่วมกับ Tajo ได้

```javascript
const b2bConfig = {
  companyAccounts: {
    enabled: true,
    syncCompanyData: true,
    fields: [
      'company_name',
      'tax_id',
      'credit_limit',
      'payment_terms',
      'price_list'
    ]
  },

  // B2B-specific loyalty rules
  b2bLoyalty: {
    orderVolumeBonus: {
      threshold: 10000,
      bonusMultiplier: 1.5
    },
    reorderPoints: {
      enabled: true,
      rate: 0.5 // 0.5 points per $1 on reorders
    }
  }
};
```

### การเชื่อมกลุ่มลูกค้า

```javascript
// Map BigCommerce customer groups to Tajo segments
const customerGroupMapping = {
  'Retail': {
    tajoSegment: 'retail_customers',
    loyaltyTier: 'Bronze',
    emailList: 'retail_newsletter'
  },
  'Wholesale': {
    tajoSegment: 'wholesale_customers',
    loyaltyTier: 'Silver',
    emailList: 'wholesale_updates'
  },
  'VIP': {
    tajoSegment: 'vip_customers',
    loyaltyTier: 'Gold',
    emailList: 'vip_exclusive'
  }
};
```

## ขั้นที่ 5: การกู้คืนตะกร้าสินค้าที่ถูกละทิ้ง

### การติดตามตะกร้าสินค้า

```javascript
// BigCommerce cart webhook handler
async function handleCartWebhook(event) {
  const cart = await bigcommerce.carts.get(event.data.cartId);

  if (!cart.customer_id && !cart.email) {
    return; // Can't track without identity
  }

  await tajo.carts.track({
    customerId: cart.customer_id,
    email: cart.email,
    cartId: cart.id,
    items: cart.line_items.physical_items.map(item => ({
      productId: item.product_id,
      variantId: item.variant_id,
      title: item.name,
      quantity: item.quantity,
      price: item.sale_price || item.list_price,
      image: item.image_url
    })),
    totalPrice: cart.cart_amount,
    currency: cart.currency.code,
    checkoutUrl: cart.redirect_urls?.checkout_url
  });
}
```

### ลำดับข้อความกู้คืนตะกร้า

```json
{
  "abandoned_cart_sequence": {
    "trigger": {
      "event": "cart_abandoned",
      "delay": "1 hour"
    },
    "messages": [
      {
        "delay": "1 hour",
        "channel": "email",
        "template": "cart_reminder_1",
        "subject": "You left something behind!"
      },
      {
        "delay": "24 hours",
        "channel": "email",
        "template": "cart_reminder_2",
        "subject": "Your cart is waiting - 10% off inside"
      },
      {
        "delay": "72 hours",
        "channel": "sms",
        "template": "cart_sms_final"
      }
    ],
    "exit_conditions": [
      "order_completed",
      "cart_emptied",
      "unsubscribed"
    ]
  }
}
```

## ขั้นที่ 6: การตลาดอัตโนมัติ

### กลุ่มลูกค้า

```javascript
const bigcommerceSegments = [
  // Purchase behavior
  {
    name: 'First-Time Buyers',
    conditions: { orders_count: 1 }
  },
  {
    name: 'Repeat Customers',
    conditions: { orders_count: { $gte: 2 } }
  },
  {
    name: 'High-Value Customers',
    conditions: { total_spent: { $gte: 1000 } }
  },

  // Customer groups
  {
    name: 'Wholesale Accounts',
    conditions: { customer_group: 'Wholesale' }
  },

  // Engagement
  {
    name: 'At-Risk Customers',
    conditions: {
      last_order_date: { $lt: '-90 days' },
      orders_count: { $gte: 2 }
    }
  }
];
```

### แคมเปญอัตโนมัติ

```javascript
// Order status change triggers
bigcommerce.webhooks.on('store/order/statusUpdated', async (event) => {
  const order = await bigcommerce.orders.get(event.data.orderId);
  const customer = await tajo.customers.getByEmail(order.billing_address.email);

  switch (event.data.status.new_status) {
    case 'Shipped':
      await brevo.trackEvent(customer.email, 'order_shipped', {
        orderId: order.id,
        trackingNumber: order.tracking_number,
        carrier: order.shipping_carrier
      });
      break;

    case 'Completed':
      // Award loyalty points
      const points = calculatePoints(order, customer);
      await tajo.loyalty.awardPoints(customer.id, points);

      // Trigger review request after 14 days
      await brevo.scheduleEvent(customer.email, 'review_request', {
        orderId: order.id,
        products: order.products
      }, { delay: '14 days' });
      break;
  }
});
```

## ขั้นที่ 7: การวิเคราะห์ข้อมูล

### ตัวชี้วัดบนแดชบอร์ด

```javascript
const dashboardMetrics = {
  customers: {
    total: await tajo.analytics.count('customers'),
    byChannel: await tajo.analytics.groupBy('customers', 'channel_id'),
    newThisMonth: await tajo.analytics.count('customers', {
      created_at: { $gte: 'this_month' }
    })
  },

  revenue: {
    total: await tajo.analytics.sum('orders.total'),
    byChannel: await tajo.analytics.groupBy('orders', 'channel_id', {
      aggregate: 'sum',
      field: 'total'
    }),
    averageOrderValue: await tajo.analytics.avg('orders.total')
  },

  loyalty: {
    activeMembers: await tajo.analytics.count('loyalty_members'),
    pointsIssued: await tajo.analytics.sum('points.awarded'),
    redemptionRate: await tajo.analytics.pointsRedemptionRate()
  }
};
```

## การแก้ปัญหา

### ขีดจำกัดอัตราการเรียกใช้ API

```javascript
// Implement rate limiting
async function bigcommerceApiCall(endpoint, options, retries = 3) {
  for (let i = 0; i < retries; i++) {
    try {
      const response = await fetch(endpoint, options);

      if (response.status === 429) {
        const retryAfter = response.headers.get('X-Rate-Limit-Time-Reset-Ms');
        await sleep(parseInt(retryAfter) || Math.pow(2, i) * 1000);
        continue;
      }

      return response;
    } catch (error) {
      if (i === retries - 1) throw error;
    }
  }
}
```

### การตรวจสอบ Webhook

```javascript
// Verify BigCommerce webhook signature
function verifyWebhook(payload, signature, secret) {
  const expected = crypto
    .createHmac('sha256', secret)
    .update(payload)
    .digest('base64');

  return crypto.timingSafeEqual(
    Buffer.from(expected),
    Buffer.from(signature)
  );
}
```

## ขั้นตอนถัดไป

1. **[ตั้งค่าการเชื่อมต่อ Brevo](https://tajo.io/th/docs/platform-integration/tajo-brevo-integration)** สำหรับแคมเปญอีเมลและ SMS
2. **[ตั้งค่า Webhook](https://tajo.io/th/docs/webhook-configuration/setup-guide)** สำหรับเหตุการณ์แบบเรียลไทม์
3. **[สร้างกลุ่มลูกค้า](https://tajo.io/th/docs/contact-management)** สำหรับการตลาดแบบเจาะกลุ่ม
4. **[สร้างเทมเพลตอีเมล](https://tajo.io/th/docs/messaging-api)** สำหรับแคมเปญอัตโนมัติ

## การสนับสนุน

- **ฝ่ายสนับสนุนการเชื่อมต่อ**: [support@tajo.io](mailto:support@tajo.io)
- **เอกสารของ BigCommerce**: [developer.bigcommerce.com](https://developer.bigcommerce.com/)
- **เอกสารอ้างอิง API**: [docs.tajo.io/api](https://tajo.io/th/docs/endpoints/rest-api)
- **ติดต่อฝ่ายสนับสนุน**: [/th/contact](https://tajo.io/th/contact)
