mirror of
https://github.com/mii443/vrchatapi-rust.git
synced 2025-08-22 15:45:35 +00:00
Upgrade Rust SDK to spec 1.17.3
This commit is contained in:
@ -22,6 +22,7 @@ docs/CreateGroupInviteRequest.md
|
||||
docs/CreateGroupPostRequest.md
|
||||
docs/CreateGroupRequest.md
|
||||
docs/CreateGroupRoleRequest.md
|
||||
docs/CreateInstanceRequest.md
|
||||
docs/CreateWorldRequest.md
|
||||
docs/CurrentUser.md
|
||||
docs/CurrentUserPresence.md
|
||||
@ -94,6 +95,11 @@ docs/LimitedWorld.md
|
||||
docs/MimeType.md
|
||||
docs/ModerateUserRequest.md
|
||||
docs/Notification.md
|
||||
docs/NotificationDetailInvite.md
|
||||
docs/NotificationDetailInviteResponse.md
|
||||
docs/NotificationDetailRequestInvite.md
|
||||
docs/NotificationDetailRequestInviteResponse.md
|
||||
docs/NotificationDetailVoteToKick.md
|
||||
docs/NotificationType.md
|
||||
docs/NotificationsApi.md
|
||||
docs/OrderOption.md
|
||||
@ -185,6 +191,7 @@ src/models/create_group_invite_request.rs
|
||||
src/models/create_group_post_request.rs
|
||||
src/models/create_group_request.rs
|
||||
src/models/create_group_role_request.rs
|
||||
src/models/create_instance_request.rs
|
||||
src/models/create_world_request.rs
|
||||
src/models/current_user.rs
|
||||
src/models/current_user_presence.rs
|
||||
@ -251,6 +258,11 @@ src/models/mime_type.rs
|
||||
src/models/mod.rs
|
||||
src/models/moderate_user_request.rs
|
||||
src/models/notification.rs
|
||||
src/models/notification_detail_invite.rs
|
||||
src/models/notification_detail_invite_response.rs
|
||||
src/models/notification_detail_request_invite.rs
|
||||
src/models/notification_detail_request_invite_response.rs
|
||||
src/models/notification_detail_vote_to_kick.rs
|
||||
src/models/notification_type.rs
|
||||
src/models/order_option.rs
|
||||
src/models/paginated_group_audit_log_entry_list.rs
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "vrchatapi"
|
||||
version = "1.17.2"
|
||||
version = "1.17.3"
|
||||
authors = ["vrchatapi.lpv0t@aries.fyi"]
|
||||
description = "VRChat API Client for Rust"
|
||||
license = "MIT"
|
||||
|
18
docs/CreateInstanceRequest.md
Normal file
18
docs/CreateInstanceRequest.md
Normal file
@ -0,0 +1,18 @@
|
||||
# CreateInstanceRequest
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**world_id** | **String** | WorldID be \"offline\" on User profiles if you are not friends with that user. |
|
||||
**r#type** | [**crate::models::InstanceType**](InstanceType.md) | |
|
||||
**region** | [**crate::models::Region**](Region.md) | |
|
||||
**owner_id** | Option<**String**> | A groupId if the instance type is \"group\", null if instance type is public, or a userId otherwise | [optional]
|
||||
**role_ids** | Option<**Vec<String>**> | Group roleIds that are allowed to join if the type is \"group\" and groupAccessType is \"member\" | [optional]
|
||||
**group_access_type** | Option<[**crate::models::GroupAccessType**](GroupAccessType.md)> | | [optional]
|
||||
**queue_enabled** | Option<**bool**> | | [optional][default to false]
|
||||
**closed_at** | Option<**String**> | The time after which users won't be allowed to join the instance | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
@ -44,6 +44,7 @@ Method | HTTP request | Description
|
||||
[**update_group**](GroupsApi.md#update_group) | **PUT** /groups/{groupId} | Update Group
|
||||
[**update_group_gallery**](GroupsApi.md#update_group_gallery) | **PUT** /groups/{groupId}/galleries/{groupGalleryId} | Update Group Gallery
|
||||
[**update_group_member**](GroupsApi.md#update_group_member) | **PUT** /groups/{groupId}/members/{userId} | Update Group Member
|
||||
[**update_group_post**](GroupsApi.md#update_group_post) | **PUT** /groups/{groupId}/posts/{notificationId} | Edits a Group post
|
||||
[**update_group_role**](GroupsApi.md#update_group_role) | **PUT** /groups/{groupId}/roles/{groupRoleId} | Update Group Role
|
||||
|
||||
|
||||
@ -1299,6 +1300,38 @@ Name | Type | Description | Required | Notes
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
## update_group_post
|
||||
|
||||
> crate::models::GroupPost update_group_post(group_id, notification_id, create_group_post_request)
|
||||
Edits a Group post
|
||||
|
||||
Edits a Group post
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Required | Notes
|
||||
------------- | ------------- | ------------- | ------------- | -------------
|
||||
**group_id** | **String** | Must be a valid group ID. | [required] |
|
||||
**notification_id** | **String** | Must be a valid notification ID. | [required] |
|
||||
**create_group_post_request** | [**CreateGroupPostRequest**](CreateGroupPostRequest.md) | | [required] |
|
||||
|
||||
### Return type
|
||||
|
||||
[**crate::models::GroupPost**](GroupPost.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[authCookie](../README.md#authCookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
## update_group_role
|
||||
|
||||
> Vec<crate::models::GroupRole> update_group_role(group_id, group_role_id, update_group_role_request)
|
||||
|
@ -5,6 +5,7 @@ All URIs are relative to *https://api.vrchat.cloud/api/1*
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**close_instance**](InstancesApi.md#close_instance) | **DELETE** /instances/{worldId}:{instanceId} | Close Instance
|
||||
[**create_instance**](InstancesApi.md#create_instance) | **POST** /instances | Create Instance
|
||||
[**get_instance**](InstancesApi.md#get_instance) | **GET** /instances/{worldId}:{instanceId} | Get Instance
|
||||
[**get_instance_by_short_name**](InstancesApi.md#get_instance_by_short_name) | **GET** /instances/s/{shortName} | Get Instance By Short Name
|
||||
[**get_short_name**](InstancesApi.md#get_short_name) | **GET** /instances/{worldId}:{instanceId}/shortName | Get Instance Short Name
|
||||
@ -14,10 +15,10 @@ Method | HTTP request | Description
|
||||
|
||||
## close_instance
|
||||
|
||||
> crate::models::Instance close_instance(world_id, instance_id, hard_close)
|
||||
> crate::models::Instance close_instance(world_id, instance_id, hard_close, closed_at)
|
||||
Close Instance
|
||||
|
||||
Close an instance. You can only close an instance if the ownerId is yourself or if the instance owner is a group and you have the `group-instance-moderate` permission.
|
||||
Close an instance or update the closedAt time when it will be closed. You can only close an instance if the ownerId is yourself or if the instance owner is a group and you have the `group-instance-moderate` permission.
|
||||
|
||||
### Parameters
|
||||
|
||||
@ -27,6 +28,7 @@ Name | Type | Description | Required | Notes
|
||||
**world_id** | **String** | Must be a valid world ID. | [required] |
|
||||
**instance_id** | **String** | Must be a valid instance ID. | [required] |
|
||||
**hard_close** | Option<**bool**> | Whether to hard close the instance. Defaults to false. | |
|
||||
**closed_at** | Option<**String**> | The time after which users won't be allowed to join the instances. If omitted, the instance will be closed immediately. | |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -44,6 +46,36 @@ Name | Type | Description | Required | Notes
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
## create_instance
|
||||
|
||||
> crate::models::Instance create_instance(create_instance_request)
|
||||
Create Instance
|
||||
|
||||
Create an instance
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Required | Notes
|
||||
------------- | ------------- | ------------- | ------------- | -------------
|
||||
**create_instance_request** | [**CreateInstanceRequest**](CreateInstanceRequest.md) | | [required] |
|
||||
|
||||
### Return type
|
||||
|
||||
[**crate::models::Instance**](Instance.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[authCookie](../README.md#authCookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
## get_instance
|
||||
|
||||
> crate::models::Instance get_instance(world_id, instance_id)
|
||||
|
13
docs/NotificationDetailInvite.md
Normal file
13
docs/NotificationDetailInvite.md
Normal file
@ -0,0 +1,13 @@
|
||||
# NotificationDetailInvite
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**invite_message** | Option<**String**> | | [optional]
|
||||
**world_id** | **String** | WorldID be \"offline\" on User profiles if you are not friends with that user. |
|
||||
**world_name** | **String** | |
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
12
docs/NotificationDetailInviteResponse.md
Normal file
12
docs/NotificationDetailInviteResponse.md
Normal file
@ -0,0 +1,12 @@
|
||||
# NotificationDetailInviteResponse
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**in_response_to** | **String** | |
|
||||
**response_message** | **String** | |
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
12
docs/NotificationDetailRequestInvite.md
Normal file
12
docs/NotificationDetailRequestInvite.md
Normal file
@ -0,0 +1,12 @@
|
||||
# NotificationDetailRequestInvite
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**platform** | Option<**String**> | TODO: Does this still exist? | [optional]
|
||||
**request_message** | Option<**String**> | Used when using InviteMessage Slot. | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
12
docs/NotificationDetailRequestInviteResponse.md
Normal file
12
docs/NotificationDetailRequestInviteResponse.md
Normal file
@ -0,0 +1,12 @@
|
||||
# NotificationDetailRequestInviteResponse
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**in_response_to** | **String** | |
|
||||
**request_message** | Option<**String**> | Used when using InviteMessage Slot. | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
12
docs/NotificationDetailVoteToKick.md
Normal file
12
docs/NotificationDetailVoteToKick.md
Normal file
@ -0,0 +1,12 @@
|
||||
# NotificationDetailVoteToKick
|
||||
|
||||
## Properties
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**initiator_user_id** | **String** | A users unique ID, usually in the form of `usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469`. Legacy players can have old IDs in the form of `8JoV9XEdpo`. The ID can never be changed. |
|
||||
**user_to_kick_id** | **String** | A users unique ID, usually in the form of `usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469`. Legacy players can have old IDs in the form of `8JoV9XEdpo`. The ID can never be changed. |
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
@ -106,7 +106,7 @@ Name | Type | Description | Required | Notes
|
||||
|
||||
## get_user_groups
|
||||
|
||||
> Vec<crate::models::Group> get_user_groups(user_id)
|
||||
> Vec<crate::models::LimitedGroup> get_user_groups(user_id)
|
||||
Get User Groups
|
||||
|
||||
Get user's public groups
|
||||
@ -120,7 +120,7 @@ Name | Type | Description | Required | Notes
|
||||
|
||||
### Return type
|
||||
|
||||
[**Vec<crate::models::Group>**](Group.md)
|
||||
[**Vec<crate::models::LimitedGroup>**](LimitedGroup.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
|
@ -380,6 +380,15 @@ pub enum UpdateGroupMemberError {
|
||||
UnknownValue(serde_json::Value),
|
||||
}
|
||||
|
||||
/// struct for typed errors of method [`update_group_post`]
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
pub enum UpdateGroupPostError {
|
||||
Status401(crate::models::Error),
|
||||
Status404(crate::models::Success),
|
||||
UnknownValue(serde_json::Value),
|
||||
}
|
||||
|
||||
/// struct for typed errors of method [`update_group_role`]
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
@ -1590,6 +1599,35 @@ pub fn update_group_member(configuration: &configuration::Configuration, group_i
|
||||
}
|
||||
}
|
||||
|
||||
/// Edits a Group post
|
||||
pub fn update_group_post(configuration: &configuration::Configuration, group_id: &str, notification_id: &str, create_group_post_request: crate::models::CreateGroupPostRequest) -> Result<crate::models::GroupPost, Error<UpdateGroupPostError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
||||
let local_var_client = &local_var_configuration.client;
|
||||
|
||||
let local_var_uri_str = format!("{}/groups/{groupId}/posts/{notificationId}", local_var_configuration.base_path, groupId=crate::apis::urlencode(group_id), notificationId=crate::apis::urlencode(notification_id));
|
||||
let mut local_var_req_builder = local_var_client.request(reqwest::Method::PUT, local_var_uri_str.as_str());
|
||||
|
||||
if let Some(ref local_var_user_agent) = local_var_configuration.user_agent {
|
||||
local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone());
|
||||
}
|
||||
local_var_req_builder = local_var_req_builder.json(&create_group_post_request);
|
||||
|
||||
let local_var_req = local_var_req_builder.build()?;
|
||||
let mut local_var_resp = local_var_client.execute(local_var_req)?;
|
||||
|
||||
let local_var_status = local_var_resp.status();
|
||||
let local_var_content = local_var_resp.text()?;
|
||||
|
||||
if !local_var_status.is_client_error() && !local_var_status.is_server_error() {
|
||||
serde_json::from_str(&local_var_content).map_err(Error::from)
|
||||
} else {
|
||||
let local_var_entity: Option<UpdateGroupPostError> = serde_json::from_str(&local_var_content).ok();
|
||||
let local_var_error = ResponseContent { status: local_var_status, content: local_var_content, entity: local_var_entity };
|
||||
Err(Error::ResponseError(local_var_error))
|
||||
}
|
||||
}
|
||||
|
||||
/// Updates a group role by ID.
|
||||
pub fn update_group_role(configuration: &configuration::Configuration, group_id: &str, group_role_id: &str, update_group_role_request: Option<crate::models::UpdateGroupRoleRequest>) -> Result<Vec<crate::models::GroupRole>, Error<UpdateGroupRoleError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
@ -23,6 +23,14 @@ pub enum CloseInstanceError {
|
||||
UnknownValue(serde_json::Value),
|
||||
}
|
||||
|
||||
/// struct for typed errors of method [`create_instance`]
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
pub enum CreateInstanceError {
|
||||
Status401(crate::models::Error),
|
||||
UnknownValue(serde_json::Value),
|
||||
}
|
||||
|
||||
/// struct for typed errors of method [`get_instance`]
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
@ -57,8 +65,8 @@ pub enum SendSelfInviteError {
|
||||
}
|
||||
|
||||
|
||||
/// Close an instance. You can only close an instance if the ownerId is yourself or if the instance owner is a group and you have the `group-instance-moderate` permission.
|
||||
pub fn close_instance(configuration: &configuration::Configuration, world_id: &str, instance_id: &str, hard_close: Option<bool>) -> Result<crate::models::Instance, Error<CloseInstanceError>> {
|
||||
/// Close an instance or update the closedAt time when it will be closed. You can only close an instance if the ownerId is yourself or if the instance owner is a group and you have the `group-instance-moderate` permission.
|
||||
pub fn close_instance(configuration: &configuration::Configuration, world_id: &str, instance_id: &str, hard_close: Option<bool>, closed_at: Option<String>) -> Result<crate::models::Instance, Error<CloseInstanceError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
||||
let local_var_client = &local_var_configuration.client;
|
||||
@ -69,6 +77,9 @@ pub fn close_instance(configuration: &configuration::Configuration, world_id: &s
|
||||
if let Some(ref local_var_str) = hard_close {
|
||||
local_var_req_builder = local_var_req_builder.query(&[("hardClose", &local_var_str.to_string())]);
|
||||
}
|
||||
if let Some(ref local_var_str) = closed_at {
|
||||
local_var_req_builder = local_var_req_builder.query(&[("closedAt", &local_var_str.to_string())]);
|
||||
}
|
||||
if let Some(ref local_var_user_agent) = local_var_configuration.user_agent {
|
||||
local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone());
|
||||
}
|
||||
@ -88,6 +99,35 @@ pub fn close_instance(configuration: &configuration::Configuration, world_id: &s
|
||||
}
|
||||
}
|
||||
|
||||
/// Create an instance
|
||||
pub fn create_instance(configuration: &configuration::Configuration, create_instance_request: crate::models::CreateInstanceRequest) -> Result<crate::models::Instance, Error<CreateInstanceError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
||||
let local_var_client = &local_var_configuration.client;
|
||||
|
||||
let local_var_uri_str = format!("{}/instances", local_var_configuration.base_path);
|
||||
let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str());
|
||||
|
||||
if let Some(ref local_var_user_agent) = local_var_configuration.user_agent {
|
||||
local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone());
|
||||
}
|
||||
local_var_req_builder = local_var_req_builder.json(&create_instance_request);
|
||||
|
||||
let local_var_req = local_var_req_builder.build()?;
|
||||
let mut local_var_resp = local_var_client.execute(local_var_req)?;
|
||||
|
||||
let local_var_status = local_var_resp.status();
|
||||
let local_var_content = local_var_resp.text()?;
|
||||
|
||||
if !local_var_status.is_client_error() && !local_var_status.is_server_error() {
|
||||
serde_json::from_str(&local_var_content).map_err(Error::from)
|
||||
} else {
|
||||
let local_var_entity: Option<CreateInstanceError> = serde_json::from_str(&local_var_content).ok();
|
||||
let local_var_error = ResponseContent { status: local_var_status, content: local_var_content, entity: local_var_entity };
|
||||
Err(Error::ResponseError(local_var_error))
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns an instance. Please read [Instances Tutorial](https://vrchatapi.github.io/tutorials/instances/) for more information on Instances. If an invalid instanceId is provided, this endpoint will simply return \"null\"!
|
||||
pub fn get_instance(configuration: &configuration::Configuration, world_id: &str, instance_id: &str) -> Result<crate::models::Instance, Error<GetInstanceError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
@ -156,7 +156,7 @@ pub fn get_user_group_requests(configuration: &configuration::Configuration, use
|
||||
}
|
||||
|
||||
/// Get user's public groups
|
||||
pub fn get_user_groups(configuration: &configuration::Configuration, user_id: &str) -> Result<Vec<crate::models::Group>, Error<GetUserGroupsError>> {
|
||||
pub fn get_user_groups(configuration: &configuration::Configuration, user_id: &str) -> Result<Vec<crate::models::LimitedGroup>, Error<GetUserGroupsError>> {
|
||||
let local_var_configuration = configuration;
|
||||
|
||||
let local_var_client = &local_var_configuration.client;
|
||||
|
51
src/models/create_instance_request.rs
Normal file
51
src/models/create_instance_request.rs
Normal file
@ -0,0 +1,51 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct CreateInstanceRequest {
|
||||
/// WorldID be \"offline\" on User profiles if you are not friends with that user.
|
||||
#[serde(rename = "worldId")]
|
||||
pub world_id: String,
|
||||
#[serde(rename = "type")]
|
||||
pub r#type: crate::models::InstanceType,
|
||||
#[serde(rename = "region")]
|
||||
pub region: crate::models::Region,
|
||||
/// A groupId if the instance type is \"group\", null if instance type is public, or a userId otherwise
|
||||
#[serde(rename = "ownerId", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
|
||||
pub owner_id: Option<Option<String>>,
|
||||
/// Group roleIds that are allowed to join if the type is \"group\" and groupAccessType is \"member\"
|
||||
#[serde(rename = "roleIds", skip_serializing_if = "Option::is_none")]
|
||||
pub role_ids: Option<Vec<String>>,
|
||||
#[serde(rename = "groupAccessType", skip_serializing_if = "Option::is_none")]
|
||||
pub group_access_type: Option<crate::models::GroupAccessType>,
|
||||
#[serde(rename = "queueEnabled", skip_serializing_if = "Option::is_none")]
|
||||
pub queue_enabled: Option<bool>,
|
||||
/// The time after which users won't be allowed to join the instance
|
||||
#[serde(rename = "closedAt", skip_serializing_if = "Option::is_none")]
|
||||
pub closed_at: Option<String>,
|
||||
}
|
||||
|
||||
impl CreateInstanceRequest {
|
||||
pub fn new(world_id: String, r#type: crate::models::InstanceType, region: crate::models::Region) -> CreateInstanceRequest {
|
||||
CreateInstanceRequest {
|
||||
world_id,
|
||||
r#type,
|
||||
region,
|
||||
owner_id: None,
|
||||
role_ids: None,
|
||||
group_access_type: None,
|
||||
queue_enabled: None,
|
||||
closed_at: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -38,6 +38,8 @@ pub mod create_group_request;
|
||||
pub use self::create_group_request::CreateGroupRequest;
|
||||
pub mod create_group_role_request;
|
||||
pub use self::create_group_role_request::CreateGroupRoleRequest;
|
||||
pub mod create_instance_request;
|
||||
pub use self::create_instance_request::CreateInstanceRequest;
|
||||
pub mod create_world_request;
|
||||
pub use self::create_world_request::CreateWorldRequest;
|
||||
pub mod current_user;
|
||||
@ -168,6 +170,16 @@ pub mod moderate_user_request;
|
||||
pub use self::moderate_user_request::ModerateUserRequest;
|
||||
pub mod notification;
|
||||
pub use self::notification::Notification;
|
||||
pub mod notification_detail_invite;
|
||||
pub use self::notification_detail_invite::NotificationDetailInvite;
|
||||
pub mod notification_detail_invite_response;
|
||||
pub use self::notification_detail_invite_response::NotificationDetailInviteResponse;
|
||||
pub mod notification_detail_request_invite;
|
||||
pub use self::notification_detail_request_invite::NotificationDetailRequestInvite;
|
||||
pub mod notification_detail_request_invite_response;
|
||||
pub use self::notification_detail_request_invite_response::NotificationDetailRequestInviteResponse;
|
||||
pub mod notification_detail_vote_to_kick;
|
||||
pub use self::notification_detail_vote_to_kick::NotificationDetailVoteToKick;
|
||||
pub mod notification_type;
|
||||
pub use self::notification_type::NotificationType;
|
||||
pub mod order_option;
|
||||
|
33
src/models/notification_detail_invite.rs
Normal file
33
src/models/notification_detail_invite.rs
Normal file
@ -0,0 +1,33 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct NotificationDetailInvite {
|
||||
#[serde(rename = "inviteMessage", skip_serializing_if = "Option::is_none")]
|
||||
pub invite_message: Option<String>,
|
||||
/// WorldID be \"offline\" on User profiles if you are not friends with that user.
|
||||
#[serde(rename = "worldId")]
|
||||
pub world_id: String,
|
||||
#[serde(rename = "worldName")]
|
||||
pub world_name: String,
|
||||
}
|
||||
|
||||
impl NotificationDetailInvite {
|
||||
pub fn new(world_id: String, world_name: String) -> NotificationDetailInvite {
|
||||
NotificationDetailInvite {
|
||||
invite_message: None,
|
||||
world_id,
|
||||
world_name,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
29
src/models/notification_detail_invite_response.rs
Normal file
29
src/models/notification_detail_invite_response.rs
Normal file
@ -0,0 +1,29 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct NotificationDetailInviteResponse {
|
||||
#[serde(rename = "inResponseTo")]
|
||||
pub in_response_to: String,
|
||||
#[serde(rename = "responseMessage")]
|
||||
pub response_message: String,
|
||||
}
|
||||
|
||||
impl NotificationDetailInviteResponse {
|
||||
pub fn new(in_response_to: String, response_message: String) -> NotificationDetailInviteResponse {
|
||||
NotificationDetailInviteResponse {
|
||||
in_response_to,
|
||||
response_message,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
31
src/models/notification_detail_request_invite.rs
Normal file
31
src/models/notification_detail_request_invite.rs
Normal file
@ -0,0 +1,31 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct NotificationDetailRequestInvite {
|
||||
/// TODO: Does this still exist?
|
||||
#[serde(rename = "platform", skip_serializing_if = "Option::is_none")]
|
||||
pub platform: Option<String>,
|
||||
/// Used when using InviteMessage Slot.
|
||||
#[serde(rename = "requestMessage", skip_serializing_if = "Option::is_none")]
|
||||
pub request_message: Option<String>,
|
||||
}
|
||||
|
||||
impl NotificationDetailRequestInvite {
|
||||
pub fn new() -> NotificationDetailRequestInvite {
|
||||
NotificationDetailRequestInvite {
|
||||
platform: None,
|
||||
request_message: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
30
src/models/notification_detail_request_invite_response.rs
Normal file
30
src/models/notification_detail_request_invite_response.rs
Normal file
@ -0,0 +1,30 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct NotificationDetailRequestInviteResponse {
|
||||
#[serde(rename = "inResponseTo")]
|
||||
pub in_response_to: String,
|
||||
/// Used when using InviteMessage Slot.
|
||||
#[serde(rename = "requestMessage", skip_serializing_if = "Option::is_none")]
|
||||
pub request_message: Option<String>,
|
||||
}
|
||||
|
||||
impl NotificationDetailRequestInviteResponse {
|
||||
pub fn new(in_response_to: String) -> NotificationDetailRequestInviteResponse {
|
||||
NotificationDetailRequestInviteResponse {
|
||||
in_response_to,
|
||||
request_message: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
31
src/models/notification_detail_vote_to_kick.rs
Normal file
31
src/models/notification_detail_vote_to_kick.rs
Normal file
@ -0,0 +1,31 @@
|
||||
/*
|
||||
* VRChat API Documentation
|
||||
*
|
||||
*
|
||||
* Contact: vrchatapi.lpv0t@aries.fyi
|
||||
* Generated by: https://openapi-generator.tech
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
|
||||
pub struct NotificationDetailVoteToKick {
|
||||
/// A users unique ID, usually in the form of `usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469`. Legacy players can have old IDs in the form of `8JoV9XEdpo`. The ID can never be changed.
|
||||
#[serde(rename = "initiatorUserId")]
|
||||
pub initiator_user_id: String,
|
||||
/// A users unique ID, usually in the form of `usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469`. Legacy players can have old IDs in the form of `8JoV9XEdpo`. The ID can never be changed.
|
||||
#[serde(rename = "userToKickId")]
|
||||
pub user_to_kick_id: String,
|
||||
}
|
||||
|
||||
impl NotificationDetailVoteToKick {
|
||||
pub fn new(initiator_user_id: String, user_to_kick_id: String) -> NotificationDetailVoteToKick {
|
||||
NotificationDetailVoteToKick {
|
||||
initiator_user_id,
|
||||
user_to_kick_id,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user