Empower yourself with Environmental APIs. The API makes it possible to fetch current environmental data including humidity and temperature for a single sensor (identified by IBX code and sensor ID) or for all the sensors within an IBX (identified by IBX code) in a paginated way. When fetching all sensor readings you can apply additional sort criteria.
This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.
- API version: 2.0
- Package version: 0.47.0
- Generator version: 7.4.0
- Build package: org.openapitools.codegen.languages.GoClientCodegen For more information, please visit https://docs.equinix.com/api-support.htm
Install the following dependencies:
go get github.com/stretchr/testify/assert
go get golang.org/x/net/context
Put the package under your project folder and add the following in import:
import smartview "github.com/equinix/equinix-sdk-go/services/smartview"
To use a proxy, set the environment variable HTTP_PROXY
:
os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")
Default configuration comes with Servers
field that contains server objects as defined in the OpenAPI specification.
For using other server than the one defined on index 0 set context value smartview.ContextServerIndex
of type int
.
ctx := context.WithValue(context.Background(), smartview.ContextServerIndex, 1)
Templated server URL is formatted using default variables from configuration or from context value smartview.ContextServerVariables
of type map[string]string
.
ctx := context.WithValue(context.Background(), smartview.ContextServerVariables, map[string]string{
"basePath": "v2",
})
Note, enum values are always validated and all unused variables are silently ignored.
Each operation can use different server URL defined using OperationServers
map in the Configuration
.
An operation is uniquely identified by "{classname}Service.{nickname}"
string.
Similar rules for overriding default operation server index and variables applies by using smartview.ContextOperationServerIndices
and smartview.ContextOperationServerVariables
context maps.
ctx := context.WithValue(context.Background(), smartview.ContextOperationServerIndices, map[string]int{
"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), smartview.ContextOperationServerVariables, map[string]map[string]string{
"{classname}Service.{nickname}": {
"port": "8443",
},
})
All URIs are relative to https://api.equinix.com
Class | Method | HTTP request | Description |
---|---|---|---|
AlertLogApi | GetAlertActivityLog | Get /smartview/v1/alerts/getAlertActivityLog | get alert activity logs |
AlertsApi | GetAlerts | Get /smartview/v1/alerts/getAlerts | obtain active SmartView alerts. |
DCIMPowerApi | Mixin0 | Post /power/v1/current | Fetch current power consumption data |
DCIMPowerApi | Mixin0_0 | Get /power/v1/trending | Fetch Trending Power Data. |
DCIMPowerApi | PowerV1CurrentGet | Get /power/v1/current | Fetch current power consumption data |
DefaultApi | CreateSubscription | Post /smartview/v2/streaming/subscriptions | Create subscription endpoint |
DefaultApi | DeleteSubscriptionById | Delete /smartview/v2/streaming/subscriptions/{id} | Delete subscription endpoint |
DefaultApi | GetAllSubscriptions | Get /smartview/v2/streaming/subscriptions | Get all subscription endpoint |
DefaultApi | GetSubscriptionById | Get /smartview/v2/streaming/subscriptions/{id} | Get subscription endpoint |
DefaultApi | GetSubscriptionData | Get /smartview/v2/streaming/subscriptionData/{subscriptionId} | Get subscription data via REST |
DefaultApi | UpdateSubscription | Put /smartview/v2/streaming/subscriptions/{id} | Update subscription endpoint |
SmartViewAssetsApi | GetAffectedAsset | Get /smartview/v1/asset/tagpoint/affected-assets | get affected customers assets hierarchy |
SmartViewAssetsApi | GetAsset | Get /smartview/v1/asset/list | get assets list information |
SmartViewAssetsApi | GetAssetDetails | Get /smartview/v1/asset/details | get details for an asset. |
SmartViewAssetsApi | GetCurrentTagPoint | Get /smartview/v1/asset/tagpoint/current | obtain latest tag point data |
SmartViewAssetsApi | GetTagpointTrending | Get /smartview/v1/asset/tagpoint/trending | obtain trending tag point data |
SmartViewAssetsApi | Mixin4 | Post /smartview/v1/asset/details | get asset details |
SmartViewAssetsApi | Mixin4_0 | Post /smartview/v1/asset/tagpoint/current | get current tag points data |
SmartViewAssetsApi | SearchAsset | Get /smartview/v1/asset/search | Search for Assets matching identifiers |
SmartViewEnvironmentApi | Mixin1 | Get /environment/v1/current | Get current environmental data |
SmartViewEnvironmentApi | Mixin1_0 | Get /environment/v1/listCurrent | Fetch list of environmental data |
SmartViewEnvironmentApi | Mixin1_1 | Get /environment/v1/trending | Fetch trending environmental data |
SmartViewEnvironmentalApi | GetSensorReadings | Get /smartview/v2/environmental/ibxs/{ibx}/sensors/readings | IBX sensors current readings |
SmartViewEnvironmentalApi | GetSingleSensorReadings | Get /smartview/v2/environmental/ibxs/{ibx}/sensors/{sensorId}/readings | Single sensor current value(s) |
SmartViewHierarchyAPIsApi | GetLocationHierarchy | Get /smartview/v1/hierarchy/location | Fetch the Location Hierarchy |
SmartViewHierarchyAPIsApi | GetPowerHierarchy | Get /smartview/v1/hierarchy/power | Fetch the Power Hierarchy |
- Alarm
- AlarmAssetDetails
- AlarmCurrentValueDetails
- AlarmMessageData
- AlarmStatusDetails
- AlarmTagDetails
- AlarmThresholdDetails
- Alert
- AlertActivityLog
- AlertActivityLogObj
- AlertAssetDetails
- AlertDto1
- AlertDto2
- AlertMessageData
- AlertObj
- AlertTagDetails
- AlertThresholdDetails
- AlertType
- Alerts
- ApiError
- ApiErrorAdditionalInfo
- Asset
- AssetAssetClassificationInner
- AssetDetailResponse
- AssetDetailResponsePayLoad
- AssetDetailResponseStatus
- AssetDetailResponseStatusType
- AssetDetails
- AssetDetailsGetResponse
- AssetDetailsGetResponsePayLoad
- AssetDetailsRequest
- AssetDetailsResponse
- AssetDetailsResponsePayLoad
- AssetDetailsTagPointData
- Assets
- AssetsArray
- AssetsList
- AssetsListPayLoad
- AssetsListStatus
- AssetsPayLoad
- AssetsStatus
- AwsIotCoreChannelConfiguration
- AzureChannelConfiguration
- Cabinets
- CabinetsName
- Cages
- Category
- Channel
- ChannelChannelType
- Circuits
- CircuitsMapWithCage
- CircuitsMapWithCageName
- CircuitsName
- CircuitsType
- ComparisonData
- ComparisonDataDatapoint
- ComparisonDataTrend
- ConditionalAlert
- CurrentTagPointRequest
- CurrentTagPointResponse
- CustomAlert
- CustomerAssets
- DataValue
- Environment
- EnvironmentAssetDetails
- EnvironmentData
- EnvironmentDataForArray
- EnvironmentDataPayLoad
- EnvironmentDataResponse
- EnvironmentDataResponsePayLoad
- EnvironmentDataResponseStatus
- EnvironmentDataStatus
- EnvironmentMessageData
- EnvironmentTagDetails
- EnvironmentValueWithUnit
- Environmental
- EnvironmentalLevelInner
- Error
- ErrorStatus
- ErrorStatusType
- GenericRequest
- GetAssetClassificationParameter
- GetSubscriptionDataMessageTypesParameterInner
- HierarchyNode
- HierarchyNodePayLoad
- MessageType
- MeteredPower
- MeteredPowerAssetDetails
- MeteredPowerMessageData
- MeteredPowerTagDetails
- MeteredPowerValueWithUnit
- Mixin1DataPointParameter
- Mixin1IntervalParameter
- Mixin1LevelTypeParameter
- Pagination
- Power
- PowerApparentPowerValueWithUnit
- PowerAssetDetails
- PowerCabinetRatingValueWithUnit
- PowerContractualPowerValueWithUnit
- PowerCurrentPostRequest
- PowerCurrentPostRequestLevelType
- PowerCurrentValueWithUnit
- PowerData
- PowerDataError
- PowerDataErrorStatus
- PowerDataIBX
- PowerDataPayLoad
- PowerDataPayLoadLevelType
- PowerDataResponseIBX
- PowerDataResponseIBXPayLoad
- PowerHierarchyNode
- PowerHierarchyNodeLevelType
- PowerMessage
- PowerMessageData
- PowerPeakLastSevenDaysContractualPowerValueWithUnit
- PowerPeakLastSevenDaysRatioValueWithUnit
- PowerPeakLastSevenDaysValueWithUnit
- PowerPowerConsumptionToContractualValueWithUnit
- PowerPowerFactorValueWithUnit
- PowerRealPowerValueWithUnit
- PowerSoldCurrentValueWithUnit
- PowerSoldPowerValueWithUnit
- PowerV1CurrentGetLevelTypeParameter
- RecipientsArray
- SensorReading
- SensorReadingsResponse
- Status
- StatusInfo
- SubscriptionData
- SubscriptionRequest
- SubscriptionResponse
- SubscriptionResponseStatus
- SystemAlert
- TagDetails
- TagPoint
- TagPointData
- TagPointDataArray
- TagPointDataArrayCurrent
- TagPointDataStatus
- TagPointMessageData
- TagPointTrendingData
- TagPointTrendingResponse
- TagPointTrendingResponsePayLoad
- TagPointTrendingResponsePayLoadInterval
- TagPointTrendingResponseStatus
- TagPointValueWithUnit
- Template
- TrendingEnvironmentData
- TrendingEnvironmentDataPayLoad
- TrendingPowerData
- TrendingPowerDataPayLoad
- TrendingPowerDataPayLoadInterval
- TrendingPowerDataPayLoadLevelType
- TrendingPowerDataStatus
- ValueWithUnit
- ValueWithUnitDoubleHumidityUnit
- ValueWithUnitDoubleHumidityUnitUnit
- ValueWithUnitDoubleTemperatureUnit
- ValueWithUnitDoubleTemperatureUnitUnit
- WebhookChannelConfiguration
Endpoints do not require authorization.
Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:
PtrBool
PtrInt
PtrInt32
PtrInt64
PtrFloat
PtrFloat32
PtrFloat64
PtrString
PtrTime