Getting Started
Installation

Installation Guide

System Requirements

Python Environment

  • Python 3.8 or higher
  • aiohttp (automatically installed for OIDC functionality)
  • Operating Systems: Linux, macOS, Windows

TypeScript/JavaScript Environment

  • Node.js 14.0.0 or higher
  • TypeScript 4.9.0 or higher (for TypeScript projects)
  • Operating Systems: Linux, macOS, Windows

Installation Methods

Python Installation

Using pip

pip install aztp-client

Using uv (Recommended for modern Python projects)

uv add aztp-client

Using poetry

poetry add aztp-client

Verify Installation

from aztp_client import Aztp
print("AZTP Client installed successfully!")

TypeScript/JavaScript Installation

Using npm

npm install aztp-client

Using yarn

yarn add aztp-client

Using pnpm

pnpm add aztp-client

Verify Installation

import { AztpClient } from 'aztp-client';
console.log("AZTP Client installed successfully!");

Environment Configuration

Required Environment Variables

# AZTP Service Configuration
export AZTP_BASE_URL=https://your-aztp-server.com
export AZTP_API_KEY=your-organization-api-key
 
# Optional: Policy Configuration
export AZTP_POLICY_ENABLED=true
export AZTP_POLICY_STRICT_MODE=false
export AZTP_POLICY_DEFAULT_ACTION=allow
export AZTP_POLICY_LOG_LEVEL=info
 
# Optional: User Context (for OIAP policies)
export USERNAME=your-username

Configuration File (Optional)

Create .aztp-config.json in your project root:

{
  "baseUrl": "https://your-aztp-server.com",
  "defaultTrustDomain": "aztp.network",
  "policy": {
    "enabled": true,
    "strictMode": false,
    "defaultAction": "allow",
    "logLevel": "info"
  },
  "security": {
    "enableSafeMcp": true,
    "validateInputs": true,
    "auditEnabled": true
  }
}

Trusted Domains Setup

AZTP Client maintains a whitelist of trusted domains. Check available domains:

Python

from aztp_client import whiteListTrustDomains
print("Available trusted domains:", whiteListTrustDomains)

TypeScript/JavaScript

import { whiteListTrustDomains } from 'aztp-client';
console.log("Available trusted domains:", whiteListTrustDomains);

Current Trusted Domains:

  • aztp.network (default)
  • gptarticles.xyz
  • gptapps.ai
  • vcagents.ai

Framework Integration

Langflow Integration

For Langflow projects, AZTP Client is automatically included:

# Already included in Langflow dependencies
from langflow.services.identity import get_identity_service
 
identity_service = get_identity_service()

FastAPI Integration

from fastapi import FastAPI, Depends
from aztp_client import Aztp
 
app = FastAPI()
 
async def get_aztp_client():
    return Aztp(api_key=os.getenv("AZTP_API_KEY"))
 
@app.post("/secure-endpoint")
async def secure_endpoint(client: Aztp = Depends(get_aztp_client)):
    agent = await client.secure_connect({}, "api-service")
    return {"identity": agent.identity.aztp_id}

Express.js Integration

import express from 'express';
import { AztpClient } from 'aztp-client';
 
const app = express();
const aztpClient = new AztpClient(process.env.AZTP_API_KEY);
 
app.post('/secure-endpoint', async (req, res) => {
  const agent = await aztpClient.secureConnect({}, 'api-service');
  res.json({ identity: agent.identity.aztpId });
});

Troubleshooting

Common Installation Issues

Python: Module Not Found

# Ensure pip is up to date
pip install --upgrade pip
 
# Install in user directory if permission issues
pip install --user aztp-client
 
# For virtual environments
python -m venv venv
source venv/bin/activate  # Linux/macOS
# or
venv\Scripts\activate  # Windows
pip install aztp-client

TypeScript: Type Definitions

# Install type definitions if needed
npm install --save-dev @types/node
 
# For TypeScript projects, ensure tsconfig.json includes:
# "moduleResolution": "node"
# "esModuleInterop": true

Network/Firewall Issues

If you encounter connection issues:

  1. Check Firewall Settings - Ensure outbound HTTPS connections are allowed
  2. Verify Base URL - Confirm AZTP service endpoint is accessible
  3. Test Connection - Use curl or ping to verify network connectivity
# Test AZTP service connectivity
curl -I https://your-aztp-server.com/health

Version Compatibility

AZTP Client VersionPython VersionNode.js VersionFeaturesRelease Date
1.0.42 (Latest)3.8+14+Full feature set, SAFE-MCP support, Identity flows, OIAP policiesAug 29, 2025
1.0.40+3.8+14+Identity flows, OIAP policiesAug 2025
1.0.30+3.8+14+Basic identity managementJul 2025

Getting Help

If you encounter issues:

  1. Check the FAQ for common solutions
  2. Review Examples for implementation patterns
  3. Enable Debug Logging for detailed error information:
import logging
logging.getLogger("aztp_client").setLevel(logging.DEBUG)
  1. Contact Support through Astha.ai (opens in a new tab) for enterprise assistance

Next Steps

After successful installation:

  1. Configure Trusted Domains - Set up your trust boundaries
  2. Create Your First Connection - Follow the quick start guide
  3. Explore Examples - See real-world implementations