Skip to main content
Looking to get started quickly? Check out our 5-minute quickstart guide first.

API Endpoints

POST /attestations/verify

Upload and verify an SGX or TDX attestation quote. Supported Input Formats:
  1. File Upload (multipart/form-data) - Recommended for most use cases
  2. Hex String JSON (application/json) - For programmatic integration
  3. Hex String Form Data (application/x-www-form-urlencoded) - For simple form submissions
Quote Requirements:
  • Valid Intel SGX DCAP or TDX quote (2-8KB typical size)
  • Complete certificate chains included
  • ECDSA-P256 signature format
  • Generated from genuine Intel SGX/TDX platform
Request Parameters: Hex String Notes:
  • Optional 0x prefix supported
  • Case insensitive
  • Whitespace automatically trimmed
Response Schema: VerificationResponse
Response Fields: Error Responses: Error Responses:

GET /attestations/view/

Retrieve complete quote details including header, body, and verification status. Path Parameters:
  • checksum (string): Quote’s unique SHA256 identifier
Response: Full Quote object with additional metadata
Error Responses:
  • 404 Not Found: Quote with specified checksum doesn’t exist

GET /attestations/collateral/

Get cryptographic collateral (certificates, CRLs, TCB info) used for verification. Response Headers:
  • Cache-Control: public, max-age=86400 (24 hour cache)
  • ETag: "{checksum}" (for conditional requests)
Response: QuoteCollateralV3 object Headers:
  • Cache-Control: public, max-age=86400
  • CDN-Cache-Control: public, max-age=86400
  • Vary: Accept-Encoding
  • ETag: "9540fda5e6416c9d02bae726b146be58bee3caccfe7f874dbc68c808a13b1139"
Error Responses:
  • 404 Not Found: Quote with specified checksum doesn’t exist
  • 400 Bad Request: Unable to retrieve collateral data

GET /attestations/raw/

Download original binary quote data. Response:
  • Content-Type: application/octet-stream
  • Content-Disposition: attachment; filename={checksum}.bin
  • Content-Length: {size} (typically 2-8KB)

HEAD /attestations/raw/

Check quote existence and size without downloading.

GET /attestations/recent

List recently uploaded quotes with pagination. Query Parameters:
  • skip (integer): Records to skip (default: 0)
  • limit (integer): Maximum records to return (default: 20)
Returns array of quote summaries:

Data Models

Quote

QuoteHeader

QuoteBody

Core attestation measurements and platform data.
Complete Field Reference: Critical Fields for Verification:
  • mrtd: Trust domain fingerprint - must match expected value
  • rtmr0-3: Software measurements - verify boot chain and application integrity
  • reportdata: Challenge-response data - must contain expected nonce/response
  • tee_tcb_svn: Platform security level - check against known vulnerabilities

QuoteCollateralV3

Cryptographic verification data from Intel PCS.
Complete Field Reference: Usage Notes:
  • Certificate Chains: Used to validate signatures back to Intel root certificates
  • CRL Data: Check for revoked certificates and compromised platforms
  • TCB Info: Contains platform security version info and vulnerability advisories
  • QE Identity: Validates the Quoting Enclave that signed the quote
  • Signatures: All signatures use ECDSA-P256 and must be validated against certificate chains

Verification Process

  1. Parse - Extract header, body, and certificates from binary quote
  2. Platform Check - Verify quote from genuine Intel SGX/TDX platform
  3. TCB Validation - Check platform firmware is current and not revoked
  4. Signature Verification - Validate using Intel-provided certificates
  5. Storage - Cache results and collateral for future access

Integration Patterns

Basic Verification Workflow

Binary File Upload:
Hex Data from dstack SDK:
Hex String Conversion:

Error Handling Best Practices

Input Format Issues:
  • 422 Unprocessable Entity: Wrong file format, corrupted data, or invalid hex
  • 400 Bad Request: Missing input, invalid hex characters, or format conflicts
Verification Issues:
  • 400 Verification Failed: Platform may be development/non-genuine
  • 404 Not Found: Invalid checksum or quote not uploaded
  • 500 Server Error: Retry after delay, Intel PCS may be unavailable

Cache Policy

  • Quote collateral is cached for 24 hours to improve performance
  • Raw quote data and verification results are stored permanently
  • ETags are provided for efficient client-side caching

Security Notes

  • All quotes are publicly accessible by checksum
  • Always validate reportdata contains expected nonces/challenges
  • Check verified: true before trusting quote contents
  • Verification depends on Intel’s Provisioning Certification Service

Need help getting started? Check out our quick start guide for a 5-minute walkthrough.