(buildsV1())
createBuildDeprecated- CreateBuildDeprecated⚠️ DeprecateddeleteBuildDeprecated- DeleteBuildDeprecated⚠️ DeprecatedgetBuildInfoDeprecated- GetBuildInfoDeprecated⚠️ DeprecatedgetBuildsDeprecated- GetBuildsDeprecated⚠️ DeprecatedrunBuildDeprecated- RunBuildDeprecated⚠️ Deprecated
Creates a new build. Responds with a buildId
that you must pass to RunBuild()
to build the game server artifact. You can optionally pass in a buildTag
to associate an external version with a build.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
package hello.world;
import dev.hathora.cloud_sdk.HathoraCloud;
import dev.hathora.cloud_sdk.models.errors.ApiError;
import dev.hathora.cloud_sdk.models.operations.CreateBuildDeprecatedResponse;
import dev.hathora.cloud_sdk.models.shared.CreateBuildParams;
import dev.hathora.cloud_sdk.models.shared.Security;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ApiError, Exception {
HathoraCloud sdk = HathoraCloud.builder()
.security(Security.builder()
.hathoraDevToken("<YOUR_BEARER_TOKEN_HERE>")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.orgId("org-6f706e83-0ec1-437a-9a46-7d4281eb2f39")
.build();
CreateBuildDeprecatedResponse res = sdk.buildsV1().createBuildDeprecated()
.createBuildParams(CreateBuildParams.builder()
.buildTag("0.1.14-14c793")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.call();
if (res.build().isPresent()) {
// handle response
}
}
}
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
createBuildParams |
CreateBuildParams | ✔️ | N/A | |
appId |
Optional<String> | ➖ | N/A | app-af469a92-5b45-4565-b3c4-b79878de67d2 |
Error Type | Status Code | Content Type |
---|---|---|
models/errors/ApiError | 401, 404, 422, 429, 500 | application/json |
models/errors/SDKError | 4XX, 5XX | */* |
Delete a build. All associated metadata is deleted.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
package hello.world;
import dev.hathora.cloud_sdk.HathoraCloud;
import dev.hathora.cloud_sdk.models.errors.ApiError;
import dev.hathora.cloud_sdk.models.operations.DeleteBuildDeprecatedResponse;
import dev.hathora.cloud_sdk.models.shared.Security;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ApiError, Exception {
HathoraCloud sdk = HathoraCloud.builder()
.security(Security.builder()
.hathoraDevToken("<YOUR_BEARER_TOKEN_HERE>")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.orgId("org-6f706e83-0ec1-437a-9a46-7d4281eb2f39")
.build();
DeleteBuildDeprecatedResponse res = sdk.buildsV1().deleteBuildDeprecated()
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.buildId(1)
.call();
// handle response
}
}
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
appId |
Optional<String> | ➖ | N/A | app-af469a92-5b45-4565-b3c4-b79878de67d2 |
buildId |
int | ✔️ | N/A | 1 |
Error Type | Status Code | Content Type |
---|---|---|
models/errors/ApiError | 401, 404, 422, 429, 500 | application/json |
models/errors/SDKError | 4XX, 5XX | */* |
Get details for a build.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
package hello.world;
import dev.hathora.cloud_sdk.HathoraCloud;
import dev.hathora.cloud_sdk.models.errors.ApiError;
import dev.hathora.cloud_sdk.models.operations.GetBuildInfoDeprecatedResponse;
import dev.hathora.cloud_sdk.models.shared.Security;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ApiError, Exception {
HathoraCloud sdk = HathoraCloud.builder()
.security(Security.builder()
.hathoraDevToken("<YOUR_BEARER_TOKEN_HERE>")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.orgId("org-6f706e83-0ec1-437a-9a46-7d4281eb2f39")
.build();
GetBuildInfoDeprecatedResponse res = sdk.buildsV1().getBuildInfoDeprecated()
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.buildId(1)
.call();
if (res.build().isPresent()) {
// handle response
}
}
}
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
appId |
Optional<String> | ➖ | N/A | app-af469a92-5b45-4565-b3c4-b79878de67d2 |
buildId |
int | ✔️ | N/A | 1 |
GetBuildInfoDeprecatedResponse
Error Type | Status Code | Content Type |
---|---|---|
models/errors/ApiError | 401, 404, 429 | application/json |
models/errors/SDKError | 4XX, 5XX | */* |
Returns an array of builds for an application.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
package hello.world;
import dev.hathora.cloud_sdk.HathoraCloud;
import dev.hathora.cloud_sdk.models.errors.ApiError;
import dev.hathora.cloud_sdk.models.operations.GetBuildsDeprecatedResponse;
import dev.hathora.cloud_sdk.models.shared.Security;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ApiError, Exception {
HathoraCloud sdk = HathoraCloud.builder()
.security(Security.builder()
.hathoraDevToken("<YOUR_BEARER_TOKEN_HERE>")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.orgId("org-6f706e83-0ec1-437a-9a46-7d4281eb2f39")
.build();
GetBuildsDeprecatedResponse res = sdk.buildsV1().getBuildsDeprecated()
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.call();
if (res.classes().isPresent()) {
// handle response
}
}
}
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
appId |
Optional<String> | ➖ | N/A | app-af469a92-5b45-4565-b3c4-b79878de67d2 |
Error Type | Status Code | Content Type |
---|---|---|
models/errors/ApiError | 401, 404, 429 | application/json |
models/errors/SDKError | 4XX, 5XX | */* |
Builds a game server artifact from a tarball you provide. Pass in the buildId
generated from CreateBuild()
.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
package hello.world;
import dev.hathora.cloud_sdk.HathoraCloud;
import dev.hathora.cloud_sdk.models.errors.ApiError;
import dev.hathora.cloud_sdk.models.operations.File;
import dev.hathora.cloud_sdk.models.operations.RunBuildDeprecatedRequestBody;
import dev.hathora.cloud_sdk.models.operations.RunBuildDeprecatedResponse;
import dev.hathora.cloud_sdk.models.shared.Security;
import java.lang.Exception;
import java.nio.charset.StandardCharsets;
public class Application {
public static void main(String[] args) throws ApiError, Exception {
HathoraCloud sdk = HathoraCloud.builder()
.security(Security.builder()
.hathoraDevToken("<YOUR_BEARER_TOKEN_HERE>")
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.orgId("org-6f706e83-0ec1-437a-9a46-7d4281eb2f39")
.build();
RunBuildDeprecatedResponse res = sdk.buildsV1().runBuildDeprecated()
.requestBody(RunBuildDeprecatedRequestBody.builder()
.file(File.builder()
.content("0x9C4e3B3eB2".getBytes(StandardCharsets.UTF_8))
.fileName("example.file")
.build())
.build())
.appId("app-af469a92-5b45-4565-b3c4-b79878de67d2")
.buildId(1)
.call();
if (res.res().isPresent()) {
// handle response
}
}
}
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
requestBody |
RunBuildDeprecatedRequestBody | ✔️ | N/A | |
appId |
Optional<String> | ➖ | N/A | app-af469a92-5b45-4565-b3c4-b79878de67d2 |
buildId |
int | ✔️ | N/A | 1 |
Error Type | Status Code | Content Type |
---|---|---|
models/errors/ApiError | 400, 401, 404, 429, 500 | application/json |
models/errors/SDKError | 4XX, 5XX | */* |