ThemisDB implements comprehensive API versioning to ensure backward compatibility and smooth upgrades for all API types:
- REST API: HTTP/HTTPS endpoints
- gRPC API: Protocol Buffers services
- GraphQL API: GraphQL queries and mutations
Current Version: v1.4.1
Minimum Supported Version: v1.0.0
Version Format: Semantic Versioning (Major.Minor.Patch)
ThemisDB supports two mechanisms for specifying the API version in REST requests. URL path
prefixes take priority over the Accept-Version header.
Embed the version directly in the URL path using a /v{N}/ prefix:
GET /v1/entities/urn:themis:entity:123
Authorization: Bearer <token>GET /v2/entities/urn:themis:entity:123
Authorization: Bearer <token>Behaviour:
- The gateway extracts the version from the path prefix and resolves it to the latest
matching supported release (e.g.
/v1/→v1.4.1). - The
/v{N}/prefix is stripped before the request is forwarded to the handler, so all handlers see canonical, unversioned paths regardless of which version prefix the client used. - Query strings are preserved:
/v1/entities?page=2is forwarded as/entities?page=2.
Response includes the resolved version:
HTTP/1.1 200 OK
API-Version: v1.4.1
Content-Type: application/json
{
"data": { ... }
}Use the Accept-Version header for version negotiation without modifying the URL:
GET /api/entities/urn:themis:entity:123
Accept-Version: v1.3.0
Authorization: Bearer <token>Response includes version information:
HTTP/1.1 200 OK
API-Version: v1.3.0
Content-Type: application/json
{
"data": { ... }
}Note: When both a URL path prefix (
/v1/) and anAccept-Versionheader are present, the URL path prefix takes precedence.
v1.4.1- Full versionv1.4- Minor version (resolves to latest patch)v1- Major version (resolves to latest minor.patch)latest- Current stable version
If neither a URL path prefix nor an Accept-Version header is provided, the current stable
version is used.
Use metadata to specify API version in gRPC calls:
grpc::ClientContext context;
context.AddMetadata("api-version", "v1.4.0");
CreateRequest request;
CreateResponse response;
stub->Create(&context, request, &response);Response metadata includes:
api-version: v1.4.0
Specify version in the request header or query parameter:
# Header-based
Accept-Version: v1.4.0
# Query parameter
query {
entities(version: "v1.4.0") {
id
data
}
}ThemisDB follows a 24-month deprecation policy:
-
Deprecation Announcement (Month 0)
- Feature/endpoint marked as deprecated
- Deprecation headers added to responses
- Migration guide published
-
Deprecation Period (Months 0-24)
- Feature continues to work
- Deprecation warnings in logs and responses
- Migration support available
-
Removal (Month 24+)
- Feature removed in next major version
- Breaking change documented in CHANGELOG
- Upgrade path clearly defined
When accessing deprecated endpoints, responses include:
HTTP/1.1 200 OK
API-Version: v1.3.0
Deprecation: true; deprecated-version="v1.3.0"; removal-version="v2.0.0"
Sunset: Wed, 24 Jan 2028 06:00:00 GMT
Link: <https://docs.themisdb.com/migration/v1-to-v2>; rel="deprecation"Headers:
Deprecation: RFC draft - indicates deprecation statusSunset: RFC 8594 - removal dateLink: Migration guide URL
| Version | Status | Release Date | End of Support | Notes |
|---|---|---|---|---|
| v1.4.x | Current | 2026-01-19 | TBD | Production ready |
| v1.3.x | Supported | 2025-09-15 | 2027-09-15 | 24-month support |
| v1.2.x | Supported | 2025-03-10 | 2027-03-10 | 24-month support |
| v1.1.x | Supported | 2024-09-01 | 2026-09-01 | 24-month support |
| v1.0.x | Minimum | 2024-01-15 | 2026-01-15 | Basic compatibility |
- No breaking changes planned
- Focus on feature additions and performance
- Extended context window (backward compatible)
- New LLM/LoRA endpoints (additive)
- Enhanced pagination (backward compatible)
- Query optimizer improvements (transparent)
- New authentication methods (additive)
- Enhanced transaction semantics (backward compatible)
- New sharding features (opt-in)
- Initial stable release to first feature update
- No breaking changes
Clients should be designed to handle:
- Unknown fields: Ignore fields not in their API version
- New optional parameters: Skip parameters they don't recognize
- Deprecated warnings: Log and plan migration
Detect server API version:
# REST
curl -I https://api.themisdb.com/api/status | grep "API-Version"
# Response
API-Version: v1.4.1Query server for supported versions:
GET /api/status{
"version": "1.4.1-dev",
"api_version": {
"major": 1,
"minor": 4,
"patch": 1
},
"supported_api_versions": [
{"major": 1, "minor": 0, "patch": 0},
{"major": 1, "minor": 1, "patch": 0},
{"major": 1, "minor": 2, "patch": 0},
{"major": 1, "minor": 3, "patch": 0},
{"major": 1, "minor": 4, "patch": 0},
{"major": 1, "minor": 4, "patch": 1}
]
}All official SDKs support version negotiation:
# Python
from themisdb import Client
client = Client(
url="https://api.themisdb.com",
api_version="v1.4.0"
)// JavaScript/TypeScript
import { ThemisClient } from 'themisdb-client';
const client = new ThemisClient({
url: 'https://api.themisdb.com',
apiVersion: 'v1.4.0'
});// Go
import "github.com/makr-code/themisdb-go"
client := themisdb.NewClient(
themisdb.WithURL("https://api.themisdb.com"),
themisdb.WithAPIVersion("v1.4.0"),
)See detailed migration guides for version transitions:
- v1.3.x to v1.4.x Migration Guide
- v1.2.x to v1.3.x Migration Guide
- v1.1.x to v1.2.x Migration Guide
- v1.0.x to v1.1.x Migration Guide
- Always specify API version in production
- Monitor deprecation warnings in logs
- Test against new versions before upgrading
- Use version pinning in configuration
- Subscribe to breaking changes announcements
- Document all breaking changes in CHANGELOG
- Provide migration guides for deprecated features
- Support multiple versions during transition
- Use semantic versioning consistently
- Communicate early about deprecations
The current stable version (v1.4.1) will be used.
Yes, different requests can use different API versions.
Check the Deprecation header in responses and review the Deprecation Registry.
You'll receive a 400 Bad Request with guidance to upgrade. Critical security updates may require immediate upgrade.
Generally no. Older versions may miss performance optimizations from newer releases.
For API versioning questions:
- Documentation: https://docs.themisdb.com/api/versioning
- GitHub Issues: https://github.com/makr-code/ThemisDB/issues
- Community: https://github.com/makr-code/ThemisDB/discussions