loader image
cloudnosys logo
Widgets API

Endpoint with Base URL: https://console.cloudnosys.com/api/v1/widgets 

Users can get data from any widget for any cloud account of their organization.

POST Request #

Headers #

Fields Value
Content-Type ‘application/json’
Authorization ACCESS_TOKEN

Body #

Fields Type Description
orgId String It is the organization id i.e myorg_3x4
cloudAccounts Array It is the list of cloud account id’s (provided by cloudnosys), for which you require widgets data,

i.e [ “dmFaJkoj8JLtQzGfccr” , ”AmFaDaAU88JLtQzasdf” ]

widget String It can be one of these possible values:

  • SecurityPosture
  • Inventory
  • Network
  • Compute
  • Storage
  • IAM
  • RisksByRegion
  • PublicallyExposedResources
  • MostCriticalResources
  • RisksByGroup
  • ComplianceOverview
  • SecurityGroups
  • Regulations
  • ComplianceStandards
  • RisksBySeverity
  • RisksByCloudAccount
  • RisksByCategory
relativeDate String It can be one of these possible values:

  • Current
  • Yesterday
  • Last Week
  • Last Month

Response body #

Status: 200

JSON representation

   “widgetId”:  String ,

   “widgetName”: String,

   “widgetDescription”: String,

   “relativeDate”: String,

   “data”:  Object

}

Sample Response Body

JSON representation
{

    “widgetId”: “SecurityPosture”,

    “widgetName”: “Security Posture”,

    “widgetDescription”: “Security Posture”,

    “relativeDate”: “Yesterday”,

    “data”: {

        “total”: 1780,

        “passed”: 1078,

        “low”: 110,

        “medium”: 118,

        “high”: 474,

        “percentage”: “61”

    }

}

Error Responses #

Status: 401 #

JSON representation

   “Status”: 401

   “message”: ERROR_MESSAGE

}

ERROR_MESSAGE
Unauthorized request!
  • Missing authentication token in headers or invalid token. 
  • Trying to access a restricted organization.

Status: 400 #

JSON representation

   “Status”: 400

   “Message”: ERROR_MESSAGE

}

ERROR_MESSAGE
Invalid request! Any of the required params in the request body is missing. i.e  orgId, cloudAccounts, relativeDate, widget.

Was this page helpful?