Barrack API Documentation
  1. vm
Barrack API Documentation
  • Platform Documentation
    • "Authentication & Access"
    • "Getting Started"
    • "Platform Documentation"
    • "Troubleshooting"
    • vm
      • "Advanced Configuration"
      • "Boot Source Configuration"
      • "GPU Configuration"
      • "Region Selection"
      • "SSH Key Configuration"
      • "VM States & Billing"
    • storage
      • "Managing Volumes"
      • "Storage Management"
    • ssh
      • "Creating SSH Keys"
      • "Importing SSH Keys"
      • "Managing SSH Keys"
    • security
      • "Attaching Firewalls to VMs"
      • "Firewall Management"
      • "Firewall Rules"
    • dashboard
      • "Dashboard Overview"
      • "VM Management"
    • backup
      • "Creating Snapshots"
      • "Custom Images"
      • "Managing Snapshots"
      • "Restoring Snapshots"
      • "Snapshots Management"
    • account
      • "Credits System"
      • "Account Management"
  • Balance
    • Get credit balance
      GET
  • GPU Stocks
    • Get GPU stock availability
      GET
  • GPU Specs
    • Get GPU specifications
      GET
  • Regions
    • List available regions
      GET
  • Pricing
    • Get pricing information
      GET
    • Get pricing information
      POST
  • Deploy Instance
    • Create a new instance
  • Instance management
    • List instances
    • Delete instance
    • Get instance billing
    • Hibernate instance
    • Reboot instance
    • Restore hibernated instance
    • Start instance
    • Stop instance
    • Toggle public IP for instance
    • Get instance details
    • Get hibernated instances count
    • Add instance security rule
    • Remove instance security rule
  • OS Images
    • List OS images
  • SSH Keys
    • List SSH keys
    • Create SSH key
    • Get SSH key
    • Delete SSH key
  • Scripts
    • List all startup scripts
    • Create a startup script
    • Get startup script details
    • Update a startup script
    • Delete a startup script
    • Delete multiple startup scripts
  • Firewalls
    • List firewalls
    • Get firewall details
    • Attach firewall to instances
    • Get firewalls attached to instance
    • Delete firewall
    • Remove firewall rule
    • Add firewall rule
    • Create firewall
    • Get supported protocols
    • List instances available for firewall attachment
    • List instances available for firewall attachment
  • Snapshots
    • List snapshots
    • Get snapshot billing
    • List Instance eligible for snapshot creation
    • Get snapshot details
    • Delete snapshot
    • Restore snapshot
    • Create snapshot
    • Create snapshot
    • Get snapshot billing
  • Images
    • List custom images
    • Get image details
    • Delete custom image
    • Create image from snapshot
    • Get snapshot-image relationship
    • Get snapshot-image relationship list
  • AI Chat
    • Chat with AI
    • Get AI usage summary
    • Get AI usage history
    • Get available AI models
  • Volumes
    • Attach volumes to instance
    • Detach volumes from instance
    • Clone volume
    • Resize volume
    • Get volume billing
    • List available volume types
    • List volumes
    • Create volume
    • Get volume details
    • Delete volume
  • Virtual Machines
    • Get firewalls attached to instance
    • Remove instance security rule
    • List Instance eligible for snapshot creation
  • Schemas
    • AITransaction
    • AddFirewallRuleRequest
    • AddFirewallRuleResponse
    • AddVMSecurityRuleResponse
    • AttachFirewallRequest
    • AggregatedBillingResponse
    • AttachFirewallResponse
    • AttachVolumesRequest
    • AttachVolumesResponse
    • AttachedFirewall
    • BatchSnapshotImageRelationshipResponse
    • Balance
    • Billing
    • ChatCompletionsRequest
    • ChatCompletionsResponse
    • CloneVolumeRequest
    • BillingRecord
    • CloneVolumeResponse
    • BillingSummary
    • CreateFirewallRequest
    • CreateFirewallResponse
    • CreateImageFromSnapshotRequest
    • CreateSSHKeyRequest
    • CreateScriptRequest
    • CreateSnapshotRequest
    • CreateSnapshotResponse
    • CreateSSHKeyResponse
    • CurrencyEnum
    • Data
    • CreditBalanceResponse
    • DeleteFirewallResponse
    • CreateVolumeRequest
    • DeleteSnapshotResponse
    • CreateVolumeResponse
    • DeleteVMResponse
    • DetachVolumesRequest
    • DetachVolumesResponse
    • DeploymentRequest
    • DirectionEnum
    • DeploymentResponse
    • EthertypeEnum
    • ErrorResponse
    • FirewallAttachment
    • DeleteVolumeResponse
    • DeleteSSHKeyResponse
    • FirewallEnvironment
    • FirewallResponse
    • FirewallRule
    • FirewallVM
    • GetBatchSnapshotImageRelationshipsRequest
    • GetFirewallDetailsResponse
    • GPUStockConfiguration
    • GPUSpec
    • GetHibernatedVMsResponse
    • GPUStockItem
    • GPUSpecsResponse
    • GetSupportedProtocolsResponse
    • GPUStocksResponse
    • GetVMAttachedFirewallsResponse
    • GetVolumeTypesResponse
    • HibernateVMResponse
    • HibernationBillingMetrics
    • ListFirewallsResponse
    • ListUserVMsResponse
    • ListVMsResponse
    • ModelsResponse
    • GetSSHKeysResponse
    • Pagination
    • PricingRequest
    • OSImage
    • PricingResponse
    • OSImagesResponse
    • Protocol
    • GpuCountEnum
    • ProtocolEnum
    • Image
    • GpuModelEnum
    • GetVolumeDetailsResponse
    • RebootVMResponse
    • ImageCreateResponse
    • RecentHibernation
    • ImageDeleteResponse
    • GetVolumesWithNextNameResponse
    • RemoveFirewallRuleResponse
    • ImageDetailResponse
    • RemoveVMSecurityRuleResponse
    • Region
    • ImageListResponse
    • ResizeVolumeRequest
    • RegionsResponse
    • Price
    • ResizeVolumeResponse
    • ResourceTypeEnum
    • RestoreSnapshotRequest
    • RestoreSnapshotResponse
    • RestoreVMResponse
    • Snapshot
    • SnapshotImageRelationshipResponse
    • Specs
    • StartVMResponse
    • StopVMResponse
    • TierEnum
    • UpdateScriptRequest
    • UsageHistoryResponse
    • UsageSummaryResponse
    • RegionEnum
    • UserVM
    • VMDetailsResponse
    • VMFlavor
    • VMImage
    • VMInstance
    • VMResponse
    • SpecsMetadata
    • VMSecurityRule
    • VMSecurityRuleRequest
    • VMStatus
    • VMVolumeAttachment
    • Script
    • VolumeTypeEnum
    • SSHKeyResponse
    • ScriptListResponse
    • ToggleVMPublicIPResponse
    • VolumeBillingRecord
    • VolumeBillingSummary
    • VolumeHourlyBillingResponse
    • VolumeResponse
  1. vm

"VM States & Billing"

Virtual machines can exist in various states, each with different billing implications. Understanding these states helps you manage costs effectively.
ACTIVE
The VM is running with all resources allocated. This is the standard working state.
Billing: Full rate (per-minute billing)
SHUTOFF
The VM is stopped but resources remain reserved exclusively for your use.
Billing: Full rate (per-minute billing)
HIBERNATED
The VM's state is saved while hardware resources are released. Only root disk storage remains allocated.
Billing: Reduced rate ($0.01/€0.01/₹1.00 per hour)
DELETED
The VM is permanently removed with all resources released.
Billing: No charge

Per-Minute Billing#

The platform uses precise per-minute billing for optimal cost efficiency:
Billing Precision
State-Based Billing
Cost Optimization

Transitional VM States#

During operations, your VM may temporarily be in one of these states. No additional charges apply during these transitional states:
Creation States
Shutdown States
Recovery States
Removal States

Billing Rate Examples#

GPU Billing Rates per Minute#

Based on hourly rates, here are the per-minute costs:
USD Rates
EUR Rates
INR Rates
GPU ModelUSD per HourUSD per Minute
H100-SXM5-80GB$2.69$0.0448
H100-PCIe-NVLink-80GB$2.29$0.0382
H100-PCIe-80GB$2.25$0.0375
A100-SXM4-80GB-NVLink$1.59$0.0265
A100-PCIe-80GB$1.55$0.0258
L40$1.19$0.0198
RTX-A6000$0.69$0.0115
A40$0.69$0.0115

Hibernation Benefits#

Hibernation provides significant cost savings while preserving your VM state:
Cost Savings
Dramatic Cost Reduction
Hibernated VMs cost only $0.01/€0.01/₹1.00 per hour
Saves 95%+ compared to running VMs
Perfect for VMs used intermittently
Ideal for development environments
State Preservation
Complete Environment Preservation
All applications and data remain intact
Running processes are preserved
Memory state is saved
Quick restoration when needed

Hibernation Use Cases#

Development Workflows
Batch Processing
Testing Environments
Training Experiments

Cost Management Strategies#

Billing Optimization#

Short-term Usage
Development Work
Production Workloads
Long-term Projects
For Brief Tasks (< 1 hour)
Use per-minute billing advantage
Choose appropriate GPU size
Delete VM when complete
Monitor usage in real-time

State Management Best Practices#

1
Plan Your Usage
Estimate actual usage hours per day
Identify hibernation opportunities
Plan for peak and off-peak usage
Consider time zone differences for global teams
2
Implement State Management
Use hibernation for regular off-hours
Set up monitoring for usage patterns
Automate hibernation where possible
Create procedures for team members
3
Monitor and Optimize
Track actual costs vs. estimates
Identify optimization opportunities
Adjust GPU sizes based on actual needs
Regular review of hibernation effectiveness
4
Scale Efficiently
Add VMs based on actual demand
Use hibernation for overflow capacity
Consider bootable volumes for quick scaling
Monitor performance vs. cost metrics

Real-world Cost Examples#

Example Scenarios#

Development Scenario
Batch Processing
Research Project
Production Service
8-hour workday, 5 days per week
A100-PCIe-80GB:
Active time: 40 hours/week × 1.55=62/week
Hibernated: 128 hours/week × 0.01=1.28/week
**Total: 63.28/week∗∗vs.260.40 if always active
Savings: 76%

Billing Monitoring#

Real-time Cost Tracking#

Dashboard Monitoring
Track Usage in Real-time
Current VM states and costs
Hourly and daily usage summaries
Cost projections based on current usage
Historical usage patterns
Cost Optimization Tools
Optimize Your Spending
Hibernation opportunity identification
Right-sizing recommendations
Usage pattern analysis
Cost-saving suggestions

Billing FAQ#

How precise is per-minute billing?
What happens during state transitions?
How quickly can I hibernate and restore?
Are there any hibernation limitations?
How do I track my usage?
Previous
"SSH Key Configuration"
Next
"Managing Volumes"
Built with