Skip to main content

Overview

The CardClan Integration API uses standard HTTP status codes and provides detailed error messages to help you troubleshoot issues quickly. This guide covers common errors, their causes, and how to handle them effectively in your applications.

HTTP Status Codes

The API uses standard HTTP status codes to indicate the success or failure of requests:
  • 200 OK - Request successful, data returned - 201 Created - Resource created successfully (e.g., card sent, configuration created)
  • 400 Bad Request - Invalid request parameters or missing required fields - 401 Unauthorized - Invalid or missing authentication credentials - 404 Not Found - Requested resource doesn’t exist or user doesn’t have access - 409 Conflict - Resource conflict (e.g., integration configuration already exists)
  • 500 Internal Server Error - Unexpected server error - 502 Bad Gateway - Temporary server issue - 503 Service Unavailable - Service temporarily unavailable

Error Response Format

All error responses follow a consistent structure:
string
Human-readable error type corresponding to the HTTP status
string
Detailed error message explaining what went wrong
number
HTTP status code for the error
string
ISO 8601 timestamp when the error occurred

Common Errors and Solutions

Authentication Errors

Cause: Missing Authorization header in your requestSolution: Include the Bearer token header
Cause: Authorization header present but token value is emptySolution: Ensure your integration key is properly set
Cause: Integration key is invalid or has been regeneratedSolution: Generate a new integration key from CardClan dashboard

Validation Errors

Cause: Missing card parameter in request payloadSolution: Include the card ID in your request
Cause: Missing integrationId parameterSolution: Create integration configuration first, then use the returned ID
Cause: Missing or invalid mergeTags parameterSolution: Provide merge tags as a non-empty array
Cause: Missing workspace query parameter when fetching cardsSolution: Include workspace ID in the query string

Resource Errors

Cause: Card ID doesn’t exist or user doesn’t have permission to access itSolution: Verify the card exists and belongs to your workspace
Cause: Trying to create an integration configuration for a card that already has oneSolution: Get the existing configuration instead
Cause: Trying to use an integration ID that doesn’t existSolution: Create the integration configuration first

Next Steps

Now that you have covered the error handling:
  1. Explore examples
  2. Explore the API reference for detailed endpoint documentation