VRChat.Notifications (vrchat v1.20.0)
View SourceAPI calls for all endpoints tagged Notifications
.
Summary
Functions
Accept Friend Request
Accept a friend request by notification frq_
ID. Friend requests can be found using the NotificationsAPI getNotifications
by filtering of type friendRequest
.
Clear All Notifications Clear all notifications.
Delete Notification Delete a notification.
Show notification
Get a notification by notification not_
ID.
List Notifications Retrieve all of the current user's notifications.
Mark Notification As Read Mark a notification as seen.
Functions
@spec accept_friend_request(Tesla.Env.client(), String.t(), keyword()) :: {:ok, VRChat.Model.Success.t()} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
Accept Friend Request
Accept a friend request by notification frq_
ID. Friend requests can be found using the NotificationsAPI getNotifications
by filtering of type friendRequest
.
Parameters
connection
(VRChat.Connection): Connection to servernotification_id
(String.t): Must be a valid notification ID.opts
(keyword): Optional parameters
Returns
{:ok, VRChat.Model.Success.t}
on success{:error, Tesla.Env.t}
on failure
@spec clear_notifications( Tesla.Env.client(), keyword() ) :: {:ok, VRChat.Model.Success.t()} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
Clear All Notifications Clear all notifications.
Parameters
connection
(VRChat.Connection): Connection to serveropts
(keyword): Optional parameters
Returns
{:ok, VRChat.Model.Success.t}
on success{:error, Tesla.Env.t}
on failure
@spec delete_notification(Tesla.Env.client(), String.t(), keyword()) :: {:ok, VRChat.Model.Notification.t()} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
Delete Notification Delete a notification.
Parameters
connection
(VRChat.Connection): Connection to servernotification_id
(String.t): Must be a valid notification ID.opts
(keyword): Optional parameters
Returns
{:ok, VRChat.Model.Notification.t}
on success{:error, Tesla.Env.t}
on failure
@spec get_notification(Tesla.Env.client(), String.t(), keyword()) :: {:ok, VRChat.Model.Notification.t()} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
Show notification
Get a notification by notification not_
ID.
Parameters
connection
(VRChat.Connection): Connection to servernotification_id
(String.t): Must be a valid notification ID.opts
(keyword): Optional parameters
Returns
{:ok, VRChat.Model.Notification.t}
on success{:error, Tesla.Env.t}
on failure
@spec get_notifications( Tesla.Env.client(), keyword() ) :: {:ok, [VRChat.Model.Notification.t()]} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
List Notifications Retrieve all of the current user's notifications.
Parameters
connection
(VRChat.Connection): Connection to serveropts
(keyword): Optional parameters:type
(String.t): Only send notifications of this type (can useall
for all). This parameter no longer does anything, and is deprecated.:sent
(boolean()): Return notifications sent by the user. Must be false or omitted.:hidden
(boolean()): Whether to return hidden or non-hidden notifications. True only allowed on typefriendRequest
.:after
(String.t): Only return notifications sent after this Date. Ignored if type isfriendRequest
.:n
(integer()): The number of objects to return.:offset
(integer()): A zero-based offset from the default object sorting from where search results start.
Returns
{:ok, [%Notification{}, ...]}
on success{:error, Tesla.Env.t}
on failure
@spec mark_notification_as_read(Tesla.Env.client(), String.t(), keyword()) :: {:ok, VRChat.Model.Notification.t()} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}
Mark Notification As Read Mark a notification as seen.
Parameters
connection
(VRChat.Connection): Connection to servernotification_id
(String.t): Must be a valid notification ID.opts
(keyword): Optional parameters
Returns
{:ok, VRChat.Model.Notification.t}
on success{:error, Tesla.Env.t}
on failure