invite
Sends the group invitation to specific resident.
// HTTP request to:
// https://api.mysmartbots.com/api/simple.html
// with action=invite and required parametersInput
Variable | Required | Description |
|---|---|---|
| Yes | Must be |
| Yes | Your personal developer's API key. |
| Yes | Security code of the group you are using. |
| Optional | Same as |
| Yes | The group name (must be listed with SmartBots!). |
| Yes | The UUID of the resident. |
| Optional | The group role name (default: |
| Optional | A message to send along with the invitation. Cannot contain international characters. |
| Optional | If set to |
| Optional | Do not send another invite to this resident for X seconds. Max value: |
| Optional | A custom location string shown in statistics. Format: |
| Optional | Custom misc value shown in group invitation statistics. Max 60 characters. |
Output (Plain text)
| Command completed successfully. |
anything else | Request failed. The failure reason is returned in plain text. |
Example
Basic
POST https://api.mysmartbots.com/api/simple.html
action=invite
apikey=YOUR_API_KEY
secret=YOUR_GROUP_SECRET
group=My Group Name
slkey=00000000-0000-0000-0000-000000000000
message=Welcome!
force=1CURL
curl -X POST https://api.mysmartbots.com/api/simple.html \
-d "action=invite" \
-d "apikey=YOUR_API_KEY" \
-d "secret=YOUR_GROUP_SECRET" \
-d "group=My Group Name" \
-d "slkey=00000000-0000-0000-0000-000000000000" \
-d "message=Welcome!" \
-d "force=1"LSL
touch_start(integer num) {
string params = llDumpList2String([
"action=" + "invite",
"apikey=" + llEscapeURL(yourApiKey),
"secret=" + llEscapeURL(groupSecretCode),
"group=" + llEscapeURL("My Group Name"),
"slkey=" + (string)llDetectedKey(0),
"force=" + "1",
"message=" + llEscapeURL("Welcome!")],
"&");
llHTTPRequest(
"https://api.mysmartbots.com/api/simple.html",
[HTTP_METHOD,"POST"],
params
);
}