API Reference

You bring the UI; we run the backend. REST + JSON, Bearer tokens, standard HTTP codes. Every response carries a request ID so support handoffs are one paste.

Authentication

Pass your API key as a Bearer token in the Authorization header. Manage keys from the CLI or team settings.

bash
curl -H "Authorization: Bearer sk_live_your_key" \
  https://www.cstar.help/api/v1/teams/{teamId}/tickets

Secret
sk_live_* / sk_test_*

Acts for the member who made it, so it can do what their role can today (an admin's key can't open billing). Server-side only. If it lands in your bundle, rotate it.

Publishable
pk_live_* / pk_test_*

For the public library and community SDKs and /auth/whoami. Safe in browsers. Team endpoints answer 403: publishable_key_forbidden on reads, publishable_key_write on writes.

Base URL

text
https://www.cstar.help/api/v1/teams/{teamId}

All endpoints are scoped to your team. Replace {teamId} with your team's UUID (found in team settings or via cstar status).

Errors

Conventional HTTP status codes. 2xx means it worked, 4xx means you need to fix something, 5xx means we do. The full Error Reference has the per-code playbook.

200 OK: Request succeeded
201 Created: Resource created successfully
400 Bad Request: Missing or invalid parameters
401 Unauthorized: Invalid or missing API key
403 Forbidden: Key lacks required permissions
404 Not Found: Resource doesn't exist
429 Rate Limited: Too many requests
500 Server Error: Something went wrong on our end
Error response shape
{
  "success": false,
  "error": {
    "type": "invalid_request_error",
    "code": "parameter_missing",
    "message": "The 'title' field is required.",
    "param": "title",
    "doc_url": "https://www.cstar.help/developers/errors#parameter_missing",
    "request_id": "req_abc123"
  },
  "meta": {
    "timestamp": "2025-12-10T14:30:00Z"
  }
}

Rate Limits

The API is rate-limited per key. Limits are returned in response headers. When exceeded, requests return 429 with a retryAfter value in the error body.

Secret keys 1,000 requests / hour
Publishable keys 100 requests / hour

Input limits

Every limit is far above real use. A request over one returns 400 with the field in param, before anything is written. The help center search reads the first 200 characters of a longer query instead.

Tags on one record 50 tags
One tag as sent 100 characters
Each team tag list 1,000 tags
Article content 200,000 characters
New ticket messages 100 messages
Each message 50,000 characters
Messages in total 1,000,000 characters
Customer email 254 characters
search and q 200 characters
JSON body nesting 64 levels

Stored tags are trimmed, lowercased and cut to 50 characters. A tag new to a full team list is refused: use tags already on it, or delete some in Settings first.

Idempotency

For safe retries on POST and PATCH requests, include an Idempotency-Key header. Within 24 hours, the same request (same method, endpoint and body) with the same key gets the first successful response back, marked Idempotent-Replayed: true, instead of creating a duplicate. A failed request doesn't use up its key, so you can fix it and retry.

The same key with a different body returns 422 idempotency_key_reused. While the first request is still running, the key returns 409 idempotency_key_in_use with a Retry-After header: wait that many seconds and send the same request again. A key already used on another endpoint also returns 409 idempotency_key_in_use. Multipart uploads are compared by their fields and each file's name, type and bytes, so a new form boundary still counts as the same request.

Keys are 1 to 250 characters; a longer key is a 400 with param: Idempotency-Key. A request that never finishes holds its key for up to 15 minutes, answering 409 meanwhile. A 503 service_unavailable with Retry-After means the key could not be recorded and nothing ran: retry with the same key.

A few endpoints don't cache responses and ignore the key: creating API keys, webhooks and webhook listeners, event stream tokens, data exports and billing portal sessions. Retrying those can still make a second webhook or listener (a repeated export only reads your data again). Adding a ticket message uses the key as that message's receipt: a retry returns the saved message, and the same key with a different message returns 409 idempotency_key_in_use.

bash
curl -X POST .../tickets \
  -H "Authorization: Bearer sk_live_..." \
  -H "Idempotency-Key: unique-request-id-123" \
  -d '{"title": "My ticket"}'

# Retry with the same key and body → returns the same ticket, no duplicate

Resources

Explore each resource for full endpoint documentation, parameters, and code examples.

Tickets Tickets are the core of cStar. Each one represents a customer support conversation. Create, update, and resolve tickets through the API.
GET /
GET /{ticketId}
POST /
+2 more
Customers Customers represent the people who submit tickets. Track their history, sentiment, and metadata across all interactions.
GET /
GET /{customerId}
POST /
+2 more
Customer Groups Customer groups let you organize customers into flexible categories, like Zendesk organizations, Intercom companies, or custom segments. Customers can belong to multiple groups. A group is test or live data like its customers: a test key creates and reaches only test groups, and a live key only live ones.
GET /
POST /
GET /{groupId}
+5 more
Articles Articles power your knowledge base. Create, publish, and manage help content that customers and agents can search.
GET /
GET /{articleId}
POST /
+2 more
Messages Messages belong to tickets and represent the conversation thread between agents and customers. Each message has a sender type and optional metadata.
GET /
POST /
Webhooks Webhooks notify your application in real-time when events happen in cStar. Subscribe to ticket, customer, article, and gamification events.
GET /
GET /{webhookId}
POST /
+3 more
Categories Categories organize your knowledge base articles into logical groups. Customers see public categories when browsing your help center.
GET /
POST /
PATCH /{categoryId}
+1 more
Community Community posts let customers ask questions, share feedback, and vote on feature requests. Agents can manage posts, set statuses, and moderate content.
GET /posts
POST /posts
PATCH /posts/{postId}
+11 more
Members Team members are the agents and admins who use cStar. Manage roles, view stats, and send invites.
GET /
GET /{memberId}
PATCH /{memberId}
+5 more
Settings Team settings control statuses, quick replies, the widget's online hours, and widget appearance. Secret key required.
GET /
GET /../preferences
PATCH /../preferences
+6 more
Notifications In-app notifications for team members. Every call names the team member with userId.
GET /
GET /unread-count
POST /mark-all-read
Custom Fields Define custom data fields for tickets, customers and articles. Supports text, number, date, select and checkbox types.
GET /
POST /
SLA Rules Service Level Agreement rules define response and resolution time targets by ticket priority.
GET /
POST /
Analytics Team performance analytics, agent stats, and CSAT data. All analytics endpoints require a secret key.
GET /
GET /agents
Bulk Operations Perform bulk updates or deletes on tickets, customers, or articles. Max 100 items per request.
POST /
Export Export tickets, customers, or articles as JSON or CSV. Exports run synchronously with up to 10,000 rows per resource, oldest first. When a resource has more, the export says so in truncated and the X-Result-Truncated header.
POST /
Import Import ticket details, customers, or articles. Processes up to 500 records synchronously and supports merge strategies.
POST /
GET /
Audit Log A log of the API requests made with your team's keys, in the key's mode: a test key sees test requests, a live key live ones. Filter by method, status, time window or key. Any other filter is a 400.
GET /
Search Search tickets, customers and articles with a secret key. Requires view permission for each selected resource.
GET /
Tags Tags on tickets, customers and articles. List them with usage counts, merge one into another, or remove one everywhere. There is no create call: add a tag by updating a record’s tags.
GET /
POST /
DELETE /
Game The cStar gamification system includes player stats, boss battles, leaderboards, achievements, quests, puzzles, social features, cosmetics, seasons, and skill trees. Use a secret key on your server. Player and game operations require the game_participation permission. With Gamification turned off for the team, every game endpoint but high-fives (social, they pay nothing) answers 403 feature_disabled with feature bossBattles and an enable_url.
GET /player
GET /player/{memberId}
GET /boss
+35 more
AI Actions AI-powered actions for ticket management: auto-tag tickets, generate reply suggestions, summarize conversations, and improve draft text.
POST /
Automations Automation rules that trigger actions when specific events occur. Rules have conditions, actions, and can be tested with dry runs.
GET /
POST /
POST /{ruleId}/test
Saved Views Saved filter presets for tickets, customers, articles, or community posts. Create reusable views and execute them to get filtered results.
GET /
POST /
GET /{viewId}/execute
Billing Access subscription status and create Stripe billing portal sessions. Secret key required.
GET /subscription
POST /portal