DOCUMENTATION
Getting Started
Patchra is an incremental extension installer that allows you to upgrade your Solana agents seamlessly without downtime. Start by integrating Patchra into your project to enable versioned rollouts and rollback capabilities.
npm install @verityx/clientCore Concepts
Versioned Rollouts
Manage your upgrades with versioning, enabling safe integration of new tools or patterns into your agents without any service interruptions.
• Upgrade process: Incremental and backward-compatible
• Rollback feature: Revert to previous versions easily
• Testing: Thorough validation before deployment
Rollback Capabilities
Instantly revert to previous versions of your agents if new functionalities introduce issues, ensuring stability and reliability.
• Reversion method: Simple command to restore
• Safety checks: Verify state before rollback
• Logs: Maintain detailed history of changes
API Endpoints
/v1/versions/:agentIdRetrieve the version history for a specific agent.
/v1/agents/deployDeploy a new version of an agent with specified features and configurations.
/v1/agents/:agentId/statusCheck the current status and version of a running agent.
/v1/agents/rollbackInitiate a rollback to a previous version of an agent.
Integration Guide
Basic Connection
import { PatchraClient } from '@verityx/client'
const client = new PatchraClient({
apiKey: process.env.VERTYX_API_KEY,
network: 'mainnet'
})
// Deploy a new agent version
const deployment = await client.deployAgent('agent_id', { features: ['newTool'] })
console.log(deployment.success) // trueRollback Procedure
// Rollback to previous version
const rollback = await client.rollbackAgent('agent_id', 'previous_version_id')
console.log(rollback.success) // trueDeveloper Notes
Rate Limits
Free tier: 100 deployments/minute. Staked tier (10K+ $PTRA): 1000 deployments/minute. Enterprise: Unlimited (custom $PTRA stake required).
Version Verification
All version updates include validation parameters. The client SDK verifies locally by default. Disable with verifyLocal: false to trust network consensus.
Error Handling
Network rejects invalid deployments immediately. Failed updates return success: false with detailed rejection reason. Always validate your agent's state before trust.