TestCompare API

Integrate data validation and comparison directly into your applications

Quick Start

1
Authentication
Register and obtain your API credentials
POST /api/v1/auth/register { "email": "your@email.com", "password": "secure_password" } POST /api/v1/auth/login { "username": "your@email.com", "password": "secure_password" }
2
Create a Test
Set up your first data comparison test
POST /api/v1/tests/ { "name": "Production vs Staging", "source_config": { "type": "postgres", "connection": {...} }, "target_config": { "type": "postgres", "connection": {...} } }

API Endpoints

Authentication
Manage user authentication and API access
POST
/api/v1/auth/registerCreate new user account
POST
/api/v1/auth/loginAuthenticate user and get token
Test Management
Create, manage, and execute data comparison tests
GET
/api/v1/tests/List all tests
POST
/api/v1/tests/Create new test configuration
GET
/api/v1/tests/{test_id}Get specific test details
PUT
/api/v1/tests/{test_id}Update test configuration
POST
/api/v1/tests/{test_id}/runExecute test
GET
/api/v1/tests/{test_id}/resultsGet test results
Connectors
Configure and validate data source connections
GET
/api/v1/connectors/List available connectors
POST
/api/v1/connectors/{type}/validateValidate connector config
GET
/api/v1/connectors/{type}/schemaGet data source schema
Job Management
Monitor and manage test execution jobs
GET
/api/v1/jobs/List all jobs
GET
/api/v1/jobs/{job_id}Get job details
POST
/api/v1/jobs/{job_id}/cancelCancel running job

Supported Data Sources

PostgreSQL
MySQL
Snowflake
Salesforce
CSV
JSON
REST API

Authentication

OAuth2 Bearer Token
All API requests require authentication using Bearer tokens

1. Obtain Access Token

curl -X POST "https://api.testcompare.ai/api/v1/auth/login" \ -H "Content-Type: application/json" \ -d '{ "username": "your@email.com", "password": "your_password" }'

2. Use Token in Requests

curl -X GET "https://api.testcompare.ai/api/v1/tests/" \ -H "Authorization: Bearer YOUR_ACCESS_TOKEN"