Skip to content

Commit

Permalink
feat: Update get and put device env vars by PIN routes (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
paigen11 authored Sep 25, 2023
2 parents 489518c + afdf6f9 commit 4c1571b
Show file tree
Hide file tree
Showing 90 changed files with 161 additions and 154 deletions.
2 changes: 1 addition & 1 deletion config.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"licenseName": "MIT",
"moduleName": "NotehubJs",
"npmRepository": "https://registry.npmjs.org",
"projectVersion": "1.0.16",
"projectVersion": "1.0.17",
"sourceFolder": "src",
"usePromises": true
}
12 changes: 10 additions & 2 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1462,9 +1462,9 @@ paths:
default:
$ref: '#/components/responses/ErrorResponse'

/v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin:
/v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin:
parameters:
- $ref: '#/components/parameters/projectUIDParam'
- $ref: '#/components/parameters/productUIDParam'
- $ref: '#/components/parameters/deviceUIDParam'

get:
Expand Down Expand Up @@ -1866,6 +1866,14 @@ components:
# NOTE: Airnote's Project UID
example: app:2606f411-dea6-44a0-9743-1130f57d77d8

productUIDParam:
name: productUID
in: path
required: true
schema:
type: string
example: com.blues.bridge:sensors

eventUIDParam:
name: eventUID
in: path
Expand Down
1 change: 0 additions & 1 deletion src/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -173,4 +173,3 @@ src/model/TowerLocation.js
src/model/Twilio.js
src/model/UpdateFleetRequest.js
src/model/UserDbRoute.js
test/model/Slack.spec.js
10 changes: 5 additions & 5 deletions src/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The OpenAPI definition for the Notehub.io API.
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

- API version: 1.0.0
- Package version: 1.0.16
- Package version: 1.0.17
- Build package: org.openapitools.codegen.languages.JavascriptClientCodegen
For more information, please visit [https://dev.blues.io/support/](https://dev.blues.io/support/)

Expand Down Expand Up @@ -131,15 +131,15 @@ All URIs are relative to *https://api.notefile.net*
| _NotehubJs.DeviceApi_ | [**enableDevice**](docs/DeviceApi.md#enableDevice) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/enable |
| _NotehubJs.DeviceApi_ | [**enableDeviceConnectivityAssurance**](docs/DeviceApi.md#enableDeviceConnectivityAssurance) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/enable-connectivity-assurance |
| _NotehubJs.DeviceApi_ | [**getDeviceEnvironmentVariables**](docs/DeviceApi.md#getDeviceEnvironmentVariables) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| _NotehubJs.DeviceApi_ | [**getDeviceEnvironmentVariablesByPin**](docs/DeviceApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.DeviceApi_ | [**getDeviceEnvironmentVariablesByPin**](docs/DeviceApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.DeviceApi_ | [**getDeviceFleets**](docs/DeviceApi.md#getDeviceFleets) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/fleets |
| _NotehubJs.DeviceApi_ | [**getDeviceHealthLog**](docs/DeviceApi.md#getDeviceHealthLog) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/health-log |
| _NotehubJs.DeviceApi_ | [**getDeviceLatest**](docs/DeviceApi.md#getDeviceLatest) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/latest |
| _NotehubJs.DeviceApi_ | [**getDevicePublicKey**](docs/DeviceApi.md#getDevicePublicKey) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/public-key |
| _NotehubJs.DeviceApi_ | [**getDeviceSessions**](docs/DeviceApi.md#getDeviceSessions) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/sessions |
| _NotehubJs.DeviceApi_ | [**handleNoteSignal**](docs/DeviceApi.md#handleNoteSignal) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/signal |
| _NotehubJs.DeviceApi_ | [**putDeviceEnvironmentVariables**](docs/DeviceApi.md#putDeviceEnvironmentVariables) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| _NotehubJs.DeviceApi_ | [**putDeviceEnvironmentVariablesByPin**](docs/DeviceApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.DeviceApi_ | [**putDeviceEnvironmentVariablesByPin**](docs/DeviceApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.DeviceApi_ | [**putDeviceFleets**](docs/DeviceApi.md#putDeviceFleets) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/fleets |
| _NotehubJs.DevicesApi_ | [**deleteProjectDevice**](docs/DevicesApi.md#deleteProjectDevice) | **DELETE** /v1/projects/{projectUID}/devices/{deviceUID} |
| _NotehubJs.DevicesApi_ | [**getDevice**](docs/DevicesApi.md#getDevice) | **GET** /v1/projects/{projectUID}/devices/{deviceUID} |
Expand All @@ -150,11 +150,11 @@ All URIs are relative to *https://api.notefile.net*
| _NotehubJs.EnvironmentVariablesApi_ | [**deleteFleetEnvironmentVariable**](docs/EnvironmentVariablesApi.md#deleteFleetEnvironmentVariable) | **DELETE** /v1/projects/{projectUID}/fleets/{fleetUID}/environment_variables/{key} |
| _NotehubJs.EnvironmentVariablesApi_ | [**deleteProjectEnvironmentVariable**](docs/EnvironmentVariablesApi.md#deleteProjectEnvironmentVariable) | **DELETE** /v1/projects/{projectUID}/environment_variables/{key} |
| _NotehubJs.EnvironmentVariablesApi_ | [**getDeviceEnvironmentVariables**](docs/EnvironmentVariablesApi.md#getDeviceEnvironmentVariables) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| _NotehubJs.EnvironmentVariablesApi_ | [**getDeviceEnvironmentVariablesByPin**](docs/EnvironmentVariablesApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.EnvironmentVariablesApi_ | [**getDeviceEnvironmentVariablesByPin**](docs/EnvironmentVariablesApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.EnvironmentVariablesApi_ | [**getFleetEnvironmentVariables**](docs/EnvironmentVariablesApi.md#getFleetEnvironmentVariables) | **GET** /v1/projects/{projectUID}/fleets/{fleetUID}/environment_variables |
| _NotehubJs.EnvironmentVariablesApi_ | [**getProjectEnvironmentVariables**](docs/EnvironmentVariablesApi.md#getProjectEnvironmentVariables) | **GET** /v1/projects/{projectUID}/environment_variables |
| _NotehubJs.EnvironmentVariablesApi_ | [**putDeviceEnvironmentVariables**](docs/EnvironmentVariablesApi.md#putDeviceEnvironmentVariables) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| _NotehubJs.EnvironmentVariablesApi_ | [**putDeviceEnvironmentVariablesByPin**](docs/EnvironmentVariablesApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.EnvironmentVariablesApi_ | [**putDeviceEnvironmentVariablesByPin**](docs/EnvironmentVariablesApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| _NotehubJs.EnvironmentVariablesApi_ | [**putFleetEnvironmentVariables**](docs/EnvironmentVariablesApi.md#putFleetEnvironmentVariables) | **PUT** /v1/projects/{projectUID}/fleets/{fleetUID}/environment_variables |
| _NotehubJs.EnvironmentVariablesApi_ | [**putProjectEnvironmentVariables**](docs/EnvironmentVariablesApi.md#putProjectEnvironmentVariables) | **PUT** /v1/projects/{projectUID}/environment_variables |
| _NotehubJs.EventApi_ | [**getFleetEvents**](docs/EventApi.md#getFleetEvents) | **GET** /v1/projects/{projectUID}/fleets/{fleetUID}/events |
Expand Down
20 changes: 10 additions & 10 deletions src/docs/DeviceApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ All URIs are relative to *https://api.notefile.net*
| [**enableDevice**](DeviceApi.md#enableDevice) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/enable |
| [**enableDeviceConnectivityAssurance**](DeviceApi.md#enableDeviceConnectivityAssurance) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/enable-connectivity-assurance |
| [**getDeviceEnvironmentVariables**](DeviceApi.md#getDeviceEnvironmentVariables) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| [**getDeviceEnvironmentVariablesByPin**](DeviceApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| [**getDeviceEnvironmentVariablesByPin**](DeviceApi.md#getDeviceEnvironmentVariablesByPin) | **GET** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| [**getDeviceFleets**](DeviceApi.md#getDeviceFleets) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/fleets |
| [**getDeviceHealthLog**](DeviceApi.md#getDeviceHealthLog) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/health-log |
| [**getDeviceLatest**](DeviceApi.md#getDeviceLatest) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/latest |
| [**getDevicePublicKey**](DeviceApi.md#getDevicePublicKey) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/public-key |
| [**getDeviceSessions**](DeviceApi.md#getDeviceSessions) | **GET** /v1/projects/{projectUID}/devices/{deviceUID}/sessions |
| [**handleNoteSignal**](DeviceApi.md#handleNoteSignal) | **POST** /v1/projects/{projectUID}/devices/{deviceUID}/signal |
| [**putDeviceEnvironmentVariables**](DeviceApi.md#putDeviceEnvironmentVariables) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables |
| [**putDeviceEnvironmentVariablesByPin**](DeviceApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables_with_pin |
| [**putDeviceEnvironmentVariablesByPin**](DeviceApi.md#putDeviceEnvironmentVariablesByPin) | **PUT** /v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin |
| [**putDeviceFleets**](DeviceApi.md#putDeviceFleets) | **PUT** /v1/projects/{projectUID}/devices/{deviceUID}/fleets |

## deleteDeviceEnvironmentVariable
Expand Down Expand Up @@ -350,7 +350,7 @@ apiInstance.getDeviceEnvironmentVariables(projectUID, deviceUID).then((data) =>

## getDeviceEnvironmentVariablesByPin

> GetDeviceEnvironmentVariables200Response getDeviceEnvironmentVariablesByPin(projectUID, deviceUID)
> GetDeviceEnvironmentVariables200Response getDeviceEnvironmentVariablesByPin(productUID, deviceUID)
Get environment variables of a device with device pin authorization

Expand All @@ -364,9 +364,9 @@ let pin = defaultClient.authentications['pin'];
pin.apiKey = 'YOUR API KEY';

let apiInstance = new NotehubJs.DeviceApi();
let projectUID = app:2606f411-dea6-44a0-9743-1130f57d77d8; // String |
let productUID = com.blues.bridge:sensors; // String |
let deviceUID = "deviceUID_example"; // String |
apiInstance.getDeviceEnvironmentVariablesByPin(projectUID, deviceUID).then((data) => {
apiInstance.getDeviceEnvironmentVariablesByPin(productUID, deviceUID).then((data) => {
console.log('API called successfully. Returned data: ' + JSON.stringify(data));
}, (error) => {
console.error(error);
Expand All @@ -378,7 +378,7 @@ apiInstance.getDeviceEnvironmentVariablesByPin(projectUID, deviceUID).then((data

| Name | Type | Description | Notes |
| -------------- | ---------- | ----------- | ----- |
| **projectUID** | **String** | |
| **productUID** | **String** | |
| **deviceUID** | **String** | |

### Return type
Expand Down Expand Up @@ -728,7 +728,7 @@ apiInstance.putDeviceEnvironmentVariables(projectUID, deviceUID, environmentVari

## putDeviceEnvironmentVariablesByPin

> EnvironmentVariables putDeviceEnvironmentVariablesByPin(projectUID, deviceUID, environmentVariables)
> EnvironmentVariables putDeviceEnvironmentVariablesByPin(productUID, deviceUID, environmentVariables)
Put environment variables of a device with device pin authorization

Expand All @@ -742,10 +742,10 @@ let pin = defaultClient.authentications['pin'];
pin.apiKey = 'YOUR API KEY';

let apiInstance = new NotehubJs.DeviceApi();
let projectUID = app:2606f411-dea6-44a0-9743-1130f57d77d8; // String |
let productUID = com.blues.bridge:sensors; // String |
let deviceUID = "deviceUID_example"; // String |
let environmentVariables = new NotehubJs.EnvironmentVariables(); // EnvironmentVariables | Environment variables to be added to the device
apiInstance.putDeviceEnvironmentVariablesByPin(projectUID, deviceUID, environmentVariables).then((data) => {
apiInstance.putDeviceEnvironmentVariablesByPin(productUID, deviceUID, environmentVariables).then((data) => {
console.log('API called successfully. Returned data: ' + JSON.stringify(data));
}, (error) => {
console.error(error);
Expand All @@ -757,7 +757,7 @@ apiInstance.putDeviceEnvironmentVariablesByPin(projectUID, deviceUID, environmen

| Name | Type | Description | Notes |
| ------------------------ | --------------------------------------------------- | ----------------------------------------------- | ----- |
| **projectUID** | **String** | |
| **productUID** | **String** | |
| **deviceUID** | **String** | |
| **environmentVariables** | [**EnvironmentVariables**](EnvironmentVariables.md) | Environment variables to be added to the device |

Expand Down
Loading

0 comments on commit 4c1571b

Please sign in to comment.