Installation
Install the package
Usage patterns
- Fetch API
- AI SDK integration
- HTTPS agent
The The response includes an
createAtlsFetch function returns a fetch-compatible function with attestation support:attestation property:API reference
createAtlsFetch(target)
Create an attested fetch function with a simple target string:createAtlsFetch(options)
Create with full configuration:createAtlsAgent(options)
For use withhttps.request, axios, or other HTTP clients:
closeAllSockets()
Close all open aTLS connections. Use for graceful shutdown in long-running processes:- Server processes with graceful shutdown handlers
- Test suites that need clean teardown
- CLI tools that need clean exit
Policy configuration
Policies control attestation verification requirements. Pass a policy object tocreateAtlsFetch or createAtlsAgent:
How it works
Node.js bindings connect directly to TEE endpoints via TCP (no proxy required):- TLS handshake - Establishes TLS 1.3 with session binding via EKM
- Quote retrieval - Fetches attestation quote from the server
- Verification - Validates quote against policy using Intel DCAP
- Request execution - Proceeds with HTTP request over verified channel