service_profiles
Creates, updates, deletes or gets a service_profile resource or lists service_profiles in a region
Overview
| Name | service_profiles |
| Type | Resource |
| Description | An example resource schema demonstrating some basic constructs and validation rules. |
| Id | awscc.iotwireless.service_profiles |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
name | string | Name of service profile |
lo_ra_wan | object | LoRaWAN supports all LoRa specific attributes for service profile for CreateServiceProfile operation |
tags | array | A list of key-value pairs that contain metadata for the service profile. |
arn | string | Service profile Arn. Returned after successful create. |
id | string | Service profile Id. Returned after successful create. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
id | string | Service profile Id. Returned after successful create. |
region | string | AWS region. |
For more information, see AWS::IoTWireless::ServiceProfile.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | service_profiles | INSERT | , region |
delete_resource | service_profiles | DELETE | Identifier, region |
update_resource | service_profiles | UPDATE | Identifier, PatchDocument, region |
list_resources | service_profiles_list_only | SELECT | region |
get_resource | service_profiles | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual service_profile.
SELECT
region,
name,
lo_ra_wan,
tags,
arn,
id
FROM awscc.iotwireless.service_profiles
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}';
Lists all service_profiles in a region.
SELECT
region,
id
FROM awscc.iotwireless.service_profiles_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new service_profile resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.iotwireless.service_profiles (
,
region
)
SELECT
'{{ }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.iotwireless.service_profiles (
Name,
LoRaWAN,
Tags,
region
)
SELECT
'{{ name }}',
'{{ lo_ra_wan }}',
'{{ tags }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: service_profile
props:
- name: name
value: '{{ name }}'
- name: lo_ra_wan
value:
ul_rate: '{{ ul_rate }}'
ul_bucket_size: '{{ ul_bucket_size }}'
ul_rate_policy: '{{ ul_rate_policy }}'
dl_rate: '{{ dl_rate }}'
dl_bucket_size: '{{ dl_bucket_size }}'
dl_rate_policy: '{{ dl_rate_policy }}'
add_gw_metadata: '{{ add_gw_metadata }}'
dev_status_req_freq: '{{ dev_status_req_freq }}'
report_dev_status_battery: '{{ report_dev_status_battery }}'
report_dev_status_margin: '{{ report_dev_status_margin }}'
dr_min: '{{ dr_min }}'
dr_max: '{{ dr_max }}'
channel_mask: '{{ channel_mask }}'
pr_allowed: '{{ pr_allowed }}'
hr_allowed: '{{ hr_allowed }}'
ra_allowed: '{{ ra_allowed }}'
nwk_geo_loc: '{{ nwk_geo_loc }}'
target_per: '{{ target_per }}'
min_gw_diversity: '{{ min_gw_diversity }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a service_profile resource, using stack-deploy.
/*+ update */
UPDATE awscc.iotwireless.service_profiles
SET PatchDocument = string('{{ {
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.iotwireless.service_profiles
WHERE
Identifier = '{{ id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the service_profiles resource, the following permissions are required:
- Create
- Update
- Read
- Delete
- List
iotwireless:CreateServiceProfile,
iotwireless:TagResource
iotwireless:GetServiceProfile,
iotwireless:TagResource,
iotwireless:UntagResource
iotwireless:GetServiceProfile,
iotwireless:ListTagsForResource
iotwireless:DeleteServiceProfile
iotwireless:ListServiceProfiles,
iotwireless:ListTagsForResource