wireless_gateways
Creates, updates, deletes or gets a wireless_gateway
resource or lists wireless_gateways
in a region
Overview
Name | wireless_gateways |
Type | Resource |
Description | Create and manage wireless gateways, including LoRa gateways. |
Id | aws.iotwireless.wireless_gateways |
Fields
Name | Datatype | Description |
---|---|---|
name | string | Name of Wireless Gateway. |
description | string | Description of Wireless Gateway. |
tags | array | A list of key-value pairs that contain metadata for the gateway. |
lo_ra_wan | object | The combination of Package, Station and Model which represents the version of the LoRaWAN Wireless Gateway. |
arn | string | Arn for Wireless Gateway. Returned upon successful create. |
id | string | Id for Wireless Gateway. Returned upon successful create. |
thing_arn | string | Thing Arn. Passed into Update to associate a Thing with the Wireless Gateway. |
thing_name | string | Thing Name. If there is a Thing created, this can be returned with a Get call. |
last_uplink_received_at | string | The date and time when the most recent uplink was received. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | LoRaWAN, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all wireless_gateways
in a region.
SELECT
region,
name,
description,
tags,
lo_ra_wan,
arn,
id,
thing_arn,
thing_name,
last_uplink_received_at
FROM aws.iotwireless.wireless_gateways
WHERE region = 'us-east-1';
Gets all properties from an individual wireless_gateway
.
SELECT
region,
name,
description,
tags,
lo_ra_wan,
arn,
id,
thing_arn,
thing_name,
last_uplink_received_at
FROM aws.iotwireless.wireless_gateways
WHERE region = 'us-east-1' AND data__Identifier = '<Id>';
INSERT
example
Use the following StackQL query and manifest file to create a new wireless_gateway
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.iotwireless.wireless_gateways (
LoRaWAN,
region
)
SELECT
'{{ LoRaWAN }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.iotwireless.wireless_gateways (
Name,
Description,
Tags,
LoRaWAN,
ThingArn,
ThingName,
LastUplinkReceivedAt,
region
)
SELECT
'{{ Name }}',
'{{ Description }}',
'{{ Tags }}',
'{{ LoRaWAN }}',
'{{ ThingArn }}',
'{{ ThingName }}',
'{{ LastUplinkReceivedAt }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: wireless_gateway
props:
- name: Name
value: '{{ Name }}'
- name: Description
value: '{{ Description }}'
- name: Tags
value:
- Key: '{{ Key }}'
Value: '{{ Value }}'
- name: LoRaWAN
value:
GatewayEui: '{{ GatewayEui }}'
RfRegion: '{{ RfRegion }}'
- name: ThingArn
value: '{{ ThingArn }}'
- name: ThingName
value: '{{ ThingName }}'
- name: LastUplinkReceivedAt
value: '{{ LastUplinkReceivedAt }}'
DELETE
example
/*+ delete */
DELETE FROM aws.iotwireless.wireless_gateways
WHERE data__Identifier = '<Id>'
AND region = 'us-east-1';
Permissions
To operate on the wireless_gateways
resource, the following permissions are required:
Create
iotwireless:CreateWirelessGateway,
iotwireless:TagResource,
iotwireless:ListTagsForResource
Read
iotwireless:GetWirelessGateway,
iotwireless:ListTagsForResource
Update
iotwireless:UpdateWirelessGateway,
iotwireless:UntagResource,
iotwireless:ListTagsForResource,
iotwireless:AssociateWirelessGatewayWithThing
Delete
iotwireless:DeleteWirelessGateway,
iotwireless:DisassociateWirelessGatewayFromThing
List
iotwireless:ListWirelessGateways,
iotwireless:ListTagsForResource