Denvr AI Services Docs
  • Welcome to Denvr AI Services Docs!
  • OVERVIEW
    • Getting started
      • Launch a virtual machine
      • Secure Shell (SSH): Best Practices
      • API Usage samples
      • Registration
    • Data centers
    • Shared responsibility model
    • Technical support
    • What's new!
  • PLATFORM
    • Dashboard
    • Applications
    • Virtual machines
    • Bare metal
    • Storage
    • Networking
    • User management
    • Billing
  • API Reference
    • Authentication
    • Clusters
    • Applications
    • Virtual machines
    • VPCs
    • Bare metal
  • Additional Information
    • FAQs
      • Desktop vs data center GPUs
      • Differences of bare metal and virtual machines
      • GPU monitoring
      • Using Github with SSH keys
      • Data persistence and recovery
      • Do you support Kubernetes?
      • Installing GPU drivers
      • What is the network bandwidth?
      • What ports are publicly accessible?
      • What is persistent local storage?
      • Adding DAS to /etc/fstab
      • Provisioning States
    • Policies
      • Terms of Service
      • Privacy Policy
      • Maintenance policy
Powered by GitBook
On this page
  • Authenticate
  • /api/v1/clusters/GetAll
  • /api/v1/servers/virtual/CreateServer
  1. OVERVIEW
  2. Getting started

API Usage samples

Authenticate

curl -X 'POST' \
  'https://api.cloud.denvrdata.com/api/TokenAuth/Authenticate' \
  -H 'accept: text/plain' \
  -H 'Content-Type: application/json-patch+json' \
  -d '{
  "userNameOrEmailAddress": "YOUR_EMAIL_ADDRESS",
  "password": "YOUR_PASSWORD"
}'

Response:

{
    "result": {
        "accessToken": "eyJhbGci...",
        "encryptedAccessToken": "l6/HiYvjFp...",
        "expireInSeconds": 86400,
        "shouldResetPassword": false,
        "passwordResetCode": null,
        "userId": 12345,
        "requiresTwoFactorVerification": false,
        "twoFactorAuthProviders": null,
        "twoFactorRememberClientToken": null,
        "returnUrl": null,
        "refreshToken": "eyJhbGciOi...",
        "refreshTokenExpireInSeconds": 31536000
    },
    "targetUrl": null,
    "success": true,
    "error": null,
    "unAuthorizedRequest": false,
    "__abp": true
}

/api/v1/clusters/GetAll

curl -X 'GET' \
  'https://api.cloud.denvrdata.com/api/v1/clusters/GetAll' \
  -H 'accept: */*' \
  -H 'Content-Type: application/json-patch+json' \
  -H 'Authorization: Bearer  eyJhbGci...'

Response:

{
    "result": [
        "Hou1","Msc1"
    ],
    "targetUrl": null,
    "success": true,
    "error": null,
    "unAuthorizedRequest": false,
    "__abp": true
}

/api/v1/servers/virtual/CreateServer

curl -X 'POST' \
  'https://api.cloud.denvrdata.com/api/v1/servers/virtual/CreateServer' \
  -H 'accept: */*' \
  -H 'Content-Type: application/json-patch+json' \
  -H 'Authorization: Bearer  eyJhbGci...' \
  -d '{
  "name": "my-test-vm",
  "rpool": "on-demand",
  "vpc": "YOUR_VPC_NAME",
  "configuration": "A100_80GB_SXM_1x",
  "cluster": "Hou1",
  "ssh_keys": [
    "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQC..."
  ],
  "operatingSystemImage": "Ubuntu 22.04.4 LTS",
  "rootDiskSize": 500
}'

Response:

{
    "result": {
        "username": "YOUR_EMAIL_ADDRESS",
        "tenancy_name": "YOUR_TENANCY_NAME",
        "rpool": "on-demand",
        "directAttachedStoragePersisted": false,
        "id": "my-test-vm",
        "namespace": "YOUR_VPC_NAME",
        "configuration": "A100_80GB_SXM_1x",
        "storage": 2125,
        "gpu_type": "nvidia.com/A100SXM480GB",
        "gpus": 1,
        "vcpus": 24,
        "memory": 116,
        "ip": "",
        "privateIp": "172...",
        "image": "Ubuntu_22.04.4_LTS",
        "cluster": "Hou1",
        "status": "na",
        "storageType": "na"
    },
    "targetUrl": null,
    "success": true,
    "error": null,
    "unAuthorizedRequest": false,
    "__abp": true
}
PreviousSecure Shell (SSH): Best PracticesNextRegistration

Last updated 3 months ago