Difference between revisions of "Bot Playground/Commands/avatarInfo"
From SmartBots Developers Docs
(Created page with "{{DISPLAYTITLE:{{SUBPAGENAME}}}} <onlyinclude>Returns the Second Life avatar details.</onlyinclude> <syntaxhighlight lang="javascript"> Bot.avatarInfo("0b65a122-8f77-64fe-5b2...") |
|||
Line 6: | Line 6: | ||
console.log("Avatar info:", res); | console.log("Avatar info:", res); | ||
}); | }); | ||
+ | </syntaxhighlight> | ||
+ | |||
+ | or using [[Async and await]]: | ||
+ | |||
+ | <syntaxhighlight lang="javascript"> | ||
+ | let res = await Bot.avatarInfo("0b65a122-8f77-64fe-5b2a-225d4c490d9c"); | ||
+ | console.log("Avatar info:", res); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Latest revision as of 15:46, 9 January 2021
Returns the Second Life avatar details.
Bot.avatarInfo("0b65a122-8f77-64fe-5b2a-225d4c490d9c").then(function(res) {
console.log("Avatar info:", res);
});
or using Async and await:
let res = await Bot.avatarInfo("0b65a122-8f77-64fe-5b2a-225d4c490d9c");
console.log("Avatar info:", res);
Reference
This command accepts the following parameters:
Variable | Required | Description
| |
---|---|---|---|
Input: | |||
Output: | |||
Function returns a Promise with the following data: | |||
success | bool | true if command completed successfully | |
error | string | error string if command has failed | |
about | Profile text | ||
born | SL birth day, MM/DD/YYYY | ||
identified | "1" if avatar has payment info | ||
image | Profile image UUID | ||
first_life_image | First life image UUID | ||
first_life_text | First life text | ||
mature | "1" if profile is mature | ||
online | "1" if avatar is online | ||
partner | Partner UUID (zero UUID if no partner) | ||
publish_web | "1" if profile is allowed to be published on web | ||
transacted | "1" if payment info was used | ||
url | Profile URL |
Details
See HTTP API avatar_info for more information and limitations.