Skip to main content

bots

Creates, updates, deletes, gets or lists a bots resource.

Overview

Namebots
TypeResource
Idaws.wickr.bots

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
bot_idstringThe unique identifier of the bot. (pattern: <code>[\S\s]*</code>)
display_namestringThe display name of the bot that is visible to users. (pattern: <code>[\S\s]*</code>)
group_idstringThe ID of the security group to which the bot belongs. (pattern: <code>[\S\s]*</code>)
has_challengebooleanIndicates whether the bot has a password set.
last_loginstringThe timestamp of the bot's last login. (pattern: <code>[\S\s]*</code>)
pubkeystringThe public key of the bot used for encryption. (pattern: <code>[\S\s]*</code>)
statusintegerThe current status of the bot (1 for pending, 2 for active).
suspendedbooleanIndicates whether the bot is currently suspended.
unamestringThe unique username hash identifier for the bot. (pattern: <code>[\S\s]*</code>)
usernamestringThe username of the bot. (pattern: <code>[\S\s]*</code>)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_botselectnetwork_id, bot_id, regionRetrieves detailed information about a specific bot in a Wickr network, including its status, group membership, and authentication details.
list_botsselectnetwork_id, regionnextToken, maxResults, sortFields, sortDirection, displayName, username, status, groupIdRetrieves a paginated list of bots in a specified Wickr network. You can filter and sort the results based on various criteria.
create_botinsertnetwork_id, region, username, groupId, challengeCreates a new bot in a specified Wickr network. Bots are automated accounts that can send and receive messages, enabling integration with external systems and automation of tasks.
update_botupdatenetwork_id, bot_id, regionUpdates the properties of an existing bot in a Wickr network. This operation allows you to modify the bot's display name, security group, password, or suspension status.
delete_botdeletenetwork_id, bot_id, regionDeletes a bot from a specified Wickr network. This operation permanently removes the bot account and its associated data from the network.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
bot_idstringThe unique identifier of the bot to be deleted.
network_idstringThe ID of the Wickr network from which the bot will be deleted.
regionstringAWS region (default: us-east-1)
displayNamestringFilter results to only include bots with display names matching this value.
groupIdstringFilter results to only include bots belonging to this security group.
maxResultsintegerThe maximum number of bots to return in a single page. Valid range is 1-100. Default is 10.
nextTokenstringThe token for retrieving the next page of results. This is returned from a previous request when there are more results available.
sortDirectionstringThe direction to sort results. Valid values are 'ASC' (ascending) or 'DESC' (descending). Default is 'DESC'.
sortFieldsstringThe fields to sort bots by. Multiple fields can be specified by separating them with '+'. Accepted values include 'username', 'firstName', 'displayName', 'status', and 'groupId'.
statusintegerFilter results to only include bots with this status (1 for pending, 2 for active).
usernamestringFilter results to only include bots with usernames matching this value.

SELECT examples

Retrieves detailed information about a specific bot in a Wickr network, including its status, group membership, and authentication details.

SELECT
bot_id,
display_name,
group_id,
has_challenge,
last_login,
pubkey,
status,
suspended,
uname,
username
FROM aws.wickr.bots
WHERE network_id = '{{ network_id }}' -- required
AND bot_id = '{{ bot_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a new bot in a specified Wickr network. Bots are automated accounts that can send and receive messages, enabling integration with external systems and automation of tasks.

INSERT INTO aws.wickr.bots (
username,
displayName,
groupId,
challenge,
network_id,
region
)
SELECT
'{{ username }}' /* required */,
'{{ displayName }}',
'{{ groupId }}' /* required */,
'{{ challenge }}' /* required */,
'{{ network_id }}',
'{{ region }}'
RETURNING
bot_id,
display_name,
group_id,
message,
network_id,
username
;

UPDATE examples

Updates the properties of an existing bot in a Wickr network. This operation allows you to modify the bot's display name, security group, password, or suspension status.

UPDATE aws.wickr.bots
SET
displayName = '{{ displayName }}',
groupId = '{{ groupId }}',
challenge = '{{ challenge }}',
suspend = {{ suspend }}
WHERE
network_id = '{{ network_id }}' --required
AND bot_id = '{{ bot_id }}' --required
AND region = '{{ region }}' --required
RETURNING
message;

DELETE examples

Deletes a bot from a specified Wickr network. This operation permanently removes the bot account and its associated data from the network.

DELETE FROM aws.wickr.bots
WHERE network_id = '{{ network_id }}' --required
AND bot_id = '{{ bot_id }}' --required
AND region = '{{ region }}' --required
;