Skip to content

Commit

Permalink
Upgrade C# SDK to spec 1.17.3
Browse files Browse the repository at this point in the history
  • Loading branch information
VRCCat committed Apr 29, 2024
1 parent 860b7a0 commit 6dd583d
Show file tree
Hide file tree
Showing 180 changed files with 2,036 additions and 214 deletions.
12 changes: 12 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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
Expand Down Expand Up @@ -199,6 +205,7 @@ src/VRChat.API/Model/CreateGroupInviteRequest.cs
src/VRChat.API/Model/CreateGroupPostRequest.cs
src/VRChat.API/Model/CreateGroupRequest.cs
src/VRChat.API/Model/CreateGroupRoleRequest.cs
src/VRChat.API/Model/CreateInstanceRequest.cs
src/VRChat.API/Model/CreateWorldRequest.cs
src/VRChat.API/Model/CurrentUser.cs
src/VRChat.API/Model/CurrentUserPresence.cs
Expand Down Expand Up @@ -264,6 +271,11 @@ src/VRChat.API/Model/LimitedWorld.cs
src/VRChat.API/Model/MIMEType.cs
src/VRChat.API/Model/ModerateUserRequest.cs
src/VRChat.API/Model/Notification.cs
src/VRChat.API/Model/NotificationDetailInvite.cs
src/VRChat.API/Model/NotificationDetailInviteResponse.cs
src/VRChat.API/Model/NotificationDetailRequestInvite.cs
src/VRChat.API/Model/NotificationDetailRequestInviteResponse.cs
src/VRChat.API/Model/NotificationDetailVoteToKick.cs
src/VRChat.API/Model/NotificationType.cs
src/VRChat.API/Model/OrderOption.cs
src/VRChat.API/Model/PaginatedGroupAuditLogEntryList.cs
Expand Down
17 changes: 17 additions & 0 deletions docs/CreateInstanceRequest.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# VRChat.API.Model.CreateInstanceRequest

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**WorldId** | **string** | WorldID be \"offline\" on User profiles if you are not friends with that user. |
**Type** | **InstanceType** | |
**Region** | **Region** | |
**OwnerId** | **string** | A groupId if the instance type is \"group\", null if instance type is public, or a userId otherwise | [optional]
**RoleIds** | **List<string>** | Group roleIds that are allowed to join if the type is \"group\" and groupAccessType is \"member\" | [optional]
**GroupAccessType** | **GroupAccessType** | | [optional]
**QueueEnabled** | **bool** | | [optional] [default to false]
**ClosedAt** | **DateTime** | 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)

103 changes: 103 additions & 0 deletions docs/GroupsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ All URIs are relative to *https://api.vrchat.cloud/api/1*
| [**UpdateGroup**](GroupsApi.md#updategroup) | **PUT** /groups/{groupId} | Update Group |
| [**UpdateGroupGallery**](GroupsApi.md#updategroupgallery) | **PUT** /groups/{groupId}/galleries/{groupGalleryId} | Update Group Gallery |
| [**UpdateGroupMember**](GroupsApi.md#updategroupmember) | **PUT** /groups/{groupId}/members/{userId} | Update Group Member |
| [**UpdateGroupPost**](GroupsApi.md#updategrouppost) | **PUT** /groups/{groupId}/posts/{notificationId} | Edits a Group post |
| [**UpdateGroupRole**](GroupsApi.md#updategrouprole) | **PUT** /groups/{groupId}/roles/{groupRoleId} | Update Group Role |

<a name="addgroupgalleryimage"></a>
Expand Down Expand Up @@ -4046,6 +4047,108 @@ catch (ApiException e)

[[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)

<a name="updategrouppost"></a>
# **UpdateGroupPost**
> GroupPost UpdateGroupPost (string groupId, string notificationId, CreateGroupPostRequest createGroupPostRequest)
Edits a Group post

Edits a Group post

### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using VRChat.API.Api;
using VRChat.API.Client;
using VRChat.API.Model;

namespace Example
{
public class UpdateGroupPostExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.vrchat.cloud/api/1";
// Configure API key authorization: authCookie
config.AddApiKey("auth", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("auth", "Bearer");
var apiInstance = new GroupsApi(config);
var groupId = grp_00000000-0000-0000-0000-000000000000; // string | Must be a valid group ID.
var notificationId = "notificationId_example"; // string | Must be a valid notification ID.
var createGroupPostRequest = new CreateGroupPostRequest(); // CreateGroupPostRequest |
try
{
// Edits a Group post
GroupPost result = apiInstance.UpdateGroupPost(groupId, notificationId, createGroupPostRequest);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling GroupsApi.UpdateGroupPost: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```

#### Using the UpdateGroupPostWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.

```csharp
try
{
// Edits a Group post
ApiResponse<GroupPost> response = apiInstance.UpdateGroupPostWithHttpInfo(groupId, notificationId, createGroupPostRequest);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling GroupsApi.UpdateGroupPostWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```

### Parameters

| Name | Type | Description | Notes |
|------|------|-------------|-------|
| **groupId** | **string** | Must be a valid group ID. | |
| **notificationId** | **string** | Must be a valid notification ID. | |
| **createGroupPostRequest** | [**CreateGroupPostRequest**](CreateGroupPostRequest.md) | | |

### Return type

[**GroupPost**](GroupPost.md)

### Authorization

[authCookie](../README.md#authCookie)

### HTTP request headers

- **Content-Type**: application/json
- **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | Returns a GroupPost object. | - |
| **401** | Error response due to missing auth cookie. | - |
| **404** | Response after deleting a group post. | - |

[[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)

<a name="updategrouprole"></a>
# **UpdateGroupRole**
> List&lt;GroupRole&gt; UpdateGroupRole (string groupId, string groupRoleId, UpdateGroupRoleRequest updateGroupRoleRequest = null)
Expand Down
108 changes: 104 additions & 4 deletions docs/InstancesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,19 @@ All URIs are relative to *https://api.vrchat.cloud/api/1*
| Method | HTTP request | Description |
|--------|--------------|-------------|
| [**CloseInstance**](InstancesApi.md#closeinstance) | **DELETE** /instances/{worldId}:{instanceId} | Close Instance |
| [**CreateInstance**](InstancesApi.md#createinstance) | **POST** /instances | Create Instance |
| [**GetInstance**](InstancesApi.md#getinstance) | **GET** /instances/{worldId}:{instanceId} | Get Instance |
| [**GetInstanceByShortName**](InstancesApi.md#getinstancebyshortname) | **GET** /instances/s/{shortName} | Get Instance By Short Name |
| [**GetShortName**](InstancesApi.md#getshortname) | **GET** /instances/{worldId}:{instanceId}/shortName | Get Instance Short Name |
| [**SendSelfInvite**](InstancesApi.md#sendselfinvite) | **POST** /instances/{worldId}:{instanceId}/invite | Send Self Invite |

<a name="closeinstance"></a>
# **CloseInstance**
> Instance CloseInstance (string worldId, string instanceId, bool? hardClose = null)
> Instance CloseInstance (string worldId, string instanceId, bool? hardClose = null, DateTime? closedAt = null)
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.

### Example
```csharp
Expand All @@ -43,11 +44,12 @@ namespace Example
var worldId = "worldId_example"; // string | Must be a valid world ID.
var instanceId = "instanceId_example"; // string | Must be a valid instance ID.
var hardClose = true; // bool? | Whether to hard close the instance. Defaults to false. (optional)
var closedAt = DateTime.Parse("2013-10-20T19:20:30+01:00"); // DateTime? | The time after which users won't be allowed to join the instances. If omitted, the instance will be closed immediately. (optional)
try
{
// Close Instance
Instance result = apiInstance.CloseInstance(worldId, instanceId, hardClose);
Instance result = apiInstance.CloseInstance(worldId, instanceId, hardClose, closedAt);
Debug.WriteLine(result);
}
catch (ApiException e)
Expand All @@ -68,7 +70,7 @@ This returns an ApiResponse object which contains the response data, status code
try
{
// Close Instance
ApiResponse<Instance> response = apiInstance.CloseInstanceWithHttpInfo(worldId, instanceId, hardClose);
ApiResponse<Instance> response = apiInstance.CloseInstanceWithHttpInfo(worldId, instanceId, hardClose, closedAt);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
Expand All @@ -88,6 +90,7 @@ catch (ApiException e)
| **worldId** | **string** | Must be a valid world ID. | |
| **instanceId** | **string** | Must be a valid instance ID. | |
| **hardClose** | **bool?** | Whether to hard close the instance. Defaults to false. | [optional] |
| **closedAt** | **DateTime?** | The time after which users won&#39;t be allowed to join the instances. If omitted, the instance will be closed immediately. | [optional] |

### Return type

Expand All @@ -113,6 +116,103 @@ catch (ApiException e)

[[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)

<a name="createinstance"></a>
# **CreateInstance**
> Instance CreateInstance (CreateInstanceRequest createInstanceRequest)
Create Instance

Create an instance

### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using VRChat.API.Api;
using VRChat.API.Client;
using VRChat.API.Model;

namespace Example
{
public class CreateInstanceExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.vrchat.cloud/api/1";
// Configure API key authorization: authCookie
config.AddApiKey("auth", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("auth", "Bearer");
var apiInstance = new InstancesApi(config);
var createInstanceRequest = new CreateInstanceRequest(); // CreateInstanceRequest |
try
{
// Create Instance
Instance result = apiInstance.CreateInstance(createInstanceRequest);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling InstancesApi.CreateInstance: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```

#### Using the CreateInstanceWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.

```csharp
try
{
// Create Instance
ApiResponse<Instance> response = apiInstance.CreateInstanceWithHttpInfo(createInstanceRequest);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling InstancesApi.CreateInstanceWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```

### Parameters

| Name | Type | Description | Notes |
|------|------|-------------|-------|
| **createInstanceRequest** | [**CreateInstanceRequest**](CreateInstanceRequest.md) | | |

### Return type

[**Instance**](Instance.md)

### Authorization

[authCookie](../README.md#authCookie)

### HTTP request headers

- **Content-Type**: application/json
- **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | Returns a single Instance object. | - |
| **401** | Error response due to missing auth cookie. | - |

[[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)

<a name="getinstance"></a>
# **GetInstance**
> Instance GetInstance (string worldId, string instanceId)
Expand Down
12 changes: 12 additions & 0 deletions docs/NotificationDetailInvite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# VRChat.API.Model.NotificationDetailInvite

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**InviteMessage** | **string** | | [optional]
**WorldId** | **string** | WorldID be \&quot;offline\&quot; on User profiles if you are not friends with that user. |
**WorldName** | **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)

11 changes: 11 additions & 0 deletions docs/NotificationDetailInviteResponse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# VRChat.API.Model.NotificationDetailInviteResponse

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**InResponseTo** | **string** | |
**ResponseMessage** | **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)

11 changes: 11 additions & 0 deletions docs/NotificationDetailRequestInvite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# VRChat.API.Model.NotificationDetailRequestInvite

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Platform** | **string** | TODO: Does this still exist? | [optional]
**RequestMessage** | **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)

11 changes: 11 additions & 0 deletions docs/NotificationDetailRequestInviteResponse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# VRChat.API.Model.NotificationDetailRequestInviteResponse

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**InResponseTo** | **string** | |
**RequestMessage** | **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)

11 changes: 11 additions & 0 deletions docs/NotificationDetailVoteToKick.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# VRChat.API.Model.NotificationDetailVoteToKick

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**InitiatorUserId** | **string** | A users unique ID, usually in the form of &#x60;usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469&#x60;. Legacy players can have old IDs in the form of &#x60;8JoV9XEdpo&#x60;. The ID can never be changed. |
**UserToKickId** | **string** | A users unique ID, usually in the form of &#x60;usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469&#x60;. Legacy players can have old IDs in the form of &#x60;8JoV9XEdpo&#x60;. 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)

Loading

0 comments on commit 6dd583d

Please sign in to comment.