@accelbyte/sdk-ams 0.0.0-dev-20240828032938
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/LICENSE +19 -0
- package/package.json +55 -0
- package/react-query/package.json +5 -0
- package/src/Ams.ts +42 -0
- package/src/all-imports.ts +91 -0
- package/src/all-query-imports.ts +19 -0
- package/src/custom/index.ts +6 -0
- package/src/generated-admin/AccountAdminApi.ts +91 -0
- package/src/generated-admin/AmsInfoAdminApi.ts +65 -0
- package/src/generated-admin/AmsQoSAdminApi.ts +65 -0
- package/src/generated-admin/ArtifactsAdminApi.ts +122 -0
- package/src/generated-admin/DevelopmentAdminApi.ts +89 -0
- package/src/generated-admin/FleetsAdminApi.ts +112 -0
- package/src/generated-admin/ImagesAdminApi.ts +111 -0
- package/src/generated-admin/ServersAdminApi.ts +89 -0
- package/src/generated-admin/endpoints/AccountAdmin$.ts +68 -0
- package/src/generated-admin/endpoints/AmsInfoAdmin$.ts +42 -0
- package/src/generated-admin/endpoints/AmsQoSAdmin$.ts +43 -0
- package/src/generated-admin/endpoints/ArtifactsAdmin$.ts +100 -0
- package/src/generated-admin/endpoints/DevelopmentAdmin$.ts +67 -0
- package/src/generated-admin/endpoints/FleetsAdmin$.ts +90 -0
- package/src/generated-admin/endpoints/ImagesAdmin$.ts +89 -0
- package/src/generated-admin/endpoints/ServersAdmin$.ts +66 -0
- package/src/generated-admin/queries/AccountAdmin.query.ts +131 -0
- package/src/generated-admin/queries/AmsInfoAdmin.query.ts +81 -0
- package/src/generated-admin/queries/AmsQoSAdmin.query.ts +77 -0
- package/src/generated-admin/queries/ArtifactsAdmin.query.ts +211 -0
- package/src/generated-admin/queries/DevelopmentAdmin.query.ts +130 -0
- package/src/generated-admin/queries/FleetsAdmin.query.ts +182 -0
- package/src/generated-admin/queries/ImagesAdmin.query.ts +181 -0
- package/src/generated-admin/queries/ServersAdmin.query.ts +139 -0
- package/src/generated-definitions/AccountCreateRequest.ts +10 -0
- package/src/generated-definitions/AccountCreateResponse.ts +11 -0
- package/src/generated-definitions/AccountLimits.ts +16 -0
- package/src/generated-definitions/AccountLinkRequest.ts +10 -0
- package/src/generated-definitions/AccountLinkResponse.ts +11 -0
- package/src/generated-definitions/AccountLinkTokenResponse.ts +10 -0
- package/src/generated-definitions/AccountResponse.ts +11 -0
- package/src/generated-definitions/AmsRegionsResponse.ts +10 -0
- package/src/generated-definitions/ArtifactListResponse.ts +11 -0
- package/src/generated-definitions/ArtifactResponse.ts +24 -0
- package/src/generated-definitions/ArtifactSamplingRule.ts +10 -0
- package/src/generated-definitions/ArtifactTypeSamplingRules.ts +11 -0
- package/src/generated-definitions/ArtifactUrlResponse.ts +10 -0
- package/src/generated-definitions/ArtifactUsageResponse.ts +14 -0
- package/src/generated-definitions/AvailableInstanceTypesResponse.ts +11 -0
- package/src/generated-definitions/DevelopmentServerConfigurationCreateRequest.ts +14 -0
- package/src/generated-definitions/DevelopmentServerConfigurationCreateResponse.ts +10 -0
- package/src/generated-definitions/DevelopmentServerConfigurationGetResponse.ts +14 -0
- package/src/generated-definitions/DevelopmentServerConfigurationListResponse.ts +14 -0
- package/src/generated-definitions/DsHistoryEvent.ts +19 -0
- package/src/generated-definitions/DsHistoryList.ts +12 -0
- package/src/generated-definitions/DsHostConfiguration.ts +10 -0
- package/src/generated-definitions/ErrorResponse.ts +10 -0
- package/src/generated-definitions/FleetArtifactsSampleRules.ts +11 -0
- package/src/generated-definitions/FleetClaimByKeysReq.ts +10 -0
- package/src/generated-definitions/FleetClaimReq.ts +10 -0
- package/src/generated-definitions/FleetClaimResponse.ts +10 -0
- package/src/generated-definitions/FleetCreateResponse.ts +10 -0
- package/src/generated-definitions/FleetGetResponse.ts +25 -0
- package/src/generated-definitions/FleetListItemResponse.ts +20 -0
- package/src/generated-definitions/FleetListResponse.ts +11 -0
- package/src/generated-definitions/FleetParameters.ts +23 -0
- package/src/generated-definitions/FleetRegionalServerCounts.ts +17 -0
- package/src/generated-definitions/FleetServerConnectionInfoResponse.ts +16 -0
- package/src/generated-definitions/FleetServerHistoryEventResponse.ts +19 -0
- package/src/generated-definitions/FleetServerHistoryResponse.ts +11 -0
- package/src/generated-definitions/FleetServerInfoResponse.ts +26 -0
- package/src/generated-definitions/FleetServersResponse.ts +17 -0
- package/src/generated-definitions/ImageDeploymentProfile.ts +17 -0
- package/src/generated-definitions/ImageDetails.ts +25 -0
- package/src/generated-definitions/ImageList.ts +11 -0
- package/src/generated-definitions/ImageListItem.ts +24 -0
- package/src/generated-definitions/ImageStorage.ts +14 -0
- package/src/generated-definitions/ImageUpdate.ts +15 -0
- package/src/generated-definitions/InstanceTypeDescriptionResponse.ts +17 -0
- package/src/generated-definitions/Location.ts +20 -0
- package/src/generated-definitions/PagingInfo.ts +19 -0
- package/src/generated-definitions/PortConfiguration.ts +10 -0
- package/src/generated-definitions/QoSEndpointResponse.ts +11 -0
- package/src/generated-definitions/QoSServer.ts +18 -0
- package/src/generated-definitions/ReferencingFleet.ts +10 -0
- package/src/generated-definitions/RegionConfig.ts +16 -0
- package/src/generated-definitions/Time.ts +10 -0
- package/src/generated-definitions/Timeout.ts +15 -0
- package/src/generated-definitions/UpdateServerRequest.ts +10 -0
- package/src/generated-definitions/Zone.ts +10 -0
- package/src/generated-definitions/ZoneTrans.ts +10 -0
- package/src/generated-public/AccountApi.ts +53 -0
- package/src/generated-public/AmsInfoApi.ts +50 -0
- package/src/generated-public/AuthApi.ts +53 -0
- package/src/generated-public/FleetCommanderApi.ts +50 -0
- package/src/generated-public/FleetsApi.ts +66 -0
- package/src/generated-public/WatchdogsApi.ts +64 -0
- package/src/generated-public/endpoints/Account$.ts +30 -0
- package/src/generated-public/endpoints/AmsInfo$.ts +28 -0
- package/src/generated-public/endpoints/Auth$.ts +31 -0
- package/src/generated-public/endpoints/FleetCommander$.ts +28 -0
- package/src/generated-public/endpoints/Fleets$.ts +43 -0
- package/src/generated-public/endpoints/Watchdogs$.ts +42 -0
- package/src/generated-public/queries/Account.query.ts +52 -0
- package/src/generated-public/queries/AmsInfo.query.ts +52 -0
- package/src/generated-public/queries/Auth.query.ts +52 -0
- package/src/generated-public/queries/FleetCommander.query.ts +52 -0
- package/src/generated-public/queries/Fleets.query.ts +74 -0
- package/src/generated-public/queries/Watchdogs.query.ts +80 -0
- package/src/index.ts +7 -0
- package/src/version.json +7 -0
- package/swaggers/ams.json +3978 -0
- package/swaggers.json +1 -0
- package/tsconfig.json +18 -0
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* AUTO GENERATED
|
|
8
|
+
*/
|
|
9
|
+
/* eslint-disable camelcase */
|
|
10
|
+
import { AccelByteSDK, SdkSetConfigParam, ApiError } from '@accelbyte/sdk'
|
|
11
|
+
import { AxiosError, AxiosResponse } from 'axios'
|
|
12
|
+
// @ts-ignore
|
|
13
|
+
import { useQuery, UseQueryOptions, UseQueryResult, useMutation, UseMutationOptions, UseMutationResult } from '@tanstack/react-query'
|
|
14
|
+
import { ImagesAdminApi } from "../ImagesAdminApi.js"
|
|
15
|
+
|
|
16
|
+
import { ImageDetails } from '../../generated-definitions/ImageDetails.js'
|
|
17
|
+
import { ImageList } from '../../generated-definitions/ImageList.js'
|
|
18
|
+
import { ImageStorage } from '../../generated-definitions/ImageStorage.js'
|
|
19
|
+
import { ImageUpdate } from '../../generated-definitions/ImageUpdate.js'
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
export enum Key_ImagesAdmin {
|
|
23
|
+
Images = 'Ams.ImagesAdmin.Images',
|
|
24
|
+
ImagesStorage = 'Ams.ImagesAdmin.ImagesStorage',
|
|
25
|
+
Image_ByImageId = 'Ams.ImagesAdmin.Image_ByImageId',
|
|
26
|
+
Restore_ByImageId = 'Ams.ImagesAdmin.Restore_ByImageId',
|
|
27
|
+
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
export const useImagesAdminApi_GetImages = (
|
|
33
|
+
sdk: AccelByteSDK,
|
|
34
|
+
input: SdkSetConfigParam ,
|
|
35
|
+
options?: Omit<UseQueryOptions<ImageList, AxiosError<ApiError>>, 'queryKey'>,
|
|
36
|
+
callback?: (data: AxiosResponse<ImageList>) => void
|
|
37
|
+
): UseQueryResult<ImageList, AxiosError<ApiError>> => {
|
|
38
|
+
//
|
|
39
|
+
const queryFn = (
|
|
40
|
+
sdk: AccelByteSDK,
|
|
41
|
+
input: Parameters<typeof useImagesAdminApi_GetImages>[1]
|
|
42
|
+
) => async () => {
|
|
43
|
+
const response =
|
|
44
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
45
|
+
getImages())
|
|
46
|
+
callback && callback(response)
|
|
47
|
+
return response.data
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
return useQuery<ImageList, AxiosError<ApiError>>({
|
|
51
|
+
queryKey: [Key_ImagesAdmin.Images, input],
|
|
52
|
+
queryFn: queryFn(sdk, input),
|
|
53
|
+
...options
|
|
54
|
+
})
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
export const useImagesAdminApi_GetImagesStorage = (
|
|
60
|
+
sdk: AccelByteSDK,
|
|
61
|
+
input: SdkSetConfigParam ,
|
|
62
|
+
options?: Omit<UseQueryOptions<ImageStorage, AxiosError<ApiError>>, 'queryKey'>,
|
|
63
|
+
callback?: (data: AxiosResponse<ImageStorage>) => void
|
|
64
|
+
): UseQueryResult<ImageStorage, AxiosError<ApiError>> => {
|
|
65
|
+
//
|
|
66
|
+
const queryFn = (
|
|
67
|
+
sdk: AccelByteSDK,
|
|
68
|
+
input: Parameters<typeof useImagesAdminApi_GetImagesStorage>[1]
|
|
69
|
+
) => async () => {
|
|
70
|
+
const response =
|
|
71
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
72
|
+
getImagesStorage())
|
|
73
|
+
callback && callback(response)
|
|
74
|
+
return response.data
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return useQuery<ImageStorage, AxiosError<ApiError>>({
|
|
78
|
+
queryKey: [Key_ImagesAdmin.ImagesStorage, input],
|
|
79
|
+
queryFn: queryFn(sdk, input),
|
|
80
|
+
...options
|
|
81
|
+
})
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
export const useImagesAdminApi_DeleteImage_ByImageId = (
|
|
87
|
+
sdk: AccelByteSDK,
|
|
88
|
+
options?: Omit<UseMutationOptions<unknown, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string }>, 'mutationKey'>,
|
|
89
|
+
callback?: (data: unknown) => void
|
|
90
|
+
): UseMutationResult<unknown, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string }> => {
|
|
91
|
+
//
|
|
92
|
+
const mutationFn = async (input: SdkSetConfigParam & { imageID:string }) => {
|
|
93
|
+
const response =
|
|
94
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
95
|
+
deleteImage_ByImageId(input.imageID))
|
|
96
|
+
callback && callback(response.data)
|
|
97
|
+
return response.data
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
return useMutation({
|
|
101
|
+
mutationKey: [Key_ImagesAdmin.Image_ByImageId],
|
|
102
|
+
mutationFn,
|
|
103
|
+
...options
|
|
104
|
+
})
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
export const useImagesAdminApi_GetImage_ByImageId = (
|
|
110
|
+
sdk: AccelByteSDK,
|
|
111
|
+
input: SdkSetConfigParam & { imageID:string },
|
|
112
|
+
options?: Omit<UseQueryOptions<ImageDetails, AxiosError<ApiError>>, 'queryKey'>,
|
|
113
|
+
callback?: (data: AxiosResponse<ImageDetails>) => void
|
|
114
|
+
): UseQueryResult<ImageDetails, AxiosError<ApiError>> => {
|
|
115
|
+
//
|
|
116
|
+
const queryFn = (
|
|
117
|
+
sdk: AccelByteSDK,
|
|
118
|
+
input: Parameters<typeof useImagesAdminApi_GetImage_ByImageId>[1]
|
|
119
|
+
) => async () => {
|
|
120
|
+
const response =
|
|
121
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
122
|
+
getImage_ByImageId(input.imageID))
|
|
123
|
+
callback && callback(response)
|
|
124
|
+
return response.data
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
return useQuery<ImageDetails, AxiosError<ApiError>>({
|
|
128
|
+
queryKey: [Key_ImagesAdmin.Image_ByImageId, input],
|
|
129
|
+
queryFn: queryFn(sdk, input),
|
|
130
|
+
...options
|
|
131
|
+
})
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
export const useImagesAdminApi_PatchImage_ByImageId = (
|
|
137
|
+
sdk: AccelByteSDK,
|
|
138
|
+
options?: Omit<UseMutationOptions<ImageDetails, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string, data: ImageUpdate }>, 'mutationKey'>,
|
|
139
|
+
callback?: (data: ImageDetails) => void
|
|
140
|
+
): UseMutationResult<ImageDetails, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string, data: ImageUpdate }> => {
|
|
141
|
+
//
|
|
142
|
+
const mutationFn = async (input: SdkSetConfigParam & { imageID:string, data: ImageUpdate }) => {
|
|
143
|
+
const response =
|
|
144
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
145
|
+
patchImage_ByImageId(input.imageID, input.data))
|
|
146
|
+
callback && callback(response.data)
|
|
147
|
+
return response.data
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
return useMutation({
|
|
151
|
+
mutationKey: [Key_ImagesAdmin.Image_ByImageId],
|
|
152
|
+
mutationFn,
|
|
153
|
+
...options
|
|
154
|
+
})
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
export const useImagesAdminApi_CreateRestore_ByImageId = (
|
|
160
|
+
sdk: AccelByteSDK,
|
|
161
|
+
options?: Omit<UseMutationOptions<unknown, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string }>, 'mutationKey'>,
|
|
162
|
+
callback?: (data: unknown) => void
|
|
163
|
+
): UseMutationResult<unknown, AxiosError<ApiError>, SdkSetConfigParam & { imageID:string }> => {
|
|
164
|
+
//
|
|
165
|
+
const mutationFn = async (input: SdkSetConfigParam & { imageID:string }) => {
|
|
166
|
+
const response =
|
|
167
|
+
(await ImagesAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
168
|
+
createRestore_ByImageId(input.imageID))
|
|
169
|
+
callback && callback(response.data)
|
|
170
|
+
return response.data
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
return useMutation({
|
|
174
|
+
mutationKey: [Key_ImagesAdmin.Restore_ByImageId],
|
|
175
|
+
mutationFn,
|
|
176
|
+
...options
|
|
177
|
+
})
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* AUTO GENERATED
|
|
8
|
+
*/
|
|
9
|
+
/* eslint-disable camelcase */
|
|
10
|
+
import { AccelByteSDK, SdkSetConfigParam, ApiError } from '@accelbyte/sdk'
|
|
11
|
+
import { AxiosError, AxiosResponse } from 'axios'
|
|
12
|
+
// @ts-ignore
|
|
13
|
+
import { useQuery, UseQueryOptions, UseQueryResult } from '@tanstack/react-query'
|
|
14
|
+
import { ServersAdminApi } from "../ServersAdminApi.js"
|
|
15
|
+
|
|
16
|
+
import { DsHistoryList } from '../../generated-definitions/DsHistoryList.js'
|
|
17
|
+
import { FleetServerConnectionInfoResponse } from '../../generated-definitions/FleetServerConnectionInfoResponse.js'
|
|
18
|
+
import { FleetServerHistoryResponse } from '../../generated-definitions/FleetServerHistoryResponse.js'
|
|
19
|
+
import { FleetServerInfoResponse } from '../../generated-definitions/FleetServerInfoResponse.js'
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
export enum Key_ServersAdmin {
|
|
23
|
+
Server_ByServerId = 'Ams.ServersAdmin.Server_ByServerId',
|
|
24
|
+
History_ByServerId = 'Ams.ServersAdmin.History_ByServerId',
|
|
25
|
+
ServersHistory_ByFleetId = 'Ams.ServersAdmin.ServersHistory_ByFleetId',
|
|
26
|
+
Connectioninfo_ByServerId = 'Ams.ServersAdmin.Connectioninfo_ByServerId',
|
|
27
|
+
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
export const useServersAdminApi_GetServer_ByServerId = (
|
|
33
|
+
sdk: AccelByteSDK,
|
|
34
|
+
input: SdkSetConfigParam & { serverID:string },
|
|
35
|
+
options?: Omit<UseQueryOptions<FleetServerInfoResponse, AxiosError<ApiError>>, 'queryKey'>,
|
|
36
|
+
callback?: (data: AxiosResponse<FleetServerInfoResponse>) => void
|
|
37
|
+
): UseQueryResult<FleetServerInfoResponse, AxiosError<ApiError>> => {
|
|
38
|
+
//
|
|
39
|
+
const queryFn = (
|
|
40
|
+
sdk: AccelByteSDK,
|
|
41
|
+
input: Parameters<typeof useServersAdminApi_GetServer_ByServerId>[1]
|
|
42
|
+
) => async () => {
|
|
43
|
+
const response =
|
|
44
|
+
(await ServersAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
45
|
+
getServer_ByServerId(input.serverID))
|
|
46
|
+
callback && callback(response)
|
|
47
|
+
return response.data
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
return useQuery<FleetServerInfoResponse, AxiosError<ApiError>>({
|
|
51
|
+
queryKey: [Key_ServersAdmin.Server_ByServerId, input],
|
|
52
|
+
queryFn: queryFn(sdk, input),
|
|
53
|
+
...options
|
|
54
|
+
})
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
export const useServersAdminApi_GetHistory_ByServerId = (
|
|
60
|
+
sdk: AccelByteSDK,
|
|
61
|
+
input: SdkSetConfigParam & { serverID:string },
|
|
62
|
+
options?: Omit<UseQueryOptions<FleetServerHistoryResponse, AxiosError<ApiError>>, 'queryKey'>,
|
|
63
|
+
callback?: (data: AxiosResponse<FleetServerHistoryResponse>) => void
|
|
64
|
+
): UseQueryResult<FleetServerHistoryResponse, AxiosError<ApiError>> => {
|
|
65
|
+
//
|
|
66
|
+
const queryFn = (
|
|
67
|
+
sdk: AccelByteSDK,
|
|
68
|
+
input: Parameters<typeof useServersAdminApi_GetHistory_ByServerId>[1]
|
|
69
|
+
) => async () => {
|
|
70
|
+
const response =
|
|
71
|
+
(await ServersAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
72
|
+
getHistory_ByServerId(input.serverID))
|
|
73
|
+
callback && callback(response)
|
|
74
|
+
return response.data
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return useQuery<FleetServerHistoryResponse, AxiosError<ApiError>>({
|
|
78
|
+
queryKey: [Key_ServersAdmin.History_ByServerId, input],
|
|
79
|
+
queryFn: queryFn(sdk, input),
|
|
80
|
+
...options
|
|
81
|
+
})
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
export const useServersAdminApi_GetServersHistory_ByFleetId = (
|
|
87
|
+
sdk: AccelByteSDK,
|
|
88
|
+
input: SdkSetConfigParam & { fleetID:string, queryParams?: {count?: number, offset?: number, reason?: string | null, region?: string | null, serverId?: string | null, sortDirection?: string | null, status?: string | null} },
|
|
89
|
+
options?: Omit<UseQueryOptions<DsHistoryList, AxiosError<ApiError>>, 'queryKey'>,
|
|
90
|
+
callback?: (data: AxiosResponse<DsHistoryList>) => void
|
|
91
|
+
): UseQueryResult<DsHistoryList, AxiosError<ApiError>> => {
|
|
92
|
+
//
|
|
93
|
+
const queryFn = (
|
|
94
|
+
sdk: AccelByteSDK,
|
|
95
|
+
input: Parameters<typeof useServersAdminApi_GetServersHistory_ByFleetId>[1]
|
|
96
|
+
) => async () => {
|
|
97
|
+
const response =
|
|
98
|
+
(await ServersAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
99
|
+
getServersHistory_ByFleetId(input.fleetID, input.queryParams))
|
|
100
|
+
callback && callback(response)
|
|
101
|
+
return response.data
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
return useQuery<DsHistoryList, AxiosError<ApiError>>({
|
|
105
|
+
queryKey: [Key_ServersAdmin.ServersHistory_ByFleetId, input],
|
|
106
|
+
queryFn: queryFn(sdk, input),
|
|
107
|
+
...options
|
|
108
|
+
})
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
export const useServersAdminApi_GetConnectioninfo_ByServerId = (
|
|
114
|
+
sdk: AccelByteSDK,
|
|
115
|
+
input: SdkSetConfigParam & { serverID:string },
|
|
116
|
+
options?: Omit<UseQueryOptions<FleetServerConnectionInfoResponse, AxiosError<ApiError>>, 'queryKey'>,
|
|
117
|
+
callback?: (data: AxiosResponse<FleetServerConnectionInfoResponse>) => void
|
|
118
|
+
): UseQueryResult<FleetServerConnectionInfoResponse, AxiosError<ApiError>> => {
|
|
119
|
+
//
|
|
120
|
+
const queryFn = (
|
|
121
|
+
sdk: AccelByteSDK,
|
|
122
|
+
input: Parameters<typeof useServersAdminApi_GetConnectioninfo_ByServerId>[1]
|
|
123
|
+
) => async () => {
|
|
124
|
+
const response =
|
|
125
|
+
(await ServersAdminApi(sdk, { coreConfig: input.coreConfig, axiosConfig: input.axiosConfig }).
|
|
126
|
+
getConnectioninfo_ByServerId(input.serverID))
|
|
127
|
+
callback && callback(response)
|
|
128
|
+
return response.data
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
return useQuery<FleetServerConnectionInfoResponse, AxiosError<ApiError>>({
|
|
132
|
+
queryKey: [Key_ServersAdmin.Connectioninfo_ByServerId, input],
|
|
133
|
+
queryFn: queryFn(sdk, input),
|
|
134
|
+
...options
|
|
135
|
+
})
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const AccountCreateRequest = z.object({ name: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface AccountCreateRequest extends z.TypeOf<typeof AccountCreateRequest> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { AccountLimits } from './AccountLimits.js'
|
|
8
|
+
|
|
9
|
+
export const AccountCreateResponse = z.object({ Limits: AccountLimits, id: z.string(), name: z.string(), namespaces: z.array(z.string()) })
|
|
10
|
+
|
|
11
|
+
export interface AccountCreateResponse extends z.TypeOf<typeof AccountCreateResponse> {}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const AccountLimits = z.object({
|
|
9
|
+
allowedNodeClasses: z.array(z.string()).nullish(),
|
|
10
|
+
allowedRegions: z.array(z.string()).nullish(),
|
|
11
|
+
fleetCount: z.number().int().nullish(),
|
|
12
|
+
fleetVmCount: z.number().int().nullish(),
|
|
13
|
+
imageStorageQuotaBytes: z.number().int().nullish()
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
export interface AccountLimits extends z.TypeOf<typeof AccountLimits> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const AccountLinkRequest = z.object({ token: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface AccountLinkRequest extends z.TypeOf<typeof AccountLinkRequest> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { AccountLimits } from './AccountLimits.js'
|
|
8
|
+
|
|
9
|
+
export const AccountLinkResponse = z.object({ Limits: AccountLimits, id: z.string(), name: z.string(), namespaces: z.array(z.string()) })
|
|
10
|
+
|
|
11
|
+
export interface AccountLinkResponse extends z.TypeOf<typeof AccountLinkResponse> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const AccountLinkTokenResponse = z.object({ token: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface AccountLinkTokenResponse extends z.TypeOf<typeof AccountLinkTokenResponse> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { AccountLimits } from './AccountLimits.js'
|
|
8
|
+
|
|
9
|
+
export const AccountResponse = z.object({ Limits: AccountLimits, id: z.string(), name: z.string(), namespaces: z.array(z.string()) })
|
|
10
|
+
|
|
11
|
+
export interface AccountResponse extends z.TypeOf<typeof AccountResponse> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const AmsRegionsResponse = z.object({ regions: z.array(z.string()).nullish() })
|
|
9
|
+
|
|
10
|
+
export interface AmsRegionsResponse extends z.TypeOf<typeof AmsRegionsResponse> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { ArtifactResponse } from './ArtifactResponse.js'
|
|
8
|
+
|
|
9
|
+
export const ArtifactListResponse = z.object({ data: z.array(ArtifactResponse), totalData: z.number().int() })
|
|
10
|
+
|
|
11
|
+
export interface ArtifactListResponse extends z.TypeOf<typeof ArtifactListResponse> {}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { Time } from './Time.js'
|
|
8
|
+
|
|
9
|
+
export const ArtifactResponse = z.object({
|
|
10
|
+
artifactType: z.string(),
|
|
11
|
+
createdOn: Time,
|
|
12
|
+
dsId: z.string(),
|
|
13
|
+
expiresOn: Time,
|
|
14
|
+
filename: z.string(),
|
|
15
|
+
fleetId: z.string(),
|
|
16
|
+
id: z.string(),
|
|
17
|
+
imageId: z.string(),
|
|
18
|
+
namespace: z.string(),
|
|
19
|
+
region: z.string(),
|
|
20
|
+
sizeBytes: z.number().int(),
|
|
21
|
+
status: z.string()
|
|
22
|
+
})
|
|
23
|
+
|
|
24
|
+
export interface ArtifactResponse extends z.TypeOf<typeof ArtifactResponse> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const ArtifactSamplingRule = z.object({ collect: z.boolean(), percentage: z.number().int() })
|
|
9
|
+
|
|
10
|
+
export interface ArtifactSamplingRule extends z.TypeOf<typeof ArtifactSamplingRule> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { ArtifactSamplingRule } from './ArtifactSamplingRule.js'
|
|
8
|
+
|
|
9
|
+
export const ArtifactTypeSamplingRules = z.object({ crashed: ArtifactSamplingRule, success: ArtifactSamplingRule })
|
|
10
|
+
|
|
11
|
+
export interface ArtifactTypeSamplingRules extends z.TypeOf<typeof ArtifactTypeSamplingRules> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const ArtifactUrlResponse = z.object({ url: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface ArtifactUrlResponse extends z.TypeOf<typeof ArtifactUrlResponse> {}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const ArtifactUsageResponse = z.object({
|
|
9
|
+
quotaBytes: z.number().int(),
|
|
10
|
+
remainingBytes: z.number().int(),
|
|
11
|
+
usedBytes: z.number().int()
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
export interface ArtifactUsageResponse extends z.TypeOf<typeof ArtifactUsageResponse> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { InstanceTypeDescriptionResponse } from './InstanceTypeDescriptionResponse.js'
|
|
8
|
+
|
|
9
|
+
export const AvailableInstanceTypesResponse = z.object({ availableInstanceTypes: z.array(InstanceTypeDescriptionResponse) })
|
|
10
|
+
|
|
11
|
+
export interface AvailableInstanceTypesResponse extends z.TypeOf<typeof AvailableInstanceTypesResponse> {}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const DevelopmentServerConfigurationCreateRequest = z.object({
|
|
9
|
+
commandLineArguments: z.string(),
|
|
10
|
+
imageId: z.string(),
|
|
11
|
+
name: z.string()
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
export interface DevelopmentServerConfigurationCreateRequest extends z.TypeOf<typeof DevelopmentServerConfigurationCreateRequest> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const DevelopmentServerConfigurationCreateResponse = z.object({ name: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface DevelopmentServerConfigurationCreateResponse extends z.TypeOf<typeof DevelopmentServerConfigurationCreateResponse> {}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const DevelopmentServerConfigurationGetResponse = z.object({
|
|
9
|
+
commandLineArguments: z.string(),
|
|
10
|
+
imageId: z.string(),
|
|
11
|
+
name: z.string()
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
export interface DevelopmentServerConfigurationGetResponse extends z.TypeOf<typeof DevelopmentServerConfigurationGetResponse> {}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { DevelopmentServerConfigurationGetResponse } from './DevelopmentServerConfigurationGetResponse.js'
|
|
8
|
+
|
|
9
|
+
export const DevelopmentServerConfigurationListResponse = z.object({
|
|
10
|
+
data: z.array(DevelopmentServerConfigurationGetResponse),
|
|
11
|
+
totalData: z.number().int()
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
export interface DevelopmentServerConfigurationListResponse extends z.TypeOf<typeof DevelopmentServerConfigurationListResponse> {}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { Time } from './Time.js'
|
|
8
|
+
|
|
9
|
+
export const DsHistoryEvent = z.object({
|
|
10
|
+
createdAt: Time,
|
|
11
|
+
exitCode: z.number().int(),
|
|
12
|
+
ipAddress: z.string(),
|
|
13
|
+
reason: z.string(),
|
|
14
|
+
region: z.string(),
|
|
15
|
+
serverId: z.string(),
|
|
16
|
+
status: z.string()
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
export interface DsHistoryEvent extends z.TypeOf<typeof DsHistoryEvent> {}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { DsHistoryEvent } from './DsHistoryEvent.js'
|
|
8
|
+
import { PagingInfo } from './PagingInfo.js'
|
|
9
|
+
|
|
10
|
+
export const DsHistoryList = z.object({ events: z.array(DsHistoryEvent), paging: PagingInfo })
|
|
11
|
+
|
|
12
|
+
export interface DsHistoryList extends z.TypeOf<typeof DsHistoryList> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const DsHostConfiguration = z.object({ instanceId: z.string(), instanceType: z.string(), serversPerVm: z.number().int() })
|
|
9
|
+
|
|
10
|
+
export interface DsHostConfiguration extends z.TypeOf<typeof DsHostConfiguration> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const ErrorResponse = z.object({ errorMessage: z.string(), errorType: z.string(), traceId: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface ErrorResponse extends z.TypeOf<typeof ErrorResponse> {}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
import { ArtifactTypeSamplingRules } from './ArtifactTypeSamplingRules.js'
|
|
8
|
+
|
|
9
|
+
export const FleetArtifactsSampleRules = z.object({ coredumps: ArtifactTypeSamplingRules, logs: ArtifactTypeSamplingRules })
|
|
10
|
+
|
|
11
|
+
export interface FleetArtifactsSampleRules extends z.TypeOf<typeof FleetArtifactsSampleRules> {}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2022-2024 AccelByte Inc. All Rights Reserved
|
|
3
|
+
* This is licensed software from AccelByte Inc, for limitations
|
|
4
|
+
* and restrictions contact your company contract manager.
|
|
5
|
+
*/
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export const FleetClaimByKeysReq = z.object({ claimKeys: z.array(z.string()), regions: z.array(z.string()), sessionId: z.string() })
|
|
9
|
+
|
|
10
|
+
export interface FleetClaimByKeysReq extends z.TypeOf<typeof FleetClaimByKeysReq> {}
|