weavix REST APIs allow admins to perform certain actions in an automated fashion from outside the weavix system. In order to do this, you must have a valid API key for your account. Visit Getting Started for more information.
Below you will find examples of useful weavix APIs and how they can be utilized.
Crafts
Create a craft
Creates a new craft with the specified name.
POST https://api.weavix.com/core/crafts
{
“name”: “string”
}
Get a list of all crafts
Returns a list of all the Crafts on your account. You can obtain the craftId for a specific Craft from this list.
GET https://api.weavix.com/core/crafts
Permission Groups
Get a list of all Permission Groups
Returns a list of all the Permission Groups on your account. You can obtain the groupId for a specific Permission Group from this list.
GET https://api.weavix.com/core/groups
Sites
Get a list of all Sites
Returns a list of all the Sites on your account. You can obtain the facilityID for a specific Site from this list.
GET https://api.weavix.com/track/facilities
User Management
Get a list of all users on the account
Returns a list of all the Users on your account. You can obtain the userId for a specific User from this list.
GET https://api.weavix.com/core/people/names
Get a user
Gets the user profile information of the specified user.
GET https://api.weavix.com/core/users/{id}
{id} is the user id of the user you wish to view
Delete a user
Deletes the specified user from your account.
DELETE https://api.weavix.com/core/people/{id}
{id} is the user id of the user you wish to delete
Add a user
Creates a new user on your account with all the provided information. This user will be created, but will still need to be Activated after creation.
POST https://api.weavix.com/core/people/new-user
{
"folderId": "string",
"firstName": "string",
"lastName": "string",
"email": "",
"phone": "",
"group": "string",
"facilities": [
{
"facilityId": "string",
"facilityGroup": "string"
}
],
"crafts": [
"string"
],
"locale": "en"
}
Required fields are firstName, lastName, group, and facilities (if not a global-admin).
Folders
If you’ve created folders for your users in weavix, you can specify which folder a user should be created in. The folderId is the unique identifier for that folder and can be determined by opening that folder in weavix and locating the folderId in the URL.
Permissions
Account Permissions: group (a unique identifier for one of your permission groups)
Site Permission: facilityGroup (a unique identifier for one of your permission groups)
Options for group and facilityGroup are “global-admin”, “none”, or the id of one of your Permission Groups (can be determined by the requesting a list of Permission Groups)
Sites
Site: facilityId (the unique identifier for your site)
FacilityId can be determined by requesting a list of facilities
Crafts
Multiple crafts can be assigned to a user
Crafts: (a unique identifier for one of the crafts you have created in weavix)
Locale
The locale allows you to specify the default language for the user on their weavix devices.
This must be two digit ISO 639 language code for one of the weavix supported languages. If not provided, users will be set to English ("locale": "en") by default.
Update a user
Updates an existing user on your account with all the provided information. Only updates with the keys provided, so you can choose to update just a single piece of information if you wish.
PUT https://api.weavix.com/core/people/{id}
{
"folderId": "string",
"firstName": "string",
"middleName": "string",
"lastName": "string",
"group": "string",
"sites": [
{
"facilityId": "string",
"facilityGroup": "string"
}
],
"crafts": [
"string"
],
"locale": "en"
}
{id} is the user id of the user you wish to edit.
See the above information regarding adding a user for explanations of each key.
Send a message to a channel
Get a list of all Admin Defined Channels
Returns a list of all the Admin Defined Channels on your account. You can obtain the channelId for a specific channel from this list.
GET https://api.weavix.com/core/channels
Send a message to an Admin Defined Channel
Allows you to send a message to a specific channel that will show to a user as a System Message.
POST https://api/weavix.com/api/{channelId}/message
{
"message": "string",
"senderName": "string",
"readAloud": true
}
Requires the {channelId} for the channel you wish to send a message to.
Body:
message field is the message you wish to send to the channel and is required.
senderName is the name you wish to be displayed as the sender of the message. This field is optional and if you choose to not pass in a senderName, the message will appear to be sent from "weavix Integrations".
readAloud is set to true if you want the message to be read out loud when received on a walt. If you set this to false, the message will follow the user's settings when deciding whether to read it out loud or not.
Example of sending a message to a channel:
{
"message": "Line 1 press is down. Low pressure warning.",
"senderName": "Line 1 Press",
"readAloud": true
}
Get the messages from a channel
Allows you to get all of the messages that have been sent to a channel with the provided parameters.
GET https://api/weavix.com/core/{channelId}/messages?limit={number}
Requires the channelId for the channel you wish to pull messages for. Also requires a number to limit how many messages are pulled in the query.
Additional Options
Addition Options include the ability to set a fromDate (will only search for messages after this date/time), a toDate (will only search for message prior to this date/time), and a contentType (will filter messages to only the requested type). These options are added to the end of the request URL
fromDate & toDate Format
The date options are yyyy-mm-dd
contentType Options
audio: Push-to-Talk messages
image: Picture messages
video: Video Messages
file: Attached files sent from Web Radio or the weavix Mobile App
An example with dates and content type
GET https://api.weavix.com/core/channels/{channelId}/messages?limit=50&fromDate=2023-01-20&toDate=2024-01-20&contentType=image
Send a message to an individual user
Get a list of all users on the account
Send a message to a user
Allows you to send a message to a specific user. You can specify a "Sender Name" and the message will show as a message from the specified sender.
POST https://api/weavix.com/api/admin/channel-message
{
"userId": "string",
"message": "string",
"senderName": "string",
"messageLanguage": "string",
"readAloud": true/false,
"mediaUrl": "string",
"channelImageUrl": "string",
"responseUrl": "string"
}
Body:
userId field is the ID of the user you wish to send the message to
message field is the message you wish to send to the channel and is required
senderName is the name you wish to be displayed as the sender of the message. This field is optional and if you choose to not pass in a senderName, the message will appear to be sent from "weavix Integrations".
messageLanguage field specifies the language of the message you are sending
This must be two digit ISO 639 language code for one of the weavix supported languages. If not provided, users will be set to English ("locale": "en") by default.
readAloud is set to true if you want the message to be read out loud when received on a walt. If you set this to false, the message will follow the user's settings when deciding whether to read it out loud or not.
mediaUrl field is optional. It is for any media you wish to include with your message
channelImageUrl field is optional. This field allows you to provide an image that will be used as the "profile avatar" for the message.
responseUrl field is optional. If a URL is provided in this field, if the user responds to the message, the transcript of their response will be sent to this URL.
Get results from Form submissions
Get results from a specific form
Allows you to pull all of the submissions for a specific form. Result includes the ID of the user who provided the submission and can be correlated to a user name using the Get a User call above.
GET https://api.weavix.com/v1/core/forms/{formId}/submissions
Requires the formId to be included. This formId can be found by opening the Form in the weavix Console and locating the ID at the end of the URL.