NAV Navbar
5.3.1
shell
LUMEN API

Introduction

Welcome to the Lumen Edge API Documentation.

Lumen Edge is a powerful cloud management tool that provides provisioning, monitoring, logging, backups, and application deployment strategies.

This document describes the Lumen Edge API protocol and the available endpoints. Sections are organized in the same manner as they appear in the Lumen Edge UI.

Sections

Section Description
Operations Dashboard, Reports, Activity
Provisioning Instances
Infrastructure Groups
Administration Users

ID Code Tables

To access various resources through this API, you will need to specify ID Codes corresponding to a matching resource. Tables for each resource type have been included below.

Layout Table

Operating System ID Code
CentOS 7.9 3898
CentOS 8.3 3901
Ubuntu 18.04 3904
Ubuntu 20.04 3907

Server Plans Table

Plan ID Code Ram (GB) Storage (GB) CPUs
Large 1208 768 32200 32
Medium 1229 384 7680 32

Clouds Table

Cloud Cloud ID Code Resource Pool ID Code(s)
Lumen Edge Computing Solutions 11 71

Locations Table

Location ID Code
Albany, NY ALBYNYVPLEC
Albuquerque, NM ALBQNMMALEC
Amarillo, TX AMRMTXAMLEC
Amsterdam, NL AMSTNLAQLEC
Atlanta, GA ATLDGAUYLEC
Austin, TX AUSTTXUHLEC
Billings, MT BLNGTMALEC
Boise, ID BOISIDMALEC
Broadview, IL BRVWILCULEC
Cambridge, MA CMBRMAORLEC
Casper, WY CSPRWYMALEC
Cedar Rapids, IA CDRRIADTLEC
Charlotte, NC CHRLNCRLLEC
Cincinnati, OH CNCNOHBVLEC
Cleveland, OH CLEVOH97LEC
Dallas, TX DLLATX37LEC
Denver, CO DNVTCO56LEC
Detroit, MI DTRTMITKLEC
El Paso, TX ELPUTXAYLEC
Frankfurt, Germany FRNKGEATLEC
Fresno,CA FRSMCA15LEC
Herndon, VA HRNDVAIZLEC
Honolulu, HI MLUAHIAKLEC
Houston, TX HSTQTX02LEC
Indianapolis, IN IPLWINROLEC
Jackson, MS JCSNMS91LEC
Jacksonville, FL JCVLFLAILEC
Kansas City, MO KSCBMOVSLEC
Las Vegas, NV NLVGNVBVLEC
Lachine, QC LCHNPQEQLEC
Little Rock, AR LTRKARDRLEC
London, England LONDENEHLEC
Madison, WI MDSNWIUQLEC
McAllan, TX MCAMTXKNLEC
Metairie, LA MTRELANJLEC
Miami, FL MIATFLADLEC
Minnetonka, MN MNNTMNICLEC
Munich, DE MNCHGEAOLEC
Nashville, TN NSVMTN17LEC
New York, NY NYCPNYYKLEC
Omaha, NE OMALNEUNLEC
Paris, France PARSFRAWLEC
Philadelphia, PA PHLAPAFGLEC
Phoenix, AZ PHNDAZ91LEC
Pittsburgh, PA PITEPADTLEC
Portland, OR PTLGORIALEC
Reno, NV RENPNVARLEC
Salt Lake City, UT SLKDUTTXLEC
San Antonio, TX SNAQTXKYLEC
San Diego, CA SNDACAGLLEC
Santa Clara, CA SNTDCADZLEC
Seattle, WA STTNWAHOLEC
Spokane, WA SPKNWA01LEC
St. Louis,MO STLSMOPLLEC
Tampa, FL TAMRFLWSLEC
Toronto,CA TORVONRFLEC
Tulsa, OK TULUOKBRLEC
Tustin, CA TUSTCAFTLEC
Vancouver, BC VANCBCHCLEC
West Sacramento, CA WSCRCAHWLEC

Network Type / Bandwidth

Network Type Bandwidth
Internet 100 Mbps
Internet 500 Mbps
Internet 1 Gbps
Internet 2 Gbps
Internet 5 Gbps
Internet 10 Gbps
Internet 20 Gbps
Internet 30 Gbps

Operations

The Operations API endpoints provide insight into the Lumen Edge dashboard, activity, reports and health.

Dashboard

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/dashboard" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "success": true,
  "monitoring": {
    "avgHealth": 8.3333333333,
    "avgResponseTime": 22.3333333333,
    "warningApps": 0,
    "warningChecks": 0,
    "failApps": 0,
    "totalApps": 2,
    "failChecks": 1,
    "successApps": 2,
    "mutedApps": 0,
    "successChecks": 5,
    "totalChecks": 6,
    "mutedChecks": 0,
    "responseTimes": [
      0,
      2,
      2,
      125,
      5,
      0,
      0
    ],
    "allSuccess": false,
    "openIncidents": 0
  },
  "provisioning": {
    "instanceCount": 3,
    "favoriteInstances": [
      {
        "id": 319,
        "accountId": 1,
        "instanceType": {
          "id": 6,
          "code": "webservercustom",
          "category": "web",
          "name": "web server custom"
        },
        "zones": [
          {
            "id": 40,
            "accountId": 1,
            "groups": [
              1
            ],
            "name": "custom-cloud2",
            "description": null,
            "location": null,
            "visibility": "private",
            "zoneTypeId": 9
          }
        ],
        "layout": {
          "id": 1292,
          "code": "webserver-2.4-ubuntu-16.04-single",
          "name": "Webserver Ubuntu",
          "description": "This will provision a single process with no redundancy",
          "sortOrder": 10
        },
        "plan": {
          "name": "Basic_A0 (1 Core, 0.75GB Memory) (westus)",
          "id": 187,
          "code": "custom.cloud.plan.westus.Basic_A0"
        },
        "name": "test-webserver1",
        "displayName": "test-webserver1",
        "description": null,
        "dateCreated": "2019-09-18T16:07:47Z",
        "lastUpdated": "2019-10-25T09:12:29Z",
        "status": "unknown",
        "containerIds": [
          317
        ],
        "containers": [
          {
            "ip": "0.0.0.0",
            "port": {
              "id": 19,
              "exportName": "HTTP",
              "container": {
                "id": 317
              },
              "loadBalancerInstance": null,
              "primaryPort": false,
              "loadBalanceProtocol": null,
              "linkPort": true,
              "internalPort": 80,
              "export": true,
              "portType": {
                "id": 8
              },
              "displayName": "Http",
              "protocol": "http",
              "portIndex": 0,
              "externalIp": null,
              "externalPort": 80,
              "internalIp": null,
              "visible": true,
              "loadBalance": true
            }
          }
        ],
        "version": "2.4",
        "environmentPrefix": null
      }
    ]
  },
  "instanceStats": {
    "usedMemory": 479804000,
    "maxMemory": 1771446368,
    "usedStorage": 6202490880,
    "maxStorage": 55530786816,
    "running": 2,
    "total": 3,
    "totalContainers": 4
  },
  "backups": {
    "accountStats": {
      "totalSizeByDay": [
        0,
        0,
        0,
        0,
        0
      ],
      "totalSizeByDay7Days": [
        0,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "formattedTotalSize": {
        "value": "0",
        "units": "KB"
      },
      "backupCount": 3,
      "totalSize": 0,
      "success": 0,
      "failed": 0,
      "totalCompleted": 0,
      "avgSize": 0,
      "failedRate": 0,
      "successRate": 0,
      "nextFireTotal": 1,
      "backupDayCount": [
        0,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "backupDayCountTotal": 0
    }
  },
  "activity": [
    {
      "success": false,
      "name": "dev-appliance",
      "message": "Check successfully been created.",
      "ts": "2019-10-22T00:06:20Z",
      "activityType": "Monitoring",
      "accountId": 1,
      "userId": 1,
      "userName": "admin",
      "objectId": 238,
      "objectType": "MonitorCheck",
      "_id": "0276e1fc-214d-4cb3-bcf4-9ebda0b26542",
      "timestamp": "2019-10-22T00:06:20Z"
    },
    {
      "success": true,
      "name": "admin",
      "message": "User 'admin' updated. Password changed.",
      "ts": "2019-10-08T21:17:52Z",
      "activityType": "Admin",
      "accountId": 1,
      "userId": 1,
      "userName": "admin",
      "objectId": 96,
      "objectType": "User",
      "_id": "26976fe0-a722-4d20-9849-9405a95d0db9",
      "timestamp": "2019-10-08T21:17:52Z"
    }
  ]
}

This endpoint can be used to view dashboard information about the remote Lumen Edge appliance. This is an overview and summary of data available to the user that can be used to render a dashboard.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/dashboard

Reports

Provides API interfaces for viewing report results and executing new reports.

Get All Report Types

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/report-types" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "reportTypes": [
    {
      "id": 21,
      "code": "appCost",
      "name": "Application Cost",
      "category": "cost",
      "dateCreated": "2018-05-02T07:44:46+0000",
      "optionTypes": [
        {
          "id": 1073,
          "name": "endDate",
          "code": "reportType.endDate",
          "description": null,
          "fieldName": "endDate",
          "fieldLabel": "End Date",
          "fieldContext": "report",
          "fieldGroup": null,
          "fieldClass": null,
          "fieldAddOn": null,
          "fieldComponent": null,
          "placeHolder": null,
          "helpBlock": "",
          "defaultValue": null,
          "optionSource": null,
          "type": "text",
          "advanced": false,
          "required": true,
          "editable": true,
          "creatable": null,
          "config": {
          },
          "displayOrder": 2,
          "wrapperClass": null,
          "enabled": true,
          "noBlank": false,
          "dependsOnCode": null,
          "contextualDefault": false
        }
      ]
    },
    {
      "id": 26,
      "code": "workloadSummary",
      "name": "Workload Summary",
      "category": "provisioningInventory",
      "dateCreated": "2018-09-10T08:18:04+0000",
      "optionTypes": [

      ]
    }
  ],
  "meta": {
    "size": 18,
    "total": 18,
    "offset": 0,
    "max": 25
  }
}

This endpoint retrieves all available report types. A report type has optionTypes that define the parameters available when executing a report of that type. The sample response has been abbreviated.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/report-types

Query Parameters

Parameter Default Description
max 25 Max number of results to return
offset 0 Offset of records you want to load
sort name Sort order
direction asc Sort direction, use ‘desc’ to reverse sort
phrase If specified will return a partial match on name
name If specified will return an exact match on name
code If specified will return an exact match on code
category If specified will return an exact match on category

Get All Reports

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/reports" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "reportResults": [
    {
      "id": 2,
      "type": {
        "id": 21,
        "code": "appCost",
        "name": "Application Cost"
      },
      "reportTitle": "Application Cost Jun 04, 2019 19:28:02",
      "filterTitle": "Jun 04, 2019",
      "status": "ready",
      "dateCreated": "2019-06-04T23:28:02+0000",
      "lastUpdated": "2019-06-04T23:28:02+0000",
      "startDate": null,
      "endDate": null,
      "config": {
        "type": "appCost"
      },
      "createdBy": {
        "id": 1,
        "username": "root"
      }
    },
    {
      "id": 1,
      "type": {
        "id": 6,
        "code": "groupInventory",
        "name": "Group Inventory Summary"
      },
      "reportTitle": "Group Inventory Summary Jul 12, 2019 16:30:04",
      "filterTitle": "Jul 12, 2019 | All Clouds | foo:bar",
      "status": "ready",
      "dateCreated": "2019-07-12T20:30:04+0000",
      "lastUpdated": "2019-07-12T20:30:04+0000",
      "startDate": null,
      "endDate": null,
      "config": {
        "reportType": "groupInventory",
        "cloudId": "",
        "environment": "",
        "tagName": "foo",
        "tagValue": "bar"
      },
      "createdBy": {
        "id": 1,
        "username": "root"
      }
    }
  ],
  "meta": {
    "size": 2,
    "total": 2,
    "offset": 0,
    "max": 25
  }
}

This endpoint returns all reports. This is results of reports that have been executed in the past.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/reports

Query Parameters

Parameter Default Description
max 25 Max number of results to return
offset 0 Offset of records you want to load
sort name Sort order, default is dateCreated with direction desc
direction asc Sort direction, use 'desc’ to reverse sort
phrase If specified will return a partial match on name
name If specified will return an exact match on name
reportType If specified will return an exact match on report type code, accepts multiple values
category If specified will return an exact match on report type category, accepts multiple values

Get a Specific Report

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/reports/2" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "reportResult": {
    "id": 2,
    "type": {
      "id": 21,
      "code": "appCost",
      "name": "Application Cost"
    },
    "reportTitle": "Application Cost Jun 04, 2019 19:28:02",
    "filterTitle": "Jun 04, 2019",
    "status": "ready",
    "dateCreated": "2019-06-04T23:28:02+0000",
    "lastUpdated": "2019-06-04T23:28:02+0000",
    "startDate": null,
    "endDate": null,
    "config": {
      "type": "appCost"
    },
    "createdBy": {
      "id": 1,
      "username": "root"
    },
    "rows": [
      {
        "id": 536,
        "section": "header",
        "data": "{\"code\":\"totalCount\",\"name\":\"Apps\",\"value\":2",
        "displayOrder": 0
      },
      {
        "id": 535,
        "section": "header",
        "data": "{\"code\":\"totalCost\",\"name\":\"Total Cost\",\"value\":99.99,\"currency\":\"USD\"}",
        "displayOrder": 0
      },
      {
        "id": 534,
        "section": "main",
        "data": "{\"name\":\"testapp1\",\"cost\":0,\"price\":0,\"currency\":\"USD\"}",
        "displayOrder": 0
      },
      {
        "id": 533,
        "section": "main",
        "data": "{\"name\":\"testapp2\",\"cost\":99.99,\"price\":0,\"currency\":\"USD\"}",
        "displayOrder": 1
      }
    ]
  }
}

This endpoint retrieves a specific report result. The response includes the result data as rows which can be used to render the report.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/reports/:id

URL Parameters

Parameter Description
id ID of the report result

Download a Specific Report

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/reports/download/2" \
  -H "Authorization: Bearer $accessToken"

The above command returns Content-Type: "application/octet-stream" and Content-disposition: attachment;filename=reportTitle.json.

This endpoint downloads a specific report result as a file attachment. The default file format is json.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/reports/download/:id(.:format)

URL Parameters

Parameter Description
id ID of the report result
format Format of the rendered report file, json or csv. The default is .json.

Run a Report

curl -XPOST "https://api.lumen.com/EdgeServices/v1/Compute/api/reports" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{
  "report": {
    "type": "appCost",
    "startDate": "2019-01-01",
    "endDate": "2020-01-01"
  }}'

The above command returns JSON structured like getting a single report:

This endpoint execute the specified report type and create a new report result.

HTTP Request

POST https://api.lumen.com/EdgeServices/v1/Compute/api/reports

JSON Report Parameters

Parameter Default Description
type The Report Type code to be executed.

The available parameters vary by report type. Refer to the defined optionTypes for each report.

JSON Common Report Parameters

Parameter Default Description
startDate The start date for the report
endDate The end date for the report
groupId The Group ID filter for the report
cloudId The Cloud ID filter for the report

Delete a Report

curl -XDELETE "https://api.lumen.com/EdgeServices/v1/Compute/api/reports/1" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON Structured like this:

{
  "success": true
}

This endpoint will delete a report result.

HTTP Request

DELETE https://api.lumen.com/EdgeServices/v1/Compute/api/reports/:id

URL Parameters

Parameter Description
ID The ID of the report result.

Activity

This endpoint provides data about activity with the Lumen Edge appliance. User activity and other Lumen Edge events can be seen here.

The most recent activity is returned by default.

Get All Activity

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/activity" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "activity": [
    {
      "_id": "ed970f86-c2bd-4ea2-8c3e-37494c8d8c67",
      "success": false,
      "activityType": "Alert",
      "name": "test check",
      "message": "Check has successfully been deleted",
      "objectId": 239,
      "objectType": "MonitorCheck",
      "user": {
        "id": 22,
        "username": "tester"
      },
      "timestamp": "2019-10-23T19:31:54Z"
    },
    {
      "_id": "247f122a-2dd6-4d92-a945-9e1fc35d8e51",
      "success": false,
      "activityType": "Monitoring",
      "name": "dev-appliance",
      "message": "Check has successfully been updated.",
      "objectId": 238,
      "objectType": "MonitorCheck",
      "user": {
        "id": 1,
        "username": "root"
      },
      "ts": "2019-10-22T07:55:49Z"
    },
    {
      "_id": "0276e1fc-214d-4cb3-bcf4-9ebda0b26542",
      "success": false,
      "activityType": "Monitoring",
      "name": "dev-appliance",
      "message": "Check successfully been created.",
      "objectId": 238,
      "objectType": "MonitorCheck",
      "user": {
        "id": 1,
        "username": "root"
      },
      "ts": "2019-10-22T00:06:20Z"
    },
    {
      "_id": "26976fe0-a722-4d20-9849-9405a95d0db9",
      "success": true,
      "activityType": "Admin",
      "name": "julius",
      "message": "User 'julius' updated. Password changed.",
      "objectId": 96,
      "objectType": "User",
      "user": {
        "id": 1,
        "username": "root"
      },
      "ts": "2019-10-08T21:17:52Z"
    }
  ]
}

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/activity

Query Parameters

Parameter Default Description
max 25 Max number of results to return
offset 0 Offset of records you want to load
sort name Sort order
order asc Sort direction, use ‘desc’ to reverse sort
name Filter by name
phrase Filter by wildcard search of name and description
userId Filter by User ID.
tenantId Filter by Tenant ID. Only available to the master account.
timeframe month Filter by a timeframe. eg. today,yesterday,week,month,3months.
start (1 month ago) Filter by activity on or after a date(time)
end (current time) Filter by activity on or before a date(time)

History

Provides API interfaces for viewing the process history for instances.

Get All Processes

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/processes" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "processes": [
    {
      "id": 250,
      "accountId": 1,
      "uniqueId": "cebc47ec-cb2f-417a-886e-dd60cf81db26",
      "processType": {
        "code": "provision",
        "name": "provision"
      },
      "description": null,
      "subType": null,
      "subId": null,
      "zoneId": 34,
      "integrationId": null,
      "instanceId": 238,
      "containerId": 240,
      "serverId": 601,
      "containerName": "apachetest",
      "displayName": "apachetest",
      "timerCategory": "vmware",
      "timerSubCategory": "28",
      "status": "failed",
      "reason": null,
      "percent": 100.0,
      "statusEta": 348246,
      "message": null,
      "output": null,
      "error": null,
      "startDate": "2018-09-28T19:10:56+0000",
      "endDate": "2018-09-28T20:21:49+0000",
      "duration": 4253127,
      "dateCreated": "2018-09-28T19:10:56+0000",
      "lastUpdated": "2018-09-28T20:21:49+0000",
      "createdBy": {
        "username": "admin",
        "displayName": "Admin"
      },
      "updatedBy": {
        "username": "admin",
        "displayName": "Admin"
      },
      "events": [

      ]
    }
  ],
  "meta": {
    "size": 1,
    "total": 1,
    "offset": 0,
    "max": 25
  }
}

This endpoint retrieves all processes.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/processes

Query Parameters

Parameter Default Description
phrase If specified will return a partial match on displayName, message or output
instanceId Filter by instance id(s)
containerId Filter by container id(s)
serverId Filter by server id(s)
zoneId Filter by zone id(s)
appId Filter by app id(s)

Get a Specific Process

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/processes/250" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "process": {
    "id": 250,
    "accountId": 1,
    "uniqueId": "cebc47ec-cb2f-417a-886e-dd60cf81db26",
    "processType": {
      "code": "provision",
      "name": "provision"
    },
    "description": null,
    "subType": null,
    "subId": null,
    "zoneId": 34,
    "integrationId": null,
    "instanceId": 238,
    "containerId": 240,
    "serverId": 601,
    "containerName": "apachetest",
    "displayName": "apachetest",
    "timerCategory": "vmware",
    "timerSubCategory": "28",
    "status": "failed",
    "reason": null,
    "percent": 100.0,
    "statusEta": 348246,
    "message": null,
    "output": null,
    "error": null,
    "startDate": "2018-09-28T19:10:56+0000",
    "endDate": "2018-09-28T20:21:49+0000",
    "duration": 4253127,
    "dateCreated": "2018-09-28T19:10:56+0000",
    "lastUpdated": "2018-09-28T20:21:49+0000",
    "createdBy": {
      "username": "admin",
      "displayName": "Admin"
    },
    "updatedBy": {
      "username": "admin",
      "displayName": "Admin"
    },
    "events": [
      {
        "id": 940,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "54bf6265-1e86-45b4-b1a7-d4b198b13c45",
        "processType": {
          "code": "provisionResources",
          "name": "prepare resources"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:10:56+0000",
        "endDate": "2018-09-28T19:10:57+0000",
        "duration": 921,
        "dateCreated": "2018-09-28T19:10:56+0000",
        "lastUpdated": "2018-09-28T19:10:57+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 941,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "9a9791b7-0091-4ba7-be4d-e1586be3078c",
        "processType": {
          "code": "provisionImage",
          "name": "prepare image"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:10:57+0000",
        "endDate": "2018-09-28T19:11:01+0000",
        "duration": 3645,
        "dateCreated": "2018-09-28T19:10:57+0000",
        "lastUpdated": "2018-09-28T19:11:01+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 942,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "f1905796-9387-4983-ae0d-0fee5bb81f56",
        "processType": {
          "code": "provisionConfig",
          "name": "configure instance"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:01+0000",
        "endDate": "2018-09-28T19:11:01+0000",
        "duration": 28,
        "dateCreated": "2018-09-28T19:11:01+0000",
        "lastUpdated": "2018-09-28T19:11:01+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 943,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "599a0c2d-491c-4178-8b86-55b6d019d48c",
        "processType": {
          "code": "provisionDeploy",
          "name": "deploy instance"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:01+0000",
        "endDate": "2018-09-28T19:11:33+0000",
        "duration": 32219,
        "dateCreated": "2018-09-28T19:11:01+0000",
        "lastUpdated": "2018-09-28T19:11:33+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 944,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "4f4088b0-7043-4a35-82c1-00456643beaa",
        "processType": {
          "code": "provisionResize",
          "name": "resize instance"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:33+0000",
        "endDate": "2018-09-28T19:11:36+0000",
        "duration": 2896,
        "dateCreated": "2018-09-28T19:11:33+0000",
        "lastUpdated": "2018-09-28T19:11:36+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 945,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "10559e2a-6980-4443-afd4-37b7471492ba",
        "processType": {
          "code": "provisionCloudInit",
          "name": "configure cloud init"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:36+0000",
        "endDate": "2018-09-28T19:11:42+0000",
        "duration": 6152,
        "dateCreated": "2018-09-28T19:11:36+0000",
        "lastUpdated": "2018-09-28T19:11:42+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 946,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "0081e523-bfea-4664-b582-d68076943a46",
        "processType": {
          "code": "provisionLaunch",
          "name": "power on"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "complete",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:42+0000",
        "endDate": "2018-09-28T19:11:45+0000",
        "duration": 2549,
        "dateCreated": "2018-09-28T19:11:42+0000",
        "lastUpdated": "2018-09-28T19:11:45+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      },
      {
        "id": 947,
        "processId": 250,
        "accountId": 1,
        "uniqueId": "de66729e-9580-43b0-950c-f2769cd86790",
        "processType": {
          "code": "provisionNetwork",
          "name": "network wait"
        },
        "description": null,
        "refType": "container",
        "refId": 240,
        "subType": null,
        "subId": null,
        "zoneId": 34,
        "integrationId": null,
        "instanceId": 238,
        "containerId": 240,
        "serverId": 601,
        "containerName": "apachetest",
        "displayName": "apachetest",
        "status": "failed",
        "reason": null,
        "percent": 100.0,
        "statusEta": 348246,
        "message": null,
        "output": null,
        "error": null,
        "startDate": "2018-09-28T19:11:45+0000",
        "endDate": "2018-09-28T20:21:49+0000",
        "duration": 4204122,
        "dateCreated": "2018-09-28T19:11:45+0000",
        "lastUpdated": "2018-09-28T20:21:49+0000",
        "createdBy": {
          "username": "admin",
          "displayName": "Admin"
        },
        "updatedBy": {
          "username": "admin",
          "displayName": "Admin"
        }
      }
    ]
  }
}

This endpoint retrieves a specific process.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/processes/:id

URL Parameters

Parameter Description
ID The ID of the process

Get a Specific Process Event

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/processes/events/940" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "processEvent": {
    "id": 940,
    "processId": 250,
    "accountId": 1,
    "uniqueId": "54bf6265-1e86-45b4-b1a7-d4b198b13c45",
    "processType": {
      "code": "provisionResources",
      "name": "prepare resources"
    },
    "description": null,
    "refType": "container",
    "refId": 240,
    "subType": null,
    "subId": null,
    "zoneId": 34,
    "integrationId": null,
    "instanceId": 238,
    "containerId": 240,
    "serverId": 601,
    "containerName": "apachetest",
    "displayName": "apachetest",
    "status": "complete",
    "reason": null,
    "percent": 100.0,
    "statusEta": 348246,
    "message": null,
    "output": null,
    "error": null,
    "startDate": "2018-09-28T19:10:56+0000",
    "endDate": "2018-09-28T19:10:57+0000",
    "duration": 921,
    "dateCreated": "2018-09-28T19:10:56+0000",
    "lastUpdated": "2018-09-28T19:10:57+0000",
    "createdBy": {
      "username": "admin",
      "displayName": "Admin"
    },
    "updatedBy": {
      "username": "admin",
      "displayName": "Admin"
    }
  }
}

This endpoint retrieves a specific process event.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/processes/events/:id

URL Parameters

Parameter Description
ID The ID of the process event

Provisioning

The Provisioning API endpoints provide management of Instances.

Lumen Edge supports a diverse set of cloud APIs for provisioning compute and services. In order to facilitate some of these capabilities and preserve some of the diverse sets of feature sets across these plaforms it is necessary to provide a means to dynamicaly specifying provisioning options depending on what is being provisioned. Lumen Edge calls these ProvisionType. Each InstanceTypeLayout that can be provisioned has a correlating ProvisionType and each CloudType (aka ZoneType) has a list of supported provision types it is capable of provisioning. This record contains optionTypes (see section on optionTypes for specifics on how to parse this data) as well as information for building out network parameters and storage parameters by listing different storage type information.

Instances

Instances are sets of containers or vms (Lumen Edge API represents a vm as a container attached to a server) of various types that can be provisioned across the Lumen Edge stack and offer a wide range of services. There are a few important concept differentiators between what Lumen Edge calls an instance and what amazon calls an instance. In Lumen Edge an isntance can represent many vms or containers that are of a set. For example. If you wanted to spin up a Mongo sharded replicaset, that requires 7 virtual machines or 7 docker containers. Lumen Edge represents this as a singular instance with a specified layout and then represents all the associated services running within that instance as containers. If, a container record is a docker container then the serverId it belongs to is representative of the Docker Host it was provisioned onto. If the container is a virtual machine then the serverId represents the compute resource it was provisioned onto, (i.e. the virtual machine).

Get All Instances

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/instances?max=3"
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "instances": [
    {
      "id": 1530,
      "accountId": 1,
      "instanceType": {
        "id": 35,
        "code": "ubuntu",
        "category": "os",
        "name": "Ubuntu"
      },
      "group": {
        "id": 3,
        "name": "Demo"
      },
      "cloud": {
        "id": 6,
        "name": "San Mateo VMware"
      },
      "containers": [
        1798
      ],
      "servers": [
        2
      ],
      "connectionInfo": [
        {
          "ip": "192.168.162.59",
          "port": 22
        }
      ],
      "layout": {
        "id": 105
      },
      "plan": {
        "id": 12,
        "code": "vm-2048"
      },
      "name": "ah-San Mateo VMware-ubuntu",
      "description": null,
      "instanceVersion": null,
      "dateCreated": "2017-01-31T21:30:49+0000",
      "lastUpdated": "2017-02-07T22:58:26+0000",
      "hostName": "ah-San-Mateo-VMware-ubuntu",
      "domainName": null,
      "environmentPrefix": null,
      "firewallEnabled": true,
      "networkLevel": "container",
      "autoScale": false,
      "instanceContext": "production",
      "currentDeployId": null,
      "status": "running",
      "statusMessage": null,
      "errorMessage": null,
      "statusDate": "2017-01-31T21:34:07+0000",
      "statusPercent": null,
      "statusEta": null,
      "userStatus": null,
      "createdBy": {
        "id": 38
      }
    },
    {
      "id": 1653,
      "accountId": 1,
      "instanceType": {
        "id": 35,
        "code": "ubuntu",
        "category": "os",
        "name": "Ubuntu"
      },
      "group": {
        "id": 3,
        "name": "Demo"
      },
      "cloud": {
        "id": 6,
        "name": "San Mateo VMware"
      },
      "containers": [
        1945
      ],
      "servers": [
        2
      ],
      "connectionInfo": [
        {
          "ip": "192.168.163.55",
          "port": 22
        }
      ],
      "layout": {
        "id": 105
      },
      "plan": {
        "id": 11,
        "code": "vm-1024"
      },
      "name": "ah-San Mateo VMware-ubuntu-PDNStest",
      "description": null,
      "instanceVersion": null,
      "dateCreated": "2017-02-10T14:27:42+0000",
      "lastUpdated": "2017-02-10T14:31:19+0000",
      "hostName": "ah-san-mateo-vmware-ubuntu-pdnstest",
      "domainName": null,
      "environmentPrefix": null,
      "firewallEnabled": true,
      "networkLevel": "container",
      "autoScale": false,
      "instanceContext": "dev",
      "currentDeployId": null,
      "status": "running",
      "statusMessage": null,
      "errorMessage": null,
      "statusDate": "2017-02-10T14:30:43+0000",
      "statusPercent": null,
      "statusEta": null,
      "userStatus": null,
      "createdBy": {
        "id": 38
      }
    },
    {
      "id": 1624,
      "accountId": 1,
      "instanceType": {
        "id": 21,
        "code": "apache",
        "category": "web",
        "name": "Apache"
      },
      "group": {
        "id": 163,
        "name": "snow-approvals"
      },
      "cloud": {
        "id": 6,
        "name": "San Mateo VMware"
      },
      "containers": [
        1912
      ],
      "servers": [
        3
      ],
      "connectionInfo": [
        {
          "ip": "192.168.163.28",
          "port": 10009
        }
      ],
      "layout": {
        "id": 48
      },
      "plan": {
        "id": 3,
        "code": "container-256"
      },
      "name": "approval-snow-test",
      "description": null,
      "instanceVersion": null,
      "dateCreated": "2017-02-09T06:45:30+0000",
      "lastUpdated": "2017-02-09T06:53:20+0000",
      "hostName": "approval-snow-test",
      "domainName": null,
      "environmentPrefix": null,
      "firewallEnabled": true,
      "networkLevel": "container",
      "autoScale": false,
      "instanceContext": null,
      "currentDeployId": null,
      "status": "running",
      "statusMessage": null,
      "errorMessage": null,
      "statusDate": "2017-02-09T06:53:20+0000",
      "statusPercent": null,
      "statusEta": null,
      "userStatus": null,
      "owner": {
        "id": 1,
        "username": "admin"
      }
    }
  ],
  "stats": {
    "1530": {
      "usedStorage": 6776664064,
      "maxStorage": 21067075584,
      "usedMemory": 1909739520,
      "maxMemory": 2098315264,
      "usedCpu": 1.0926682792
    },
    "1653": {
      "usedStorage": 2662801408,
      "maxStorage": 10499452928,
      "usedMemory": 935444480,
      "maxMemory": 1041350656,
      "usedCpu": 0.1501000667
    },
    "1624": {
      "usedStorage": 4829184,
      "maxStorage": 3103539200,
      "usedMemory": 9113600,
      "maxMemory": 268435456,
      "usedCpu": 0
    }
  },
  "loadBalancers": [],
  "meta": {
    "offset": 0,
    "max": 25,
    "size": 3,
    "total": 21
  }
}

This endpoint retrieves a paginated list of instances.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/instances

Query Parameters

Parameter Default Description
max 25 Max number of results to return
offset 0 Offset of records you want to load
name Filter by name
phrase Filter by wildcard search of name and description
instanceType Filter by instance type code
lastUpdated Date filter, restricts query to only load instances updated timestamp is more recent or equal to the date specified
createdBy Filter by Created By (User) ID. Accepts multiple values.
status Filter by instance type status
showDeleted false If true, includes instances in pending removal status.
deleted If true, only instances in pending removal status are returned.
expireDate Filter by expireDate less than equal to specified date
expireDateMin Filter expireDate greater than or equal to the specified date
expireDays Filter by expireDays less than or equal to the specified value
expireDaysMin Filter by expireDays greater than or equal to the specified value
shutdownDate Filter by shutdownDate less than equal to the specified date
shutdownDateMin Filter by shutdownDate greater than or equal to the specified date
shutdownDays Filter by shutdownDays less than or equal to the specified value
shutdownDaysMin Filter by shutdownDays greater than or equal to the specified value
labels Filter by label(s).
tags Filter by tags (metadata). This allows filtering by arbitrary tag names and values like this tags.foo=bar.
metadata Alias for tags.

Get a Specific Instance

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1216" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "success": true,
  "instance": {
    "id": 1698,
    "accountId": 1,
    "instanceType": {
      "id": 44,
      "code": "redis",
      "category": "cache",
      "name": "Redis"
    },
    "group": {
      "id": 3,
      "name": "Demo"
    },
    "cloud": {
      "id": 6,
      "name": "San Mateo VMware"
    },
    "containers": [
      19
    ],
    "servers": [
      2
    ],
    "connectionInfo": [
      {
        "ip": "10.211.55.11",
        "port": 10000
      }
    ],
    "layout": {
      "id": 221
    },
    "plan": {
      "id": 69,
      "code": "container-512"
    },
    "name": "redistest",
    "description": null,
    "instanceVersion": null,
    "labels": [
      "web"
    ],
    "tags": [
      ["id": 55, "name": "Category", "value": "Web"]
    ],
    "maxMemory": 536870912,
    "maxStorage": 5368709120,
    "maxCores": 0,
    "maxCpu": null,
    "dateCreated": "2016-10-25T15:12:06+0000",
    "lastUpdated": "2017-02-13T19:22:00+0000",
    "hostName": "redistest",
    "domainName": null,
    "environmentPrefix": null,
    "firewallEnabled": true,
    "networkLevel": "container",
    "autoScale": false,
    "instanceContext": null,
    "currentDeployId": null,
    "status": "running",
    "statusMessage": null,
    "errorMessage": null,
    "statusDate": "2016-10-25T15:12:41+0000",
    "statusPercent": null,
    "statusEta": null,
    "userStatus": null,
    "owner": {
      "id": 1,
      "username": "admin"
    }
  },
  "stats": {
    "usedStorage": 2951,
    "maxStorage": 1073741824,
    "usedMemory": 266240,
    "maxMemory": 268435456,
    "usedCpu": 0.0418375032
  }
}

This endpoint retrieves a specific instance.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id

URL Parameters

Parameter Description
:id ID of the instance

Get Instance History

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/238/history" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "processes": [
    {
      "id": 250,
      "accountId": 1,
      "uniqueId": "cebc47ec-cb2f-417a-886e-dd60cf81db26",
      "processType": {
        "code": "provision",
        "name": "provision"
      },
      "description": null,
      "subType": null,
      "subId": null,
      "zoneId": 34,
      "integrationId": null,
      "instanceId": 238,
      "containerId": 240,
      "serverId": 601,
      "containerName": "apachetest",
      "displayName": "apachetest",
      "timerCategory": "vmware",
      "timerSubCategory": "28",
      "status": "failed",
      "reason": null,
      "percent": 100.0,
      "statusEta": 348246,
      "message": null,
      "output": null,
      "error": null,
      "startDate": "2018-09-28T19:10:56+0000",
      "endDate": "2018-09-28T20:21:49+0000",
      "duration": 4253127,
      "dateCreated": "2018-09-28T19:10:56+0000",
      "lastUpdated": "2018-09-28T20:21:49+0000",
      "createdBy": {
        "username": "admin",
        "displayName": "Admin"
      },
      "updatedBy": {
        "username": "admin",
        "displayName": "Admin"
      },
      "events": [

      ]
    }
  ],
  "meta": {
    "size": 1,
    "total": 1,
    "offset": 0,
    "max": 25
  }
}

This endpoint retrieves the process history for a specific instance.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id/history

URL Parameters

Parameter Description
:id ID of the instance

Query Parameters

Parameter Default Description
phrase If specified will return a partial match on displayName, message or output
containerId Filter by container id(s)
serverId Filter by server id(s)
zoneId Filter by zone id(s)

Create an Instance

curl -X POST "https://api.lumen.com/EdgeServices/v1/Compute/api/instances" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{
  "zoneId": 11,
  "instance": {
    "name": "api-testing",
    "site": {
      "id": 2
    },
    "instanceType": {
      "code": "centos"
    },
    "description": "Sample description",
    "instanceContext": "dev",
    "layout": {
      "id": 3518
    },
    "plan": {
      "id": 1229
    }
  },
  "config": {
    "resourcePoolId": "71",
    "customOptions": {
       "edgeLocation": "DLLATX37LEC",
       "centuryLinkNetworkType": "EDGE_COMPUTE_INTERNET",
       "edgeBandwidth": 1000
    },
     "createUser": true
  },
  "volumes": [
    {
      "id": -1,
      "rootVolume": true,
      "name": "root",
      "size": 7680,
      "sizeId": null,
      "storageType": 2,
      "datastoreId": null
    }
  ]
}'

The above command returns a similar JSON structure when submitting a GET request for a single instance

HTTP Request

POST https://api.lumen.com/EdgeServices/v1/Compute/api/instances

JSON Parameters

Parameter Required Default Description
instance Y n/a Key for name, site, instanceType layout, and plan
instance.name Y Name of the instance to be created
instance.site.id Y To know what Group ID you will use for this parameter, use the Get All Groups API that is located at here
instance.instanceType.code Y The type of instance by human readable code we want to fetch. See curl example in right pane.
instance.layout.id Y The layout id for the instance type that you want to provision. See Layout Table
instance.plan.id Y The id for the memory and storage option pre-configured within Lumen Edge. See Service Plans Table
zoneId Y The Cloud ID to provision the instance onto. See Clouds Table
evars N [] Environment Variables, an array of objects that have name and value.
copies N 1 Number of copies to provision
layoutSize N 1 Apply a multiply factor of containers/vms within the instance
servicePlanOptions N Map of custom options depending on selected service plan . An example would be maxMemory, or maxCores.
securityGroups N Key for security group configuration. It should be passed as an array of objects containing the id of the security group to assign the instance to
volumes N Key for volume configuration, see Volumes
networkInterfaces N Key for network configuration, see Network Interfaces
config Y Key for specific type configuration, see Config
labels N Array of strings (keywords)
tags N Metadata tags, Array of objects having a name and value.
metadata N Alias for tags
ports N Array of port objects, see Exposed Ports
taskSetId N The Workflow ID to execute.
taskSetName N The Workflow Name to execute.

Volumes

The (optional) volumes parameter is for LV configuration, can create additional LVs at provision It should be passed as an array of Objects with the following attributes:

Parameter Required Default Description
id N -1 The id for the LV configuration being created
rootVolume N true If set to false then a non-root LV will be created
name Y root Name/type of the LV being created
size N [from service plan] Size of the LV to be created in GBs
sizeId N Can be used to select pre-existing LV choices from Lumen Edge
storageType N Identifier for LV type
datastoreId Y The ID of the specific datastore. Auto selection can be specified as auto or autoCluster (for clusters).

Network Interfaces

The networkInterfaces parameter is for network configuration.

The Options API /api/options/zoneNetworkOptions?zoneId=5&provisionTypeId=10 can be used to see which options are available.

It should be passed as an array of Objects with the following attributes:

Parameter Required Default Description
network.id Y n/a id of the network to be used. A network group can be specified instead by prefixing its ID with networkGroup-.
networkInterfaceTypeId Y n/a The id of type of the network interface.
ipAddress Y n/a The ip address. Not applicable when using DHCP or IP Pools.

Exposed Ports

The ports parameter is for port configuration.

The layout may have default ports, which are defined in node types, that are always configured. This parameter will be for additional custom ports to be opened.

It should be passed as an array of Objects with the following attributes:

Parameter Required Default Description
port Y n/a port number. eg. 8080
name N n/a A name for the port eg. web
lb N The load balancer protocol. HTTP, HTTPS, or TCP. Default is none.

Config

The config parameter is for configuration options that are specific to each Provision Type. The Provision Types api can be used to see which options are available.

JSON Config Parameters for Lumen Edge Computing Solutions
Parameter Required Default Description
resourcePoolId Y External ID of the resource group to use for instance. see Resource Pool ID Code under Lumen Edge Computing Solutions in the Clouds Table
createUser N false Toggles the creation of a User.
customOptions.edgeLocation Y The location code of where to provision the instance. See Locations Table
customOptions.centuryLinkNetworkType Y The type of networking to attach the instance to.
customOptions.bandwidth Y The network bandwidth allocated to the instance where 1mbps = 1000. See example curl in the right pane.

Metadata

Also known as tags. Some instance types may require tags depending on their cloud environment. These are given as name-value pairs. See the curl in the right pane for the proper formatting.

-d '{
  "zoneId": 6,
  "instance": {
    ...
  }
  ...
  "tags": [
    {
      "name": "SampleName",
      "value": "SampleValue"
    }
    {
      "name": "BusinessUnit",
      "value": "QualityAssurance"
    }
  ]
  ...
}

There can be additional properties to apply to the instance. For example mysql provisioning requires a set of initial credentials. You can get a list of what these input options are by fetching the instance-types list via the instance-types api and getting available layouts as well as the provision type option types associated with the layout. Currently these input options are available from the option-types map. These however, can be overridden in the event a config options map exists on the layout object within. NOTE: See the API Document on OptionTypes for figuring out how to build property maps from them.

Updating an Instance

curl -X PUT "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{ "instance": {
  "description": "my new redis",
  "addTags": [
    {"name": "hello", "value": "world"},
    {"name": "flash", "value": "bang"}
  ],
  "removeTags": [
    {"name": "oldTag"}
  ]
  }}'

The above command returns a similar JSON structure when submitting a GET request for a single instance

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id

URL Parameters

Parameter Description
:id ID of the instance

JSON Instance Parameters

Parameter Default Description
name Unique name scoped to your account for the instance
description Optional description field
instanceContext Environment
labels Array of strings (keywords)
tags Metadata tags, Array of objects having a name and value, this adds or updates the specified tags and removes any tags not specified.
addTags Add or update value of Metadata tags, Array of objects having a name and value
removeTags Remove Metadata tags, Array of objects having a name and an optional value. If value is passed, it must match to be removed.
powerScheduleType Power Schedule ID
site.id Group ID
ownerId User ID, can be used to change instance owner.

Stop an Instance

curl -X PUT "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1/stop" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structure like this:

{
  "success": true
}

This will stop all containers running within an instance.

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id/stop

URL Parameters

Parameter Description
:id ID of the instance

Start an Instance

curl -X PUT "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1/start" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structure like this:

{
  "success": true
}

This will start all containers running within an instance.

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id/start

URL Parameters

Parameter Description
:id ID of the instance

Restart an Instance

curl -X PUT "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1/restart" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structure like this:

{
  "success": true
}

This will restart all containers running within an instance. This includes rebuilding the environment variables and applying settings to the docker containers.

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id/restart

URL Parameters

Parameter Description
:id ID of the instance

Delete an Instance

curl -XDELETE "https://api.lumen.com/EdgeServices/v1/Compute/api/instances/1" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structure like this:

{
  "success": true
}

Will delete an instance and all associated monitors and backups.

HTTP Request

DELETE https://api.lumen.com/EdgeServices/v1/Compute/api/instances/:id

URL Parameters

Parameter Description
:id ID of the instance

Query Parameters

Parameter Default Description
preserveVolumes off Preserve Volumes
keepBackups off Preserve copy of backups
releaseEIPs on Release EIPs
force off Force Delete

Groups

Groups are used to organize provisioned servers in your infrastructure. When a user on the system provisions an instance like MySQL, they can select which group to provision the instance into. This can be used to scope servers by environment or by region.

A Group may also be referred to as a Site or site.

Get All Groups

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/groups"
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "groups": [
    {
      "id": 1,
      "accountId": 1,
      "name": "Amazon East",
      "code": "amazon",
      "active": true,
      "location": null,
      "zones": [
        {
          "id": 1,
          "accountId": 1,
          "groupId": 1,
          "name": "VPC 1a",
          "description": "1a VPC Subnet",
          "location": null,
          "visibility": "private",
          "zoneTypeId": 1
        }
      ]
    }
  ]
}

This endpoint retrieves all groups and a list of zones associated with the group by id.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/groups

Query Parameters

Parameter Default Description
lastUpdated A date filter, restricts query to only load groups updated more recent or equal to the date specified
name If specified will return an exact match group

Get a Specific Group

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/groups/1" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "success": true,
  "group": {
    "id": 1,
    "accountId": 1,
    "name": "Vagrant",
    "code": null,
    "active": true,
    "location": null,
    "zones": [
      {
        "id": 1,
        "accountId": 1,
        "groupId": 1,
        "name": "Davids Laptop",
        "description": "My Laptop Vagrant",
        "location": null,
        "visibility": "private",
        "zoneTypeId": 1
      }
    ]
  }
}

This endpoint retrieves a specific group.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/groups/:id

URL Parameters

Parameter Description
ID The ID of the group to retrieve

Create a Group

curl -XPOST "https://api.lumen.com/EdgeServices/v1/Compute/api/groups" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"group":{
    "name": "My Group",
    "description": "My description",
    "location": "US EAST"
  }}'

The above command returns JSON structured like getting a single group:

HTTP Request

POST https://api.lumen.com/EdgeServices/v1/Compute/api/groups

JSON Check Group Parameters

Parameter Default Description
name A unique name scoped to your account for the group
code Optional code for use with policies
location Optional location argument for your group

Updating a Group

curl -XPUT "https://api.lumen.com/EdgeServices/v1/Compute/api/groups/1" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"group":{
    "name": "My Group",
    "location": "US EAST"
  }}'

The above command returns JSON structured like getting a single group:

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/groups/:id

JSON Check Group Parameters

Parameter Default Description
name A unique name scoped to your account for the group
code Optional code for use with policies
location Optional location for your group

Updating Group Zones

curl -XPUT "https://api.lumen.com/EdgeServices/v1/Compute/api/groups/1/update-zones" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"group":{
    "zones": [
      {"id": 1}, {"id": 2}, {"id": 5}
    ]
  }}'

The above command returns JSON Structured like this:

{
  "success": true
}

This will update the zones that are assigned to the group. Any zones that are not passed in the zones parameter will be removed from the group.

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/groups/:id/update-zones

JSON Update Group Zones Parameters

Parameter Default Description
zones An array of all the zones assigned to this group.

Delete a Group

curl -XDELETE "https://api.lumen.com/EdgeServices/v1/Compute/api/groups/1" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON Structured like this:

{
  "success": true
}

If a group has zones or servers still tied to it, a delete action will fail

HTTP Request

DELETE https://api.lumen.com/EdgeServices/v1/Compute/api/groups/:id

Administration

The Admin endpoints are for appliance administration. This currently includes management of Users.

Users

Users are meant to represent people or services that will be using the Lumen Edge appliance. Users belong to a Tenant (Account).

Get All Users

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users"
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "users": [
    {
      "id": 1,
      "accountId": 1,
      "username": "davydotcom",
      "displayName": "David Estes",
      "email": "destes@bcap.com",
      "firstName": "David",
      "lastName": "Estes",
      "dateCreated": "2015-11-10T18:58:55+0000",
      "lastUpdated": "2015-11-10T18:58:55+0000",
      "enabled": true,
      "accountExpired": false,
      "accountLocked": false,
      "passwordExpired": false,
      "roles": [
        {
          "id": 1,
          "authority": "System Admin",
          "description": "Super User"
        }
      ],
      "account": {
        "id": 1,
        "name": "Root Account"
      }
    }
  ],
  "meta": {
    "offset": 0,
    "max": 25,
    "size": 1,
    "total": 1
  },
  "global": false
}

This endpoint retrieves all users in the current user’s tenant account. Master tenant users with permission to manage subtenants can use global=true to find users across all tenants.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/users

Query Parameters

Parameter Default Description
max 25 Max number of results to return
offset 0 Offset of records you want to load
sort name Sort order
direction asc Sort direction, use ‘desc’ to reverse sort order
phrase Filter by matching any part of firstName, lastName, username, or email
username Filter by username
firstName Filter by firstName
lastName Filter by lastName
email Filter by email
lastUpdated Date filter, restricts query to only load users updated timestamp is more recent or equal to the date specified
tenantId Filter by Tenant ID. This is only available to master tenant users with permission to manage tenants and users.
global false Global (All Tenants), load users from all tenants. The default is to only see your own tenant. This is only available to master tenant users with permission to manage tenants and users.

Get All Users Across All Tenants

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users?global=true"
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like Get All Users for a Tenant

Using global=true is a way to list users across all tenants. This is only available to master tenant users with permission to manage users and tenants.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/users?global=true

Query Parameters

The same as Get All Users.

Get a Specific User

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users/1" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "user": {
    "id": 1,
    "accountId": 1,
    "username": "davydotcom",
    "displayName": "David Estes",
    "email": "destes@bcap.com",
    "firstName": "David",
    "lastName": "Estes",
    "dateCreated": "2015-11-10T18:58:55+0000",
    "lastUpdated": "2015-11-10T18:58:55+0000",
    "enabled": true,
    "accountExpired": false,
    "accountLocked": false,
    "passwordExpired": false,
    "roles": [
      {
        "id": 1,
        "authority": "System Admin",
        "description": "Super User"
      }
    ],
    "account": {
      "id": 1,
      "name": "Root Account"
    },
    "access": {
      "features": [
        {
          "id": 11,
          "code": "admin-appliance",
          "name": "Admin: Appliance Settings",
          "access": "full"
        }
      ],
      "zones": [
        {
          "id": 1,
          "name": "zone1",
          "access": "full"
        }
      ],
      "sites": [
        {
          "id": 1,
          "name": "site1",
          "access": "full"
        }
      ],
      "instanceTypes": [
        {
          "id": 123,
          "code": "centoscustom",
          "name": "centos custom",
          "access": "full"
        }
      ],
      "appTemplates": [
        {
          "id": 1,
          "name": "Blank Apache",
          "access": "full"
        }
      ]
    }
  }
}

This endpoint will retrieve a specific user by id if the user has permission to access the user.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/users/:id

URL Parameters

Parameter Description
id The ID of the User

Query Parameters

Parameter Default Description
includeAccess Include access the user payload

Create a User

curl -XPOST "https://api.lumen.com/EdgeServices/v1/Compute/api/users" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"user":{
    "username": "testuser",
    "email": "testuser@lumen.com",
    "firstName": "Test",
    "lastName": "User",
    "password": "aStr0ngp@ssword",
    "roles": [{"id": 1}]
  }}'

The above command returns JSON structured like getting a single user

HTTP Request

POST https://api.lumen.com/EdgeServices/v1/Compute/api/users

URL Parameters

Parameter Description
accountId The ID of the User

JSON User Parameters

Parameter Default Description
username A unique username
email The user’s email
firstName The user’s first name (optional)
lastName The user’s last name (optional)
password The password to apply to the user
roles Array of objects with id of the role(s) to assign to the user. See Get Available Roles for a User.
receiveNotifications true Receive Notifications?
linuxUsername Linux Username, user settings for provisioning
linuxPassword Linux Password, user settings for provisioning
linuxKeyPairId Linux SSH Key, user settings for provisioning
windowsUsername Windows Username, user settings for provisioning
windowsPassword Windows Password, user settings for provisioning

Create a User For a Tenant

curl -XPOST "https://api.lumen.com/EdgeServices/v1/Compute/api/accounts/2/users" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"user":{
    "username": "testuser",
    "email": "testuser@lumen.com",
    "firstName": "Test",
    "lastName": "User",
    "password": "aStr0ngp@ssword",
    "roles": [{"id": 3}]
  }}'

The above command returns JSON structured like getting a single user

HTTP Request

POST https://api.lumen.com/EdgeServices/v1/Compute/api/accounts/:accountId/users

URL Parameters

Parameter Description
accountId The ID of the Tenant

JSON User Parameters

The same as Create a User.

This creates a user in a specific tenant. This is only available to master tenant users with permission to manage users and tenants.

See Get Available Roles for a Sub Tenant User to find roles available to the user.

Updating a User

curl -XPUT "https://api.lumen.com/EdgeServices/v1/Compute/api/users/2" \
  -H "Authorization: Bearer $accessToken" \
  -H "Content-Type: application/json" \
  -d '{"user":{
    "username": "testUser",
    "firstName": "Jane",
    "lastName": "Doe",
    "password": "aStr0ngp@ssword",
    "roles": [{"id": 1}]
  }}'

The above command returns JSON structured like getting a single user

HTTP Request

PUT https://api.lumen.com/EdgeServices/v1/Compute/api/users/:id

JSON User Parameters

Parameter Default Description
username A unique username
email The user’s email
firstName The user’s first name (optional)
lastName The user’s last name (optional)
password The password to apply to the user
roles Array of objects with id of the role(s) to assign to the user. See Get Available Roles for a User.
receiveNotifications true Receive Notifications?
linuxUsername Linux Username, user settings for provisioning
linuxPassword Linux Password, user settings for provisioning
linuxKeyPairId Linux SSH Key, user settings for provisioning
windowsUsername Windows Username, user settings for provisioning
windowsPassword Windows Password, user settings for provisioning

Update a user.

Delete a User

curl -XDELETE "https://api.lumen.com/EdgeServices/v1/Compute/api/users/99" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON Structured like this:

{
  "success": true
}

Delete a user. This will disassociate the user from any instances they have previously provisioned.

HTTP Request

DELETE https://api.lumen.com/EdgeServices/v1/Compute/api/users/:id

Get a Specific User Permissions

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users/1/permissions" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "access": {
    "features": [
      {
        "id": 11,
        "code": "admin-appliance",
        "name": "Admin: Appliance Settings",
        "access": "full"
      },
      {
        "id": 13,
        "code": "admin-backupSettings",
        "name": "Admin: Backup Settings",
        "access": "none"
      }
    ],
    "zones": [
      {
        "id": 1,
        "name": "zone1",
        "access": "full"
      }
    ],
    "sites": [
      {
        "id": 2,
        "name": "site1",
        "access": "none"
      }
    ],
    "instanceTypes": [
      {
        "id": 1,
        "code": "customcentos",
        "name": "custom centos",
        "access": "full"
      }
    ],
    "appTemplates": [
      {
        "id": 1,
        "name": "Blank Apache",
        "access": "full"
      },
      {
        "id": 4,
        "name": "dand-azure-blueprint",
        "access": "none"
      }
    ]
  }
}

This will list all the permissions for a specific user.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/users/:id/permissions

Get Available Roles for a User

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users/available-roles" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "roles": [
     {
      "id": 1,
      "authority": "System Admin",
      "name": "System Admin",
      "description": "Super User",
      "roleType": null,
      "owner": null
    },
    {
      "id": 3,
      "authority": "User Admin",
      "name": "User Admin",
      "description": "Sub Tenant User Template",
      "roleType": "user",
      "owner": null
    }
  ]
}

This endpoint will retrieve a list of roles that can be assigned to a user.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/accounts/available-roles

Query Parameters

Parameter Default Description
accountId (current tenant) ID of Tenant Only available to the master account.

Get Available Roles for a Sub Tenant User

curl "https://api.lumen.com/EdgeServices/v1/Compute/api/users/available-roles?accountId={accountId}" \
  -H "Authorization: Bearer $accessToken"

The above command returns JSON structured like this:

{
  "roles": [
     {
      "id": 1,
      "authority": "System Admin",
      "name": "System Admin",
      "description": "Super User",
      "roleType": null,
      "owner": null
    },
    {
      "id": 3,
      "authority": "User Admin",
      "name": "User Admin",
      "description": "Sub Tenant User Template",
      "roleType": "user",
      "owner": null
    }
  ]
}

This endpoint will retrieve a list of roles that can be assigned to a user belonging to a sub tenant account.

NOTE Multitenant Role IDs will be different for each sub tenant account. Multitenant roles are cloned and kept in sync for each sub tenant account, so that the permissions are pruned according to the sub tenant’s assigned base role.

HTTP Request

GET https://api.lumen.com/EdgeServices/v1/Compute/api/users/available-roles?accountId=:accountId

Query Parameters

Parameter Default Description
accountId (current tenant) ID of Tenant Only available to the master account.