Customer Category API
Customer categories allow you to segment and organize customers for reporting and analysis.
Endpoints
| Method | Endpoint | Description |
|---|---|---|
GET | /record/v1/customerCategory | List all customer categories |
GET | /record/v1/customerCategory/{id} | Get specific category |
POST | /record/v1/customerCategory | Create new category |
PATCH | /record/v1/customerCategory/{id} | Update category |
DELETE | /record/v1/customerCategory/{id} | Delete category |
Base URL
https://{account_id}.suitetalk.api.netsuite.com/services/rest/record/v1/customerCategory
Key Fields
| Field | Type | Description | Required |
|---|---|---|---|
id | string | Internal ID (read-only) | - |
name | string | Category name | Yes |
isInactive | boolean | Inactive flag | No |
Example: Create Customer Category
POST /record/v1/customerCategory
Content-Type: application/json
Authorization: Bearer {access_token}
{
"name": "Enterprise"
}
Response
{
"links": [
{
"rel": "self",
"href": "https://1234567.suitetalk.api.netsuite.com/services/rest/record/v1/customerCategory/5"
}
],
"id": "5",
"name": "Enterprise",
"isInactive": false
}
Example: Update Customer Category
PATCH /record/v1/customerCategory/5
Content-Type: application/json
Authorization: Bearer {access_token}
{
"name": "Enterprise - Updated",
"isInactive": false
}
Response
{
"links": [
{
"rel": "self",
"href": "https://1234567.suitetalk.api.netsuite.com/services/rest/record/v1/customerCategory/5"
}
],
"id": "5",
"name": "Enterprise - Updated",
"isInactive": false
}
Query Filters
List All Active Categories
GET /record/v1/customerCategory?q=isInactive=false&limit=100
Find Category by Name
GET /record/v1/customerCategory?q=name='Enterprise'
Find Categories by Partial Name
GET /record/v1/customerCategory?q=name LIKE 'Enter%'
List Inactive Categories
GET /record/v1/customerCategory?q=isInactive=true
Common Use Cases
1. Segment Customers by Size
Create categories to organize customers by business size:
// Create Enterprise category
await createCategory({ name: "Enterprise" });
// Create SMB category
await createCategory({ name: "Small & Medium Business" });
// Create Startup category
await createCategory({ name: "Startup" });
2. Assign Category to Customer
await patchCustomer(customerId, {
category: { id: "5" } // Enterprise
});
3. Report by Customer Category
Use categories to filter customers in reports and queries:
GET /record/v1/customer?q=category='5'
4. Deactivate Unused Category
await patchCategory(categoryId, {
isInactive: true
});
Important Notes
Required Fields
- name: The category name is required and must be unique
Category Usage
- Categories can be used for customer segmentation and reporting
- Customers can have zero or one category assigned
- Categories are typically used to group customers by:
- Business size (Enterprise, SMB, Startup)
- Industry vertical (Healthcare, Finance, Retail)
- Customer lifecycle (New, Growth, Mature)
- Geographic region (North America, EMEA, APAC)
Deleting Categories
- You cannot delete a category that is assigned to active customers
- Either remove the category from all customers first, or mark it as inactive
Best Practices
- Keep category names clear and consistent
- Use categories that align with your reporting needs
- Consider creating a category hierarchy using naming conventions (e.g., "Enterprise - Healthcare", "Enterprise - Finance")
Common Categories Examples
By Business Size
- Enterprise
- Mid-Market
- Small Business
- Startup
- Individual/Consumer
By Industry
- Healthcare
- Financial Services
- Retail
- Manufacturing
- Technology
- Professional Services
By Customer Type
- Direct Customer
- Reseller/Partner
- Government
- Non-Profit
- Educational Institution
By Region
- North America
- EMEA (Europe, Middle East, Africa)
- APAC (Asia Pacific)
- Latin America
See Also
- Customer - Assign categories to customers
- Vendor Category - Similar concept for vendors
- Customer Status - Track customer lifecycle stage