diff --git a/Cargo.toml b/Cargo.toml index c04af8b05b..2ab8dad422 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,6 +9,39 @@ edition = "2021" authors = ["Rivet Gaming, LLC "] license = "Apache-2.0" +[workspace.dependencies.sqlx] +git = "https://github.com/rivet-gg/sqlx" +rev = "e7120f59" + +[workspace.dependencies.nomad_client] +git = "https://github.com/rivet-gg/nomad-client" +rev = "abb66bf" + +[workspace.dependencies.nomad_client_new] +git = "https://github.com/rivet-gg/nomad-client" +rev = "abb66bf" +package = "nomad_client" + +[workspace.dependencies.async-posthog] +git = "https://github.com/rivet-gg/posthog-rs" +rev = "ef4e80e" + +[workspace.dependencies.cloudflare] +git = "https://github.com/cloudflare/cloudflare-rs" +rev = "f14720e" + +[workspace.dependencies.rivet-term] +git = "https://github.com/rivet-gg/rivet-term" +rev = "d539a07" + +[workspace.dependencies.redis] +git = "https://github.com/rivet-gg/redis-rs" +rev = "ac3e27f" + +[workspace.dependencies.serde_array_query] +git = "https://github.com/rivet-gg/serde_array_query" +rev = "b9f8bfa" + [workspace.dependencies.job-runner] path = "packages/infra/legacy/job-runner" @@ -890,40 +923,6 @@ path = "packages/services/tier" [workspace.dependencies.rivet-api] path = "sdks/full/rust" -[workspace.dependencies.sqlx] -git = "https://github.com/rivet-gg/sqlx" -rev = "e7120f59" - -[workspace.dependencies.nomad_client] -git = "https://github.com/rivet-gg/nomad-client" -rev = "abb66bf" - -[workspace.dependencies.nomad_client_new] -git = "https://github.com/rivet-gg/nomad-client" -rev = "abb66bf" -package = "nomad_client" - -[workspace.dependencies.async-posthog] -git = "https://github.com/rivet-gg/posthog-rs" -rev = "ef4e80e" - -[workspace.dependencies.cloudflare] -git = "https://github.com/cloudflare/cloudflare-rs" -rev = "f14720e" - -[workspace.dependencies.rivet-term] -git = "https://github.com/rivet-gg/rivet-term" -rev = "d539a07" - -[workspace.dependencies.redis] -# TODO: https://github.com/rivet-gg/rivet/issues/508 -git = "https://github.com/rivet-gg/redis-rs" -rev = "ac3e27f" - -[workspace.dependencies.serde_array_query] -git = "https://github.com/rivet-gg/serde_array_query" -rev = "b9f8bfa" - [profile.dev] overflow-checks = false debug = false diff --git a/packages/api/actor/src/route/actors.rs b/packages/api/actor/src/route/actors.rs index 979e8fe9de..b6b59b86e4 100644 --- a/packages/api/actor/src/route/actors.rs +++ b/packages/api/actor/src/route/actors.rs @@ -168,7 +168,7 @@ pub async fn create( routing: if let Some(routing) = p.routing { match *routing { models::ActorPortRouting { - game_guard: Some(gg), + guard: Some(gg), host: None, } => ds::types::Routing::GameGuard { protocol: p.protocol.api_into(), @@ -188,7 +188,7 @@ pub async fn create( }, }, models::ActorPortRouting { - game_guard: None, + guard: None, host: Some(_), } => ds::types::Routing::Host { protocol: p.protocol.api_try_into()?, @@ -295,8 +295,8 @@ pub async fn create_deprecated( }, routing: p.routing.map(|r| { Box::new(models::ActorPortRouting { - game_guard: r.game_guard.map(|_| { - Box::new(models::ActorGameGuardRouting::default()) + guard: r.game_guard.map(|_| { + Box::new(models::ActorGuardRouting::default()) }), host: r.host.map(|_| json!({})), }) @@ -558,7 +558,7 @@ fn legacy_convert_actor_to_server( public_hostname: p.public_hostname, public_port: p.public_port, routing: Box::new(models::ServersPortRouting { - game_guard: p.routing.game_guard.map(|_| json!({})), + game_guard: p.routing.guard.map(|_| json!({})), host: p.routing.host.map(|_| json!({})), }), }, diff --git a/packages/common/config/src/config/server/rivet/cluster_provision.rs b/packages/common/config/src/config/server/rivet/cluster_provision.rs index 43b66a3e74..a9999761c4 100644 --- a/packages/common/config/src/config/server/rivet/cluster_provision.rs +++ b/packages/common/config/src/config/server/rivet/cluster_provision.rs @@ -134,7 +134,7 @@ impl ClusterPoolGg { self.vlan_ip_net().hosts() } - pub fn firewall_rules(&self, gg: &super::GameGuard) -> Vec { + pub fn firewall_rules(&self, gg: &super::Guard) -> Vec { [ FirewallRule::base_rules(), vec![ diff --git a/packages/common/config/src/config/server/rivet/mod.rs b/packages/common/config/src/config/server/rivet/mod.rs index bd77f33839..f36af4a14c 100644 --- a/packages/common/config/src/config/server/rivet/mod.rs +++ b/packages/common/config/src/config/server/rivet/mod.rs @@ -73,7 +73,7 @@ pub struct Rivet { pub pegboard: Pegboard, #[serde(default)] - pub game_guard: GameGuard, + pub guard: Guard, #[serde(default)] pub auth: Auth, @@ -132,7 +132,7 @@ impl Default for Rivet { tunnel: Default::default(), ui: Default::default(), pegboard: Pegboard::default(), - game_guard: GameGuard::default(), + guard: Guard::default(), job_run: None, auth: Auth::default(), token: Tokens::default(), @@ -465,18 +465,18 @@ impl Pegboard { } } -/// The port ranges define what ports Game Guard will allocate ports on. If using cluster +/// The port ranges define what ports Guard will allocate ports on. If using cluster /// provisioning, these are also used for firewall rules. #[derive(Debug, Serialize, Deserialize, Clone, Default)] #[serde(rename_all = "snake_case", deny_unknown_fields)] -pub struct GameGuard { +pub struct Guard { pub min_ingress_port_tcp: Option, pub max_ingress_port_tcp: Option, pub min_ingress_port_udp: Option, pub max_ingress_port_udp: Option, } -impl GameGuard { +impl Guard { pub fn min_ingress_port_tcp(&self) -> u16 { self.min_ingress_port_tcp.unwrap_or(20000) } diff --git a/packages/services/cluster/src/workflows/server/install/install_scripts/components/traefik.rs b/packages/services/cluster/src/workflows/server/install/install_scripts/components/traefik.rs index 041964fb6b..886111aefd 100644 --- a/packages/services/cluster/src/workflows/server/install/install_scripts/components/traefik.rs +++ b/packages/services/cluster/src/workflows/server/install/install_scripts/components/traefik.rs @@ -224,7 +224,7 @@ fn tunnel_dynamic_config(host_tunnel: &str) -> String { pub async fn gg_static_config(config: &rivet_config::Config) -> GlobalResult { let provision_config = config.server()?.rivet.provision()?; - let gg_config = &config.server()?.rivet.game_guard; + let gg_config = &config.server()?.rivet.guard; let http_provider_endpoint = if let Some(api_traefik_provider_token) = &config.server()?.rivet.token.traefik_provider diff --git a/packages/services/ds/src/types.rs b/packages/services/ds/src/types.rs index c9883a5107..1f61c2e954 100644 --- a/packages/services/ds/src/types.rs +++ b/packages/services/ds/src/types.rs @@ -193,7 +193,7 @@ impl ApiFrom for models::ActorPort { } => ( (*protocol).api_into(), models::ActorPortRouting { - game_guard: Some(Box::new(models::ActorGameGuardRouting { + guard: Some(Box::new(models::ActorGuardRouting { authorization: match authorization { PortAuthorization::None => None, PortAuthorization::Bearer(token) => { diff --git a/packages/services/ds/src/workflows/server/mod.rs b/packages/services/ds/src/workflows/server/mod.rs index 8eab05cd52..2d3bf38429 100644 --- a/packages/services/ds/src/workflows/server/mod.rs +++ b/packages/services/ds/src/workflows/server/mod.rs @@ -478,7 +478,7 @@ pub(crate) async fn resolve_image_artifact_url( /// - TCP/TLS: random /// - UDP: random async fn choose_ingress_port(ctx: &ActivityCtx, protocol: GameGuardProtocol) -> GlobalResult { - let gg_config = &ctx.config().server()?.rivet.game_guard; + let gg_config = &ctx.config().server()?.rivet.guard; match protocol { GameGuardProtocol::Http => Ok(80), diff --git a/packages/services/job-run/src/workers/create/mod.rs b/packages/services/job-run/src/workers/create/mod.rs index 425d04a5e9..727f0a8cd4 100644 --- a/packages/services/job-run/src/workers/create/mod.rs +++ b/packages/services/job-run/src/workers/create/mod.rs @@ -337,7 +337,7 @@ async fn choose_ingress_port( ) -> GlobalResult { use backend::job::ProxyProtocol; - let gg_config = &ctx.config().server()?.rivet.game_guard; + let gg_config = &ctx.config().server()?.rivet.guard; let ingress_port = if let Some(ingress_port) = proxied_port.ingress_port { ingress_port as i32 diff --git a/packages/services/linode/src/types.rs b/packages/services/linode/src/types.rs index 5b7f72ce5e..f3f752ce89 100644 --- a/packages/services/linode/src/types.rs +++ b/packages/services/linode/src/types.rs @@ -30,7 +30,7 @@ impl FirewallPreset { FirewallPreset::Gg => provision_config .pools .gg - .firewall_rules(&config.server()?.rivet.game_guard), + .firewall_rules(&config.server()?.rivet.guard), FirewallPreset::Ats => provision_config.pools.ats.firewall_rules(), }) } diff --git a/sdks/fern/definition/actor/common.yml b/sdks/fern/definition/actor/common.yml index 077b2e9667..de7b7c7a64 100644 --- a/sdks/fern/definition/actor/common.yml +++ b/sdks/fern/definition/actor/common.yml @@ -72,10 +72,10 @@ types: PortRouting: properties: - game_guard: optional + guard: optional host: optional - GameGuardRouting: + GuardRouting: properties: authorization: optional diff --git a/sdks/full/go/actor/types.go b/sdks/full/go/actor/types.go index 677f4ab2cc..085d7dd33e 100644 --- a/sdks/full/go/actor/types.go +++ b/sdks/full/go/actor/types.go @@ -174,24 +174,24 @@ func (b *Build) String() string { return fmt.Sprintf("%#v", b) } -type GameGuardRouting struct { +type GuardRouting struct { Authorization *PortAuthorization `json:"authorization,omitempty"` _rawJSON json.RawMessage } -func (g *GameGuardRouting) UnmarshalJSON(data []byte) error { - type unmarshaler GameGuardRouting +func (g *GuardRouting) UnmarshalJSON(data []byte) error { + type unmarshaler GuardRouting var value unmarshaler if err := json.Unmarshal(data, &value); err != nil { return err } - *g = GameGuardRouting(value) + *g = GuardRouting(value) g._rawJSON = json.RawMessage(data) return nil } -func (g *GameGuardRouting) String() string { +func (g *GuardRouting) String() string { if len(g._rawJSON) > 0 { if value, err := core.StringifyJSON(g._rawJSON); err == nil { return value @@ -437,8 +437,8 @@ func (p *PortQueryAuthorization) String() string { } type PortRouting struct { - GameGuard *GameGuardRouting `json:"game_guard,omitempty"` - Host *HostRouting `json:"host,omitempty"` + Guard *GuardRouting `json:"guard,omitempty"` + Host *HostRouting `json:"host,omitempty"` _rawJSON json.RawMessage } diff --git a/sdks/full/openapi/openapi.yml b/sdks/full/openapi/openapi.yml index c19aa28808..5858587f63 100644 --- a/sdks/full/openapi/openapi.yml +++ b/sdks/full/openapi/openapi.yml @@ -9802,11 +9802,11 @@ components: ActorPortRouting: type: object properties: - game_guard: - $ref: '#/components/schemas/ActorGameGuardRouting' + guard: + $ref: '#/components/schemas/ActorGuardRouting' host: $ref: '#/components/schemas/ActorHostRouting' - ActorGameGuardRouting: + ActorGuardRouting: type: object properties: authorization: diff --git a/sdks/full/openapi_compat/openapi.yml b/sdks/full/openapi_compat/openapi.yml index 859919dd42..3bb200b84f 100644 --- a/sdks/full/openapi_compat/openapi.yml +++ b/sdks/full/openapi_compat/openapi.yml @@ -139,11 +139,6 @@ components: ActorDestroyActorResponse: properties: {} type: object - ActorGameGuardRouting: - properties: - authorization: - $ref: '#/components/schemas/ActorPortAuthorization' - type: object ActorGetActorLogsResponse: properties: lines: @@ -177,6 +172,11 @@ components: required: - build type: object + ActorGuardRouting: + properties: + authorization: + $ref: '#/components/schemas/ActorPortAuthorization' + type: object ActorHostRouting: properties: {} type: object @@ -297,8 +297,8 @@ components: type: object ActorPortRouting: properties: - game_guard: - $ref: '#/components/schemas/ActorGameGuardRouting' + guard: + $ref: '#/components/schemas/ActorGuardRouting' host: $ref: '#/components/schemas/ActorHostRouting' type: object diff --git a/sdks/full/rust-cli/.openapi-generator/FILES b/sdks/full/rust-cli/.openapi-generator/FILES index b673b130b3..ec022b0f6e 100644 --- a/sdks/full/rust-cli/.openapi-generator/FILES +++ b/sdks/full/rust-cli/.openapi-generator/FILES @@ -14,10 +14,10 @@ docs/ActorCreateActorPortRequest.md docs/ActorCreateActorRequest.md docs/ActorCreateActorResponse.md docs/ActorCreateActorRuntimeRequest.md -docs/ActorGameGuardRouting.md docs/ActorGetActorLogsResponse.md docs/ActorGetActorResponse.md docs/ActorGetBuildResponse.md +docs/ActorGuardRouting.md docs/ActorLifecycle.md docs/ActorListActorsResponse.md docs/ActorListBuildsResponse.md @@ -422,10 +422,10 @@ src/models/actor_create_actor_port_request.rs src/models/actor_create_actor_request.rs src/models/actor_create_actor_response.rs src/models/actor_create_actor_runtime_request.rs -src/models/actor_game_guard_routing.rs src/models/actor_get_actor_logs_response.rs src/models/actor_get_actor_response.rs src/models/actor_get_build_response.rs +src/models/actor_guard_routing.rs src/models/actor_lifecycle.rs src/models/actor_list_actors_response.rs src/models/actor_list_builds_response.rs diff --git a/sdks/full/rust-cli/README.md b/sdks/full/rust-cli/README.md index 9000226edc..f9b85e0849 100644 --- a/sdks/full/rust-cli/README.md +++ b/sdks/full/rust-cli/README.md @@ -170,10 +170,10 @@ Class | Method | HTTP request | Description - [ActorCreateActorRequest](docs/ActorCreateActorRequest.md) - [ActorCreateActorResponse](docs/ActorCreateActorResponse.md) - [ActorCreateActorRuntimeRequest](docs/ActorCreateActorRuntimeRequest.md) - - [ActorGameGuardRouting](docs/ActorGameGuardRouting.md) - [ActorGetActorLogsResponse](docs/ActorGetActorLogsResponse.md) - [ActorGetActorResponse](docs/ActorGetActorResponse.md) - [ActorGetBuildResponse](docs/ActorGetBuildResponse.md) + - [ActorGuardRouting](docs/ActorGuardRouting.md) - [ActorLifecycle](docs/ActorLifecycle.md) - [ActorListActorsResponse](docs/ActorListActorsResponse.md) - [ActorListBuildsResponse](docs/ActorListBuildsResponse.md) diff --git a/sdks/full/rust-cli/docs/ActorGameGuardRouting.md b/sdks/full/rust-cli/docs/ActorGuardRouting.md similarity index 94% rename from sdks/full/rust-cli/docs/ActorGameGuardRouting.md rename to sdks/full/rust-cli/docs/ActorGuardRouting.md index 4e97cd2ecd..cbac90e5f8 100644 --- a/sdks/full/rust-cli/docs/ActorGameGuardRouting.md +++ b/sdks/full/rust-cli/docs/ActorGuardRouting.md @@ -1,4 +1,4 @@ -# ActorGameGuardRouting +# ActorGuardRouting ## Properties diff --git a/sdks/full/rust-cli/docs/ActorPortRouting.md b/sdks/full/rust-cli/docs/ActorPortRouting.md index d58785562a..72921d39ac 100644 --- a/sdks/full/rust-cli/docs/ActorPortRouting.md +++ b/sdks/full/rust-cli/docs/ActorPortRouting.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**game_guard** | Option<[**crate::models::ActorGameGuardRouting**](ActorGameGuardRouting.md)> | | [optional] +**guard** | Option<[**crate::models::ActorGuardRouting**](ActorGuardRouting.md)> | | [optional] **host** | Option<[**serde_json::Value**](.md)> | | [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) diff --git a/sdks/full/rust-cli/src/models/actor_game_guard_routing.rs b/sdks/full/rust-cli/src/models/actor_guard_routing.rs similarity index 78% rename from sdks/full/rust-cli/src/models/actor_game_guard_routing.rs rename to sdks/full/rust-cli/src/models/actor_guard_routing.rs index b1a29406e2..4ea1eccbc1 100644 --- a/sdks/full/rust-cli/src/models/actor_game_guard_routing.rs +++ b/sdks/full/rust-cli/src/models/actor_guard_routing.rs @@ -12,14 +12,14 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct ActorGameGuardRouting { +pub struct ActorGuardRouting { #[serde(rename = "authorization", skip_serializing_if = "Option::is_none")] pub authorization: Option>, } -impl ActorGameGuardRouting { - pub fn new() -> ActorGameGuardRouting { - ActorGameGuardRouting { +impl ActorGuardRouting { + pub fn new() -> ActorGuardRouting { + ActorGuardRouting { authorization: None, } } diff --git a/sdks/full/rust-cli/src/models/actor_port_routing.rs b/sdks/full/rust-cli/src/models/actor_port_routing.rs index 11da800ef7..d360b659fe 100644 --- a/sdks/full/rust-cli/src/models/actor_port_routing.rs +++ b/sdks/full/rust-cli/src/models/actor_port_routing.rs @@ -13,8 +13,8 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPortRouting { - #[serde(rename = "game_guard", skip_serializing_if = "Option::is_none")] - pub game_guard: Option>, + #[serde(rename = "guard", skip_serializing_if = "Option::is_none")] + pub guard: Option>, #[serde(rename = "host", skip_serializing_if = "Option::is_none")] pub host: Option, } @@ -22,7 +22,7 @@ pub struct ActorPortRouting { impl ActorPortRouting { pub fn new() -> ActorPortRouting { ActorPortRouting { - game_guard: None, + guard: None, host: None, } } diff --git a/sdks/full/rust-cli/src/models/mod.rs b/sdks/full/rust-cli/src/models/mod.rs index b446519041..68b7365a24 100644 --- a/sdks/full/rust-cli/src/models/mod.rs +++ b/sdks/full/rust-cli/src/models/mod.rs @@ -16,14 +16,14 @@ pub mod actor_create_actor_response; pub use self::actor_create_actor_response::ActorCreateActorResponse; pub mod actor_create_actor_runtime_request; pub use self::actor_create_actor_runtime_request::ActorCreateActorRuntimeRequest; -pub mod actor_game_guard_routing; -pub use self::actor_game_guard_routing::ActorGameGuardRouting; pub mod actor_get_actor_logs_response; pub use self::actor_get_actor_logs_response::ActorGetActorLogsResponse; pub mod actor_get_actor_response; pub use self::actor_get_actor_response::ActorGetActorResponse; pub mod actor_get_build_response; pub use self::actor_get_build_response::ActorGetBuildResponse; +pub mod actor_guard_routing; +pub use self::actor_guard_routing::ActorGuardRouting; pub mod actor_lifecycle; pub use self::actor_lifecycle::ActorLifecycle; pub mod actor_list_actors_response; diff --git a/sdks/full/rust/.openapi-generator/FILES b/sdks/full/rust/.openapi-generator/FILES index b673b130b3..ec022b0f6e 100644 --- a/sdks/full/rust/.openapi-generator/FILES +++ b/sdks/full/rust/.openapi-generator/FILES @@ -14,10 +14,10 @@ docs/ActorCreateActorPortRequest.md docs/ActorCreateActorRequest.md docs/ActorCreateActorResponse.md docs/ActorCreateActorRuntimeRequest.md -docs/ActorGameGuardRouting.md docs/ActorGetActorLogsResponse.md docs/ActorGetActorResponse.md docs/ActorGetBuildResponse.md +docs/ActorGuardRouting.md docs/ActorLifecycle.md docs/ActorListActorsResponse.md docs/ActorListBuildsResponse.md @@ -422,10 +422,10 @@ src/models/actor_create_actor_port_request.rs src/models/actor_create_actor_request.rs src/models/actor_create_actor_response.rs src/models/actor_create_actor_runtime_request.rs -src/models/actor_game_guard_routing.rs src/models/actor_get_actor_logs_response.rs src/models/actor_get_actor_response.rs src/models/actor_get_build_response.rs +src/models/actor_guard_routing.rs src/models/actor_lifecycle.rs src/models/actor_list_actors_response.rs src/models/actor_list_builds_response.rs diff --git a/sdks/full/rust/Cargo.toml b/sdks/full/rust/Cargo.toml index 09a3bf0d29..6a448ded68 100644 --- a/sdks/full/rust/Cargo.toml +++ b/sdks/full/rust/Cargo.toml @@ -1,9 +1,9 @@ - [package] name = "rivet-api" version = "0.0.1" authors = ["OpenAPI Generator team and contributors"] description = "No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)" +# Override this license by providing a License Object in the OpenAPI. license = "Unlicense" edition = "2018" @@ -13,11 +13,7 @@ serde_derive = "^1.0" serde_with = "^2.0" serde_json = "^1.0" url = "^2.2" - -[dependencies.uuid] -version = "^1.0" -features = ["serde"] - +uuid = { version = "^1.0", features = ["serde"] } [dependencies.reqwest] version = "^0.11" -features = ["json","multipart"] +features = ["json", "multipart"] diff --git a/sdks/full/rust/README.md b/sdks/full/rust/README.md index 9000226edc..f9b85e0849 100644 --- a/sdks/full/rust/README.md +++ b/sdks/full/rust/README.md @@ -170,10 +170,10 @@ Class | Method | HTTP request | Description - [ActorCreateActorRequest](docs/ActorCreateActorRequest.md) - [ActorCreateActorResponse](docs/ActorCreateActorResponse.md) - [ActorCreateActorRuntimeRequest](docs/ActorCreateActorRuntimeRequest.md) - - [ActorGameGuardRouting](docs/ActorGameGuardRouting.md) - [ActorGetActorLogsResponse](docs/ActorGetActorLogsResponse.md) - [ActorGetActorResponse](docs/ActorGetActorResponse.md) - [ActorGetBuildResponse](docs/ActorGetBuildResponse.md) + - [ActorGuardRouting](docs/ActorGuardRouting.md) - [ActorLifecycle](docs/ActorLifecycle.md) - [ActorListActorsResponse](docs/ActorListActorsResponse.md) - [ActorListBuildsResponse](docs/ActorListBuildsResponse.md) diff --git a/sdks/full/rust/docs/ActorGameGuardRouting.md b/sdks/full/rust/docs/ActorGuardRouting.md similarity index 94% rename from sdks/full/rust/docs/ActorGameGuardRouting.md rename to sdks/full/rust/docs/ActorGuardRouting.md index 4e97cd2ecd..cbac90e5f8 100644 --- a/sdks/full/rust/docs/ActorGameGuardRouting.md +++ b/sdks/full/rust/docs/ActorGuardRouting.md @@ -1,4 +1,4 @@ -# ActorGameGuardRouting +# ActorGuardRouting ## Properties diff --git a/sdks/full/rust/docs/ActorPortRouting.md b/sdks/full/rust/docs/ActorPortRouting.md index d58785562a..72921d39ac 100644 --- a/sdks/full/rust/docs/ActorPortRouting.md +++ b/sdks/full/rust/docs/ActorPortRouting.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**game_guard** | Option<[**crate::models::ActorGameGuardRouting**](ActorGameGuardRouting.md)> | | [optional] +**guard** | Option<[**crate::models::ActorGuardRouting**](ActorGuardRouting.md)> | | [optional] **host** | Option<[**serde_json::Value**](.md)> | | [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) diff --git a/sdks/full/rust/src/apis/actor_api.rs b/sdks/full/rust/src/apis/actor_api.rs index 775ff15fc6..2d51849e5e 100644 --- a/sdks/full/rust/src/apis/actor_api.rs +++ b/sdks/full/rust/src/apis/actor_api.rs @@ -4,294 +4,228 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`actor_create`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorCreateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_destroy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorDestroyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Create a new dynamic actor. -pub async fn actor_create( - configuration: &configuration::Configuration, - actor_create_actor_request: crate::models::ActorCreateActorRequest, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/actors", 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_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&actor_create_actor_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_create(configuration: &configuration::Configuration, actor_create_actor_request: crate::models::ActorCreateActorRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors", 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_create_actor_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Destroy a dynamic actor. -pub async fn actor_destroy( - configuration: &configuration::Configuration, - actor: &str, - project: Option<&str>, - environment: Option<&str>, - override_kill_timeout: Option, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/actors/{actor}", - local_var_configuration.base_path, - actor = crate::apis::urlencode(actor) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = override_kill_timeout { - local_var_req_builder = - local_var_req_builder.query(&[("override_kill_timeout", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_destroy(configuration: &configuration::Configuration, actor: &str, project: Option<&str>, environment: Option<&str>, override_kill_timeout: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors/{actor}", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = override_kill_timeout { + local_var_req_builder = local_var_req_builder.query(&[("override_kill_timeout", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Gets a dynamic actor. -pub async fn actor_get( - configuration: &configuration::Configuration, - actor: &str, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/actors/{actor}", - local_var_configuration.base_path, - actor = crate::apis::urlencode(actor) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } +pub async fn actor_get(configuration: &configuration::Configuration, actor: &str, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors/{actor}", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists all actors associated with the token used. Can be filtered by tags in the query string. -pub async fn actor_list( - configuration: &configuration::Configuration, - project: Option<&str>, - environment: Option<&str>, - tags_json: Option<&str>, - include_destroyed: Option, - cursor: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/actors", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = tags_json { - local_var_req_builder = - local_var_req_builder.query(&[("tags_json", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = include_destroyed { - local_var_req_builder = - local_var_req_builder.query(&[("include_destroyed", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = cursor { - local_var_req_builder = - local_var_req_builder.query(&[("cursor", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>, tags_json: Option<&str>, include_destroyed: Option, cursor: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = include_destroyed { + local_var_req_builder = local_var_req_builder.query(&[("include_destroyed", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = cursor { + local_var_req_builder = local_var_req_builder.query(&[("cursor", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/actor_builds_api.rs b/sdks/full/rust/src/apis/actor_builds_api.rs index 0efffc1bb2..ed106893ef 100644 --- a/sdks/full/rust/src/apis/actor_builds_api.rs +++ b/sdks/full/rust/src/apis/actor_builds_api.rs @@ -4,349 +4,269 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`actor_builds_complete`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorBuildsCompleteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_builds_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorBuildsGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_builds_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorBuildsListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_builds_patch_tags`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorBuildsPatchTagsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`actor_builds_prepare`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorBuildsPrepareError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Marks an upload as complete. -pub async fn actor_builds_complete( - configuration: &configuration::Configuration, - build: &str, - project: Option<&str>, - environment: Option<&str>, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/builds/{build}/complete", - local_var_configuration.base_path, - build = crate::apis::urlencode(build) - ); - 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_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn actor_builds_complete(configuration: &configuration::Configuration, build: &str, project: Option<&str>, environment: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}/complete", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Get a build. -pub async fn actor_builds_get( - configuration: &configuration::Configuration, - build: &str, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/builds/{build}", - local_var_configuration.base_path, - build = crate::apis::urlencode(build) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_builds_get(configuration: &configuration::Configuration, build: &str, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists all builds of the project associated with the token used. Can be filtered by tags in the query string. -pub async fn actor_builds_list( - configuration: &configuration::Configuration, - project: Option<&str>, - environment: Option<&str>, - tags_json: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/builds", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = tags_json { - local_var_req_builder = - local_var_req_builder.query(&[("tags_json", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_builds_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>, tags_json: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } -pub async fn actor_builds_patch_tags( - configuration: &configuration::Configuration, - build: &str, - actor_patch_build_tags_request: crate::models::ActorPatchBuildTagsRequest, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/builds/{build}/tags", - local_var_configuration.base_path, - build = crate::apis::urlencode(build) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::PATCH, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&actor_patch_build_tags_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_builds_patch_tags(configuration: &configuration::Configuration, build: &str, actor_patch_build_tags_request: crate::models::ActorPatchBuildTagsRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}/tags", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::PATCH, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_patch_build_tags_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Creates a new project build for the given project. -pub async fn actor_builds_prepare( - configuration: &configuration::Configuration, - actor_prepare_build_request: crate::models::ActorPrepareBuildRequest, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/builds/prepare", 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_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&actor_prepare_build_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn actor_builds_prepare(configuration: &configuration::Configuration, actor_prepare_build_request: crate::models::ActorPrepareBuildRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/prepare", 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_prepare_build_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/actor_logs_api.rs b/sdks/full/rust/src/apis/actor_logs_api.rs index e5136cbffe..461db7db1d 100644 --- a/sdks/full/rust/src/apis/actor_logs_api.rs +++ b/sdks/full/rust/src/apis/actor_logs_api.rs @@ -4,86 +4,69 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`actor_logs_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorLogsGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns the logs for a given actor. -pub async fn actor_logs_get( - configuration: &configuration::Configuration, - actor: &str, - stream: crate::models::ActorLogStream, - project: Option<&str>, - environment: Option<&str>, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; +pub async fn actor_logs_get(configuration: &configuration::Configuration, actor: &str, stream: crate::models::ActorLogStream, project: Option<&str>, environment: Option<&str>, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!( - "{}/actors/{actor}/logs", - local_var_configuration.base_path, - actor = crate::apis::urlencode(actor) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_uri_str = format!("{}/actors/{actor}/logs", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); - } - local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; - 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 = - 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)) - } + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/actor_regions_api.rs b/sdks/full/rust/src/apis/actor_regions_api.rs index 965ea3902a..4dacb2916b 100644 --- a/sdks/full/rust/src/apis/actor_regions_api.rs +++ b/sdks/full/rust/src/apis/actor_regions_api.rs @@ -4,73 +4,64 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`actor_regions_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ActorRegionsListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn actor_regions_list( - configuration: &configuration::Configuration, - project: Option<&str>, - environment: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; +pub async fn actor_regions_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_uri_str = format!("{}/regions", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_client = &local_var_configuration.client; - if let Some(ref local_var_str) = project { - local_var_req_builder = - local_var_req_builder.query(&[("project", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = environment { - local_var_req_builder = - local_var_req_builder.query(&[("environment", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + let local_var_uri_str = format!("{}/regions", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - 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 = - 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)) - } + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/auth_identity_email_api.rs b/sdks/full/rust/src/apis/auth_identity_email_api.rs index 01663ebd12..751bdad564 100644 --- a/sdks/full/rust/src/apis/auth_identity_email_api.rs +++ b/sdks/full/rust/src/apis/auth_identity_email_api.rs @@ -4,135 +4,105 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`auth_identity_email_complete_email_verification`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum AuthIdentityEmailCompleteEmailVerificationError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`auth_identity_email_start_email_verification`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum AuthIdentityEmailStartEmailVerificationError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Completes the email verification process. -pub async fn auth_identity_email_complete_email_verification( - configuration: &configuration::Configuration, - auth_identity_complete_email_verification_request: crate::models::AuthIdentityCompleteEmailVerificationRequest, -) -> Result< - crate::models::AuthIdentityCompleteEmailVerificationResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/auth/identity/email/complete-verification", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&auth_identity_complete_email_verification_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn auth_identity_email_complete_email_verification(configuration: &configuration::Configuration, auth_identity_complete_email_verification_request: crate::models::AuthIdentityCompleteEmailVerificationRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/auth/identity/email/complete-verification", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&auth_identity_complete_email_verification_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Starts the verification process for linking an email to your identity. -pub async fn auth_identity_email_start_email_verification( - configuration: &configuration::Configuration, - auth_identity_start_email_verification_request: crate::models::AuthIdentityStartEmailVerificationRequest, -) -> Result< - crate::models::AuthIdentityStartEmailVerificationResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/auth/identity/email/start-verification", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&auth_identity_start_email_verification_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn auth_identity_email_start_email_verification(configuration: &configuration::Configuration, auth_identity_start_email_verification_request: crate::models::AuthIdentityStartEmailVerificationRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/auth/identity/email/start-verification", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&auth_identity_start_email_verification_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/auth_tokens_api.rs b/sdks/full/rust/src/apis/auth_tokens_api.rs index e528d6d633..1890915227 100644 --- a/sdks/full/rust/src/apis/auth_tokens_api.rs +++ b/sdks/full/rust/src/apis/auth_tokens_api.rs @@ -4,69 +4,60 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`auth_tokens_refresh_identity_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum AuthTokensRefreshIdentityTokenError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Refreshes the current identity's token and sets authentication headers. -pub async fn auth_tokens_refresh_identity_token( - configuration: &configuration::Configuration, - auth_refresh_identity_token_request: crate::models::AuthRefreshIdentityTokenRequest, -) -> Result< - crate::models::AuthRefreshIdentityTokenResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/auth/tokens/identity", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&auth_refresh_identity_token_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +/// Refreshes the current identity's token and sets authentication headers. +pub async fn auth_tokens_refresh_identity_token(configuration: &configuration::Configuration, auth_refresh_identity_token_request: crate::models::AuthRefreshIdentityTokenRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/auth/tokens/identity", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&auth_refresh_identity_token_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_api.rs b/sdks/full/rust/src/apis/cloud_api.rs index 60482ad366..a440747fbd 100644 --- a/sdks/full/rust/src/apis/cloud_api.rs +++ b/sdks/full/rust/src/apis/cloud_api.rs @@ -4,64 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_bootstrap`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudBootstrapError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns the basic information required to use the cloud APIs. -pub async fn cloud_bootstrap( - configuration: &configuration::Configuration, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/bootstrap", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 the basic information required to use the cloud APIs. +pub async fn cloud_bootstrap(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/bootstrap", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_auth_api.rs b/sdks/full/rust/src/apis/cloud_auth_api.rs index e400bc46b1..dd9b6ace1c 100644 --- a/sdks/full/rust/src/apis/cloud_auth_api.rs +++ b/sdks/full/rust/src/apis/cloud_auth_api.rs @@ -4,64 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_auth_inspect`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudAuthInspectError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns information about the current authenticated agent. -pub async fn cloud_auth_inspect( - configuration: &configuration::Configuration, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/auth/inspect", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 information about the current authenticated agent. +pub async fn cloud_auth_inspect(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/auth/inspect", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_devices_links_api.rs b/sdks/full/rust/src/apis/cloud_devices_links_api.rs index 2d5c04d917..ded16ed7e6 100644 --- a/sdks/full/rust/src/apis/cloud_devices_links_api.rs +++ b/sdks/full/rust/src/apis/cloud_devices_links_api.rs @@ -4,174 +4,140 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_devices_links_complete`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudDevicesLinksCompleteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_devices_links_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudDevicesLinksGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_devices_links_prepare`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudDevicesLinksPrepareError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn cloud_devices_links_complete( - configuration: &configuration::Configuration, - cloud_devices_complete_device_link_request: crate::models::CloudDevicesCompleteDeviceLinkRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/devices/links/complete", - 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(&cloud_devices_complete_device_link_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } + +pub async fn cloud_devices_links_complete(configuration: &configuration::Configuration, cloud_devices_complete_device_link_request: crate::models::CloudDevicesCompleteDeviceLinkRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/devices/links/complete", 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(&cloud_devices_complete_device_link_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } -pub async fn cloud_devices_links_get( - configuration: &configuration::Configuration, - device_link_token: &str, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/devices/links", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - local_var_req_builder = - local_var_req_builder.query(&[("device_link_token", &device_link_token.to_string())]); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_devices_links_get(configuration: &configuration::Configuration, device_link_token: &str, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/devices/links", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + local_var_req_builder = local_var_req_builder.query(&[("device_link_token", &device_link_token.to_string())]); + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } -pub async fn cloud_devices_links_prepare( - configuration: &configuration::Configuration, -) -> Result< - crate::models::CloudDevicesPrepareDeviceLinkResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/devices/links", 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()); - } - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_devices_links_prepare(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/devices/links", 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()); + } + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_api.rs b/sdks/full/rust/src/apis/cloud_games_api.rs index 455760ed69..b9a0a98e2b 100644 --- a/sdks/full/rust/src/apis/cloud_games_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_api.rs @@ -4,490 +4,377 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_create_game`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesCreateGameError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_game_banner_upload_complete`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGameBannerUploadCompleteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_game_banner_upload_prepare`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGameBannerUploadPrepareError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_game_logo_upload_complete`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGameLogoUploadCompleteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_game_logo_upload_prepare`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGameLogoUploadPrepareError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_get_game_by_id`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGetGameByIdError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_get_games`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesGetGamesError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_validate_game`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesValidateGameError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Creates a new game. -pub async fn cloud_games_create_game( - configuration: &configuration::Configuration, - cloud_games_create_game_request: crate::models::CloudGamesCreateGameRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/games", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_create_game(configuration: &configuration::Configuration, cloud_games_create_game_request: crate::models::CloudGamesCreateGameRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Completes an game banner image upload. Must be called after the file upload process completes. -pub async fn cloud_games_game_banner_upload_complete( - configuration: &configuration::Configuration, - game_id: &str, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/banner-upload/{upload_id}/complete", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_game_banner_upload_complete(configuration: &configuration::Configuration, game_id: &str, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/banner-upload/{upload_id}/complete", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Prepares a game banner image upload. -pub async fn cloud_games_game_banner_upload_prepare( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_game_banner_upload_prepare_request: crate::models::CloudGamesGameBannerUploadPrepareRequest, -) -> Result< - crate::models::CloudGamesGameBannerUploadPrepareResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/banner-upload/prepare", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_game_banner_upload_prepare_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_game_banner_upload_prepare(configuration: &configuration::Configuration, game_id: &str, cloud_games_game_banner_upload_prepare_request: crate::models::CloudGamesGameBannerUploadPrepareRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/banner-upload/prepare", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_game_banner_upload_prepare_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Completes a game logo image upload. Must be called after the file upload process completes. -pub async fn cloud_games_game_logo_upload_complete( - configuration: &configuration::Configuration, - game_id: &str, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/logo-upload/{upload_id}/complete", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_game_logo_upload_complete(configuration: &configuration::Configuration, game_id: &str, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/logo-upload/{upload_id}/complete", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Prepares a game logo image upload. -pub async fn cloud_games_game_logo_upload_prepare( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_game_logo_upload_prepare_request: crate::models::CloudGamesGameLogoUploadPrepareRequest, -) -> Result< - crate::models::CloudGamesGameLogoUploadPrepareResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/logo-upload/prepare", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_game_logo_upload_prepare_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_game_logo_upload_prepare(configuration: &configuration::Configuration, game_id: &str, cloud_games_game_logo_upload_prepare_request: crate::models::CloudGamesGameLogoUploadPrepareRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/logo-upload/prepare", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_game_logo_upload_prepare_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a game by its game id. -pub async fn cloud_games_get_game_by_id( - configuration: &configuration::Configuration, - game_id: &str, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_get_game_by_id(configuration: &configuration::Configuration, game_id: &str, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a list of games in which the current identity is a group member of its development team. -pub async fn cloud_games_get_games( - configuration: &configuration::Configuration, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/games", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_get_games(configuration: &configuration::Configuration, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Validates information used to create a new game. -pub async fn cloud_games_validate_game( - configuration: &configuration::Configuration, - cloud_games_validate_game_request: crate::models::CloudGamesValidateGameRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/games/validate", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_validate_game_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_validate_game(configuration: &configuration::Configuration, cloud_games_validate_game_request: crate::models::CloudGamesValidateGameRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/validate", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_validate_game_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_avatars_api.rs b/sdks/full/rust/src/apis/cloud_games_avatars_api.rs index f04e020c20..f8f658cb3b 100644 --- a/sdks/full/rust/src/apis/cloud_games_avatars_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_avatars_api.rs @@ -4,196 +4,148 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_avatars_complete_custom_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesAvatarsCompleteCustomAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_avatars_list_game_custom_avatars`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesAvatarsListGameCustomAvatarsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_avatars_prepare_custom_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesAvatarsPrepareCustomAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Completes a custom avatar image upload. Must be called after the file upload process completes. -pub async fn cloud_games_avatars_complete_custom_avatar_upload( - configuration: &configuration::Configuration, - game_id: &str, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/avatar-upload/{upload_id}/complete", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_avatars_complete_custom_avatar_upload(configuration: &configuration::Configuration, game_id: &str, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/avatar-upload/{upload_id}/complete", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Lists custom avatars for the given game. -pub async fn cloud_games_avatars_list_game_custom_avatars( - configuration: &configuration::Configuration, - game_id: &str, -) -> Result< - crate::models::CloudGamesListGameCustomAvatarsResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/avatars", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_avatars_list_game_custom_avatars(configuration: &configuration::Configuration, game_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/avatars", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Prepares a custom avatar image upload. Complete upload with `rivet.api.cloud#CompleteCustomAvatarUpload`. -pub async fn cloud_games_avatars_prepare_custom_avatar_upload( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_prepare_custom_avatar_upload_request: crate::models::CloudGamesPrepareCustomAvatarUploadRequest, -) -> Result< - crate::models::CloudGamesPrepareCustomAvatarUploadResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/prepare", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_prepare_custom_avatar_upload_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_avatars_prepare_custom_avatar_upload(configuration: &configuration::Configuration, game_id: &str, cloud_games_prepare_custom_avatar_upload_request: crate::models::CloudGamesPrepareCustomAvatarUploadRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/prepare", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_prepare_custom_avatar_upload_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_builds_api.rs b/sdks/full/rust/src/apis/cloud_games_builds_api.rs index 8dcd39fabd..d1bc1e91f6 100644 --- a/sdks/full/rust/src/apis/cloud_games_builds_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_builds_api.rs @@ -4,135 +4,104 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_builds_create_game_build`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesBuildsCreateGameBuildError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_builds_list_game_builds`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesBuildsListGameBuildsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Creates a new game build for the given game. -pub async fn cloud_games_builds_create_game_build( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_create_game_build_request: crate::models::CloudGamesCreateGameBuildRequest, -) -> Result< - crate::models::CloudGamesCreateGameBuildResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/builds", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_build_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_builds_create_game_build(configuration: &configuration::Configuration, game_id: &str, cloud_games_create_game_build_request: crate::models::CloudGamesCreateGameBuildRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/builds", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_build_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists game builds for the given game. -pub async fn cloud_games_builds_list_game_builds( - configuration: &configuration::Configuration, - game_id: &str, -) -> Result< - crate::models::CloudGamesListGameBuildsResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/builds", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_builds_list_game_builds(configuration: &configuration::Configuration, game_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/builds", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_cdn_api.rs b/sdks/full/rust/src/apis/cloud_games_cdn_api.rs index 3c11c484c9..7e017e7854 100644 --- a/sdks/full/rust/src/apis/cloud_games_cdn_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_cdn_api.rs @@ -4,135 +4,104 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_cdn_create_game_cdn_site`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesCdnCreateGameCdnSiteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_cdn_list_game_cdn_sites`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesCdnListGameCdnSitesError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Creates a new CDN site for the given game. -pub async fn cloud_games_cdn_create_game_cdn_site( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_create_game_cdn_site_request: crate::models::CloudGamesCreateGameCdnSiteRequest, -) -> Result< - crate::models::CloudGamesCreateGameCdnSiteResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/cdn/sites", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_cdn_site_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_cdn_create_game_cdn_site(configuration: &configuration::Configuration, game_id: &str, cloud_games_create_game_cdn_site_request: crate::models::CloudGamesCreateGameCdnSiteRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/cdn/sites", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_cdn_site_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists CDN sites for a game. -pub async fn cloud_games_cdn_list_game_cdn_sites( - configuration: &configuration::Configuration, - game_id: &str, -) -> Result< - crate::models::CloudGamesListGameCdnSitesResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/cdn/sites", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_cdn_list_game_cdn_sites(configuration: &configuration::Configuration, game_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/cdn/sites", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_matchmaker_api.rs b/sdks/full/rust/src/apis/cloud_games_matchmaker_api.rs index dd9e9dd021..81ac9a1086 100644 --- a/sdks/full/rust/src/apis/cloud_games_matchmaker_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_matchmaker_api.rs @@ -4,273 +4,197 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_matchmaker_delete_matchmaker_lobby`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesMatchmakerDeleteMatchmakerLobbyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_matchmaker_export_lobby_logs`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesMatchmakerExportLobbyLogsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_matchmaker_export_matchmaker_lobby_history`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesMatchmakerExportMatchmakerLobbyHistoryError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_matchmaker_get_lobby_logs`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesMatchmakerGetLobbyLogsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Deletes a matchmaker lobby, stopping it immediately. -pub async fn cloud_games_matchmaker_delete_matchmaker_lobby( - configuration: &configuration::Configuration, - game_id: &str, - lobby_id: &str, -) -> Result< - crate::models::CloudGamesDeleteMatchmakerLobbyResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - lobby_id = crate::apis::urlencode(lobby_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_matchmaker_delete_matchmaker_lobby(configuration: &configuration::Configuration, game_id: &str, lobby_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), lobby_id=crate::apis::urlencode(lobby_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Generates a download URL for logs. -pub async fn cloud_games_matchmaker_export_lobby_logs( - configuration: &configuration::Configuration, - game_id: &str, - lobby_id: &str, - cloud_games_export_lobby_logs_request: crate::models::CloudGamesExportLobbyLogsRequest, -) -> Result< - crate::models::CloudGamesExportLobbyLogsResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}/logs/export", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - lobby_id = crate::apis::urlencode(lobby_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_export_lobby_logs_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_matchmaker_export_lobby_logs(configuration: &configuration::Configuration, game_id: &str, lobby_id: &str, cloud_games_export_lobby_logs_request: crate::models::CloudGamesExportLobbyLogsRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}/logs/export", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), lobby_id=crate::apis::urlencode(lobby_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_export_lobby_logs_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Exports lobby history over a given query time span. -pub async fn cloud_games_matchmaker_export_matchmaker_lobby_history( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_export_matchmaker_lobby_history_request: crate::models::CloudGamesExportMatchmakerLobbyHistoryRequest, -) -> Result< - crate::models::CloudGamesExportMatchmakerLobbyHistoryResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/matchmaker/lobbies/export-history", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_export_matchmaker_lobby_history_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_matchmaker_export_matchmaker_lobby_history(configuration: &configuration::Configuration, game_id: &str, cloud_games_export_matchmaker_lobby_history_request: crate::models::CloudGamesExportMatchmakerLobbyHistoryRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/matchmaker/lobbies/export-history", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_export_matchmaker_lobby_history_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 the logs for a given lobby. -pub async fn cloud_games_matchmaker_get_lobby_logs( - configuration: &configuration::Configuration, - game_id: &str, - lobby_id: &str, - stream: crate::models::CloudGamesLogStream, - watch_index: Option<&str>, -) -> Result< - crate::models::CloudGamesGetLobbyLogsResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}/logs", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - lobby_id = crate::apis::urlencode(lobby_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_matchmaker_get_lobby_logs(configuration: &configuration::Configuration, game_id: &str, lobby_id: &str, stream: crate::models::CloudGamesLogStream, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/matchmaker/lobbies/{lobby_id}/logs", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), lobby_id=crate::apis::urlencode(lobby_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_namespaces_analytics_api.rs b/sdks/full/rust/src/apis/cloud_games_namespaces_analytics_api.rs index 3ea7312a59..07ac2d5954 100644 --- a/sdks/full/rust/src/apis/cloud_games_namespaces_analytics_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_namespaces_analytics_api.rs @@ -4,74 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_namespaces_analytics_get_analytics_matchmaker_live`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesAnalyticsGetAnalyticsMatchmakerLiveError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns live information about all active lobbies for a given namespace. -pub async fn cloud_games_namespaces_analytics_get_analytics_matchmaker_live( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, -) -> Result< - crate::models::CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/analytics/matchmaker/live", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 live information about all active lobbies for a given namespace. +pub async fn cloud_games_namespaces_analytics_get_analytics_matchmaker_live(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/analytics/matchmaker/live", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_namespaces_api.rs b/sdks/full/rust/src/apis/cloud_games_namespaces_api.rs index 89824582e0..db4128e3af 100644 --- a/sdks/full/rust/src/apis/cloud_games_namespaces_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_namespaces_api.rs @@ -4,1040 +4,736 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_namespaces_add_namespace_domain`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesAddNamespaceDomainError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_create_game_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesCreateGameNamespaceError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_create_game_namespace_token_development`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_create_game_namespace_token_public`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesCreateGameNamespaceTokenPublicError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_get_game_namespace_by_id`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesGetGameNamespaceByIdError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_get_game_namespace_version_history_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesGetGameNamespaceVersionHistoryListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_remove_namespace_cdn_auth_user`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesRemoveNamespaceCdnAuthUserError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_remove_namespace_domain`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesRemoveNamespaceDomainError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_set_namespace_cdn_auth_type`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesSetNamespaceCdnAuthTypeError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_toggle_namespace_domain_public_auth`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesToggleNamespaceDomainPublicAuthError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_update_game_namespace_matchmaker_config`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_update_game_namespace_version`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesUpdateGameNamespaceVersionError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_update_namespace_cdn_auth_user`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesUpdateNamespaceCdnAuthUserError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_validate_game_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesValidateGameNamespaceError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_validate_game_namespace_matchmaker_config`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_validate_game_namespace_token_development`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Adds a domain to the given game namespace. -pub async fn cloud_games_namespaces_add_namespace_domain( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_add_namespace_domain_request: crate::models::CloudGamesNamespacesAddNamespaceDomainRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/domains", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_add_namespace_domain_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_add_namespace_domain(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_add_namespace_domain_request: crate::models::CloudGamesNamespacesAddNamespaceDomainRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/domains", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_add_namespace_domain_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Creates a new namespace for the given game. -pub async fn cloud_games_namespaces_create_game_namespace( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_namespaces_create_game_namespace_request: crate::models::CloudGamesNamespacesCreateGameNamespaceRequest, -) -> Result< - crate::models::CloudGamesNamespacesCreateGameNamespaceResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_create_game_namespace_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_create_game_namespace(configuration: &configuration::Configuration, game_id: &str, cloud_games_namespaces_create_game_namespace_request: crate::models::CloudGamesNamespacesCreateGameNamespaceRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_create_game_namespace_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Creates a development token for the given namespace. -pub async fn cloud_games_namespaces_create_game_namespace_token_development( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_create_game_namespace_token_development_request: crate::models::CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest, -) -> Result< - crate::models::CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/development", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder - .json(&cloud_games_namespaces_create_game_namespace_token_development_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_create_game_namespace_token_development(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_create_game_namespace_token_development_request: crate::models::CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/development", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_create_game_namespace_token_development_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Creates a public token for the given namespace. -pub async fn cloud_games_namespaces_create_game_namespace_token_public( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, -) -> Result< - crate::models::CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/public", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_create_game_namespace_token_public(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/public", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Gets a game namespace by namespace ID. -pub async fn cloud_games_namespaces_get_game_namespace_by_id( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, -) -> Result< - crate::models::CloudGamesNamespacesGetGameNamespaceByIdResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_get_game_namespace_by_id(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Gets the version history for a given namespace. -pub async fn cloud_games_namespaces_get_game_namespace_version_history_list( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - anchor: Option<&str>, - limit: Option, -) -> Result< - crate::models::CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/version-history", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = anchor { - local_var_req_builder = - local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = limit { - local_var_req_builder = - local_var_req_builder.query(&[("limit", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_get_game_namespace_version_history_list(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, anchor: Option<&str>, limit: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/version-history", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = anchor { + local_var_req_builder = local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = limit { + local_var_req_builder = local_var_req_builder.query(&[("limit", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Removes an authenticated user from the given game namespace. -pub async fn cloud_games_namespaces_remove_namespace_cdn_auth_user( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - user: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/auth-user/{user}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id), - user = crate::apis::urlencode(user) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_remove_namespace_cdn_auth_user(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, user: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/auth-user/{user}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id), user=crate::apis::urlencode(user)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Removes a domain from the given game namespace. -pub async fn cloud_games_namespaces_remove_namespace_domain( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - domain: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/domains/{domain}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id), - domain = crate::apis::urlencode(domain) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_remove_namespace_domain(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, domain: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/domains/{domain}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id), domain=crate::apis::urlencode(domain)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 the CDN authentication type of the given game namespace. -pub async fn cloud_games_namespaces_set_namespace_cdn_auth_type( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_set_namespace_cdn_auth_type_request: crate::models::CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/cdn-auth", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_set_namespace_cdn_auth_type_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_set_namespace_cdn_auth_type(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_set_namespace_cdn_auth_type_request: crate::models::CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/cdn-auth", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_set_namespace_cdn_auth_type_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Toggles whether or not to allow authentication based on domain for the given game namespace. -pub async fn cloud_games_namespaces_toggle_namespace_domain_public_auth( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_toggle_namespace_domain_public_auth_request: crate::models::CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/domain-public-auth", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder - .json(&cloud_games_namespaces_toggle_namespace_domain_public_auth_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_toggle_namespace_domain_public_auth(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_toggle_namespace_domain_public_auth_request: crate::models::CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/domain-public-auth", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_toggle_namespace_domain_public_auth_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 matchmaker config for the given game namespace. -pub async fn cloud_games_namespaces_update_game_namespace_matchmaker_config( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_update_game_namespace_matchmaker_config_request: crate::models::CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/mm-config", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder - .json(&cloud_games_namespaces_update_game_namespace_matchmaker_config_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_update_game_namespace_matchmaker_config(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_update_game_namespace_matchmaker_config_request: crate::models::CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/mm-config", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_update_game_namespace_matchmaker_config_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 the version of a game namespace. -pub async fn cloud_games_namespaces_update_game_namespace_version( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_update_game_namespace_version_request: crate::models::CloudGamesNamespacesUpdateGameNamespaceVersionRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/version", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_update_game_namespace_version_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_update_game_namespace_version(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_update_game_namespace_version_request: crate::models::CloudGamesNamespacesUpdateGameNamespaceVersionRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/version", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_update_game_namespace_version_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Adds an authenticated user to the given game namespace. -pub async fn cloud_games_namespaces_update_namespace_cdn_auth_user( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_update_namespace_cdn_auth_user_request: crate::models::CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/auth-user", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_update_namespace_cdn_auth_user_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn cloud_games_namespaces_update_namespace_cdn_auth_user(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_update_namespace_cdn_auth_user_request: crate::models::CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/auth-user", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_update_namespace_cdn_auth_user_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Validates information used to create a new game namespace. -pub async fn cloud_games_namespaces_validate_game_namespace( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_namespaces_validate_game_namespace_request: crate::models::CloudGamesNamespacesValidateGameNamespaceRequest, -) -> Result< - crate::models::CloudGamesNamespacesValidateGameNamespaceResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/validate", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = - local_var_req_builder.json(&cloud_games_namespaces_validate_game_namespace_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_validate_game_namespace(configuration: &configuration::Configuration, game_id: &str, cloud_games_namespaces_validate_game_namespace_request: crate::models::CloudGamesNamespacesValidateGameNamespaceRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/validate", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_validate_game_namespace_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Validates information used to update a game namespace's matchmaker config. -pub async fn cloud_games_namespaces_validate_game_namespace_matchmaker_config( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_validate_game_namespace_matchmaker_config_request: crate::models::CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest, -) -> Result< - crate::models::CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/mm-config/validate", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder - .json(&cloud_games_namespaces_validate_game_namespace_matchmaker_config_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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< - CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigError, - > = 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)) - } +pub async fn cloud_games_namespaces_validate_game_namespace_matchmaker_config(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_validate_game_namespace_matchmaker_config_request: crate::models::CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/mm-config/validate", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_validate_game_namespace_matchmaker_config_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Validates information used to create a new game namespace development token. -pub async fn cloud_games_namespaces_validate_game_namespace_token_development( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - cloud_games_namespaces_validate_game_namespace_token_development_request: crate::models::CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest, -) -> Result< - crate::models::CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/development/validate", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder - .json(&cloud_games_namespaces_validate_game_namespace_token_development_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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< - CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentError, - > = 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)) - } +pub async fn cloud_games_namespaces_validate_game_namespace_token_development(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, cloud_games_namespaces_validate_game_namespace_token_development_request: crate::models::CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/tokens/development/validate", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_namespaces_validate_game_namespace_token_development_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_namespaces_logs_api.rs b/sdks/full/rust/src/apis/cloud_games_namespaces_logs_api.rs index 2a2849f0bd..43e8b17d20 100644 --- a/sdks/full/rust/src/apis/cloud_games_namespaces_logs_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_namespaces_logs_api.rs @@ -4,144 +4,106 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_namespaces_logs_get_namespace_lobby`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesLogsGetNamespaceLobbyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_namespaces_logs_list_namespace_lobbies`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesNamespacesLogsListNamespaceLobbiesError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns a lobby from the given game namespace. -pub async fn cloud_games_namespaces_logs_get_namespace_lobby( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - lobby_id: &str, -) -> Result< - crate::models::CloudGamesNamespacesGetNamespaceLobbyResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/logs/lobbies/{lobby_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id), - lobby_id = crate::apis::urlencode(lobby_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_logs_get_namespace_lobby(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, lobby_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/logs/lobbies/{lobby_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id), lobby_id=crate::apis::urlencode(lobby_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a list of lobbies for the given game namespace. -pub async fn cloud_games_namespaces_logs_list_namespace_lobbies( - configuration: &configuration::Configuration, - game_id: &str, - namespace_id: &str, - before_create_ts: Option, -) -> Result< - crate::models::CloudGamesNamespacesListNamespaceLobbiesResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/namespaces/{namespace_id}/logs/lobbies", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - namespace_id = crate::apis::urlencode(namespace_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = before_create_ts { - local_var_req_builder = - local_var_req_builder.query(&[("before_create_ts", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_namespaces_logs_list_namespace_lobbies(configuration: &configuration::Configuration, game_id: &str, namespace_id: &str, before_create_ts: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/namespaces/{namespace_id}/logs/lobbies", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), namespace_id=crate::apis::urlencode(namespace_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = before_create_ts { + local_var_req_builder = local_var_req_builder.query(&[("before_create_ts", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_tokens_api.rs b/sdks/full/rust/src/apis/cloud_games_tokens_api.rs index b37531cc9a..42318b5460 100644 --- a/sdks/full/rust/src/apis/cloud_games_tokens_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_tokens_api.rs @@ -4,72 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_tokens_create_cloud_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesTokensCreateCloudTokenError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Creates a new game cloud token. -pub async fn cloud_games_tokens_create_cloud_token( - configuration: &configuration::Configuration, - game_id: &str, -) -> Result< - crate::models::CloudGamesCreateCloudTokenResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/tokens/cloud", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +/// Creates a new game cloud token. +pub async fn cloud_games_tokens_create_cloud_token(configuration: &configuration::Configuration, game_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/tokens/cloud", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_games_versions_api.rs b/sdks/full/rust/src/apis/cloud_games_versions_api.rs index a8b523d19a..3b57b01cc3 100644 --- a/sdks/full/rust/src/apis/cloud_games_versions_api.rs +++ b/sdks/full/rust/src/apis/cloud_games_versions_api.rs @@ -4,261 +4,193 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_games_versions_create_game_version`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesVersionsCreateGameVersionError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_versions_get_game_version_by_id`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesVersionsGetGameVersionByIdError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_versions_reserve_version_name`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesVersionsReserveVersionNameError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`cloud_games_versions_validate_game_version`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGamesVersionsValidateGameVersionError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Creates a new game version. -pub async fn cloud_games_versions_create_game_version( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_create_game_version_request: crate::models::CloudGamesCreateGameVersionRequest, -) -> Result< - crate::models::CloudGamesCreateGameVersionResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/versions", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_version_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_versions_create_game_version(configuration: &configuration::Configuration, game_id: &str, cloud_games_create_game_version_request: crate::models::CloudGamesCreateGameVersionRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/versions", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_create_game_version_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a game version by its version ID. -pub async fn cloud_games_versions_get_game_version_by_id( - configuration: &configuration::Configuration, - game_id: &str, - version_id: &str, -) -> Result< - crate::models::CloudGamesGetGameVersionByIdResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/versions/{version_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - version_id = crate::apis::urlencode(version_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_versions_get_game_version_by_id(configuration: &configuration::Configuration, game_id: &str, version_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/versions/{version_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), version_id=crate::apis::urlencode(version_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Reserves a display name for the next version. Used to generate a monotomically increasing build number without causing a race condition with multiple versions getting created at the same time. -pub async fn cloud_games_versions_reserve_version_name( - configuration: &configuration::Configuration, - game_id: &str, -) -> Result< - crate::models::CloudGamesReserveVersionNameResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/versions/reserve-name", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_versions_reserve_version_name(configuration: &configuration::Configuration, game_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/versions/reserve-name", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Validates information used to create a new game version. -pub async fn cloud_games_versions_validate_game_version( - configuration: &configuration::Configuration, - game_id: &str, - cloud_games_validate_game_version_request: crate::models::CloudGamesValidateGameVersionRequest, -) -> Result< - crate::models::CloudGamesValidateGameVersionResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/games/{game_id}/versions/validate", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_games_validate_game_version_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn cloud_games_versions_validate_game_version(configuration: &configuration::Configuration, game_id: &str, cloud_games_validate_game_version_request: crate::models::CloudGamesValidateGameVersionRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/games/{game_id}/versions/validate", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_games_validate_game_version_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_groups_api.rs b/sdks/full/rust/src/apis/cloud_groups_api.rs index 9bf1053e71..74d4ad260f 100644 --- a/sdks/full/rust/src/apis/cloud_groups_api.rs +++ b/sdks/full/rust/src/apis/cloud_groups_api.rs @@ -4,69 +4,60 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_groups_validate`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudGroupsValidateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Validates information used to create a new group. -pub async fn cloud_groups_validate( - configuration: &configuration::Configuration, - cloud_validate_group_request: crate::models::CloudValidateGroupRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/groups/validate", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&cloud_validate_group_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +/// Validates information used to create a new group. +pub async fn cloud_groups_validate(configuration: &configuration::Configuration, cloud_validate_group_request: crate::models::CloudValidateGroupRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/groups/validate", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&cloud_validate_group_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_logs_api.rs b/sdks/full/rust/src/apis/cloud_logs_api.rs index 0fc44fff99..30436fa40d 100644 --- a/sdks/full/rust/src/apis/cloud_logs_api.rs +++ b/sdks/full/rust/src/apis/cloud_logs_api.rs @@ -4,69 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_logs_get_ray_perf_logs`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudLogsGetRayPerfLogsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns performance information about a Rivet Ray. -pub async fn cloud_logs_get_ray_perf_logs( - configuration: &configuration::Configuration, - ray_id: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/rays/{ray_id}/perf", - local_var_configuration.base_path, - ray_id = crate::apis::urlencode(ray_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 performance information about a Rivet Ray. +pub async fn cloud_logs_get_ray_perf_logs(configuration: &configuration::Configuration, ray_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/rays/{ray_id}/perf", local_var_configuration.base_path, ray_id=crate::apis::urlencode(ray_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_tiers_api.rs b/sdks/full/rust/src/apis/cloud_tiers_api.rs index cdecc649c7..3f8df8ee31 100644 --- a/sdks/full/rust/src/apis/cloud_tiers_api.rs +++ b/sdks/full/rust/src/apis/cloud_tiers_api.rs @@ -4,64 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_tiers_get_region_tiers`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudTiersGetRegionTiersError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns all available region tiers. -pub async fn cloud_tiers_get_region_tiers( - configuration: &configuration::Configuration, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/cloud/region-tiers", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 all available region tiers. +pub async fn cloud_tiers_get_region_tiers(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/region-tiers", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/cloud_uploads_api.rs b/sdks/full/rust/src/apis/cloud_uploads_api.rs index 685047855a..5ff4809f43 100644 --- a/sdks/full/rust/src/apis/cloud_uploads_api.rs +++ b/sdks/full/rust/src/apis/cloud_uploads_api.rs @@ -4,69 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`cloud_uploads_complete_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CloudUploadsCompleteUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Marks an upload as complete. -pub async fn cloud_uploads_complete_upload( - configuration: &configuration::Configuration, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/cloud/uploads/{upload_id}/complete", - local_var_configuration.base_path, - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +/// Marks an upload as complete. +pub async fn cloud_uploads_complete_upload(configuration: &configuration::Configuration, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/cloud/uploads/{upload_id}/complete", local_var_configuration.base_path, upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } + diff --git a/sdks/full/rust/src/apis/configuration.rs b/sdks/full/rust/src/apis/configuration.rs index 15eda335ca..6535a51c12 100644 --- a/sdks/full/rust/src/apis/configuration.rs +++ b/sdks/full/rust/src/apis/configuration.rs @@ -4,46 +4,50 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + #[derive(Debug, Clone)] pub struct Configuration { - pub base_path: String, - pub user_agent: Option, - pub client: reqwest::Client, - pub basic_auth: Option, - pub oauth_access_token: Option, - pub bearer_access_token: Option, - pub api_key: Option, - // TODO: take an oauth2 token source, similar to the go one + pub base_path: String, + pub user_agent: Option, + pub client: reqwest::Client, + pub basic_auth: Option, + pub oauth_access_token: Option, + pub bearer_access_token: Option, + pub api_key: Option, + // TODO: take an oauth2 token source, similar to the go one } pub type BasicAuth = (String, Option); #[derive(Debug, Clone)] pub struct ApiKey { - pub prefix: Option, - pub key: String, + pub prefix: Option, + pub key: String, } + impl Configuration { - pub fn new() -> Configuration { - Configuration::default() - } + pub fn new() -> Configuration { + Configuration::default() + } } impl Default for Configuration { - fn default() -> Self { - Configuration { - base_path: "https://api.rivet.gg".to_owned(), - user_agent: Some("OpenAPI-Generator/0.0.1/rust".to_owned()), - client: reqwest::Client::new(), - basic_auth: None, - oauth_access_token: None, - bearer_access_token: None, - api_key: None, - } - } + fn default() -> Self { + Configuration { + base_path: "https://api.rivet.gg".to_owned(), + user_agent: Some("OpenAPI-Generator/0.0.1/rust".to_owned()), + client: reqwest::Client::new(), + basic_auth: None, + oauth_access_token: None, + bearer_access_token: None, + api_key: None, + + } + } } diff --git a/sdks/full/rust/src/apis/games_environments_tokens_api.rs b/sdks/full/rust/src/apis/games_environments_tokens_api.rs index a23e9aedf7..a36af51a32 100644 --- a/sdks/full/rust/src/apis/games_environments_tokens_api.rs +++ b/sdks/full/rust/src/apis/games_environments_tokens_api.rs @@ -4,74 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`games_environments_tokens_create_service_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GamesEnvironmentsTokensCreateServiceTokenError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Creates a new environment service token. -pub async fn games_environments_tokens_create_service_token( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, -) -> Result< - crate::models::GamesEnvironmentsCreateServiceTokenResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/tokens/service", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +/// Creates a new environment service token. +pub async fn games_environments_tokens_create_service_token(configuration: &configuration::Configuration, game_id: &str, environment_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/tokens/service", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/group_api.rs b/sdks/full/rust/src/apis/group_api.rs index 687ea14bc8..a2e46b3ada 100644 --- a/sdks/full/rust/src/apis/group_api.rs +++ b/sdks/full/rust/src/apis/group_api.rs @@ -4,996 +4,755 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`group_ban_identity`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupBanIdentityError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_complete_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupCompleteAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_create`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupCreateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_get_bans`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupGetBansError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_get_join_requests`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupGetJoinRequestsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_get_members`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupGetMembersError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_get_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupGetProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_get_summary`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupGetSummaryError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_kick_member`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupKickMemberError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_leave`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupLeaveError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_list_suggested`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupListSuggestedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_prepare_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupPrepareAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_transfer_ownership`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupTransferOwnershipError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_unban_identity`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupUnbanIdentityError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_update_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupUpdateProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_validate_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupValidateProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Bans an identity from a group. Must be the owner of the group to perform this action. The banned identity will no longer be able to create a join request or use a group invite. -pub async fn group_ban_identity( - configuration: &configuration::Configuration, - group_id: &str, - identity_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/bans/{identity_id}", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id), - identity_id = crate::apis::urlencode(identity_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_ban_identity(configuration: &configuration::Configuration, group_id: &str, identity_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/bans/{identity_id}", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id), identity_id=crate::apis::urlencode(identity_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Completes an avatar image upload. Must be called after the file upload process completes. Call `rivet.api.group#PrepareAvatarUpload` first. -pub async fn group_complete_avatar_upload( - configuration: &configuration::Configuration, - group_id: &str, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/avatar-upload/{upload_id}/complete", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id), - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_complete_avatar_upload(configuration: &configuration::Configuration, group_id: &str, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/avatar-upload/{upload_id}/complete", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id), upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Creates a new group. -pub async fn group_create( - configuration: &configuration::Configuration, - group_create_request: crate::models::GroupCreateRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/group/groups", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_create_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_create(configuration: &configuration::Configuration, group_create_request: crate::models::GroupCreateRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_create_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a group's bans. Must have valid permissions to view. -pub async fn group_get_bans( - configuration: &configuration::Configuration, - group_id: &str, - anchor: Option<&str>, - count: Option, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/bans", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = anchor { - local_var_req_builder = - local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = count { - local_var_req_builder = - local_var_req_builder.query(&[("count", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_get_bans(configuration: &configuration::Configuration, group_id: &str, anchor: Option<&str>, count: Option, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/bans", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = anchor { + local_var_req_builder = local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = count { + local_var_req_builder = local_var_req_builder.query(&[("count", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a group's join requests. Must have valid permissions to view. -pub async fn group_get_join_requests( - configuration: &configuration::Configuration, - group_id: &str, - anchor: Option<&str>, - count: Option, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/join-requests", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = anchor { - local_var_req_builder = - local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = count { - local_var_req_builder = - local_var_req_builder.query(&[("count", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_get_join_requests(configuration: &configuration::Configuration, group_id: &str, anchor: Option<&str>, count: Option, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/join-requests", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = anchor { + local_var_req_builder = local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = count { + local_var_req_builder = local_var_req_builder.query(&[("count", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a group's members. -pub async fn group_get_members( - configuration: &configuration::Configuration, - group_id: &str, - anchor: Option<&str>, - count: Option, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/members", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = anchor { - local_var_req_builder = - local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = count { - local_var_req_builder = - local_var_req_builder.query(&[("count", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_get_members(configuration: &configuration::Configuration, group_id: &str, anchor: Option<&str>, count: Option, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/members", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = anchor { + local_var_req_builder = local_var_req_builder.query(&[("anchor", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = count { + local_var_req_builder = local_var_req_builder.query(&[("count", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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 a group profile. -pub async fn group_get_profile( - configuration: &configuration::Configuration, - group_id: &str, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/profile", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } -} - -pub async fn group_get_summary( - configuration: &configuration::Configuration, - group_id: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/summary", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_get_profile(configuration: &configuration::Configuration, group_id: &str, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/profile", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +pub async fn group_get_summary(configuration: &configuration::Configuration, group_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/summary", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Kicks an identity from a group. Must be the owner of the group to perform this action. -pub async fn group_kick_member( - configuration: &configuration::Configuration, - group_id: &str, - identity_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/kick/{identity_id}", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id), - identity_id = crate::apis::urlencode(identity_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_kick_member(configuration: &configuration::Configuration, group_id: &str, identity_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/kick/{identity_id}", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id), identity_id=crate::apis::urlencode(identity_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Leaves a group. -pub async fn group_leave( - configuration: &configuration::Configuration, - group_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/leave", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_leave(configuration: &configuration::Configuration, group_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/leave", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 a list of suggested groups. -pub async fn group_list_suggested( - configuration: &configuration::Configuration, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/group/groups", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_list_suggested(configuration: &configuration::Configuration, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Prepares an avatar image upload. Complete upload with `rivet.api.group#CompleteAvatarUpload`. -pub async fn group_prepare_avatar_upload( - configuration: &configuration::Configuration, - group_prepare_avatar_upload_request: crate::models::GroupPrepareAvatarUploadRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/avatar-upload/prepare", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_prepare_avatar_upload_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_prepare_avatar_upload(configuration: &configuration::Configuration, group_prepare_avatar_upload_request: crate::models::GroupPrepareAvatarUploadRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/avatar-upload/prepare", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_prepare_avatar_upload_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Transfers ownership of a group to another identity. -pub async fn group_transfer_ownership( - configuration: &configuration::Configuration, - group_id: &str, - group_transfer_ownership_request: crate::models::GroupTransferOwnershipRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/transfer-owner", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_transfer_ownership_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_transfer_ownership(configuration: &configuration::Configuration, group_id: &str, group_transfer_ownership_request: crate::models::GroupTransferOwnershipRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/transfer-owner", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_transfer_ownership_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Unbans an identity from a group. Must be the owner of the group to perform this action. -pub async fn group_unban_identity( - configuration: &configuration::Configuration, - group_id: &str, - identity_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/bans/{identity_id}", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id), - identity_id = crate::apis::urlencode(identity_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } -} - -pub async fn group_update_profile( - configuration: &configuration::Configuration, - group_id: &str, - group_update_profile_request: crate::models::GroupUpdateProfileRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/profile", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_update_profile_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_unban_identity(configuration: &configuration::Configuration, group_id: &str, identity_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/bans/{identity_id}", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id), identity_id=crate::apis::urlencode(identity_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } +} + +pub async fn group_update_profile(configuration: &configuration::Configuration, group_id: &str, group_update_profile_request: crate::models::GroupUpdateProfileRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/profile", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_update_profile_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Validate contents of group profile. Use to provide immediate feedback on profile changes before committing them. -pub async fn group_validate_profile( - configuration: &configuration::Configuration, - group_validate_profile_request: crate::models::GroupValidateProfileRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/profile/validate", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_validate_profile_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_validate_profile(configuration: &configuration::Configuration, group_validate_profile_request: crate::models::GroupValidateProfileRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/profile/validate", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_validate_profile_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/group_invites_api.rs b/sdks/full/rust/src/apis/group_invites_api.rs index 74791d615b..2940010eeb 100644 --- a/sdks/full/rust/src/apis/group_invites_api.rs +++ b/sdks/full/rust/src/apis/group_invites_api.rs @@ -4,187 +4,148 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`group_invites_consume_invite`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupInvitesConsumeInviteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_invites_create_invite`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupInvitesCreateInviteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_invites_get_invite`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupInvitesGetInviteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Consumes a group invite to join a group. -pub async fn group_invites_consume_invite( - configuration: &configuration::Configuration, - group_invite_code: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/invites/{group_invite_code}/consume", - local_var_configuration.base_path, - group_invite_code = crate::apis::urlencode(group_invite_code) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_invites_consume_invite(configuration: &configuration::Configuration, group_invite_code: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/invites/{group_invite_code}/consume", local_var_configuration.base_path, group_invite_code=crate::apis::urlencode(group_invite_code)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Creates a group invite. Can be shared with other identities to let them join this group. -pub async fn group_invites_create_invite( - configuration: &configuration::Configuration, - group_id: &str, - group_create_invite_request: crate::models::GroupCreateInviteRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/invites", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_create_invite_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_invites_create_invite(configuration: &configuration::Configuration, group_id: &str, group_create_invite_request: crate::models::GroupCreateInviteRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/invites", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_create_invite_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Inspects a group invite returning information about the team that created it. -pub async fn group_invites_get_invite( - configuration: &configuration::Configuration, - group_invite_code: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/invites/{group_invite_code}", - local_var_configuration.base_path, - group_invite_code = crate::apis::urlencode(group_invite_code) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn group_invites_get_invite(configuration: &configuration::Configuration, group_invite_code: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/invites/{group_invite_code}", local_var_configuration.base_path, group_invite_code=crate::apis::urlencode(group_invite_code)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/group_join_requests_api.rs b/sdks/full/rust/src/apis/group_join_requests_api.rs index 321fe0c58b..1b345544c5 100644 --- a/sdks/full/rust/src/apis/group_join_requests_api.rs +++ b/sdks/full/rust/src/apis/group_join_requests_api.rs @@ -4,131 +4,104 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`group_join_requests_create_join_request`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupJoinRequestsCreateJoinRequestError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`group_join_requests_resolve_join_request`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GroupJoinRequestsResolveJoinRequestError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Requests to join a group. -pub async fn group_join_requests_create_join_request( - configuration: &configuration::Configuration, - group_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/join-request", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_join_requests_create_join_request(configuration: &configuration::Configuration, group_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/join-request", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Resolves a join request for a given group. -pub async fn group_join_requests_resolve_join_request( - configuration: &configuration::Configuration, - group_id: &str, - identity_id: &str, - group_resolve_join_request_request: crate::models::GroupResolveJoinRequestRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/group/groups/{group_id}/join-request/{identity_id}", - local_var_configuration.base_path, - group_id = crate::apis::urlencode(group_id), - identity_id = crate::apis::urlencode(identity_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&group_resolve_join_request_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn group_join_requests_resolve_join_request(configuration: &configuration::Configuration, group_id: &str, identity_id: &str, group_resolve_join_request_request: crate::models::GroupResolveJoinRequestRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/group/groups/{group_id}/join-request/{identity_id}", local_var_configuration.base_path, group_id=crate::apis::urlencode(group_id), identity_id=crate::apis::urlencode(identity_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&group_resolve_join_request_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } + diff --git a/sdks/full/rust/src/apis/identity_activities_api.rs b/sdks/full/rust/src/apis/identity_activities_api.rs index e559a90ab1..b50c773b28 100644 --- a/sdks/full/rust/src/apis/identity_activities_api.rs +++ b/sdks/full/rust/src/apis/identity_activities_api.rs @@ -4,69 +4,62 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`identity_activities_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityActivitiesListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns an overview of all players currently online or in game. -pub async fn identity_activities_list( - configuration: &configuration::Configuration, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; +pub async fn identity_activities_list(configuration: &configuration::Configuration, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/identity/activities", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_uri_str = format!("{}/identity/activities", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; - 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 = - 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)) - } + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/identity_api.rs b/sdks/full/rust/src/apis/identity_api.rs index f0a656e0f0..fc7ff309f7 100644 --- a/sdks/full/rust/src/apis/identity_api.rs +++ b/sdks/full/rust/src/apis/identity_api.rs @@ -4,883 +4,688 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`identity_complete_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityCompleteAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_get_handles`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityGetHandlesError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_get_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityGetProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_get_self_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityGetSelfProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_get_summaries`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityGetSummariesError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_mark_deletion`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityMarkDeletionError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_prepare_avatar_upload`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityPrepareAvatarUploadError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_remove_game_activity`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityRemoveGameActivityError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_set_game_activity`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentitySetGameActivityError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_setup`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentitySetupError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_signup_for_beta`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentitySignupForBetaError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_unmark_deletion`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityUnmarkDeletionError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_update_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityUpdateProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_update_status`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityUpdateStatusError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`identity_validate_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityValidateProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Completes an avatar image upload. Must be called after the file upload process completes. -pub async fn identity_complete_avatar_upload( - configuration: &configuration::Configuration, - upload_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/avatar-upload/{upload_id}/complete", - local_var_configuration.base_path, - upload_id = crate::apis::urlencode(upload_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_complete_avatar_upload(configuration: &configuration::Configuration, upload_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/avatar-upload/{upload_id}/complete", local_var_configuration.base_path, upload_id=crate::apis::urlencode(upload_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Fetches a list of identity handles. -pub async fn identity_get_handles( - configuration: &configuration::Configuration, - identity_ids: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/batch/handle", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - local_var_req_builder = - local_var_req_builder.query(&[("identity_ids", &identity_ids.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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_get_handles(configuration: &configuration::Configuration, identity_ids: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/batch/handle", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + local_var_req_builder = local_var_req_builder.query(&[("identity_ids", &identity_ids.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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Fetches an identity profile. -pub async fn identity_get_profile( - configuration: &configuration::Configuration, - identity_id: &str, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/{identity_id}/profile", - local_var_configuration.base_path, - identity_id = crate::apis::urlencode(identity_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_get_profile(configuration: &configuration::Configuration, identity_id: &str, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/{identity_id}/profile", local_var_configuration.base_path, identity_id=crate::apis::urlencode(identity_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Fetches the current identity's profile. -pub async fn identity_get_self_profile( - configuration: &configuration::Configuration, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/profile", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_get_self_profile(configuration: &configuration::Configuration, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/profile", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Fetches a list of identity summaries. -pub async fn identity_get_summaries( - configuration: &configuration::Configuration, - identity_ids: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/batch/summary", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - local_var_req_builder = - local_var_req_builder.query(&[("identity_ids", &identity_ids.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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_get_summaries(configuration: &configuration::Configuration, identity_ids: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/batch/summary", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + local_var_req_builder = local_var_req_builder.query(&[("identity_ids", &identity_ids.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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } -pub async fn identity_mark_deletion( - configuration: &configuration::Configuration, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/delete-request", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_mark_deletion(configuration: &configuration::Configuration, ) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/delete-request", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Prepares an avatar image upload. Complete upload with `CompleteIdentityAvatarUpload`. -pub async fn identity_prepare_avatar_upload( - configuration: &configuration::Configuration, - identity_prepare_avatar_upload_request: crate::models::IdentityPrepareAvatarUploadRequest, -) -> Result< - crate::models::IdentityPrepareAvatarUploadResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/avatar-upload/prepare", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_prepare_avatar_upload_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_prepare_avatar_upload(configuration: &configuration::Configuration, identity_prepare_avatar_upload_request: crate::models::IdentityPrepareAvatarUploadRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/avatar-upload/prepare", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_prepare_avatar_upload_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Removes the current identity's game activity. -pub async fn identity_remove_game_activity( - configuration: &configuration::Configuration, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/activity", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_remove_game_activity(configuration: &configuration::Configuration, ) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/activity", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Sets the current identity's game activity. This activity will automatically be removed when the identity goes offline. -pub async fn identity_set_game_activity( - configuration: &configuration::Configuration, - identity_set_game_activity_request: crate::models::IdentitySetGameActivityRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/activity", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_set_game_activity_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_set_game_activity(configuration: &configuration::Configuration, identity_set_game_activity_request: crate::models::IdentitySetGameActivityRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/activity", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_set_game_activity_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Gets or creates an identity. Passing an existing identity token in the body refreshes the token. Temporary Accounts Until the identity is linked with the Rivet Hub (see `PrepareGameLink`), this identity will be temporary but still behave like all other identities. This is intended to allow users to play the game without signing up while still having the benefits of having an account. When they are ready to save their account, they should be instructed to link their account (see `PrepareGameLink`). Storing Token `identity_token` should be stored in some form of persistent storage. The token should be read from storage and passed to `Setup` every time the client starts. -pub async fn identity_setup( - configuration: &configuration::Configuration, - identity_setup_request: crate::models::IdentitySetupRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/identity/identities", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_setup_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn identity_setup(configuration: &configuration::Configuration, identity_setup_request: crate::models::IdentitySetupRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_setup_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Completes an avatar image upload. Must be called after the file upload process completes. -pub async fn identity_signup_for_beta( - configuration: &configuration::Configuration, - identity_signup_for_beta_request: crate::models::IdentitySignupForBetaRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/beta-signup", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_signup_for_beta_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_signup_for_beta(configuration: &configuration::Configuration, identity_signup_for_beta_request: crate::models::IdentitySignupForBetaRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/beta-signup", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_signup_for_beta_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } -pub async fn identity_unmark_deletion( - configuration: &configuration::Configuration, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/delete-request", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_unmark_deletion(configuration: &configuration::Configuration, ) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/delete-request", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 profile of the current identity. -pub async fn identity_update_profile( - configuration: &configuration::Configuration, - identity_update_profile_request: crate::models::IdentityUpdateProfileRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/profile", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_update_profile_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_update_profile(configuration: &configuration::Configuration, identity_update_profile_request: crate::models::IdentityUpdateProfileRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/profile", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_update_profile_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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 the current identity's status. -pub async fn identity_update_status( - configuration: &configuration::Configuration, - identity_update_status_request: crate::models::IdentityUpdateStatusRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/identities/self/status", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_update_status_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_update_status(configuration: &configuration::Configuration, identity_update_status_request: crate::models::IdentityUpdateStatusRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/identities/self/status", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_update_status_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Validate contents of identity profile. Use to provide immediate feedback on profile changes before committing them. -pub async fn identity_validate_profile( - configuration: &configuration::Configuration, - identity_update_profile_request: crate::models::IdentityUpdateProfileRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/identity/identities/self/profile/validate", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&identity_update_profile_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn identity_validate_profile(configuration: &configuration::Configuration, identity_update_profile_request: crate::models::IdentityUpdateProfileRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/identity/identities/self/profile/validate", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&identity_update_profile_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } + diff --git a/sdks/full/rust/src/apis/identity_events_api.rs b/sdks/full/rust/src/apis/identity_events_api.rs index f31335222c..db247b63fe 100644 --- a/sdks/full/rust/src/apis/identity_events_api.rs +++ b/sdks/full/rust/src/apis/identity_events_api.rs @@ -4,69 +4,62 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`identity_events_watch`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum IdentityEventsWatchError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns all events relative to the current identity. -pub async fn identity_events_watch( - configuration: &configuration::Configuration, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; +pub async fn identity_events_watch(configuration: &configuration::Configuration, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/identity/events/live", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_uri_str = format!("{}/identity/events/live", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; - 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 = - 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)) - } + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/job_run_api.rs b/sdks/full/rust/src/apis/job_run_api.rs index de8bad1fd2..a67c3ad575 100644 --- a/sdks/full/rust/src/apis/job_run_api.rs +++ b/sdks/full/rust/src/apis/job_run_api.rs @@ -4,63 +4,58 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`job_run_cleanup`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum JobRunCleanupError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn job_run_cleanup( - configuration: &configuration::Configuration, -) -> Result<(), Error> { - let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; +pub async fn job_run_cleanup(configuration: &configuration::Configuration, ) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_uri_str = format!("{}/job/runs/cleanup", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); + let local_var_client = &local_var_configuration.client; - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + let local_var_uri_str = format!("{}/job/runs/cleanup", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } + diff --git a/sdks/full/rust/src/apis/matchmaker_lobbies_api.rs b/sdks/full/rust/src/apis/matchmaker_lobbies_api.rs index 44a4ce10e5..50c2f0f0c6 100644 --- a/sdks/full/rust/src/apis/matchmaker_lobbies_api.rs +++ b/sdks/full/rust/src/apis/matchmaker_lobbies_api.rs @@ -4,481 +4,378 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`matchmaker_lobbies_create`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesCreateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_find`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesFindError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_get_state`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesGetStateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_join`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesJoinError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_ready`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesReadyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_set_closed`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesSetClosedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_lobbies_set_state`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerLobbiesSetStateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Creates a custom lobby. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_create( - configuration: &configuration::Configuration, - matchmaker_lobbies_create_request: crate::models::MatchmakerLobbiesCreateRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/create", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_create_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_lobbies_create(configuration: &configuration::Configuration, matchmaker_lobbies_create_request: crate::models::MatchmakerLobbiesCreateRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/create", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_create_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Finds a lobby based on the given criteria. If a lobby is not found and `prevent_auto_create_lobby` is `false`, a new lobby will be created. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_find( - configuration: &configuration::Configuration, - matchmaker_lobbies_find_request: crate::models::MatchmakerLobbiesFindRequest, - origin: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/find", - 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()); - } - if let Some(local_var_param_value) = origin { - local_var_req_builder = - local_var_req_builder.header("origin", local_var_param_value.to_string()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_find_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_lobbies_find(configuration: &configuration::Configuration, matchmaker_lobbies_find_request: crate::models::MatchmakerLobbiesFindRequest, origin: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/find", 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()); + } + if let Some(local_var_param_value) = origin { + local_var_req_builder = local_var_req_builder.header("origin", local_var_param_value.to_string()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_find_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Get the state of any lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_get_state( - configuration: &configuration::Configuration, - lobby_id: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/{lobby_id}/state", - local_var_configuration.base_path, - lobby_id = crate::apis::urlencode(lobby_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_lobbies_get_state(configuration: &configuration::Configuration, lobby_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/{lobby_id}/state", local_var_configuration.base_path, lobby_id=crate::apis::urlencode(lobby_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Joins a specific lobby. This request will use the direct player count configured for the lobby group. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_join( - configuration: &configuration::Configuration, - matchmaker_lobbies_join_request: crate::models::MatchmakerLobbiesJoinRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/join", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_join_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_lobbies_join(configuration: &configuration::Configuration, matchmaker_lobbies_join_request: crate::models::MatchmakerLobbiesJoinRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/join", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_join_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists all open lobbies. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_list( - configuration: &configuration::Configuration, - include_state: Option, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/list", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = include_state { - local_var_req_builder = - local_var_req_builder.query(&[("include_state", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_lobbies_list(configuration: &configuration::Configuration, include_state: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/list", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = include_state { + local_var_req_builder = local_var_req_builder.query(&[("include_state", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Marks the current lobby as ready to accept connections. Players will not be able to connect to this lobby until the lobby is flagged as ready. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_ready( - configuration: &configuration::Configuration, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/ready", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn matchmaker_lobbies_ready(configuration: &configuration::Configuration, ) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/ready", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// If `is_closed` is `true`, the matchmaker will no longer route players to the lobby. Players can still join using the /join endpoint (this can be disabled by the developer by rejecting all new connections after setting the lobby to closed). Does not shutdown the lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_set_closed( - configuration: &configuration::Configuration, - matchmaker_lobbies_set_closed_request: crate::models::MatchmakerLobbiesSetClosedRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/closed", - local_var_configuration.base_path - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_set_closed_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn matchmaker_lobbies_set_closed(configuration: &configuration::Configuration, matchmaker_lobbies_set_closed_request: crate::models::MatchmakerLobbiesSetClosedRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/closed", local_var_configuration.base_path); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_set_closed_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Sets the state JSON of the current lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_set_state( - configuration: &configuration::Configuration, - body: Option, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/lobbies/state", - local_var_configuration.base_path - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&body); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn matchmaker_lobbies_set_state(configuration: &configuration::Configuration, body: Option) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/lobbies/state", local_var_configuration.base_path); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&body); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } + diff --git a/sdks/full/rust/src/apis/matchmaker_players_api.rs b/sdks/full/rust/src/apis/matchmaker_players_api.rs index 7121a0a8f8..e0cb52729e 100644 --- a/sdks/full/rust/src/apis/matchmaker_players_api.rs +++ b/sdks/full/rust/src/apis/matchmaker_players_api.rs @@ -4,186 +4,149 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`matchmaker_players_connected`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerPlayersConnectedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_players_disconnected`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerPlayersDisconnectedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`matchmaker_players_get_statistics`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerPlayersGetStatisticsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Validates the player token is valid and has not already been consumed then marks the player as connected. # Player Tokens and Reserved Slots Player tokens reserve a spot in the lobby until they expire. This allows for precise matchmaking up to exactly the lobby's player limit, which is important for games with small lobbies and a high influx of players. By calling this endpoint with the player token, the player's spot is marked as connected and will not expire. If this endpoint is never called, the player's token will expire and this spot will be filled by another player. # Anti-Botting Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. These endpoints have anti-botting measures (i.e. enforcing max player limits, captchas, and detecting bots), so valid player tokens provide some confidence that the player is not a bot. Therefore, it's important to make sure the token is valid by waiting for this endpoint to return OK before allowing the connected socket to do anything else. If this endpoint returns an error, the socket should be disconnected immediately. # How to Transmit the Player Token The client is responsible for acquiring the player token by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. Beyond that, it's up to the developer how the player token is transmitted to the lobby. If using WebSockets, the player token can be transmitted as a query parameter. Otherwise, the player token will likely be automatically sent by the client once the socket opens. As mentioned above, nothing else should happen until the player token is validated. -pub async fn matchmaker_players_connected( - configuration: &configuration::Configuration, - matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/players/connected", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn matchmaker_players_connected(configuration: &configuration::Configuration, matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/players/connected", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Marks a player as disconnected. # Ghost Players If players are not marked as disconnected, lobbies will result with \"ghost players\" that the matchmaker thinks exist but are no longer connected to the lobby. -pub async fn matchmaker_players_disconnected( - configuration: &configuration::Configuration, - matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/players/disconnected", - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn matchmaker_players_disconnected(configuration: &configuration::Configuration, matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/players/disconnected", 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Gives matchmaker statistics about the players in game. -pub async fn matchmaker_players_get_statistics( - configuration: &configuration::Configuration, -) -> Result< - crate::models::MatchmakerGetStatisticsResponse, - Error, -> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/matchmaker/players/statistics", - local_var_configuration.base_path - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn matchmaker_players_get_statistics(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/players/statistics", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/matchmaker_regions_api.rs b/sdks/full/rust/src/apis/matchmaker_regions_api.rs index b7b1b4172c..f70241924f 100644 --- a/sdks/full/rust/src/apis/matchmaker_regions_api.rs +++ b/sdks/full/rust/src/apis/matchmaker_regions_api.rs @@ -4,64 +4,59 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`matchmaker_regions_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum MatchmakerRegionsListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -/// Returns a list of regions available to this namespace. Regions are sorted by most optimal to least optimal. The player's IP address is used to calculate the regions' optimality. -pub async fn matchmaker_regions_list( - configuration: &configuration::Configuration, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/regions", local_var_configuration.base_path); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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 a list of regions available to this namespace. Regions are sorted by most optimal to least optimal. The player's IP address is used to calculate the regions' optimality. +pub async fn matchmaker_regions_list(configuration: &configuration::Configuration, ) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/matchmaker/regions", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/mod.rs b/sdks/full/rust/src/apis/mod.rs index d41027ecc8..d45f134146 100644 --- a/sdks/full/rust/src/apis/mod.rs +++ b/sdks/full/rust/src/apis/mod.rs @@ -3,96 +3,91 @@ use std::fmt; #[derive(Debug, Clone)] pub struct ResponseContent { - pub status: reqwest::StatusCode, - pub content: String, - pub entity: Option, + pub status: reqwest::StatusCode, + pub content: String, + pub entity: Option, } #[derive(Debug)] pub enum Error { - Reqwest(reqwest::Error), - Serde(serde_json::Error), - Io(std::io::Error), - ResponseError(ResponseContent), + Reqwest(reqwest::Error), + Serde(serde_json::Error), + Io(std::io::Error), + ResponseError(ResponseContent), } -impl fmt::Display for Error { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - let (module, e) = match self { - Error::Reqwest(e) => ("reqwest", e.to_string()), - Error::Serde(e) => ("serde", e.to_string()), - Error::Io(e) => ("IO", e.to_string()), - Error::ResponseError(e) => ( - "response", - format!("status code {}\n{}", e.status, e.content), - ), - }; - write!(f, "error in {}: {}", module, e) - } +impl fmt::Display for Error { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + let (module, e) = match self { + Error::Reqwest(e) => ("reqwest", e.to_string()), + Error::Serde(e) => ("serde", e.to_string()), + Error::Io(e) => ("IO", e.to_string()), + Error::ResponseError(e) => ("response", format!("status code {}\n{}", e.status, e.content)), + }; + write!(f, "error in {}: {}", module, e) + } } -impl error::Error for Error { - fn source(&self) -> Option<&(dyn error::Error + 'static)> { - Some(match self { - Error::Reqwest(e) => e, - Error::Serde(e) => e, - Error::Io(e) => e, - Error::ResponseError(_) => return None, - }) - } +impl error::Error for Error { + fn source(&self) -> Option<&(dyn error::Error + 'static)> { + Some(match self { + Error::Reqwest(e) => e, + Error::Serde(e) => e, + Error::Io(e) => e, + Error::ResponseError(_) => return None, + }) + } } -impl From for Error { - fn from(e: reqwest::Error) -> Self { - Error::Reqwest(e) - } +impl From for Error { + fn from(e: reqwest::Error) -> Self { + Error::Reqwest(e) + } } -impl From for Error { - fn from(e: serde_json::Error) -> Self { - Error::Serde(e) - } +impl From for Error { + fn from(e: serde_json::Error) -> Self { + Error::Serde(e) + } } -impl From for Error { - fn from(e: std::io::Error) -> Self { - Error::Io(e) - } +impl From for Error { + fn from(e: std::io::Error) -> Self { + Error::Io(e) + } } pub fn urlencode>(s: T) -> String { - ::url::form_urlencoded::byte_serialize(s.as_ref().as_bytes()).collect() + ::url::form_urlencoded::byte_serialize(s.as_ref().as_bytes()).collect() } pub fn parse_deep_object(prefix: &str, value: &serde_json::Value) -> Vec<(String, String)> { - if let serde_json::Value::Object(object) = value { - let mut params = vec![]; + if let serde_json::Value::Object(object) = value { + let mut params = vec![]; - for (key, value) in object { - match value { - serde_json::Value::Object(_) => params.append(&mut parse_deep_object( - &format!("{}[{}]", prefix, key), - value, - )), - serde_json::Value::Array(array) => { - for (i, value) in array.iter().enumerate() { - params.append(&mut parse_deep_object( - &format!("{}[{}][{}]", prefix, key, i), - value, - )); - } - } - serde_json::Value::String(s) => { - params.push((format!("{}[{}]", prefix, key), s.clone())) - } - _ => params.push((format!("{}[{}]", prefix, key), value.to_string())), - } - } + for (key, value) in object { + match value { + serde_json::Value::Object(_) => params.append(&mut parse_deep_object( + &format!("{}[{}]", prefix, key), + value, + )), + serde_json::Value::Array(array) => { + for (i, value) in array.iter().enumerate() { + params.append(&mut parse_deep_object( + &format!("{}[{}][{}]", prefix, key, i), + value, + )); + } + }, + serde_json::Value::String(s) => params.push((format!("{}[{}]", prefix, key), s.clone())), + _ => params.push((format!("{}[{}]", prefix, key), value.to_string())), + } + } - return params; - } + return params; + } - unimplemented!("Only objects are supported with style=deepObject") + unimplemented!("Only objects are supported with style=deepObject") } pub mod actor_api; @@ -109,8 +104,8 @@ pub mod cloud_games_avatars_api; pub mod cloud_games_builds_api; pub mod cloud_games_cdn_api; pub mod cloud_games_matchmaker_api; -pub mod cloud_games_namespaces_analytics_api; pub mod cloud_games_namespaces_api; +pub mod cloud_games_namespaces_analytics_api; pub mod cloud_games_namespaces_logs_api; pub mod cloud_games_tokens_api; pub mod cloud_games_versions_api; @@ -122,8 +117,8 @@ pub mod games_environments_tokens_api; pub mod group_api; pub mod group_invites_api; pub mod group_join_requests_api; -pub mod identity_activities_api; pub mod identity_api; +pub mod identity_activities_api; pub mod identity_events_api; pub mod job_run_api; pub mod matchmaker_lobbies_api; diff --git a/sdks/full/rust/src/apis/portal_games_api.rs b/sdks/full/rust/src/apis/portal_games_api.rs index c7d12c164d..731e627d6b 100644 --- a/sdks/full/rust/src/apis/portal_games_api.rs +++ b/sdks/full/rust/src/apis/portal_games_api.rs @@ -4,74 +4,62 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`portal_games_get_game_profile`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PortalGamesGetGameProfileError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns a game profile. -pub async fn portal_games_get_game_profile( - configuration: &configuration::Configuration, - game_name_id: &str, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; +pub async fn portal_games_get_game_profile(configuration: &configuration::Configuration, game_name_id: &str, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!( - "{}/portal/games/{game_name_id}/profile", - local_var_configuration.base_path, - game_name_id = crate::apis::urlencode(game_name_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_uri_str = format!("{}/portal/games/{game_name_id}/profile", local_var_configuration.base_path, game_name_id=crate::apis::urlencode(game_name_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; - 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 = - 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)) - } + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/provision_datacenters_api.rs b/sdks/full/rust/src/apis/provision_datacenters_api.rs index 7d5f9673ae..f65a93e263 100644 --- a/sdks/full/rust/src/apis/provision_datacenters_api.rs +++ b/sdks/full/rust/src/apis/provision_datacenters_api.rs @@ -4,69 +4,58 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`provision_datacenters_get_tls`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ProvisionDatacentersGetTlsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn provision_datacenters_get_tls( - configuration: &configuration::Configuration, - datacenter_id: &str, -) -> Result> -{ - let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; +pub async fn provision_datacenters_get_tls(configuration: &configuration::Configuration, datacenter_id: &str) -> Result> { + let local_var_configuration = configuration; - let local_var_uri_str = format!( - "{}/datacenters/{datacenter_id}/tls", - local_var_configuration.base_path, - datacenter_id = crate::apis::urlencode(datacenter_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_client = &local_var_configuration.client; - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + let local_var_uri_str = format!("{}/datacenters/{datacenter_id}/tls", local_var_configuration.base_path, datacenter_id=crate::apis::urlencode(datacenter_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - 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 = - 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)) - } + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/provision_servers_api.rs b/sdks/full/rust/src/apis/provision_servers_api.rs index 7ef19287a8..c2aab2852d 100644 --- a/sdks/full/rust/src/apis/provision_servers_api.rs +++ b/sdks/full/rust/src/apis/provision_servers_api.rs @@ -4,68 +4,58 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`provision_servers_get_info`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ProvisionServersGetInfoError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn provision_servers_get_info( - configuration: &configuration::Configuration, - ip: &str, -) -> Result> { - let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; +pub async fn provision_servers_get_info(configuration: &configuration::Configuration, ip: &str) -> Result> { + let local_var_configuration = configuration; - let local_var_uri_str = format!( - "{}/servers/{ip}", - local_var_configuration.base_path, - ip = crate::apis::urlencode(ip) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_client = &local_var_configuration.client; - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + let local_var_uri_str = format!("{}/servers/{ip}", local_var_configuration.base_path, ip=crate::apis::urlencode(ip)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - 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 = - 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)) - } + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/servers_api.rs b/sdks/full/rust/src/apis/servers_api.rs index a9703b6b99..3ae454a3c5 100644 --- a/sdks/full/rust/src/apis/servers_api.rs +++ b/sdks/full/rust/src/apis/servers_api.rs @@ -4,277 +4,204 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`servers_create`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersCreateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_destroy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersDestroyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Create a new dynamic server. -pub async fn servers_create( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - servers_create_server_request: crate::models::ServersCreateServerRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/servers", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&servers_create_server_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_create(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, servers_create_server_request: crate::models::ServersCreateServerRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/servers", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&servers_create_server_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Destroy a dynamic server. -pub async fn servers_destroy( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - server_id: &str, - override_kill_timeout: Option, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/servers/{server_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - server_id = crate::apis::urlencode(server_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = override_kill_timeout { - local_var_req_builder = - local_var_req_builder.query(&[("override_kill_timeout", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_destroy(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, server_id: &str, override_kill_timeout: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/servers/{server_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), server_id=crate::apis::urlencode(server_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = override_kill_timeout { + local_var_req_builder = local_var_req_builder.query(&[("override_kill_timeout", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Gets a dynamic server. -pub async fn servers_get( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - server_id: &str, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/servers/{server_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - server_id = crate::apis::urlencode(server_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_get(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, server_id: &str) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/servers/{server_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), server_id=crate::apis::urlencode(server_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists all servers associated with the token used. Can be filtered by tags in the query string. -pub async fn servers_list( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - tags_json: Option<&str>, - include_destroyed: Option, - cursor: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/servers", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = tags_json { - local_var_req_builder = - local_var_req_builder.query(&[("tags_json", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = include_destroyed { - local_var_req_builder = - local_var_req_builder.query(&[("include_destroyed", &local_var_str.to_string())]); - } - if let Some(ref local_var_str) = cursor { - local_var_req_builder = - local_var_req_builder.query(&[("cursor", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_list(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, tags_json: Option<&str>, include_destroyed: Option, cursor: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/servers", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = include_destroyed { + local_var_req_builder = local_var_req_builder.query(&[("include_destroyed", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = cursor { + local_var_req_builder = local_var_req_builder.query(&[("cursor", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/servers_builds_api.rs b/sdks/full/rust/src/apis/servers_builds_api.rs index 97ec771029..1dcd704434 100644 --- a/sdks/full/rust/src/apis/servers_builds_api.rs +++ b/sdks/full/rust/src/apis/servers_builds_api.rs @@ -4,330 +4,242 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`servers_builds_complete`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersBuildsCompleteError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_builds_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersBuildsGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_builds_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersBuildsListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_builds_patch_tags`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersBuildsPatchTagsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } /// struct for typed errors of method [`servers_builds_prepare`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersBuildsPrepareError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Marks an upload as complete. -pub async fn servers_builds_complete( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - build_id: &str, -) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/builds/{build_id}/complete", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - build_id = crate::apis::urlencode(build_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = - 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)) - } +pub async fn servers_builds_complete(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, build_id: &str) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/builds/{build_id}/complete", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), build_id=crate::apis::urlencode(build_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } } /// Lists all builds of the game associated with the token used. Can be filtered by tags in the query string. -pub async fn servers_builds_get( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - build_id: &str, - tags_json: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/builds/{build_id}", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - build_id = crate::apis::urlencode(build_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = tags_json { - local_var_req_builder = - local_var_req_builder.query(&[("tags_json", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_builds_get(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, build_id: &str, tags_json: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/builds/{build_id}", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), build_id=crate::apis::urlencode(build_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Lists all builds of the game associated with the token used. Can be filtered by tags in the query string. -pub async fn servers_builds_list( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - tags_json: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/builds", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = tags_json { - local_var_req_builder = - local_var_req_builder.query(&[("tags_json", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_builds_list(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, tags_json: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/builds", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } -pub async fn servers_builds_patch_tags( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - build_id: &str, - servers_patch_build_tags_request: crate::models::ServersPatchBuildTagsRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/builds/{build_id}/tags", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - build_id = crate::apis::urlencode(build_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::PATCH, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&servers_patch_build_tags_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_builds_patch_tags(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, build_id: &str, servers_patch_build_tags_request: crate::models::ServersPatchBuildTagsRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/builds/{build_id}/tags", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), build_id=crate::apis::urlencode(build_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::PATCH, 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&servers_patch_build_tags_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } /// Creates a new game build for the given game. -pub async fn servers_builds_prepare( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - servers_create_build_request: crate::models::ServersCreateBuildRequest, -) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/builds/prepare", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&servers_create_build_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = - 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)) - } +pub async fn servers_builds_prepare(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, servers_create_build_request: crate::models::ServersCreateBuildRequest) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/builds/prepare", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&servers_create_build_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/servers_datacenters_api.rs b/sdks/full/rust/src/apis/servers_datacenters_api.rs index 11e8490029..5bb388081f 100644 --- a/sdks/full/rust/src/apis/servers_datacenters_api.rs +++ b/sdks/full/rust/src/apis/servers_datacenters_api.rs @@ -4,70 +4,58 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`servers_datacenters_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersDatacentersListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } -pub async fn servers_datacenters_list( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, -) -> Result> { - let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; +pub async fn servers_datacenters_list(configuration: &configuration::Configuration, game_id: &str, environment_id: &str) -> Result> { + let local_var_configuration = configuration; - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/datacenters", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_client = &local_var_configuration.client; - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/datacenters", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + 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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - 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 = - 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)) - } + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/apis/servers_logs_api.rs b/sdks/full/rust/src/apis/servers_logs_api.rs index 5d1eb5f386..d0233ea3a7 100644 --- a/sdks/full/rust/src/apis/servers_logs_api.rs +++ b/sdks/full/rust/src/apis/servers_logs_api.rs @@ -4,80 +4,63 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + use reqwest; -use super::{configuration, Error}; use crate::apis::ResponseContent; +use super::{Error, configuration}; + /// struct for typed errors of method [`servers_logs_get`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum ServersLogsGetError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), } + /// Returns the logs for a given server. -pub async fn servers_logs_get( - configuration: &configuration::Configuration, - game_id: &str, - environment_id: &str, - server_id: &str, - stream: crate::models::ServersLogStream, - watch_index: Option<&str>, -) -> Result> { - let local_var_configuration = configuration; +pub async fn servers_logs_get(configuration: &configuration::Configuration, game_id: &str, environment_id: &str, server_id: &str, stream: crate::models::ServersLogStream, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &local_var_configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!( - "{}/games/{game_id}/environments/{environment_id}/servers/{server_id}/logs", - local_var_configuration.base_path, - game_id = crate::apis::urlencode(game_id), - environment_id = crate::apis::urlencode(environment_id), - server_id = crate::apis::urlencode(server_id) - ); - let mut local_var_req_builder = - local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + let local_var_uri_str = format!("{}/games/{game_id}/environments/{environment_id}/servers/{server_id}/logs", local_var_configuration.base_path, game_id=crate::apis::urlencode(game_id), environment_id=crate::apis::urlencode(environment_id), server_id=crate::apis::urlencode(server_id)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); - if let Some(ref local_var_str) = watch_index { - local_var_req_builder = - local_var_req_builder.query(&[("watch_index", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; + local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; - 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 = - 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)) - } + 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 = 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)) + } } + diff --git a/sdks/full/rust/src/lib.rs b/sdks/full/rust/src/lib.rs index fc22e4e4b9..c1dd666f79 100644 --- a/sdks/full/rust/src/lib.rs +++ b/sdks/full/rust/src/lib.rs @@ -1,10 +1,10 @@ #[macro_use] extern crate serde_derive; -extern crate reqwest; extern crate serde; extern crate serde_json; extern crate url; +extern crate reqwest; pub mod apis; pub mod models; diff --git a/sdks/full/rust/src/models/actor_actor.rs b/sdks/full/rust/src/models/actor_actor.rs index 1a2833dd58..15bbcbdf6b 100644 --- a/sdks/full/rust/src/models/actor_actor.rs +++ b/sdks/full/rust/src/models/actor_actor.rs @@ -4,56 +4,52 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorActor { - #[serde(rename = "created_at")] - pub created_at: i64, - #[serde(rename = "destroyed_at", skip_serializing_if = "Option::is_none")] - pub destroyed_at: Option, - #[serde(rename = "id")] - pub id: uuid::Uuid, - #[serde(rename = "lifecycle")] - pub lifecycle: Box, - #[serde(rename = "network")] - pub network: Box, - #[serde(rename = "region")] - pub region: String, - #[serde(rename = "resources")] - pub resources: Box, - #[serde(rename = "runtime")] - pub runtime: Box, - #[serde(rename = "started_at", skip_serializing_if = "Option::is_none")] - pub started_at: Option, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + #[serde(rename = "created_at")] + pub created_at: i64, + #[serde(rename = "destroyed_at", skip_serializing_if = "Option::is_none")] + pub destroyed_at: Option, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "lifecycle")] + pub lifecycle: Box, + #[serde(rename = "network")] + pub network: Box, + #[serde(rename = "region")] + pub region: String, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "started_at", skip_serializing_if = "Option::is_none")] + pub started_at: Option, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ActorActor { - pub fn new( - created_at: i64, - id: uuid::Uuid, - lifecycle: crate::models::ActorLifecycle, - network: crate::models::ActorNetwork, - region: String, - resources: crate::models::ActorResources, - runtime: crate::models::ActorRuntime, - tags: Option, - ) -> ActorActor { - ActorActor { - created_at, - destroyed_at: None, - id, - lifecycle: Box::new(lifecycle), - network: Box::new(network), - region, - resources: Box::new(resources), - runtime: Box::new(runtime), - started_at: None, - tags, - } - } + pub fn new(created_at: i64, id: uuid::Uuid, lifecycle: crate::models::ActorLifecycle, network: crate::models::ActorNetwork, region: String, resources: crate::models::ActorResources, runtime: crate::models::ActorRuntime, tags: Option) -> ActorActor { + ActorActor { + created_at, + destroyed_at: None, + id, + lifecycle: Box::new(lifecycle), + network: Box::new(network), + region, + resources: Box::new(resources), + runtime: Box::new(runtime), + started_at: None, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_build.rs b/sdks/full/rust/src/models/actor_build.rs index 22d4e34bdc..15122033fb 100644 --- a/sdks/full/rust/src/models/actor_build.rs +++ b/sdks/full/rust/src/models/actor_build.rs @@ -4,41 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorBuild { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// RFC3339 timestamp - #[serde(rename = "created_at")] - pub created_at: String, - #[serde(rename = "id")] - pub id: uuid::Uuid, - #[serde(rename = "name")] - pub name: String, - /// Tags of this build - #[serde(rename = "tags")] - pub tags: ::std::collections::HashMap, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "created_at")] + pub created_at: String, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "name")] + pub name: String, + /// Tags of this build + #[serde(rename = "tags")] + pub tags: ::std::collections::HashMap, } impl ActorBuild { - pub fn new( - content_length: i64, - created_at: String, - id: uuid::Uuid, - name: String, - tags: ::std::collections::HashMap, - ) -> ActorBuild { - ActorBuild { - content_length, - created_at, - id, - name, - tags, - } - } + pub fn new(content_length: i64, created_at: String, id: uuid::Uuid, name: String, tags: ::std::collections::HashMap) -> ActorBuild { + ActorBuild { + content_length, + created_at, + id, + name, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_build_compression.rs b/sdks/full/rust/src/models/actor_build_compression.rs index fa57788e02..9554afe9c0 100644 --- a/sdks/full/rust/src/models/actor_build_compression.rs +++ b/sdks/full/rust/src/models/actor_build_compression.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ActorBuildCompression { - #[serde(rename = "none")] - None, - #[serde(rename = "lz4")] - Lz4, + #[serde(rename = "none")] + None, + #[serde(rename = "lz4")] + Lz4, + } impl ToString for ActorBuildCompression { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::Lz4 => String::from("lz4"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::Lz4 => String::from("lz4"), + } + } } impl Default for ActorBuildCompression { - fn default() -> ActorBuildCompression { - Self::None - } + fn default() -> ActorBuildCompression { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/actor_build_kind.rs b/sdks/full/rust/src/models/actor_build_kind.rs index 6b26fe8fd7..9e9fd07ff3 100644 --- a/sdks/full/rust/src/models/actor_build_kind.rs +++ b/sdks/full/rust/src/models/actor_build_kind.rs @@ -4,33 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ActorBuildKind { - #[serde(rename = "docker_image")] - DockerImage, - #[serde(rename = "oci_bundle")] - OciBundle, - #[serde(rename = "javascript")] - Javascript, + #[serde(rename = "docker_image")] + DockerImage, + #[serde(rename = "oci_bundle")] + OciBundle, + #[serde(rename = "javascript")] + Javascript, + } impl ToString for ActorBuildKind { - fn to_string(&self) -> String { - match self { - Self::DockerImage => String::from("docker_image"), - Self::OciBundle => String::from("oci_bundle"), - Self::Javascript => String::from("javascript"), - } - } + fn to_string(&self) -> String { + match self { + Self::DockerImage => String::from("docker_image"), + Self::OciBundle => String::from("oci_bundle"), + Self::Javascript => String::from("javascript"), + } + } } impl Default for ActorBuildKind { - fn default() -> ActorBuildKind { - Self::DockerImage - } + fn default() -> ActorBuildKind { + Self::DockerImage + } } + + + + diff --git a/sdks/full/rust/src/models/actor_create_actor_network_request.rs b/sdks/full/rust/src/models/actor_create_actor_network_request.rs index 8ba2da1ac7..1f8bb0e290 100644 --- a/sdks/full/rust/src/models/actor_create_actor_network_request.rs +++ b/sdks/full/rust/src/models/actor_create_actor_network_request.rs @@ -4,24 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorCreateActorNetworkRequest { - #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] - pub mode: Option, - #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] - pub ports: - Option<::std::collections::HashMap>, + #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] + pub mode: Option, + #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] + pub ports: Option<::std::collections::HashMap>, } impl ActorCreateActorNetworkRequest { - pub fn new() -> ActorCreateActorNetworkRequest { - ActorCreateActorNetworkRequest { - mode: None, - ports: None, - } - } + pub fn new() -> ActorCreateActorNetworkRequest { + ActorCreateActorNetworkRequest { + mode: None, + ports: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_create_actor_port_request.rs b/sdks/full/rust/src/models/actor_create_actor_port_request.rs index 37b0d352a0..74497965ba 100644 --- a/sdks/full/rust/src/models/actor_create_actor_port_request.rs +++ b/sdks/full/rust/src/models/actor_create_actor_port_request.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorCreateActorPortRequest { - #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] - pub internal_port: Option, - #[serde(rename = "protocol")] - pub protocol: crate::models::ActorPortProtocol, - #[serde(rename = "routing", skip_serializing_if = "Option::is_none")] - pub routing: Option>, + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ActorPortProtocol, + #[serde(rename = "routing", skip_serializing_if = "Option::is_none")] + pub routing: Option>, } impl ActorCreateActorPortRequest { - pub fn new(protocol: crate::models::ActorPortProtocol) -> ActorCreateActorPortRequest { - ActorCreateActorPortRequest { - internal_port: None, - protocol, - routing: None, - } - } + pub fn new(protocol: crate::models::ActorPortProtocol) -> ActorCreateActorPortRequest { + ActorCreateActorPortRequest { + internal_port: None, + protocol, + routing: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_create_actor_request.rs b/sdks/full/rust/src/models/actor_create_actor_request.rs index 679c0a0b31..482c9ac50c 100644 --- a/sdks/full/rust/src/models/actor_create_actor_request.rs +++ b/sdks/full/rust/src/models/actor_create_actor_request.rs @@ -4,40 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorCreateActorRequest { - #[serde(rename = "lifecycle", skip_serializing_if = "Option::is_none")] - pub lifecycle: Option>, - #[serde(rename = "network", skip_serializing_if = "Option::is_none")] - pub network: Option>, - #[serde(rename = "region")] - pub region: String, - #[serde(rename = "resources")] - pub resources: Box, - #[serde(rename = "runtime")] - pub runtime: Box, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + #[serde(rename = "lifecycle", skip_serializing_if = "Option::is_none")] + pub lifecycle: Option>, + #[serde(rename = "network", skip_serializing_if = "Option::is_none")] + pub network: Option>, + #[serde(rename = "region")] + pub region: String, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ActorCreateActorRequest { - pub fn new( - region: String, - resources: crate::models::ActorResources, - runtime: crate::models::ActorCreateActorRuntimeRequest, - tags: Option, - ) -> ActorCreateActorRequest { - ActorCreateActorRequest { - lifecycle: None, - network: None, - region, - resources: Box::new(resources), - runtime: Box::new(runtime), - tags, - } - } + pub fn new(region: String, resources: crate::models::ActorResources, runtime: crate::models::ActorCreateActorRuntimeRequest, tags: Option) -> ActorCreateActorRequest { + ActorCreateActorRequest { + lifecycle: None, + network: None, + region, + resources: Box::new(resources), + runtime: Box::new(runtime), + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_create_actor_response.rs b/sdks/full/rust/src/models/actor_create_actor_response.rs index 3a00d20196..bed37f45b7 100644 --- a/sdks/full/rust/src/models/actor_create_actor_response.rs +++ b/sdks/full/rust/src/models/actor_create_actor_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorCreateActorResponse { - #[serde(rename = "actor")] - pub actor: Box, + #[serde(rename = "actor")] + pub actor: Box, } impl ActorCreateActorResponse { - pub fn new(actor: crate::models::ActorActor) -> ActorCreateActorResponse { - ActorCreateActorResponse { - actor: Box::new(actor), - } - } + pub fn new(actor: crate::models::ActorActor) -> ActorCreateActorResponse { + ActorCreateActorResponse { + actor: Box::new(actor), + } + } } + + diff --git a/sdks/full/rust/src/models/actor_create_actor_runtime_request.rs b/sdks/full/rust/src/models/actor_create_actor_runtime_request.rs index 3a22ee1402..502cbdc320 100644 --- a/sdks/full/rust/src/models/actor_create_actor_runtime_request.rs +++ b/sdks/full/rust/src/models/actor_create_actor_runtime_request.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorCreateActorRuntimeRequest { - #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] - pub arguments: Option>, - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] - pub environment: Option<::std::collections::HashMap>, + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, } impl ActorCreateActorRuntimeRequest { - pub fn new(build: uuid::Uuid) -> ActorCreateActorRuntimeRequest { - ActorCreateActorRuntimeRequest { - arguments: None, - build, - environment: None, - } - } + pub fn new(build: uuid::Uuid) -> ActorCreateActorRuntimeRequest { + ActorCreateActorRuntimeRequest { + arguments: None, + build, + environment: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_game_guard_routing.rs b/sdks/full/rust/src/models/actor_game_guard_routing.rs deleted file mode 100644 index f997f43aae..0000000000 --- a/sdks/full/rust/src/models/actor_game_guard_routing.rs +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct ActorGameGuardRouting { - #[serde(rename = "authorization", skip_serializing_if = "Option::is_none")] - pub authorization: Option>, -} - -impl ActorGameGuardRouting { - pub fn new() -> ActorGameGuardRouting { - ActorGameGuardRouting { - authorization: None, - } - } -} diff --git a/sdks/full/rust/src/models/actor_get_actor_logs_response.rs b/sdks/full/rust/src/models/actor_get_actor_logs_response.rs index 29050dd2be..7475d6b35b 100644 --- a/sdks/full/rust/src/models/actor_get_actor_logs_response.rs +++ b/sdks/full/rust/src/models/actor_get_actor_logs_response.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorGetActorLogsResponse { - /// Sorted old to new. - #[serde(rename = "lines")] - pub lines: Vec, - /// Sorted old to new. - #[serde(rename = "timestamps")] - pub timestamps: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// Sorted old to new. + #[serde(rename = "lines")] + pub lines: Vec, + /// Sorted old to new. + #[serde(rename = "timestamps")] + pub timestamps: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl ActorGetActorLogsResponse { - pub fn new( - lines: Vec, - timestamps: Vec, - watch: crate::models::WatchResponse, - ) -> ActorGetActorLogsResponse { - ActorGetActorLogsResponse { - lines, - timestamps, - watch: Box::new(watch), - } - } + pub fn new(lines: Vec, timestamps: Vec, watch: crate::models::WatchResponse) -> ActorGetActorLogsResponse { + ActorGetActorLogsResponse { + lines, + timestamps, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/actor_get_actor_response.rs b/sdks/full/rust/src/models/actor_get_actor_response.rs index 3ed148b70a..39f675add9 100644 --- a/sdks/full/rust/src/models/actor_get_actor_response.rs +++ b/sdks/full/rust/src/models/actor_get_actor_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorGetActorResponse { - #[serde(rename = "actor")] - pub actor: Box, + #[serde(rename = "actor")] + pub actor: Box, } impl ActorGetActorResponse { - pub fn new(actor: crate::models::ActorActor) -> ActorGetActorResponse { - ActorGetActorResponse { - actor: Box::new(actor), - } - } + pub fn new(actor: crate::models::ActorActor) -> ActorGetActorResponse { + ActorGetActorResponse { + actor: Box::new(actor), + } + } } + + diff --git a/sdks/full/rust/src/models/actor_get_build_response.rs b/sdks/full/rust/src/models/actor_get_build_response.rs index 05f748e69c..6b3176958d 100644 --- a/sdks/full/rust/src/models/actor_get_build_response.rs +++ b/sdks/full/rust/src/models/actor_get_build_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorGetBuildResponse { - #[serde(rename = "build")] - pub build: Box, + #[serde(rename = "build")] + pub build: Box, } impl ActorGetBuildResponse { - pub fn new(build: crate::models::ActorBuild) -> ActorGetBuildResponse { - ActorGetBuildResponse { - build: Box::new(build), - } - } + pub fn new(build: crate::models::ActorBuild) -> ActorGetBuildResponse { + ActorGetBuildResponse { + build: Box::new(build), + } + } } + + diff --git a/sdks/full/rust/src/models/actor_guard_routing.rs b/sdks/full/rust/src/models/actor_guard_routing.rs new file mode 100644 index 0000000000..4ea1eccbc1 --- /dev/null +++ b/sdks/full/rust/src/models/actor_guard_routing.rs @@ -0,0 +1,28 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorGuardRouting { + #[serde(rename = "authorization", skip_serializing_if = "Option::is_none")] + pub authorization: Option>, +} + +impl ActorGuardRouting { + pub fn new() -> ActorGuardRouting { + ActorGuardRouting { + authorization: None, + } + } +} + + diff --git a/sdks/full/rust/src/models/actor_lifecycle.rs b/sdks/full/rust/src/models/actor_lifecycle.rs index 42e1da1398..bb91f243a0 100644 --- a/sdks/full/rust/src/models/actor_lifecycle.rs +++ b/sdks/full/rust/src/models/actor_lifecycle.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorLifecycle { - /// The duration to wait for in milliseconds before killing the actor. This should be set to a safe default, and can be overridden during a DELETE request if needed. - #[serde(rename = "kill_timeout", skip_serializing_if = "Option::is_none")] - pub kill_timeout: Option, + /// The duration to wait for in milliseconds before killing the actor. This should be set to a safe default, and can be overridden during a DELETE request if needed. + #[serde(rename = "kill_timeout", skip_serializing_if = "Option::is_none")] + pub kill_timeout: Option, } impl ActorLifecycle { - pub fn new() -> ActorLifecycle { - ActorLifecycle { kill_timeout: None } - } + pub fn new() -> ActorLifecycle { + ActorLifecycle { + kill_timeout: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_list_actors_response.rs b/sdks/full/rust/src/models/actor_list_actors_response.rs index b3b58db82b..36c315efc1 100644 --- a/sdks/full/rust/src/models/actor_list_actors_response.rs +++ b/sdks/full/rust/src/models/actor_list_actors_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorListActorsResponse { - /// A list of actors for the project associated with the token. - #[serde(rename = "actors")] - pub actors: Vec, + /// A list of actors for the project associated with the token. + #[serde(rename = "actors")] + pub actors: Vec, } impl ActorListActorsResponse { - pub fn new(actors: Vec) -> ActorListActorsResponse { - ActorListActorsResponse { actors } - } + pub fn new(actors: Vec) -> ActorListActorsResponse { + ActorListActorsResponse { + actors, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_list_builds_response.rs b/sdks/full/rust/src/models/actor_list_builds_response.rs index 33d4f7f426..d7aa8fc073 100644 --- a/sdks/full/rust/src/models/actor_list_builds_response.rs +++ b/sdks/full/rust/src/models/actor_list_builds_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorListBuildsResponse { - /// A list of builds for the project associated with the token. - #[serde(rename = "builds")] - pub builds: Vec, + /// A list of builds for the project associated with the token. + #[serde(rename = "builds")] + pub builds: Vec, } impl ActorListBuildsResponse { - pub fn new(builds: Vec) -> ActorListBuildsResponse { - ActorListBuildsResponse { builds } - } + pub fn new(builds: Vec) -> ActorListBuildsResponse { + ActorListBuildsResponse { + builds, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_list_regions_response.rs b/sdks/full/rust/src/models/actor_list_regions_response.rs index 1176e11a7e..cee15d56f7 100644 --- a/sdks/full/rust/src/models/actor_list_regions_response.rs +++ b/sdks/full/rust/src/models/actor_list_regions_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorListRegionsResponse { - #[serde(rename = "regions")] - pub regions: Vec, + #[serde(rename = "regions")] + pub regions: Vec, } impl ActorListRegionsResponse { - pub fn new(regions: Vec) -> ActorListRegionsResponse { - ActorListRegionsResponse { regions } - } + pub fn new(regions: Vec) -> ActorListRegionsResponse { + ActorListRegionsResponse { + regions, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_log_stream.rs b/sdks/full/rust/src/models/actor_log_stream.rs index 613798dbdb..e4ec433d4f 100644 --- a/sdks/full/rust/src/models/actor_log_stream.rs +++ b/sdks/full/rust/src/models/actor_log_stream.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ActorLogStream { - #[serde(rename = "std_out")] - StdOut, - #[serde(rename = "std_err")] - StdErr, + #[serde(rename = "std_out")] + StdOut, + #[serde(rename = "std_err")] + StdErr, + } impl ToString for ActorLogStream { - fn to_string(&self) -> String { - match self { - Self::StdOut => String::from("std_out"), - Self::StdErr => String::from("std_err"), - } - } + fn to_string(&self) -> String { + match self { + Self::StdOut => String::from("std_out"), + Self::StdErr => String::from("std_err"), + } + } } impl Default for ActorLogStream { - fn default() -> ActorLogStream { - Self::StdOut - } + fn default() -> ActorLogStream { + Self::StdOut + } } + + + + diff --git a/sdks/full/rust/src/models/actor_network.rs b/sdks/full/rust/src/models/actor_network.rs index b04123d30c..00c077b796 100644 --- a/sdks/full/rust/src/models/actor_network.rs +++ b/sdks/full/rust/src/models/actor_network.rs @@ -4,23 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorNetwork { - #[serde(rename = "mode")] - pub mode: crate::models::ActorNetworkMode, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "mode")] + pub mode: crate::models::ActorNetworkMode, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl ActorNetwork { - pub fn new( - mode: crate::models::ActorNetworkMode, - ports: ::std::collections::HashMap, - ) -> ActorNetwork { - ActorNetwork { mode, ports } - } + pub fn new(mode: crate::models::ActorNetworkMode, ports: ::std::collections::HashMap) -> ActorNetwork { + ActorNetwork { + mode, + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_network_mode.rs b/sdks/full/rust/src/models/actor_network_mode.rs index 505cdbb6fe..db460774fb 100644 --- a/sdks/full/rust/src/models/actor_network_mode.rs +++ b/sdks/full/rust/src/models/actor_network_mode.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ActorNetworkMode { - #[serde(rename = "bridge")] - Bridge, - #[serde(rename = "host")] - Host, + #[serde(rename = "bridge")] + Bridge, + #[serde(rename = "host")] + Host, + } impl ToString for ActorNetworkMode { - fn to_string(&self) -> String { - match self { - Self::Bridge => String::from("bridge"), - Self::Host => String::from("host"), - } - } + fn to_string(&self) -> String { + match self { + Self::Bridge => String::from("bridge"), + Self::Host => String::from("host"), + } + } } impl Default for ActorNetworkMode { - fn default() -> ActorNetworkMode { - Self::Bridge - } + fn default() -> ActorNetworkMode { + Self::Bridge + } } + + + + diff --git a/sdks/full/rust/src/models/actor_patch_build_tags_request.rs b/sdks/full/rust/src/models/actor_patch_build_tags_request.rs index 5957395ec4..26ec7f51b9 100644 --- a/sdks/full/rust/src/models/actor_patch_build_tags_request.rs +++ b/sdks/full/rust/src/models/actor_patch_build_tags_request.rs @@ -4,24 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPatchBuildTagsRequest { - /// Removes the given tag keys from all other builds. - #[serde(rename = "exclusive_tags", skip_serializing_if = "Option::is_none")] - pub exclusive_tags: Option>, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + /// Removes the given tag keys from all other builds. + #[serde(rename = "exclusive_tags", skip_serializing_if = "Option::is_none")] + pub exclusive_tags: Option>, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ActorPatchBuildTagsRequest { - pub fn new(tags: Option) -> ActorPatchBuildTagsRequest { - ActorPatchBuildTagsRequest { - exclusive_tags: None, - tags, - } - } + pub fn new(tags: Option) -> ActorPatchBuildTagsRequest { + ActorPatchBuildTagsRequest { + exclusive_tags: None, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_port.rs b/sdks/full/rust/src/models/actor_port.rs index 0f090c51e0..a217927b23 100644 --- a/sdks/full/rust/src/models/actor_port.rs +++ b/sdks/full/rust/src/models/actor_port.rs @@ -4,35 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPort { - #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] - pub internal_port: Option, - #[serde(rename = "protocol")] - pub protocol: crate::models::ActorPortProtocol, - #[serde(rename = "public_hostname", skip_serializing_if = "Option::is_none")] - pub public_hostname: Option, - #[serde(rename = "public_port", skip_serializing_if = "Option::is_none")] - pub public_port: Option, - #[serde(rename = "routing")] - pub routing: Box, + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ActorPortProtocol, + #[serde(rename = "public_hostname", skip_serializing_if = "Option::is_none")] + pub public_hostname: Option, + #[serde(rename = "public_port", skip_serializing_if = "Option::is_none")] + pub public_port: Option, + #[serde(rename = "routing")] + pub routing: Box, } impl ActorPort { - pub fn new( - protocol: crate::models::ActorPortProtocol, - routing: crate::models::ActorPortRouting, - ) -> ActorPort { - ActorPort { - internal_port: None, - protocol, - public_hostname: None, - public_port: None, - routing: Box::new(routing), - } - } + pub fn new(protocol: crate::models::ActorPortProtocol, routing: crate::models::ActorPortRouting) -> ActorPort { + ActorPort { + internal_port: None, + protocol, + public_hostname: None, + public_port: None, + routing: Box::new(routing), + } + } } + + diff --git a/sdks/full/rust/src/models/actor_port_authorization.rs b/sdks/full/rust/src/models/actor_port_authorization.rs index f49785d6a2..c3962e01ac 100644 --- a/sdks/full/rust/src/models/actor_port_authorization.rs +++ b/sdks/full/rust/src/models/actor_port_authorization.rs @@ -4,23 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPortAuthorization { - #[serde(rename = "bearer", skip_serializing_if = "Option::is_none")] - pub bearer: Option, - #[serde(rename = "query", skip_serializing_if = "Option::is_none")] - pub query: Option>, + #[serde(rename = "bearer", skip_serializing_if = "Option::is_none")] + pub bearer: Option, + #[serde(rename = "query", skip_serializing_if = "Option::is_none")] + pub query: Option>, } impl ActorPortAuthorization { - pub fn new() -> ActorPortAuthorization { - ActorPortAuthorization { - bearer: None, - query: None, - } - } + pub fn new() -> ActorPortAuthorization { + ActorPortAuthorization { + bearer: None, + query: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_port_protocol.rs b/sdks/full/rust/src/models/actor_port_protocol.rs index c5e9d49c1e..06ef550fe2 100644 --- a/sdks/full/rust/src/models/actor_port_protocol.rs +++ b/sdks/full/rust/src/models/actor_port_protocol.rs @@ -4,39 +4,45 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ActorPortProtocol { - #[serde(rename = "http")] - Http, - #[serde(rename = "https")] - Https, - #[serde(rename = "tcp")] - Tcp, - #[serde(rename = "tcp_tls")] - TcpTls, - #[serde(rename = "udp")] - Udp, + #[serde(rename = "http")] + Http, + #[serde(rename = "https")] + Https, + #[serde(rename = "tcp")] + Tcp, + #[serde(rename = "tcp_tls")] + TcpTls, + #[serde(rename = "udp")] + Udp, + } impl ToString for ActorPortProtocol { - fn to_string(&self) -> String { - match self { - Self::Http => String::from("http"), - Self::Https => String::from("https"), - Self::Tcp => String::from("tcp"), - Self::TcpTls => String::from("tcp_tls"), - Self::Udp => String::from("udp"), - } - } + fn to_string(&self) -> String { + match self { + Self::Http => String::from("http"), + Self::Https => String::from("https"), + Self::Tcp => String::from("tcp"), + Self::TcpTls => String::from("tcp_tls"), + Self::Udp => String::from("udp"), + } + } } impl Default for ActorPortProtocol { - fn default() -> ActorPortProtocol { - Self::Http - } + fn default() -> ActorPortProtocol { + Self::Http + } } + + + + diff --git a/sdks/full/rust/src/models/actor_port_query_authorization.rs b/sdks/full/rust/src/models/actor_port_query_authorization.rs index a559e7adc3..ea8b447713 100644 --- a/sdks/full/rust/src/models/actor_port_query_authorization.rs +++ b/sdks/full/rust/src/models/actor_port_query_authorization.rs @@ -4,20 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPortQueryAuthorization { - #[serde(rename = "key")] - pub key: String, - #[serde(rename = "value")] - pub value: String, + #[serde(rename = "key")] + pub key: String, + #[serde(rename = "value")] + pub value: String, } impl ActorPortQueryAuthorization { - pub fn new(key: String, value: String) -> ActorPortQueryAuthorization { - ActorPortQueryAuthorization { key, value } - } + pub fn new(key: String, value: String) -> ActorPortQueryAuthorization { + ActorPortQueryAuthorization { + key, + value, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_port_routing.rs b/sdks/full/rust/src/models/actor_port_routing.rs index e976434af8..d360b659fe 100644 --- a/sdks/full/rust/src/models/actor_port_routing.rs +++ b/sdks/full/rust/src/models/actor_port_routing.rs @@ -4,23 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPortRouting { - #[serde(rename = "game_guard", skip_serializing_if = "Option::is_none")] - pub game_guard: Option>, - #[serde(rename = "host", skip_serializing_if = "Option::is_none")] - pub host: Option, + #[serde(rename = "guard", skip_serializing_if = "Option::is_none")] + pub guard: Option>, + #[serde(rename = "host", skip_serializing_if = "Option::is_none")] + pub host: Option, } impl ActorPortRouting { - pub fn new() -> ActorPortRouting { - ActorPortRouting { - game_guard: None, - host: None, - } - } + pub fn new() -> ActorPortRouting { + ActorPortRouting { + guard: None, + host: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_prepare_build_request.rs b/sdks/full/rust/src/models/actor_prepare_build_request.rs index 6e9fe09547..ddf999bf9c 100644 --- a/sdks/full/rust/src/models/actor_prepare_build_request.rs +++ b/sdks/full/rust/src/models/actor_prepare_build_request.rs @@ -4,42 +4,44 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPrepareBuildRequest { - #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] - pub compression: Option, - #[serde(rename = "image_file")] - pub image_file: Box, - /// A tag given to the project build. - #[serde(rename = "image_tag", skip_serializing_if = "Option::is_none")] - pub image_tag: Option, - #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] - pub kind: Option, - #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] - pub multipart_upload: Option, - #[serde(rename = "name")] - pub name: String, - #[serde(rename = "prewarm_regions", skip_serializing_if = "Option::is_none")] - pub prewarm_regions: Option>, + #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] + pub compression: Option, + #[serde(rename = "image_file")] + pub image_file: Box, + /// A tag given to the project build. + #[serde(rename = "image_tag", skip_serializing_if = "Option::is_none")] + pub image_tag: Option, + #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] + pub kind: Option, + #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] + pub multipart_upload: Option, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "prewarm_regions", skip_serializing_if = "Option::is_none")] + pub prewarm_regions: Option>, } impl ActorPrepareBuildRequest { - pub fn new( - image_file: crate::models::UploadPrepareFile, - name: String, - ) -> ActorPrepareBuildRequest { - ActorPrepareBuildRequest { - compression: None, - image_file: Box::new(image_file), - image_tag: None, - kind: None, - multipart_upload: None, - name, - prewarm_regions: None, - } - } + pub fn new(image_file: crate::models::UploadPrepareFile, name: String) -> ActorPrepareBuildRequest { + ActorPrepareBuildRequest { + compression: None, + image_file: Box::new(image_file), + image_tag: None, + kind: None, + multipart_upload: None, + name, + prewarm_regions: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_prepare_build_response.rs b/sdks/full/rust/src/models/actor_prepare_build_response.rs index 67aacbb8a1..9dd9f19ece 100644 --- a/sdks/full/rust/src/models/actor_prepare_build_response.rs +++ b/sdks/full/rust/src/models/actor_prepare_build_response.rs @@ -4,32 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorPrepareBuildResponse { - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde( - rename = "image_presigned_request", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_request: Option>, - #[serde( - rename = "image_presigned_requests", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_requests: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "image_presigned_request", skip_serializing_if = "Option::is_none")] + pub image_presigned_request: Option>, + #[serde(rename = "image_presigned_requests", skip_serializing_if = "Option::is_none")] + pub image_presigned_requests: Option>, } impl ActorPrepareBuildResponse { - pub fn new(build: uuid::Uuid) -> ActorPrepareBuildResponse { - ActorPrepareBuildResponse { - build, - image_presigned_request: None, - image_presigned_requests: None, - } - } + pub fn new(build: uuid::Uuid) -> ActorPrepareBuildResponse { + ActorPrepareBuildResponse { + build, + image_presigned_request: None, + image_presigned_requests: None, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_region.rs b/sdks/full/rust/src/models/actor_region.rs index f22e5492f2..9d89f0371e 100644 --- a/sdks/full/rust/src/models/actor_region.rs +++ b/sdks/full/rust/src/models/actor_region.rs @@ -4,20 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorRegion { - #[serde(rename = "id")] - pub id: String, - #[serde(rename = "name")] - pub name: String, + #[serde(rename = "id")] + pub id: String, + #[serde(rename = "name")] + pub name: String, } impl ActorRegion { - pub fn new(id: String, name: String) -> ActorRegion { - ActorRegion { id, name } - } + pub fn new(id: String, name: String) -> ActorRegion { + ActorRegion { + id, + name, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_resources.rs b/sdks/full/rust/src/models/actor_resources.rs index 7d8d3661aa..57d7dc7ed4 100644 --- a/sdks/full/rust/src/models/actor_resources.rs +++ b/sdks/full/rust/src/models/actor_resources.rs @@ -4,22 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorResources { - /// The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. - #[serde(rename = "cpu")] - pub cpu: i32, - /// The amount of memory in megabytes - #[serde(rename = "memory")] - pub memory: i32, + /// The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. + #[serde(rename = "cpu")] + pub cpu: i32, + /// The amount of memory in megabytes + #[serde(rename = "memory")] + pub memory: i32, } impl ActorResources { - pub fn new(cpu: i32, memory: i32) -> ActorResources { - ActorResources { cpu, memory } - } + pub fn new(cpu: i32, memory: i32) -> ActorResources { + ActorResources { + cpu, + memory, + } + } } + + diff --git a/sdks/full/rust/src/models/actor_runtime.rs b/sdks/full/rust/src/models/actor_runtime.rs index 80e8ddcda9..63ba97b4e7 100644 --- a/sdks/full/rust/src/models/actor_runtime.rs +++ b/sdks/full/rust/src/models/actor_runtime.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ActorRuntime { - #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] - pub arguments: Option>, - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] - pub environment: Option<::std::collections::HashMap>, + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, } impl ActorRuntime { - pub fn new(build: uuid::Uuid) -> ActorRuntime { - ActorRuntime { - arguments: None, - build, - environment: None, - } - } + pub fn new(build: uuid::Uuid) -> ActorRuntime { + ActorRuntime { + arguments: None, + build, + environment: None, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_complete_status.rs b/sdks/full/rust/src/models/auth_complete_status.rs index a7fca96169..f2d9876170 100644 --- a/sdks/full/rust/src/models/auth_complete_status.rs +++ b/sdks/full/rust/src/models/auth_complete_status.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,35 +13,40 @@ /// Represents the state of an external account linking process. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum AuthCompleteStatus { - #[serde(rename = "switch_identity")] - SwitchIdentity, - #[serde(rename = "linked_account_added")] - LinkedAccountAdded, - #[serde(rename = "already_complete")] - AlreadyComplete, - #[serde(rename = "expired")] - Expired, - #[serde(rename = "too_many_attempts")] - TooManyAttempts, - #[serde(rename = "incorrect")] - Incorrect, + #[serde(rename = "switch_identity")] + SwitchIdentity, + #[serde(rename = "linked_account_added")] + LinkedAccountAdded, + #[serde(rename = "already_complete")] + AlreadyComplete, + #[serde(rename = "expired")] + Expired, + #[serde(rename = "too_many_attempts")] + TooManyAttempts, + #[serde(rename = "incorrect")] + Incorrect, + } impl ToString for AuthCompleteStatus { - fn to_string(&self) -> String { - match self { - Self::SwitchIdentity => String::from("switch_identity"), - Self::LinkedAccountAdded => String::from("linked_account_added"), - Self::AlreadyComplete => String::from("already_complete"), - Self::Expired => String::from("expired"), - Self::TooManyAttempts => String::from("too_many_attempts"), - Self::Incorrect => String::from("incorrect"), - } - } + fn to_string(&self) -> String { + match self { + Self::SwitchIdentity => String::from("switch_identity"), + Self::LinkedAccountAdded => String::from("linked_account_added"), + Self::AlreadyComplete => String::from("already_complete"), + Self::Expired => String::from("expired"), + Self::TooManyAttempts => String::from("too_many_attempts"), + Self::Incorrect => String::from("incorrect"), + } + } } impl Default for AuthCompleteStatus { - fn default() -> AuthCompleteStatus { - Self::SwitchIdentity - } + fn default() -> AuthCompleteStatus { + Self::SwitchIdentity + } } + + + + diff --git a/sdks/full/rust/src/models/auth_identity_complete_email_verification_request.rs b/sdks/full/rust/src/models/auth_identity_complete_email_verification_request.rs index eb650fc87a..5fb77a7dd3 100644 --- a/sdks/full/rust/src/models/auth_identity_complete_email_verification_request.rs +++ b/sdks/full/rust/src/models/auth_identity_complete_email_verification_request.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthIdentityCompleteEmailVerificationRequest { - /// The code sent to the requestee's email. - #[serde(rename = "code")] - pub code: String, - #[serde(rename = "verification_id")] - pub verification_id: uuid::Uuid, + /// The code sent to the requestee's email. + #[serde(rename = "code")] + pub code: String, + #[serde(rename = "verification_id")] + pub verification_id: uuid::Uuid, } impl AuthIdentityCompleteEmailVerificationRequest { - pub fn new( - code: String, - verification_id: uuid::Uuid, - ) -> AuthIdentityCompleteEmailVerificationRequest { - AuthIdentityCompleteEmailVerificationRequest { - code, - verification_id, - } - } + pub fn new(code: String, verification_id: uuid::Uuid) -> AuthIdentityCompleteEmailVerificationRequest { + AuthIdentityCompleteEmailVerificationRequest { + code, + verification_id, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_identity_complete_email_verification_response.rs b/sdks/full/rust/src/models/auth_identity_complete_email_verification_response.rs index 0a7176f4b0..557811bb75 100644 --- a/sdks/full/rust/src/models/auth_identity_complete_email_verification_response.rs +++ b/sdks/full/rust/src/models/auth_identity_complete_email_verification_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthIdentityCompleteEmailVerificationResponse { - #[serde(rename = "status")] - pub status: crate::models::AuthCompleteStatus, + #[serde(rename = "status")] + pub status: crate::models::AuthCompleteStatus, } impl AuthIdentityCompleteEmailVerificationResponse { - pub fn new( - status: crate::models::AuthCompleteStatus, - ) -> AuthIdentityCompleteEmailVerificationResponse { - AuthIdentityCompleteEmailVerificationResponse { status } - } + pub fn new(status: crate::models::AuthCompleteStatus) -> AuthIdentityCompleteEmailVerificationResponse { + AuthIdentityCompleteEmailVerificationResponse { + status, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_identity_start_email_verification_request.rs b/sdks/full/rust/src/models/auth_identity_start_email_verification_request.rs index 3f9a2cdc91..d11fbea291 100644 --- a/sdks/full/rust/src/models/auth_identity_start_email_verification_request.rs +++ b/sdks/full/rust/src/models/auth_identity_start_email_verification_request.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthIdentityStartEmailVerificationRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "email")] - pub email: String, - #[serde(rename = "game_id", skip_serializing_if = "Option::is_none")] - pub game_id: Option, + #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] + pub captcha: Option>, + #[serde(rename = "email")] + pub email: String, + #[serde(rename = "game_id", skip_serializing_if = "Option::is_none")] + pub game_id: Option, } impl AuthIdentityStartEmailVerificationRequest { - pub fn new(email: String) -> AuthIdentityStartEmailVerificationRequest { - AuthIdentityStartEmailVerificationRequest { - captcha: None, - email, - game_id: None, - } - } + pub fn new(email: String) -> AuthIdentityStartEmailVerificationRequest { + AuthIdentityStartEmailVerificationRequest { + captcha: None, + email, + game_id: None, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_identity_start_email_verification_response.rs b/sdks/full/rust/src/models/auth_identity_start_email_verification_response.rs index a071908725..78533e77b2 100644 --- a/sdks/full/rust/src/models/auth_identity_start_email_verification_response.rs +++ b/sdks/full/rust/src/models/auth_identity_start_email_verification_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthIdentityStartEmailVerificationResponse { - #[serde(rename = "verification_id")] - pub verification_id: uuid::Uuid, + #[serde(rename = "verification_id")] + pub verification_id: uuid::Uuid, } impl AuthIdentityStartEmailVerificationResponse { - pub fn new(verification_id: uuid::Uuid) -> AuthIdentityStartEmailVerificationResponse { - AuthIdentityStartEmailVerificationResponse { verification_id } - } + pub fn new(verification_id: uuid::Uuid) -> AuthIdentityStartEmailVerificationResponse { + AuthIdentityStartEmailVerificationResponse { + verification_id, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_refresh_identity_token_request.rs b/sdks/full/rust/src/models/auth_refresh_identity_token_request.rs index 3312ac7ea8..bfaf83a1f3 100644 --- a/sdks/full/rust/src/models/auth_refresh_identity_token_request.rs +++ b/sdks/full/rust/src/models/auth_refresh_identity_token_request.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthRefreshIdentityTokenRequest { - /// When `true`, the current identity for the provided cookie will be logged out and a new identity will be returned. - #[serde(rename = "logout", skip_serializing_if = "Option::is_none")] - pub logout: Option, + /// When `true`, the current identity for the provided cookie will be logged out and a new identity will be returned. + #[serde(rename = "logout", skip_serializing_if = "Option::is_none")] + pub logout: Option, } impl AuthRefreshIdentityTokenRequest { - pub fn new() -> AuthRefreshIdentityTokenRequest { - AuthRefreshIdentityTokenRequest { logout: None } - } + pub fn new() -> AuthRefreshIdentityTokenRequest { + AuthRefreshIdentityTokenRequest { + logout: None, + } + } } + + diff --git a/sdks/full/rust/src/models/auth_refresh_identity_token_response.rs b/sdks/full/rust/src/models/auth_refresh_identity_token_response.rs index e83886c5f0..04fc595d97 100644 --- a/sdks/full/rust/src/models/auth_refresh_identity_token_response.rs +++ b/sdks/full/rust/src/models/auth_refresh_identity_token_response.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AuthRefreshIdentityTokenResponse { - /// Token expiration time (in milliseconds). - #[serde(rename = "exp")] - pub exp: String, - #[serde(rename = "identity_id")] - pub identity_id: uuid::Uuid, - /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. - #[serde(rename = "token")] - pub token: String, + /// Token expiration time (in milliseconds). + #[serde(rename = "exp")] + pub exp: String, + #[serde(rename = "identity_id")] + pub identity_id: uuid::Uuid, + /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. + #[serde(rename = "token")] + pub token: String, } impl AuthRefreshIdentityTokenResponse { - pub fn new( - exp: String, - identity_id: uuid::Uuid, - token: String, - ) -> AuthRefreshIdentityTokenResponse { - AuthRefreshIdentityTokenResponse { - exp, - identity_id, - token, - } - } + pub fn new(exp: String, identity_id: uuid::Uuid, token: String) -> AuthRefreshIdentityTokenResponse { + AuthRefreshIdentityTokenResponse { + exp, + identity_id, + token, + } + } } + + diff --git a/sdks/full/rust/src/models/captcha_config.rs b/sdks/full/rust/src/models/captcha_config.rs index edbb05f410..d285073ecd 100644 --- a/sdks/full/rust/src/models/captcha_config.rs +++ b/sdks/full/rust/src/models/captcha_config.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CaptchaConfig : Methods to verify a captcha + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CaptchaConfig { - #[serde(rename = "hcaptcha", skip_serializing_if = "Option::is_none")] - pub hcaptcha: Option>, - #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] - pub turnstile: Option>, + #[serde(rename = "hcaptcha", skip_serializing_if = "Option::is_none")] + pub hcaptcha: Option>, + #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] + pub turnstile: Option>, } impl CaptchaConfig { - /// Methods to verify a captcha - pub fn new() -> CaptchaConfig { - CaptchaConfig { - hcaptcha: None, - turnstile: None, - } - } + /// Methods to verify a captcha + pub fn new() -> CaptchaConfig { + CaptchaConfig { + hcaptcha: None, + turnstile: None, + } + } } + + diff --git a/sdks/full/rust/src/models/captcha_config_hcaptcha.rs b/sdks/full/rust/src/models/captcha_config_hcaptcha.rs index f229d0e40f..a342255d1d 100644 --- a/sdks/full/rust/src/models/captcha_config_hcaptcha.rs +++ b/sdks/full/rust/src/models/captcha_config_hcaptcha.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CaptchaConfigHcaptcha : Captcha configuration. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CaptchaConfigHcaptcha { - #[serde(rename = "client_response")] - pub client_response: String, + #[serde(rename = "client_response")] + pub client_response: String, } impl CaptchaConfigHcaptcha { - /// Captcha configuration. - pub fn new(client_response: String) -> CaptchaConfigHcaptcha { - CaptchaConfigHcaptcha { client_response } - } + /// Captcha configuration. + pub fn new(client_response: String) -> CaptchaConfigHcaptcha { + CaptchaConfigHcaptcha { + client_response, + } + } } + + diff --git a/sdks/full/rust/src/models/captcha_config_turnstile.rs b/sdks/full/rust/src/models/captcha_config_turnstile.rs index 2c464d4433..ca74d127c0 100644 --- a/sdks/full/rust/src/models/captcha_config_turnstile.rs +++ b/sdks/full/rust/src/models/captcha_config_turnstile.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CaptchaConfigTurnstile : Captcha configuration. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CaptchaConfigTurnstile { - #[serde(rename = "client_response")] - pub client_response: String, + #[serde(rename = "client_response")] + pub client_response: String, } impl CaptchaConfigTurnstile { - /// Captcha configuration. - pub fn new(client_response: String) -> CaptchaConfigTurnstile { - CaptchaConfigTurnstile { client_response } - } + /// Captcha configuration. + pub fn new(client_response: String) -> CaptchaConfigTurnstile { + CaptchaConfigTurnstile { + client_response, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_auth_agent.rs b/sdks/full/rust/src/models/cloud_auth_agent.rs index d48a3aaa51..5ab694c6ad 100644 --- a/sdks/full/rust/src/models/cloud_auth_agent.rs +++ b/sdks/full/rust/src/models/cloud_auth_agent.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudAuthAgent : The current authenticated agent. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudAuthAgent { - #[serde(rename = "game_cloud", skip_serializing_if = "Option::is_none")] - pub game_cloud: Option>, - #[serde(rename = "identity", skip_serializing_if = "Option::is_none")] - pub identity: Option>, + #[serde(rename = "game_cloud", skip_serializing_if = "Option::is_none")] + pub game_cloud: Option>, + #[serde(rename = "identity", skip_serializing_if = "Option::is_none")] + pub identity: Option>, } impl CloudAuthAgent { - /// The current authenticated agent. - pub fn new() -> CloudAuthAgent { - CloudAuthAgent { - game_cloud: None, - identity: None, - } - } + /// The current authenticated agent. + pub fn new() -> CloudAuthAgent { + CloudAuthAgent { + game_cloud: None, + identity: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_auth_agent_game_cloud.rs b/sdks/full/rust/src/models/cloud_auth_agent_game_cloud.rs index 29859b7b3f..4698420b34 100644 --- a/sdks/full/rust/src/models/cloud_auth_agent_game_cloud.rs +++ b/sdks/full/rust/src/models/cloud_auth_agent_game_cloud.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudAuthAgentGameCloud : The current authenticated game cloud. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudAuthAgentGameCloud { - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, } impl CloudAuthAgentGameCloud { - /// The current authenticated game cloud. - pub fn new(game_id: uuid::Uuid) -> CloudAuthAgentGameCloud { - CloudAuthAgentGameCloud { game_id } - } + /// The current authenticated game cloud. + pub fn new(game_id: uuid::Uuid) -> CloudAuthAgentGameCloud { + CloudAuthAgentGameCloud { + game_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_auth_agent_identity.rs b/sdks/full/rust/src/models/cloud_auth_agent_identity.rs index 799fe9ea84..38dff8d0ec 100644 --- a/sdks/full/rust/src/models/cloud_auth_agent_identity.rs +++ b/sdks/full/rust/src/models/cloud_auth_agent_identity.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudAuthAgentIdentity : The current authenticated identity. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudAuthAgentIdentity { - #[serde(rename = "identity_id")] - pub identity_id: uuid::Uuid, + #[serde(rename = "identity_id")] + pub identity_id: uuid::Uuid, } impl CloudAuthAgentIdentity { - /// The current authenticated identity. - pub fn new(identity_id: uuid::Uuid) -> CloudAuthAgentIdentity { - CloudAuthAgentIdentity { identity_id } - } + /// The current authenticated identity. + pub fn new(identity_id: uuid::Uuid) -> CloudAuthAgentIdentity { + CloudAuthAgentIdentity { + identity_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_access.rs b/sdks/full/rust/src/models/cloud_bootstrap_access.rs index 6d5441c30e..30ad6842f2 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_access.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_access.rs @@ -4,33 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudBootstrapAccess { - #[serde(rename = "public")] - Public, - #[serde(rename = "private")] - Private, - #[serde(rename = "development")] - Development, + #[serde(rename = "public")] + Public, + #[serde(rename = "private")] + Private, + #[serde(rename = "development")] + Development, + } impl ToString for CloudBootstrapAccess { - fn to_string(&self) -> String { - match self { - Self::Public => String::from("public"), - Self::Private => String::from("private"), - Self::Development => String::from("development"), - } - } + fn to_string(&self) -> String { + match self { + Self::Public => String::from("public"), + Self::Private => String::from("private"), + Self::Development => String::from("development"), + } + } } impl Default for CloudBootstrapAccess { - fn default() -> CloudBootstrapAccess { - Self::Public - } + fn default() -> CloudBootstrapAccess { + Self::Public + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_captcha.rs b/sdks/full/rust/src/models/cloud_bootstrap_captcha.rs index af623c7661..9f83ccbc73 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_captcha.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_captcha.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapCaptcha { - #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] - pub turnstile: Option>, + #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] + pub turnstile: Option>, } impl CloudBootstrapCaptcha { - pub fn new() -> CloudBootstrapCaptcha { - CloudBootstrapCaptcha { turnstile: None } - } + pub fn new() -> CloudBootstrapCaptcha { + CloudBootstrapCaptcha { + turnstile: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_captcha_turnstile.rs b/sdks/full/rust/src/models/cloud_bootstrap_captcha_turnstile.rs index 04daf43ea0..4e326bb691 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_captcha_turnstile.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_captcha_turnstile.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapCaptchaTurnstile { - #[serde(rename = "site_key")] - pub site_key: String, + #[serde(rename = "site_key")] + pub site_key: String, } impl CloudBootstrapCaptchaTurnstile { - pub fn new(site_key: String) -> CloudBootstrapCaptchaTurnstile { - CloudBootstrapCaptchaTurnstile { site_key } - } + pub fn new(site_key: String) -> CloudBootstrapCaptchaTurnstile { + CloudBootstrapCaptchaTurnstile { + site_key, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_cluster.rs b/sdks/full/rust/src/models/cloud_bootstrap_cluster.rs index 103fbe8182..3152f22de5 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_cluster.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_cluster.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// The type of cluster that the backend is currently running. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudBootstrapCluster { - #[serde(rename = "enterprise")] - Enterprise, - #[serde(rename = "oss")] - Oss, + #[serde(rename = "enterprise")] + Enterprise, + #[serde(rename = "oss")] + Oss, + } impl ToString for CloudBootstrapCluster { - fn to_string(&self) -> String { - match self { - Self::Enterprise => String::from("enterprise"), - Self::Oss => String::from("oss"), - } - } + fn to_string(&self) -> String { + match self { + Self::Enterprise => String::from("enterprise"), + Self::Oss => String::from("oss"), + } + } } impl Default for CloudBootstrapCluster { - fn default() -> CloudBootstrapCluster { - Self::Enterprise - } + fn default() -> CloudBootstrapCluster { + Self::Enterprise + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_domains.rs b/sdks/full/rust/src/models/cloud_bootstrap_domains.rs index 79f31cd630..1ba4c25ae0 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_domains.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_domains.rs @@ -4,29 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudBootstrapDomains : Domains that host parts of Rivet + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapDomains { - #[serde(rename = "cdn", skip_serializing_if = "Option::is_none")] - pub cdn: Option, - #[serde(rename = "job", skip_serializing_if = "Option::is_none")] - pub job: Option, - #[serde(rename = "opengb", skip_serializing_if = "Option::is_none")] - pub opengb: Option, + #[serde(rename = "cdn", skip_serializing_if = "Option::is_none")] + pub cdn: Option, + #[serde(rename = "job", skip_serializing_if = "Option::is_none")] + pub job: Option, + #[serde(rename = "opengb", skip_serializing_if = "Option::is_none")] + pub opengb: Option, } impl CloudBootstrapDomains { - /// Domains that host parts of Rivet - pub fn new() -> CloudBootstrapDomains { - CloudBootstrapDomains { - cdn: None, - job: None, - opengb: None, - } - } + /// Domains that host parts of Rivet + pub fn new() -> CloudBootstrapDomains { + CloudBootstrapDomains { + cdn: None, + job: None, + opengb: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_login_methods.rs b/sdks/full/rust/src/models/cloud_bootstrap_login_methods.rs index 72a6bb5291..f643f7fb3f 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_login_methods.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_login_methods.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapLoginMethods { - #[serde(rename = "email")] - pub email: bool, + #[serde(rename = "email")] + pub email: bool, } impl CloudBootstrapLoginMethods { - pub fn new(email: bool) -> CloudBootstrapLoginMethods { - CloudBootstrapLoginMethods { email } - } + pub fn new(email: bool) -> CloudBootstrapLoginMethods { + CloudBootstrapLoginMethods { + email, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_origins.rs b/sdks/full/rust/src/models/cloud_bootstrap_origins.rs index f50a31c39c..4a26422571 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_origins.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_origins.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudBootstrapOrigins : Origins used to build URLs from + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapOrigins { - #[serde(rename = "hub")] - pub hub: String, + #[serde(rename = "hub")] + pub hub: String, } impl CloudBootstrapOrigins { - /// Origins used to build URLs from - pub fn new(hub: String) -> CloudBootstrapOrigins { - CloudBootstrapOrigins { hub } - } + /// Origins used to build URLs from + pub fn new(hub: String) -> CloudBootstrapOrigins { + CloudBootstrapOrigins { + hub, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_bootstrap_response.rs b/sdks/full/rust/src/models/cloud_bootstrap_response.rs index b4848ed6c9..a0a2c78897 100644 --- a/sdks/full/rust/src/models/cloud_bootstrap_response.rs +++ b/sdks/full/rust/src/models/cloud_bootstrap_response.rs @@ -4,46 +4,43 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBootstrapResponse { - #[serde(rename = "access")] - pub access: crate::models::CloudBootstrapAccess, - #[serde(rename = "captcha")] - pub captcha: Box, - #[serde(rename = "cluster")] - pub cluster: crate::models::CloudBootstrapCluster, - #[serde(rename = "deploy_hash")] - pub deploy_hash: String, - #[serde(rename = "domains")] - pub domains: Box, - #[serde(rename = "login_methods")] - pub login_methods: Box, - #[serde(rename = "origins")] - pub origins: Box, + #[serde(rename = "access")] + pub access: crate::models::CloudBootstrapAccess, + #[serde(rename = "captcha")] + pub captcha: Box, + #[serde(rename = "cluster")] + pub cluster: crate::models::CloudBootstrapCluster, + #[serde(rename = "deploy_hash")] + pub deploy_hash: String, + #[serde(rename = "domains")] + pub domains: Box, + #[serde(rename = "login_methods")] + pub login_methods: Box, + #[serde(rename = "origins")] + pub origins: Box, } impl CloudBootstrapResponse { - pub fn new( - access: crate::models::CloudBootstrapAccess, - captcha: crate::models::CloudBootstrapCaptcha, - cluster: crate::models::CloudBootstrapCluster, - deploy_hash: String, - domains: crate::models::CloudBootstrapDomains, - login_methods: crate::models::CloudBootstrapLoginMethods, - origins: crate::models::CloudBootstrapOrigins, - ) -> CloudBootstrapResponse { - CloudBootstrapResponse { - access, - captcha: Box::new(captcha), - cluster, - deploy_hash, - domains: Box::new(domains), - login_methods: Box::new(login_methods), - origins: Box::new(origins), - } - } + pub fn new(access: crate::models::CloudBootstrapAccess, captcha: crate::models::CloudBootstrapCaptcha, cluster: crate::models::CloudBootstrapCluster, deploy_hash: String, domains: crate::models::CloudBootstrapDomains, login_methods: crate::models::CloudBootstrapLoginMethods, origins: crate::models::CloudBootstrapOrigins) -> CloudBootstrapResponse { + CloudBootstrapResponse { + access, + captcha: Box::new(captcha), + cluster, + deploy_hash, + domains: Box::new(domains), + login_methods: Box::new(login_methods), + origins: Box::new(origins), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_build_summary.rs b/sdks/full/rust/src/models/cloud_build_summary.rs index da48359dfe..2191748cf3 100644 --- a/sdks/full/rust/src/models/cloud_build_summary.rs +++ b/sdks/full/rust/src/models/cloud_build_summary.rs @@ -4,54 +4,50 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudBuildSummary : A build summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudBuildSummary { - #[serde(rename = "build_id")] - pub build_id: uuid::Uuid, - /// Whether or not this build has completely been uploaded. - #[serde(rename = "complete")] - pub complete: bool, - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// Tags of this build - #[serde(rename = "tags")] - pub tags: ::std::collections::HashMap, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "build_id")] + pub build_id: uuid::Uuid, + /// Whether or not this build has completely been uploaded. + #[serde(rename = "complete")] + pub complete: bool, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// Tags of this build + #[serde(rename = "tags")] + pub tags: ::std::collections::HashMap, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudBuildSummary { - /// A build summary. - pub fn new( - build_id: uuid::Uuid, - complete: bool, - content_length: i64, - create_ts: String, - display_name: String, - tags: ::std::collections::HashMap, - upload_id: uuid::Uuid, - ) -> CloudBuildSummary { - CloudBuildSummary { - build_id, - complete, - content_length, - create_ts, - display_name, - tags, - upload_id, - } - } + /// A build summary. + pub fn new(build_id: uuid::Uuid, complete: bool, content_length: i64, create_ts: String, display_name: String, tags: ::std::collections::HashMap, upload_id: uuid::Uuid) -> CloudBuildSummary { + CloudBuildSummary { + build_id, + complete, + content_length, + create_ts, + display_name, + tags, + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_auth_type.rs b/sdks/full/rust/src/models/cloud_cdn_auth_type.rs index 8175735bf6..bd9b926551 100644 --- a/sdks/full/rust/src/models/cloud_cdn_auth_type.rs +++ b/sdks/full/rust/src/models/cloud_cdn_auth_type.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// A value denoting what type of authentication to use for a game namespace's CDN. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudCdnAuthType { - #[serde(rename = "none")] - None, - #[serde(rename = "basic")] - Basic, + #[serde(rename = "none")] + None, + #[serde(rename = "basic")] + Basic, + } impl ToString for CloudCdnAuthType { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::Basic => String::from("basic"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::Basic => String::from("basic"), + } + } } impl Default for CloudCdnAuthType { - fn default() -> CloudCdnAuthType { - Self::None - } + fn default() -> CloudCdnAuthType { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_auth_user.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_auth_user.rs index a39ab114b4..21b67ffac2 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_auth_user.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_auth_user.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCdnNamespaceAuthUser : An authenticated CDN user for a given namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnNamespaceAuthUser { - /// A user name. - #[serde(rename = "user")] - pub user: String, + /// A user name. + #[serde(rename = "user")] + pub user: String, } impl CloudCdnNamespaceAuthUser { - /// An authenticated CDN user for a given namespace. - pub fn new(user: String) -> CloudCdnNamespaceAuthUser { - CloudCdnNamespaceAuthUser { user } - } + /// An authenticated CDN user for a given namespace. + pub fn new(user: String) -> CloudCdnNamespaceAuthUser { + CloudCdnNamespaceAuthUser { + user, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_config.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_config.rs index f5908c3393..438f4a8cc3 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_config.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_config.rs @@ -4,40 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCdnNamespaceConfig : CDN configuration for a given namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnNamespaceConfig { - #[serde(rename = "auth_type")] - pub auth_type: crate::models::CloudCdnAuthType, - /// A list of CDN authenticated users for a given namespace. - #[serde(rename = "auth_user_list")] - pub auth_user_list: Vec, - /// A list of CDN domains for a given namespace. - #[serde(rename = "domains")] - pub domains: Vec, - /// Whether or not to allow users to connect to the given namespace via domain name. - #[serde(rename = "enable_domain_public_auth")] - pub enable_domain_public_auth: bool, + #[serde(rename = "auth_type")] + pub auth_type: crate::models::CloudCdnAuthType, + /// A list of CDN authenticated users for a given namespace. + #[serde(rename = "auth_user_list")] + pub auth_user_list: Vec, + /// A list of CDN domains for a given namespace. + #[serde(rename = "domains")] + pub domains: Vec, + /// Whether or not to allow users to connect to the given namespace via domain name. + #[serde(rename = "enable_domain_public_auth")] + pub enable_domain_public_auth: bool, } impl CloudCdnNamespaceConfig { - /// CDN configuration for a given namespace. - pub fn new( - auth_type: crate::models::CloudCdnAuthType, - auth_user_list: Vec, - domains: Vec, - enable_domain_public_auth: bool, - ) -> CloudCdnNamespaceConfig { - CloudCdnNamespaceConfig { - auth_type, - auth_user_list, - domains, - enable_domain_public_auth, - } - } + /// CDN configuration for a given namespace. + pub fn new(auth_type: crate::models::CloudCdnAuthType, auth_user_list: Vec, domains: Vec, enable_domain_public_auth: bool) -> CloudCdnNamespaceConfig { + CloudCdnNamespaceConfig { + auth_type, + auth_user_list, + domains, + enable_domain_public_auth, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_domain.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_domain.rs index f19b425709..db81a282e7 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_domain.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_domain.rs @@ -4,43 +4,41 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCdnNamespaceDomain : A CDN domain for a given namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnNamespaceDomain { - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// A valid domain name (no protocol). - #[serde(rename = "domain")] - pub domain: String, - #[serde(rename = "verification_errors")] - pub verification_errors: Vec, - #[serde(rename = "verification_method")] - pub verification_method: Box, - #[serde(rename = "verification_status")] - pub verification_status: crate::models::CloudCdnNamespaceDomainVerificationStatus, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// A valid domain name (no protocol). + #[serde(rename = "domain")] + pub domain: String, + #[serde(rename = "verification_errors")] + pub verification_errors: Vec, + #[serde(rename = "verification_method")] + pub verification_method: Box, + #[serde(rename = "verification_status")] + pub verification_status: crate::models::CloudCdnNamespaceDomainVerificationStatus, } impl CloudCdnNamespaceDomain { - /// A CDN domain for a given namespace. - pub fn new( - create_ts: String, - domain: String, - verification_errors: Vec, - verification_method: crate::models::CloudCdnNamespaceDomainVerificationMethod, - verification_status: crate::models::CloudCdnNamespaceDomainVerificationStatus, - ) -> CloudCdnNamespaceDomain { - CloudCdnNamespaceDomain { - create_ts, - domain, - verification_errors, - verification_method: Box::new(verification_method), - verification_status, - } - } + /// A CDN domain for a given namespace. + pub fn new(create_ts: String, domain: String, verification_errors: Vec, verification_method: crate::models::CloudCdnNamespaceDomainVerificationMethod, verification_status: crate::models::CloudCdnNamespaceDomainVerificationStatus) -> CloudCdnNamespaceDomain { + CloudCdnNamespaceDomain { + create_ts, + domain, + verification_errors, + verification_method: Box::new(verification_method), + verification_status, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method.rs index 0d2b113286..b6dfced487 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCdnNamespaceDomainVerificationMethod : A union representing the verification method used for this CDN domain. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnNamespaceDomainVerificationMethod { - #[serde(rename = "http", skip_serializing_if = "Option::is_none")] - pub http: Option>, - #[serde(rename = "invalid", skip_serializing_if = "Option::is_none")] - pub invalid: Option, + #[serde(rename = "http", skip_serializing_if = "Option::is_none")] + pub http: Option>, + #[serde(rename = "invalid", skip_serializing_if = "Option::is_none")] + pub invalid: Option, } impl CloudCdnNamespaceDomainVerificationMethod { - /// A union representing the verification method used for this CDN domain. - pub fn new() -> CloudCdnNamespaceDomainVerificationMethod { - CloudCdnNamespaceDomainVerificationMethod { - http: None, - invalid: None, - } - } + /// A union representing the verification method used for this CDN domain. + pub fn new() -> CloudCdnNamespaceDomainVerificationMethod { + CloudCdnNamespaceDomainVerificationMethod { + http: None, + invalid: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method_http.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method_http.rs index 748a818f3d..2e382e2dea 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method_http.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_method_http.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnNamespaceDomainVerificationMethodHttp { - #[serde(rename = "cname_record")] - pub cname_record: String, + #[serde(rename = "cname_record")] + pub cname_record: String, } impl CloudCdnNamespaceDomainVerificationMethodHttp { - pub fn new(cname_record: String) -> CloudCdnNamespaceDomainVerificationMethodHttp { - CloudCdnNamespaceDomainVerificationMethodHttp { cname_record } - } + pub fn new(cname_record: String) -> CloudCdnNamespaceDomainVerificationMethodHttp { + CloudCdnNamespaceDomainVerificationMethodHttp { + cname_record, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_status.rs b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_status.rs index e99b8fec85..c76e43bf9a 100644 --- a/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_status.rs +++ b/sdks/full/rust/src/models/cloud_cdn_namespace_domain_verification_status.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,26 +13,31 @@ /// A value denoting the status of a CDN domain's verification status. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudCdnNamespaceDomainVerificationStatus { - #[serde(rename = "active")] - Active, - #[serde(rename = "pending")] - Pending, - #[serde(rename = "failed")] - Failed, + #[serde(rename = "active")] + Active, + #[serde(rename = "pending")] + Pending, + #[serde(rename = "failed")] + Failed, + } impl ToString for CloudCdnNamespaceDomainVerificationStatus { - fn to_string(&self) -> String { - match self { - Self::Active => String::from("active"), - Self::Pending => String::from("pending"), - Self::Failed => String::from("failed"), - } - } + fn to_string(&self) -> String { + match self { + Self::Active => String::from("active"), + Self::Pending => String::from("pending"), + Self::Failed => String::from("failed"), + } + } } impl Default for CloudCdnNamespaceDomainVerificationStatus { - fn default() -> CloudCdnNamespaceDomainVerificationStatus { - Self::Active - } + fn default() -> CloudCdnNamespaceDomainVerificationStatus { + Self::Active + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_cdn_site_summary.rs b/sdks/full/rust/src/models/cloud_cdn_site_summary.rs index c1f81da4f4..15f0418c57 100644 --- a/sdks/full/rust/src/models/cloud_cdn_site_summary.rs +++ b/sdks/full/rust/src/models/cloud_cdn_site_summary.rs @@ -4,49 +4,46 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCdnSiteSummary : A CDN site summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCdnSiteSummary { - /// Whether or not this site has completely been uploaded. - #[serde(rename = "complete")] - pub complete: bool, - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "site_id")] - pub site_id: uuid::Uuid, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + /// Whether or not this site has completely been uploaded. + #[serde(rename = "complete")] + pub complete: bool, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "site_id")] + pub site_id: uuid::Uuid, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudCdnSiteSummary { - /// A CDN site summary. - pub fn new( - complete: bool, - content_length: i64, - create_ts: String, - display_name: String, - site_id: uuid::Uuid, - upload_id: uuid::Uuid, - ) -> CloudCdnSiteSummary { - CloudCdnSiteSummary { - complete, - content_length, - create_ts, - display_name, - site_id, - upload_id, - } - } + /// A CDN site summary. + pub fn new(complete: bool, content_length: i64, create_ts: String, display_name: String, site_id: uuid::Uuid, upload_id: uuid::Uuid) -> CloudCdnSiteSummary { + CloudCdnSiteSummary { + complete, + content_length, + create_ts, + display_name, + site_id, + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_custom_avatar_summary.rs b/sdks/full/rust/src/models/cloud_custom_avatar_summary.rs index ae427a4833..e3716280da 100644 --- a/sdks/full/rust/src/models/cloud_custom_avatar_summary.rs +++ b/sdks/full/rust/src/models/cloud_custom_avatar_summary.rs @@ -4,49 +4,47 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudCustomAvatarSummary : A custom avatar summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudCustomAvatarSummary { - /// Whether or not this custom avatar has completely been uploaded. - #[serde(rename = "complete")] - pub complete: bool, - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, - /// The URL of this custom avatar image. Only present if upload is complete. - #[serde(rename = "url", skip_serializing_if = "Option::is_none")] - pub url: Option, + /// Whether or not this custom avatar has completely been uploaded. + #[serde(rename = "complete")] + pub complete: bool, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, + /// The URL of this custom avatar image. Only present if upload is complete. + #[serde(rename = "url", skip_serializing_if = "Option::is_none")] + pub url: Option, } impl CloudCustomAvatarSummary { - /// A custom avatar summary. - pub fn new( - complete: bool, - content_length: i64, - create_ts: String, - display_name: String, - upload_id: uuid::Uuid, - ) -> CloudCustomAvatarSummary { - CloudCustomAvatarSummary { - complete, - content_length, - create_ts, - display_name, - upload_id, - url: None, - } - } + /// A custom avatar summary. + pub fn new(complete: bool, content_length: i64, create_ts: String, display_name: String, upload_id: uuid::Uuid) -> CloudCustomAvatarSummary { + CloudCustomAvatarSummary { + complete, + content_length, + create_ts, + display_name, + upload_id, + url: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_devices_complete_device_link_request.rs b/sdks/full/rust/src/models/cloud_devices_complete_device_link_request.rs index 9d9567e981..be88fe67ec 100644 --- a/sdks/full/rust/src/models/cloud_devices_complete_device_link_request.rs +++ b/sdks/full/rust/src/models/cloud_devices_complete_device_link_request.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudDevicesCompleteDeviceLinkRequest { - /// Documentation at https://jwt.io/ - #[serde(rename = "device_link_token")] - pub device_link_token: String, - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, + /// Documentation at https://jwt.io/ + #[serde(rename = "device_link_token")] + pub device_link_token: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, } impl CloudDevicesCompleteDeviceLinkRequest { - pub fn new( - device_link_token: String, - game_id: uuid::Uuid, - ) -> CloudDevicesCompleteDeviceLinkRequest { - CloudDevicesCompleteDeviceLinkRequest { - device_link_token, - game_id, - } - } + pub fn new(device_link_token: String, game_id: uuid::Uuid) -> CloudDevicesCompleteDeviceLinkRequest { + CloudDevicesCompleteDeviceLinkRequest { + device_link_token, + game_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_devices_get_device_link_response.rs b/sdks/full/rust/src/models/cloud_devices_get_device_link_response.rs index ed0dd748b0..38a1f79d55 100644 --- a/sdks/full/rust/src/models/cloud_devices_get_device_link_response.rs +++ b/sdks/full/rust/src/models/cloud_devices_get_device_link_response.rs @@ -4,23 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudDevicesGetDeviceLinkResponse { - #[serde(rename = "cloud_token", skip_serializing_if = "Option::is_none")] - pub cloud_token: Option, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "cloud_token", skip_serializing_if = "Option::is_none")] + pub cloud_token: Option, + #[serde(rename = "watch")] + pub watch: Box, } impl CloudDevicesGetDeviceLinkResponse { - pub fn new(watch: crate::models::WatchResponse) -> CloudDevicesGetDeviceLinkResponse { - CloudDevicesGetDeviceLinkResponse { - cloud_token: None, - watch: Box::new(watch), - } - } + pub fn new(watch: crate::models::WatchResponse) -> CloudDevicesGetDeviceLinkResponse { + CloudDevicesGetDeviceLinkResponse { + cloud_token: None, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_devices_prepare_device_link_response.rs b/sdks/full/rust/src/models/cloud_devices_prepare_device_link_response.rs index 3615140d36..3e33ef2133 100644 --- a/sdks/full/rust/src/models/cloud_devices_prepare_device_link_response.rs +++ b/sdks/full/rust/src/models/cloud_devices_prepare_device_link_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudDevicesPrepareDeviceLinkResponse { - #[serde(rename = "device_link_id")] - pub device_link_id: uuid::Uuid, - #[serde(rename = "device_link_token")] - pub device_link_token: String, - #[serde(rename = "device_link_url")] - pub device_link_url: String, + #[serde(rename = "device_link_id")] + pub device_link_id: uuid::Uuid, + #[serde(rename = "device_link_token")] + pub device_link_token: String, + #[serde(rename = "device_link_url")] + pub device_link_url: String, } impl CloudDevicesPrepareDeviceLinkResponse { - pub fn new( - device_link_id: uuid::Uuid, - device_link_token: String, - device_link_url: String, - ) -> CloudDevicesPrepareDeviceLinkResponse { - CloudDevicesPrepareDeviceLinkResponse { - device_link_id, - device_link_token, - device_link_url, - } - } + pub fn new(device_link_id: uuid::Uuid, device_link_token: String, device_link_url: String) -> CloudDevicesPrepareDeviceLinkResponse { + CloudDevicesPrepareDeviceLinkResponse { + device_link_id, + device_link_token, + device_link_url, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_game_full.rs b/sdks/full/rust/src/models/cloud_game_full.rs index 7b58a6a1eb..a4ffd17835 100644 --- a/sdks/full/rust/src/models/cloud_game_full.rs +++ b/sdks/full/rust/src/models/cloud_game_full.rs @@ -4,72 +4,66 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudGameFull : A full game. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGameFull { - /// A list of region summaries. - #[serde(rename = "available_regions")] - pub available_regions: Vec, - /// The URL of this game's banner image. - #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] - pub banner_url: Option, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - #[serde(rename = "developer_group_id")] - pub developer_group_id: uuid::Uuid, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, - /// The URL of this game's logo image. - #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] - pub logo_url: Option, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - /// A list of namespace summaries. - #[serde(rename = "namespaces")] - pub namespaces: Vec, - /// Unsigned 32 bit integer. - #[serde(rename = "total_player_count")] - pub total_player_count: i32, - /// A list of version summaries. - #[serde(rename = "versions")] - pub versions: Vec, + /// A list of region summaries. + #[serde(rename = "available_regions")] + pub available_regions: Vec, + /// The URL of this game's banner image. + #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] + pub banner_url: Option, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + #[serde(rename = "developer_group_id")] + pub developer_group_id: uuid::Uuid, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, + /// The URL of this game's logo image. + #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] + pub logo_url: Option, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + /// A list of namespace summaries. + #[serde(rename = "namespaces")] + pub namespaces: Vec, + /// Unsigned 32 bit integer. + #[serde(rename = "total_player_count")] + pub total_player_count: i32, + /// A list of version summaries. + #[serde(rename = "versions")] + pub versions: Vec, } impl CloudGameFull { - /// A full game. - pub fn new( - available_regions: Vec, - create_ts: String, - developer_group_id: uuid::Uuid, - display_name: String, - game_id: uuid::Uuid, - name_id: String, - namespaces: Vec, - total_player_count: i32, - versions: Vec, - ) -> CloudGameFull { - CloudGameFull { - available_regions, - banner_url: None, - create_ts, - developer_group_id, - display_name, - game_id, - logo_url: None, - name_id, - namespaces, - total_player_count, - versions, - } - } + /// A full game. + pub fn new(available_regions: Vec, create_ts: String, developer_group_id: uuid::Uuid, display_name: String, game_id: uuid::Uuid, name_id: String, namespaces: Vec, total_player_count: i32, versions: Vec) -> CloudGameFull { + CloudGameFull { + available_regions, + banner_url: None, + create_ts, + developer_group_id, + display_name, + game_id, + logo_url: None, + name_id, + namespaces, + total_player_count, + versions, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_game_lobby_expenses.rs b/sdks/full/rust/src/models/cloud_game_lobby_expenses.rs index 0e9213b689..8fd76e7e4e 100644 --- a/sdks/full/rust/src/models/cloud_game_lobby_expenses.rs +++ b/sdks/full/rust/src/models/cloud_game_lobby_expenses.rs @@ -4,35 +4,35 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudGameLobbyExpenses : Game lobby expenses. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGameLobbyExpenses { - /// A list of multiple region tier expenses. - #[serde(rename = "expenses")] - pub expenses: Vec, - #[serde(rename = "game")] - pub game: Box, - /// A list of namespace summaries. - #[serde(rename = "namespaces")] - pub namespaces: Vec, + /// A list of multiple region tier expenses. + #[serde(rename = "expenses")] + pub expenses: Vec, + #[serde(rename = "game")] + pub game: Box, + /// A list of namespace summaries. + #[serde(rename = "namespaces")] + pub namespaces: Vec, } impl CloudGameLobbyExpenses { - /// Game lobby expenses. - pub fn new( - expenses: Vec, - game: crate::models::GameHandle, - namespaces: Vec, - ) -> CloudGameLobbyExpenses { - CloudGameLobbyExpenses { - expenses, - game: Box::new(game), - namespaces, - } - } + /// Game lobby expenses. + pub fn new(expenses: Vec, game: crate::models::GameHandle, namespaces: Vec) -> CloudGameLobbyExpenses { + CloudGameLobbyExpenses { + expenses, + game: Box::new(game), + namespaces, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_build_compression.rs b/sdks/full/rust/src/models/cloud_games_build_compression.rs index 9cf09b955b..9980cc9cb9 100644 --- a/sdks/full/rust/src/models/cloud_games_build_compression.rs +++ b/sdks/full/rust/src/models/cloud_games_build_compression.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudGamesBuildCompression { - #[serde(rename = "none")] - None, - #[serde(rename = "lz4")] - Lz4, + #[serde(rename = "none")] + None, + #[serde(rename = "lz4")] + Lz4, + } impl ToString for CloudGamesBuildCompression { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::Lz4 => String::from("lz4"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::Lz4 => String::from("lz4"), + } + } } impl Default for CloudGamesBuildCompression { - fn default() -> CloudGamesBuildCompression { - Self::None - } + fn default() -> CloudGamesBuildCompression { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_games_build_kind.rs b/sdks/full/rust/src/models/cloud_games_build_kind.rs index 4afc78adae..892db37414 100644 --- a/sdks/full/rust/src/models/cloud_games_build_kind.rs +++ b/sdks/full/rust/src/models/cloud_games_build_kind.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudGamesBuildKind { - #[serde(rename = "docker_image")] - DockerImage, - #[serde(rename = "oci_bundle")] - OciBundle, + #[serde(rename = "docker_image")] + DockerImage, + #[serde(rename = "oci_bundle")] + OciBundle, + } impl ToString for CloudGamesBuildKind { - fn to_string(&self) -> String { - match self { - Self::DockerImage => String::from("docker_image"), - Self::OciBundle => String::from("oci_bundle"), - } - } + fn to_string(&self) -> String { + match self { + Self::DockerImage => String::from("docker_image"), + Self::OciBundle => String::from("oci_bundle"), + } + } } impl Default for CloudGamesBuildKind { - fn default() -> CloudGamesBuildKind { - Self::DockerImage - } + fn default() -> CloudGamesBuildKind { + Self::DockerImage + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_games_create_cloud_token_response.rs b/sdks/full/rust/src/models/cloud_games_create_cloud_token_response.rs index c9cebaab4e..d6264302b4 100644 --- a/sdks/full/rust/src/models/cloud_games_create_cloud_token_response.rs +++ b/sdks/full/rust/src/models/cloud_games_create_cloud_token_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateCloudTokenResponse { - /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. - #[serde(rename = "token")] - pub token: String, + /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. + #[serde(rename = "token")] + pub token: String, } impl CloudGamesCreateCloudTokenResponse { - pub fn new(token: String) -> CloudGamesCreateCloudTokenResponse { - CloudGamesCreateCloudTokenResponse { token } - } + pub fn new(token: String) -> CloudGamesCreateCloudTokenResponse { + CloudGamesCreateCloudTokenResponse { + token, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_build_request.rs b/sdks/full/rust/src/models/cloud_games_create_game_build_request.rs index 2ebbaed054..b25d286793 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_build_request.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_build_request.rs @@ -4,41 +4,42 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameBuildRequest { - #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] - pub compression: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "image_file")] - pub image_file: Box, - /// A tag given to the game build. - #[serde(rename = "image_tag")] - pub image_tag: String, - #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] - pub kind: Option, - #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] - pub multipart_upload: Option, + #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] + pub compression: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "image_file")] + pub image_file: Box, + /// A tag given to the game build. + #[serde(rename = "image_tag")] + pub image_tag: String, + #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] + pub kind: Option, + #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] + pub multipart_upload: Option, } impl CloudGamesCreateGameBuildRequest { - pub fn new( - display_name: String, - image_file: crate::models::UploadPrepareFile, - image_tag: String, - ) -> CloudGamesCreateGameBuildRequest { - CloudGamesCreateGameBuildRequest { - compression: None, - display_name, - image_file: Box::new(image_file), - image_tag, - kind: None, - multipart_upload: None, - } - } + pub fn new(display_name: String, image_file: crate::models::UploadPrepareFile, image_tag: String) -> CloudGamesCreateGameBuildRequest { + CloudGamesCreateGameBuildRequest { + compression: None, + display_name, + image_file: Box::new(image_file), + image_tag, + kind: None, + multipart_upload: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_build_response.rs b/sdks/full/rust/src/models/cloud_games_create_game_build_response.rs index 607b999323..bf7ed65cca 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_build_response.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_build_response.rs @@ -4,35 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameBuildResponse { - #[serde(rename = "build_id")] - pub build_id: uuid::Uuid, - #[serde( - rename = "image_presigned_request", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_request: Option>, - #[serde( - rename = "image_presigned_requests", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_requests: Option>, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "build_id")] + pub build_id: uuid::Uuid, + #[serde(rename = "image_presigned_request", skip_serializing_if = "Option::is_none")] + pub image_presigned_request: Option>, + #[serde(rename = "image_presigned_requests", skip_serializing_if = "Option::is_none")] + pub image_presigned_requests: Option>, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudGamesCreateGameBuildResponse { - pub fn new(build_id: uuid::Uuid, upload_id: uuid::Uuid) -> CloudGamesCreateGameBuildResponse { - CloudGamesCreateGameBuildResponse { - build_id, - image_presigned_request: None, - image_presigned_requests: None, - upload_id, - } - } + pub fn new(build_id: uuid::Uuid, upload_id: uuid::Uuid) -> CloudGamesCreateGameBuildResponse { + CloudGamesCreateGameBuildResponse { + build_id, + image_presigned_request: None, + image_presigned_requests: None, + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_request.rs b/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_request.rs index 313aee8065..57d52bb0a7 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_request.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_request.rs @@ -4,28 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameCdnSiteRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A list of files preparing to upload. - #[serde(rename = "files")] - pub files: Vec, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A list of files preparing to upload. + #[serde(rename = "files")] + pub files: Vec, } impl CloudGamesCreateGameCdnSiteRequest { - pub fn new( - display_name: String, - files: Vec, - ) -> CloudGamesCreateGameCdnSiteRequest { - CloudGamesCreateGameCdnSiteRequest { - display_name, - files, - } - } + pub fn new(display_name: String, files: Vec) -> CloudGamesCreateGameCdnSiteRequest { + CloudGamesCreateGameCdnSiteRequest { + display_name, + files, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_response.rs b/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_response.rs index c78123eabc..55458bf686 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_response.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_cdn_site_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameCdnSiteResponse { - #[serde(rename = "presigned_requests")] - pub presigned_requests: Vec, - #[serde(rename = "site_id")] - pub site_id: uuid::Uuid, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_requests")] + pub presigned_requests: Vec, + #[serde(rename = "site_id")] + pub site_id: uuid::Uuid, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudGamesCreateGameCdnSiteResponse { - pub fn new( - presigned_requests: Vec, - site_id: uuid::Uuid, - upload_id: uuid::Uuid, - ) -> CloudGamesCreateGameCdnSiteResponse { - CloudGamesCreateGameCdnSiteResponse { - presigned_requests, - site_id, - upload_id, - } - } + pub fn new(presigned_requests: Vec, site_id: uuid::Uuid, upload_id: uuid::Uuid) -> CloudGamesCreateGameCdnSiteResponse { + CloudGamesCreateGameCdnSiteResponse { + presigned_requests, + site_id, + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_request.rs b/sdks/full/rust/src/models/cloud_games_create_game_request.rs index 5e4d2a651e..e5fd44a582 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_request.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_request.rs @@ -4,31 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameRequest { - #[serde(rename = "developer_group_id")] - pub developer_group_id: uuid::Uuid, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id", skip_serializing_if = "Option::is_none")] - pub name_id: Option, + #[serde(rename = "developer_group_id")] + pub developer_group_id: uuid::Uuid, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id", skip_serializing_if = "Option::is_none")] + pub name_id: Option, } impl CloudGamesCreateGameRequest { - pub fn new( - developer_group_id: uuid::Uuid, - display_name: String, - ) -> CloudGamesCreateGameRequest { - CloudGamesCreateGameRequest { - developer_group_id, - display_name, - name_id: None, - } - } + pub fn new(developer_group_id: uuid::Uuid, display_name: String) -> CloudGamesCreateGameRequest { + CloudGamesCreateGameRequest { + developer_group_id, + display_name, + name_id: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_response.rs b/sdks/full/rust/src/models/cloud_games_create_game_response.rs index 55865a7004..9cb95bbc78 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_response.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameResponse { - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, } impl CloudGamesCreateGameResponse { - pub fn new(game_id: uuid::Uuid) -> CloudGamesCreateGameResponse { - CloudGamesCreateGameResponse { game_id } - } + pub fn new(game_id: uuid::Uuid) -> CloudGamesCreateGameResponse { + CloudGamesCreateGameResponse { + game_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_version_request.rs b/sdks/full/rust/src/models/cloud_games_create_game_version_request.rs index 8fe360c142..0fd1233300 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_version_request.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_version_request.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameVersionRequest { - #[serde(rename = "config")] - pub config: Box, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + #[serde(rename = "config")] + pub config: Box, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl CloudGamesCreateGameVersionRequest { - pub fn new( - config: crate::models::CloudVersionConfig, - display_name: String, - ) -> CloudGamesCreateGameVersionRequest { - CloudGamesCreateGameVersionRequest { - config: Box::new(config), - display_name, - } - } + pub fn new(config: crate::models::CloudVersionConfig, display_name: String) -> CloudGamesCreateGameVersionRequest { + CloudGamesCreateGameVersionRequest { + config: Box::new(config), + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_create_game_version_response.rs b/sdks/full/rust/src/models/cloud_games_create_game_version_response.rs index 6faea83e92..fdda808ad3 100644 --- a/sdks/full/rust/src/models/cloud_games_create_game_version_response.rs +++ b/sdks/full/rust/src/models/cloud_games_create_game_version_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesCreateGameVersionResponse { - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudGamesCreateGameVersionResponse { - pub fn new(version_id: uuid::Uuid) -> CloudGamesCreateGameVersionResponse { - CloudGamesCreateGameVersionResponse { version_id } - } + pub fn new(version_id: uuid::Uuid) -> CloudGamesCreateGameVersionResponse { + CloudGamesCreateGameVersionResponse { + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_delete_matchmaker_lobby_response.rs b/sdks/full/rust/src/models/cloud_games_delete_matchmaker_lobby_response.rs index 2a9a1aa711..d7fa01f123 100644 --- a/sdks/full/rust/src/models/cloud_games_delete_matchmaker_lobby_response.rs +++ b/sdks/full/rust/src/models/cloud_games_delete_matchmaker_lobby_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesDeleteMatchmakerLobbyResponse { - /// Whether or not the lobby was successfully stopped. - #[serde(rename = "did_remove")] - pub did_remove: bool, + /// Whether or not the lobby was successfully stopped. + #[serde(rename = "did_remove")] + pub did_remove: bool, } impl CloudGamesDeleteMatchmakerLobbyResponse { - pub fn new(did_remove: bool) -> CloudGamesDeleteMatchmakerLobbyResponse { - CloudGamesDeleteMatchmakerLobbyResponse { did_remove } - } + pub fn new(did_remove: bool) -> CloudGamesDeleteMatchmakerLobbyResponse { + CloudGamesDeleteMatchmakerLobbyResponse { + did_remove, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_export_lobby_logs_request.rs b/sdks/full/rust/src/models/cloud_games_export_lobby_logs_request.rs index 1bcbea9fe2..6f095bf46c 100644 --- a/sdks/full/rust/src/models/cloud_games_export_lobby_logs_request.rs +++ b/sdks/full/rust/src/models/cloud_games_export_lobby_logs_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesExportLobbyLogsRequest { - #[serde(rename = "stream")] - pub stream: crate::models::CloudGamesLogStream, + #[serde(rename = "stream")] + pub stream: crate::models::CloudGamesLogStream, } impl CloudGamesExportLobbyLogsRequest { - pub fn new(stream: crate::models::CloudGamesLogStream) -> CloudGamesExportLobbyLogsRequest { - CloudGamesExportLobbyLogsRequest { stream } - } + pub fn new(stream: crate::models::CloudGamesLogStream) -> CloudGamesExportLobbyLogsRequest { + CloudGamesExportLobbyLogsRequest { + stream, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_export_lobby_logs_response.rs b/sdks/full/rust/src/models/cloud_games_export_lobby_logs_response.rs index 537962e6a1..3d37548c73 100644 --- a/sdks/full/rust/src/models/cloud_games_export_lobby_logs_response.rs +++ b/sdks/full/rust/src/models/cloud_games_export_lobby_logs_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesExportLobbyLogsResponse { - /// The URL to a CSV file for the given lobby history. - #[serde(rename = "url")] - pub url: String, + /// The URL to a CSV file for the given lobby history. + #[serde(rename = "url")] + pub url: String, } impl CloudGamesExportLobbyLogsResponse { - pub fn new(url: String) -> CloudGamesExportLobbyLogsResponse { - CloudGamesExportLobbyLogsResponse { url } - } + pub fn new(url: String) -> CloudGamesExportLobbyLogsResponse { + CloudGamesExportLobbyLogsResponse { + url, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_request.rs b/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_request.rs index 730d41d3f8..87efdd49d2 100644 --- a/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_request.rs +++ b/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_request.rs @@ -4,25 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesExportMatchmakerLobbyHistoryRequest { - /// Unsigned 64 bit integer. - #[serde(rename = "query_end")] - pub query_end: i64, - /// Unsigned 64 bit integer. - #[serde(rename = "query_start")] - pub query_start: i64, + /// Unsigned 64 bit integer. + #[serde(rename = "query_end")] + pub query_end: i64, + /// Unsigned 64 bit integer. + #[serde(rename = "query_start")] + pub query_start: i64, } impl CloudGamesExportMatchmakerLobbyHistoryRequest { - pub fn new(query_end: i64, query_start: i64) -> CloudGamesExportMatchmakerLobbyHistoryRequest { - CloudGamesExportMatchmakerLobbyHistoryRequest { - query_end, - query_start, - } - } + pub fn new(query_end: i64, query_start: i64) -> CloudGamesExportMatchmakerLobbyHistoryRequest { + CloudGamesExportMatchmakerLobbyHistoryRequest { + query_end, + query_start, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_response.rs b/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_response.rs index b6f7026b4e..a526adcc88 100644 --- a/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_response.rs +++ b/sdks/full/rust/src/models/cloud_games_export_matchmaker_lobby_history_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesExportMatchmakerLobbyHistoryResponse { - /// The URL to a CSV file for the given lobby history. - #[serde(rename = "url")] - pub url: String, + /// The URL to a CSV file for the given lobby history. + #[serde(rename = "url")] + pub url: String, } impl CloudGamesExportMatchmakerLobbyHistoryResponse { - pub fn new(url: String) -> CloudGamesExportMatchmakerLobbyHistoryResponse { - CloudGamesExportMatchmakerLobbyHistoryResponse { url } - } + pub fn new(url: String) -> CloudGamesExportMatchmakerLobbyHistoryResponse { + CloudGamesExportMatchmakerLobbyHistoryResponse { + url, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_request.rs b/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_request.rs index d4cfa4066d..46eb2ebf13 100644 --- a/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_request.rs +++ b/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_request.rs @@ -4,29 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGameBannerUploadPrepareRequest { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The MIME type of the game banner. - #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] - pub mime: Option, - /// The path/filename of the game banner. - #[serde(rename = "path")] - pub path: String, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the game banner. + #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] + pub mime: Option, + /// The path/filename of the game banner. + #[serde(rename = "path")] + pub path: String, } impl CloudGamesGameBannerUploadPrepareRequest { - pub fn new(content_length: i64, path: String) -> CloudGamesGameBannerUploadPrepareRequest { - CloudGamesGameBannerUploadPrepareRequest { - content_length, - mime: None, - path, - } - } + pub fn new(content_length: i64, path: String) -> CloudGamesGameBannerUploadPrepareRequest { + CloudGamesGameBannerUploadPrepareRequest { + content_length, + mime: None, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_response.rs b/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_response.rs index 81449fb91b..f93a11279d 100644 --- a/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_response.rs +++ b/sdks/full/rust/src/models/cloud_games_game_banner_upload_prepare_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGameBannerUploadPrepareResponse { - #[serde(rename = "presigned_request")] - pub presigned_request: Box, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_request")] + pub presigned_request: Box, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudGamesGameBannerUploadPrepareResponse { - pub fn new( - presigned_request: crate::models::UploadPresignedRequest, - upload_id: uuid::Uuid, - ) -> CloudGamesGameBannerUploadPrepareResponse { - CloudGamesGameBannerUploadPrepareResponse { - presigned_request: Box::new(presigned_request), - upload_id, - } - } + pub fn new(presigned_request: crate::models::UploadPresignedRequest, upload_id: uuid::Uuid) -> CloudGamesGameBannerUploadPrepareResponse { + CloudGamesGameBannerUploadPrepareResponse { + presigned_request: Box::new(presigned_request), + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_request.rs b/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_request.rs index 655c25fddb..fb54a8713c 100644 --- a/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_request.rs +++ b/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_request.rs @@ -4,29 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGameLogoUploadPrepareRequest { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The MIME type of the game logo. - #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] - pub mime: Option, - /// The path/filename of the game logo. - #[serde(rename = "path")] - pub path: String, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the game logo. + #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] + pub mime: Option, + /// The path/filename of the game logo. + #[serde(rename = "path")] + pub path: String, } impl CloudGamesGameLogoUploadPrepareRequest { - pub fn new(content_length: i64, path: String) -> CloudGamesGameLogoUploadPrepareRequest { - CloudGamesGameLogoUploadPrepareRequest { - content_length, - mime: None, - path, - } - } + pub fn new(content_length: i64, path: String) -> CloudGamesGameLogoUploadPrepareRequest { + CloudGamesGameLogoUploadPrepareRequest { + content_length, + mime: None, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_response.rs b/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_response.rs index a873dfda35..9030027d3f 100644 --- a/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_response.rs +++ b/sdks/full/rust/src/models/cloud_games_game_logo_upload_prepare_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGameLogoUploadPrepareResponse { - #[serde(rename = "presigned_request")] - pub presigned_request: Box, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_request")] + pub presigned_request: Box, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudGamesGameLogoUploadPrepareResponse { - pub fn new( - presigned_request: crate::models::UploadPresignedRequest, - upload_id: uuid::Uuid, - ) -> CloudGamesGameLogoUploadPrepareResponse { - CloudGamesGameLogoUploadPrepareResponse { - presigned_request: Box::new(presigned_request), - upload_id, - } - } + pub fn new(presigned_request: crate::models::UploadPresignedRequest, upload_id: uuid::Uuid) -> CloudGamesGameLogoUploadPrepareResponse { + CloudGamesGameLogoUploadPrepareResponse { + presigned_request: Box::new(presigned_request), + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_get_game_by_id_response.rs b/sdks/full/rust/src/models/cloud_games_get_game_by_id_response.rs index 02eb27ff5d..7b34a45026 100644 --- a/sdks/full/rust/src/models/cloud_games_get_game_by_id_response.rs +++ b/sdks/full/rust/src/models/cloud_games_get_game_by_id_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGetGameByIdResponse { - #[serde(rename = "game")] - pub game: Box, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "game")] + pub game: Box, + #[serde(rename = "watch")] + pub watch: Box, } impl CloudGamesGetGameByIdResponse { - pub fn new( - game: crate::models::CloudGameFull, - watch: crate::models::WatchResponse, - ) -> CloudGamesGetGameByIdResponse { - CloudGamesGetGameByIdResponse { - game: Box::new(game), - watch: Box::new(watch), - } - } + pub fn new(game: crate::models::CloudGameFull, watch: crate::models::WatchResponse) -> CloudGamesGetGameByIdResponse { + CloudGamesGetGameByIdResponse { + game: Box::new(game), + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_get_game_version_by_id_response.rs b/sdks/full/rust/src/models/cloud_games_get_game_version_by_id_response.rs index b95750a2cb..17d85fdb62 100644 --- a/sdks/full/rust/src/models/cloud_games_get_game_version_by_id_response.rs +++ b/sdks/full/rust/src/models/cloud_games_get_game_version_by_id_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGetGameVersionByIdResponse { - #[serde(rename = "version")] - pub version: Box, + #[serde(rename = "version")] + pub version: Box, } impl CloudGamesGetGameVersionByIdResponse { - pub fn new(version: crate::models::CloudVersionFull) -> CloudGamesGetGameVersionByIdResponse { - CloudGamesGetGameVersionByIdResponse { - version: Box::new(version), - } - } + pub fn new(version: crate::models::CloudVersionFull) -> CloudGamesGetGameVersionByIdResponse { + CloudGamesGetGameVersionByIdResponse { + version: Box::new(version), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_get_games_response.rs b/sdks/full/rust/src/models/cloud_games_get_games_response.rs index a81d838fc3..d6bf996615 100644 --- a/sdks/full/rust/src/models/cloud_games_get_games_response.rs +++ b/sdks/full/rust/src/models/cloud_games_get_games_response.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGetGamesResponse { - /// A list of game summaries. - #[serde(rename = "games")] - pub games: Vec, - /// A list of group summaries. - #[serde(rename = "groups")] - pub groups: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// A list of game summaries. + #[serde(rename = "games")] + pub games: Vec, + /// A list of group summaries. + #[serde(rename = "groups")] + pub groups: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl CloudGamesGetGamesResponse { - pub fn new( - games: Vec, - groups: Vec, - watch: crate::models::WatchResponse, - ) -> CloudGamesGetGamesResponse { - CloudGamesGetGamesResponse { - games, - groups, - watch: Box::new(watch), - } - } + pub fn new(games: Vec, groups: Vec, watch: crate::models::WatchResponse) -> CloudGamesGetGamesResponse { + CloudGamesGetGamesResponse { + games, + groups, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_get_lobby_logs_response.rs b/sdks/full/rust/src/models/cloud_games_get_lobby_logs_response.rs index d9afa54e1e..58f54377ac 100644 --- a/sdks/full/rust/src/models/cloud_games_get_lobby_logs_response.rs +++ b/sdks/full/rust/src/models/cloud_games_get_lobby_logs_response.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesGetLobbyLogsResponse { - /// Sorted old to new. - #[serde(rename = "lines")] - pub lines: Vec, - /// Sorted old to new. - #[serde(rename = "timestamps")] - pub timestamps: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// Sorted old to new. + #[serde(rename = "lines")] + pub lines: Vec, + /// Sorted old to new. + #[serde(rename = "timestamps")] + pub timestamps: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl CloudGamesGetLobbyLogsResponse { - pub fn new( - lines: Vec, - timestamps: Vec, - watch: crate::models::WatchResponse, - ) -> CloudGamesGetLobbyLogsResponse { - CloudGamesGetLobbyLogsResponse { - lines, - timestamps, - watch: Box::new(watch), - } - } + pub fn new(lines: Vec, timestamps: Vec, watch: crate::models::WatchResponse) -> CloudGamesGetLobbyLogsResponse { + CloudGamesGetLobbyLogsResponse { + lines, + timestamps, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_list_game_builds_response.rs b/sdks/full/rust/src/models/cloud_games_list_game_builds_response.rs index f2bd888b0b..b1acc359db 100644 --- a/sdks/full/rust/src/models/cloud_games_list_game_builds_response.rs +++ b/sdks/full/rust/src/models/cloud_games_list_game_builds_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesListGameBuildsResponse { - /// A list of build summaries. - #[serde(rename = "builds")] - pub builds: Vec, + /// A list of build summaries. + #[serde(rename = "builds")] + pub builds: Vec, } impl CloudGamesListGameBuildsResponse { - pub fn new(builds: Vec) -> CloudGamesListGameBuildsResponse { - CloudGamesListGameBuildsResponse { builds } - } + pub fn new(builds: Vec) -> CloudGamesListGameBuildsResponse { + CloudGamesListGameBuildsResponse { + builds, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_list_game_cdn_sites_response.rs b/sdks/full/rust/src/models/cloud_games_list_game_cdn_sites_response.rs index b3d42de100..6c6d5a0dc1 100644 --- a/sdks/full/rust/src/models/cloud_games_list_game_cdn_sites_response.rs +++ b/sdks/full/rust/src/models/cloud_games_list_game_cdn_sites_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesListGameCdnSitesResponse { - /// A list of CDN site summaries. - #[serde(rename = "sites")] - pub sites: Vec, + /// A list of CDN site summaries. + #[serde(rename = "sites")] + pub sites: Vec, } impl CloudGamesListGameCdnSitesResponse { - pub fn new( - sites: Vec, - ) -> CloudGamesListGameCdnSitesResponse { - CloudGamesListGameCdnSitesResponse { sites } - } + pub fn new(sites: Vec) -> CloudGamesListGameCdnSitesResponse { + CloudGamesListGameCdnSitesResponse { + sites, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_list_game_custom_avatars_response.rs b/sdks/full/rust/src/models/cloud_games_list_game_custom_avatars_response.rs index 569fef54b4..12d3443345 100644 --- a/sdks/full/rust/src/models/cloud_games_list_game_custom_avatars_response.rs +++ b/sdks/full/rust/src/models/cloud_games_list_game_custom_avatars_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesListGameCustomAvatarsResponse { - /// A list of custom avatar summaries. - #[serde(rename = "custom_avatars")] - pub custom_avatars: Vec, + /// A list of custom avatar summaries. + #[serde(rename = "custom_avatars")] + pub custom_avatars: Vec, } impl CloudGamesListGameCustomAvatarsResponse { - pub fn new( - custom_avatars: Vec, - ) -> CloudGamesListGameCustomAvatarsResponse { - CloudGamesListGameCustomAvatarsResponse { custom_avatars } - } + pub fn new(custom_avatars: Vec) -> CloudGamesListGameCustomAvatarsResponse { + CloudGamesListGameCustomAvatarsResponse { + custom_avatars, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_log_stream.rs b/sdks/full/rust/src/models/cloud_games_log_stream.rs index 7baa7ce2e1..64bc9afaf3 100644 --- a/sdks/full/rust/src/models/cloud_games_log_stream.rs +++ b/sdks/full/rust/src/models/cloud_games_log_stream.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudGamesLogStream { - #[serde(rename = "std_out")] - StdOut, - #[serde(rename = "std_err")] - StdErr, + #[serde(rename = "std_out")] + StdOut, + #[serde(rename = "std_err")] + StdErr, + } impl ToString for CloudGamesLogStream { - fn to_string(&self) -> String { - match self { - Self::StdOut => String::from("std_out"), - Self::StdErr => String::from("std_err"), - } - } + fn to_string(&self) -> String { + match self { + Self::StdOut => String::from("std_out"), + Self::StdErr => String::from("std_err"), + } + } } impl Default for CloudGamesLogStream { - fn default() -> CloudGamesLogStream { - Self::StdOut - } + fn default() -> CloudGamesLogStream { + Self::StdOut + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_add_namespace_domain_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_add_namespace_domain_request.rs index 2d1a3bbee5..444ef1c6a1 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_add_namespace_domain_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_add_namespace_domain_request.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesAddNamespaceDomainRequest { - /// A valid domain name (no protocol). - #[serde(rename = "domain")] - pub domain: String, + /// A valid domain name (no protocol). + #[serde(rename = "domain")] + pub domain: String, } impl CloudGamesNamespacesAddNamespaceDomainRequest { - pub fn new(domain: String) -> CloudGamesNamespacesAddNamespaceDomainRequest { - CloudGamesNamespacesAddNamespaceDomainRequest { domain } - } + pub fn new(domain: String) -> CloudGamesNamespacesAddNamespaceDomainRequest { + CloudGamesNamespacesAddNamespaceDomainRequest { + domain, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_request.rs index e7dac7cb97..39f79522d1 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_request.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesCreateGameNamespaceRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudGamesNamespacesCreateGameNamespaceRequest { - pub fn new( - display_name: String, - name_id: String, - version_id: uuid::Uuid, - ) -> CloudGamesNamespacesCreateGameNamespaceRequest { - CloudGamesNamespacesCreateGameNamespaceRequest { - display_name, - name_id, - version_id, - } - } + pub fn new(display_name: String, name_id: String, version_id: uuid::Uuid) -> CloudGamesNamespacesCreateGameNamespaceRequest { + CloudGamesNamespacesCreateGameNamespaceRequest { + display_name, + name_id, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_response.rs index a1351cfb99..816d4796b3 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesCreateGameNamespaceResponse { - #[serde(rename = "namespace_id")] - pub namespace_id: uuid::Uuid, + #[serde(rename = "namespace_id")] + pub namespace_id: uuid::Uuid, } impl CloudGamesNamespacesCreateGameNamespaceResponse { - pub fn new(namespace_id: uuid::Uuid) -> CloudGamesNamespacesCreateGameNamespaceResponse { - CloudGamesNamespacesCreateGameNamespaceResponse { namespace_id } - } + pub fn new(namespace_id: uuid::Uuid) -> CloudGamesNamespacesCreateGameNamespaceResponse { + CloudGamesNamespacesCreateGameNamespaceResponse { + namespace_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_request.rs index 506a52f6b7..d494b88b33 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_request.rs @@ -4,29 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { - /// The hostname used for the token. - #[serde(rename = "hostname")] - pub hostname: String, - /// **Deprecated** A list of docker ports. - #[serde(rename = "lobby_ports", skip_serializing_if = "Option::is_none")] - pub lobby_ports: Option>, - #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] - pub ports: - Option<::std::collections::HashMap>, + /// The hostname used for the token. + #[serde(rename = "hostname")] + pub hostname: String, + /// **Deprecated** A list of docker ports. + #[serde(rename = "lobby_ports", skip_serializing_if = "Option::is_none")] + pub lobby_ports: Option>, + #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] + pub ports: Option<::std::collections::HashMap>, } impl CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { - pub fn new(hostname: String) -> CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { - CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { - hostname, - lobby_ports: None, - ports: None, - } - } + pub fn new(hostname: String) -> CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { + CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentRequest { + hostname, + lobby_ports: None, + ports: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_response.rs index c4f1e06b9f..1e607255f1 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_development_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { - /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. - #[serde(rename = "token")] - pub token: String, + /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. + #[serde(rename = "token")] + pub token: String, } impl CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { - pub fn new(token: String) -> CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { - CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { token } - } + pub fn new(token: String) -> CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { + CloudGamesNamespacesCreateGameNamespaceTokenDevelopmentResponse { + token, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_public_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_public_response.rs index 629019dc8c..9d6dd8b1ed 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_public_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_create_game_namespace_token_public_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { - /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. - #[serde(rename = "token")] - pub token: String, + /// A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON. + #[serde(rename = "token")] + pub token: String, } impl CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { - pub fn new(token: String) -> CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { - CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { token } - } + pub fn new(token: String) -> CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { + CloudGamesNamespacesCreateGameNamespaceTokenPublicResponse { + token, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_get_analytics_matchmaker_live_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_get_analytics_matchmaker_live_response.rs index 3fc3a7304f..09a134856e 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_get_analytics_matchmaker_live_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_get_analytics_matchmaker_live_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { - /// A list of analytics lobby summaries. - #[serde(rename = "lobbies")] - pub lobbies: Vec, + /// A list of analytics lobby summaries. + #[serde(rename = "lobbies")] + pub lobbies: Vec, } impl CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { - pub fn new( - lobbies: Vec, - ) -> CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { - CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { lobbies } - } + pub fn new(lobbies: Vec) -> CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { + CloudGamesNamespacesGetAnalyticsMatchmakerLiveResponse { + lobbies, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_by_id_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_by_id_response.rs index 7e0d67f7d6..5aa1f56dc4 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_by_id_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_by_id_response.rs @@ -4,22 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesGetGameNamespaceByIdResponse { - #[serde(rename = "namespace")] - pub namespace: Box, + #[serde(rename = "namespace")] + pub namespace: Box, } impl CloudGamesNamespacesGetGameNamespaceByIdResponse { - pub fn new( - namespace: crate::models::CloudNamespaceFull, - ) -> CloudGamesNamespacesGetGameNamespaceByIdResponse { - CloudGamesNamespacesGetGameNamespaceByIdResponse { - namespace: Box::new(namespace), - } - } + pub fn new(namespace: crate::models::CloudNamespaceFull) -> CloudGamesNamespacesGetGameNamespaceByIdResponse { + CloudGamesNamespacesGetGameNamespaceByIdResponse { + namespace: Box::new(namespace), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_version_history_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_version_history_response.rs index beae4bcaf9..0e28f0773e 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_version_history_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_get_game_namespace_version_history_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { - /// A list of previously deployed namespace versions. - #[serde(rename = "versions")] - pub versions: Vec, + /// A list of previously deployed namespace versions. + #[serde(rename = "versions")] + pub versions: Vec, } impl CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { - pub fn new( - versions: Vec, - ) -> CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { - CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { versions } - } + pub fn new(versions: Vec) -> CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { + CloudGamesNamespacesGetGameNamespaceVersionHistoryResponse { + versions, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_get_namespace_lobby_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_get_namespace_lobby_response.rs index 571152f5c6..c09446bc8c 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_get_namespace_lobby_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_get_namespace_lobby_response.rs @@ -4,40 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesGetNamespaceLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "metrics", skip_serializing_if = "Option::is_none")] - pub metrics: Option>, - /// **Deprecated** A list of service performance summaries. - #[serde(rename = "perf_lists")] - pub perf_lists: Vec, - /// **Deprecated** A list of URLs. - #[serde(rename = "stderr_presigned_urls")] - pub stderr_presigned_urls: Vec, - /// **Deprecated** A list of URLs. - #[serde(rename = "stdout_presigned_urls")] - pub stdout_presigned_urls: Vec, + #[serde(rename = "lobby")] + pub lobby: Box, + #[serde(rename = "metrics", skip_serializing_if = "Option::is_none")] + pub metrics: Option>, + /// **Deprecated** A list of service performance summaries. + #[serde(rename = "perf_lists")] + pub perf_lists: Vec, + /// **Deprecated** A list of URLs. + #[serde(rename = "stderr_presigned_urls")] + pub stderr_presigned_urls: Vec, + /// **Deprecated** A list of URLs. + #[serde(rename = "stdout_presigned_urls")] + pub stdout_presigned_urls: Vec, } impl CloudGamesNamespacesGetNamespaceLobbyResponse { - pub fn new( - lobby: crate::models::CloudLogsLobbySummary, - perf_lists: Vec, - stderr_presigned_urls: Vec, - stdout_presigned_urls: Vec, - ) -> CloudGamesNamespacesGetNamespaceLobbyResponse { - CloudGamesNamespacesGetNamespaceLobbyResponse { - lobby: Box::new(lobby), - metrics: None, - perf_lists, - stderr_presigned_urls, - stdout_presigned_urls, - } - } + pub fn new(lobby: crate::models::CloudLogsLobbySummary, perf_lists: Vec, stderr_presigned_urls: Vec, stdout_presigned_urls: Vec) -> CloudGamesNamespacesGetNamespaceLobbyResponse { + CloudGamesNamespacesGetNamespaceLobbyResponse { + lobby: Box::new(lobby), + metrics: None, + perf_lists, + stderr_presigned_urls, + stdout_presigned_urls, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_inspect_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_inspect_response.rs index 04d48f490b..90fc0df81b 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_inspect_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_inspect_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesInspectResponse { - #[serde(rename = "agent")] - pub agent: Box, + #[serde(rename = "agent")] + pub agent: Box, } impl CloudGamesNamespacesInspectResponse { - pub fn new(agent: crate::models::CloudAuthAgent) -> CloudGamesNamespacesInspectResponse { - CloudGamesNamespacesInspectResponse { - agent: Box::new(agent), - } - } + pub fn new(agent: crate::models::CloudAuthAgent) -> CloudGamesNamespacesInspectResponse { + CloudGamesNamespacesInspectResponse { + agent: Box::new(agent), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_list_namespace_lobbies_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_list_namespace_lobbies_response.rs index dc24c28505..42e804d011 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_list_namespace_lobbies_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_list_namespace_lobbies_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesListNamespaceLobbiesResponse { - /// A list of lobby log summaries. - #[serde(rename = "lobbies")] - pub lobbies: Vec, + /// A list of lobby log summaries. + #[serde(rename = "lobbies")] + pub lobbies: Vec, } impl CloudGamesNamespacesListNamespaceLobbiesResponse { - pub fn new( - lobbies: Vec, - ) -> CloudGamesNamespacesListNamespaceLobbiesResponse { - CloudGamesNamespacesListNamespaceLobbiesResponse { lobbies } - } + pub fn new(lobbies: Vec) -> CloudGamesNamespacesListNamespaceLobbiesResponse { + CloudGamesNamespacesListNamespaceLobbiesResponse { + lobbies, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_set_namespace_cdn_auth_type_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_set_namespace_cdn_auth_type_request.rs index dce840ab4e..d6f98905b4 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_set_namespace_cdn_auth_type_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_set_namespace_cdn_auth_type_request.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { - #[serde(rename = "auth_type")] - pub auth_type: crate::models::CloudCdnAuthType, + #[serde(rename = "auth_type")] + pub auth_type: crate::models::CloudCdnAuthType, } impl CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { - pub fn new( - auth_type: crate::models::CloudCdnAuthType, - ) -> CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { - CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { auth_type } - } + pub fn new(auth_type: crate::models::CloudCdnAuthType) -> CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { + CloudGamesNamespacesSetNamespaceCdnAuthTypeRequest { + auth_type, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_toggle_namespace_domain_public_auth_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_toggle_namespace_domain_public_auth_request.rs index fbe7dc86f5..8f756de255 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_toggle_namespace_domain_public_auth_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_toggle_namespace_domain_public_auth_request.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { - /// Whether or not to enable authentication based on domain. - #[serde(rename = "enabled")] - pub enabled: bool, + /// Whether or not to enable authentication based on domain. + #[serde(rename = "enabled")] + pub enabled: bool, } impl CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { - pub fn new(enabled: bool) -> CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { - CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { enabled } - } + pub fn new(enabled: bool) -> CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { + CloudGamesNamespacesToggleNamespaceDomainPublicAuthRequest { + enabled, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_matchmaker_config_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_matchmaker_config_request.rs index fcbeabf8e3..1e10a667a3 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_matchmaker_config_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_matchmaker_config_request.rs @@ -4,28 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { - /// Unsigned 32 bit integer. - #[serde(rename = "lobby_count_max")] - pub lobby_count_max: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players")] - pub max_players: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "lobby_count_max")] + pub lobby_count_max: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players")] + pub max_players: i32, } impl CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { - pub fn new( - lobby_count_max: i32, - max_players: i32, - ) -> CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { - CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { - lobby_count_max, - max_players, - } - } + pub fn new(lobby_count_max: i32, max_players: i32) -> CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { + CloudGamesNamespacesUpdateGameNamespaceMatchmakerConfigRequest { + lobby_count_max, + max_players, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_version_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_version_request.rs index 449d2f84f5..7bc24f72d1 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_version_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_update_game_namespace_version_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesUpdateGameNamespaceVersionRequest { - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudGamesNamespacesUpdateGameNamespaceVersionRequest { - pub fn new(version_id: uuid::Uuid) -> CloudGamesNamespacesUpdateGameNamespaceVersionRequest { - CloudGamesNamespacesUpdateGameNamespaceVersionRequest { version_id } - } + pub fn new(version_id: uuid::Uuid) -> CloudGamesNamespacesUpdateGameNamespaceVersionRequest { + CloudGamesNamespacesUpdateGameNamespaceVersionRequest { + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_update_namespace_cdn_auth_user_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_update_namespace_cdn_auth_user_request.rs index f534b12a1b..639da0d8a5 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_update_namespace_cdn_auth_user_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_update_namespace_cdn_auth_user_request.rs @@ -4,25 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { - /// A bcrypt encrypted password. An error is returned if the given string is not properly encrypted. - #[serde(rename = "password")] - pub password: String, - /// A user name. - #[serde(rename = "user")] - pub user: String, + /// A bcrypt encrypted password. An error is returned if the given string is not properly encrypted. + #[serde(rename = "password")] + pub password: String, + /// A user name. + #[serde(rename = "user")] + pub user: String, } impl CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { - pub fn new( - password: String, - user: String, - ) -> CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { - CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { password, user } - } + pub fn new(password: String, user: String) -> CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { + CloudGamesNamespacesUpdateNamespaceCdnAuthUserRequest { + password, + user, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_request.rs index 4bd2f73d7c..b144620c51 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_request.rs @@ -4,28 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { - /// Unsigned 32 bit integer. - #[serde(rename = "lobby_count_max")] - pub lobby_count_max: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players")] - pub max_players: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "lobby_count_max")] + pub lobby_count_max: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players")] + pub max_players: i32, } impl CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { - pub fn new( - lobby_count_max: i32, - max_players: i32, - ) -> CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { - CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { - lobby_count_max, - max_players, - } - } + pub fn new(lobby_count_max: i32, max_players: i32) -> CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { + CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigRequest { + lobby_count_max, + max_players, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_response.rs index cecc971e97..5b0d3eee10 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_matchmaker_config_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { - pub fn new( - errors: Vec, - ) -> CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { - CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { errors } - } + pub fn new(errors: Vec) -> CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { + CloudGamesNamespacesValidateGameNamespaceMatchmakerConfigResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_request.rs index ad37b02940..3b49b7bcab 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_request.rs @@ -4,28 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, } impl CloudGamesNamespacesValidateGameNamespaceRequest { - pub fn new( - display_name: String, - name_id: String, - ) -> CloudGamesNamespacesValidateGameNamespaceRequest { - CloudGamesNamespacesValidateGameNamespaceRequest { - display_name, - name_id, - } - } + pub fn new(display_name: String, name_id: String) -> CloudGamesNamespacesValidateGameNamespaceRequest { + CloudGamesNamespacesValidateGameNamespaceRequest { + display_name, + name_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_response.rs index fd9e4ecf65..65be900bea 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudGamesNamespacesValidateGameNamespaceResponse { - pub fn new( - errors: Vec, - ) -> CloudGamesNamespacesValidateGameNamespaceResponse { - CloudGamesNamespacesValidateGameNamespaceResponse { errors } - } + pub fn new(errors: Vec) -> CloudGamesNamespacesValidateGameNamespaceResponse { + CloudGamesNamespacesValidateGameNamespaceResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_request.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_request.rs index dc2251e01a..c3c7db4f09 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_request.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_request.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { - #[serde(rename = "hostname")] - pub hostname: String, - /// A list of docker ports. - #[serde(rename = "lobby_ports")] - pub lobby_ports: Vec, + #[serde(rename = "hostname")] + pub hostname: String, + /// A list of docker ports. + #[serde(rename = "lobby_ports")] + pub lobby_ports: Vec, } impl CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { - pub fn new( - hostname: String, - lobby_ports: Vec, - ) -> CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { - CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { - hostname, - lobby_ports, - } - } + pub fn new(hostname: String, lobby_ports: Vec) -> CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { + CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentRequest { + hostname, + lobby_ports, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_response.rs b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_response.rs index 1c1bf23657..b647adf24a 100644 --- a/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_response.rs +++ b/sdks/full/rust/src/models/cloud_games_namespaces_validate_game_namespace_token_development_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { - pub fn new( - errors: Vec, - ) -> CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { - CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { errors } - } + pub fn new(errors: Vec) -> CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { + CloudGamesNamespacesValidateGameNamespaceTokenDevelopmentResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_request.rs b/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_request.rs index 2bc7209e85..fe9c725209 100644 --- a/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_request.rs +++ b/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_request.rs @@ -4,29 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesPrepareCustomAvatarUploadRequest { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The MIME type of the custom avatar. - #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] - pub mime: Option, - /// The path/filename of the custom avatar. - #[serde(rename = "path")] - pub path: String, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the custom avatar. + #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] + pub mime: Option, + /// The path/filename of the custom avatar. + #[serde(rename = "path")] + pub path: String, } impl CloudGamesPrepareCustomAvatarUploadRequest { - pub fn new(content_length: i64, path: String) -> CloudGamesPrepareCustomAvatarUploadRequest { - CloudGamesPrepareCustomAvatarUploadRequest { - content_length, - mime: None, - path, - } - } + pub fn new(content_length: i64, path: String) -> CloudGamesPrepareCustomAvatarUploadRequest { + CloudGamesPrepareCustomAvatarUploadRequest { + content_length, + mime: None, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_response.rs b/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_response.rs index 4c5c52bd45..acf310ffb8 100644 --- a/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_response.rs +++ b/sdks/full/rust/src/models/cloud_games_prepare_custom_avatar_upload_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesPrepareCustomAvatarUploadResponse { - #[serde(rename = "presigned_request")] - pub presigned_request: Box, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_request")] + pub presigned_request: Box, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudGamesPrepareCustomAvatarUploadResponse { - pub fn new( - presigned_request: crate::models::UploadPresignedRequest, - upload_id: uuid::Uuid, - ) -> CloudGamesPrepareCustomAvatarUploadResponse { - CloudGamesPrepareCustomAvatarUploadResponse { - presigned_request: Box::new(presigned_request), - upload_id, - } - } + pub fn new(presigned_request: crate::models::UploadPresignedRequest, upload_id: uuid::Uuid) -> CloudGamesPrepareCustomAvatarUploadResponse { + CloudGamesPrepareCustomAvatarUploadResponse { + presigned_request: Box::new(presigned_request), + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_reserve_version_name_response.rs b/sdks/full/rust/src/models/cloud_games_reserve_version_name_response.rs index f4db92c3dc..1ca6b9fd43 100644 --- a/sdks/full/rust/src/models/cloud_games_reserve_version_name_response.rs +++ b/sdks/full/rust/src/models/cloud_games_reserve_version_name_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesReserveVersionNameResponse { - /// Represent a resource's readable display name. - #[serde(rename = "version_display_name")] - pub version_display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "version_display_name")] + pub version_display_name: String, } impl CloudGamesReserveVersionNameResponse { - pub fn new(version_display_name: String) -> CloudGamesReserveVersionNameResponse { - CloudGamesReserveVersionNameResponse { - version_display_name, - } - } + pub fn new(version_display_name: String) -> CloudGamesReserveVersionNameResponse { + CloudGamesReserveVersionNameResponse { + version_display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_validate_game_request.rs b/sdks/full/rust/src/models/cloud_games_validate_game_request.rs index 1583276b99..30f7fb8d7b 100644 --- a/sdks/full/rust/src/models/cloud_games_validate_game_request.rs +++ b/sdks/full/rust/src/models/cloud_games_validate_game_request.rs @@ -4,25 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesValidateGameRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id", skip_serializing_if = "Option::is_none")] - pub name_id: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id", skip_serializing_if = "Option::is_none")] + pub name_id: Option, } impl CloudGamesValidateGameRequest { - pub fn new(display_name: String) -> CloudGamesValidateGameRequest { - CloudGamesValidateGameRequest { - display_name, - name_id: None, - } - } + pub fn new(display_name: String) -> CloudGamesValidateGameRequest { + CloudGamesValidateGameRequest { + display_name, + name_id: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_validate_game_response.rs b/sdks/full/rust/src/models/cloud_games_validate_game_response.rs index 05215a883f..d5b3f32d81 100644 --- a/sdks/full/rust/src/models/cloud_games_validate_game_response.rs +++ b/sdks/full/rust/src/models/cloud_games_validate_game_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesValidateGameResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudGamesValidateGameResponse { - pub fn new(errors: Vec) -> CloudGamesValidateGameResponse { - CloudGamesValidateGameResponse { errors } - } + pub fn new(errors: Vec) -> CloudGamesValidateGameResponse { + CloudGamesValidateGameResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_validate_game_version_request.rs b/sdks/full/rust/src/models/cloud_games_validate_game_version_request.rs index 4ef42058f4..2f2f612e67 100644 --- a/sdks/full/rust/src/models/cloud_games_validate_game_version_request.rs +++ b/sdks/full/rust/src/models/cloud_games_validate_game_version_request.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesValidateGameVersionRequest { - #[serde(rename = "config")] - pub config: Box, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + #[serde(rename = "config")] + pub config: Box, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl CloudGamesValidateGameVersionRequest { - pub fn new( - config: crate::models::CloudVersionConfig, - display_name: String, - ) -> CloudGamesValidateGameVersionRequest { - CloudGamesValidateGameVersionRequest { - config: Box::new(config), - display_name, - } - } + pub fn new(config: crate::models::CloudVersionConfig, display_name: String) -> CloudGamesValidateGameVersionRequest { + CloudGamesValidateGameVersionRequest { + config: Box::new(config), + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_games_validate_game_version_response.rs b/sdks/full/rust/src/models/cloud_games_validate_game_version_response.rs index c9d0d60710..8d55feaec9 100644 --- a/sdks/full/rust/src/models/cloud_games_validate_game_version_response.rs +++ b/sdks/full/rust/src/models/cloud_games_validate_game_version_response.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGamesValidateGameVersionResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudGamesValidateGameVersionResponse { - pub fn new( - errors: Vec, - ) -> CloudGamesValidateGameVersionResponse { - CloudGamesValidateGameVersionResponse { errors } - } + pub fn new(errors: Vec) -> CloudGamesValidateGameVersionResponse { + CloudGamesValidateGameVersionResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_get_ray_perf_logs_response.rs b/sdks/full/rust/src/models/cloud_get_ray_perf_logs_response.rs index 1f64ed13d8..ec13db31b5 100644 --- a/sdks/full/rust/src/models/cloud_get_ray_perf_logs_response.rs +++ b/sdks/full/rust/src/models/cloud_get_ray_perf_logs_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGetRayPerfLogsResponse { - /// A list of service performance summaries. - #[serde(rename = "perf_lists")] - pub perf_lists: Vec, + /// A list of service performance summaries. + #[serde(rename = "perf_lists")] + pub perf_lists: Vec, } impl CloudGetRayPerfLogsResponse { - pub fn new(perf_lists: Vec) -> CloudGetRayPerfLogsResponse { - CloudGetRayPerfLogsResponse { perf_lists } - } + pub fn new(perf_lists: Vec) -> CloudGetRayPerfLogsResponse { + CloudGetRayPerfLogsResponse { + perf_lists, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_get_region_tiers_response.rs b/sdks/full/rust/src/models/cloud_get_region_tiers_response.rs index 4c2f4b22de..e49ac514bf 100644 --- a/sdks/full/rust/src/models/cloud_get_region_tiers_response.rs +++ b/sdks/full/rust/src/models/cloud_get_region_tiers_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGetRegionTiersResponse { - /// A list of region server tiers. - #[serde(rename = "tiers")] - pub tiers: Vec, + /// A list of region server tiers. + #[serde(rename = "tiers")] + pub tiers: Vec, } impl CloudGetRegionTiersResponse { - pub fn new(tiers: Vec) -> CloudGetRegionTiersResponse { - CloudGetRegionTiersResponse { tiers } - } + pub fn new(tiers: Vec) -> CloudGetRegionTiersResponse { + CloudGetRegionTiersResponse { + tiers, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_group_bank_source.rs b/sdks/full/rust/src/models/cloud_group_bank_source.rs index 34e49405bb..78e864f8c4 100644 --- a/sdks/full/rust/src/models/cloud_group_bank_source.rs +++ b/sdks/full/rust/src/models/cloud_group_bank_source.rs @@ -4,25 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudGroupBankSource { - /// The bank account number of this group's bank source. - #[serde(rename = "account_number")] - pub account_number: String, - /// The bank routing number of this group's bank source. - #[serde(rename = "routing_number")] - pub routing_number: String, + /// The bank account number of this group's bank source. + #[serde(rename = "account_number")] + pub account_number: String, + /// The bank routing number of this group's bank source. + #[serde(rename = "routing_number")] + pub routing_number: String, } impl CloudGroupBankSource { - pub fn new(account_number: String, routing_number: String) -> CloudGroupBankSource { - CloudGroupBankSource { - account_number, - routing_number, - } - } + pub fn new(account_number: String, routing_number: String) -> CloudGroupBankSource { + CloudGroupBankSource { + account_number, + routing_number, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_inspect_response.rs b/sdks/full/rust/src/models/cloud_inspect_response.rs index 721bc953dd..21bfa6f475 100644 --- a/sdks/full/rust/src/models/cloud_inspect_response.rs +++ b/sdks/full/rust/src/models/cloud_inspect_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudInspectResponse { - #[serde(rename = "agent")] - pub agent: Box, + #[serde(rename = "agent")] + pub agent: Box, } impl CloudInspectResponse { - pub fn new(agent: crate::models::CloudAuthAgent) -> CloudInspectResponse { - CloudInspectResponse { - agent: Box::new(agent), - } - } + pub fn new(agent: crate::models::CloudAuthAgent) -> CloudInspectResponse { + CloudInspectResponse { + agent: Box::new(agent), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_lobby_summary_analytics.rs b/sdks/full/rust/src/models/cloud_lobby_summary_analytics.rs index 99601bf8bc..e99c372fb3 100644 --- a/sdks/full/rust/src/models/cloud_lobby_summary_analytics.rs +++ b/sdks/full/rust/src/models/cloud_lobby_summary_analytics.rs @@ -4,88 +4,77 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLobbySummaryAnalytics : Analytical information about a lobby. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLobbySummaryAnalytics { - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Whether or not this lobby is in a closed state. - #[serde(rename = "is_closed")] - pub is_closed: bool, - /// Whether or not this lobby is idle. - #[serde(rename = "is_idle")] - pub is_idle: bool, - /// Whether or not this lobby is outdated. - #[serde(rename = "is_outdated")] - pub is_outdated: bool, - /// Whether or not this lobby is ready. - #[serde(rename = "is_ready")] - pub is_ready: bool, - #[serde(rename = "lobby_group_id")] - pub lobby_group_id: uuid::Uuid, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "lobby_group_name_id")] - pub lobby_group_name_id: String, - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_direct")] - pub max_players_direct: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_normal")] - pub max_players_normal: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_party")] - pub max_players_party: i32, - #[serde(rename = "region_id")] - pub region_id: uuid::Uuid, - /// Unsigned 32 bit integer. - #[serde(rename = "registered_player_count")] - pub registered_player_count: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "total_player_count")] - pub total_player_count: i32, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Whether or not this lobby is in a closed state. + #[serde(rename = "is_closed")] + pub is_closed: bool, + /// Whether or not this lobby is idle. + #[serde(rename = "is_idle")] + pub is_idle: bool, + /// Whether or not this lobby is outdated. + #[serde(rename = "is_outdated")] + pub is_outdated: bool, + /// Whether or not this lobby is ready. + #[serde(rename = "is_ready")] + pub is_ready: bool, + #[serde(rename = "lobby_group_id")] + pub lobby_group_id: uuid::Uuid, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "lobby_group_name_id")] + pub lobby_group_name_id: String, + #[serde(rename = "lobby_id")] + pub lobby_id: uuid::Uuid, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_direct")] + pub max_players_direct: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_normal")] + pub max_players_normal: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_party")] + pub max_players_party: i32, + #[serde(rename = "region_id")] + pub region_id: uuid::Uuid, + /// Unsigned 32 bit integer. + #[serde(rename = "registered_player_count")] + pub registered_player_count: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "total_player_count")] + pub total_player_count: i32, } impl CloudLobbySummaryAnalytics { - /// Analytical information about a lobby. - pub fn new( - create_ts: String, - is_closed: bool, - is_idle: bool, - is_outdated: bool, - is_ready: bool, - lobby_group_id: uuid::Uuid, - lobby_group_name_id: String, - lobby_id: uuid::Uuid, - max_players_direct: i32, - max_players_normal: i32, - max_players_party: i32, - region_id: uuid::Uuid, - registered_player_count: i32, - total_player_count: i32, - ) -> CloudLobbySummaryAnalytics { - CloudLobbySummaryAnalytics { - create_ts, - is_closed, - is_idle, - is_outdated, - is_ready, - lobby_group_id, - lobby_group_name_id, - lobby_id, - max_players_direct, - max_players_normal, - max_players_party, - region_id, - registered_player_count, - total_player_count, - } - } + /// Analytical information about a lobby. + pub fn new(create_ts: String, is_closed: bool, is_idle: bool, is_outdated: bool, is_ready: bool, lobby_group_id: uuid::Uuid, lobby_group_name_id: String, lobby_id: uuid::Uuid, max_players_direct: i32, max_players_normal: i32, max_players_party: i32, region_id: uuid::Uuid, registered_player_count: i32, total_player_count: i32) -> CloudLobbySummaryAnalytics { + CloudLobbySummaryAnalytics { + create_ts, + is_closed, + is_idle, + is_outdated, + is_ready, + lobby_group_id, + lobby_group_name_id, + lobby_id, + max_players_direct, + max_players_normal, + max_players_party, + region_id, + registered_player_count, + total_player_count, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_logs_lobby_status.rs b/sdks/full/rust/src/models/cloud_logs_lobby_status.rs index 6ba2e567db..6ce2a4709b 100644 --- a/sdks/full/rust/src/models/cloud_logs_lobby_status.rs +++ b/sdks/full/rust/src/models/cloud_logs_lobby_status.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLogsLobbyStatus : A union representing the state of a lobby. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLogsLobbyStatus { - #[serde(rename = "running")] - pub running: serde_json::Value, - #[serde(rename = "stopped", skip_serializing_if = "Option::is_none")] - pub stopped: Option>, + #[serde(rename = "running")] + pub running: serde_json::Value, + #[serde(rename = "stopped", skip_serializing_if = "Option::is_none")] + pub stopped: Option>, } impl CloudLogsLobbyStatus { - /// A union representing the state of a lobby. - pub fn new(running: serde_json::Value) -> CloudLogsLobbyStatus { - CloudLogsLobbyStatus { - running, - stopped: None, - } - } + /// A union representing the state of a lobby. + pub fn new(running: serde_json::Value) -> CloudLogsLobbyStatus { + CloudLogsLobbyStatus { + running, + stopped: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_logs_lobby_status_stopped.rs b/sdks/full/rust/src/models/cloud_logs_lobby_status_stopped.rs index a8c76c69a2..c74fa79844 100644 --- a/sdks/full/rust/src/models/cloud_logs_lobby_status_stopped.rs +++ b/sdks/full/rust/src/models/cloud_logs_lobby_status_stopped.rs @@ -4,32 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLogsLobbyStatusStopped : The status of a stopped lobby. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLogsLobbyStatusStopped { - /// The exit code returned by the lobby's main process when stopped. - #[serde(rename = "exit_code")] - pub exit_code: i32, - /// Whether or not the lobby failed or stopped successfully. - #[serde(rename = "failed")] - pub failed: bool, - /// RFC3339 timestamp - #[serde(rename = "stop_ts")] - pub stop_ts: String, + /// The exit code returned by the lobby's main process when stopped. + #[serde(rename = "exit_code")] + pub exit_code: i32, + /// Whether or not the lobby failed or stopped successfully. + #[serde(rename = "failed")] + pub failed: bool, + /// RFC3339 timestamp + #[serde(rename = "stop_ts")] + pub stop_ts: String, } impl CloudLogsLobbyStatusStopped { - /// The status of a stopped lobby. - pub fn new(exit_code: i32, failed: bool, stop_ts: String) -> CloudLogsLobbyStatusStopped { - CloudLogsLobbyStatusStopped { - exit_code, - failed, - stop_ts, - } - } + /// The status of a stopped lobby. + pub fn new(exit_code: i32, failed: bool, stop_ts: String) -> CloudLogsLobbyStatusStopped { + CloudLogsLobbyStatusStopped { + exit_code, + failed, + stop_ts, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_logs_lobby_summary.rs b/sdks/full/rust/src/models/cloud_logs_lobby_summary.rs index 9453e99016..7f24f714de 100644 --- a/sdks/full/rust/src/models/cloud_logs_lobby_summary.rs +++ b/sdks/full/rust/src/models/cloud_logs_lobby_summary.rs @@ -4,55 +4,52 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLogsLobbySummary : A logs summary for a lobby. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLogsLobbySummary { - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "lobby_group_name_id")] - pub lobby_group_name_id: String, - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - #[serde(rename = "namespace_id")] - pub namespace_id: uuid::Uuid, - /// RFC3339 timestamp - #[serde(rename = "ready_ts", skip_serializing_if = "Option::is_none")] - pub ready_ts: Option, - #[serde(rename = "region_id")] - pub region_id: uuid::Uuid, - /// RFC3339 timestamp - #[serde(rename = "start_ts", skip_serializing_if = "Option::is_none")] - pub start_ts: Option, - #[serde(rename = "status")] - pub status: Box, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "lobby_group_name_id")] + pub lobby_group_name_id: String, + #[serde(rename = "lobby_id")] + pub lobby_id: uuid::Uuid, + #[serde(rename = "namespace_id")] + pub namespace_id: uuid::Uuid, + /// RFC3339 timestamp + #[serde(rename = "ready_ts", skip_serializing_if = "Option::is_none")] + pub ready_ts: Option, + #[serde(rename = "region_id")] + pub region_id: uuid::Uuid, + /// RFC3339 timestamp + #[serde(rename = "start_ts", skip_serializing_if = "Option::is_none")] + pub start_ts: Option, + #[serde(rename = "status")] + pub status: Box, } impl CloudLogsLobbySummary { - /// A logs summary for a lobby. - pub fn new( - create_ts: String, - lobby_group_name_id: String, - lobby_id: uuid::Uuid, - namespace_id: uuid::Uuid, - region_id: uuid::Uuid, - status: crate::models::CloudLogsLobbyStatus, - ) -> CloudLogsLobbySummary { - CloudLogsLobbySummary { - create_ts, - lobby_group_name_id, - lobby_id, - namespace_id, - ready_ts: None, - region_id, - start_ts: None, - status: Box::new(status), - } - } + /// A logs summary for a lobby. + pub fn new(create_ts: String, lobby_group_name_id: String, lobby_id: uuid::Uuid, namespace_id: uuid::Uuid, region_id: uuid::Uuid, status: crate::models::CloudLogsLobbyStatus) -> CloudLogsLobbySummary { + CloudLogsLobbySummary { + create_ts, + lobby_group_name_id, + lobby_id, + namespace_id, + ready_ts: None, + region_id, + start_ts: None, + status: Box::new(status), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_logs_perf_mark.rs b/sdks/full/rust/src/models/cloud_logs_perf_mark.rs index 5510570cbe..7df6a121f9 100644 --- a/sdks/full/rust/src/models/cloud_logs_perf_mark.rs +++ b/sdks/full/rust/src/models/cloud_logs_perf_mark.rs @@ -4,34 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLogsPerfMark : A performance mark. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLogsPerfMark { - /// The label given to this performance mark. - #[serde(rename = "label")] - pub label: String, - #[serde(rename = "ray_id", skip_serializing_if = "Option::is_none")] - pub ray_id: Option, - #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] - pub req_id: Option, - /// RFC3339 timestamp - #[serde(rename = "ts")] - pub ts: String, + /// The label given to this performance mark. + #[serde(rename = "label")] + pub label: String, + #[serde(rename = "ray_id", skip_serializing_if = "Option::is_none")] + pub ray_id: Option, + #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] + pub req_id: Option, + /// RFC3339 timestamp + #[serde(rename = "ts")] + pub ts: String, } impl CloudLogsPerfMark { - /// A performance mark. - pub fn new(label: String, ts: String) -> CloudLogsPerfMark { - CloudLogsPerfMark { - label, - ray_id: None, - req_id: None, - ts, - } - } + /// A performance mark. + pub fn new(label: String, ts: String) -> CloudLogsPerfMark { + CloudLogsPerfMark { + label, + ray_id: None, + req_id: None, + ts, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_logs_perf_span.rs b/sdks/full/rust/src/models/cloud_logs_perf_span.rs index ca76fd748f..43429ba2c8 100644 --- a/sdks/full/rust/src/models/cloud_logs_perf_span.rs +++ b/sdks/full/rust/src/models/cloud_logs_perf_span.rs @@ -4,35 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudLogsPerfSpan : A performance span. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudLogsPerfSpan { - /// RFC3339 timestamp - #[serde(rename = "finish_ts", skip_serializing_if = "Option::is_none")] - pub finish_ts: Option, - /// The label given to this performance span. - #[serde(rename = "label")] - pub label: String, - #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] - pub req_id: Option, - /// RFC3339 timestamp - #[serde(rename = "start_ts")] - pub start_ts: String, + /// RFC3339 timestamp + #[serde(rename = "finish_ts", skip_serializing_if = "Option::is_none")] + pub finish_ts: Option, + /// The label given to this performance span. + #[serde(rename = "label")] + pub label: String, + #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] + pub req_id: Option, + /// RFC3339 timestamp + #[serde(rename = "start_ts")] + pub start_ts: String, } impl CloudLogsPerfSpan { - /// A performance span. - pub fn new(label: String, start_ts: String) -> CloudLogsPerfSpan { - CloudLogsPerfSpan { - finish_ts: None, - label, - req_id: None, - start_ts, - } - } + /// A performance span. + pub fn new(label: String, start_ts: String) -> CloudLogsPerfSpan { + CloudLogsPerfSpan { + finish_ts: None, + label, + req_id: None, + start_ts, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_matchmaker_development_port.rs b/sdks/full/rust/src/models/cloud_matchmaker_development_port.rs index a4be2575ae..b901399953 100644 --- a/sdks/full/rust/src/models/cloud_matchmaker_development_port.rs +++ b/sdks/full/rust/src/models/cloud_matchmaker_development_port.rs @@ -4,31 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudMatchmakerDevelopmentPort : A port configuration used to create development tokens. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudMatchmakerDevelopmentPort { - #[serde(rename = "port", skip_serializing_if = "Option::is_none")] - pub port: Option, - #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] - pub port_range: Option>, - #[serde(rename = "protocol")] - pub protocol: crate::models::CloudVersionMatchmakerPortProtocol, + #[serde(rename = "port", skip_serializing_if = "Option::is_none")] + pub port: Option, + #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] + pub port_range: Option>, + #[serde(rename = "protocol")] + pub protocol: crate::models::CloudVersionMatchmakerPortProtocol, } impl CloudMatchmakerDevelopmentPort { - /// A port configuration used to create development tokens. - pub fn new( - protocol: crate::models::CloudVersionMatchmakerPortProtocol, - ) -> CloudMatchmakerDevelopmentPort { - CloudMatchmakerDevelopmentPort { - port: None, - port_range: None, - protocol, - } - } + /// A port configuration used to create development tokens. + pub fn new(protocol: crate::models::CloudVersionMatchmakerPortProtocol) -> CloudMatchmakerDevelopmentPort { + CloudMatchmakerDevelopmentPort { + port: None, + port_range: None, + protocol, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_matchmaker_namespace_config.rs b/sdks/full/rust/src/models/cloud_matchmaker_namespace_config.rs index 07b9f85be3..458a1df6b1 100644 --- a/sdks/full/rust/src/models/cloud_matchmaker_namespace_config.rs +++ b/sdks/full/rust/src/models/cloud_matchmaker_namespace_config.rs @@ -4,51 +4,48 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudMatchmakerNamespaceConfig : Matchmaker configuration for a given namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudMatchmakerNamespaceConfig { - /// Unsigned 32 bit integer. - #[serde(rename = "lobby_count_max")] - pub lobby_count_max: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_per_client")] - pub max_players_per_client: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_per_client_hosting")] - pub max_players_per_client_hosting: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_per_client_proxy")] - pub max_players_per_client_proxy: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_per_client_tor")] - pub max_players_per_client_tor: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_per_client_vpn")] - pub max_players_per_client_vpn: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "lobby_count_max")] + pub lobby_count_max: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_per_client")] + pub max_players_per_client: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_per_client_hosting")] + pub max_players_per_client_hosting: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_per_client_proxy")] + pub max_players_per_client_proxy: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_per_client_tor")] + pub max_players_per_client_tor: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_per_client_vpn")] + pub max_players_per_client_vpn: i32, } impl CloudMatchmakerNamespaceConfig { - /// Matchmaker configuration for a given namespace. - pub fn new( - lobby_count_max: i32, - max_players_per_client: i32, - max_players_per_client_hosting: i32, - max_players_per_client_proxy: i32, - max_players_per_client_tor: i32, - max_players_per_client_vpn: i32, - ) -> CloudMatchmakerNamespaceConfig { - CloudMatchmakerNamespaceConfig { - lobby_count_max, - max_players_per_client, - max_players_per_client_hosting, - max_players_per_client_proxy, - max_players_per_client_tor, - max_players_per_client_vpn, - } - } + /// Matchmaker configuration for a given namespace. + pub fn new(lobby_count_max: i32, max_players_per_client: i32, max_players_per_client_hosting: i32, max_players_per_client_proxy: i32, max_players_per_client_tor: i32, max_players_per_client_vpn: i32) -> CloudMatchmakerNamespaceConfig { + CloudMatchmakerNamespaceConfig { + lobby_count_max, + max_players_per_client, + max_players_per_client_hosting, + max_players_per_client_proxy, + max_players_per_client_tor, + max_players_per_client_vpn, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_namespace_config.rs b/sdks/full/rust/src/models/cloud_namespace_config.rs index 80029d1d79..7dfe67ee46 100644 --- a/sdks/full/rust/src/models/cloud_namespace_config.rs +++ b/sdks/full/rust/src/models/cloud_namespace_config.rs @@ -4,39 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudNamespaceConfig : Cloud configuration for a given namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudNamespaceConfig { - #[serde(rename = "cdn")] - pub cdn: Box, - /// Identity configuration for a given namespace. - #[serde(rename = "identity")] - pub identity: serde_json::Value, - /// KV configuration for a given namespace. - #[serde(rename = "kv")] - pub kv: serde_json::Value, - #[serde(rename = "matchmaker")] - pub matchmaker: Box, + #[serde(rename = "cdn")] + pub cdn: Box, + /// Identity configuration for a given namespace. + #[serde(rename = "identity")] + pub identity: serde_json::Value, + /// KV configuration for a given namespace. + #[serde(rename = "kv")] + pub kv: serde_json::Value, + #[serde(rename = "matchmaker")] + pub matchmaker: Box, } impl CloudNamespaceConfig { - /// Cloud configuration for a given namespace. - pub fn new( - cdn: crate::models::CloudCdnNamespaceConfig, - identity: serde_json::Value, - kv: serde_json::Value, - matchmaker: crate::models::CloudMatchmakerNamespaceConfig, - ) -> CloudNamespaceConfig { - CloudNamespaceConfig { - cdn: Box::new(cdn), - identity, - kv, - matchmaker: Box::new(matchmaker), - } - } + /// Cloud configuration for a given namespace. + pub fn new(cdn: crate::models::CloudCdnNamespaceConfig, identity: serde_json::Value, kv: serde_json::Value, matchmaker: crate::models::CloudMatchmakerNamespaceConfig) -> CloudNamespaceConfig { + CloudNamespaceConfig { + cdn: Box::new(cdn), + identity, + kv, + matchmaker: Box::new(matchmaker), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_namespace_full.rs b/sdks/full/rust/src/models/cloud_namespace_full.rs index a099ca3987..581f7008ae 100644 --- a/sdks/full/rust/src/models/cloud_namespace_full.rs +++ b/sdks/full/rust/src/models/cloud_namespace_full.rs @@ -4,48 +4,45 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudNamespaceFull : A full namespace. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudNamespaceFull { - #[serde(rename = "config")] - pub config: Box, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - #[serde(rename = "namespace_id")] - pub namespace_id: uuid::Uuid, - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + #[serde(rename = "config")] + pub config: Box, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + #[serde(rename = "namespace_id")] + pub namespace_id: uuid::Uuid, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudNamespaceFull { - /// A full namespace. - pub fn new( - config: crate::models::CloudNamespaceConfig, - create_ts: String, - display_name: String, - name_id: String, - namespace_id: uuid::Uuid, - version_id: uuid::Uuid, - ) -> CloudNamespaceFull { - CloudNamespaceFull { - config: Box::new(config), - create_ts, - display_name, - name_id, - namespace_id, - version_id, - } - } + /// A full namespace. + pub fn new(config: crate::models::CloudNamespaceConfig, create_ts: String, display_name: String, name_id: String, namespace_id: uuid::Uuid, version_id: uuid::Uuid) -> CloudNamespaceFull { + CloudNamespaceFull { + config: Box::new(config), + create_ts, + display_name, + name_id, + namespace_id, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_namespace_summary.rs b/sdks/full/rust/src/models/cloud_namespace_summary.rs index 52aaf7abaf..d7e3215a51 100644 --- a/sdks/full/rust/src/models/cloud_namespace_summary.rs +++ b/sdks/full/rust/src/models/cloud_namespace_summary.rs @@ -4,44 +4,42 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudNamespaceSummary : A namespace summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudNamespaceSummary { - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - #[serde(rename = "namespace_id")] - pub namespace_id: uuid::Uuid, - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + #[serde(rename = "namespace_id")] + pub namespace_id: uuid::Uuid, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudNamespaceSummary { - /// A namespace summary. - pub fn new( - create_ts: String, - display_name: String, - name_id: String, - namespace_id: uuid::Uuid, - version_id: uuid::Uuid, - ) -> CloudNamespaceSummary { - CloudNamespaceSummary { - create_ts, - display_name, - name_id, - namespace_id, - version_id, - } - } + /// A namespace summary. + pub fn new(create_ts: String, display_name: String, name_id: String, namespace_id: uuid::Uuid, version_id: uuid::Uuid) -> CloudNamespaceSummary { + CloudNamespaceSummary { + create_ts, + display_name, + name_id, + namespace_id, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_namespace_version.rs b/sdks/full/rust/src/models/cloud_namespace_version.rs index 16dcd05f7e..fcab3769a1 100644 --- a/sdks/full/rust/src/models/cloud_namespace_version.rs +++ b/sdks/full/rust/src/models/cloud_namespace_version.rs @@ -4,36 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudNamespaceVersion : A previously deployed namespace version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudNamespaceVersion { - /// RFC3339 timestamp - #[serde(rename = "deploy_ts")] - pub deploy_ts: String, - /// A universally unique identifier. - #[serde(rename = "namespace_id")] - pub namespace_id: String, - /// A universally unique identifier. - #[serde(rename = "version_id")] - pub version_id: String, + /// RFC3339 timestamp + #[serde(rename = "deploy_ts")] + pub deploy_ts: String, + /// A universally unique identifier. + #[serde(rename = "namespace_id")] + pub namespace_id: String, + /// A universally unique identifier. + #[serde(rename = "version_id")] + pub version_id: String, } impl CloudNamespaceVersion { - /// A previously deployed namespace version. - pub fn new( - deploy_ts: String, - namespace_id: String, - version_id: String, - ) -> CloudNamespaceVersion { - CloudNamespaceVersion { - deploy_ts, - namespace_id, - version_id, - } - } + /// A previously deployed namespace version. + pub fn new(deploy_ts: String, namespace_id: String, version_id: String) -> CloudNamespaceVersion { + CloudNamespaceVersion { + deploy_ts, + namespace_id, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_region_summary.rs b/sdks/full/rust/src/models/cloud_region_summary.rs index cd574d637c..397c9ceb8e 100644 --- a/sdks/full/rust/src/models/cloud_region_summary.rs +++ b/sdks/full/rust/src/models/cloud_region_summary.rs @@ -4,49 +4,46 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudRegionSummary : A region summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudRegionSummary { - /// The server provider of this region. - #[serde(rename = "provider")] - pub provider: String, - /// Represent a resource's readable display name. - #[serde(rename = "provider_display_name")] - pub provider_display_name: String, - /// Represent a resource's readable display name. - #[serde(rename = "region_display_name")] - pub region_display_name: String, - #[serde(rename = "region_id")] - pub region_id: uuid::Uuid, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "region_name_id")] - pub region_name_id: String, - #[serde(rename = "universal_region")] - pub universal_region: crate::models::CloudUniversalRegion, + /// The server provider of this region. + #[serde(rename = "provider")] + pub provider: String, + /// Represent a resource's readable display name. + #[serde(rename = "provider_display_name")] + pub provider_display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "region_display_name")] + pub region_display_name: String, + #[serde(rename = "region_id")] + pub region_id: uuid::Uuid, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "region_name_id")] + pub region_name_id: String, + #[serde(rename = "universal_region")] + pub universal_region: crate::models::CloudUniversalRegion, } impl CloudRegionSummary { - /// A region summary. - pub fn new( - provider: String, - provider_display_name: String, - region_display_name: String, - region_id: uuid::Uuid, - region_name_id: String, - universal_region: crate::models::CloudUniversalRegion, - ) -> CloudRegionSummary { - CloudRegionSummary { - provider, - provider_display_name, - region_display_name, - region_id, - region_name_id, - universal_region, - } - } + /// A region summary. + pub fn new(provider: String, provider_display_name: String, region_display_name: String, region_id: uuid::Uuid, region_name_id: String, universal_region: crate::models::CloudUniversalRegion) -> CloudRegionSummary { + CloudRegionSummary { + provider, + provider_display_name, + region_display_name, + region_id, + region_name_id, + universal_region, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_region_tier.rs b/sdks/full/rust/src/models/cloud_region_tier.rs index 3a4a9b32fb..7b21fb0790 100644 --- a/sdks/full/rust/src/models/cloud_region_tier.rs +++ b/sdks/full/rust/src/models/cloud_region_tier.rs @@ -4,61 +4,56 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudRegionTier : A region server tier. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudRegionTier { - /// Internet bandwidth (MB). - #[serde(rename = "bandwidth")] - pub bandwidth: i32, - /// CPU frequency (MHz). - #[serde(rename = "cpu")] - pub cpu: i32, - /// Allocated disk space (MB). - #[serde(rename = "disk")] - pub disk: i32, - /// Allocated memory (MB). - #[serde(rename = "memory")] - pub memory: i32, - /// **Deprecated** Price billed for every second this server is running (in quadrillionth USD, 1,000,000,000,000 = $1.00). - #[serde(rename = "price_per_second")] - pub price_per_second: i32, - /// Together with the numerator, denotes the portion of the CPU a given server uses. - #[serde(rename = "rivet_cores_denominator")] - pub rivet_cores_denominator: i32, - /// Together with the denominator, denotes the portion of the CPU a given server uses. - #[serde(rename = "rivet_cores_numerator")] - pub rivet_cores_numerator: i32, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "tier_name_id")] - pub tier_name_id: String, + /// Internet bandwidth (MB). + #[serde(rename = "bandwidth")] + pub bandwidth: i32, + /// CPU frequency (MHz). + #[serde(rename = "cpu")] + pub cpu: i32, + /// Allocated disk space (MB). + #[serde(rename = "disk")] + pub disk: i32, + /// Allocated memory (MB). + #[serde(rename = "memory")] + pub memory: i32, + /// **Deprecated** Price billed for every second this server is running (in quadrillionth USD, 1,000,000,000,000 = $1.00). + #[serde(rename = "price_per_second")] + pub price_per_second: i32, + /// Together with the numerator, denotes the portion of the CPU a given server uses. + #[serde(rename = "rivet_cores_denominator")] + pub rivet_cores_denominator: i32, + /// Together with the denominator, denotes the portion of the CPU a given server uses. + #[serde(rename = "rivet_cores_numerator")] + pub rivet_cores_numerator: i32, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "tier_name_id")] + pub tier_name_id: String, } impl CloudRegionTier { - /// A region server tier. - pub fn new( - bandwidth: i32, - cpu: i32, - disk: i32, - memory: i32, - price_per_second: i32, - rivet_cores_denominator: i32, - rivet_cores_numerator: i32, - tier_name_id: String, - ) -> CloudRegionTier { - CloudRegionTier { - bandwidth, - cpu, - disk, - memory, - price_per_second, - rivet_cores_denominator, - rivet_cores_numerator, - tier_name_id, - } - } + /// A region server tier. + pub fn new(bandwidth: i32, cpu: i32, disk: i32, memory: i32, price_per_second: i32, rivet_cores_denominator: i32, rivet_cores_numerator: i32, tier_name_id: String) -> CloudRegionTier { + CloudRegionTier { + bandwidth, + cpu, + disk, + memory, + price_per_second, + rivet_cores_denominator, + rivet_cores_numerator, + tier_name_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_region_tier_expenses.rs b/sdks/full/rust/src/models/cloud_region_tier_expenses.rs index 84015024eb..58daa9b4a1 100644 --- a/sdks/full/rust/src/models/cloud_region_tier_expenses.rs +++ b/sdks/full/rust/src/models/cloud_region_tier_expenses.rs @@ -4,49 +4,46 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudRegionTierExpenses : Region tier expenses. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudRegionTierExpenses { - /// Amount of expenses for this region tier (in hundred-thousandths USD, 100,000 = $1.00). - #[serde(rename = "expenses")] - pub expenses: f64, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "lobby_group_name_id")] - pub lobby_group_name_id: String, - #[serde(rename = "namespace_id")] - pub namespace_id: uuid::Uuid, - #[serde(rename = "region_id")] - pub region_id: uuid::Uuid, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "tier_name_id")] - pub tier_name_id: String, - /// How long a region tier has been active (in milliseconds). - #[serde(rename = "uptime")] - pub uptime: f64, + /// Amount of expenses for this region tier (in hundred-thousandths USD, 100,000 = $1.00). + #[serde(rename = "expenses")] + pub expenses: f64, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "lobby_group_name_id")] + pub lobby_group_name_id: String, + #[serde(rename = "namespace_id")] + pub namespace_id: uuid::Uuid, + #[serde(rename = "region_id")] + pub region_id: uuid::Uuid, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "tier_name_id")] + pub tier_name_id: String, + /// How long a region tier has been active (in milliseconds). + #[serde(rename = "uptime")] + pub uptime: f64, } impl CloudRegionTierExpenses { - /// Region tier expenses. - pub fn new( - expenses: f64, - lobby_group_name_id: String, - namespace_id: uuid::Uuid, - region_id: uuid::Uuid, - tier_name_id: String, - uptime: f64, - ) -> CloudRegionTierExpenses { - CloudRegionTierExpenses { - expenses, - lobby_group_name_id, - namespace_id, - region_id, - tier_name_id, - uptime, - } - } + /// Region tier expenses. + pub fn new(expenses: f64, lobby_group_name_id: String, namespace_id: uuid::Uuid, region_id: uuid::Uuid, tier_name_id: String, uptime: f64) -> CloudRegionTierExpenses { + CloudRegionTierExpenses { + expenses, + lobby_group_name_id, + namespace_id, + region_id, + tier_name_id, + uptime, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_svc_metrics.rs b/sdks/full/rust/src/models/cloud_svc_metrics.rs index a2fc995492..e4d5250626 100644 --- a/sdks/full/rust/src/models/cloud_svc_metrics.rs +++ b/sdks/full/rust/src/models/cloud_svc_metrics.rs @@ -4,36 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudSvcMetrics : Metrics relating to a job service. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudSvcMetrics { - /// Total allocated memory (MB). - #[serde(rename = "allocated_memory", skip_serializing_if = "Option::is_none")] - pub allocated_memory: Option, - /// CPU metrics. - #[serde(rename = "cpu")] - pub cpu: Vec, - /// The job name. - #[serde(rename = "job")] - pub job: String, - /// Memory metrics. - #[serde(rename = "memory")] - pub memory: Vec, + /// Total allocated memory (MB). + #[serde(rename = "allocated_memory", skip_serializing_if = "Option::is_none")] + pub allocated_memory: Option, + /// CPU metrics. + #[serde(rename = "cpu")] + pub cpu: Vec, + /// The job name. + #[serde(rename = "job")] + pub job: String, + /// Memory metrics. + #[serde(rename = "memory")] + pub memory: Vec, } impl CloudSvcMetrics { - /// Metrics relating to a job service. - pub fn new(cpu: Vec, job: String, memory: Vec) -> CloudSvcMetrics { - CloudSvcMetrics { - allocated_memory: None, - cpu, - job, - memory, - } - } + /// Metrics relating to a job service. + pub fn new(cpu: Vec, job: String, memory: Vec) -> CloudSvcMetrics { + CloudSvcMetrics { + allocated_memory: None, + cpu, + job, + memory, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_svc_perf.rs b/sdks/full/rust/src/models/cloud_svc_perf.rs index 0baeb61ec9..297dd08172 100644 --- a/sdks/full/rust/src/models/cloud_svc_perf.rs +++ b/sdks/full/rust/src/models/cloud_svc_perf.rs @@ -4,49 +4,47 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudSvcPerf : A service performance summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudSvcPerf { - /// Unsigned 64 bit integer. - #[serde(rename = "duration")] - pub duration: i64, - /// A list of performance marks. - #[serde(rename = "marks")] - pub marks: Vec, - #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] - pub req_id: Option, - /// A list of performance spans. - #[serde(rename = "spans")] - pub spans: Vec, - /// The name of the service. - #[serde(rename = "svc_name")] - pub svc_name: String, - /// RFC3339 timestamp - #[serde(rename = "ts")] - pub ts: String, + /// Unsigned 64 bit integer. + #[serde(rename = "duration")] + pub duration: i64, + /// A list of performance marks. + #[serde(rename = "marks")] + pub marks: Vec, + #[serde(rename = "req_id", skip_serializing_if = "Option::is_none")] + pub req_id: Option, + /// A list of performance spans. + #[serde(rename = "spans")] + pub spans: Vec, + /// The name of the service. + #[serde(rename = "svc_name")] + pub svc_name: String, + /// RFC3339 timestamp + #[serde(rename = "ts")] + pub ts: String, } impl CloudSvcPerf { - /// A service performance summary. - pub fn new( - duration: i64, - marks: Vec, - spans: Vec, - svc_name: String, - ts: String, - ) -> CloudSvcPerf { - CloudSvcPerf { - duration, - marks, - req_id: None, - spans, - svc_name, - ts, - } - } + /// A service performance summary. + pub fn new(duration: i64, marks: Vec, spans: Vec, svc_name: String, ts: String) -> CloudSvcPerf { + CloudSvcPerf { + duration, + marks, + req_id: None, + spans, + svc_name, + ts, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_universal_region.rs b/sdks/full/rust/src/models/cloud_universal_region.rs index eadba68d59..33d71d0238 100644 --- a/sdks/full/rust/src/models/cloud_universal_region.rs +++ b/sdks/full/rust/src/models/cloud_universal_region.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,101 +13,106 @@ /// **Deprecated** #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudUniversalRegion { - #[serde(rename = "unknown")] - Unknown, - #[serde(rename = "local")] - Local, - #[serde(rename = "amsterdam")] - Amsterdam, - #[serde(rename = "atlanta")] - Atlanta, - #[serde(rename = "bangalore")] - Bangalore, - #[serde(rename = "dallas")] - Dallas, - #[serde(rename = "frankfurt")] - Frankfurt, - #[serde(rename = "london")] - London, - #[serde(rename = "mumbai")] - Mumbai, - #[serde(rename = "newark")] - Newark, - #[serde(rename = "new_york_city")] - NewYorkCity, - #[serde(rename = "san_francisco")] - SanFrancisco, - #[serde(rename = "singapore")] - Singapore, - #[serde(rename = "sydney")] - Sydney, - #[serde(rename = "tokyo")] - Tokyo, - #[serde(rename = "toronto")] - Toronto, - #[serde(rename = "washington_dc")] - WashingtonDc, - #[serde(rename = "chicago")] - Chicago, - #[serde(rename = "paris")] - Paris, - #[serde(rename = "seattle")] - Seattle, - #[serde(rename = "sao_paulo")] - SaoPaulo, - #[serde(rename = "stockholm")] - Stockholm, - #[serde(rename = "chennai")] - Chennai, - #[serde(rename = "osaka")] - Osaka, - #[serde(rename = "milan")] - Milan, - #[serde(rename = "miami")] - Miami, - #[serde(rename = "jakarta")] - Jakarta, - #[serde(rename = "los_angeles")] - LosAngeles, + #[serde(rename = "unknown")] + Unknown, + #[serde(rename = "local")] + Local, + #[serde(rename = "amsterdam")] + Amsterdam, + #[serde(rename = "atlanta")] + Atlanta, + #[serde(rename = "bangalore")] + Bangalore, + #[serde(rename = "dallas")] + Dallas, + #[serde(rename = "frankfurt")] + Frankfurt, + #[serde(rename = "london")] + London, + #[serde(rename = "mumbai")] + Mumbai, + #[serde(rename = "newark")] + Newark, + #[serde(rename = "new_york_city")] + NewYorkCity, + #[serde(rename = "san_francisco")] + SanFrancisco, + #[serde(rename = "singapore")] + Singapore, + #[serde(rename = "sydney")] + Sydney, + #[serde(rename = "tokyo")] + Tokyo, + #[serde(rename = "toronto")] + Toronto, + #[serde(rename = "washington_dc")] + WashingtonDc, + #[serde(rename = "chicago")] + Chicago, + #[serde(rename = "paris")] + Paris, + #[serde(rename = "seattle")] + Seattle, + #[serde(rename = "sao_paulo")] + SaoPaulo, + #[serde(rename = "stockholm")] + Stockholm, + #[serde(rename = "chennai")] + Chennai, + #[serde(rename = "osaka")] + Osaka, + #[serde(rename = "milan")] + Milan, + #[serde(rename = "miami")] + Miami, + #[serde(rename = "jakarta")] + Jakarta, + #[serde(rename = "los_angeles")] + LosAngeles, + } impl ToString for CloudUniversalRegion { - fn to_string(&self) -> String { - match self { - Self::Unknown => String::from("unknown"), - Self::Local => String::from("local"), - Self::Amsterdam => String::from("amsterdam"), - Self::Atlanta => String::from("atlanta"), - Self::Bangalore => String::from("bangalore"), - Self::Dallas => String::from("dallas"), - Self::Frankfurt => String::from("frankfurt"), - Self::London => String::from("london"), - Self::Mumbai => String::from("mumbai"), - Self::Newark => String::from("newark"), - Self::NewYorkCity => String::from("new_york_city"), - Self::SanFrancisco => String::from("san_francisco"), - Self::Singapore => String::from("singapore"), - Self::Sydney => String::from("sydney"), - Self::Tokyo => String::from("tokyo"), - Self::Toronto => String::from("toronto"), - Self::WashingtonDc => String::from("washington_dc"), - Self::Chicago => String::from("chicago"), - Self::Paris => String::from("paris"), - Self::Seattle => String::from("seattle"), - Self::SaoPaulo => String::from("sao_paulo"), - Self::Stockholm => String::from("stockholm"), - Self::Chennai => String::from("chennai"), - Self::Osaka => String::from("osaka"), - Self::Milan => String::from("milan"), - Self::Miami => String::from("miami"), - Self::Jakarta => String::from("jakarta"), - Self::LosAngeles => String::from("los_angeles"), - } - } + fn to_string(&self) -> String { + match self { + Self::Unknown => String::from("unknown"), + Self::Local => String::from("local"), + Self::Amsterdam => String::from("amsterdam"), + Self::Atlanta => String::from("atlanta"), + Self::Bangalore => String::from("bangalore"), + Self::Dallas => String::from("dallas"), + Self::Frankfurt => String::from("frankfurt"), + Self::London => String::from("london"), + Self::Mumbai => String::from("mumbai"), + Self::Newark => String::from("newark"), + Self::NewYorkCity => String::from("new_york_city"), + Self::SanFrancisco => String::from("san_francisco"), + Self::Singapore => String::from("singapore"), + Self::Sydney => String::from("sydney"), + Self::Tokyo => String::from("tokyo"), + Self::Toronto => String::from("toronto"), + Self::WashingtonDc => String::from("washington_dc"), + Self::Chicago => String::from("chicago"), + Self::Paris => String::from("paris"), + Self::Seattle => String::from("seattle"), + Self::SaoPaulo => String::from("sao_paulo"), + Self::Stockholm => String::from("stockholm"), + Self::Chennai => String::from("chennai"), + Self::Osaka => String::from("osaka"), + Self::Milan => String::from("milan"), + Self::Miami => String::from("miami"), + Self::Jakarta => String::from("jakarta"), + Self::LosAngeles => String::from("los_angeles"), + } + } } impl Default for CloudUniversalRegion { - fn default() -> CloudUniversalRegion { - Self::Unknown - } + fn default() -> CloudUniversalRegion { + Self::Unknown + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_validate_group_request.rs b/sdks/full/rust/src/models/cloud_validate_group_request.rs index 394c6fea71..998146bdce 100644 --- a/sdks/full/rust/src/models/cloud_validate_group_request.rs +++ b/sdks/full/rust/src/models/cloud_validate_group_request.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudValidateGroupRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl CloudValidateGroupRequest { - pub fn new(display_name: String) -> CloudValidateGroupRequest { - CloudValidateGroupRequest { display_name } - } + pub fn new(display_name: String) -> CloudValidateGroupRequest { + CloudValidateGroupRequest { + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_validate_group_response.rs b/sdks/full/rust/src/models/cloud_validate_group_response.rs index a36a8f15c4..285d7b19c9 100644 --- a/sdks/full/rust/src/models/cloud_validate_group_response.rs +++ b/sdks/full/rust/src/models/cloud_validate_group_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudValidateGroupResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl CloudValidateGroupResponse { - pub fn new(errors: Vec) -> CloudValidateGroupResponse { - CloudValidateGroupResponse { errors } - } + pub fn new(errors: Vec) -> CloudValidateGroupResponse { + CloudValidateGroupResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_config.rs b/sdks/full/rust/src/models/cloud_version_cdn_config.rs index 5d4109fac7..4d3fabb0cf 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_config.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_config.rs @@ -4,39 +4,43 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionCdnConfig : CDN configuration for a given version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnConfig { - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "build_command", skip_serializing_if = "Option::is_none")] - pub build_command: Option, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "build_env", skip_serializing_if = "Option::is_none")] - pub build_env: Option<::std::collections::HashMap>, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "build_output", skip_serializing_if = "Option::is_none")] - pub build_output: Option, - /// Multiple CDN version routes. - #[serde(rename = "routes", skip_serializing_if = "Option::is_none")] - pub routes: Option>, - #[serde(rename = "site_id", skip_serializing_if = "Option::is_none")] - pub site_id: Option, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "build_command", skip_serializing_if = "Option::is_none")] + pub build_command: Option, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "build_env", skip_serializing_if = "Option::is_none")] + pub build_env: Option<::std::collections::HashMap>, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "build_output", skip_serializing_if = "Option::is_none")] + pub build_output: Option, + /// Multiple CDN version routes. + #[serde(rename = "routes", skip_serializing_if = "Option::is_none")] + pub routes: Option>, + #[serde(rename = "site_id", skip_serializing_if = "Option::is_none")] + pub site_id: Option, } impl CloudVersionCdnConfig { - /// CDN configuration for a given version. - pub fn new() -> CloudVersionCdnConfig { - CloudVersionCdnConfig { - build_command: None, - build_env: None, - build_output: None, - routes: None, - site_id: None, - } - } + /// CDN configuration for a given version. + pub fn new() -> CloudVersionCdnConfig { + CloudVersionCdnConfig { + build_command: None, + build_env: None, + build_output: None, + routes: None, + site_id: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_custom_headers_middleware.rs b/sdks/full/rust/src/models/cloud_version_cdn_custom_headers_middleware.rs index 7c6210fdfc..edcab304b2 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_custom_headers_middleware.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_custom_headers_middleware.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnCustomHeadersMiddleware { - #[serde(rename = "headers")] - pub headers: Vec, + #[serde(rename = "headers")] + pub headers: Vec, } impl CloudVersionCdnCustomHeadersMiddleware { - pub fn new( - headers: Vec, - ) -> CloudVersionCdnCustomHeadersMiddleware { - CloudVersionCdnCustomHeadersMiddleware { headers } - } + pub fn new(headers: Vec) -> CloudVersionCdnCustomHeadersMiddleware { + CloudVersionCdnCustomHeadersMiddleware { + headers, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_header.rs b/sdks/full/rust/src/models/cloud_version_cdn_header.rs index 6dd05a9aa5..c588c07e13 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_header.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_header.rs @@ -4,20 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnHeader { - #[serde(rename = "name")] - pub name: String, - #[serde(rename = "value")] - pub value: String, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "value")] + pub value: String, } impl CloudVersionCdnHeader { - pub fn new(name: String, value: String) -> CloudVersionCdnHeader { - CloudVersionCdnHeader { name, value } - } + pub fn new(name: String, value: String) -> CloudVersionCdnHeader { + CloudVersionCdnHeader { + name, + value, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_middleware.rs b/sdks/full/rust/src/models/cloud_version_cdn_middleware.rs index f7e81e7509..3a4f78a4b7 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_middleware.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_middleware.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnMiddleware { - #[serde(rename = "kind")] - pub kind: Box, + #[serde(rename = "kind")] + pub kind: Box, } impl CloudVersionCdnMiddleware { - pub fn new(kind: crate::models::CloudVersionCdnMiddlewareKind) -> CloudVersionCdnMiddleware { - CloudVersionCdnMiddleware { - kind: Box::new(kind), - } - } + pub fn new(kind: crate::models::CloudVersionCdnMiddlewareKind) -> CloudVersionCdnMiddleware { + CloudVersionCdnMiddleware { + kind: Box::new(kind), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_middleware_kind.rs b/sdks/full/rust/src/models/cloud_version_cdn_middleware_kind.rs index cc2c743870..ef872cbb4d 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_middleware_kind.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_middleware_kind.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnMiddlewareKind { - #[serde(rename = "custom_headers", skip_serializing_if = "Option::is_none")] - pub custom_headers: Option>, + #[serde(rename = "custom_headers", skip_serializing_if = "Option::is_none")] + pub custom_headers: Option>, } impl CloudVersionCdnMiddlewareKind { - pub fn new() -> CloudVersionCdnMiddlewareKind { - CloudVersionCdnMiddlewareKind { - custom_headers: None, - } - } + pub fn new() -> CloudVersionCdnMiddlewareKind { + CloudVersionCdnMiddlewareKind { + custom_headers: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_cdn_route.rs b/sdks/full/rust/src/models/cloud_version_cdn_route.rs index ca1df1edf1..5498d95a48 100644 --- a/sdks/full/rust/src/models/cloud_version_cdn_route.rs +++ b/sdks/full/rust/src/models/cloud_version_cdn_route.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionCdnRoute { - #[serde(rename = "glob")] - pub glob: String, - /// Multiple CDN version middleware. - #[serde(rename = "middlewares")] - pub middlewares: Vec, - /// Unsigned 32 bit integer. - #[serde(rename = "priority")] - pub priority: i32, + #[serde(rename = "glob")] + pub glob: String, + /// Multiple CDN version middleware. + #[serde(rename = "middlewares")] + pub middlewares: Vec, + /// Unsigned 32 bit integer. + #[serde(rename = "priority")] + pub priority: i32, } impl CloudVersionCdnRoute { - pub fn new( - glob: String, - middlewares: Vec, - priority: i32, - ) -> CloudVersionCdnRoute { - CloudVersionCdnRoute { - glob, - middlewares, - priority, - } - } + pub fn new(glob: String, middlewares: Vec, priority: i32) -> CloudVersionCdnRoute { + CloudVersionCdnRoute { + glob, + middlewares, + priority, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_config.rs b/sdks/full/rust/src/models/cloud_version_config.rs index e0ca93ee8c..7815efc02b 100644 --- a/sdks/full/rust/src/models/cloud_version_config.rs +++ b/sdks/full/rust/src/models/cloud_version_config.rs @@ -4,39 +4,43 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionConfig : Cloud configuration for a given version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionConfig { - #[serde(rename = "cdn", skip_serializing_if = "Option::is_none")] - pub cdn: Option>, - #[serde(rename = "engine", skip_serializing_if = "Option::is_none")] - pub engine: Option>, - #[serde(rename = "identity", skip_serializing_if = "Option::is_none")] - pub identity: Option>, - /// KV configuration for a given version. - #[serde(rename = "kv", skip_serializing_if = "Option::is_none")] - pub kv: Option, - #[serde(rename = "matchmaker", skip_serializing_if = "Option::is_none")] - pub matchmaker: Option>, - #[serde(rename = "scripts", skip_serializing_if = "Option::is_none")] - pub scripts: Option<::std::collections::HashMap>, + #[serde(rename = "cdn", skip_serializing_if = "Option::is_none")] + pub cdn: Option>, + #[serde(rename = "engine", skip_serializing_if = "Option::is_none")] + pub engine: Option>, + #[serde(rename = "identity", skip_serializing_if = "Option::is_none")] + pub identity: Option>, + /// KV configuration for a given version. + #[serde(rename = "kv", skip_serializing_if = "Option::is_none")] + pub kv: Option, + #[serde(rename = "matchmaker", skip_serializing_if = "Option::is_none")] + pub matchmaker: Option>, + #[serde(rename = "scripts", skip_serializing_if = "Option::is_none")] + pub scripts: Option<::std::collections::HashMap>, } impl CloudVersionConfig { - /// Cloud configuration for a given version. - pub fn new() -> CloudVersionConfig { - CloudVersionConfig { - cdn: None, - engine: None, - identity: None, - kv: None, - matchmaker: None, - scripts: None, - } - } + /// Cloud configuration for a given version. + pub fn new() -> CloudVersionConfig { + CloudVersionConfig { + cdn: None, + engine: None, + identity: None, + kv: None, + matchmaker: None, + scripts: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_engine_config.rs b/sdks/full/rust/src/models/cloud_version_engine_config.rs index b15e0422f0..19c6114c49 100644 --- a/sdks/full/rust/src/models/cloud_version_engine_config.rs +++ b/sdks/full/rust/src/models/cloud_version_engine_config.rs @@ -4,32 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionEngineConfig { - #[serde(rename = "custom", skip_serializing_if = "Option::is_none")] - pub custom: Option, - #[serde(rename = "godot", skip_serializing_if = "Option::is_none")] - pub godot: Option, - #[serde(rename = "html5", skip_serializing_if = "Option::is_none")] - pub html5: Option, - #[serde(rename = "unity", skip_serializing_if = "Option::is_none")] - pub unity: Option, - #[serde(rename = "unreal", skip_serializing_if = "Option::is_none")] - pub unreal: Option>, + #[serde(rename = "custom", skip_serializing_if = "Option::is_none")] + pub custom: Option, + #[serde(rename = "godot", skip_serializing_if = "Option::is_none")] + pub godot: Option, + #[serde(rename = "html5", skip_serializing_if = "Option::is_none")] + pub html5: Option, + #[serde(rename = "unity", skip_serializing_if = "Option::is_none")] + pub unity: Option, + #[serde(rename = "unreal", skip_serializing_if = "Option::is_none")] + pub unreal: Option>, } impl CloudVersionEngineConfig { - pub fn new() -> CloudVersionEngineConfig { - CloudVersionEngineConfig { - custom: None, - godot: None, - html5: None, - unity: None, - unreal: None, - } - } + pub fn new() -> CloudVersionEngineConfig { + CloudVersionEngineConfig { + custom: None, + godot: None, + html5: None, + unity: None, + unreal: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_engine_unreal_config.rs b/sdks/full/rust/src/models/cloud_version_engine_unreal_config.rs index c3305e692d..82c3f11211 100644 --- a/sdks/full/rust/src/models/cloud_version_engine_unreal_config.rs +++ b/sdks/full/rust/src/models/cloud_version_engine_unreal_config.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionEngineUnrealConfig { - /// Name of the Unreal module that holds the game code. This is usually the value of `$.Modules[0].Name` in the file `MyProject.unproject`. _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "game_module")] - pub game_module: String, + /// Name of the Unreal module that holds the game code. This is usually the value of `$.Modules[0].Name` in the file `MyProject.unproject`. _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "game_module")] + pub game_module: String, } impl CloudVersionEngineUnrealConfig { - pub fn new(game_module: String) -> CloudVersionEngineUnrealConfig { - CloudVersionEngineUnrealConfig { game_module } - } + pub fn new(game_module: String) -> CloudVersionEngineUnrealConfig { + CloudVersionEngineUnrealConfig { + game_module, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_full.rs b/sdks/full/rust/src/models/cloud_version_full.rs index c4ee85004b..05edda9dd6 100644 --- a/sdks/full/rust/src/models/cloud_version_full.rs +++ b/sdks/full/rust/src/models/cloud_version_full.rs @@ -4,39 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionFull : A full version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionFull { - #[serde(rename = "config")] - pub config: Box, - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + #[serde(rename = "config")] + pub config: Box, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudVersionFull { - /// A full version. - pub fn new( - config: crate::models::CloudVersionConfig, - create_ts: String, - display_name: String, - version_id: uuid::Uuid, - ) -> CloudVersionFull { - CloudVersionFull { - config: Box::new(config), - create_ts, - display_name, - version_id, - } - } + /// A full version. + pub fn new(config: crate::models::CloudVersionConfig, create_ts: String, display_name: String, version_id: uuid::Uuid) -> CloudVersionFull { + CloudVersionFull { + config: Box::new(config), + create_ts, + display_name, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_identity_config.rs b/sdks/full/rust/src/models/cloud_version_identity_config.rs index 37202c1264..386a7ddc70 100644 --- a/sdks/full/rust/src/models/cloud_version_identity_config.rs +++ b/sdks/full/rust/src/models/cloud_version_identity_config.rs @@ -4,39 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionIdentityConfig : **Deprecated** Identity configuration for a given version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionIdentityConfig { - /// **Deprecated** - #[serde(rename = "avatars", skip_serializing_if = "Option::is_none")] - pub avatars: Option>, - /// **Deprecated** - #[serde(rename = "custom_avatars", skip_serializing_if = "Option::is_none")] - pub custom_avatars: Option>, - /// **Deprecated** - #[serde( - rename = "custom_display_names", - skip_serializing_if = "Option::is_none" - )] - pub custom_display_names: Option>, - /// **Deprecated** - #[serde(rename = "display_names", skip_serializing_if = "Option::is_none")] - pub display_names: Option>, + /// **Deprecated** + #[serde(rename = "avatars", skip_serializing_if = "Option::is_none")] + pub avatars: Option>, + /// **Deprecated** + #[serde(rename = "custom_avatars", skip_serializing_if = "Option::is_none")] + pub custom_avatars: Option>, + /// **Deprecated** + #[serde(rename = "custom_display_names", skip_serializing_if = "Option::is_none")] + pub custom_display_names: Option>, + /// **Deprecated** + #[serde(rename = "display_names", skip_serializing_if = "Option::is_none")] + pub display_names: Option>, } impl CloudVersionIdentityConfig { - /// **Deprecated** Identity configuration for a given version. - pub fn new() -> CloudVersionIdentityConfig { - CloudVersionIdentityConfig { - avatars: None, - custom_avatars: None, - custom_display_names: None, - display_names: None, - } - } + /// **Deprecated** Identity configuration for a given version. + pub fn new() -> CloudVersionIdentityConfig { + CloudVersionIdentityConfig { + avatars: None, + custom_avatars: None, + custom_display_names: None, + display_names: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_identity_custom_avatar.rs b/sdks/full/rust/src/models/cloud_version_identity_custom_avatar.rs index c6a502ad7d..f096ebc61c 100644 --- a/sdks/full/rust/src/models/cloud_version_identity_custom_avatar.rs +++ b/sdks/full/rust/src/models/cloud_version_identity_custom_avatar.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionIdentityCustomAvatar { - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl CloudVersionIdentityCustomAvatar { - pub fn new(upload_id: uuid::Uuid) -> CloudVersionIdentityCustomAvatar { - CloudVersionIdentityCustomAvatar { upload_id } - } + pub fn new(upload_id: uuid::Uuid) -> CloudVersionIdentityCustomAvatar { + CloudVersionIdentityCustomAvatar { + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_identity_custom_display_name.rs b/sdks/full/rust/src/models/cloud_version_identity_custom_display_name.rs index 9f0a4efd38..8c4087fc33 100644 --- a/sdks/full/rust/src/models/cloud_version_identity_custom_display_name.rs +++ b/sdks/full/rust/src/models/cloud_version_identity_custom_display_name.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionIdentityCustomDisplayName { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl CloudVersionIdentityCustomDisplayName { - pub fn new(display_name: String) -> CloudVersionIdentityCustomDisplayName { - CloudVersionIdentityCustomDisplayName { display_name } - } + pub fn new(display_name: String) -> CloudVersionIdentityCustomDisplayName { + CloudVersionIdentityCustomDisplayName { + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha.rs index c90d667142..8db17cc3f6 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha.rs @@ -4,37 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerCaptcha : Matchmaker captcha configuration. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerCaptcha { - #[serde(rename = "hcaptcha", skip_serializing_if = "Option::is_none")] - pub hcaptcha: Option>, - /// Denotes how many requests a connection can make before it is required to reverify a captcha. - #[serde(rename = "requests_before_reverify")] - pub requests_before_reverify: i32, - #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] - pub turnstile: Option>, - /// Denotes how long a connection can continue to reconnect without having to reverify a captcha (in milliseconds). - #[serde(rename = "verification_ttl")] - pub verification_ttl: i64, + #[serde(rename = "hcaptcha", skip_serializing_if = "Option::is_none")] + pub hcaptcha: Option>, + /// Denotes how many requests a connection can make before it is required to reverify a captcha. + #[serde(rename = "requests_before_reverify")] + pub requests_before_reverify: i32, + #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] + pub turnstile: Option>, + /// Denotes how long a connection can continue to reconnect without having to reverify a captcha (in milliseconds). + #[serde(rename = "verification_ttl")] + pub verification_ttl: i64, } impl CloudVersionMatchmakerCaptcha { - /// Matchmaker captcha configuration. - pub fn new( - requests_before_reverify: i32, - verification_ttl: i64, - ) -> CloudVersionMatchmakerCaptcha { - CloudVersionMatchmakerCaptcha { - hcaptcha: None, - requests_before_reverify, - turnstile: None, - verification_ttl, - } - } + /// Matchmaker captcha configuration. + pub fn new(requests_before_reverify: i32, verification_ttl: i64) -> CloudVersionMatchmakerCaptcha { + CloudVersionMatchmakerCaptcha { + hcaptcha: None, + requests_before_reverify, + turnstile: None, + verification_ttl, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha.rs index 8cee8814fd..3154536904 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha.rs @@ -4,31 +4,35 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerCaptchaHcaptcha : hCpatcha configuration. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerCaptchaHcaptcha { - #[serde(rename = "level", skip_serializing_if = "Option::is_none")] - pub level: Option, - /// Secret key for your hCaptcha application. Must be set. - #[serde(rename = "secret_key", skip_serializing_if = "Option::is_none")] - pub secret_key: Option, - /// Site key for your hCaptcha application. Must be set. - #[serde(rename = "site_key", skip_serializing_if = "Option::is_none")] - pub site_key: Option, + #[serde(rename = "level", skip_serializing_if = "Option::is_none")] + pub level: Option, + /// Secret key for your hCaptcha application. Must be set. + #[serde(rename = "secret_key", skip_serializing_if = "Option::is_none")] + pub secret_key: Option, + /// Site key for your hCaptcha application. Must be set. + #[serde(rename = "site_key", skip_serializing_if = "Option::is_none")] + pub site_key: Option, } impl CloudVersionMatchmakerCaptchaHcaptcha { - /// hCpatcha configuration. - pub fn new() -> CloudVersionMatchmakerCaptchaHcaptcha { - CloudVersionMatchmakerCaptchaHcaptcha { - level: None, - secret_key: None, - site_key: None, - } - } + /// hCpatcha configuration. + pub fn new() -> CloudVersionMatchmakerCaptchaHcaptcha { + CloudVersionMatchmakerCaptchaHcaptcha { + level: None, + secret_key: None, + site_key: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha_level.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha_level.rs index 42679b8cd0..8eb4d54577 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha_level.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_hcaptcha_level.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,29 +13,34 @@ /// **Deprecated** How hard a captcha should be. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudVersionMatchmakerCaptchaHcaptchaLevel { - #[serde(rename = "easy")] - Easy, - #[serde(rename = "moderate")] - Moderate, - #[serde(rename = "difficult")] - Difficult, - #[serde(rename = "always_on")] - AlwaysOn, + #[serde(rename = "easy")] + Easy, + #[serde(rename = "moderate")] + Moderate, + #[serde(rename = "difficult")] + Difficult, + #[serde(rename = "always_on")] + AlwaysOn, + } impl ToString for CloudVersionMatchmakerCaptchaHcaptchaLevel { - fn to_string(&self) -> String { - match self { - Self::Easy => String::from("easy"), - Self::Moderate => String::from("moderate"), - Self::Difficult => String::from("difficult"), - Self::AlwaysOn => String::from("always_on"), - } - } + fn to_string(&self) -> String { + match self { + Self::Easy => String::from("easy"), + Self::Moderate => String::from("moderate"), + Self::Difficult => String::from("difficult"), + Self::AlwaysOn => String::from("always_on"), + } + } } impl Default for CloudVersionMatchmakerCaptchaHcaptchaLevel { - fn default() -> CloudVersionMatchmakerCaptchaHcaptchaLevel { - Self::Easy - } + fn default() -> CloudVersionMatchmakerCaptchaHcaptchaLevel { + Self::Easy + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_turnstile.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_turnstile.rs index bd7d314c8f..f4b1412810 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_turnstile.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_captcha_turnstile.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerCaptchaTurnstile : Turnstile captcha configuration. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerCaptchaTurnstile { - #[serde(rename = "secret_key")] - pub secret_key: String, - #[serde(rename = "site_key")] - pub site_key: String, + #[serde(rename = "secret_key")] + pub secret_key: String, + #[serde(rename = "site_key")] + pub site_key: String, } impl CloudVersionMatchmakerCaptchaTurnstile { - /// Turnstile captcha configuration. - pub fn new(secret_key: String, site_key: String) -> CloudVersionMatchmakerCaptchaTurnstile { - CloudVersionMatchmakerCaptchaTurnstile { - secret_key, - site_key, - } - } + /// Turnstile captcha configuration. + pub fn new(secret_key: String, site_key: String) -> CloudVersionMatchmakerCaptchaTurnstile { + CloudVersionMatchmakerCaptchaTurnstile { + secret_key, + site_key, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_config.rs index d3e793b84b..407acf78b8 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_config.rs @@ -4,59 +4,60 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerConfig : Matchmaker configuration for a given version. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerConfig { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "dev_hostname", skip_serializing_if = "Option::is_none")] - pub dev_hostname: Option, - #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] - pub docker: Option>, - /// A list of game modes. - #[serde(rename = "game_modes", skip_serializing_if = "Option::is_none")] - pub game_modes: - Option<::std::collections::HashMap>, - #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] - pub idle_lobbies: Option>, - /// **Deprecated: use `game_modes` instead** A list of game modes. - #[serde(rename = "lobby_groups", skip_serializing_if = "Option::is_none")] - pub lobby_groups: Option>, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde(rename = "max_players_direct", skip_serializing_if = "Option::is_none")] - pub max_players_direct: Option, - #[serde(rename = "max_players_party", skip_serializing_if = "Option::is_none")] - pub max_players_party: Option, - #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] - pub regions: Option< - ::std::collections::HashMap, - >, - #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] - pub tier: Option, + #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] + pub captcha: Option>, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "dev_hostname", skip_serializing_if = "Option::is_none")] + pub dev_hostname: Option, + #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] + pub docker: Option>, + /// A list of game modes. + #[serde(rename = "game_modes", skip_serializing_if = "Option::is_none")] + pub game_modes: Option<::std::collections::HashMap>, + #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] + pub idle_lobbies: Option>, + /// **Deprecated: use `game_modes` instead** A list of game modes. + #[serde(rename = "lobby_groups", skip_serializing_if = "Option::is_none")] + pub lobby_groups: Option>, + #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] + pub max_players: Option, + #[serde(rename = "max_players_direct", skip_serializing_if = "Option::is_none")] + pub max_players_direct: Option, + #[serde(rename = "max_players_party", skip_serializing_if = "Option::is_none")] + pub max_players_party: Option, + #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] + pub regions: Option<::std::collections::HashMap>, + #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] + pub tier: Option, } impl CloudVersionMatchmakerConfig { - /// Matchmaker configuration for a given version. - pub fn new() -> CloudVersionMatchmakerConfig { - CloudVersionMatchmakerConfig { - captcha: None, - dev_hostname: None, - docker: None, - game_modes: None, - idle_lobbies: None, - lobby_groups: None, - max_players: None, - max_players_direct: None, - max_players_party: None, - regions: None, - tier: None, - } - } + /// Matchmaker configuration for a given version. + pub fn new() -> CloudVersionMatchmakerConfig { + CloudVersionMatchmakerConfig { + captcha: None, + dev_hostname: None, + docker: None, + game_modes: None, + idle_lobbies: None, + lobby_groups: None, + max_players: None, + max_players_direct: None, + max_players_party: None, + regions: None, + tier: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode.rs index 5e4bb6c0cf..07698268ca 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode.rs @@ -4,58 +4,57 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameMode : A game mode. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameMode { - #[serde(rename = "actions", skip_serializing_if = "Option::is_none")] - pub actions: Option>, - #[serde( - rename = "allow_dynamic_max_players", - skip_serializing_if = "Option::is_none" - )] - pub allow_dynamic_max_players: Option, - #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] - pub docker: Option>, - #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] - pub idle_lobbies: Option>, - #[serde(rename = "listable", skip_serializing_if = "Option::is_none")] - pub listable: Option, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde(rename = "max_players_direct", skip_serializing_if = "Option::is_none")] - pub max_players_direct: Option, - #[serde(rename = "max_players_party", skip_serializing_if = "Option::is_none")] - pub max_players_party: Option, - #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] - pub regions: Option< - ::std::collections::HashMap, - >, - #[serde(rename = "taggable", skip_serializing_if = "Option::is_none")] - pub taggable: Option, - #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] - pub tier: Option, + #[serde(rename = "actions", skip_serializing_if = "Option::is_none")] + pub actions: Option>, + #[serde(rename = "allow_dynamic_max_players", skip_serializing_if = "Option::is_none")] + pub allow_dynamic_max_players: Option, + #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] + pub docker: Option>, + #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] + pub idle_lobbies: Option>, + #[serde(rename = "listable", skip_serializing_if = "Option::is_none")] + pub listable: Option, + #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] + pub max_players: Option, + #[serde(rename = "max_players_direct", skip_serializing_if = "Option::is_none")] + pub max_players_direct: Option, + #[serde(rename = "max_players_party", skip_serializing_if = "Option::is_none")] + pub max_players_party: Option, + #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] + pub regions: Option<::std::collections::HashMap>, + #[serde(rename = "taggable", skip_serializing_if = "Option::is_none")] + pub taggable: Option, + #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] + pub tier: Option, } impl CloudVersionMatchmakerGameMode { - /// A game mode. - pub fn new() -> CloudVersionMatchmakerGameMode { - CloudVersionMatchmakerGameMode { - actions: None, - allow_dynamic_max_players: None, - docker: None, - idle_lobbies: None, - listable: None, - max_players: None, - max_players_direct: None, - max_players_party: None, - regions: None, - taggable: None, - tier: None, - } - } + /// A game mode. + pub fn new() -> CloudVersionMatchmakerGameMode { + CloudVersionMatchmakerGameMode { + actions: None, + allow_dynamic_max_players: None, + docker: None, + idle_lobbies: None, + listable: None, + max_players: None, + max_players_direct: None, + max_players_party: None, + regions: None, + taggable: None, + tier: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_actions.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_actions.rs index d6690de743..3a1e7c4258 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_actions.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_actions.rs @@ -4,29 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeActions : Configuration for the connection types allowed for a game mode. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeActions { - #[serde(rename = "create", skip_serializing_if = "Option::is_none")] - pub create: Option>, - #[serde(rename = "find", skip_serializing_if = "Option::is_none")] - pub find: Option>, - #[serde(rename = "join", skip_serializing_if = "Option::is_none")] - pub join: Option>, + #[serde(rename = "create", skip_serializing_if = "Option::is_none")] + pub create: Option>, + #[serde(rename = "find", skip_serializing_if = "Option::is_none")] + pub find: Option>, + #[serde(rename = "join", skip_serializing_if = "Option::is_none")] + pub join: Option>, } impl CloudVersionMatchmakerGameModeActions { - /// Configuration for the connection types allowed for a game mode. - pub fn new() -> CloudVersionMatchmakerGameModeActions { - CloudVersionMatchmakerGameModeActions { - create: None, - find: None, - join: None, - } - } + /// Configuration for the connection types allowed for a game mode. + pub fn new() -> CloudVersionMatchmakerGameModeActions { + CloudVersionMatchmakerGameModeActions { + create: None, + find: None, + join: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_create_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_create_config.rs index 85d3896fc4..de1ecfcea3 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_create_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_create_config.rs @@ -4,49 +4,46 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeCreateConfig : Configures the requirements and authentication for the /create endpoint. If this value is not set in the config, the /create endpoint is NOT enabled. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeCreateConfig { - /// Defaults to true when unset. - #[serde(rename = "enable_private", skip_serializing_if = "Option::is_none")] - pub enable_private: Option, - /// Defaults to false when unset. - #[serde(rename = "enable_public", skip_serializing_if = "Option::is_none")] - pub enable_public: Option, - /// Sets whether or not the /create endpoint is enabled. - #[serde(rename = "enabled")] - pub enabled: bool, - #[serde( - rename = "identity_requirement", - skip_serializing_if = "Option::is_none" - )] - pub identity_requirement: - Option, - /// **Deprecated** - #[serde( - rename = "max_lobbies_per_identity", - skip_serializing_if = "Option::is_none" - )] - pub max_lobbies_per_identity: Option, - #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] - pub verification: Option>, + /// Defaults to true when unset. + #[serde(rename = "enable_private", skip_serializing_if = "Option::is_none")] + pub enable_private: Option, + /// Defaults to false when unset. + #[serde(rename = "enable_public", skip_serializing_if = "Option::is_none")] + pub enable_public: Option, + /// Sets whether or not the /create endpoint is enabled. + #[serde(rename = "enabled")] + pub enabled: bool, + #[serde(rename = "identity_requirement", skip_serializing_if = "Option::is_none")] + pub identity_requirement: Option, + /// **Deprecated** + #[serde(rename = "max_lobbies_per_identity", skip_serializing_if = "Option::is_none")] + pub max_lobbies_per_identity: Option, + #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] + pub verification: Option>, } impl CloudVersionMatchmakerGameModeCreateConfig { - /// Configures the requirements and authentication for the /create endpoint. If this value is not set in the config, the /create endpoint is NOT enabled. - pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeCreateConfig { - CloudVersionMatchmakerGameModeCreateConfig { - enable_private: None, - enable_public: None, - enabled, - identity_requirement: None, - max_lobbies_per_identity: None, - verification: None, - } - } + /// Configures the requirements and authentication for the /create endpoint. If this value is not set in the config, the /create endpoint is NOT enabled. + pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeCreateConfig { + CloudVersionMatchmakerGameModeCreateConfig { + enable_private: None, + enable_public: None, + enabled, + identity_requirement: None, + max_lobbies_per_identity: None, + verification: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_find_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_find_config.rs index 983711b3e0..93bbfc3fcf 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_find_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_find_config.rs @@ -4,34 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeFindConfig : Configures the requirements and authentication for the /find endpoint. If this value is not set in the config, the /find endpoint is still enabled. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeFindConfig { - /// Sets whether or not the /find endpoint is enabled. - #[serde(rename = "enabled")] - pub enabled: bool, - #[serde( - rename = "identity_requirement", - skip_serializing_if = "Option::is_none" - )] - pub identity_requirement: - Option, - #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] - pub verification: Option>, + /// Sets whether or not the /find endpoint is enabled. + #[serde(rename = "enabled")] + pub enabled: bool, + #[serde(rename = "identity_requirement", skip_serializing_if = "Option::is_none")] + pub identity_requirement: Option, + #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] + pub verification: Option>, } impl CloudVersionMatchmakerGameModeFindConfig { - /// Configures the requirements and authentication for the /find endpoint. If this value is not set in the config, the /find endpoint is still enabled. - pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeFindConfig { - CloudVersionMatchmakerGameModeFindConfig { - enabled, - identity_requirement: None, - verification: None, - } - } + /// Configures the requirements and authentication for the /find endpoint. If this value is not set in the config, the /find endpoint is still enabled. + pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeFindConfig { + CloudVersionMatchmakerGameModeFindConfig { + enabled, + identity_requirement: None, + verification: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_identity_requirement.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_identity_requirement.rs index 230ae04efa..e72e5b25a9 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_identity_requirement.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_identity_requirement.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,26 +13,31 @@ /// **Deprecated** The registration requirement for a user when joining/finding/creating a lobby. \"None\" allows for connections without an identity. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudVersionMatchmakerGameModeIdentityRequirement { - #[serde(rename = "none")] - None, - #[serde(rename = "guest")] - Guest, - #[serde(rename = "registered")] - Registered, + #[serde(rename = "none")] + None, + #[serde(rename = "guest")] + Guest, + #[serde(rename = "registered")] + Registered, + } impl ToString for CloudVersionMatchmakerGameModeIdentityRequirement { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::Guest => String::from("guest"), - Self::Registered => String::from("registered"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::Guest => String::from("guest"), + Self::Registered => String::from("registered"), + } + } } impl Default for CloudVersionMatchmakerGameModeIdentityRequirement { - fn default() -> CloudVersionMatchmakerGameModeIdentityRequirement { - Self::None - } + fn default() -> CloudVersionMatchmakerGameModeIdentityRequirement { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_idle_lobbies_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_idle_lobbies_config.rs index 27d347bf86..0b4bea341e 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_idle_lobbies_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_idle_lobbies_config.rs @@ -4,23 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeIdleLobbiesConfig : Configuration for how many idle lobbies a game version should have. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeIdleLobbiesConfig { - #[serde(rename = "max")] - pub max: i32, - #[serde(rename = "min")] - pub min: i32, + #[serde(rename = "max")] + pub max: i32, + #[serde(rename = "min")] + pub min: i32, } impl CloudVersionMatchmakerGameModeIdleLobbiesConfig { - /// Configuration for how many idle lobbies a game version should have. - pub fn new(max: i32, min: i32) -> CloudVersionMatchmakerGameModeIdleLobbiesConfig { - CloudVersionMatchmakerGameModeIdleLobbiesConfig { max, min } - } + /// Configuration for how many idle lobbies a game version should have. + pub fn new(max: i32, min: i32) -> CloudVersionMatchmakerGameModeIdleLobbiesConfig { + CloudVersionMatchmakerGameModeIdleLobbiesConfig { + max, + min, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_join_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_join_config.rs index 59c3612561..471835d937 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_join_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_join_config.rs @@ -4,34 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeJoinConfig : Configures the requirements and authentication for the /join endpoint. If this value is not set in the config, the /join endpoint is still enabled. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeJoinConfig { - /// Sets whether or not the /join endpoint is enabled. - #[serde(rename = "enabled")] - pub enabled: bool, - #[serde( - rename = "identity_requirement", - skip_serializing_if = "Option::is_none" - )] - pub identity_requirement: - Option, - #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] - pub verification: Option>, + /// Sets whether or not the /join endpoint is enabled. + #[serde(rename = "enabled")] + pub enabled: bool, + #[serde(rename = "identity_requirement", skip_serializing_if = "Option::is_none")] + pub identity_requirement: Option, + #[serde(rename = "verification", skip_serializing_if = "Option::is_none")] + pub verification: Option>, } impl CloudVersionMatchmakerGameModeJoinConfig { - /// Configures the requirements and authentication for the /join endpoint. If this value is not set in the config, the /join endpoint is still enabled. - pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeJoinConfig { - CloudVersionMatchmakerGameModeJoinConfig { - enabled, - identity_requirement: None, - verification: None, - } - } + /// Configures the requirements and authentication for the /join endpoint. If this value is not set in the config, the /join endpoint is still enabled. + pub fn new(enabled: bool) -> CloudVersionMatchmakerGameModeJoinConfig { + CloudVersionMatchmakerGameModeJoinConfig { + enabled, + identity_requirement: None, + verification: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_region.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_region.rs index 61aa12558a..bb1c3aa23d 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_region.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_region.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeRegion : A game mode region. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeRegion { - #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] - pub idle_lobbies: Option>, - #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] - pub tier: Option, + #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] + pub idle_lobbies: Option>, + #[serde(rename = "tier", skip_serializing_if = "Option::is_none")] + pub tier: Option, } impl CloudVersionMatchmakerGameModeRegion { - /// A game mode region. - pub fn new() -> CloudVersionMatchmakerGameModeRegion { - CloudVersionMatchmakerGameModeRegion { - idle_lobbies: None, - tier: None, - } - } + /// A game mode region. + pub fn new() -> CloudVersionMatchmakerGameModeRegion { + CloudVersionMatchmakerGameModeRegion { + idle_lobbies: None, + tier: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker.rs index 9ad013bdaa..d94ccdb29f 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker.rs @@ -4,52 +4,51 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeRuntimeDocker : A game mode runtime running through Docker. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeRuntimeDocker { - #[serde(rename = "args", skip_serializing_if = "Option::is_none")] - pub args: Option>, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "build_args", skip_serializing_if = "Option::is_none")] - pub build_args: Option<::std::collections::HashMap>, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "dockerfile", skip_serializing_if = "Option::is_none")] - pub dockerfile: Option, - #[serde(rename = "env", skip_serializing_if = "Option::is_none")] - pub env: Option<::std::collections::HashMap>, - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "image", skip_serializing_if = "Option::is_none")] - pub image: Option, - #[serde(rename = "image_id", skip_serializing_if = "Option::is_none")] - pub image_id: Option, - #[serde(rename = "network_mode", skip_serializing_if = "Option::is_none")] - pub network_mode: Option, - #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] - pub ports: Option< - ::std::collections::HashMap< - String, - crate::models::CloudVersionMatchmakerGameModeRuntimeDockerPort, - >, - >, + #[serde(rename = "args", skip_serializing_if = "Option::is_none")] + pub args: Option>, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "build_args", skip_serializing_if = "Option::is_none")] + pub build_args: Option<::std::collections::HashMap>, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "dockerfile", skip_serializing_if = "Option::is_none")] + pub dockerfile: Option, + #[serde(rename = "env", skip_serializing_if = "Option::is_none")] + pub env: Option<::std::collections::HashMap>, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "image", skip_serializing_if = "Option::is_none")] + pub image: Option, + #[serde(rename = "image_id", skip_serializing_if = "Option::is_none")] + pub image_id: Option, + #[serde(rename = "network_mode", skip_serializing_if = "Option::is_none")] + pub network_mode: Option, + #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] + pub ports: Option<::std::collections::HashMap>, } impl CloudVersionMatchmakerGameModeRuntimeDocker { - /// A game mode runtime running through Docker. - pub fn new() -> CloudVersionMatchmakerGameModeRuntimeDocker { - CloudVersionMatchmakerGameModeRuntimeDocker { - args: None, - build_args: None, - dockerfile: None, - env: None, - image: None, - image_id: None, - network_mode: None, - ports: None, - } - } + /// A game mode runtime running through Docker. + pub fn new() -> CloudVersionMatchmakerGameModeRuntimeDocker { + CloudVersionMatchmakerGameModeRuntimeDocker { + args: None, + build_args: None, + dockerfile: None, + env: None, + image: None, + image_id: None, + network_mode: None, + ports: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker_port.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker_port.rs index 6a61b5ca41..27660b0f01 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker_port.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_runtime_docker_port.rs @@ -4,43 +4,47 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeRuntimeDockerPort : Port config for a docker build. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeRuntimeDockerPort { - /// _Configures Rivet CLI behavior. Has no effect on server behavior._ - #[serde(rename = "dev_port", skip_serializing_if = "Option::is_none")] - pub dev_port: Option, - #[serde(rename = "dev_port_range", skip_serializing_if = "Option::is_none")] - pub dev_port_range: Option>, - #[serde(rename = "dev_protocol", skip_serializing_if = "Option::is_none")] - pub dev_protocol: Option, - /// The port number to connect to. ### Related - cloud.version.matchmaker.PortProtocol - cloud.version.matchmaker.ProxyKind - #[serde(rename = "port", skip_serializing_if = "Option::is_none")] - pub port: Option, - #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] - pub port_range: Option>, - #[serde(rename = "protocol", skip_serializing_if = "Option::is_none")] - pub protocol: Option, - #[serde(rename = "proxy", skip_serializing_if = "Option::is_none")] - pub proxy: Option, + /// _Configures Rivet CLI behavior. Has no effect on server behavior._ + #[serde(rename = "dev_port", skip_serializing_if = "Option::is_none")] + pub dev_port: Option, + #[serde(rename = "dev_port_range", skip_serializing_if = "Option::is_none")] + pub dev_port_range: Option>, + #[serde(rename = "dev_protocol", skip_serializing_if = "Option::is_none")] + pub dev_protocol: Option, + /// The port number to connect to. ### Related - cloud.version.matchmaker.PortProtocol - cloud.version.matchmaker.ProxyKind + #[serde(rename = "port", skip_serializing_if = "Option::is_none")] + pub port: Option, + #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] + pub port_range: Option>, + #[serde(rename = "protocol", skip_serializing_if = "Option::is_none")] + pub protocol: Option, + #[serde(rename = "proxy", skip_serializing_if = "Option::is_none")] + pub proxy: Option, } impl CloudVersionMatchmakerGameModeRuntimeDockerPort { - /// Port config for a docker build. - pub fn new() -> CloudVersionMatchmakerGameModeRuntimeDockerPort { - CloudVersionMatchmakerGameModeRuntimeDockerPort { - dev_port: None, - dev_port_range: None, - dev_protocol: None, - port: None, - port_range: None, - protocol: None, - proxy: None, - } - } + /// Port config for a docker build. + pub fn new() -> CloudVersionMatchmakerGameModeRuntimeDockerPort { + CloudVersionMatchmakerGameModeRuntimeDockerPort { + dev_port: None, + dev_port_range: None, + dev_protocol: None, + port: None, + port_range: None, + protocol: None, + proxy: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_verification_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_verification_config.rs index 2311a9be1c..306ca5d409 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_verification_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_game_mode_verification_config.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerGameModeVerificationConfig : Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the `verification_data` property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerGameModeVerificationConfig { - #[serde(rename = "headers")] - pub headers: ::std::collections::HashMap, - #[serde(rename = "url")] - pub url: String, + #[serde(rename = "headers")] + pub headers: ::std::collections::HashMap, + #[serde(rename = "url")] + pub url: String, } impl CloudVersionMatchmakerGameModeVerificationConfig { - /// Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the `verification_data` property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not. - pub fn new( - headers: ::std::collections::HashMap, - url: String, - ) -> CloudVersionMatchmakerGameModeVerificationConfig { - CloudVersionMatchmakerGameModeVerificationConfig { headers, url } - } + /// Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the `verification_data` property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not. + pub fn new(headers: ::std::collections::HashMap, url: String) -> CloudVersionMatchmakerGameModeVerificationConfig { + CloudVersionMatchmakerGameModeVerificationConfig { + headers, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group.rs index ec57cf0ed4..fdc1f740a4 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group.rs @@ -4,50 +4,47 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroup : A game mode. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroup { - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_direct")] - pub max_players_direct: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_normal")] - pub max_players_normal: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "max_players_party")] - pub max_players_party: i32, - /// **Deprecated: use GameMode instead** A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - /// A list of game mode regions. - #[serde(rename = "regions")] - pub regions: Vec, - #[serde(rename = "runtime")] - pub runtime: Box, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_direct")] + pub max_players_direct: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_normal")] + pub max_players_normal: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_players_party")] + pub max_players_party: i32, + /// **Deprecated: use GameMode instead** A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + /// A list of game mode regions. + #[serde(rename = "regions")] + pub regions: Vec, + #[serde(rename = "runtime")] + pub runtime: Box, } impl CloudVersionMatchmakerLobbyGroup { - /// A game mode. - pub fn new( - max_players_direct: i32, - max_players_normal: i32, - max_players_party: i32, - name_id: String, - regions: Vec, - runtime: crate::models::CloudVersionMatchmakerLobbyGroupRuntime, - ) -> CloudVersionMatchmakerLobbyGroup { - CloudVersionMatchmakerLobbyGroup { - max_players_direct, - max_players_normal, - max_players_party, - name_id, - regions, - runtime: Box::new(runtime), - } - } + /// A game mode. + pub fn new(max_players_direct: i32, max_players_normal: i32, max_players_party: i32, name_id: String, regions: Vec, runtime: crate::models::CloudVersionMatchmakerLobbyGroupRuntime) -> CloudVersionMatchmakerLobbyGroup { + CloudVersionMatchmakerLobbyGroup { + max_players_direct, + max_players_normal, + max_players_party, + name_id, + regions, + runtime: Box::new(runtime), + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_idle_lobbies_config.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_idle_lobbies_config.rs index f956cf2423..f6a1279fe0 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_idle_lobbies_config.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_idle_lobbies_config.rs @@ -4,31 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig : **Deprecated: use GameMode instead** Configuration for how many idle lobbies a game version should have. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { - /// Unsigned 32 bit integer. - #[serde(rename = "max_idle_lobbies")] - pub max_idle_lobbies: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "min_idle_lobbies")] - pub min_idle_lobbies: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max_idle_lobbies")] + pub max_idle_lobbies: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "min_idle_lobbies")] + pub min_idle_lobbies: i32, } impl CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { - /// **Deprecated: use GameMode instead** Configuration for how many idle lobbies a game version should have. - pub fn new( - max_idle_lobbies: i32, - min_idle_lobbies: i32, - ) -> CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { - CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { - max_idle_lobbies, - min_idle_lobbies, - } - } + /// **Deprecated: use GameMode instead** Configuration for how many idle lobbies a game version should have. + pub fn new(max_idle_lobbies: i32, min_idle_lobbies: i32) -> CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { + CloudVersionMatchmakerLobbyGroupIdleLobbiesConfig { + max_idle_lobbies, + min_idle_lobbies, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_region.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_region.rs index 3ac192f979..fd8dd5d457 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_region.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_region.rs @@ -4,33 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupRegion : **Deprecated: use GameMode instead** A game mode region. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupRegion { - #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] - pub idle_lobbies: Option>, - #[serde(rename = "region_id")] - pub region_id: uuid::Uuid, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "tier_name_id")] - pub tier_name_id: String, + #[serde(rename = "idle_lobbies", skip_serializing_if = "Option::is_none")] + pub idle_lobbies: Option>, + #[serde(rename = "region_id")] + pub region_id: uuid::Uuid, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "tier_name_id")] + pub tier_name_id: String, } impl CloudVersionMatchmakerLobbyGroupRegion { - /// **Deprecated: use GameMode instead** A game mode region. - pub fn new( - region_id: uuid::Uuid, - tier_name_id: String, - ) -> CloudVersionMatchmakerLobbyGroupRegion { - CloudVersionMatchmakerLobbyGroupRegion { - idle_lobbies: None, - region_id, - tier_name_id, - } - } + /// **Deprecated: use GameMode instead** A game mode region. + pub fn new(region_id: uuid::Uuid, tier_name_id: String) -> CloudVersionMatchmakerLobbyGroupRegion { + CloudVersionMatchmakerLobbyGroupRegion { + idle_lobbies: None, + region_id, + tier_name_id, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime.rs index c8c5d51a73..1c6df44b6c 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime.rs @@ -4,21 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupRuntime : **Deprecated: use GameMode instead** A union representing the runtime a game mode runs on. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupRuntime { - #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] - pub docker: Option>, + #[serde(rename = "docker", skip_serializing_if = "Option::is_none")] + pub docker: Option>, } impl CloudVersionMatchmakerLobbyGroupRuntime { - /// **Deprecated: use GameMode instead** A union representing the runtime a game mode runs on. - pub fn new() -> CloudVersionMatchmakerLobbyGroupRuntime { - CloudVersionMatchmakerLobbyGroupRuntime { docker: None } - } + /// **Deprecated: use GameMode instead** A union representing the runtime a game mode runs on. + pub fn new() -> CloudVersionMatchmakerLobbyGroupRuntime { + CloudVersionMatchmakerLobbyGroupRuntime { + docker: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker.rs index 23e51de78b..3b7abf858c 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker.rs @@ -4,39 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupRuntimeDocker : **Deprecated: use GameMode instead** A game mode runtime running through Docker. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupRuntimeDocker { - #[serde(rename = "args")] - pub args: Vec, - #[serde(rename = "build_id", skip_serializing_if = "Option::is_none")] - pub build_id: Option, - #[serde(rename = "env_vars")] - pub env_vars: Vec, - #[serde(rename = "network_mode", skip_serializing_if = "Option::is_none")] - pub network_mode: Option, - #[serde(rename = "ports")] - pub ports: Vec, + #[serde(rename = "args")] + pub args: Vec, + #[serde(rename = "build_id", skip_serializing_if = "Option::is_none")] + pub build_id: Option, + #[serde(rename = "env_vars")] + pub env_vars: Vec, + #[serde(rename = "network_mode", skip_serializing_if = "Option::is_none")] + pub network_mode: Option, + #[serde(rename = "ports")] + pub ports: Vec, } impl CloudVersionMatchmakerLobbyGroupRuntimeDocker { - /// **Deprecated: use GameMode instead** A game mode runtime running through Docker. - pub fn new( - args: Vec, - env_vars: Vec, - ports: Vec, - ) -> CloudVersionMatchmakerLobbyGroupRuntimeDocker { - CloudVersionMatchmakerLobbyGroupRuntimeDocker { - args, - build_id: None, - env_vars, - network_mode: None, - ports, - } - } + /// **Deprecated: use GameMode instead** A game mode runtime running through Docker. + pub fn new(args: Vec, env_vars: Vec, ports: Vec) -> CloudVersionMatchmakerLobbyGroupRuntimeDocker { + CloudVersionMatchmakerLobbyGroupRuntimeDocker { + args, + build_id: None, + env_vars, + network_mode: None, + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_env_var.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_env_var.rs index 3c7c8a6d0e..7deb9e1a6e 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_env_var.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_env_var.rs @@ -4,23 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar : **Deprecated: use GameMode instead** A docker environment variable. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { - #[serde(rename = "key")] - pub key: String, - #[serde(rename = "value")] - pub value: String, + #[serde(rename = "key")] + pub key: String, + #[serde(rename = "value")] + pub value: String, } impl CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { - /// **Deprecated: use GameMode instead** A docker environment variable. - pub fn new(key: String, value: String) -> CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { - CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { key, value } - } + /// **Deprecated: use GameMode instead** A docker environment variable. + pub fn new(key: String, value: String) -> CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { + CloudVersionMatchmakerLobbyGroupRuntimeDockerEnvVar { + key, + value, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_port.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_port.rs index e9e71af610..33e4251a44 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_port.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_lobby_group_runtime_docker_port.rs @@ -4,37 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerLobbyGroupRuntimeDockerPort : **Deprecated: use GameMode instead** A docker port. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { - /// The label of this docker port. - #[serde(rename = "label")] - pub label: String, - #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] - pub port_range: Option>, - #[serde(rename = "proxy_protocol")] - pub proxy_protocol: crate::models::CloudVersionMatchmakerPortProtocol, - /// The port number to connect to. - #[serde(rename = "target_port", skip_serializing_if = "Option::is_none")] - pub target_port: Option, + /// The label of this docker port. + #[serde(rename = "label")] + pub label: String, + #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] + pub port_range: Option>, + #[serde(rename = "proxy_protocol")] + pub proxy_protocol: crate::models::CloudVersionMatchmakerPortProtocol, + /// The port number to connect to. + #[serde(rename = "target_port", skip_serializing_if = "Option::is_none")] + pub target_port: Option, } impl CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { - /// **Deprecated: use GameMode instead** A docker port. - pub fn new( - label: String, - proxy_protocol: crate::models::CloudVersionMatchmakerPortProtocol, - ) -> CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { - CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { - label, - port_range: None, - proxy_protocol, - target_port: None, - } - } + /// **Deprecated: use GameMode instead** A docker port. + pub fn new(label: String, proxy_protocol: crate::models::CloudVersionMatchmakerPortProtocol) -> CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { + CloudVersionMatchmakerLobbyGroupRuntimeDockerPort { + label, + port_range: None, + proxy_protocol, + target_port: None, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_network_mode.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_network_mode.rs index 9622bea2bd..01ac9c3c9e 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_network_mode.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_network_mode.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// Configures how the container's network is isolated from the host. `bridge` (default) networking isolates the container's network from the host & other containers. `host` networking removes isolation between the container and the host. Only available in Rivet Open Source & Enterprise. Read more about bridge vs host networking [here](https://rivet.gg/docs/dynamic-servers/concepts/host-bridge-networking). #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudVersionMatchmakerNetworkMode { - #[serde(rename = "bridge")] - Bridge, - #[serde(rename = "host")] - Host, + #[serde(rename = "bridge")] + Bridge, + #[serde(rename = "host")] + Host, + } impl ToString for CloudVersionMatchmakerNetworkMode { - fn to_string(&self) -> String { - match self { - Self::Bridge => String::from("bridge"), - Self::Host => String::from("host"), - } - } + fn to_string(&self) -> String { + match self { + Self::Bridge => String::from("bridge"), + Self::Host => String::from("host"), + } + } } impl Default for CloudVersionMatchmakerNetworkMode { - fn default() -> CloudVersionMatchmakerNetworkMode { - Self::Bridge - } + fn default() -> CloudVersionMatchmakerNetworkMode { + Self::Bridge + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_port_protocol.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_port_protocol.rs index c051284dec..50d9809f63 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_port_protocol.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_port_protocol.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,32 +13,37 @@ /// Signifies the protocol of the port. Note that when proxying through GameGuard (via `ProxyKind`), the port number returned by `/find`, `/join`, and `/create` will not be the same as the port number configured in the config: - With HTTP, the port will always be 80. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server. - With HTTPS, the port will always be 443. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server. - Using TCP/UDP, the port will be a random number between 26000 and 31999. This gets automatically routed to the correct port being used by the game server. ### Related - cloud.version.matchmaker.GameModeRuntimeDockerPort - cloud.version.matchmaker.ProxyKind - /docs/dynamic-servers/concepts/game-guard - matchmaker.lobbies.find #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudVersionMatchmakerPortProtocol { - #[serde(rename = "http")] - Http, - #[serde(rename = "https")] - Https, - #[serde(rename = "tcp")] - Tcp, - #[serde(rename = "tcp_tls")] - TcpTls, - #[serde(rename = "udp")] - Udp, + #[serde(rename = "http")] + Http, + #[serde(rename = "https")] + Https, + #[serde(rename = "tcp")] + Tcp, + #[serde(rename = "tcp_tls")] + TcpTls, + #[serde(rename = "udp")] + Udp, + } impl ToString for CloudVersionMatchmakerPortProtocol { - fn to_string(&self) -> String { - match self { - Self::Http => String::from("http"), - Self::Https => String::from("https"), - Self::Tcp => String::from("tcp"), - Self::TcpTls => String::from("tcp_tls"), - Self::Udp => String::from("udp"), - } - } + fn to_string(&self) -> String { + match self { + Self::Http => String::from("http"), + Self::Https => String::from("https"), + Self::Tcp => String::from("tcp"), + Self::TcpTls => String::from("tcp_tls"), + Self::Udp => String::from("udp"), + } + } } impl Default for CloudVersionMatchmakerPortProtocol { - fn default() -> CloudVersionMatchmakerPortProtocol { - Self::Http - } + fn default() -> CloudVersionMatchmakerPortProtocol { + Self::Http + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_port_range.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_port_range.rs index d79b40a65c..97b716690d 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_port_range.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_port_range.rs @@ -4,25 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionMatchmakerPortRange : Range of ports that can be connected to. If configured, `network_mode` must equal `host`. Port ranges may overlap between containers, it is the responsibility of the developer to ensure ports are available before using. Read more about host networking [here](https://rivet.gg/docs/dynamic-servers/concepts/host-bridge-networking). Only available on Rivet Open Source & Enterprise. ### Related - cloud.version.matchmaker.PortProtocol - cloud.version.matchmaker.ProxyKind + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionMatchmakerPortRange { - /// Unsigned 32 bit integer. - #[serde(rename = "max")] - pub max: i32, - /// Unsigned 32 bit integer. - #[serde(rename = "min")] - pub min: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "max")] + pub max: i32, + /// Unsigned 32 bit integer. + #[serde(rename = "min")] + pub min: i32, } impl CloudVersionMatchmakerPortRange { - /// Range of ports that can be connected to. If configured, `network_mode` must equal `host`. Port ranges may overlap between containers, it is the responsibility of the developer to ensure ports are available before using. Read more about host networking [here](https://rivet.gg/docs/dynamic-servers/concepts/host-bridge-networking). Only available on Rivet Open Source & Enterprise. ### Related - cloud.version.matchmaker.PortProtocol - cloud.version.matchmaker.ProxyKind - pub fn new(max: i32, min: i32) -> CloudVersionMatchmakerPortRange { - CloudVersionMatchmakerPortRange { max, min } - } + /// Range of ports that can be connected to. If configured, `network_mode` must equal `host`. Port ranges may overlap between containers, it is the responsibility of the developer to ensure ports are available before using. Read more about host networking [here](https://rivet.gg/docs/dynamic-servers/concepts/host-bridge-networking). Only available on Rivet Open Source & Enterprise. ### Related - cloud.version.matchmaker.PortProtocol - cloud.version.matchmaker.ProxyKind + pub fn new(max: i32, min: i32) -> CloudVersionMatchmakerPortRange { + CloudVersionMatchmakerPortRange { + max, + min, + } + } } + + diff --git a/sdks/full/rust/src/models/cloud_version_matchmaker_proxy_kind.rs b/sdks/full/rust/src/models/cloud_version_matchmaker_proxy_kind.rs index f102ccd44e..f2d1f0de49 100644 --- a/sdks/full/rust/src/models/cloud_version_matchmaker_proxy_kind.rs +++ b/sdks/full/rust/src/models/cloud_version_matchmaker_proxy_kind.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// Range of ports that can be connected to. `game_guard` (default) proxies all traffic through [Game Guard](https://rivet.gg/docs/dynamic-servers/concepts/game-guard) to mitigate DDoS attacks and provide TLS termination. `none` sends traffic directly to the game server. If configured, `network_mode` must equal `host`. Read more about host networking [here](https://rivet.gg/docs/dynamic-servers/concepts/host-bridge-networking). Only available on Rivet Open Source & Enterprise. ### Related - /docs/dynamic-servers/concepts/game-guard - cloud.version.matchmaker.PortProtocol #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum CloudVersionMatchmakerProxyKind { - #[serde(rename = "none")] - None, - #[serde(rename = "game_guard")] - GameGuard, + #[serde(rename = "none")] + None, + #[serde(rename = "game_guard")] + GameGuard, + } impl ToString for CloudVersionMatchmakerProxyKind { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::GameGuard => String::from("game_guard"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::GameGuard => String::from("game_guard"), + } + } } impl Default for CloudVersionMatchmakerProxyKind { - fn default() -> CloudVersionMatchmakerProxyKind { - Self::None - } + fn default() -> CloudVersionMatchmakerProxyKind { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/cloud_version_summary.rs b/sdks/full/rust/src/models/cloud_version_summary.rs index d0b9e99e48..52f47690d2 100644 --- a/sdks/full/rust/src/models/cloud_version_summary.rs +++ b/sdks/full/rust/src/models/cloud_version_summary.rs @@ -4,35 +4,35 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// CloudVersionSummary : A version summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CloudVersionSummary { - /// RFC3339 timestamp - #[serde(rename = "create_ts")] - pub create_ts: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "version_id")] - pub version_id: uuid::Uuid, + /// RFC3339 timestamp + #[serde(rename = "create_ts")] + pub create_ts: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "version_id")] + pub version_id: uuid::Uuid, } impl CloudVersionSummary { - /// A version summary. - pub fn new( - create_ts: String, - display_name: String, - version_id: uuid::Uuid, - ) -> CloudVersionSummary { - CloudVersionSummary { - create_ts, - display_name, - version_id, - } - } + /// A version summary. + pub fn new(create_ts: String, display_name: String, version_id: uuid::Uuid) -> CloudVersionSummary { + CloudVersionSummary { + create_ts, + display_name, + version_id, + } + } } + + diff --git a/sdks/full/rust/src/models/error_body.rs b/sdks/full/rust/src/models/error_body.rs index eccffc0d94..1ad1d62334 100644 --- a/sdks/full/rust/src/models/error_body.rs +++ b/sdks/full/rust/src/models/error_body.rs @@ -4,38 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ErrorBody { - #[serde(rename = "code")] - pub code: String, - #[serde(rename = "documentation", skip_serializing_if = "Option::is_none")] - pub documentation: Option, - #[serde(rename = "message")] - pub message: String, - /// Unstructured metadata relating to an error. Must be manually parsed. - #[serde( - rename = "metadata", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub metadata: Option>, - #[serde(rename = "ray_id")] - pub ray_id: String, + #[serde(rename = "code")] + pub code: String, + #[serde(rename = "documentation", skip_serializing_if = "Option::is_none")] + pub documentation: Option, + #[serde(rename = "message")] + pub message: String, + /// Unstructured metadata relating to an error. Must be manually parsed. + #[serde(rename = "metadata", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub metadata: Option>, + #[serde(rename = "ray_id")] + pub ray_id: String, } impl ErrorBody { - pub fn new(code: String, message: String, ray_id: String) -> ErrorBody { - ErrorBody { - code, - documentation: None, - message, - metadata: None, - ray_id, - } - } + pub fn new(code: String, message: String, ray_id: String) -> ErrorBody { + ErrorBody { + code, + documentation: None, + message, + metadata: None, + ray_id, + } + } } + + diff --git a/sdks/full/rust/src/models/game_handle.rs b/sdks/full/rust/src/models/game_handle.rs index 930e573ccc..346a1b6a6e 100644 --- a/sdks/full/rust/src/models/game_handle.rs +++ b/sdks/full/rust/src/models/game_handle.rs @@ -4,36 +4,41 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameHandle { - /// The URL of this game's banner image. - #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] - pub banner_url: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, - /// The URL of this game's logo image. - #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] - pub logo_url: Option, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, + /// The URL of this game's banner image. + #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] + pub banner_url: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, + /// The URL of this game's logo image. + #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] + pub logo_url: Option, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, } impl GameHandle { - pub fn new(display_name: String, game_id: uuid::Uuid, name_id: String) -> GameHandle { - GameHandle { - banner_url: None, - display_name, - game_id, - logo_url: None, - name_id, - } - } + pub fn new(display_name: String, game_id: uuid::Uuid, name_id: String) -> GameHandle { + GameHandle { + banner_url: None, + display_name, + game_id, + logo_url: None, + name_id, + } + } } + + diff --git a/sdks/full/rust/src/models/game_leaderboard_category.rs b/sdks/full/rust/src/models/game_leaderboard_category.rs index 187d93ebe0..29cb86fe4e 100644 --- a/sdks/full/rust/src/models/game_leaderboard_category.rs +++ b/sdks/full/rust/src/models/game_leaderboard_category.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GameLeaderboardCategory : A game leaderboard category. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameLeaderboardCategory { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl GameLeaderboardCategory { - /// A game leaderboard category. - pub fn new(display_name: String) -> GameLeaderboardCategory { - GameLeaderboardCategory { display_name } - } + /// A game leaderboard category. + pub fn new(display_name: String) -> GameLeaderboardCategory { + GameLeaderboardCategory { + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/game_platform_link.rs b/sdks/full/rust/src/models/game_platform_link.rs index 7b117be70c..f8a8591e22 100644 --- a/sdks/full/rust/src/models/game_platform_link.rs +++ b/sdks/full/rust/src/models/game_platform_link.rs @@ -4,25 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GamePlatformLink : A platform link denoting a supported platform. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GamePlatformLink { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// The URL to the given game's method of distribution on this platform. - #[serde(rename = "url")] - pub url: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// The URL to the given game's method of distribution on this platform. + #[serde(rename = "url")] + pub url: String, } impl GamePlatformLink { - /// A platform link denoting a supported platform. - pub fn new(display_name: String, url: String) -> GamePlatformLink { - GamePlatformLink { display_name, url } - } + /// A platform link denoting a supported platform. + pub fn new(display_name: String, url: String) -> GamePlatformLink { + GamePlatformLink { + display_name, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/game_profile.rs b/sdks/full/rust/src/models/game_profile.rs index 97e790e6e7..4fd3a3dfdb 100644 --- a/sdks/full/rust/src/models/game_profile.rs +++ b/sdks/full/rust/src/models/game_profile.rs @@ -4,82 +4,74 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GameProfile : A game profile. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameProfile { - /// The URL of this game's banner image. - #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] - pub banner_url: Option, - /// A description of the given game. - #[serde(rename = "description")] - pub description: String, - #[serde(rename = "developer")] - pub developer: Box, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, - /// A list of game leaderboard categories. - #[serde(rename = "group_leaderboard_categories")] - pub group_leaderboard_categories: Vec, - /// A list of game leaderboard categories. - #[serde(rename = "identity_leaderboard_categories")] - pub identity_leaderboard_categories: Vec, - /// The URL of this game's logo image. - #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] - pub logo_url: Option, - /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - /// A list of platform links. - #[serde(rename = "platforms")] - pub platforms: Vec, - /// A list of group summaries. - #[serde(rename = "recommended_groups")] - pub recommended_groups: Vec, - /// A list of game tags. - #[serde(rename = "tags")] - pub tags: Vec, - /// The URL to this game's website. - #[serde(rename = "url")] - pub url: String, + /// The URL of this game's banner image. + #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] + pub banner_url: Option, + /// A description of the given game. + #[serde(rename = "description")] + pub description: String, + #[serde(rename = "developer")] + pub developer: Box, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, + /// A list of game leaderboard categories. + #[serde(rename = "group_leaderboard_categories")] + pub group_leaderboard_categories: Vec, + /// A list of game leaderboard categories. + #[serde(rename = "identity_leaderboard_categories")] + pub identity_leaderboard_categories: Vec, + /// The URL of this game's logo image. + #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] + pub logo_url: Option, + /// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + /// A list of platform links. + #[serde(rename = "platforms")] + pub platforms: Vec, + /// A list of group summaries. + #[serde(rename = "recommended_groups")] + pub recommended_groups: Vec, + /// A list of game tags. + #[serde(rename = "tags")] + pub tags: Vec, + /// The URL to this game's website. + #[serde(rename = "url")] + pub url: String, } impl GameProfile { - /// A game profile. - pub fn new( - description: String, - developer: crate::models::GroupSummary, - display_name: String, - game_id: uuid::Uuid, - group_leaderboard_categories: Vec, - identity_leaderboard_categories: Vec, - name_id: String, - platforms: Vec, - recommended_groups: Vec, - tags: Vec, - url: String, - ) -> GameProfile { - GameProfile { - banner_url: None, - description, - developer: Box::new(developer), - display_name, - game_id, - group_leaderboard_categories, - identity_leaderboard_categories, - logo_url: None, - name_id, - platforms, - recommended_groups, - tags, - url, - } - } + /// A game profile. + pub fn new(description: String, developer: crate::models::GroupSummary, display_name: String, game_id: uuid::Uuid, group_leaderboard_categories: Vec, identity_leaderboard_categories: Vec, name_id: String, platforms: Vec, recommended_groups: Vec, tags: Vec, url: String) -> GameProfile { + GameProfile { + banner_url: None, + description, + developer: Box::new(developer), + display_name, + game_id, + group_leaderboard_categories, + identity_leaderboard_categories, + logo_url: None, + name_id, + platforms, + recommended_groups, + tags, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/game_stat.rs b/sdks/full/rust/src/models/game_stat.rs index ddc881a2fb..d9fbbfe2d1 100644 --- a/sdks/full/rust/src/models/game_stat.rs +++ b/sdks/full/rust/src/models/game_stat.rs @@ -4,27 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GameStat : A game statistic. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameStat { - #[serde(rename = "config")] - pub config: Box, - /// A single overall value of the given statistic. - #[serde(rename = "overall_value")] - pub overall_value: f64, + #[serde(rename = "config")] + pub config: Box, + /// A single overall value of the given statistic. + #[serde(rename = "overall_value")] + pub overall_value: f64, } impl GameStat { - /// A game statistic. - pub fn new(config: crate::models::GameStatConfig, overall_value: f64) -> GameStat { - GameStat { - config: Box::new(config), - overall_value, - } - } + /// A game statistic. + pub fn new(config: crate::models::GameStatConfig, overall_value: f64) -> GameStat { + GameStat { + config: Box::new(config), + overall_value, + } + } } + + diff --git a/sdks/full/rust/src/models/game_stat_aggregation_method.rs b/sdks/full/rust/src/models/game_stat_aggregation_method.rs index 6f39077c88..7f11571aa2 100644 --- a/sdks/full/rust/src/models/game_stat_aggregation_method.rs +++ b/sdks/full/rust/src/models/game_stat_aggregation_method.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,29 +13,34 @@ /// A value denoting the aggregation method of a game statistic. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum GameStatAggregationMethod { - #[serde(rename = "sum")] - Sum, - #[serde(rename = "average")] - Average, - #[serde(rename = "min")] - Min, - #[serde(rename = "max")] - Max, + #[serde(rename = "sum")] + Sum, + #[serde(rename = "average")] + Average, + #[serde(rename = "min")] + Min, + #[serde(rename = "max")] + Max, + } impl ToString for GameStatAggregationMethod { - fn to_string(&self) -> String { - match self { - Self::Sum => String::from("sum"), - Self::Average => String::from("average"), - Self::Min => String::from("min"), - Self::Max => String::from("max"), - } - } + fn to_string(&self) -> String { + match self { + Self::Sum => String::from("sum"), + Self::Average => String::from("average"), + Self::Min => String::from("min"), + Self::Max => String::from("max"), + } + } } impl Default for GameStatAggregationMethod { - fn default() -> GameStatAggregationMethod { - Self::Sum - } + fn default() -> GameStatAggregationMethod { + Self::Sum + } } + + + + diff --git a/sdks/full/rust/src/models/game_stat_config.rs b/sdks/full/rust/src/models/game_stat_config.rs index 6df69b3d04..f9c47ec3b2 100644 --- a/sdks/full/rust/src/models/game_stat_config.rs +++ b/sdks/full/rust/src/models/game_stat_config.rs @@ -4,66 +4,62 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GameStatConfig : A game statistic config. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameStatConfig { - #[serde(rename = "aggregation")] - pub aggregation: crate::models::GameStatAggregationMethod, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "format")] - pub format: crate::models::GameStatFormatMethod, - #[serde(rename = "icon_id")] - pub icon_id: uuid::Uuid, - /// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**. - #[serde(rename = "postfix_plural", skip_serializing_if = "Option::is_none")] - pub postfix_plural: Option, - /// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**. - #[serde(rename = "postfix_singular", skip_serializing_if = "Option::is_none")] - pub postfix_singular: Option, - /// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45. - #[serde(rename = "prefix_plural", skip_serializing_if = "Option::is_none")] - pub prefix_plural: Option, - /// A string appended to the beginning of a singular game statistic's value. Example: **value** 1. - #[serde(rename = "prefix_singular", skip_serializing_if = "Option::is_none")] - pub prefix_singular: Option, - #[serde(rename = "priority")] - pub priority: i32, - #[serde(rename = "record_id")] - pub record_id: uuid::Uuid, - #[serde(rename = "sorting")] - pub sorting: crate::models::GameStatSortingMethod, + #[serde(rename = "aggregation")] + pub aggregation: crate::models::GameStatAggregationMethod, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "format")] + pub format: crate::models::GameStatFormatMethod, + #[serde(rename = "icon_id")] + pub icon_id: uuid::Uuid, + /// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**. + #[serde(rename = "postfix_plural", skip_serializing_if = "Option::is_none")] + pub postfix_plural: Option, + /// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**. + #[serde(rename = "postfix_singular", skip_serializing_if = "Option::is_none")] + pub postfix_singular: Option, + /// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45. + #[serde(rename = "prefix_plural", skip_serializing_if = "Option::is_none")] + pub prefix_plural: Option, + /// A string appended to the beginning of a singular game statistic's value. Example: **value** 1. + #[serde(rename = "prefix_singular", skip_serializing_if = "Option::is_none")] + pub prefix_singular: Option, + #[serde(rename = "priority")] + pub priority: i32, + #[serde(rename = "record_id")] + pub record_id: uuid::Uuid, + #[serde(rename = "sorting")] + pub sorting: crate::models::GameStatSortingMethod, } impl GameStatConfig { - /// A game statistic config. - pub fn new( - aggregation: crate::models::GameStatAggregationMethod, - display_name: String, - format: crate::models::GameStatFormatMethod, - icon_id: uuid::Uuid, - priority: i32, - record_id: uuid::Uuid, - sorting: crate::models::GameStatSortingMethod, - ) -> GameStatConfig { - GameStatConfig { - aggregation, - display_name, - format, - icon_id, - postfix_plural: None, - postfix_singular: None, - prefix_plural: None, - prefix_singular: None, - priority, - record_id, - sorting, - } - } + /// A game statistic config. + pub fn new(aggregation: crate::models::GameStatAggregationMethod, display_name: String, format: crate::models::GameStatFormatMethod, icon_id: uuid::Uuid, priority: i32, record_id: uuid::Uuid, sorting: crate::models::GameStatSortingMethod) -> GameStatConfig { + GameStatConfig { + aggregation, + display_name, + format, + icon_id, + postfix_plural: None, + postfix_singular: None, + prefix_plural: None, + prefix_singular: None, + priority, + record_id, + sorting, + } + } } + + diff --git a/sdks/full/rust/src/models/game_stat_format_method.rs b/sdks/full/rust/src/models/game_stat_format_method.rs index bbeb74d568..7340afdf6e 100644 --- a/sdks/full/rust/src/models/game_stat_format_method.rs +++ b/sdks/full/rust/src/models/game_stat_format_method.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,38 +13,43 @@ /// A value denoting the format method of a game statistic. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum GameStatFormatMethod { - #[serde(rename = "integer")] - Integer, - #[serde(rename = "float_1")] - Float1, - #[serde(rename = "float_2")] - Float2, - #[serde(rename = "float_3")] - Float3, - #[serde(rename = "duration_minute")] - DurationMinute, - #[serde(rename = "duration_second")] - DurationSecond, - #[serde(rename = "duration_hundredth_second")] - DurationHundredthSecond, + #[serde(rename = "integer")] + Integer, + #[serde(rename = "float_1")] + Float1, + #[serde(rename = "float_2")] + Float2, + #[serde(rename = "float_3")] + Float3, + #[serde(rename = "duration_minute")] + DurationMinute, + #[serde(rename = "duration_second")] + DurationSecond, + #[serde(rename = "duration_hundredth_second")] + DurationHundredthSecond, + } impl ToString for GameStatFormatMethod { - fn to_string(&self) -> String { - match self { - Self::Integer => String::from("integer"), - Self::Float1 => String::from("float_1"), - Self::Float2 => String::from("float_2"), - Self::Float3 => String::from("float_3"), - Self::DurationMinute => String::from("duration_minute"), - Self::DurationSecond => String::from("duration_second"), - Self::DurationHundredthSecond => String::from("duration_hundredth_second"), - } - } + fn to_string(&self) -> String { + match self { + Self::Integer => String::from("integer"), + Self::Float1 => String::from("float_1"), + Self::Float2 => String::from("float_2"), + Self::Float3 => String::from("float_3"), + Self::DurationMinute => String::from("duration_minute"), + Self::DurationSecond => String::from("duration_second"), + Self::DurationHundredthSecond => String::from("duration_hundredth_second"), + } + } } impl Default for GameStatFormatMethod { - fn default() -> GameStatFormatMethod { - Self::Integer - } + fn default() -> GameStatFormatMethod { + Self::Integer + } } + + + + diff --git a/sdks/full/rust/src/models/game_stat_sorting_method.rs b/sdks/full/rust/src/models/game_stat_sorting_method.rs index 88fdf54b02..695fcf70a6 100644 --- a/sdks/full/rust/src/models/game_stat_sorting_method.rs +++ b/sdks/full/rust/src/models/game_stat_sorting_method.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// A value denoting the sorting method of a game statistic. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum GameStatSortingMethod { - #[serde(rename = "desc")] - Desc, - #[serde(rename = "asc")] - Asc, + #[serde(rename = "desc")] + Desc, + #[serde(rename = "asc")] + Asc, + } impl ToString for GameStatSortingMethod { - fn to_string(&self) -> String { - match self { - Self::Desc => String::from("desc"), - Self::Asc => String::from("asc"), - } - } + fn to_string(&self) -> String { + match self { + Self::Desc => String::from("desc"), + Self::Asc => String::from("asc"), + } + } } impl Default for GameStatSortingMethod { - fn default() -> GameStatSortingMethod { - Self::Desc - } + fn default() -> GameStatSortingMethod { + Self::Desc + } } + + + + diff --git a/sdks/full/rust/src/models/game_stat_summary.rs b/sdks/full/rust/src/models/game_stat_summary.rs index 443355d4ce..1d1a267675 100644 --- a/sdks/full/rust/src/models/game_stat_summary.rs +++ b/sdks/full/rust/src/models/game_stat_summary.rs @@ -4,29 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GameStatSummary : A game statistic summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameStatSummary { - #[serde(rename = "game")] - pub game: Box, - #[serde(rename = "stats")] - pub stats: Vec, + #[serde(rename = "game")] + pub game: Box, + #[serde(rename = "stats")] + pub stats: Vec, } impl GameStatSummary { - /// A game statistic summary. - pub fn new( - game: crate::models::GameHandle, - stats: Vec, - ) -> GameStatSummary { - GameStatSummary { - game: Box::new(game), - stats, - } - } + /// A game statistic summary. + pub fn new(game: crate::models::GameHandle, stats: Vec) -> GameStatSummary { + GameStatSummary { + game: Box::new(game), + stats, + } + } } + + diff --git a/sdks/full/rust/src/models/game_summary.rs b/sdks/full/rust/src/models/game_summary.rs index 61e9ec4f4c..88d337f3db 100644 --- a/sdks/full/rust/src/models/game_summary.rs +++ b/sdks/full/rust/src/models/game_summary.rs @@ -4,53 +4,51 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GameSummary { - /// The URL of this game's banner image. - #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] - pub banner_url: Option, - #[serde(rename = "developer")] - pub developer: Box, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, - /// The URL of this game's logo image. - #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] - pub logo_url: Option, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "name_id")] - pub name_id: String, - /// Unsigned 32 bit integer. - #[serde(rename = "total_player_count")] - pub total_player_count: i32, - #[serde(rename = "url")] - pub url: String, + /// The URL of this game's banner image. + #[serde(rename = "banner_url", skip_serializing_if = "Option::is_none")] + pub banner_url: Option, + #[serde(rename = "developer")] + pub developer: Box, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, + /// The URL of this game's logo image. + #[serde(rename = "logo_url", skip_serializing_if = "Option::is_none")] + pub logo_url: Option, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "name_id")] + pub name_id: String, + /// Unsigned 32 bit integer. + #[serde(rename = "total_player_count")] + pub total_player_count: i32, + #[serde(rename = "url")] + pub url: String, } impl GameSummary { - pub fn new( - developer: crate::models::GroupHandle, - display_name: String, - game_id: uuid::Uuid, - name_id: String, - total_player_count: i32, - url: String, - ) -> GameSummary { - GameSummary { - banner_url: None, - developer: Box::new(developer), - display_name, - game_id, - logo_url: None, - name_id, - total_player_count, - url, - } - } + pub fn new(developer: crate::models::GroupHandle, display_name: String, game_id: uuid::Uuid, name_id: String, total_player_count: i32, url: String) -> GameSummary { + GameSummary { + banner_url: None, + developer: Box::new(developer), + display_name, + game_id, + logo_url: None, + name_id, + total_player_count, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/games_environments_create_service_token_response.rs b/sdks/full/rust/src/models/games_environments_create_service_token_response.rs index f139fee460..fb7f482fce 100644 --- a/sdks/full/rust/src/models/games_environments_create_service_token_response.rs +++ b/sdks/full/rust/src/models/games_environments_create_service_token_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GamesEnvironmentsCreateServiceTokenResponse { - /// A JSON Web Token. - #[serde(rename = "token")] - pub token: String, + /// A JSON Web Token. + #[serde(rename = "token")] + pub token: String, } impl GamesEnvironmentsCreateServiceTokenResponse { - pub fn new(token: String) -> GamesEnvironmentsCreateServiceTokenResponse { - GamesEnvironmentsCreateServiceTokenResponse { token } - } + pub fn new(token: String) -> GamesEnvironmentsCreateServiceTokenResponse { + GamesEnvironmentsCreateServiceTokenResponse { + token, + } + } } + + diff --git a/sdks/full/rust/src/models/geo_coord.rs b/sdks/full/rust/src/models/geo_coord.rs index 54c01a7bfb..6ebb7e3346 100644 --- a/sdks/full/rust/src/models/geo_coord.rs +++ b/sdks/full/rust/src/models/geo_coord.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GeoCoord : Geographical coordinates for a location on Planet Earth. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GeoCoord { - #[serde(rename = "latitude")] - pub latitude: f64, - #[serde(rename = "longitude")] - pub longitude: f64, + #[serde(rename = "latitude")] + pub latitude: f64, + #[serde(rename = "longitude")] + pub longitude: f64, } impl GeoCoord { - /// Geographical coordinates for a location on Planet Earth. - pub fn new(latitude: f64, longitude: f64) -> GeoCoord { - GeoCoord { - latitude, - longitude, - } - } + /// Geographical coordinates for a location on Planet Earth. + pub fn new(latitude: f64, longitude: f64) -> GeoCoord { + GeoCoord { + latitude, + longitude, + } + } } + + diff --git a/sdks/full/rust/src/models/geo_distance.rs b/sdks/full/rust/src/models/geo_distance.rs index d4373b1057..19b1f82bf0 100644 --- a/sdks/full/rust/src/models/geo_distance.rs +++ b/sdks/full/rust/src/models/geo_distance.rs @@ -4,23 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GeoDistance : Distance available in multiple units. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GeoDistance { - #[serde(rename = "kilometers")] - pub kilometers: f64, - #[serde(rename = "miles")] - pub miles: f64, + #[serde(rename = "kilometers")] + pub kilometers: f64, + #[serde(rename = "miles")] + pub miles: f64, } impl GeoDistance { - /// Distance available in multiple units. - pub fn new(kilometers: f64, miles: f64) -> GeoDistance { - GeoDistance { kilometers, miles } - } + /// Distance available in multiple units. + pub fn new(kilometers: f64, miles: f64) -> GeoDistance { + GeoDistance { + kilometers, + miles, + } + } } + + diff --git a/sdks/full/rust/src/models/global_event_notification.rs b/sdks/full/rust/src/models/global_event_notification.rs index 242c904a7b..d0ff0d22ee 100644 --- a/sdks/full/rust/src/models/global_event_notification.rs +++ b/sdks/full/rust/src/models/global_event_notification.rs @@ -4,34 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GlobalEventNotification { - #[serde(rename = "description")] - pub description: String, - #[serde(rename = "thumbnail_url")] - pub thumbnail_url: String, - #[serde(rename = "title")] - pub title: String, - #[serde(rename = "url")] - pub url: String, + #[serde(rename = "description")] + pub description: String, + #[serde(rename = "thumbnail_url")] + pub thumbnail_url: String, + #[serde(rename = "title")] + pub title: String, + #[serde(rename = "url")] + pub url: String, } impl GlobalEventNotification { - pub fn new( - description: String, - thumbnail_url: String, - title: String, - url: String, - ) -> GlobalEventNotification { - GlobalEventNotification { - description, - thumbnail_url, - title, - url, - } - } + pub fn new(description: String, thumbnail_url: String, title: String, url: String) -> GlobalEventNotification { + GlobalEventNotification { + description, + thumbnail_url, + title, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/group_banned_identity.rs b/sdks/full/rust/src/models/group_banned_identity.rs index 429b9368a4..2e552da163 100644 --- a/sdks/full/rust/src/models/group_banned_identity.rs +++ b/sdks/full/rust/src/models/group_banned_identity.rs @@ -4,27 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupBannedIdentity : A banned identity. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupBannedIdentity { - /// RFC3339 timestamp - #[serde(rename = "ban_ts")] - pub ban_ts: String, - #[serde(rename = "identity")] - pub identity: Box, + /// RFC3339 timestamp + #[serde(rename = "ban_ts")] + pub ban_ts: String, + #[serde(rename = "identity")] + pub identity: Box, } impl GroupBannedIdentity { - /// A banned identity. - pub fn new(ban_ts: String, identity: crate::models::IdentityHandle) -> GroupBannedIdentity { - GroupBannedIdentity { - ban_ts, - identity: Box::new(identity), - } - } + /// A banned identity. + pub fn new(ban_ts: String, identity: crate::models::IdentityHandle) -> GroupBannedIdentity { + GroupBannedIdentity { + ban_ts, + identity: Box::new(identity), + } + } } + + diff --git a/sdks/full/rust/src/models/group_consume_invite_response.rs b/sdks/full/rust/src/models/group_consume_invite_response.rs index ac423b29e5..fe68dce2b4 100644 --- a/sdks/full/rust/src/models/group_consume_invite_response.rs +++ b/sdks/full/rust/src/models/group_consume_invite_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupConsumeInviteResponse { - #[serde(rename = "group_id", skip_serializing_if = "Option::is_none")] - pub group_id: Option, + #[serde(rename = "group_id", skip_serializing_if = "Option::is_none")] + pub group_id: Option, } impl GroupConsumeInviteResponse { - pub fn new() -> GroupConsumeInviteResponse { - GroupConsumeInviteResponse { group_id: None } - } + pub fn new() -> GroupConsumeInviteResponse { + GroupConsumeInviteResponse { + group_id: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_create_invite_request.rs b/sdks/full/rust/src/models/group_create_invite_request.rs index 2c19fd9fd0..c4a59e94e5 100644 --- a/sdks/full/rust/src/models/group_create_invite_request.rs +++ b/sdks/full/rust/src/models/group_create_invite_request.rs @@ -4,25 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupCreateInviteRequest { - /// How long until the group invite expires (in milliseconds). - #[serde(rename = "ttl", skip_serializing_if = "Option::is_none")] - pub ttl: Option, - /// How many times the group invite can be used. - #[serde(rename = "use_count", skip_serializing_if = "Option::is_none")] - pub use_count: Option, + /// How long until the group invite expires (in milliseconds). + #[serde(rename = "ttl", skip_serializing_if = "Option::is_none")] + pub ttl: Option, + /// How many times the group invite can be used. + #[serde(rename = "use_count", skip_serializing_if = "Option::is_none")] + pub use_count: Option, } impl GroupCreateInviteRequest { - pub fn new() -> GroupCreateInviteRequest { - GroupCreateInviteRequest { - ttl: None, - use_count: None, - } - } + pub fn new() -> GroupCreateInviteRequest { + GroupCreateInviteRequest { + ttl: None, + use_count: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_create_invite_response.rs b/sdks/full/rust/src/models/group_create_invite_response.rs index adf04e61e5..47edeb56b1 100644 --- a/sdks/full/rust/src/models/group_create_invite_response.rs +++ b/sdks/full/rust/src/models/group_create_invite_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupCreateInviteResponse { - /// The code that will be passed to `rivet.api.group#ConsumeInvite` to join a group. - #[serde(rename = "code")] - pub code: String, + /// The code that will be passed to `rivet.api.group#ConsumeInvite` to join a group. + #[serde(rename = "code")] + pub code: String, } impl GroupCreateInviteResponse { - pub fn new(code: String) -> GroupCreateInviteResponse { - GroupCreateInviteResponse { code } - } + pub fn new(code: String) -> GroupCreateInviteResponse { + GroupCreateInviteResponse { + code, + } + } } + + diff --git a/sdks/full/rust/src/models/group_create_request.rs b/sdks/full/rust/src/models/group_create_request.rs index 1ee55bb191..503c9ce897 100644 --- a/sdks/full/rust/src/models/group_create_request.rs +++ b/sdks/full/rust/src/models/group_create_request.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupCreateRequest { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, } impl GroupCreateRequest { - pub fn new(display_name: String) -> GroupCreateRequest { - GroupCreateRequest { display_name } - } + pub fn new(display_name: String) -> GroupCreateRequest { + GroupCreateRequest { + display_name, + } + } } + + diff --git a/sdks/full/rust/src/models/group_create_response.rs b/sdks/full/rust/src/models/group_create_response.rs index ea200e8016..f31960ece8 100644 --- a/sdks/full/rust/src/models/group_create_response.rs +++ b/sdks/full/rust/src/models/group_create_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupCreateResponse { - #[serde(rename = "group_id")] - pub group_id: uuid::Uuid, + #[serde(rename = "group_id")] + pub group_id: uuid::Uuid, } impl GroupCreateResponse { - pub fn new(group_id: uuid::Uuid) -> GroupCreateResponse { - GroupCreateResponse { group_id } - } + pub fn new(group_id: uuid::Uuid) -> GroupCreateResponse { + GroupCreateResponse { + group_id, + } + } } + + diff --git a/sdks/full/rust/src/models/group_external_links.rs b/sdks/full/rust/src/models/group_external_links.rs index 6ae7c869c8..b9e0f15885 100644 --- a/sdks/full/rust/src/models/group_external_links.rs +++ b/sdks/full/rust/src/models/group_external_links.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupExternalLinks : External links for this group. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupExternalLinks { - /// A link to this group's profile page. - #[serde(rename = "profile")] - pub profile: String, + /// A link to this group's profile page. + #[serde(rename = "profile")] + pub profile: String, } impl GroupExternalLinks { - /// External links for this group. - pub fn new(profile: String) -> GroupExternalLinks { - GroupExternalLinks { profile } - } + /// External links for this group. + pub fn new(profile: String) -> GroupExternalLinks { + GroupExternalLinks { + profile, + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_bans_response.rs b/sdks/full/rust/src/models/group_get_bans_response.rs index 5db580a07d..b2727d9fa0 100644 --- a/sdks/full/rust/src/models/group_get_bans_response.rs +++ b/sdks/full/rust/src/models/group_get_bans_response.rs @@ -4,31 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetBansResponse { - /// The pagination anchor. - #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] - pub anchor: Option, - /// A list of banned group members. - #[serde(rename = "banned_identities")] - pub banned_identities: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// The pagination anchor. + #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] + pub anchor: Option, + /// A list of banned group members. + #[serde(rename = "banned_identities")] + pub banned_identities: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl GroupGetBansResponse { - pub fn new( - banned_identities: Vec, - watch: crate::models::WatchResponse, - ) -> GroupGetBansResponse { - GroupGetBansResponse { - anchor: None, - banned_identities, - watch: Box::new(watch), - } - } + pub fn new(banned_identities: Vec, watch: crate::models::WatchResponse) -> GroupGetBansResponse { + GroupGetBansResponse { + anchor: None, + banned_identities, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_invite_response.rs b/sdks/full/rust/src/models/group_get_invite_response.rs index eb18e86d3c..caead9d125 100644 --- a/sdks/full/rust/src/models/group_get_invite_response.rs +++ b/sdks/full/rust/src/models/group_get_invite_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetInviteResponse { - #[serde(rename = "group")] - pub group: Box, + #[serde(rename = "group")] + pub group: Box, } impl GroupGetInviteResponse { - pub fn new(group: crate::models::GroupHandle) -> GroupGetInviteResponse { - GroupGetInviteResponse { - group: Box::new(group), - } - } + pub fn new(group: crate::models::GroupHandle) -> GroupGetInviteResponse { + GroupGetInviteResponse { + group: Box::new(group), + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_join_requests_response.rs b/sdks/full/rust/src/models/group_get_join_requests_response.rs index c9f9ac37e7..62988ed18c 100644 --- a/sdks/full/rust/src/models/group_get_join_requests_response.rs +++ b/sdks/full/rust/src/models/group_get_join_requests_response.rs @@ -4,31 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetJoinRequestsResponse { - /// The pagination anchor. - #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] - pub anchor: Option, - /// A list of group join requests. - #[serde(rename = "join_requests")] - pub join_requests: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// The pagination anchor. + #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] + pub anchor: Option, + /// A list of group join requests. + #[serde(rename = "join_requests")] + pub join_requests: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl GroupGetJoinRequestsResponse { - pub fn new( - join_requests: Vec, - watch: crate::models::WatchResponse, - ) -> GroupGetJoinRequestsResponse { - GroupGetJoinRequestsResponse { - anchor: None, - join_requests, - watch: Box::new(watch), - } - } + pub fn new(join_requests: Vec, watch: crate::models::WatchResponse) -> GroupGetJoinRequestsResponse { + GroupGetJoinRequestsResponse { + anchor: None, + join_requests, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_members_response.rs b/sdks/full/rust/src/models/group_get_members_response.rs index c79310751f..7b4917659c 100644 --- a/sdks/full/rust/src/models/group_get_members_response.rs +++ b/sdks/full/rust/src/models/group_get_members_response.rs @@ -4,31 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetMembersResponse { - /// The pagination anchor. - #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] - pub anchor: Option, - /// A list of group members. - #[serde(rename = "members")] - pub members: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// The pagination anchor. + #[serde(rename = "anchor", skip_serializing_if = "Option::is_none")] + pub anchor: Option, + /// A list of group members. + #[serde(rename = "members")] + pub members: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl GroupGetMembersResponse { - pub fn new( - members: Vec, - watch: crate::models::WatchResponse, - ) -> GroupGetMembersResponse { - GroupGetMembersResponse { - anchor: None, - members, - watch: Box::new(watch), - } - } + pub fn new(members: Vec, watch: crate::models::WatchResponse) -> GroupGetMembersResponse { + GroupGetMembersResponse { + anchor: None, + members, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_profile_response.rs b/sdks/full/rust/src/models/group_get_profile_response.rs index 9aba3fa350..d89ac68b35 100644 --- a/sdks/full/rust/src/models/group_get_profile_response.rs +++ b/sdks/full/rust/src/models/group_get_profile_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetProfileResponse { - #[serde(rename = "group")] - pub group: Box, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "group")] + pub group: Box, + #[serde(rename = "watch")] + pub watch: Box, } impl GroupGetProfileResponse { - pub fn new( - group: crate::models::GroupProfile, - watch: crate::models::WatchResponse, - ) -> GroupGetProfileResponse { - GroupGetProfileResponse { - group: Box::new(group), - watch: Box::new(watch), - } - } + pub fn new(group: crate::models::GroupProfile, watch: crate::models::WatchResponse) -> GroupGetProfileResponse { + GroupGetProfileResponse { + group: Box::new(group), + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/group_get_summary_response.rs b/sdks/full/rust/src/models/group_get_summary_response.rs index bdc9c75117..cc55fd9905 100644 --- a/sdks/full/rust/src/models/group_get_summary_response.rs +++ b/sdks/full/rust/src/models/group_get_summary_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupGetSummaryResponse { - #[serde(rename = "group")] - pub group: Box, + #[serde(rename = "group")] + pub group: Box, } impl GroupGetSummaryResponse { - pub fn new(group: crate::models::GroupSummary) -> GroupGetSummaryResponse { - GroupGetSummaryResponse { - group: Box::new(group), - } - } + pub fn new(group: crate::models::GroupSummary) -> GroupGetSummaryResponse { + GroupGetSummaryResponse { + group: Box::new(group), + } + } } + + diff --git a/sdks/full/rust/src/models/group_handle.rs b/sdks/full/rust/src/models/group_handle.rs index e0dc00ee00..6aed5a1bfa 100644 --- a/sdks/full/rust/src/models/group_handle.rs +++ b/sdks/full/rust/src/models/group_handle.rs @@ -4,42 +4,42 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupHandle : A group handle. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupHandle { - /// The URL of this group's avatar image - #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] - pub avatar_url: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - #[serde(rename = "group_id")] - pub group_id: uuid::Uuid, - /// Whether or not this group is a developer group. - #[serde(rename = "is_developer", skip_serializing_if = "Option::is_none")] - pub is_developer: Option, + /// The URL of this group's avatar image + #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] + pub avatar_url: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + #[serde(rename = "group_id")] + pub group_id: uuid::Uuid, + /// Whether or not this group is a developer group. + #[serde(rename = "is_developer", skip_serializing_if = "Option::is_none")] + pub is_developer: Option, } impl GroupHandle { - /// A group handle. - pub fn new( - display_name: String, - external: crate::models::GroupExternalLinks, - group_id: uuid::Uuid, - ) -> GroupHandle { - GroupHandle { - avatar_url: None, - display_name, - external: Box::new(external), - group_id, - is_developer: None, - } - } + /// A group handle. + pub fn new(display_name: String, external: crate::models::GroupExternalLinks, group_id: uuid::Uuid) -> GroupHandle { + GroupHandle { + avatar_url: None, + display_name, + external: Box::new(external), + group_id, + is_developer: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_join_request.rs b/sdks/full/rust/src/models/group_join_request.rs index b75c57750f..64edb19238 100644 --- a/sdks/full/rust/src/models/group_join_request.rs +++ b/sdks/full/rust/src/models/group_join_request.rs @@ -4,27 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupJoinRequest : A group join request. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupJoinRequest { - #[serde(rename = "identity")] - pub identity: Box, - /// RFC3339 timestamp - #[serde(rename = "ts")] - pub ts: String, + #[serde(rename = "identity")] + pub identity: Box, + /// RFC3339 timestamp + #[serde(rename = "ts")] + pub ts: String, } impl GroupJoinRequest { - /// A group join request. - pub fn new(identity: crate::models::IdentityHandle, ts: String) -> GroupJoinRequest { - GroupJoinRequest { - identity: Box::new(identity), - ts, - } - } + /// A group join request. + pub fn new(identity: crate::models::IdentityHandle, ts: String) -> GroupJoinRequest { + GroupJoinRequest { + identity: Box::new(identity), + ts, + } + } } + + diff --git a/sdks/full/rust/src/models/group_list_suggested_response.rs b/sdks/full/rust/src/models/group_list_suggested_response.rs index 31296a5b52..2fe41ffa8e 100644 --- a/sdks/full/rust/src/models/group_list_suggested_response.rs +++ b/sdks/full/rust/src/models/group_list_suggested_response.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupListSuggestedResponse { - /// A list of group summaries. - #[serde(rename = "groups")] - pub groups: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// A list of group summaries. + #[serde(rename = "groups")] + pub groups: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl GroupListSuggestedResponse { - pub fn new( - groups: Vec, - watch: crate::models::WatchResponse, - ) -> GroupListSuggestedResponse { - GroupListSuggestedResponse { - groups, - watch: Box::new(watch), - } - } + pub fn new(groups: Vec, watch: crate::models::WatchResponse) -> GroupListSuggestedResponse { + GroupListSuggestedResponse { + groups, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/group_member.rs b/sdks/full/rust/src/models/group_member.rs index 99ae2414ef..aecd0ba064 100644 --- a/sdks/full/rust/src/models/group_member.rs +++ b/sdks/full/rust/src/models/group_member.rs @@ -4,23 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupMember : A group member. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupMember { - #[serde(rename = "identity")] - pub identity: Box, + #[serde(rename = "identity")] + pub identity: Box, } impl GroupMember { - /// A group member. - pub fn new(identity: crate::models::IdentityHandle) -> GroupMember { - GroupMember { - identity: Box::new(identity), - } - } + /// A group member. + pub fn new(identity: crate::models::IdentityHandle) -> GroupMember { + GroupMember { + identity: Box::new(identity), + } + } } + + diff --git a/sdks/full/rust/src/models/group_prepare_avatar_upload_request.rs b/sdks/full/rust/src/models/group_prepare_avatar_upload_request.rs index 676cff4a9a..e07a49db68 100644 --- a/sdks/full/rust/src/models/group_prepare_avatar_upload_request.rs +++ b/sdks/full/rust/src/models/group_prepare_avatar_upload_request.rs @@ -4,29 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupPrepareAvatarUploadRequest { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The MIME type of the group avatar. - #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] - pub mime: Option, - /// The path/filename of the group avatar. - #[serde(rename = "path")] - pub path: String, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the group avatar. + #[serde(rename = "mime", skip_serializing_if = "Option::is_none")] + pub mime: Option, + /// The path/filename of the group avatar. + #[serde(rename = "path")] + pub path: String, } impl GroupPrepareAvatarUploadRequest { - pub fn new(content_length: i64, path: String) -> GroupPrepareAvatarUploadRequest { - GroupPrepareAvatarUploadRequest { - content_length, - mime: None, - path, - } - } + pub fn new(content_length: i64, path: String) -> GroupPrepareAvatarUploadRequest { + GroupPrepareAvatarUploadRequest { + content_length, + mime: None, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/group_prepare_avatar_upload_response.rs b/sdks/full/rust/src/models/group_prepare_avatar_upload_response.rs index 04f10e7ac7..4917e80c8d 100644 --- a/sdks/full/rust/src/models/group_prepare_avatar_upload_response.rs +++ b/sdks/full/rust/src/models/group_prepare_avatar_upload_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupPrepareAvatarUploadResponse { - #[serde(rename = "presigned_request")] - pub presigned_request: Box, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_request")] + pub presigned_request: Box, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl GroupPrepareAvatarUploadResponse { - pub fn new( - presigned_request: crate::models::UploadPresignedRequest, - upload_id: uuid::Uuid, - ) -> GroupPrepareAvatarUploadResponse { - GroupPrepareAvatarUploadResponse { - presigned_request: Box::new(presigned_request), - upload_id, - } - } + pub fn new(presigned_request: crate::models::UploadPresignedRequest, upload_id: uuid::Uuid) -> GroupPrepareAvatarUploadResponse { + GroupPrepareAvatarUploadResponse { + presigned_request: Box::new(presigned_request), + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/group_profile.rs b/sdks/full/rust/src/models/group_profile.rs index be6a629ebf..c7ac6c1011 100644 --- a/sdks/full/rust/src/models/group_profile.rs +++ b/sdks/full/rust/src/models/group_profile.rs @@ -4,83 +4,72 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// GroupProfile : A list of group profiles. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupProfile { - /// The URL of this group's avatar image. - #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] - pub avatar_url: Option, - /// Detailed information about a profile. - #[serde(rename = "bio")] - pub bio: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - #[serde(rename = "group_id")] - pub group_id: uuid::Uuid, - /// Whether or not the current identity is a member of this group. - #[serde( - rename = "is_current_identity_member", - skip_serializing_if = "Option::is_none" - )] - pub is_current_identity_member: Option, - /// Whether or not the current identity is currently requesting to join this group. - #[serde( - rename = "is_current_identity_requesting_join", - skip_serializing_if = "Option::is_none" - )] - pub is_current_identity_requesting_join: Option, - /// Whether or not this group is a developer. - #[serde(rename = "is_developer", skip_serializing_if = "Option::is_none")] - pub is_developer: Option, - /// A list of group join requests. - #[serde(rename = "join_requests")] - pub join_requests: Vec, - /// Unsigned 32 bit integer. - #[serde(rename = "member_count", skip_serializing_if = "Option::is_none")] - pub member_count: Option, - /// A list of group members. - #[serde(rename = "members")] - pub members: Vec, - #[serde(rename = "owner_identity_id")] - pub owner_identity_id: uuid::Uuid, - #[serde(rename = "publicity")] - pub publicity: crate::models::GroupPublicity, + /// The URL of this group's avatar image. + #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] + pub avatar_url: Option, + /// Detailed information about a profile. + #[serde(rename = "bio")] + pub bio: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + #[serde(rename = "group_id")] + pub group_id: uuid::Uuid, + /// Whether or not the current identity is a member of this group. + #[serde(rename = "is_current_identity_member", skip_serializing_if = "Option::is_none")] + pub is_current_identity_member: Option, + /// Whether or not the current identity is currently requesting to join this group. + #[serde(rename = "is_current_identity_requesting_join", skip_serializing_if = "Option::is_none")] + pub is_current_identity_requesting_join: Option, + /// Whether or not this group is a developer. + #[serde(rename = "is_developer", skip_serializing_if = "Option::is_none")] + pub is_developer: Option, + /// A list of group join requests. + #[serde(rename = "join_requests")] + pub join_requests: Vec, + /// Unsigned 32 bit integer. + #[serde(rename = "member_count", skip_serializing_if = "Option::is_none")] + pub member_count: Option, + /// A list of group members. + #[serde(rename = "members")] + pub members: Vec, + #[serde(rename = "owner_identity_id")] + pub owner_identity_id: uuid::Uuid, + #[serde(rename = "publicity")] + pub publicity: crate::models::GroupPublicity, } impl GroupProfile { - /// A list of group profiles. - pub fn new( - bio: String, - display_name: String, - external: crate::models::GroupExternalLinks, - group_id: uuid::Uuid, - join_requests: Vec, - members: Vec, - owner_identity_id: uuid::Uuid, - publicity: crate::models::GroupPublicity, - ) -> GroupProfile { - GroupProfile { - avatar_url: None, - bio, - display_name, - external: Box::new(external), - group_id, - is_current_identity_member: None, - is_current_identity_requesting_join: None, - is_developer: None, - join_requests, - member_count: None, - members, - owner_identity_id, - publicity, - } - } + /// A list of group profiles. + pub fn new(bio: String, display_name: String, external: crate::models::GroupExternalLinks, group_id: uuid::Uuid, join_requests: Vec, members: Vec, owner_identity_id: uuid::Uuid, publicity: crate::models::GroupPublicity) -> GroupProfile { + GroupProfile { + avatar_url: None, + bio, + display_name, + external: Box::new(external), + group_id, + is_current_identity_member: None, + is_current_identity_requesting_join: None, + is_developer: None, + join_requests, + member_count: None, + members, + owner_identity_id, + publicity, + } + } } + + diff --git a/sdks/full/rust/src/models/group_publicity.rs b/sdks/full/rust/src/models/group_publicity.rs index 1e540fd925..e8d758d80b 100644 --- a/sdks/full/rust/src/models/group_publicity.rs +++ b/sdks/full/rust/src/models/group_publicity.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,23 +13,28 @@ /// The current publicity value for the given group. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum GroupPublicity { - #[serde(rename = "open")] - Open, - #[serde(rename = "closed")] - Closed, + #[serde(rename = "open")] + Open, + #[serde(rename = "closed")] + Closed, + } impl ToString for GroupPublicity { - fn to_string(&self) -> String { - match self { - Self::Open => String::from("open"), - Self::Closed => String::from("closed"), - } - } + fn to_string(&self) -> String { + match self { + Self::Open => String::from("open"), + Self::Closed => String::from("closed"), + } + } } impl Default for GroupPublicity { - fn default() -> GroupPublicity { - Self::Open - } + fn default() -> GroupPublicity { + Self::Open + } } + + + + diff --git a/sdks/full/rust/src/models/group_resolve_join_request_request.rs b/sdks/full/rust/src/models/group_resolve_join_request_request.rs index 79f4861803..32c1e7fef7 100644 --- a/sdks/full/rust/src/models/group_resolve_join_request_request.rs +++ b/sdks/full/rust/src/models/group_resolve_join_request_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupResolveJoinRequestRequest { - #[serde(rename = "resolution", skip_serializing_if = "Option::is_none")] - pub resolution: Option, + #[serde(rename = "resolution", skip_serializing_if = "Option::is_none")] + pub resolution: Option, } impl GroupResolveJoinRequestRequest { - pub fn new() -> GroupResolveJoinRequestRequest { - GroupResolveJoinRequestRequest { resolution: None } - } + pub fn new() -> GroupResolveJoinRequestRequest { + GroupResolveJoinRequestRequest { + resolution: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_summary.rs b/sdks/full/rust/src/models/group_summary.rs index e153020a22..85ae0cfede 100644 --- a/sdks/full/rust/src/models/group_summary.rs +++ b/sdks/full/rust/src/models/group_summary.rs @@ -4,62 +4,57 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupSummary { - /// The URL of this group's avatar image. - #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] - pub avatar_url: Option, - /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ - #[serde(rename = "bio")] - pub bio: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - #[serde(rename = "group_id")] - pub group_id: uuid::Uuid, - /// Whether or not the current identity is a member of this group. - #[serde(rename = "is_current_identity_member")] - pub is_current_identity_member: bool, - /// **Deprecated** Whether or not this group is a developer. - #[serde(rename = "is_developer")] - pub is_developer: bool, - #[serde(rename = "member_count")] - pub member_count: i32, - #[serde(rename = "owner_identity_id")] - pub owner_identity_id: uuid::Uuid, - #[serde(rename = "publicity")] - pub publicity: crate::models::GroupPublicity, + /// The URL of this group's avatar image. + #[serde(rename = "avatar_url", skip_serializing_if = "Option::is_none")] + pub avatar_url: Option, + /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ + #[serde(rename = "bio")] + pub bio: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + #[serde(rename = "group_id")] + pub group_id: uuid::Uuid, + /// Whether or not the current identity is a member of this group. + #[serde(rename = "is_current_identity_member")] + pub is_current_identity_member: bool, + /// **Deprecated** Whether or not this group is a developer. + #[serde(rename = "is_developer")] + pub is_developer: bool, + #[serde(rename = "member_count")] + pub member_count: i32, + #[serde(rename = "owner_identity_id")] + pub owner_identity_id: uuid::Uuid, + #[serde(rename = "publicity")] + pub publicity: crate::models::GroupPublicity, } impl GroupSummary { - pub fn new( - bio: String, - display_name: String, - external: crate::models::GroupExternalLinks, - group_id: uuid::Uuid, - is_current_identity_member: bool, - is_developer: bool, - member_count: i32, - owner_identity_id: uuid::Uuid, - publicity: crate::models::GroupPublicity, - ) -> GroupSummary { - GroupSummary { - avatar_url: None, - bio, - display_name, - external: Box::new(external), - group_id, - is_current_identity_member, - is_developer, - member_count, - owner_identity_id, - publicity, - } - } + pub fn new(bio: String, display_name: String, external: crate::models::GroupExternalLinks, group_id: uuid::Uuid, is_current_identity_member: bool, is_developer: bool, member_count: i32, owner_identity_id: uuid::Uuid, publicity: crate::models::GroupPublicity) -> GroupSummary { + GroupSummary { + avatar_url: None, + bio, + display_name, + external: Box::new(external), + group_id, + is_current_identity_member, + is_developer, + member_count, + owner_identity_id, + publicity, + } + } } + + diff --git a/sdks/full/rust/src/models/group_transfer_ownership_request.rs b/sdks/full/rust/src/models/group_transfer_ownership_request.rs index 00711905d3..39cbd20782 100644 --- a/sdks/full/rust/src/models/group_transfer_ownership_request.rs +++ b/sdks/full/rust/src/models/group_transfer_ownership_request.rs @@ -4,21 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupTransferOwnershipRequest { - /// Identity to transfer the group to. Must be a member of the group. - #[serde(rename = "new_owner_identity_id")] - pub new_owner_identity_id: String, + /// Identity to transfer the group to. Must be a member of the group. + #[serde(rename = "new_owner_identity_id")] + pub new_owner_identity_id: String, } impl GroupTransferOwnershipRequest { - pub fn new(new_owner_identity_id: String) -> GroupTransferOwnershipRequest { - GroupTransferOwnershipRequest { - new_owner_identity_id, - } - } + pub fn new(new_owner_identity_id: String) -> GroupTransferOwnershipRequest { + GroupTransferOwnershipRequest { + new_owner_identity_id, + } + } } + + diff --git a/sdks/full/rust/src/models/group_update_profile_request.rs b/sdks/full/rust/src/models/group_update_profile_request.rs index 5e443ca780..e8e7672df5 100644 --- a/sdks/full/rust/src/models/group_update_profile_request.rs +++ b/sdks/full/rust/src/models/group_update_profile_request.rs @@ -4,28 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupUpdateProfileRequest { - /// Detailed information about a profile. - #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] - pub bio: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] - pub display_name: Option, - #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] - pub publicity: Option, + /// Detailed information about a profile. + #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] + pub bio: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] + pub display_name: Option, + #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] + pub publicity: Option, } impl GroupUpdateProfileRequest { - pub fn new() -> GroupUpdateProfileRequest { - GroupUpdateProfileRequest { - bio: None, - display_name: None, - publicity: None, - } - } + pub fn new() -> GroupUpdateProfileRequest { + GroupUpdateProfileRequest { + bio: None, + display_name: None, + publicity: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_validate_profile_request.rs b/sdks/full/rust/src/models/group_validate_profile_request.rs index 9cd8de28c9..501acb5beb 100644 --- a/sdks/full/rust/src/models/group_validate_profile_request.rs +++ b/sdks/full/rust/src/models/group_validate_profile_request.rs @@ -4,28 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupValidateProfileRequest { - /// Represent a resource's readable display name. - #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] - pub bio: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] - pub display_name: Option, - #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] - pub publicity: Option, + /// Represent a resource's readable display name. + #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] + pub bio: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] + pub display_name: Option, + #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] + pub publicity: Option, } impl GroupValidateProfileRequest { - pub fn new() -> GroupValidateProfileRequest { - GroupValidateProfileRequest { - bio: None, - display_name: None, - publicity: None, - } - } + pub fn new() -> GroupValidateProfileRequest { + GroupValidateProfileRequest { + bio: None, + display_name: None, + publicity: None, + } + } } + + diff --git a/sdks/full/rust/src/models/group_validate_profile_response.rs b/sdks/full/rust/src/models/group_validate_profile_response.rs index 794edc06d0..decad7e290 100644 --- a/sdks/full/rust/src/models/group_validate_profile_response.rs +++ b/sdks/full/rust/src/models/group_validate_profile_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GroupValidateProfileResponse { - /// A list of validation errors. - #[serde(rename = "errors")] - pub errors: Vec, + /// A list of validation errors. + #[serde(rename = "errors")] + pub errors: Vec, } impl GroupValidateProfileResponse { - pub fn new(errors: Vec) -> GroupValidateProfileResponse { - GroupValidateProfileResponse { errors } - } + pub fn new(errors: Vec) -> GroupValidateProfileResponse { + GroupValidateProfileResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_dev_state.rs b/sdks/full/rust/src/models/identity_dev_state.rs index b36d78c727..bfe9d673a4 100644 --- a/sdks/full/rust/src/models/identity_dev_state.rs +++ b/sdks/full/rust/src/models/identity_dev_state.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,26 +13,31 @@ /// The state of the given identity's developer status. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum IdentityDevState { - #[serde(rename = "inactive")] - Inactive, - #[serde(rename = "pending")] - Pending, - #[serde(rename = "accepted")] - Accepted, + #[serde(rename = "inactive")] + Inactive, + #[serde(rename = "pending")] + Pending, + #[serde(rename = "accepted")] + Accepted, + } impl ToString for IdentityDevState { - fn to_string(&self) -> String { - match self { - Self::Inactive => String::from("inactive"), - Self::Pending => String::from("pending"), - Self::Accepted => String::from("accepted"), - } - } + fn to_string(&self) -> String { + match self { + Self::Inactive => String::from("inactive"), + Self::Pending => String::from("pending"), + Self::Accepted => String::from("accepted"), + } + } } impl Default for IdentityDevState { - fn default() -> IdentityDevState { - Self::Inactive - } + fn default() -> IdentityDevState { + Self::Inactive + } } + + + + diff --git a/sdks/full/rust/src/models/identity_email_linked_account.rs b/sdks/full/rust/src/models/identity_email_linked_account.rs index a86d5eca1f..6c458bb42f 100644 --- a/sdks/full/rust/src/models/identity_email_linked_account.rs +++ b/sdks/full/rust/src/models/identity_email_linked_account.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityEmailLinkedAccount : An identity's linked email. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityEmailLinkedAccount { - /// A valid email address - #[serde(rename = "email")] - pub email: String, + /// A valid email address + #[serde(rename = "email")] + pub email: String, } impl IdentityEmailLinkedAccount { - /// An identity's linked email. - pub fn new(email: String) -> IdentityEmailLinkedAccount { - IdentityEmailLinkedAccount { email } - } + /// An identity's linked email. + pub fn new(email: String) -> IdentityEmailLinkedAccount { + IdentityEmailLinkedAccount { + email, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_external_links.rs b/sdks/full/rust/src/models/identity_external_links.rs index 35a1d52d88..dddc3a0917 100644 --- a/sdks/full/rust/src/models/identity_external_links.rs +++ b/sdks/full/rust/src/models/identity_external_links.rs @@ -4,28 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityExternalLinks : External links for an identity. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityExternalLinks { - /// A link to this identity's profile page. - #[serde(rename = "profile")] - pub profile: String, - /// A link to the Rivet settings page. - #[serde(rename = "settings", skip_serializing_if = "Option::is_none")] - pub settings: Option, + /// A link to this identity's profile page. + #[serde(rename = "profile")] + pub profile: String, + /// A link to the Rivet settings page. + #[serde(rename = "settings", skip_serializing_if = "Option::is_none")] + pub settings: Option, } impl IdentityExternalLinks { - /// External links for an identity. - pub fn new(profile: String) -> IdentityExternalLinks { - IdentityExternalLinks { - profile, - settings: None, - } - } + /// External links for an identity. + pub fn new(profile: String) -> IdentityExternalLinks { + IdentityExternalLinks { + profile, + settings: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_game_activity.rs b/sdks/full/rust/src/models/identity_game_activity.rs index c2c874b53f..e4be94ffcb 100644 --- a/sdks/full/rust/src/models/identity_game_activity.rs +++ b/sdks/full/rust/src/models/identity_game_activity.rs @@ -4,45 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityGameActivity : The game an identity is currently participating in. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGameActivity { - #[serde(rename = "game")] - pub game: Box, - /// A short activity message about the current game activity. - #[serde(rename = "message")] - pub message: String, - /// JSON data seen only by the given identity and their mutual followers. - #[serde( - rename = "mutual_metadata", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub mutual_metadata: Option>, - /// JSON data seen by anyone. - #[serde( - rename = "public_metadata", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub public_metadata: Option>, + #[serde(rename = "game")] + pub game: Box, + /// A short activity message about the current game activity. + #[serde(rename = "message")] + pub message: String, + /// JSON data seen only by the given identity and their mutual followers. + #[serde(rename = "mutual_metadata", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub mutual_metadata: Option>, + /// JSON data seen by anyone. + #[serde(rename = "public_metadata", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub public_metadata: Option>, } impl IdentityGameActivity { - /// The game an identity is currently participating in. - pub fn new(game: crate::models::GameHandle, message: String) -> IdentityGameActivity { - IdentityGameActivity { - game: Box::new(game), - message, - mutual_metadata: None, - public_metadata: None, - } - } + /// The game an identity is currently participating in. + pub fn new(game: crate::models::GameHandle, message: String) -> IdentityGameActivity { + IdentityGameActivity { + game: Box::new(game), + message, + mutual_metadata: None, + public_metadata: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_game_link_status.rs b/sdks/full/rust/src/models/identity_game_link_status.rs index b9c9934697..8fc24f518e 100644 --- a/sdks/full/rust/src/models/identity_game_link_status.rs +++ b/sdks/full/rust/src/models/identity_game_link_status.rs @@ -4,33 +4,39 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum IdentityGameLinkStatus { - #[serde(rename = "incomplete")] - Incomplete, - #[serde(rename = "complete")] - Complete, - #[serde(rename = "cancelled")] - Cancelled, + #[serde(rename = "incomplete")] + Incomplete, + #[serde(rename = "complete")] + Complete, + #[serde(rename = "cancelled")] + Cancelled, + } impl ToString for IdentityGameLinkStatus { - fn to_string(&self) -> String { - match self { - Self::Incomplete => String::from("incomplete"), - Self::Complete => String::from("complete"), - Self::Cancelled => String::from("cancelled"), - } - } + fn to_string(&self) -> String { + match self { + Self::Incomplete => String::from("incomplete"), + Self::Complete => String::from("complete"), + Self::Cancelled => String::from("cancelled"), + } + } } impl Default for IdentityGameLinkStatus { - fn default() -> IdentityGameLinkStatus { - Self::Incomplete - } + fn default() -> IdentityGameLinkStatus { + Self::Incomplete + } } + + + + diff --git a/sdks/full/rust/src/models/identity_get_handles_response.rs b/sdks/full/rust/src/models/identity_get_handles_response.rs index ac8508481f..ddbb9f7a0a 100644 --- a/sdks/full/rust/src/models/identity_get_handles_response.rs +++ b/sdks/full/rust/src/models/identity_get_handles_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGetHandlesResponse { - #[serde(rename = "identities")] - pub identities: Vec, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "identities")] + pub identities: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl IdentityGetHandlesResponse { - pub fn new( - identities: Vec, - watch: crate::models::WatchResponse, - ) -> IdentityGetHandlesResponse { - IdentityGetHandlesResponse { - identities, - watch: Box::new(watch), - } - } + pub fn new(identities: Vec, watch: crate::models::WatchResponse) -> IdentityGetHandlesResponse { + IdentityGetHandlesResponse { + identities, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_get_profile_response.rs b/sdks/full/rust/src/models/identity_get_profile_response.rs index 77765e009b..a1e34af613 100644 --- a/sdks/full/rust/src/models/identity_get_profile_response.rs +++ b/sdks/full/rust/src/models/identity_get_profile_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGetProfileResponse { - #[serde(rename = "identity")] - pub identity: Box, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "identity")] + pub identity: Box, + #[serde(rename = "watch")] + pub watch: Box, } impl IdentityGetProfileResponse { - pub fn new( - identity: crate::models::IdentityProfile, - watch: crate::models::WatchResponse, - ) -> IdentityGetProfileResponse { - IdentityGetProfileResponse { - identity: Box::new(identity), - watch: Box::new(watch), - } - } + pub fn new(identity: crate::models::IdentityProfile, watch: crate::models::WatchResponse) -> IdentityGetProfileResponse { + IdentityGetProfileResponse { + identity: Box::new(identity), + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_get_summaries_response.rs b/sdks/full/rust/src/models/identity_get_summaries_response.rs index 42b328cd1f..bf83a8b651 100644 --- a/sdks/full/rust/src/models/identity_get_summaries_response.rs +++ b/sdks/full/rust/src/models/identity_get_summaries_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGetSummariesResponse { - #[serde(rename = "identities")] - pub identities: Vec, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "identities")] + pub identities: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl IdentityGetSummariesResponse { - pub fn new( - identities: Vec, - watch: crate::models::WatchResponse, - ) -> IdentityGetSummariesResponse { - IdentityGetSummariesResponse { - identities, - watch: Box::new(watch), - } - } + pub fn new(identities: Vec, watch: crate::models::WatchResponse) -> IdentityGetSummariesResponse { + IdentityGetSummariesResponse { + identities, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_global_event.rs b/sdks/full/rust/src/models/identity_global_event.rs index 733befecce..e3533a36a9 100644 --- a/sdks/full/rust/src/models/identity_global_event.rs +++ b/sdks/full/rust/src/models/identity_global_event.rs @@ -4,30 +4,34 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityGlobalEvent : An event relevant to the current identity. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGlobalEvent { - #[serde(rename = "kind")] - pub kind: Box, - #[serde(rename = "notification", skip_serializing_if = "Option::is_none")] - pub notification: Option>, - /// RFC3339 timestamp - #[serde(rename = "ts")] - pub ts: String, + #[serde(rename = "kind")] + pub kind: Box, + #[serde(rename = "notification", skip_serializing_if = "Option::is_none")] + pub notification: Option>, + /// RFC3339 timestamp + #[serde(rename = "ts")] + pub ts: String, } impl IdentityGlobalEvent { - /// An event relevant to the current identity. - pub fn new(kind: crate::models::IdentityGlobalEventKind, ts: String) -> IdentityGlobalEvent { - IdentityGlobalEvent { - kind: Box::new(kind), - notification: None, - ts, - } - } + /// An event relevant to the current identity. + pub fn new(kind: crate::models::IdentityGlobalEventKind, ts: String) -> IdentityGlobalEvent { + IdentityGlobalEvent { + kind: Box::new(kind), + notification: None, + ts, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_global_event_identity_update.rs b/sdks/full/rust/src/models/identity_global_event_identity_update.rs index 0af36942a3..5ccdc16e9f 100644 --- a/sdks/full/rust/src/models/identity_global_event_identity_update.rs +++ b/sdks/full/rust/src/models/identity_global_event_identity_update.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGlobalEventIdentityUpdate { - #[serde(rename = "identity")] - pub identity: Box, + #[serde(rename = "identity")] + pub identity: Box, } impl IdentityGlobalEventIdentityUpdate { - pub fn new(identity: crate::models::IdentityProfile) -> IdentityGlobalEventIdentityUpdate { - IdentityGlobalEventIdentityUpdate { - identity: Box::new(identity), - } - } + pub fn new(identity: crate::models::IdentityProfile) -> IdentityGlobalEventIdentityUpdate { + IdentityGlobalEventIdentityUpdate { + identity: Box::new(identity), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_global_event_kind.rs b/sdks/full/rust/src/models/identity_global_event_kind.rs index 23f8447a1a..fab257077b 100644 --- a/sdks/full/rust/src/models/identity_global_event_kind.rs +++ b/sdks/full/rust/src/models/identity_global_event_kind.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGlobalEventKind { - #[serde(rename = "identity_update", skip_serializing_if = "Option::is_none")] - pub identity_update: Option>, + #[serde(rename = "identity_update", skip_serializing_if = "Option::is_none")] + pub identity_update: Option>, } impl IdentityGlobalEventKind { - pub fn new() -> IdentityGlobalEventKind { - IdentityGlobalEventKind { - identity_update: None, - } - } + pub fn new() -> IdentityGlobalEventKind { + IdentityGlobalEventKind { + identity_update: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_global_event_notification.rs b/sdks/full/rust/src/models/identity_global_event_notification.rs index aa81ce7b00..8472601185 100644 --- a/sdks/full/rust/src/models/identity_global_event_notification.rs +++ b/sdks/full/rust/src/models/identity_global_event_notification.rs @@ -4,39 +4,38 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityGlobalEventNotification : Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `GlobalEvent.kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `GlobalEventChatMessage`, then open the chat UI for the given thread. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGlobalEventNotification { - #[serde(rename = "description")] - pub description: String, - /// URL to an image thumbnail that should be shown for this notification. - #[serde(rename = "thumbnail_url")] - pub thumbnail_url: String, - #[serde(rename = "title")] - pub title: String, - /// Rivet Hub URL that holds the relevant context for this notification. - #[serde(rename = "url")] - pub url: String, + #[serde(rename = "description")] + pub description: String, + /// URL to an image thumbnail that should be shown for this notification. + #[serde(rename = "thumbnail_url")] + pub thumbnail_url: String, + #[serde(rename = "title")] + pub title: String, + /// Rivet Hub URL that holds the relevant context for this notification. + #[serde(rename = "url")] + pub url: String, } impl IdentityGlobalEventNotification { - /// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `GlobalEvent.kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `GlobalEventChatMessage`, then open the chat UI for the given thread. - pub fn new( - description: String, - thumbnail_url: String, - title: String, - url: String, - ) -> IdentityGlobalEventNotification { - IdentityGlobalEventNotification { - description, - thumbnail_url, - title, - url, - } - } + /// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `GlobalEvent.kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `GlobalEventChatMessage`, then open the chat UI for the given thread. + pub fn new(description: String, thumbnail_url: String, title: String, url: String) -> IdentityGlobalEventNotification { + IdentityGlobalEventNotification { + description, + thumbnail_url, + title, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_group.rs b/sdks/full/rust/src/models/identity_group.rs index 2767ddae91..a280ad6ad2 100644 --- a/sdks/full/rust/src/models/identity_group.rs +++ b/sdks/full/rust/src/models/identity_group.rs @@ -4,23 +4,27 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityGroup : A group that the given identity. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityGroup { - #[serde(rename = "group")] - pub group: Box, + #[serde(rename = "group")] + pub group: Box, } impl IdentityGroup { - /// A group that the given identity. - pub fn new(group: crate::models::GroupHandle) -> IdentityGroup { - IdentityGroup { - group: Box::new(group), - } - } + /// A group that the given identity. + pub fn new(group: crate::models::GroupHandle) -> IdentityGroup { + IdentityGroup { + group: Box::new(group), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_handle.rs b/sdks/full/rust/src/models/identity_handle.rs index 70c97f06d6..aa3767fe0e 100644 --- a/sdks/full/rust/src/models/identity_handle.rs +++ b/sdks/full/rust/src/models/identity_handle.rs @@ -4,48 +4,45 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityHandle : An identity handle. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityHandle { - #[serde(rename = "account_number")] - pub account_number: i32, - /// The URL of this identity's avatar image. - #[serde(rename = "avatar_url")] - pub avatar_url: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - #[serde(rename = "identity_id")] - pub identity_id: uuid::Uuid, - /// Whether or not this identity is registered with a linked account. - #[serde(rename = "is_registered")] - pub is_registered: bool, + #[serde(rename = "account_number")] + pub account_number: i32, + /// The URL of this identity's avatar image. + #[serde(rename = "avatar_url")] + pub avatar_url: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + #[serde(rename = "identity_id")] + pub identity_id: uuid::Uuid, + /// Whether or not this identity is registered with a linked account. + #[serde(rename = "is_registered")] + pub is_registered: bool, } impl IdentityHandle { - /// An identity handle. - pub fn new( - account_number: i32, - avatar_url: String, - display_name: String, - external: crate::models::IdentityExternalLinks, - identity_id: uuid::Uuid, - is_registered: bool, - ) -> IdentityHandle { - IdentityHandle { - account_number, - avatar_url, - display_name, - external: Box::new(external), - identity_id, - is_registered, - } - } + /// An identity handle. + pub fn new(account_number: i32, avatar_url: String, display_name: String, external: crate::models::IdentityExternalLinks, identity_id: uuid::Uuid, is_registered: bool) -> IdentityHandle { + IdentityHandle { + account_number, + avatar_url, + display_name, + external: Box::new(external), + identity_id, + is_registered, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_linked_account.rs b/sdks/full/rust/src/models/identity_linked_account.rs index d262a579e7..b0f4f62dde 100644 --- a/sdks/full/rust/src/models/identity_linked_account.rs +++ b/sdks/full/rust/src/models/identity_linked_account.rs @@ -4,26 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityLinkedAccount : A union representing an identity's linked accounts. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityLinkedAccount { - #[serde(rename = "default_user", skip_serializing_if = "Option::is_none")] - pub default_user: Option, - #[serde(rename = "email", skip_serializing_if = "Option::is_none")] - pub email: Option>, + #[serde(rename = "default_user", skip_serializing_if = "Option::is_none")] + pub default_user: Option, + #[serde(rename = "email", skip_serializing_if = "Option::is_none")] + pub email: Option>, } impl IdentityLinkedAccount { - /// A union representing an identity's linked accounts. - pub fn new() -> IdentityLinkedAccount { - IdentityLinkedAccount { - default_user: None, - email: None, - } - } + /// A union representing an identity's linked accounts. + pub fn new() -> IdentityLinkedAccount { + IdentityLinkedAccount { + default_user: None, + email: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_list_activities_response.rs b/sdks/full/rust/src/models/identity_list_activities_response.rs index c9f1f3edba..373cbb29e5 100644 --- a/sdks/full/rust/src/models/identity_list_activities_response.rs +++ b/sdks/full/rust/src/models/identity_list_activities_response.rs @@ -4,38 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityListActivitiesResponse { - #[serde(rename = "games")] - pub games: Vec, - #[serde(rename = "identities")] - pub identities: Vec, - #[serde(rename = "suggested_groups")] - pub suggested_groups: Vec, - #[serde(rename = "suggested_players")] - pub suggested_players: Vec, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "games")] + pub games: Vec, + #[serde(rename = "identities")] + pub identities: Vec, + #[serde(rename = "suggested_groups")] + pub suggested_groups: Vec, + #[serde(rename = "suggested_players")] + pub suggested_players: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl IdentityListActivitiesResponse { - pub fn new( - games: Vec, - identities: Vec, - suggested_groups: Vec, - suggested_players: Vec, - watch: crate::models::WatchResponse, - ) -> IdentityListActivitiesResponse { - IdentityListActivitiesResponse { - games, - identities, - suggested_groups, - suggested_players, - watch: Box::new(watch), - } - } + pub fn new(games: Vec, identities: Vec, suggested_groups: Vec, suggested_players: Vec, watch: crate::models::WatchResponse) -> IdentityListActivitiesResponse { + IdentityListActivitiesResponse { + games, + identities, + suggested_groups, + suggested_players, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_prepare_avatar_upload_request.rs b/sdks/full/rust/src/models/identity_prepare_avatar_upload_request.rs index 94c9b44fd6..89c23ec726 100644 --- a/sdks/full/rust/src/models/identity_prepare_avatar_upload_request.rs +++ b/sdks/full/rust/src/models/identity_prepare_avatar_upload_request.rs @@ -4,31 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityPrepareAvatarUploadRequest { - #[serde(rename = "content_length")] - pub content_length: i64, - /// See https://www.iana.org/assignments/media-types/media-types.xhtml - #[serde(rename = "mime")] - pub mime: String, - #[serde(rename = "path")] - pub path: String, + #[serde(rename = "content_length")] + pub content_length: i64, + /// See https://www.iana.org/assignments/media-types/media-types.xhtml + #[serde(rename = "mime")] + pub mime: String, + #[serde(rename = "path")] + pub path: String, } impl IdentityPrepareAvatarUploadRequest { - pub fn new( - content_length: i64, - mime: String, - path: String, - ) -> IdentityPrepareAvatarUploadRequest { - IdentityPrepareAvatarUploadRequest { - content_length, - mime, - path, - } - } + pub fn new(content_length: i64, mime: String, path: String) -> IdentityPrepareAvatarUploadRequest { + IdentityPrepareAvatarUploadRequest { + content_length, + mime, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_prepare_avatar_upload_response.rs b/sdks/full/rust/src/models/identity_prepare_avatar_upload_response.rs index 414223d33a..756fdda3de 100644 --- a/sdks/full/rust/src/models/identity_prepare_avatar_upload_response.rs +++ b/sdks/full/rust/src/models/identity_prepare_avatar_upload_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityPrepareAvatarUploadResponse { - #[serde(rename = "presigned_request")] - pub presigned_request: Box, - #[serde(rename = "upload_id")] - pub upload_id: uuid::Uuid, + #[serde(rename = "presigned_request")] + pub presigned_request: Box, + #[serde(rename = "upload_id")] + pub upload_id: uuid::Uuid, } impl IdentityPrepareAvatarUploadResponse { - pub fn new( - presigned_request: crate::models::UploadPresignedRequest, - upload_id: uuid::Uuid, - ) -> IdentityPrepareAvatarUploadResponse { - IdentityPrepareAvatarUploadResponse { - presigned_request: Box::new(presigned_request), - upload_id, - } - } + pub fn new(presigned_request: crate::models::UploadPresignedRequest, upload_id: uuid::Uuid) -> IdentityPrepareAvatarUploadResponse { + IdentityPrepareAvatarUploadResponse { + presigned_request: Box::new(presigned_request), + upload_id, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_profile.rs b/sdks/full/rust/src/models/identity_profile.rs index cbc1644fa9..ef5de34586 100644 --- a/sdks/full/rust/src/models/identity_profile.rs +++ b/sdks/full/rust/src/models/identity_profile.rs @@ -4,108 +4,94 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityProfile : An identity profile. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityProfile { - #[serde(rename = "account_number")] - pub account_number: i32, - /// The URL of this identity's avatar image. - #[serde(rename = "avatar_url")] - pub avatar_url: String, - /// Whether or not this identity is awaiting account deletion. Only visible to when the requestee is this identity. - #[serde(rename = "awaiting_deletion", skip_serializing_if = "Option::is_none")] - pub awaiting_deletion: Option, - /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ - #[serde(rename = "bio")] - pub bio: String, - #[serde(rename = "dev_state", skip_serializing_if = "Option::is_none")] - pub dev_state: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - #[serde(rename = "follower_count")] - pub follower_count: i64, - /// Whether or not the requestee's identity is following this identity. - #[serde(rename = "following")] - pub following: bool, - #[serde(rename = "following_count")] - pub following_count: i64, - #[serde(rename = "games")] - pub games: Vec, - #[serde(rename = "groups")] - pub groups: Vec, - #[serde(rename = "identity_id")] - pub identity_id: uuid::Uuid, - /// Whether or not this identity is an admin. - #[serde(rename = "is_admin")] - pub is_admin: bool, - /// Whether or not this identity is both following and is followed by the requestee's identity. - #[serde(rename = "is_following_me")] - pub is_following_me: bool, - /// Whether or not this game user has been linked through the Rivet dashboard. - #[serde(rename = "is_game_linked", skip_serializing_if = "Option::is_none")] - pub is_game_linked: Option, - #[serde(rename = "is_mutual_following")] - pub is_mutual_following: bool, - /// Whether or not this identity is registered with a linked account. - #[serde(rename = "is_registered")] - pub is_registered: bool, - /// RFC3339 timestamp - #[serde(rename = "join_ts")] - pub join_ts: String, - #[serde(rename = "linked_accounts")] - pub linked_accounts: Vec, + #[serde(rename = "account_number")] + pub account_number: i32, + /// The URL of this identity's avatar image. + #[serde(rename = "avatar_url")] + pub avatar_url: String, + /// Whether or not this identity is awaiting account deletion. Only visible to when the requestee is this identity. + #[serde(rename = "awaiting_deletion", skip_serializing_if = "Option::is_none")] + pub awaiting_deletion: Option, + /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ + #[serde(rename = "bio")] + pub bio: String, + #[serde(rename = "dev_state", skip_serializing_if = "Option::is_none")] + pub dev_state: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + #[serde(rename = "follower_count")] + pub follower_count: i64, + /// Whether or not the requestee's identity is following this identity. + #[serde(rename = "following")] + pub following: bool, + #[serde(rename = "following_count")] + pub following_count: i64, + #[serde(rename = "games")] + pub games: Vec, + #[serde(rename = "groups")] + pub groups: Vec, + #[serde(rename = "identity_id")] + pub identity_id: uuid::Uuid, + /// Whether or not this identity is an admin. + #[serde(rename = "is_admin")] + pub is_admin: bool, + /// Whether or not this identity is both following and is followed by the requestee's identity. + #[serde(rename = "is_following_me")] + pub is_following_me: bool, + /// Whether or not this game user has been linked through the Rivet dashboard. + #[serde(rename = "is_game_linked", skip_serializing_if = "Option::is_none")] + pub is_game_linked: Option, + #[serde(rename = "is_mutual_following")] + pub is_mutual_following: bool, + /// Whether or not this identity is registered with a linked account. + #[serde(rename = "is_registered")] + pub is_registered: bool, + /// RFC3339 timestamp + #[serde(rename = "join_ts")] + pub join_ts: String, + #[serde(rename = "linked_accounts")] + pub linked_accounts: Vec, } impl IdentityProfile { - /// An identity profile. - pub fn new( - account_number: i32, - avatar_url: String, - bio: String, - display_name: String, - external: crate::models::IdentityExternalLinks, - follower_count: i64, - following: bool, - following_count: i64, - games: Vec, - groups: Vec, - identity_id: uuid::Uuid, - is_admin: bool, - is_following_me: bool, - is_mutual_following: bool, - is_registered: bool, - join_ts: String, - linked_accounts: Vec, - ) -> IdentityProfile { - IdentityProfile { - account_number, - avatar_url, - awaiting_deletion: None, - bio, - dev_state: None, - display_name, - external: Box::new(external), - follower_count, - following, - following_count, - games, - groups, - identity_id, - is_admin, - is_following_me, - is_game_linked: None, - is_mutual_following, - is_registered, - join_ts, - linked_accounts, - } - } + /// An identity profile. + pub fn new(account_number: i32, avatar_url: String, bio: String, display_name: String, external: crate::models::IdentityExternalLinks, follower_count: i64, following: bool, following_count: i64, games: Vec, groups: Vec, identity_id: uuid::Uuid, is_admin: bool, is_following_me: bool, is_mutual_following: bool, is_registered: bool, join_ts: String, linked_accounts: Vec) -> IdentityProfile { + IdentityProfile { + account_number, + avatar_url, + awaiting_deletion: None, + bio, + dev_state: None, + display_name, + external: Box::new(external), + follower_count, + following, + following_count, + games, + groups, + identity_id, + is_admin, + is_following_me, + is_game_linked: None, + is_mutual_following, + is_registered, + join_ts, + linked_accounts, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_set_game_activity_request.rs b/sdks/full/rust/src/models/identity_set_game_activity_request.rs index 1de50baf6e..cb53bb90bb 100644 --- a/sdks/full/rust/src/models/identity_set_game_activity_request.rs +++ b/sdks/full/rust/src/models/identity_set_game_activity_request.rs @@ -4,22 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentitySetGameActivityRequest { - #[serde(rename = "game_activity")] - pub game_activity: Box, + #[serde(rename = "game_activity")] + pub game_activity: Box, } impl IdentitySetGameActivityRequest { - pub fn new( - game_activity: crate::models::IdentityUpdateGameActivity, - ) -> IdentitySetGameActivityRequest { - IdentitySetGameActivityRequest { - game_activity: Box::new(game_activity), - } - } + pub fn new(game_activity: crate::models::IdentityUpdateGameActivity) -> IdentitySetGameActivityRequest { + IdentitySetGameActivityRequest { + game_activity: Box::new(game_activity), + } + } } + + diff --git a/sdks/full/rust/src/models/identity_setup_request.rs b/sdks/full/rust/src/models/identity_setup_request.rs index 89389dd45c..dba1402ee0 100644 --- a/sdks/full/rust/src/models/identity_setup_request.rs +++ b/sdks/full/rust/src/models/identity_setup_request.rs @@ -4,24 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentitySetupRequest { - /// Documentation at https://jwt.io/ - #[serde( - rename = "existing_identity_token", - skip_serializing_if = "Option::is_none" - )] - pub existing_identity_token: Option, + /// Documentation at https://jwt.io/ + #[serde(rename = "existing_identity_token", skip_serializing_if = "Option::is_none")] + pub existing_identity_token: Option, } impl IdentitySetupRequest { - pub fn new() -> IdentitySetupRequest { - IdentitySetupRequest { - existing_identity_token: None, - } - } + pub fn new() -> IdentitySetupRequest { + IdentitySetupRequest { + existing_identity_token: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_setup_response.rs b/sdks/full/rust/src/models/identity_setup_response.rs index aaa588629f..d72d496270 100644 --- a/sdks/full/rust/src/models/identity_setup_response.rs +++ b/sdks/full/rust/src/models/identity_setup_response.rs @@ -4,36 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentitySetupResponse { - #[serde(rename = "game_id")] - pub game_id: uuid::Uuid, - #[serde(rename = "identity")] - pub identity: Box, - /// Documentation at https://jwt.io/ - #[serde(rename = "identity_token")] - pub identity_token: String, - /// RFC3339 timestamp - #[serde(rename = "identity_token_expire_ts")] - pub identity_token_expire_ts: String, + #[serde(rename = "game_id")] + pub game_id: uuid::Uuid, + #[serde(rename = "identity")] + pub identity: Box, + /// Documentation at https://jwt.io/ + #[serde(rename = "identity_token")] + pub identity_token: String, + /// RFC3339 timestamp + #[serde(rename = "identity_token_expire_ts")] + pub identity_token_expire_ts: String, } impl IdentitySetupResponse { - pub fn new( - game_id: uuid::Uuid, - identity: crate::models::IdentityProfile, - identity_token: String, - identity_token_expire_ts: String, - ) -> IdentitySetupResponse { - IdentitySetupResponse { - game_id, - identity: Box::new(identity), - identity_token, - identity_token_expire_ts, - } - } + pub fn new(game_id: uuid::Uuid, identity: crate::models::IdentityProfile, identity_token: String, identity_token_expire_ts: String) -> IdentitySetupResponse { + IdentitySetupResponse { + game_id, + identity: Box::new(identity), + identity_token, + identity_token_expire_ts, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_signup_for_beta_request.rs b/sdks/full/rust/src/models/identity_signup_for_beta_request.rs index f01715e87b..7e4e94dd23 100644 --- a/sdks/full/rust/src/models/identity_signup_for_beta_request.rs +++ b/sdks/full/rust/src/models/identity_signup_for_beta_request.rs @@ -4,37 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentitySignupForBetaRequest { - #[serde(rename = "company_name", skip_serializing_if = "Option::is_none")] - pub company_name: Option, - #[serde(rename = "company_size")] - pub company_size: String, - #[serde(rename = "goals")] - pub goals: String, - #[serde(rename = "name")] - pub name: String, - #[serde(rename = "preferred_tools")] - pub preferred_tools: String, + #[serde(rename = "company_name", skip_serializing_if = "Option::is_none")] + pub company_name: Option, + #[serde(rename = "company_size")] + pub company_size: String, + #[serde(rename = "goals")] + pub goals: String, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "preferred_tools")] + pub preferred_tools: String, } impl IdentitySignupForBetaRequest { - pub fn new( - company_size: String, - goals: String, - name: String, - preferred_tools: String, - ) -> IdentitySignupForBetaRequest { - IdentitySignupForBetaRequest { - company_name: None, - company_size, - goals, - name, - preferred_tools, - } - } + pub fn new(company_size: String, goals: String, name: String, preferred_tools: String) -> IdentitySignupForBetaRequest { + IdentitySignupForBetaRequest { + company_name: None, + company_size, + goals, + name, + preferred_tools, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_status.rs b/sdks/full/rust/src/models/identity_status.rs index ef1bdb6832..992b7897ac 100644 --- a/sdks/full/rust/src/models/identity_status.rs +++ b/sdks/full/rust/src/models/identity_status.rs @@ -4,7 +4,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ @@ -13,26 +13,31 @@ /// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background. #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum IdentityStatus { - #[serde(rename = "online")] - Online, - #[serde(rename = "away")] - Away, - #[serde(rename = "offline")] - Offline, + #[serde(rename = "online")] + Online, + #[serde(rename = "away")] + Away, + #[serde(rename = "offline")] + Offline, + } impl ToString for IdentityStatus { - fn to_string(&self) -> String { - match self { - Self::Online => String::from("online"), - Self::Away => String::from("away"), - Self::Offline => String::from("offline"), - } - } + fn to_string(&self) -> String { + match self { + Self::Online => String::from("online"), + Self::Away => String::from("away"), + Self::Offline => String::from("offline"), + } + } } impl Default for IdentityStatus { - fn default() -> IdentityStatus { - Self::Online - } + fn default() -> IdentityStatus { + Self::Online + } } + + + + diff --git a/sdks/full/rust/src/models/identity_summary.rs b/sdks/full/rust/src/models/identity_summary.rs index c5e27c7e43..d1d1fd63ec 100644 --- a/sdks/full/rust/src/models/identity_summary.rs +++ b/sdks/full/rust/src/models/identity_summary.rs @@ -4,62 +4,56 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentitySummary : An identity summary. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentitySummary { - #[serde(rename = "account_number")] - pub account_number: i32, - /// The URL of this identity's avatar image. - #[serde(rename = "avatar_url")] - pub avatar_url: String, - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - #[serde(rename = "external")] - pub external: Box, - /// Whether or not the requestee's identity is following this identity. - #[serde(rename = "following")] - pub following: bool, - #[serde(rename = "identity_id")] - pub identity_id: uuid::Uuid, - /// Whether or not this identity is both following and is followed by the requestee's identity. - #[serde(rename = "is_following_me")] - pub is_following_me: bool, - #[serde(rename = "is_mutual_following")] - pub is_mutual_following: bool, - /// Whether or not this identity is registered with a linked account. - #[serde(rename = "is_registered")] - pub is_registered: bool, + #[serde(rename = "account_number")] + pub account_number: i32, + /// The URL of this identity's avatar image. + #[serde(rename = "avatar_url")] + pub avatar_url: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + #[serde(rename = "external")] + pub external: Box, + /// Whether or not the requestee's identity is following this identity. + #[serde(rename = "following")] + pub following: bool, + #[serde(rename = "identity_id")] + pub identity_id: uuid::Uuid, + /// Whether or not this identity is both following and is followed by the requestee's identity. + #[serde(rename = "is_following_me")] + pub is_following_me: bool, + #[serde(rename = "is_mutual_following")] + pub is_mutual_following: bool, + /// Whether or not this identity is registered with a linked account. + #[serde(rename = "is_registered")] + pub is_registered: bool, } impl IdentitySummary { - /// An identity summary. - pub fn new( - account_number: i32, - avatar_url: String, - display_name: String, - external: crate::models::IdentityExternalLinks, - following: bool, - identity_id: uuid::Uuid, - is_following_me: bool, - is_mutual_following: bool, - is_registered: bool, - ) -> IdentitySummary { - IdentitySummary { - account_number, - avatar_url, - display_name, - external: Box::new(external), - following, - identity_id, - is_following_me, - is_mutual_following, - is_registered, - } - } + /// An identity summary. + pub fn new(account_number: i32, avatar_url: String, display_name: String, external: crate::models::IdentityExternalLinks, following: bool, identity_id: uuid::Uuid, is_following_me: bool, is_mutual_following: bool, is_registered: bool) -> IdentitySummary { + IdentitySummary { + account_number, + avatar_url, + display_name, + external: Box::new(external), + following, + identity_id, + is_following_me, + is_mutual_following, + is_registered, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_update_game_activity.rs b/sdks/full/rust/src/models/identity_update_game_activity.rs index 3512ba8268..eb5698c4e9 100644 --- a/sdks/full/rust/src/models/identity_update_game_activity.rs +++ b/sdks/full/rust/src/models/identity_update_game_activity.rs @@ -4,42 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// IdentityUpdateGameActivity : Information about the identity's current game. This is information that all other identities can see about what the current identity is doing. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityUpdateGameActivity { - /// A short message about the current game activity. - #[serde(rename = "message", skip_serializing_if = "Option::is_none")] - pub message: Option, - /// JSON data seen only by the given identity and their mutual followers. - #[serde( - rename = "mutual_metadata", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub mutual_metadata: Option>, - /// JSON data seen by anyone. - #[serde( - rename = "public_metadata", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub public_metadata: Option>, + /// A short message about the current game activity. + #[serde(rename = "message", skip_serializing_if = "Option::is_none")] + pub message: Option, + /// JSON data seen only by the given identity and their mutual followers. + #[serde(rename = "mutual_metadata", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub mutual_metadata: Option>, + /// JSON data seen by anyone. + #[serde(rename = "public_metadata", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub public_metadata: Option>, } impl IdentityUpdateGameActivity { - /// Information about the identity's current game. This is information that all other identities can see about what the current identity is doing. - pub fn new() -> IdentityUpdateGameActivity { - IdentityUpdateGameActivity { - message: None, - mutual_metadata: None, - public_metadata: None, - } - } + /// Information about the identity's current game. This is information that all other identities can see about what the current identity is doing. + pub fn new() -> IdentityUpdateGameActivity { + IdentityUpdateGameActivity { + message: None, + mutual_metadata: None, + public_metadata: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_update_profile_request.rs b/sdks/full/rust/src/models/identity_update_profile_request.rs index a85d8a40ab..24d90a91c4 100644 --- a/sdks/full/rust/src/models/identity_update_profile_request.rs +++ b/sdks/full/rust/src/models/identity_update_profile_request.rs @@ -4,28 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityUpdateProfileRequest { - #[serde(rename = "account_number", skip_serializing_if = "Option::is_none")] - pub account_number: Option, - /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ - #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] - pub bio: Option, - /// Represent a resource's readable display name. - #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] - pub display_name: Option, + #[serde(rename = "account_number", skip_serializing_if = "Option::is_none")] + pub account_number: Option, + /// Follows regex ^(?:[^\\n\\r]+\\n?|\\n){1,5}$ + #[serde(rename = "bio", skip_serializing_if = "Option::is_none")] + pub bio: Option, + /// Represent a resource's readable display name. + #[serde(rename = "display_name", skip_serializing_if = "Option::is_none")] + pub display_name: Option, } impl IdentityUpdateProfileRequest { - pub fn new() -> IdentityUpdateProfileRequest { - IdentityUpdateProfileRequest { - account_number: None, - bio: None, - display_name: None, - } - } + pub fn new() -> IdentityUpdateProfileRequest { + IdentityUpdateProfileRequest { + account_number: None, + bio: None, + display_name: None, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_update_status_request.rs b/sdks/full/rust/src/models/identity_update_status_request.rs index 8c41927f5c..c6c79c6881 100644 --- a/sdks/full/rust/src/models/identity_update_status_request.rs +++ b/sdks/full/rust/src/models/identity_update_status_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityUpdateStatusRequest { - #[serde(rename = "status")] - pub status: crate::models::IdentityStatus, + #[serde(rename = "status")] + pub status: crate::models::IdentityStatus, } impl IdentityUpdateStatusRequest { - pub fn new(status: crate::models::IdentityStatus) -> IdentityUpdateStatusRequest { - IdentityUpdateStatusRequest { status } - } + pub fn new(status: crate::models::IdentityStatus) -> IdentityUpdateStatusRequest { + IdentityUpdateStatusRequest { + status, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_validate_profile_response.rs b/sdks/full/rust/src/models/identity_validate_profile_response.rs index 36054e28d4..f08e3f02b1 100644 --- a/sdks/full/rust/src/models/identity_validate_profile_response.rs +++ b/sdks/full/rust/src/models/identity_validate_profile_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityValidateProfileResponse { - #[serde(rename = "errors")] - pub errors: Vec, + #[serde(rename = "errors")] + pub errors: Vec, } impl IdentityValidateProfileResponse { - pub fn new(errors: Vec) -> IdentityValidateProfileResponse { - IdentityValidateProfileResponse { errors } - } + pub fn new(errors: Vec) -> IdentityValidateProfileResponse { + IdentityValidateProfileResponse { + errors, + } + } } + + diff --git a/sdks/full/rust/src/models/identity_watch_events_response.rs b/sdks/full/rust/src/models/identity_watch_events_response.rs index 268c6dd650..e04fd721dc 100644 --- a/sdks/full/rust/src/models/identity_watch_events_response.rs +++ b/sdks/full/rust/src/models/identity_watch_events_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct IdentityWatchEventsResponse { - #[serde(rename = "events")] - pub events: Vec, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "events")] + pub events: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl IdentityWatchEventsResponse { - pub fn new( - events: Vec, - watch: crate::models::WatchResponse, - ) -> IdentityWatchEventsResponse { - IdentityWatchEventsResponse { - events, - watch: Box::new(watch), - } - } + pub fn new(events: Vec, watch: crate::models::WatchResponse) -> IdentityWatchEventsResponse { + IdentityWatchEventsResponse { + events, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_create_lobby_response.rs b/sdks/full/rust/src/models/matchmaker_create_lobby_response.rs index fab017c125..0d1bcc029a 100644 --- a/sdks/full/rust/src/models/matchmaker_create_lobby_response.rs +++ b/sdks/full/rust/src/models/matchmaker_create_lobby_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerCreateLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "lobby")] + pub lobby: Box, + #[serde(rename = "player")] + pub player: Box, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl MatchmakerCreateLobbyResponse { - pub fn new( - lobby: crate::models::MatchmakerJoinLobby, - player: crate::models::MatchmakerJoinPlayer, - ports: ::std::collections::HashMap, - ) -> MatchmakerCreateLobbyResponse { - MatchmakerCreateLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } + pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerCreateLobbyResponse { + MatchmakerCreateLobbyResponse { + lobby: Box::new(lobby), + player: Box::new(player), + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_custom_lobby_publicity.rs b/sdks/full/rust/src/models/matchmaker_custom_lobby_publicity.rs index 8bdb09d8f0..e3dcead796 100644 --- a/sdks/full/rust/src/models/matchmaker_custom_lobby_publicity.rs +++ b/sdks/full/rust/src/models/matchmaker_custom_lobby_publicity.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum MatchmakerCustomLobbyPublicity { - #[serde(rename = "public")] - Public, - #[serde(rename = "private")] - Private, + #[serde(rename = "public")] + Public, + #[serde(rename = "private")] + Private, + } impl ToString for MatchmakerCustomLobbyPublicity { - fn to_string(&self) -> String { - match self { - Self::Public => String::from("public"), - Self::Private => String::from("private"), - } - } + fn to_string(&self) -> String { + match self { + Self::Public => String::from("public"), + Self::Private => String::from("private"), + } + } } impl Default for MatchmakerCustomLobbyPublicity { - fn default() -> MatchmakerCustomLobbyPublicity { - Self::Public - } + fn default() -> MatchmakerCustomLobbyPublicity { + Self::Public + } } + + + + diff --git a/sdks/full/rust/src/models/matchmaker_find_lobby_response.rs b/sdks/full/rust/src/models/matchmaker_find_lobby_response.rs index 9c30250ecf..0a72c11058 100644 --- a/sdks/full/rust/src/models/matchmaker_find_lobby_response.rs +++ b/sdks/full/rust/src/models/matchmaker_find_lobby_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerFindLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "lobby")] + pub lobby: Box, + #[serde(rename = "player")] + pub player: Box, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl MatchmakerFindLobbyResponse { - pub fn new( - lobby: crate::models::MatchmakerJoinLobby, - player: crate::models::MatchmakerJoinPlayer, - ports: ::std::collections::HashMap, - ) -> MatchmakerFindLobbyResponse { - MatchmakerFindLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } + pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerFindLobbyResponse { + MatchmakerFindLobbyResponse { + lobby: Box::new(lobby), + player: Box::new(player), + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_game_mode_info.rs b/sdks/full/rust/src/models/matchmaker_game_mode_info.rs index a45e9f3615..d3d921a688 100644 --- a/sdks/full/rust/src/models/matchmaker_game_mode_info.rs +++ b/sdks/full/rust/src/models/matchmaker_game_mode_info.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerGameModeInfo : A game mode that the player can join. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerGameModeInfo { - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "game_mode_id")] - pub game_mode_id: String, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "game_mode_id")] + pub game_mode_id: String, } impl MatchmakerGameModeInfo { - /// A game mode that the player can join. - pub fn new(game_mode_id: String) -> MatchmakerGameModeInfo { - MatchmakerGameModeInfo { game_mode_id } - } + /// A game mode that the player can join. + pub fn new(game_mode_id: String) -> MatchmakerGameModeInfo { + MatchmakerGameModeInfo { + game_mode_id, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_game_mode_statistics.rs b/sdks/full/rust/src/models/matchmaker_game_mode_statistics.rs index e12272fc15..d2da15d2d9 100644 --- a/sdks/full/rust/src/models/matchmaker_game_mode_statistics.rs +++ b/sdks/full/rust/src/models/matchmaker_game_mode_statistics.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerGameModeStatistics { - #[serde(rename = "player_count")] - pub player_count: i64, - #[serde(rename = "regions")] - pub regions: ::std::collections::HashMap, + #[serde(rename = "player_count")] + pub player_count: i64, + #[serde(rename = "regions")] + pub regions: ::std::collections::HashMap, } impl MatchmakerGameModeStatistics { - pub fn new( - player_count: i64, - regions: ::std::collections::HashMap, - ) -> MatchmakerGameModeStatistics { - MatchmakerGameModeStatistics { - player_count, - regions, - } - } + pub fn new(player_count: i64, regions: ::std::collections::HashMap) -> MatchmakerGameModeStatistics { + MatchmakerGameModeStatistics { + player_count, + regions, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_get_statistics_response.rs b/sdks/full/rust/src/models/matchmaker_get_statistics_response.rs index 3650ef1378..4275e93a5e 100644 --- a/sdks/full/rust/src/models/matchmaker_get_statistics_response.rs +++ b/sdks/full/rust/src/models/matchmaker_get_statistics_response.rs @@ -4,30 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerGetStatisticsResponse { - #[serde(rename = "game_modes")] - pub game_modes: - ::std::collections::HashMap, - #[serde(rename = "player_count")] - pub player_count: i64, + #[serde(rename = "game_modes")] + pub game_modes: ::std::collections::HashMap, + #[serde(rename = "player_count")] + pub player_count: i64, } impl MatchmakerGetStatisticsResponse { - pub fn new( - game_modes: ::std::collections::HashMap< - String, - crate::models::MatchmakerGameModeStatistics, - >, - player_count: i64, - ) -> MatchmakerGetStatisticsResponse { - MatchmakerGetStatisticsResponse { - game_modes, - player_count, - } - } + pub fn new(game_modes: ::std::collections::HashMap, player_count: i64) -> MatchmakerGetStatisticsResponse { + MatchmakerGetStatisticsResponse { + game_modes, + player_count, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_lobby.rs b/sdks/full/rust/src/models/matchmaker_join_lobby.rs index 5b963a7bdc..aaf5bd9cd7 100644 --- a/sdks/full/rust/src/models/matchmaker_join_lobby.rs +++ b/sdks/full/rust/src/models/matchmaker_join_lobby.rs @@ -4,38 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerJoinLobby : A matchmaker lobby. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinLobby { - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - #[serde(rename = "player")] - pub player: Box, - /// **Deprecated** - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, - #[serde(rename = "region")] - pub region: Box, + #[serde(rename = "lobby_id")] + pub lobby_id: uuid::Uuid, + #[serde(rename = "player")] + pub player: Box, + /// **Deprecated** + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, + #[serde(rename = "region")] + pub region: Box, } impl MatchmakerJoinLobby { - /// A matchmaker lobby. - pub fn new( - lobby_id: uuid::Uuid, - player: crate::models::MatchmakerJoinPlayer, - ports: ::std::collections::HashMap, - region: crate::models::MatchmakerJoinRegion, - ) -> MatchmakerJoinLobby { - MatchmakerJoinLobby { - lobby_id, - player: Box::new(player), - ports, - region: Box::new(region), - } - } + /// A matchmaker lobby. + pub fn new(lobby_id: uuid::Uuid, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap, region: crate::models::MatchmakerJoinRegion) -> MatchmakerJoinLobby { + MatchmakerJoinLobby { + lobby_id, + player: Box::new(player), + ports, + region: Box::new(region), + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_lobby_response.rs b/sdks/full/rust/src/models/matchmaker_join_lobby_response.rs index c502c5a62f..d284339b25 100644 --- a/sdks/full/rust/src/models/matchmaker_join_lobby_response.rs +++ b/sdks/full/rust/src/models/matchmaker_join_lobby_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "lobby")] + pub lobby: Box, + #[serde(rename = "player")] + pub player: Box, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl MatchmakerJoinLobbyResponse { - pub fn new( - lobby: crate::models::MatchmakerJoinLobby, - player: crate::models::MatchmakerJoinPlayer, - ports: ::std::collections::HashMap, - ) -> MatchmakerJoinLobbyResponse { - MatchmakerJoinLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } + pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerJoinLobbyResponse { + MatchmakerJoinLobbyResponse { + lobby: Box::new(lobby), + player: Box::new(player), + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_player.rs b/sdks/full/rust/src/models/matchmaker_join_player.rs index 3645390464..198434b8ac 100644 --- a/sdks/full/rust/src/models/matchmaker_join_player.rs +++ b/sdks/full/rust/src/models/matchmaker_join_player.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerJoinPlayer : A matchmaker lobby player. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinPlayer { - /// Documentation at https://jwt.io/ - #[serde(rename = "token")] - pub token: String, + /// Documentation at https://jwt.io/ + #[serde(rename = "token")] + pub token: String, } impl MatchmakerJoinPlayer { - /// A matchmaker lobby player. - pub fn new(token: String) -> MatchmakerJoinPlayer { - MatchmakerJoinPlayer { token } - } + /// A matchmaker lobby player. + pub fn new(token: String) -> MatchmakerJoinPlayer { + MatchmakerJoinPlayer { + token, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_port.rs b/sdks/full/rust/src/models/matchmaker_join_port.rs index cdb1083dd9..86e07f170a 100644 --- a/sdks/full/rust/src/models/matchmaker_join_port.rs +++ b/sdks/full/rust/src/models/matchmaker_join_port.rs @@ -4,35 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinPort { - /// The host for the given port. Will be null if using a port range. - #[serde(rename = "host", skip_serializing_if = "Option::is_none")] - pub host: Option, - #[serde(rename = "hostname")] - pub hostname: String, - /// Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. - #[serde(rename = "is_tls")] - pub is_tls: bool, - /// The port number for this lobby. Will be null if using a port range. - #[serde(rename = "port", skip_serializing_if = "Option::is_none")] - pub port: Option, - #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] - pub port_range: Option>, + /// The host for the given port. Will be null if using a port range. + #[serde(rename = "host", skip_serializing_if = "Option::is_none")] + pub host: Option, + #[serde(rename = "hostname")] + pub hostname: String, + /// Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. + #[serde(rename = "is_tls")] + pub is_tls: bool, + /// The port number for this lobby. Will be null if using a port range. + #[serde(rename = "port", skip_serializing_if = "Option::is_none")] + pub port: Option, + #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] + pub port_range: Option>, } impl MatchmakerJoinPort { - pub fn new(hostname: String, is_tls: bool) -> MatchmakerJoinPort { - MatchmakerJoinPort { - host: None, - hostname, - is_tls, - port: None, - port_range: None, - } - } + pub fn new(hostname: String, is_tls: bool) -> MatchmakerJoinPort { + MatchmakerJoinPort { + host: None, + hostname, + is_tls, + port: None, + port_range: None, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_port_range.rs b/sdks/full/rust/src/models/matchmaker_join_port_range.rs index cf8eb661fb..5b793d5c52 100644 --- a/sdks/full/rust/src/models/matchmaker_join_port_range.rs +++ b/sdks/full/rust/src/models/matchmaker_join_port_range.rs @@ -4,25 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerJoinPortRange : Inclusive range of ports that can be connected to. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinPortRange { - /// Maximum port that can be connected to. Inclusive range. - #[serde(rename = "max")] - pub max: i32, - /// Minimum port that can be connected to. Inclusive range. - #[serde(rename = "min")] - pub min: i32, + /// Maximum port that can be connected to. Inclusive range. + #[serde(rename = "max")] + pub max: i32, + /// Minimum port that can be connected to. Inclusive range. + #[serde(rename = "min")] + pub min: i32, } impl MatchmakerJoinPortRange { - /// Inclusive range of ports that can be connected to. - pub fn new(max: i32, min: i32) -> MatchmakerJoinPortRange { - MatchmakerJoinPortRange { max, min } - } + /// Inclusive range of ports that can be connected to. + pub fn new(max: i32, min: i32) -> MatchmakerJoinPortRange { + MatchmakerJoinPortRange { + max, + min, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_join_region.rs b/sdks/full/rust/src/models/matchmaker_join_region.rs index 79f4b2ff46..7f38d680cf 100644 --- a/sdks/full/rust/src/models/matchmaker_join_region.rs +++ b/sdks/full/rust/src/models/matchmaker_join_region.rs @@ -4,28 +4,32 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerJoinRegion : A matchmaker lobby region. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerJoinRegion { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "region_id")] - pub region_id: String, + /// Represent a resource's readable display name. + #[serde(rename = "display_name")] + pub display_name: String, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "region_id")] + pub region_id: String, } impl MatchmakerJoinRegion { - /// A matchmaker lobby region. - pub fn new(display_name: String, region_id: String) -> MatchmakerJoinRegion { - MatchmakerJoinRegion { - display_name, - region_id, - } - } + /// A matchmaker lobby region. + pub fn new(display_name: String, region_id: String) -> MatchmakerJoinRegion { + MatchmakerJoinRegion { + display_name, + region_id, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_list_lobbies_response.rs b/sdks/full/rust/src/models/matchmaker_list_lobbies_response.rs index 3ead5b1d9b..181d6b0bd0 100644 --- a/sdks/full/rust/src/models/matchmaker_list_lobbies_response.rs +++ b/sdks/full/rust/src/models/matchmaker_list_lobbies_response.rs @@ -4,30 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerListLobbiesResponse { - #[serde(rename = "game_modes")] - pub game_modes: Vec, - #[serde(rename = "lobbies")] - pub lobbies: Vec, - #[serde(rename = "regions")] - pub regions: Vec, + #[serde(rename = "game_modes")] + pub game_modes: Vec, + #[serde(rename = "lobbies")] + pub lobbies: Vec, + #[serde(rename = "regions")] + pub regions: Vec, } impl MatchmakerListLobbiesResponse { - pub fn new( - game_modes: Vec, - lobbies: Vec, - regions: Vec, - ) -> MatchmakerListLobbiesResponse { - MatchmakerListLobbiesResponse { - game_modes, - lobbies, - regions, - } - } + pub fn new(game_modes: Vec, lobbies: Vec, regions: Vec) -> MatchmakerListLobbiesResponse { + MatchmakerListLobbiesResponse { + game_modes, + lobbies, + regions, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_list_regions_response.rs b/sdks/full/rust/src/models/matchmaker_list_regions_response.rs index c418c2237a..07eae13752 100644 --- a/sdks/full/rust/src/models/matchmaker_list_regions_response.rs +++ b/sdks/full/rust/src/models/matchmaker_list_regions_response.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerListRegionsResponse { - #[serde(rename = "regions")] - pub regions: Vec, + #[serde(rename = "regions")] + pub regions: Vec, } impl MatchmakerListRegionsResponse { - pub fn new(regions: Vec) -> MatchmakerListRegionsResponse { - MatchmakerListRegionsResponse { regions } - } + pub fn new(regions: Vec) -> MatchmakerListRegionsResponse { + MatchmakerListRegionsResponse { + regions, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_lobbies_create_request.rs b/sdks/full/rust/src/models/matchmaker_lobbies_create_request.rs index c4b058ecb7..4a61128a8f 100644 --- a/sdks/full/rust/src/models/matchmaker_lobbies_create_request.rs +++ b/sdks/full/rust/src/models/matchmaker_lobbies_create_request.rs @@ -4,51 +4,46 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerLobbiesCreateRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "game_mode")] - pub game_mode: String, - #[serde( - rename = "lobby_config", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub lobby_config: Option>, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] - pub publicity: Option, - #[serde(rename = "region", skip_serializing_if = "Option::is_none")] - pub region: Option, - #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option<::std::collections::HashMap>, - #[serde( - rename = "verification_data", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub verification_data: Option>, + #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] + pub captcha: Option>, + #[serde(rename = "game_mode")] + pub game_mode: String, + #[serde(rename = "lobby_config", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub lobby_config: Option>, + #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] + pub max_players: Option, + #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] + pub publicity: Option, + #[serde(rename = "region", skip_serializing_if = "Option::is_none")] + pub region: Option, + #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] + pub tags: Option<::std::collections::HashMap>, + #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub verification_data: Option>, } impl MatchmakerLobbiesCreateRequest { - pub fn new(game_mode: String) -> MatchmakerLobbiesCreateRequest { - MatchmakerLobbiesCreateRequest { - captcha: None, - game_mode, - lobby_config: None, - max_players: None, - publicity: None, - region: None, - tags: None, - verification_data: None, - } - } + pub fn new(game_mode: String) -> MatchmakerLobbiesCreateRequest { + MatchmakerLobbiesCreateRequest { + captcha: None, + game_mode, + lobby_config: None, + max_players: None, + publicity: None, + region: None, + tags: None, + verification_data: None, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_lobbies_find_request.rs b/sdks/full/rust/src/models/matchmaker_lobbies_find_request.rs index f76487ae22..6761c70629 100644 --- a/sdks/full/rust/src/models/matchmaker_lobbies_find_request.rs +++ b/sdks/full/rust/src/models/matchmaker_lobbies_find_request.rs @@ -4,46 +4,43 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerLobbiesFindRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "game_modes")] - pub game_modes: Vec, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde( - rename = "prevent_auto_create_lobby", - skip_serializing_if = "Option::is_none" - )] - pub prevent_auto_create_lobby: Option, - #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] - pub regions: Option>, - #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option<::std::collections::HashMap>, - #[serde( - rename = "verification_data", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub verification_data: Option>, + #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] + pub captcha: Option>, + #[serde(rename = "game_modes")] + pub game_modes: Vec, + #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] + pub max_players: Option, + #[serde(rename = "prevent_auto_create_lobby", skip_serializing_if = "Option::is_none")] + pub prevent_auto_create_lobby: Option, + #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] + pub regions: Option>, + #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] + pub tags: Option<::std::collections::HashMap>, + #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub verification_data: Option>, } impl MatchmakerLobbiesFindRequest { - pub fn new(game_modes: Vec) -> MatchmakerLobbiesFindRequest { - MatchmakerLobbiesFindRequest { - captcha: None, - game_modes, - max_players: None, - prevent_auto_create_lobby: None, - regions: None, - tags: None, - verification_data: None, - } - } + pub fn new(game_modes: Vec) -> MatchmakerLobbiesFindRequest { + MatchmakerLobbiesFindRequest { + captcha: None, + game_modes, + max_players: None, + prevent_auto_create_lobby: None, + regions: None, + tags: None, + verification_data: None, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_lobbies_join_request.rs b/sdks/full/rust/src/models/matchmaker_lobbies_join_request.rs index f029003f63..6f622e00a1 100644 --- a/sdks/full/rust/src/models/matchmaker_lobbies_join_request.rs +++ b/sdks/full/rust/src/models/matchmaker_lobbies_join_request.rs @@ -4,31 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerLobbiesJoinRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "lobby_id")] - pub lobby_id: String, - #[serde( - rename = "verification_data", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub verification_data: Option>, + #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] + pub captcha: Option>, + #[serde(rename = "lobby_id")] + pub lobby_id: String, + #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub verification_data: Option>, } impl MatchmakerLobbiesJoinRequest { - pub fn new(lobby_id: String) -> MatchmakerLobbiesJoinRequest { - MatchmakerLobbiesJoinRequest { - captcha: None, - lobby_id, - verification_data: None, - } - } + pub fn new(lobby_id: String) -> MatchmakerLobbiesJoinRequest { + MatchmakerLobbiesJoinRequest { + captcha: None, + lobby_id, + verification_data: None, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_lobbies_set_closed_request.rs b/sdks/full/rust/src/models/matchmaker_lobbies_set_closed_request.rs index 196665e468..32b2a4cfe2 100644 --- a/sdks/full/rust/src/models/matchmaker_lobbies_set_closed_request.rs +++ b/sdks/full/rust/src/models/matchmaker_lobbies_set_closed_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerLobbiesSetClosedRequest { - #[serde(rename = "is_closed")] - pub is_closed: bool, + #[serde(rename = "is_closed")] + pub is_closed: bool, } impl MatchmakerLobbiesSetClosedRequest { - pub fn new(is_closed: bool) -> MatchmakerLobbiesSetClosedRequest { - MatchmakerLobbiesSetClosedRequest { is_closed } - } + pub fn new(is_closed: bool) -> MatchmakerLobbiesSetClosedRequest { + MatchmakerLobbiesSetClosedRequest { + is_closed, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_lobby_info.rs b/sdks/full/rust/src/models/matchmaker_lobby_info.rs index a8b03ff8c7..bdae0cba81 100644 --- a/sdks/full/rust/src/models/matchmaker_lobby_info.rs +++ b/sdks/full/rust/src/models/matchmaker_lobby_info.rs @@ -4,57 +4,48 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerLobbyInfo : A public lobby in the lobby list. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerLobbyInfo { - #[serde(rename = "game_mode_id")] - pub game_mode_id: String, - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - #[serde(rename = "max_players_direct")] - pub max_players_direct: i32, - #[serde(rename = "max_players_normal")] - pub max_players_normal: i32, - #[serde(rename = "max_players_party")] - pub max_players_party: i32, - #[serde(rename = "region_id")] - pub region_id: String, - #[serde( - rename = "state", - default, - with = "::serde_with::rust::double_option", - skip_serializing_if = "Option::is_none" - )] - pub state: Option>, - #[serde(rename = "total_player_count")] - pub total_player_count: i32, + #[serde(rename = "game_mode_id")] + pub game_mode_id: String, + #[serde(rename = "lobby_id")] + pub lobby_id: uuid::Uuid, + #[serde(rename = "max_players_direct")] + pub max_players_direct: i32, + #[serde(rename = "max_players_normal")] + pub max_players_normal: i32, + #[serde(rename = "max_players_party")] + pub max_players_party: i32, + #[serde(rename = "region_id")] + pub region_id: String, + #[serde(rename = "state", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] + pub state: Option>, + #[serde(rename = "total_player_count")] + pub total_player_count: i32, } impl MatchmakerLobbyInfo { - /// A public lobby in the lobby list. - pub fn new( - game_mode_id: String, - lobby_id: uuid::Uuid, - max_players_direct: i32, - max_players_normal: i32, - max_players_party: i32, - region_id: String, - total_player_count: i32, - ) -> MatchmakerLobbyInfo { - MatchmakerLobbyInfo { - game_mode_id, - lobby_id, - max_players_direct, - max_players_normal, - max_players_party, - region_id, - state: None, - total_player_count, - } - } + /// A public lobby in the lobby list. + pub fn new(game_mode_id: String, lobby_id: uuid::Uuid, max_players_direct: i32, max_players_normal: i32, max_players_party: i32, region_id: String, total_player_count: i32) -> MatchmakerLobbyInfo { + MatchmakerLobbyInfo { + game_mode_id, + lobby_id, + max_players_direct, + max_players_normal, + max_players_party, + region_id, + state: None, + total_player_count, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_players_connected_request.rs b/sdks/full/rust/src/models/matchmaker_players_connected_request.rs index 00930513c4..c5de54c33c 100644 --- a/sdks/full/rust/src/models/matchmaker_players_connected_request.rs +++ b/sdks/full/rust/src/models/matchmaker_players_connected_request.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerPlayersConnectedRequest { - #[serde(rename = "player_token")] - pub player_token: String, + #[serde(rename = "player_token")] + pub player_token: String, } impl MatchmakerPlayersConnectedRequest { - pub fn new(player_token: String) -> MatchmakerPlayersConnectedRequest { - MatchmakerPlayersConnectedRequest { player_token } - } + pub fn new(player_token: String) -> MatchmakerPlayersConnectedRequest { + MatchmakerPlayersConnectedRequest { + player_token, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_region_info.rs b/sdks/full/rust/src/models/matchmaker_region_info.rs index 6329a0d4b3..ed5df899d6 100644 --- a/sdks/full/rust/src/models/matchmaker_region_info.rs +++ b/sdks/full/rust/src/models/matchmaker_region_info.rs @@ -4,44 +4,42 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// MatchmakerRegionInfo : A region that the player can connect to. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerRegionInfo { - #[serde(rename = "datacenter_coord")] - pub datacenter_coord: Box, - #[serde(rename = "datacenter_distance_from_client")] - pub datacenter_distance_from_client: Box, - /// Represent a resource's readable display name. - #[serde(rename = "provider_display_name")] - pub provider_display_name: String, - /// Represent a resource's readable display name. - #[serde(rename = "region_display_name")] - pub region_display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "region_id")] - pub region_id: String, + #[serde(rename = "datacenter_coord")] + pub datacenter_coord: Box, + #[serde(rename = "datacenter_distance_from_client")] + pub datacenter_distance_from_client: Box, + /// Represent a resource's readable display name. + #[serde(rename = "provider_display_name")] + pub provider_display_name: String, + /// Represent a resource's readable display name. + #[serde(rename = "region_display_name")] + pub region_display_name: String, + /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. + #[serde(rename = "region_id")] + pub region_id: String, } impl MatchmakerRegionInfo { - /// A region that the player can connect to. - pub fn new( - datacenter_coord: crate::models::GeoCoord, - datacenter_distance_from_client: crate::models::GeoDistance, - provider_display_name: String, - region_display_name: String, - region_id: String, - ) -> MatchmakerRegionInfo { - MatchmakerRegionInfo { - datacenter_coord: Box::new(datacenter_coord), - datacenter_distance_from_client: Box::new(datacenter_distance_from_client), - provider_display_name, - region_display_name, - region_id, - } - } + /// A region that the player can connect to. + pub fn new(datacenter_coord: crate::models::GeoCoord, datacenter_distance_from_client: crate::models::GeoDistance, provider_display_name: String, region_display_name: String, region_id: String) -> MatchmakerRegionInfo { + MatchmakerRegionInfo { + datacenter_coord: Box::new(datacenter_coord), + datacenter_distance_from_client: Box::new(datacenter_distance_from_client), + provider_display_name, + region_display_name, + region_id, + } + } } + + diff --git a/sdks/full/rust/src/models/matchmaker_region_statistics.rs b/sdks/full/rust/src/models/matchmaker_region_statistics.rs index b98695d5c1..1f213d2419 100644 --- a/sdks/full/rust/src/models/matchmaker_region_statistics.rs +++ b/sdks/full/rust/src/models/matchmaker_region_statistics.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MatchmakerRegionStatistics { - #[serde(rename = "player_count")] - pub player_count: i64, + #[serde(rename = "player_count")] + pub player_count: i64, } impl MatchmakerRegionStatistics { - pub fn new(player_count: i64) -> MatchmakerRegionStatistics { - MatchmakerRegionStatistics { player_count } - } + pub fn new(player_count: i64) -> MatchmakerRegionStatistics { + MatchmakerRegionStatistics { + player_count, + } + } } + + diff --git a/sdks/full/rust/src/models/mod.rs b/sdks/full/rust/src/models/mod.rs index b446519041..68b7365a24 100644 --- a/sdks/full/rust/src/models/mod.rs +++ b/sdks/full/rust/src/models/mod.rs @@ -16,14 +16,14 @@ pub mod actor_create_actor_response; pub use self::actor_create_actor_response::ActorCreateActorResponse; pub mod actor_create_actor_runtime_request; pub use self::actor_create_actor_runtime_request::ActorCreateActorRuntimeRequest; -pub mod actor_game_guard_routing; -pub use self::actor_game_guard_routing::ActorGameGuardRouting; pub mod actor_get_actor_logs_response; pub use self::actor_get_actor_logs_response::ActorGetActorLogsResponse; pub mod actor_get_actor_response; pub use self::actor_get_actor_response::ActorGetActorResponse; pub mod actor_get_build_response; pub use self::actor_get_build_response::ActorGetBuildResponse; +pub mod actor_guard_routing; +pub use self::actor_guard_routing::ActorGuardRouting; pub mod actor_lifecycle; pub use self::actor_lifecycle::ActorLifecycle; pub mod actor_list_actors_response; diff --git a/sdks/full/rust/src/models/portal_get_game_profile_response.rs b/sdks/full/rust/src/models/portal_get_game_profile_response.rs index 8e42244a81..956b0da212 100644 --- a/sdks/full/rust/src/models/portal_get_game_profile_response.rs +++ b/sdks/full/rust/src/models/portal_get_game_profile_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortalGetGameProfileResponse { - #[serde(rename = "game")] - pub game: Box, - #[serde(rename = "watch")] - pub watch: Box, + #[serde(rename = "game")] + pub game: Box, + #[serde(rename = "watch")] + pub watch: Box, } impl PortalGetGameProfileResponse { - pub fn new( - game: crate::models::GameProfile, - watch: crate::models::WatchResponse, - ) -> PortalGetGameProfileResponse { - PortalGetGameProfileResponse { - game: Box::new(game), - watch: Box::new(watch), - } - } + pub fn new(game: crate::models::GameProfile, watch: crate::models::WatchResponse) -> PortalGetGameProfileResponse { + PortalGetGameProfileResponse { + game: Box::new(game), + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/portal_get_suggested_games_response.rs b/sdks/full/rust/src/models/portal_get_suggested_games_response.rs index f3eaad952a..a663aeaac5 100644 --- a/sdks/full/rust/src/models/portal_get_suggested_games_response.rs +++ b/sdks/full/rust/src/models/portal_get_suggested_games_response.rs @@ -4,27 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortalGetSuggestedGamesResponse { - /// A list of game summaries. - #[serde(rename = "games")] - pub games: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// A list of game summaries. + #[serde(rename = "games")] + pub games: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl PortalGetSuggestedGamesResponse { - pub fn new( - games: Vec, - watch: crate::models::WatchResponse, - ) -> PortalGetSuggestedGamesResponse { - PortalGetSuggestedGamesResponse { - games, - watch: Box::new(watch), - } - } + pub fn new(games: Vec, watch: crate::models::WatchResponse) -> PortalGetSuggestedGamesResponse { + PortalGetSuggestedGamesResponse { + games, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/portal_notification_register_firebase_service.rs b/sdks/full/rust/src/models/portal_notification_register_firebase_service.rs index 89005a210b..213357992e 100644 --- a/sdks/full/rust/src/models/portal_notification_register_firebase_service.rs +++ b/sdks/full/rust/src/models/portal_notification_register_firebase_service.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortalNotificationRegisterFirebaseService { - #[serde(rename = "access_key")] - pub access_key: String, + #[serde(rename = "access_key")] + pub access_key: String, } impl PortalNotificationRegisterFirebaseService { - pub fn new(access_key: String) -> PortalNotificationRegisterFirebaseService { - PortalNotificationRegisterFirebaseService { access_key } - } + pub fn new(access_key: String) -> PortalNotificationRegisterFirebaseService { + PortalNotificationRegisterFirebaseService { + access_key, + } + } } + + diff --git a/sdks/full/rust/src/models/portal_notification_register_service.rs b/sdks/full/rust/src/models/portal_notification_register_service.rs index e9232ea5ec..1058fd743b 100644 --- a/sdks/full/rust/src/models/portal_notification_register_service.rs +++ b/sdks/full/rust/src/models/portal_notification_register_service.rs @@ -4,18 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortalNotificationRegisterService { - #[serde(rename = "firebase", skip_serializing_if = "Option::is_none")] - pub firebase: Option>, + #[serde(rename = "firebase", skip_serializing_if = "Option::is_none")] + pub firebase: Option>, } impl PortalNotificationRegisterService { - pub fn new() -> PortalNotificationRegisterService { - PortalNotificationRegisterService { firebase: None } - } + pub fn new() -> PortalNotificationRegisterService { + PortalNotificationRegisterService { + firebase: None, + } + } } + + diff --git a/sdks/full/rust/src/models/portal_notification_unregister_service.rs b/sdks/full/rust/src/models/portal_notification_unregister_service.rs index f7d60722c9..d4bda04c73 100644 --- a/sdks/full/rust/src/models/portal_notification_unregister_service.rs +++ b/sdks/full/rust/src/models/portal_notification_unregister_service.rs @@ -4,27 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum PortalNotificationUnregisterService { - #[serde(rename = "firebase")] - Firebase, + #[serde(rename = "firebase")] + Firebase, + } impl ToString for PortalNotificationUnregisterService { - fn to_string(&self) -> String { - match self { - Self::Firebase => String::from("firebase"), - } - } + fn to_string(&self) -> String { + match self { + Self::Firebase => String::from("firebase"), + } + } } impl Default for PortalNotificationUnregisterService { - fn default() -> PortalNotificationUnregisterService { - Self::Firebase - } + fn default() -> PortalNotificationUnregisterService { + Self::Firebase + } } + + + + diff --git a/sdks/full/rust/src/models/provision_datacenters_get_tls_response.rs b/sdks/full/rust/src/models/provision_datacenters_get_tls_response.rs index c74afabfb0..a2039a21ba 100644 --- a/sdks/full/rust/src/models/provision_datacenters_get_tls_response.rs +++ b/sdks/full/rust/src/models/provision_datacenters_get_tls_response.rs @@ -4,26 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ProvisionDatacentersGetTlsResponse { - #[serde(rename = "job_cert_pem")] - pub job_cert_pem: String, - #[serde(rename = "job_private_key_pem")] - pub job_private_key_pem: String, + #[serde(rename = "job_cert_pem")] + pub job_cert_pem: String, + #[serde(rename = "job_private_key_pem")] + pub job_private_key_pem: String, } impl ProvisionDatacentersGetTlsResponse { - pub fn new( - job_cert_pem: String, - job_private_key_pem: String, - ) -> ProvisionDatacentersGetTlsResponse { - ProvisionDatacentersGetTlsResponse { - job_cert_pem, - job_private_key_pem, - } - } + pub fn new(job_cert_pem: String, job_private_key_pem: String) -> ProvisionDatacentersGetTlsResponse { + ProvisionDatacentersGetTlsResponse { + job_cert_pem, + job_private_key_pem, + } + } } + + diff --git a/sdks/full/rust/src/models/provision_servers_get_info_response.rs b/sdks/full/rust/src/models/provision_servers_get_info_response.rs index a328594c55..7c7048be3d 100644 --- a/sdks/full/rust/src/models/provision_servers_get_info_response.rs +++ b/sdks/full/rust/src/models/provision_servers_get_info_response.rs @@ -4,42 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ProvisionServersGetInfoResponse { - #[serde(rename = "cluster_id")] - pub cluster_id: uuid::Uuid, - #[serde(rename = "datacenter_id")] - pub datacenter_id: uuid::Uuid, - #[serde(rename = "name")] - pub name: String, - #[serde(rename = "public_ip")] - pub public_ip: String, - #[serde(rename = "server_id")] - pub server_id: uuid::Uuid, - #[serde(rename = "vlan_ip")] - pub vlan_ip: String, + #[serde(rename = "cluster_id")] + pub cluster_id: uuid::Uuid, + #[serde(rename = "datacenter_id")] + pub datacenter_id: uuid::Uuid, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "public_ip")] + pub public_ip: String, + #[serde(rename = "server_id")] + pub server_id: uuid::Uuid, + #[serde(rename = "vlan_ip")] + pub vlan_ip: String, } impl ProvisionServersGetInfoResponse { - pub fn new( - cluster_id: uuid::Uuid, - datacenter_id: uuid::Uuid, - name: String, - public_ip: String, - server_id: uuid::Uuid, - vlan_ip: String, - ) -> ProvisionServersGetInfoResponse { - ProvisionServersGetInfoResponse { - cluster_id, - datacenter_id, - name, - public_ip, - server_id, - vlan_ip, - } - } + pub fn new(cluster_id: uuid::Uuid, datacenter_id: uuid::Uuid, name: String, public_ip: String, server_id: uuid::Uuid, vlan_ip: String) -> ProvisionServersGetInfoResponse { + ProvisionServersGetInfoResponse { + cluster_id, + datacenter_id, + name, + public_ip, + server_id, + vlan_ip, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_build.rs b/sdks/full/rust/src/models/servers_build.rs index fb591dbeb5..fdd8d54e66 100644 --- a/sdks/full/rust/src/models/servers_build.rs +++ b/sdks/full/rust/src/models/servers_build.rs @@ -4,41 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersBuild { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// RFC3339 timestamp - #[serde(rename = "created_at")] - pub created_at: String, - #[serde(rename = "id")] - pub id: uuid::Uuid, - #[serde(rename = "name")] - pub name: String, - /// Tags of this build - #[serde(rename = "tags")] - pub tags: ::std::collections::HashMap, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "created_at")] + pub created_at: String, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "name")] + pub name: String, + /// Tags of this build + #[serde(rename = "tags")] + pub tags: ::std::collections::HashMap, } impl ServersBuild { - pub fn new( - content_length: i64, - created_at: String, - id: uuid::Uuid, - name: String, - tags: ::std::collections::HashMap, - ) -> ServersBuild { - ServersBuild { - content_length, - created_at, - id, - name, - tags, - } - } + pub fn new(content_length: i64, created_at: String, id: uuid::Uuid, name: String, tags: ::std::collections::HashMap) -> ServersBuild { + ServersBuild { + content_length, + created_at, + id, + name, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_build_compression.rs b/sdks/full/rust/src/models/servers_build_compression.rs index ab301d44e2..fd549d6279 100644 --- a/sdks/full/rust/src/models/servers_build_compression.rs +++ b/sdks/full/rust/src/models/servers_build_compression.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ServersBuildCompression { - #[serde(rename = "none")] - None, - #[serde(rename = "lz4")] - Lz4, + #[serde(rename = "none")] + None, + #[serde(rename = "lz4")] + Lz4, + } impl ToString for ServersBuildCompression { - fn to_string(&self) -> String { - match self { - Self::None => String::from("none"), - Self::Lz4 => String::from("lz4"), - } - } + fn to_string(&self) -> String { + match self { + Self::None => String::from("none"), + Self::Lz4 => String::from("lz4"), + } + } } impl Default for ServersBuildCompression { - fn default() -> ServersBuildCompression { - Self::None - } + fn default() -> ServersBuildCompression { + Self::None + } } + + + + diff --git a/sdks/full/rust/src/models/servers_build_kind.rs b/sdks/full/rust/src/models/servers_build_kind.rs index e79562ffe6..853abbb0e7 100644 --- a/sdks/full/rust/src/models/servers_build_kind.rs +++ b/sdks/full/rust/src/models/servers_build_kind.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ServersBuildKind { - #[serde(rename = "docker_image")] - DockerImage, - #[serde(rename = "oci_bundle")] - OciBundle, + #[serde(rename = "docker_image")] + DockerImage, + #[serde(rename = "oci_bundle")] + OciBundle, + } impl ToString for ServersBuildKind { - fn to_string(&self) -> String { - match self { - Self::DockerImage => String::from("docker_image"), - Self::OciBundle => String::from("oci_bundle"), - } - } + fn to_string(&self) -> String { + match self { + Self::DockerImage => String::from("docker_image"), + Self::OciBundle => String::from("oci_bundle"), + } + } } impl Default for ServersBuildKind { - fn default() -> ServersBuildKind { - Self::DockerImage - } + fn default() -> ServersBuildKind { + Self::DockerImage + } } + + + + diff --git a/sdks/full/rust/src/models/servers_create_build_request.rs b/sdks/full/rust/src/models/servers_create_build_request.rs index d0d067ca91..eb128a33f3 100644 --- a/sdks/full/rust/src/models/servers_create_build_request.rs +++ b/sdks/full/rust/src/models/servers_create_build_request.rs @@ -4,46 +4,44 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateBuildRequest { - #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] - pub compression: Option, - #[serde(rename = "image_file")] - pub image_file: Box, - /// A tag given to the game build. - #[serde(rename = "image_tag")] - pub image_tag: String, - #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] - pub kind: Option, - #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] - pub multipart_upload: Option, - #[serde(rename = "name")] - pub name: String, - #[serde( - rename = "prewarm_datacenters", - skip_serializing_if = "Option::is_none" - )] - pub prewarm_datacenters: Option>, + #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] + pub compression: Option, + #[serde(rename = "image_file")] + pub image_file: Box, + /// A tag given to the game build. + #[serde(rename = "image_tag")] + pub image_tag: String, + #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] + pub kind: Option, + #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] + pub multipart_upload: Option, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "prewarm_datacenters", skip_serializing_if = "Option::is_none")] + pub prewarm_datacenters: Option>, } impl ServersCreateBuildRequest { - pub fn new( - image_file: crate::models::UploadPrepareFile, - image_tag: String, - name: String, - ) -> ServersCreateBuildRequest { - ServersCreateBuildRequest { - compression: None, - image_file: Box::new(image_file), - image_tag, - kind: None, - multipart_upload: None, - name, - prewarm_datacenters: None, - } - } + pub fn new(image_file: crate::models::UploadPrepareFile, image_tag: String, name: String) -> ServersCreateBuildRequest { + ServersCreateBuildRequest { + compression: None, + image_file: Box::new(image_file), + image_tag, + kind: None, + multipart_upload: None, + name, + prewarm_datacenters: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_build_response.rs b/sdks/full/rust/src/models/servers_create_build_response.rs index ef947a0bd9..c277171564 100644 --- a/sdks/full/rust/src/models/servers_create_build_response.rs +++ b/sdks/full/rust/src/models/servers_create_build_response.rs @@ -4,32 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateBuildResponse { - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde( - rename = "image_presigned_request", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_request: Option>, - #[serde( - rename = "image_presigned_requests", - skip_serializing_if = "Option::is_none" - )] - pub image_presigned_requests: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "image_presigned_request", skip_serializing_if = "Option::is_none")] + pub image_presigned_request: Option>, + #[serde(rename = "image_presigned_requests", skip_serializing_if = "Option::is_none")] + pub image_presigned_requests: Option>, } impl ServersCreateBuildResponse { - pub fn new(build: uuid::Uuid) -> ServersCreateBuildResponse { - ServersCreateBuildResponse { - build, - image_presigned_request: None, - image_presigned_requests: None, - } - } + pub fn new(build: uuid::Uuid) -> ServersCreateBuildResponse { + ServersCreateBuildResponse { + build, + image_presigned_request: None, + image_presigned_requests: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_server_network_request.rs b/sdks/full/rust/src/models/servers_create_server_network_request.rs index 78756844c5..d469cc181d 100644 --- a/sdks/full/rust/src/models/servers_create_server_network_request.rs +++ b/sdks/full/rust/src/models/servers_create_server_network_request.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateServerNetworkRequest { - #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] - pub mode: Option, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] + pub mode: Option, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl ServersCreateServerNetworkRequest { - pub fn new( - ports: ::std::collections::HashMap, - ) -> ServersCreateServerNetworkRequest { - ServersCreateServerNetworkRequest { mode: None, ports } - } + pub fn new(ports: ::std::collections::HashMap) -> ServersCreateServerNetworkRequest { + ServersCreateServerNetworkRequest { + mode: None, + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_server_port_request.rs b/sdks/full/rust/src/models/servers_create_server_port_request.rs index c11370436b..d818685f71 100644 --- a/sdks/full/rust/src/models/servers_create_server_port_request.rs +++ b/sdks/full/rust/src/models/servers_create_server_port_request.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateServerPortRequest { - #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] - pub internal_port: Option, - #[serde(rename = "protocol")] - pub protocol: crate::models::ServersPortProtocol, - #[serde(rename = "routing", skip_serializing_if = "Option::is_none")] - pub routing: Option>, + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ServersPortProtocol, + #[serde(rename = "routing", skip_serializing_if = "Option::is_none")] + pub routing: Option>, } impl ServersCreateServerPortRequest { - pub fn new(protocol: crate::models::ServersPortProtocol) -> ServersCreateServerPortRequest { - ServersCreateServerPortRequest { - internal_port: None, - protocol, - routing: None, - } - } + pub fn new(protocol: crate::models::ServersPortProtocol) -> ServersCreateServerPortRequest { + ServersCreateServerPortRequest { + internal_port: None, + protocol, + routing: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_server_request.rs b/sdks/full/rust/src/models/servers_create_server_request.rs index bf213b3ca6..84c0f99936 100644 --- a/sdks/full/rust/src/models/servers_create_server_request.rs +++ b/sdks/full/rust/src/models/servers_create_server_request.rs @@ -4,41 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateServerRequest { - #[serde(rename = "datacenter")] - pub datacenter: uuid::Uuid, - #[serde(rename = "lifecycle", skip_serializing_if = "Option::is_none")] - pub lifecycle: Option>, - #[serde(rename = "network")] - pub network: Box, - #[serde(rename = "resources")] - pub resources: Box, - #[serde(rename = "runtime")] - pub runtime: Box, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + #[serde(rename = "datacenter")] + pub datacenter: uuid::Uuid, + #[serde(rename = "lifecycle", skip_serializing_if = "Option::is_none")] + pub lifecycle: Option>, + #[serde(rename = "network")] + pub network: Box, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ServersCreateServerRequest { - pub fn new( - datacenter: uuid::Uuid, - network: crate::models::ServersCreateServerNetworkRequest, - resources: crate::models::ServersResources, - runtime: crate::models::ServersCreateServerRuntimeRequest, - tags: Option, - ) -> ServersCreateServerRequest { - ServersCreateServerRequest { - datacenter, - lifecycle: None, - network: Box::new(network), - resources: Box::new(resources), - runtime: Box::new(runtime), - tags, - } - } + pub fn new(datacenter: uuid::Uuid, network: crate::models::ServersCreateServerNetworkRequest, resources: crate::models::ServersResources, runtime: crate::models::ServersCreateServerRuntimeRequest, tags: Option) -> ServersCreateServerRequest { + ServersCreateServerRequest { + datacenter, + lifecycle: None, + network: Box::new(network), + resources: Box::new(resources), + runtime: Box::new(runtime), + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_server_response.rs b/sdks/full/rust/src/models/servers_create_server_response.rs index b26f499470..3c32cbd896 100644 --- a/sdks/full/rust/src/models/servers_create_server_response.rs +++ b/sdks/full/rust/src/models/servers_create_server_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateServerResponse { - #[serde(rename = "server")] - pub server: Box, + #[serde(rename = "server")] + pub server: Box, } impl ServersCreateServerResponse { - pub fn new(server: crate::models::ServersServer) -> ServersCreateServerResponse { - ServersCreateServerResponse { - server: Box::new(server), - } - } + pub fn new(server: crate::models::ServersServer) -> ServersCreateServerResponse { + ServersCreateServerResponse { + server: Box::new(server), + } + } } + + diff --git a/sdks/full/rust/src/models/servers_create_server_runtime_request.rs b/sdks/full/rust/src/models/servers_create_server_runtime_request.rs index 4485959944..11f4647cf9 100644 --- a/sdks/full/rust/src/models/servers_create_server_runtime_request.rs +++ b/sdks/full/rust/src/models/servers_create_server_runtime_request.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersCreateServerRuntimeRequest { - #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] - pub arguments: Option>, - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] - pub environment: Option<::std::collections::HashMap>, + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, } impl ServersCreateServerRuntimeRequest { - pub fn new(build: uuid::Uuid) -> ServersCreateServerRuntimeRequest { - ServersCreateServerRuntimeRequest { - arguments: None, - build, - environment: None, - } - } + pub fn new(build: uuid::Uuid) -> ServersCreateServerRuntimeRequest { + ServersCreateServerRuntimeRequest { + arguments: None, + build, + environment: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_datacenter.rs b/sdks/full/rust/src/models/servers_datacenter.rs index 12af6dabf7..b267b68a6e 100644 --- a/sdks/full/rust/src/models/servers_datacenter.rs +++ b/sdks/full/rust/src/models/servers_datacenter.rs @@ -4,22 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersDatacenter { - #[serde(rename = "id")] - pub id: uuid::Uuid, - #[serde(rename = "name")] - pub name: String, - #[serde(rename = "slug")] - pub slug: String, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "slug")] + pub slug: String, } impl ServersDatacenter { - pub fn new(id: uuid::Uuid, name: String, slug: String) -> ServersDatacenter { - ServersDatacenter { id, name, slug } - } + pub fn new(id: uuid::Uuid, name: String, slug: String) -> ServersDatacenter { + ServersDatacenter { + id, + name, + slug, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_get_build_response.rs b/sdks/full/rust/src/models/servers_get_build_response.rs index 65ac964d73..25515b9332 100644 --- a/sdks/full/rust/src/models/servers_get_build_response.rs +++ b/sdks/full/rust/src/models/servers_get_build_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersGetBuildResponse { - #[serde(rename = "build")] - pub build: Box, + #[serde(rename = "build")] + pub build: Box, } impl ServersGetBuildResponse { - pub fn new(build: crate::models::ServersBuild) -> ServersGetBuildResponse { - ServersGetBuildResponse { - build: Box::new(build), - } - } + pub fn new(build: crate::models::ServersBuild) -> ServersGetBuildResponse { + ServersGetBuildResponse { + build: Box::new(build), + } + } } + + diff --git a/sdks/full/rust/src/models/servers_get_server_logs_response.rs b/sdks/full/rust/src/models/servers_get_server_logs_response.rs index df3bc16c0c..dd6df5a770 100644 --- a/sdks/full/rust/src/models/servers_get_server_logs_response.rs +++ b/sdks/full/rust/src/models/servers_get_server_logs_response.rs @@ -4,32 +4,33 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersGetServerLogsResponse { - /// Sorted old to new. - #[serde(rename = "lines")] - pub lines: Vec, - /// Sorted old to new. - #[serde(rename = "timestamps")] - pub timestamps: Vec, - #[serde(rename = "watch")] - pub watch: Box, + /// Sorted old to new. + #[serde(rename = "lines")] + pub lines: Vec, + /// Sorted old to new. + #[serde(rename = "timestamps")] + pub timestamps: Vec, + #[serde(rename = "watch")] + pub watch: Box, } impl ServersGetServerLogsResponse { - pub fn new( - lines: Vec, - timestamps: Vec, - watch: crate::models::WatchResponse, - ) -> ServersGetServerLogsResponse { - ServersGetServerLogsResponse { - lines, - timestamps, - watch: Box::new(watch), - } - } + pub fn new(lines: Vec, timestamps: Vec, watch: crate::models::WatchResponse) -> ServersGetServerLogsResponse { + ServersGetServerLogsResponse { + lines, + timestamps, + watch: Box::new(watch), + } + } } + + diff --git a/sdks/full/rust/src/models/servers_get_server_response.rs b/sdks/full/rust/src/models/servers_get_server_response.rs index a6a739546b..2f017da813 100644 --- a/sdks/full/rust/src/models/servers_get_server_response.rs +++ b/sdks/full/rust/src/models/servers_get_server_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersGetServerResponse { - #[serde(rename = "server")] - pub server: Box, + #[serde(rename = "server")] + pub server: Box, } impl ServersGetServerResponse { - pub fn new(server: crate::models::ServersServer) -> ServersGetServerResponse { - ServersGetServerResponse { - server: Box::new(server), - } - } + pub fn new(server: crate::models::ServersServer) -> ServersGetServerResponse { + ServersGetServerResponse { + server: Box::new(server), + } + } } + + diff --git a/sdks/full/rust/src/models/servers_lifecycle.rs b/sdks/full/rust/src/models/servers_lifecycle.rs index 6268eb01b8..47b2074f46 100644 --- a/sdks/full/rust/src/models/servers_lifecycle.rs +++ b/sdks/full/rust/src/models/servers_lifecycle.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersLifecycle { - /// The duration to wait for in milliseconds before killing the server. This should be set to a safe default, and can be overridden during a DELETE request if needed. - #[serde(rename = "kill_timeout", skip_serializing_if = "Option::is_none")] - pub kill_timeout: Option, + /// The duration to wait for in milliseconds before killing the server. This should be set to a safe default, and can be overridden during a DELETE request if needed. + #[serde(rename = "kill_timeout", skip_serializing_if = "Option::is_none")] + pub kill_timeout: Option, } impl ServersLifecycle { - pub fn new() -> ServersLifecycle { - ServersLifecycle { kill_timeout: None } - } + pub fn new() -> ServersLifecycle { + ServersLifecycle { + kill_timeout: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_list_builds_response.rs b/sdks/full/rust/src/models/servers_list_builds_response.rs index e9bc64a4ce..c3e1d63e80 100644 --- a/sdks/full/rust/src/models/servers_list_builds_response.rs +++ b/sdks/full/rust/src/models/servers_list_builds_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersListBuildsResponse { - /// A list of builds for the game associated with the token. - #[serde(rename = "builds")] - pub builds: Vec, + /// A list of builds for the game associated with the token. + #[serde(rename = "builds")] + pub builds: Vec, } impl ServersListBuildsResponse { - pub fn new(builds: Vec) -> ServersListBuildsResponse { - ServersListBuildsResponse { builds } - } + pub fn new(builds: Vec) -> ServersListBuildsResponse { + ServersListBuildsResponse { + builds, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_list_datacenters_response.rs b/sdks/full/rust/src/models/servers_list_datacenters_response.rs index 3e228c8d52..ac3a02b52d 100644 --- a/sdks/full/rust/src/models/servers_list_datacenters_response.rs +++ b/sdks/full/rust/src/models/servers_list_datacenters_response.rs @@ -4,20 +4,25 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersListDatacentersResponse { - #[serde(rename = "datacenters")] - pub datacenters: Vec, + #[serde(rename = "datacenters")] + pub datacenters: Vec, } impl ServersListDatacentersResponse { - pub fn new( - datacenters: Vec, - ) -> ServersListDatacentersResponse { - ServersListDatacentersResponse { datacenters } - } + pub fn new(datacenters: Vec) -> ServersListDatacentersResponse { + ServersListDatacentersResponse { + datacenters, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_list_servers_response.rs b/sdks/full/rust/src/models/servers_list_servers_response.rs index 75d728f86f..202010aa26 100644 --- a/sdks/full/rust/src/models/servers_list_servers_response.rs +++ b/sdks/full/rust/src/models/servers_list_servers_response.rs @@ -4,19 +4,26 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersListServersResponse { - /// A list of servers for the game associated with the token. - #[serde(rename = "servers")] - pub servers: Vec, + /// A list of servers for the game associated with the token. + #[serde(rename = "servers")] + pub servers: Vec, } impl ServersListServersResponse { - pub fn new(servers: Vec) -> ServersListServersResponse { - ServersListServersResponse { servers } - } + pub fn new(servers: Vec) -> ServersListServersResponse { + ServersListServersResponse { + servers, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_log_stream.rs b/sdks/full/rust/src/models/servers_log_stream.rs index 22c8742c30..b96bdda215 100644 --- a/sdks/full/rust/src/models/servers_log_stream.rs +++ b/sdks/full/rust/src/models/servers_log_stream.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ServersLogStream { - #[serde(rename = "std_out")] - StdOut, - #[serde(rename = "std_err")] - StdErr, + #[serde(rename = "std_out")] + StdOut, + #[serde(rename = "std_err")] + StdErr, + } impl ToString for ServersLogStream { - fn to_string(&self) -> String { - match self { - Self::StdOut => String::from("std_out"), - Self::StdErr => String::from("std_err"), - } - } + fn to_string(&self) -> String { + match self { + Self::StdOut => String::from("std_out"), + Self::StdErr => String::from("std_err"), + } + } } impl Default for ServersLogStream { - fn default() -> ServersLogStream { - Self::StdOut - } + fn default() -> ServersLogStream { + Self::StdOut + } } + + + + diff --git a/sdks/full/rust/src/models/servers_network.rs b/sdks/full/rust/src/models/servers_network.rs index 5a0b97d95b..97bade5673 100644 --- a/sdks/full/rust/src/models/servers_network.rs +++ b/sdks/full/rust/src/models/servers_network.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersNetwork { - #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] - pub mode: Option, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, + #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] + pub mode: Option, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, } impl ServersNetwork { - pub fn new( - ports: ::std::collections::HashMap, - ) -> ServersNetwork { - ServersNetwork { mode: None, ports } - } + pub fn new(ports: ::std::collections::HashMap) -> ServersNetwork { + ServersNetwork { + mode: None, + ports, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_network_mode.rs b/sdks/full/rust/src/models/servers_network_mode.rs index d18f6caea8..bbb9bd9a5b 100644 --- a/sdks/full/rust/src/models/servers_network_mode.rs +++ b/sdks/full/rust/src/models/servers_network_mode.rs @@ -4,30 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ServersNetworkMode { - #[serde(rename = "bridge")] - Bridge, - #[serde(rename = "host")] - Host, + #[serde(rename = "bridge")] + Bridge, + #[serde(rename = "host")] + Host, + } impl ToString for ServersNetworkMode { - fn to_string(&self) -> String { - match self { - Self::Bridge => String::from("bridge"), - Self::Host => String::from("host"), - } - } + fn to_string(&self) -> String { + match self { + Self::Bridge => String::from("bridge"), + Self::Host => String::from("host"), + } + } } impl Default for ServersNetworkMode { - fn default() -> ServersNetworkMode { - Self::Bridge - } + fn default() -> ServersNetworkMode { + Self::Bridge + } } + + + + diff --git a/sdks/full/rust/src/models/servers_patch_build_tags_request.rs b/sdks/full/rust/src/models/servers_patch_build_tags_request.rs index 43bfdcff35..3857d9654a 100644 --- a/sdks/full/rust/src/models/servers_patch_build_tags_request.rs +++ b/sdks/full/rust/src/models/servers_patch_build_tags_request.rs @@ -4,24 +4,29 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersPatchBuildTagsRequest { - /// Removes the given tag keys from all other builds. - #[serde(rename = "exclusive_tags", skip_serializing_if = "Option::is_none")] - pub exclusive_tags: Option>, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + /// Removes the given tag keys from all other builds. + #[serde(rename = "exclusive_tags", skip_serializing_if = "Option::is_none")] + pub exclusive_tags: Option>, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ServersPatchBuildTagsRequest { - pub fn new(tags: Option) -> ServersPatchBuildTagsRequest { - ServersPatchBuildTagsRequest { - exclusive_tags: None, - tags, - } - } + pub fn new(tags: Option) -> ServersPatchBuildTagsRequest { + ServersPatchBuildTagsRequest { + exclusive_tags: None, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_port.rs b/sdks/full/rust/src/models/servers_port.rs index f3fdb8470e..ab305ac1e4 100644 --- a/sdks/full/rust/src/models/servers_port.rs +++ b/sdks/full/rust/src/models/servers_port.rs @@ -4,35 +4,37 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersPort { - #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] - pub internal_port: Option, - #[serde(rename = "protocol")] - pub protocol: crate::models::ServersPortProtocol, - #[serde(rename = "public_hostname", skip_serializing_if = "Option::is_none")] - pub public_hostname: Option, - #[serde(rename = "public_port", skip_serializing_if = "Option::is_none")] - pub public_port: Option, - #[serde(rename = "routing")] - pub routing: Box, + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ServersPortProtocol, + #[serde(rename = "public_hostname", skip_serializing_if = "Option::is_none")] + pub public_hostname: Option, + #[serde(rename = "public_port", skip_serializing_if = "Option::is_none")] + pub public_port: Option, + #[serde(rename = "routing")] + pub routing: Box, } impl ServersPort { - pub fn new( - protocol: crate::models::ServersPortProtocol, - routing: crate::models::ServersPortRouting, - ) -> ServersPort { - ServersPort { - internal_port: None, - protocol, - public_hostname: None, - public_port: None, - routing: Box::new(routing), - } - } + pub fn new(protocol: crate::models::ServersPortProtocol, routing: crate::models::ServersPortRouting) -> ServersPort { + ServersPort { + internal_port: None, + protocol, + public_hostname: None, + public_port: None, + routing: Box::new(routing), + } + } } + + diff --git a/sdks/full/rust/src/models/servers_port_protocol.rs b/sdks/full/rust/src/models/servers_port_protocol.rs index b5b0e4ca64..e2e8c326c9 100644 --- a/sdks/full/rust/src/models/servers_port_protocol.rs +++ b/sdks/full/rust/src/models/servers_port_protocol.rs @@ -4,39 +4,45 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ -/// + +/// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] pub enum ServersPortProtocol { - #[serde(rename = "http")] - Http, - #[serde(rename = "https")] - Https, - #[serde(rename = "tcp")] - Tcp, - #[serde(rename = "tcp_tls")] - TcpTls, - #[serde(rename = "udp")] - Udp, + #[serde(rename = "http")] + Http, + #[serde(rename = "https")] + Https, + #[serde(rename = "tcp")] + Tcp, + #[serde(rename = "tcp_tls")] + TcpTls, + #[serde(rename = "udp")] + Udp, + } impl ToString for ServersPortProtocol { - fn to_string(&self) -> String { - match self { - Self::Http => String::from("http"), - Self::Https => String::from("https"), - Self::Tcp => String::from("tcp"), - Self::TcpTls => String::from("tcp_tls"), - Self::Udp => String::from("udp"), - } - } + fn to_string(&self) -> String { + match self { + Self::Http => String::from("http"), + Self::Https => String::from("https"), + Self::Tcp => String::from("tcp"), + Self::TcpTls => String::from("tcp_tls"), + Self::Udp => String::from("udp"), + } + } } impl Default for ServersPortProtocol { - fn default() -> ServersPortProtocol { - Self::Http - } + fn default() -> ServersPortProtocol { + Self::Http + } } + + + + diff --git a/sdks/full/rust/src/models/servers_port_routing.rs b/sdks/full/rust/src/models/servers_port_routing.rs index 5ba748b474..83f0846fc4 100644 --- a/sdks/full/rust/src/models/servers_port_routing.rs +++ b/sdks/full/rust/src/models/servers_port_routing.rs @@ -4,23 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersPortRouting { - #[serde(rename = "game_guard", skip_serializing_if = "Option::is_none")] - pub game_guard: Option, - #[serde(rename = "host", skip_serializing_if = "Option::is_none")] - pub host: Option, + #[serde(rename = "game_guard", skip_serializing_if = "Option::is_none")] + pub game_guard: Option, + #[serde(rename = "host", skip_serializing_if = "Option::is_none")] + pub host: Option, } impl ServersPortRouting { - pub fn new() -> ServersPortRouting { - ServersPortRouting { - game_guard: None, - host: None, - } - } + pub fn new() -> ServersPortRouting { + ServersPortRouting { + game_guard: None, + host: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_resources.rs b/sdks/full/rust/src/models/servers_resources.rs index 34addff66f..d29a3cb0ac 100644 --- a/sdks/full/rust/src/models/servers_resources.rs +++ b/sdks/full/rust/src/models/servers_resources.rs @@ -4,22 +4,30 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersResources { - /// The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. - #[serde(rename = "cpu")] - pub cpu: i32, - /// The amount of memory in megabytes - #[serde(rename = "memory")] - pub memory: i32, + /// The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. + #[serde(rename = "cpu")] + pub cpu: i32, + /// The amount of memory in megabytes + #[serde(rename = "memory")] + pub memory: i32, } impl ServersResources { - pub fn new(cpu: i32, memory: i32) -> ServersResources { - ServersResources { cpu, memory } - } + pub fn new(cpu: i32, memory: i32) -> ServersResources { + ServersResources { + cpu, + memory, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_runtime.rs b/sdks/full/rust/src/models/servers_runtime.rs index d29bd15c94..489b53a7a9 100644 --- a/sdks/full/rust/src/models/servers_runtime.rs +++ b/sdks/full/rust/src/models/servers_runtime.rs @@ -4,26 +4,31 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersRuntime { - #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] - pub arguments: Option>, - #[serde(rename = "build")] - pub build: uuid::Uuid, - #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] - pub environment: Option<::std::collections::HashMap>, + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, } impl ServersRuntime { - pub fn new(build: uuid::Uuid) -> ServersRuntime { - ServersRuntime { - arguments: None, - build, - environment: None, - } - } + pub fn new(build: uuid::Uuid) -> ServersRuntime { + ServersRuntime { + arguments: None, + build, + environment: None, + } + } } + + diff --git a/sdks/full/rust/src/models/servers_server.rs b/sdks/full/rust/src/models/servers_server.rs index 2d6738168c..3238d633ea 100644 --- a/sdks/full/rust/src/models/servers_server.rs +++ b/sdks/full/rust/src/models/servers_server.rs @@ -4,60 +4,55 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ + + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServersServer { - #[serde(rename = "created_at")] - pub created_at: i64, - #[serde(rename = "datacenter")] - pub datacenter: uuid::Uuid, - #[serde(rename = "destroyed_at", skip_serializing_if = "Option::is_none")] - pub destroyed_at: Option, - #[serde(rename = "environment")] - pub environment: uuid::Uuid, - #[serde(rename = "id")] - pub id: uuid::Uuid, - #[serde(rename = "lifecycle")] - pub lifecycle: Box, - #[serde(rename = "network")] - pub network: Box, - #[serde(rename = "resources")] - pub resources: Box, - #[serde(rename = "runtime")] - pub runtime: Box, - #[serde(rename = "started_at", skip_serializing_if = "Option::is_none")] - pub started_at: Option, - #[serde(rename = "tags", deserialize_with = "Option::deserialize")] - pub tags: Option, + #[serde(rename = "created_at")] + pub created_at: i64, + #[serde(rename = "datacenter")] + pub datacenter: uuid::Uuid, + #[serde(rename = "destroyed_at", skip_serializing_if = "Option::is_none")] + pub destroyed_at: Option, + #[serde(rename = "environment")] + pub environment: uuid::Uuid, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "lifecycle")] + pub lifecycle: Box, + #[serde(rename = "network")] + pub network: Box, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "started_at", skip_serializing_if = "Option::is_none")] + pub started_at: Option, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, } impl ServersServer { - pub fn new( - created_at: i64, - datacenter: uuid::Uuid, - environment: uuid::Uuid, - id: uuid::Uuid, - lifecycle: crate::models::ServersLifecycle, - network: crate::models::ServersNetwork, - resources: crate::models::ServersResources, - runtime: crate::models::ServersRuntime, - tags: Option, - ) -> ServersServer { - ServersServer { - created_at, - datacenter, - destroyed_at: None, - environment, - id, - lifecycle: Box::new(lifecycle), - network: Box::new(network), - resources: Box::new(resources), - runtime: Box::new(runtime), - started_at: None, - tags, - } - } + pub fn new(created_at: i64, datacenter: uuid::Uuid, environment: uuid::Uuid, id: uuid::Uuid, lifecycle: crate::models::ServersLifecycle, network: crate::models::ServersNetwork, resources: crate::models::ServersResources, runtime: crate::models::ServersRuntime, tags: Option) -> ServersServer { + ServersServer { + created_at, + datacenter, + destroyed_at: None, + environment, + id, + lifecycle: Box::new(lifecycle), + network: Box::new(network), + resources: Box::new(resources), + runtime: Box::new(runtime), + started_at: None, + tags, + } + } } + + diff --git a/sdks/full/rust/src/models/upload_prepare_file.rs b/sdks/full/rust/src/models/upload_prepare_file.rs index 3a4e4fee92..0d197af99b 100644 --- a/sdks/full/rust/src/models/upload_prepare_file.rs +++ b/sdks/full/rust/src/models/upload_prepare_file.rs @@ -4,32 +4,36 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// UploadPrepareFile : A file being prepared to upload. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct UploadPrepareFile { - /// Unsigned 64 bit integer. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The MIME type of the file. - #[serde(rename = "content_type", skip_serializing_if = "Option::is_none")] - pub content_type: Option, - /// The path/filename of the file. - #[serde(rename = "path")] - pub path: String, + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the file. + #[serde(rename = "content_type", skip_serializing_if = "Option::is_none")] + pub content_type: Option, + /// The path/filename of the file. + #[serde(rename = "path")] + pub path: String, } impl UploadPrepareFile { - /// A file being prepared to upload. - pub fn new(content_length: i64, path: String) -> UploadPrepareFile { - UploadPrepareFile { - content_length, - content_type: None, - path, - } - } + /// A file being prepared to upload. + pub fn new(content_length: i64, path: String) -> UploadPrepareFile { + UploadPrepareFile { + content_length, + content_type: None, + path, + } + } } + + diff --git a/sdks/full/rust/src/models/upload_presigned_request.rs b/sdks/full/rust/src/models/upload_presigned_request.rs index 941e8799b9..7f2ca3aad5 100644 --- a/sdks/full/rust/src/models/upload_presigned_request.rs +++ b/sdks/full/rust/src/models/upload_presigned_request.rs @@ -4,41 +4,40 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// UploadPresignedRequest : A presigned request used to upload files. Upload your file to the given URL via a PUT request. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct UploadPresignedRequest { - /// The byte offset for this multipart chunk. Always 0 if not a multipart upload. - #[serde(rename = "byte_offset")] - pub byte_offset: i64, - /// Expected size of this upload. - #[serde(rename = "content_length")] - pub content_length: i64, - /// The name of the file to upload. This is the same as the one given in the upload prepare file. - #[serde(rename = "path")] - pub path: String, - /// The URL of the presigned request for which to upload your file to. - #[serde(rename = "url")] - pub url: String, + /// The byte offset for this multipart chunk. Always 0 if not a multipart upload. + #[serde(rename = "byte_offset")] + pub byte_offset: i64, + /// Expected size of this upload. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The name of the file to upload. This is the same as the one given in the upload prepare file. + #[serde(rename = "path")] + pub path: String, + /// The URL of the presigned request for which to upload your file to. + #[serde(rename = "url")] + pub url: String, } impl UploadPresignedRequest { - /// A presigned request used to upload files. Upload your file to the given URL via a PUT request. - pub fn new( - byte_offset: i64, - content_length: i64, - path: String, - url: String, - ) -> UploadPresignedRequest { - UploadPresignedRequest { - byte_offset, - content_length, - path, - url, - } - } + /// A presigned request used to upload files. Upload your file to the given URL via a PUT request. + pub fn new(byte_offset: i64, content_length: i64, path: String, url: String) -> UploadPresignedRequest { + UploadPresignedRequest { + byte_offset, + content_length, + path, + url, + } + } } + + diff --git a/sdks/full/rust/src/models/validation_error.rs b/sdks/full/rust/src/models/validation_error.rs index df6f1ad56d..d4b2471cb7 100644 --- a/sdks/full/rust/src/models/validation_error.rs +++ b/sdks/full/rust/src/models/validation_error.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// ValidationError : An error given by failed content validation. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ValidationError { - /// A list of strings denoting the origin of a validation error. - #[serde(rename = "path")] - pub path: Vec, + /// A list of strings denoting the origin of a validation error. + #[serde(rename = "path")] + pub path: Vec, } impl ValidationError { - /// An error given by failed content validation. - pub fn new(path: Vec) -> ValidationError { - ValidationError { path } - } + /// An error given by failed content validation. + pub fn new(path: Vec) -> ValidationError { + ValidationError { + path, + } + } } + + diff --git a/sdks/full/rust/src/models/watch_response.rs b/sdks/full/rust/src/models/watch_response.rs index f30fc24b53..d1ca872c6c 100644 --- a/sdks/full/rust/src/models/watch_response.rs +++ b/sdks/full/rust/src/models/watch_response.rs @@ -4,22 +4,28 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.1 - * + * * Generated by: https://openapi-generator.tech */ /// WatchResponse : Provided by watchable endpoints used in blocking loops. + + #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct WatchResponse { - /// Index indicating the version of the data responded. Pass this to `WatchQuery` to block and wait for the next response. - #[serde(rename = "index")] - pub index: String, + /// Index indicating the version of the data responded. Pass this to `WatchQuery` to block and wait for the next response. + #[serde(rename = "index")] + pub index: String, } impl WatchResponse { - /// Provided by watchable endpoints used in blocking loops. - pub fn new(index: String) -> WatchResponse { - WatchResponse { index } - } + /// Provided by watchable endpoints used in blocking loops. + pub fn new(index: String) -> WatchResponse { + WatchResponse { + index, + } + } } + + diff --git a/sdks/full/typescript/src/api/resources/actor/client/Client.ts b/sdks/full/typescript/src/api/resources/actor/client/Client.ts index 43a7babb12..c27e9491fb 100644 --- a/sdks/full/typescript/src/api/resources/actor/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/actor/client/Client.ts @@ -75,6 +75,9 @@ export class Actor { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -234,6 +237,9 @@ export class Actor { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -367,7 +373,7 @@ export class Actor { * } * }, * network: { - * mode: Rivet.actor.NetworkMode.Bridge, + * mode: "bridge", * ports: {} * }, * resources: { @@ -402,6 +408,9 @@ export class Actor { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -554,6 +563,9 @@ export class Actor { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts b/sdks/full/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts index d6c4325029..10fc850b7e 100644 --- a/sdks/full/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts +++ b/sdks/full/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts @@ -22,7 +22,7 @@ import * as Rivet from "../../../../index"; * } * }, * network: { - * mode: Rivet.actor.NetworkMode.Bridge, + * mode: "bridge", * ports: {} * }, * resources: { diff --git a/sdks/full/typescript/src/api/resources/actor/resources/builds/client/Client.ts b/sdks/full/typescript/src/api/resources/actor/resources/builds/client/Client.ts index 111e911807..38f9fbbfb6 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/builds/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/builds/client/Client.ts @@ -72,6 +72,9 @@ export class Builds { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -221,6 +224,9 @@ export class Builds { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -371,6 +377,9 @@ export class Builds { method: "PATCH", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -501,8 +510,8 @@ export class Builds { * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.actor.BuildKind.DockerImage, - * compression: Rivet.actor.BuildCompression.None, + * kind: "docker_image", + * compression: "none", * prewarmRegions: ["string"] * } * }) @@ -529,6 +538,9 @@ export class Builds { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -676,6 +688,9 @@ export class Builds { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts b/sdks/full/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts index 73cbad6e7e..0be804ec84 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts @@ -18,8 +18,8 @@ import * as Rivet from "../../../../../../index"; * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.actor.BuildKind.DockerImage, - * compression: Rivet.actor.BuildCompression.None, + * kind: "docker_image", + * compression: "none", * prewarmRegions: ["string"] * } * } diff --git a/sdks/full/typescript/src/api/resources/actor/resources/common/types/GameGuardRouting.ts b/sdks/full/typescript/src/api/resources/actor/resources/common/types/GameGuardRouting.ts deleted file mode 100644 index 09ae9549d4..0000000000 --- a/sdks/full/typescript/src/api/resources/actor/resources/common/types/GameGuardRouting.ts +++ /dev/null @@ -1,9 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface GameGuardRouting { - authorization?: Rivet.actor.PortAuthorization; -} diff --git a/sdks/full/typescript/src/api/resources/actor/resources/common/types/PortRouting.ts b/sdks/full/typescript/src/api/resources/actor/resources/common/types/PortRouting.ts index aa2a15cf2c..24e3b2c807 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/common/types/PortRouting.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/common/types/PortRouting.ts @@ -5,6 +5,6 @@ import * as Rivet from "../../../../../index"; export interface PortRouting { - gameGuard?: Rivet.actor.GameGuardRouting; + guard?: Rivet.actor.GuardRouting; host?: Rivet.actor.HostRouting; } diff --git a/sdks/full/typescript/src/api/resources/actor/resources/common/types/index.ts b/sdks/full/typescript/src/api/resources/actor/resources/common/types/index.ts index 89bf5598f2..24ce1387ca 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/common/types/index.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/common/types/index.ts @@ -7,7 +7,7 @@ export * from "./NetworkMode"; export * from "./Port"; export * from "./PortProtocol"; export * from "./PortRouting"; -export * from "./GameGuardRouting"; +export * from "./GuardRouting"; export * from "./PortAuthorization"; export * from "./PortQueryAuthorization"; export * from "./HostRouting"; diff --git a/sdks/full/typescript/src/api/resources/actor/resources/logs/client/Client.ts b/sdks/full/typescript/src/api/resources/actor/resources/logs/client/Client.ts index bad4ac4cf5..3a3dddc1df 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/logs/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/logs/client/Client.ts @@ -47,7 +47,7 @@ export class Logs { * await client.actor.logs.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { * project: "string", * environment: "string", - * stream: Rivet.actor.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * }) */ @@ -79,6 +79,9 @@ export class Logs { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts b/sdks/full/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts index d987f62c4c..eb1587c3e1 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts @@ -9,7 +9,7 @@ import * as Rivet from "../../../../../../index"; * { * project: "string", * environment: "string", - * stream: Rivet.actor.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * } */ diff --git a/sdks/full/typescript/src/api/resources/actor/resources/regions/client/Client.ts b/sdks/full/typescript/src/api/resources/actor/resources/regions/client/Client.ts index 89f8b5a088..66e8ee02fe 100644 --- a/sdks/full/typescript/src/api/resources/actor/resources/regions/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/actor/resources/regions/client/Client.ts @@ -68,6 +68,9 @@ export class Regions { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/auth/resources/identity/resources/email/client/Client.ts b/sdks/full/typescript/src/api/resources/auth/resources/identity/resources/email/client/Client.ts index a472fe1a73..c5e986fabd 100644 --- a/sdks/full/typescript/src/api/resources/auth/resources/identity/resources/email/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/auth/resources/identity/resources/email/client/Client.ts @@ -68,6 +68,9 @@ export class Email { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -204,6 +207,9 @@ export class Email { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/auth/resources/tokens/client/Client.ts b/sdks/full/typescript/src/api/resources/auth/resources/tokens/client/Client.ts index c184630d6d..96db59a411 100644 --- a/sdks/full/typescript/src/api/resources/auth/resources/tokens/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/auth/resources/tokens/client/Client.ts @@ -59,6 +59,9 @@ export class Tokens { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/client/Client.ts index de8ebe54b3..d85dba4bdc 100644 --- a/sdks/full/typescript/src/api/resources/cloud/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/client/Client.ts @@ -60,6 +60,9 @@ export class Cloud { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/auth/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/auth/client/Client.ts index 1cf32254f2..ccce4c0b36 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/auth/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/auth/client/Client.ts @@ -53,6 +53,9 @@ export class Auth { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/devices/resources/links/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/devices/resources/links/client/Client.ts index ca4a9601c2..6102028261 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/devices/resources/links/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/devices/resources/links/client/Client.ts @@ -53,6 +53,9 @@ export class Links { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -191,6 +194,9 @@ export class Links { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -323,6 +329,9 @@ export class Links { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/client/Client.ts index 25fc885f86..044e8f45a4 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/client/Client.ts @@ -72,6 +72,9 @@ export class Games { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -207,6 +210,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -341,6 +347,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -482,6 +491,9 @@ export class Games { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -619,6 +631,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -754,6 +769,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -884,6 +902,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1019,6 +1040,9 @@ export class Games { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/avatars/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/avatars/client/Client.ts index 65f1f73fb9..f6675189dd 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/avatars/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/avatars/client/Client.ts @@ -57,6 +57,9 @@ export class Avatars { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -194,6 +197,9 @@ export class Avatars { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -329,6 +335,9 @@ export class Avatars { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/builds/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/builds/client/Client.ts index 3dd2d3b3d8..02a8bdb628 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/builds/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/builds/client/Client.ts @@ -57,6 +57,9 @@ export class Builds { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -183,8 +186,8 @@ export class Builds { * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.cloud.games.BuildKind.DockerImage, - * compression: Rivet.cloud.games.BuildCompression.None + * kind: "docker_image", + * compression: "none" * }) */ public async createGameBuild( @@ -200,6 +203,9 @@ export class Builds { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/cdn/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/cdn/client/Client.ts index f80c3c8a78..4aa0ade6ac 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/cdn/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/cdn/client/Client.ts @@ -57,6 +57,9 @@ export class Cdn { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -196,6 +199,9 @@ export class Cdn { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/Client.ts index 86485bc973..5b9050e6a5 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/Client.ts @@ -62,6 +62,9 @@ export class Matchmaker { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -197,6 +200,9 @@ export class Matchmaker { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -316,7 +322,7 @@ export class Matchmaker { * * @example * await client.cloud.games.matchmaker.getLobbyLogs("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * stream: Rivet.cloud.games.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * }) */ @@ -341,6 +347,9 @@ export class Matchmaker { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -461,7 +470,7 @@ export class Matchmaker { * * @example * await client.cloud.games.matchmaker.exportLobbyLogs("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * stream: Rivet.cloud.games.LogStream.StdOut + * stream: "std_out" * }) */ public async exportLobbyLogs( @@ -480,6 +489,9 @@ export class Matchmaker { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.ts index 201fac731d..e3f2ef6c6e 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.ts @@ -7,7 +7,7 @@ import * as Rivet from "../../../../../../../../index"; /** * @example * { - * stream: Rivet.cloud.games.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * } */ diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/client/Client.ts index bbc2c307cc..59abd6997c 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/client/Client.ts @@ -65,6 +65,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -203,6 +206,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -338,6 +344,9 @@ export class Namespaces { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -475,6 +484,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -608,6 +620,9 @@ export class Namespaces { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -721,7 +736,7 @@ export class Namespaces { * * @example * await client.cloud.games.namespaces.setNamespaceCdnAuthType("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * authType: Rivet.cloud.CdnAuthType.None + * authType: "none" * }) */ public async setNamespaceCdnAuthType( @@ -738,6 +753,9 @@ export class Namespaces { method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -873,6 +891,9 @@ export class Namespaces { method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1006,6 +1027,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1139,6 +1163,9 @@ export class Namespaces { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1270,6 +1297,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1416,6 +1446,9 @@ export class Namespaces { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -1559,6 +1592,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1689,14 +1725,14 @@ export class Namespaces { * "string": { * port: undefined, * portRange: undefined, - * protocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * protocol: "http" * } * }, * lobbyPorts: [{ * label: "string", * targetPort: undefined, * portRange: undefined, - * proxyProtocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * proxyProtocol: "http" * }] * }) */ @@ -1716,6 +1752,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1846,7 +1885,7 @@ export class Namespaces { * label: "string", * targetPort: undefined, * portRange: undefined, - * proxyProtocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * proxyProtocol: "http" * }] * }) */ @@ -1866,6 +1905,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -2004,6 +2046,9 @@ export class Namespaces { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -2143,6 +2188,9 @@ export class Namespaces { method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/analytics/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/analytics/client/Client.ts index 7504459345..ddcfbadc6d 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/analytics/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/analytics/client/Client.ts @@ -61,6 +61,9 @@ export class Analytics { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.ts index 8736d0d426..3d9aa4d901 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.ts @@ -46,7 +46,7 @@ export class Logs { * * @example * await client.cloud.games.namespaces.logs.listNamespaceLobbies("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * beforeCreateTs: new Date("2024-01-15T09:30:00.000Z") + * beforeCreateTs: "2024-01-15T09:30:00Z" * }) */ public async listNamespaceLobbies( @@ -69,6 +69,9 @@ export class Logs { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -206,6 +209,9 @@ export class Logs { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.ts index 225936f304..549ad65e1d 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.ts @@ -7,7 +7,7 @@ import * as Rivet from "../../../../../../../../../../index"; /** * @example * { - * beforeCreateTs: new Date("2024-01-15T09:30:00.000Z") + * beforeCreateTs: "2024-01-15T09:30:00Z" * } */ export interface ListNamespaceLobbiesRequest { diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/tokens/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/tokens/client/Client.ts index 3bda5d5aa0..b60443c36c 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/tokens/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/tokens/client/Client.ts @@ -57,6 +57,9 @@ export class Tokens { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/versions/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/versions/client/Client.ts index d1d4c09edd..6a02acf8d8 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/versions/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/games/resources/versions/client/Client.ts @@ -119,6 +119,9 @@ export class Versions { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -252,6 +255,9 @@ export class Versions { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -444,6 +450,9 @@ export class Versions { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -579,6 +588,9 @@ export class Versions { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/groups/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/groups/client/Client.ts index 00b88cde08..7758cbdc72 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/groups/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/groups/client/Client.ts @@ -59,6 +59,9 @@ export class Groups { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/logs/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/logs/client/Client.ts index fe1765e41c..38f8445de8 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/logs/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/logs/client/Client.ts @@ -57,6 +57,9 @@ export class Logs { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/tiers/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/tiers/client/Client.ts index f57413c8c7..986bfda6e1 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/tiers/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/tiers/client/Client.ts @@ -53,6 +53,9 @@ export class Tiers { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/cloud/resources/uploads/client/Client.ts b/sdks/full/typescript/src/api/resources/cloud/resources/uploads/client/Client.ts index 6f7171fbae..0b59c5dd4c 100644 --- a/sdks/full/typescript/src/api/resources/cloud/resources/uploads/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/cloud/resources/uploads/client/Client.ts @@ -54,6 +54,9 @@ export class Uploads { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/games/resources/environments/resources/tokens/client/Client.ts b/sdks/full/typescript/src/api/resources/games/resources/environments/resources/tokens/client/Client.ts index 659d96aec9..4bee8975b3 100644 --- a/sdks/full/typescript/src/api/resources/games/resources/environments/resources/tokens/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/games/resources/environments/resources/tokens/client/Client.ts @@ -59,6 +59,9 @@ export class Tokens { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/group/client/Client.ts b/sdks/full/typescript/src/api/resources/group/client/Client.ts index a987950bd3..412fdc12e4 100644 --- a/sdks/full/typescript/src/api/resources/group/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/group/client/Client.ts @@ -67,6 +67,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -200,6 +203,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -336,6 +342,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -458,7 +467,7 @@ export class Group { * await client.group.validateProfile({ * displayName: "string", * bio: "string", - * publicity: Rivet.group.Publicity.Open + * publicity: "open" * }) */ public async validateProfile( @@ -473,6 +482,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -608,6 +620,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -752,6 +767,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -885,6 +903,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1011,6 +1032,9 @@ export class Group { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1155,6 +1179,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -1284,6 +1311,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1405,6 +1435,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1549,6 +1582,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -1690,6 +1726,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -1809,7 +1848,7 @@ export class Group { * await client.group.updateProfile("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { * displayName: "string", * bio: "string", - * publicity: Rivet.group.Publicity.Open + * publicity: "open" * }) */ public async updateProfile( @@ -1825,6 +1864,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1948,6 +1990,9 @@ export class Group { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -2082,6 +2127,9 @@ export class Group { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/group/resources/invites/client/Client.ts b/sdks/full/typescript/src/api/resources/group/resources/invites/client/Client.ts index d7749e2d8d..d1d9c7bcbe 100644 --- a/sdks/full/typescript/src/api/resources/group/resources/invites/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/group/resources/invites/client/Client.ts @@ -57,6 +57,9 @@ export class Invites { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -187,6 +190,9 @@ export class Invites { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -322,6 +328,9 @@ export class Invites { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/group/resources/joinRequests/client/Client.ts b/sdks/full/typescript/src/api/resources/group/resources/joinRequests/client/Client.ts index b989eee777..eb858e1592 100644 --- a/sdks/full/typescript/src/api/resources/group/resources/joinRequests/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/group/resources/joinRequests/client/Client.ts @@ -54,6 +54,9 @@ export class JoinRequests { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -184,6 +187,9 @@ export class JoinRequests { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/identity/client/Client.ts b/sdks/full/typescript/src/api/resources/identity/client/Client.ts index 452c43a915..d0663c55d9 100644 --- a/sdks/full/typescript/src/api/resources/identity/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/identity/client/Client.ts @@ -67,6 +67,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -208,6 +211,9 @@ export class Identity { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -347,6 +353,9 @@ export class Identity { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -488,6 +497,9 @@ export class Identity { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -629,6 +641,9 @@ export class Identity { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -764,6 +779,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -893,6 +911,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1028,6 +1049,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1149,6 +1173,9 @@ export class Identity { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1260,7 +1287,7 @@ export class Identity { * * @example * await client.identity.updateStatus({ - * status: Rivet.identity.Status.Online + * status: "online" * }) */ public async updateStatus( @@ -1275,6 +1302,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1404,6 +1434,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1534,6 +1567,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1664,6 +1700,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1783,6 +1822,9 @@ export class Identity { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1901,6 +1943,9 @@ export class Identity { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/identity/client/requests/UpdateStatusRequest.ts b/sdks/full/typescript/src/api/resources/identity/client/requests/UpdateStatusRequest.ts index 890f22b136..109cfb619d 100644 --- a/sdks/full/typescript/src/api/resources/identity/client/requests/UpdateStatusRequest.ts +++ b/sdks/full/typescript/src/api/resources/identity/client/requests/UpdateStatusRequest.ts @@ -7,7 +7,7 @@ import * as Rivet from "../../../../index"; /** * @example * { - * status: Rivet.identity.Status.Online + * status: "online" * } */ export interface UpdateStatusRequest { diff --git a/sdks/full/typescript/src/api/resources/identity/resources/activities/client/Client.ts b/sdks/full/typescript/src/api/resources/identity/resources/activities/client/Client.ts index 4708d6ecf6..101379bdf4 100644 --- a/sdks/full/typescript/src/api/resources/identity/resources/activities/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/identity/resources/activities/client/Client.ts @@ -65,6 +65,9 @@ export class Activities { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/identity/resources/events/client/Client.ts b/sdks/full/typescript/src/api/resources/identity/resources/events/client/Client.ts index 96177fdb5f..89e6f66598 100644 --- a/sdks/full/typescript/src/api/resources/identity/resources/events/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/identity/resources/events/client/Client.ts @@ -65,6 +65,9 @@ export class Events { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/job/resources/run/client/Client.ts b/sdks/full/typescript/src/api/resources/job/resources/run/client/Client.ts index 0a62fb84ad..213c2d8a74 100644 --- a/sdks/full/typescript/src/api/resources/job/resources/run/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/job/resources/run/client/Client.ts @@ -51,6 +51,9 @@ export class Run { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts b/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts index 6a4e261a66..ecefa8b54a 100644 --- a/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts @@ -54,6 +54,9 @@ export class Lobbies { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -188,6 +191,9 @@ export class Lobbies { method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -319,6 +325,9 @@ export class Lobbies { method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -451,6 +460,9 @@ export class Lobbies { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -610,6 +622,9 @@ export class Lobbies { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, origin: origin != null ? origin : undefined, }, contentType: "application/json", @@ -763,6 +778,9 @@ export class Lobbies { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -889,7 +907,7 @@ export class Lobbies { * await client.matchmaker.lobbies.create({ * gameMode: "string", * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, + * publicity: "public", * tags: { * "string": "string" * }, @@ -922,6 +940,9 @@ export class Lobbies { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -1067,6 +1088,9 @@ export class Lobbies { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts b/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts index ac532c8c03..f4547feb13 100644 --- a/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts +++ b/sdks/full/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts @@ -9,7 +9,7 @@ import * as Rivet from "../../../../../../index"; * { * gameMode: "string", * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, + * publicity: "public", * tags: { * "string": "string" * }, diff --git a/sdks/full/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts b/sdks/full/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts index 0f205160ad..6e02861eee 100644 --- a/sdks/full/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts @@ -93,6 +93,9 @@ export class Players { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -222,6 +225,9 @@ export class Players { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -347,6 +353,9 @@ export class Players { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts b/sdks/full/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts index 99877718dc..e18c001ea0 100644 --- a/sdks/full/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts @@ -55,6 +55,9 @@ export class Regions { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/portal/resources/games/client/Client.ts b/sdks/full/typescript/src/api/resources/portal/resources/games/client/Client.ts index eabad01e3a..0601a3a2e3 100644 --- a/sdks/full/typescript/src/api/resources/portal/resources/games/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/portal/resources/games/client/Client.ts @@ -67,6 +67,9 @@ export class Games { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/provision/resources/datacenters/client/Client.ts b/sdks/full/typescript/src/api/resources/provision/resources/datacenters/client/Client.ts index 3cced49ae6..cf4d364eb7 100644 --- a/sdks/full/typescript/src/api/resources/provision/resources/datacenters/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/provision/resources/datacenters/client/Client.ts @@ -55,6 +55,9 @@ export class Datacenters { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/provision/resources/servers/client/Client.ts b/sdks/full/typescript/src/api/resources/provision/resources/servers/client/Client.ts index bb18915d86..893da771a9 100644 --- a/sdks/full/typescript/src/api/resources/provision/resources/servers/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/provision/resources/servers/client/Client.ts @@ -55,6 +55,9 @@ export class Servers { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/servers/client/Client.ts b/sdks/full/typescript/src/api/resources/servers/client/Client.ts index 92cccc69cb..179d952b64 100644 --- a/sdks/full/typescript/src/api/resources/servers/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/servers/client/Client.ts @@ -66,6 +66,9 @@ export class Servers { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -218,6 +221,9 @@ export class Servers { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -350,10 +356,10 @@ export class Servers { * } * }, * network: { - * mode: Rivet.servers.NetworkMode.Bridge, + * mode: "bridge", * ports: { * "string": { - * protocol: Rivet.servers.PortProtocol.Http, + * protocol: "http", * internalPort: 1, * routing: { * gameGuard: {}, @@ -385,6 +391,9 @@ export class Servers { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -532,6 +541,9 @@ export class Servers { method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/servers/resources/builds/client/Client.ts b/sdks/full/typescript/src/api/resources/servers/resources/builds/client/Client.ts index 85ea52e9c8..65dbd9dab9 100644 --- a/sdks/full/typescript/src/api/resources/servers/resources/builds/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/servers/resources/builds/client/Client.ts @@ -73,6 +73,9 @@ export class Builds { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -216,6 +219,9 @@ export class Builds { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -358,6 +364,9 @@ export class Builds { method: "PATCH", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -486,8 +495,8 @@ export class Builds { * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.servers.BuildKind.DockerImage, - * compression: Rivet.servers.BuildCompression.None, + * kind: "docker_image", + * compression: "none", * prewarmDatacenters: ["d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"] * }) */ @@ -505,6 +514,9 @@ export class Builds { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", @@ -642,6 +654,9 @@ export class Builds { method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/servers/resources/datacenters/client/Client.ts b/sdks/full/typescript/src/api/resources/servers/resources/datacenters/client/Client.ts index 62359f78e9..96c1a3cc4f 100644 --- a/sdks/full/typescript/src/api/resources/servers/resources/datacenters/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/servers/resources/datacenters/client/Client.ts @@ -57,6 +57,9 @@ export class Datacenters { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", requestType: "json", diff --git a/sdks/full/typescript/src/api/resources/servers/resources/logs/client/Client.ts b/sdks/full/typescript/src/api/resources/servers/resources/logs/client/Client.ts index d4846f286f..e29c33a09b 100644 --- a/sdks/full/typescript/src/api/resources/servers/resources/logs/client/Client.ts +++ b/sdks/full/typescript/src/api/resources/servers/resources/logs/client/Client.ts @@ -47,7 +47,7 @@ export class Logs { * * @example * await client.servers.logs.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * stream: Rivet.servers.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * }) */ @@ -75,6 +75,9 @@ export class Logs { method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, diff --git a/sdks/full/typescript/src/api/resources/servers/resources/logs/client/requests/GetServerLogsRequest.ts b/sdks/full/typescript/src/api/resources/servers/resources/logs/client/requests/GetServerLogsRequest.ts index 3e92c62f94..4585514678 100644 --- a/sdks/full/typescript/src/api/resources/servers/resources/logs/client/requests/GetServerLogsRequest.ts +++ b/sdks/full/typescript/src/api/resources/servers/resources/logs/client/requests/GetServerLogsRequest.ts @@ -7,7 +7,7 @@ import * as Rivet from "../../../../../../index"; /** * @example * { - * stream: Rivet.servers.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * } */ diff --git a/sdks/full/typescript/src/core/fetcher/Fetcher.ts b/sdks/full/typescript/src/core/fetcher/Fetcher.ts index d67bc04210..b8f23717b6 100644 --- a/sdks/full/typescript/src/core/fetcher/Fetcher.ts +++ b/sdks/full/typescript/src/core/fetcher/Fetcher.ts @@ -21,7 +21,7 @@ export declare namespace Fetcher { withCredentials?: boolean; abortSignal?: AbortSignal; requestType?: "json" | "file" | "bytes"; - responseType?: "json" | "blob" | "sse" | "streaming" | "text"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; duplex?: "half"; } diff --git a/sdks/full/typescript/src/core/fetcher/getResponseBody.ts b/sdks/full/typescript/src/core/fetcher/getResponseBody.ts index a7a9c50877..d046e6ea27 100644 --- a/sdks/full/typescript/src/core/fetcher/getResponseBody.ts +++ b/sdks/full/typescript/src/core/fetcher/getResponseBody.ts @@ -3,6 +3,8 @@ import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; export async function getResponseBody(response: Response, responseType?: string): Promise { if (response.body != null && responseType === "blob") { return await response.blob(); + } else if (response.body != null && responseType === "arrayBuffer") { + return await response.arrayBuffer(); } else if (response.body != null && responseType === "sse") { return response.body; } else if (response.body != null && responseType === "streaming") { diff --git a/sdks/full/typescript/src/core/fetcher/requestWithRetries.ts b/sdks/full/typescript/src/core/fetcher/requestWithRetries.ts index ff5dc3bbab..8d5af9d5a8 100644 --- a/sdks/full/typescript/src/core/fetcher/requestWithRetries.ts +++ b/sdks/full/typescript/src/core/fetcher/requestWithRetries.ts @@ -1,6 +1,13 @@ -const INITIAL_RETRY_DELAY = 1; -const MAX_RETRY_DELAY = 60; +const INITIAL_RETRY_DELAY = 1000; // in milliseconds +const MAX_RETRY_DELAY = 60000; // in milliseconds const DEFAULT_MAX_RETRIES = 2; +const JITTER_FACTOR = 0.2; // 20% random jitter + +function addJitter(delay: number): number { + // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR + const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; + return delay * jitterMultiplier; +} export async function requestWithRetries( requestFn: () => Promise, @@ -10,8 +17,13 @@ export async function requestWithRetries( for (let i = 0; i < maxRetries; ++i) { if ([408, 409, 429].includes(response.status) || response.status >= 500) { - const delay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); - await new Promise((resolve) => setTimeout(resolve, delay)); + // Calculate base delay using exponential backoff (in milliseconds) + const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); + + // Add jitter to the delay + const delayWithJitter = addJitter(baseDelay); + + await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); response = await requestFn(); } else { break; diff --git a/sdks/full/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/sdks/full/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts index 5cc74b6b1b..4d7b7d52e8 100644 --- a/sdks/full/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts +++ b/sdks/full/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -1,17 +1,18 @@ -import type { Writable } from "stream"; +import type { Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; -export class Node18UniversalStreamWrapper - implements StreamWrapper, Uint8Array> +export class Node18UniversalStreamWrapper + implements + StreamWrapper | Writable | WritableStream, ReadFormat> { - private readableStream: ReadableStream; - private reader: ReadableStreamDefaultReader; + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; private events: Record; private paused: boolean; private resumeCallback: ((value?: unknown) => void) | null; private encoding: string | null; - constructor(readableStream: ReadableStream) { + constructor(readableStream: ReadableStream) { this.readableStream = readableStream; this.reader = this.readableStream.getReader(); this.events = { @@ -37,8 +38,8 @@ export class Node18UniversalStreamWrapper } public pipe( - dest: Node18UniversalStreamWrapper | Writable | WritableStream - ): Node18UniversalStreamWrapper | Writable | WritableStream { + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { this.on("data", async (chunk) => { if (dest instanceof Node18UniversalStreamWrapper) { dest._write(chunk); @@ -78,12 +79,12 @@ export class Node18UniversalStreamWrapper } public pipeTo( - dest: Node18UniversalStreamWrapper | Writable | WritableStream - ): Node18UniversalStreamWrapper | Writable | WritableStream { + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { return this.pipe(dest); } - public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { + public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { this.off("data", async (chunk) => { if (dest instanceof Node18UniversalStreamWrapper) { dest._write(chunk); @@ -149,7 +150,7 @@ export class Node18UniversalStreamWrapper return this.paused; } - public async read(): Promise { + public async read(): Promise { if (this.paused) { await new Promise((resolve) => { this.resumeCallback = resolve; @@ -168,12 +169,16 @@ export class Node18UniversalStreamWrapper } public async text(): Promise { - const chunks: Uint8Array[] = []; + const chunks: ReadFormat[] = []; while (true) { const { done, value } = await this.reader.read(); - if (done) break; - if (value) chunks.push(value); + if (done) { + break; + } + if (value) { + chunks.push(value); + } } const decoder = new TextDecoder(this.encoding || "utf-8"); @@ -185,7 +190,7 @@ export class Node18UniversalStreamWrapper return JSON.parse(text); } - private _write(chunk: Uint8Array): void { + private _write(chunk: ReadFormat): void { this._emit("data", chunk); } @@ -228,4 +233,24 @@ export class Node18UniversalStreamWrapper this._emit("error", error); } } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/full/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/sdks/full/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts index d73daba8ce..ba5f727675 100644 --- a/sdks/full/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts +++ b/sdks/full/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -1,4 +1,4 @@ -import type { Readable, Writable } from "stream"; +import type { Readable, Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export class NodePre18StreamWrapper implements StreamWrapper { @@ -87,4 +87,20 @@ export class NodePre18StreamWrapper implements StreamWrapper { const text = await this.text(); return JSON.parse(text); } + + public [Symbol.asyncIterator](): AsyncIterableIterator { + const readableStream = this.readableStream; + const iterator = readableStream[Symbol.asyncIterator](); + + // Create and return an async iterator that yields buffers + return { + async next(): Promise> { + const { value, done } = await iterator.next(); + return { value: value as Buffer, done }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/full/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/sdks/full/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts index 55c048732c..263af00911 100644 --- a/sdks/full/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts +++ b/sdks/full/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -78,7 +78,7 @@ export class UndiciStreamWrapper | WritableStream): void { + public unpipe(dest: UndiciStreamWrapper | WritableStream): void { this.off("data", (chunk) => { if (dest instanceof UndiciStreamWrapper) { dest._write(chunk); @@ -160,8 +160,12 @@ export class UndiciStreamWrapper { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/full/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/sdks/full/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts index 3295582d02..2abd6b2ba1 100644 --- a/sdks/full/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts +++ b/sdks/full/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -1,4 +1,4 @@ -import type { Readable } from "stream"; +import type { Readable } from "readable-stream"; import { RUNTIME } from "../../runtime"; export type EventCallback = (data?: any) => void; @@ -17,6 +17,7 @@ export interface StreamWrapper { read(): Promise; text(): Promise; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } export async function chooseStreamWrapper(responseBody: any): Promise>> { @@ -24,7 +25,7 @@ export async function chooseStreamWrapper(responseBody: any): Promise { } export const SchemaType = { + BIGINT: "bigint", DATE: "date", ENUM: "enum", LIST: "list", diff --git a/sdks/full/typescript/src/core/schemas/builders/bigint/bigint.ts b/sdks/full/typescript/src/core/schemas/builders/bigint/bigint.ts new file mode 100644 index 0000000000..dc9c742e00 --- /dev/null +++ b/sdks/full/typescript/src/core/schemas/builders/bigint/bigint.ts @@ -0,0 +1,50 @@ +import { BaseSchema, Schema, SchemaType } from "../../Schema"; +import { getErrorMessageForIncorrectType } from "../../utils/getErrorMessageForIncorrectType"; +import { maybeSkipValidation } from "../../utils/maybeSkipValidation"; +import { getSchemaUtils } from "../schema-utils"; + +export function bigint(): Schema { + const baseSchema: BaseSchema = { + parse: (raw, { breadcrumbsPrefix = [] } = {}) => { + if (typeof raw !== "string") { + return { + ok: false, + errors: [ + { + path: breadcrumbsPrefix, + message: getErrorMessageForIncorrectType(raw, "string"), + }, + ], + }; + } + return { + ok: true, + value: BigInt(raw), + }; + }, + json: (bigint, { breadcrumbsPrefix = [] } = {}) => { + if (typeof bigint === "bigint") { + return { + ok: true, + value: bigint.toString(), + }; + } else { + return { + ok: false, + errors: [ + { + path: breadcrumbsPrefix, + message: getErrorMessageForIncorrectType(bigint, "bigint"), + }, + ], + }; + } + }, + getType: () => SchemaType.BIGINT, + }; + + return { + ...maybeSkipValidation(baseSchema), + ...getSchemaUtils(baseSchema), + }; +} diff --git a/sdks/full/typescript/src/core/schemas/builders/bigint/index.ts b/sdks/full/typescript/src/core/schemas/builders/bigint/index.ts new file mode 100644 index 0000000000..e5843043fc --- /dev/null +++ b/sdks/full/typescript/src/core/schemas/builders/bigint/index.ts @@ -0,0 +1 @@ +export { bigint } from "./bigint"; diff --git a/sdks/full/typescript/src/core/schemas/builders/index.ts b/sdks/full/typescript/src/core/schemas/builders/index.ts index 050cd2c4ef..65211f9252 100644 --- a/sdks/full/typescript/src/core/schemas/builders/index.ts +++ b/sdks/full/typescript/src/core/schemas/builders/index.ts @@ -1,3 +1,4 @@ +export * from "./bigint"; export * from "./date"; export * from "./enum"; export * from "./lazy"; diff --git a/sdks/full/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts b/sdks/full/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts index 438012df41..1a5c31027c 100644 --- a/sdks/full/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts +++ b/sdks/full/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts @@ -9,9 +9,13 @@ function getTypeAsString(value: unknown): string { if (value === null) { return "null"; } + if (value instanceof BigInt) { + return "BigInt"; + } switch (typeof value) { case "string": return `"${value}"`; + case "bigint": case "number": case "boolean": case "undefined": diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/GetBuildResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/GetBuildResponse.ts index 533ab202c4..ad0991b6a9 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/GetBuildResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/GetBuildResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Build as actor_common$$build } from "../../common/types/Build"; -import { actor } from "../../../../index"; +import { Build } from "../../common/types/Build"; export const GetBuildResponse: core.serialization.ObjectSchema< serializers.actor.GetBuildResponse.Raw, Rivet.actor.GetBuildResponse > = core.serialization.object({ - build: actor_common$$build, + build: Build, }); export declare namespace GetBuildResponse { interface Raw { - build: actor.Build.Raw; + build: Build.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/ListBuildsResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/ListBuildsResponse.ts index 9f63e71bdf..6bf90e4c05 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/ListBuildsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/builds/types/ListBuildsResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Build as actor_common$$build } from "../../common/types/Build"; -import { actor } from "../../../../index"; +import { Build } from "../../common/types/Build"; export const ListBuildsResponse: core.serialization.ObjectSchema< serializers.actor.ListBuildsResponse.Raw, Rivet.actor.ListBuildsResponse > = core.serialization.object({ - builds: core.serialization.list(actor_common$$build), + builds: core.serialization.list(Build), }); export declare namespace ListBuildsResponse { interface Raw { - builds: actor.Build.Raw[]; + builds: Build.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Actor.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Actor.ts index 209ec79ea7..1acfb79b34 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Actor.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Actor.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Runtime as actor_common$$runtime } from "./Runtime"; -import { Network as actor_common$$network } from "./Network"; -import { Resources as actor_common$$resources } from "./Resources"; -import { Lifecycle as actor_common$$lifecycle } from "./Lifecycle"; -import { actor } from "../../../../index"; +import { Runtime } from "./Runtime"; +import { Network } from "./Network"; +import { Resources } from "./Resources"; +import { Lifecycle } from "./Lifecycle"; export const Actor: core.serialization.ObjectSchema = core.serialization.object({ id: core.serialization.string(), region: core.serialization.string(), tags: core.serialization.unknown(), - runtime: actor_common$$runtime, - network: actor_common$$network, - resources: actor_common$$resources, - lifecycle: actor_common$$lifecycle, + runtime: Runtime, + network: Network, + resources: Resources, + lifecycle: Lifecycle, createdAt: core.serialization.property("created_at", core.serialization.number()), startedAt: core.serialization.property("started_at", core.serialization.number().optional()), destroyedAt: core.serialization.property("destroyed_at", core.serialization.number().optional()), @@ -30,10 +29,10 @@ export declare namespace Actor { id: string; region: string; tags?: unknown; - runtime: actor.Runtime.Raw; - network: actor.Network.Raw; - resources: actor.Resources.Raw; - lifecycle: actor.Lifecycle.Raw; + runtime: Runtime.Raw; + network: Network.Raw; + resources: Resources.Raw; + lifecycle: Lifecycle.Raw; created_at: number; started_at?: number | null; destroyed_at?: number | null; diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Build.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Build.ts index d176810d7c..f7b1bf9a0e 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Build.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Build.ts @@ -5,14 +5,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const Build: core.serialization.ObjectSchema = core.serialization.object({ id: core.serialization.string(), name: core.serialization.string(), - createdAt: core.serialization.property("created_at", common$$timestamp), + createdAt: core.serialization.property("created_at", Timestamp), contentLength: core.serialization.property("content_length", core.serialization.number()), tags: core.serialization.record(core.serialization.string(), core.serialization.string()), }); @@ -21,7 +20,7 @@ export declare namespace Build { interface Raw { id: string; name: string; - created_at: common.Timestamp.Raw; + created_at: Timestamp.Raw; content_length: number; tags: Record; } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/GameGuardRouting.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/GameGuardRouting.ts deleted file mode 100644 index 0814215f40..0000000000 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/GameGuardRouting.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { PortAuthorization as actor_common$$portAuthorization } from "./PortAuthorization"; -import { actor } from "../../../../index"; - -export const GameGuardRouting: core.serialization.ObjectSchema< - serializers.actor.GameGuardRouting.Raw, - Rivet.actor.GameGuardRouting -> = core.serialization.object({ - authorization: actor_common$$portAuthorization.optional(), -}); - -export declare namespace GameGuardRouting { - interface Raw { - authorization?: actor.PortAuthorization.Raw | null; - } -} diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Network.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Network.ts index 03503d7623..a6eb07afa1 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Network.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Network.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { NetworkMode as actor_common$$networkMode } from "./NetworkMode"; -import { Port as actor_common$$port } from "./Port"; -import { actor } from "../../../../index"; +import { NetworkMode } from "./NetworkMode"; +import { Port } from "./Port"; export const Network: core.serialization.ObjectSchema = core.serialization.object({ - mode: actor_common$$networkMode, - ports: core.serialization.record(core.serialization.string(), actor_common$$port), + mode: NetworkMode, + ports: core.serialization.record(core.serialization.string(), Port), }); export declare namespace Network { interface Raw { - mode: actor.NetworkMode.Raw; - ports: Record; + mode: NetworkMode.Raw; + ports: Record; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Port.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Port.ts index 441199fbee..2433df563f 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Port.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/Port.ts @@ -5,25 +5,24 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { PortProtocol as actor_common$$portProtocol } from "./PortProtocol"; -import { PortRouting as actor_common$$portRouting } from "./PortRouting"; -import { actor } from "../../../../index"; +import { PortProtocol } from "./PortProtocol"; +import { PortRouting } from "./PortRouting"; export const Port: core.serialization.ObjectSchema = core.serialization.object({ - protocol: actor_common$$portProtocol, + protocol: PortProtocol, internalPort: core.serialization.property("internal_port", core.serialization.number().optional()), publicHostname: core.serialization.property("public_hostname", core.serialization.string().optional()), publicPort: core.serialization.property("public_port", core.serialization.number().optional()), - routing: actor_common$$portRouting, + routing: PortRouting, }); export declare namespace Port { interface Raw { - protocol: actor.PortProtocol.Raw; + protocol: PortProtocol.Raw; internal_port?: number | null; public_hostname?: string | null; public_port?: number | null; - routing: actor.PortRouting.Raw; + routing: PortRouting.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/PortRouting.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/PortRouting.ts index d9cfdc2d7b..1dfd5201c0 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/PortRouting.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/PortRouting.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { GameGuardRouting as actor_common$$gameGuardRouting } from "./GameGuardRouting"; -import { HostRouting as actor_common$$hostRouting } from "./HostRouting"; -import { actor } from "../../../../index"; +import { GuardRouting } from "./GuardRouting"; +import { HostRouting } from "./HostRouting"; export const PortRouting: core.serialization.ObjectSchema = core.serialization.object({ - gameGuard: core.serialization.property("game_guard", actor_common$$gameGuardRouting.optional()), - host: actor_common$$hostRouting.optional(), + guard: GuardRouting.optional(), + host: HostRouting.optional(), }); export declare namespace PortRouting { interface Raw { - game_guard?: actor.GameGuardRouting.Raw | null; - host?: actor.HostRouting.Raw | null; + guard?: GuardRouting.Raw | null; + host?: HostRouting.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/index.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/index.ts index 89bf5598f2..24ce1387ca 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/index.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/common/types/index.ts @@ -7,7 +7,7 @@ export * from "./NetworkMode"; export * from "./Port"; export * from "./PortProtocol"; export * from "./PortRouting"; -export * from "./GameGuardRouting"; +export * from "./GuardRouting"; export * from "./PortAuthorization"; export * from "./PortQueryAuthorization"; export * from "./HostRouting"; diff --git a/sdks/full/typescript/src/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.ts index 5397def90b..79cc8c5d45 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { common } from "../../../../index"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const GetActorLogsResponse: core.serialization.ObjectSchema< serializers.actor.GetActorLogsResponse.Raw, @@ -14,13 +13,13 @@ export const GetActorLogsResponse: core.serialization.ObjectSchema< > = core.serialization.object({ lines: core.serialization.list(core.serialization.string()), timestamps: core.serialization.list(core.serialization.string()), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetActorLogsResponse { interface Raw { lines: string[]; timestamps: string[]; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorNetworkRequest.ts b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorNetworkRequest.ts index 8a68d95bac..b77b9391a3 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorNetworkRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorNetworkRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { NetworkMode as actor_common$$networkMode } from "../resources/common/types/NetworkMode"; -import { CreateActorPortRequest as actor$$createActorPortRequest } from "./CreateActorPortRequest"; -import { actor } from "../../index"; +import { NetworkMode } from "../resources/common/types/NetworkMode"; +import { CreateActorPortRequest } from "./CreateActorPortRequest"; export const CreateActorNetworkRequest: core.serialization.ObjectSchema< serializers.actor.CreateActorNetworkRequest.Raw, Rivet.actor.CreateActorNetworkRequest > = core.serialization.object({ - mode: actor_common$$networkMode.optional(), - ports: core.serialization.record(core.serialization.string(), actor$$createActorPortRequest).optional(), + mode: NetworkMode.optional(), + ports: core.serialization.record(core.serialization.string(), CreateActorPortRequest).optional(), }); export declare namespace CreateActorNetworkRequest { interface Raw { - mode?: actor.NetworkMode.Raw | null; - ports?: Record | null; + mode?: NetworkMode.Raw | null; + ports?: Record | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorPortRequest.ts b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorPortRequest.ts index 943f5a7382..6fe88c3776 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorPortRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorPortRequest.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { PortProtocol as actor_common$$portProtocol } from "../resources/common/types/PortProtocol"; -import { PortRouting as actor_common$$portRouting } from "../resources/common/types/PortRouting"; -import { actor } from "../../index"; +import { PortProtocol } from "../resources/common/types/PortProtocol"; +import { PortRouting } from "../resources/common/types/PortRouting"; export const CreateActorPortRequest: core.serialization.ObjectSchema< serializers.actor.CreateActorPortRequest.Raw, Rivet.actor.CreateActorPortRequest > = core.serialization.object({ - protocol: actor_common$$portProtocol, + protocol: PortProtocol, internalPort: core.serialization.property("internal_port", core.serialization.number().optional()), - routing: actor_common$$portRouting.optional(), + routing: PortRouting.optional(), }); export declare namespace CreateActorPortRequest { interface Raw { - protocol: actor.PortProtocol.Raw; + protocol: PortProtocol.Raw; internal_port?: number | null; - routing?: actor.PortRouting.Raw | null; + routing?: PortRouting.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorRequest.ts b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorRequest.ts index 85f57348cf..36f1e1b45c 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorRequest.ts @@ -5,11 +5,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { CreateActorRuntimeRequest as actor$$createActorRuntimeRequest } from "./CreateActorRuntimeRequest"; -import { CreateActorNetworkRequest as actor$$createActorNetworkRequest } from "./CreateActorNetworkRequest"; -import { Resources as actor_common$$resources } from "../resources/common/types/Resources"; -import { Lifecycle as actor_common$$lifecycle } from "../resources/common/types/Lifecycle"; -import { actor } from "../../index"; +import { CreateActorRuntimeRequest } from "./CreateActorRuntimeRequest"; +import { CreateActorNetworkRequest } from "./CreateActorNetworkRequest"; +import { Resources } from "../resources/common/types/Resources"; +import { Lifecycle } from "../resources/common/types/Lifecycle"; export const CreateActorRequest: core.serialization.ObjectSchema< serializers.actor.CreateActorRequest.Raw, @@ -17,19 +16,19 @@ export const CreateActorRequest: core.serialization.ObjectSchema< > = core.serialization.object({ region: core.serialization.string(), tags: core.serialization.unknown(), - runtime: actor$$createActorRuntimeRequest, - network: actor$$createActorNetworkRequest.optional(), - resources: actor_common$$resources, - lifecycle: actor_common$$lifecycle.optional(), + runtime: CreateActorRuntimeRequest, + network: CreateActorNetworkRequest.optional(), + resources: Resources, + lifecycle: Lifecycle.optional(), }); export declare namespace CreateActorRequest { interface Raw { region: string; tags?: unknown; - runtime: actor.CreateActorRuntimeRequest.Raw; - network?: actor.CreateActorNetworkRequest.Raw | null; - resources: actor.Resources.Raw; - lifecycle?: actor.Lifecycle.Raw | null; + runtime: CreateActorRuntimeRequest.Raw; + network?: CreateActorNetworkRequest.Raw | null; + resources: Resources.Raw; + lifecycle?: Lifecycle.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorResponse.ts index 5f04bb5119..0b460b8388 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/CreateActorResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Actor as actor_common$$actor } from "../resources/common/types/Actor"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export const CreateActorResponse: core.serialization.ObjectSchema< serializers.actor.CreateActorResponse.Raw, Rivet.actor.CreateActorResponse > = core.serialization.object({ - actor: actor_common$$actor, + actor: Actor, }); export declare namespace CreateActorResponse { interface Raw { - actor: actor.Actor.Raw; + actor: Actor.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/GetActorResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/types/GetActorResponse.ts index 31ef9f10ab..2aff4a4676 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/GetActorResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/GetActorResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Actor as actor_common$$actor } from "../resources/common/types/Actor"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export const GetActorResponse: core.serialization.ObjectSchema< serializers.actor.GetActorResponse.Raw, Rivet.actor.GetActorResponse > = core.serialization.object({ - actor: actor_common$$actor, + actor: Actor, }); export declare namespace GetActorResponse { interface Raw { - actor: actor.Actor.Raw; + actor: Actor.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/actor/types/ListActorsResponse.ts b/sdks/full/typescript/src/serialization/resources/actor/types/ListActorsResponse.ts index 6bfb56aace..93b573d618 100644 --- a/sdks/full/typescript/src/serialization/resources/actor/types/ListActorsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/actor/types/ListActorsResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Actor as actor_common$$actor } from "../resources/common/types/Actor"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export const ListActorsResponse: core.serialization.ObjectSchema< serializers.actor.ListActorsResponse.Raw, Rivet.actor.ListActorsResponse > = core.serialization.object({ - actors: core.serialization.list(actor_common$$actor), + actors: core.serialization.list(Actor), }); export declare namespace ListActorsResponse { interface Raw { - actors: actor.Actor.Raw[]; + actors: Actor.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.ts b/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.ts index 18b26b8035..aa6aa090ca 100644 --- a/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CompleteStatus as auth_common$$completeStatus } from "../../../../common/types/CompleteStatus"; -import { auth } from "../../../../../../index"; +import { CompleteStatus } from "../../../../common/types/CompleteStatus"; export const CompleteEmailVerificationResponse: core.serialization.ObjectSchema< serializers.auth.identity.CompleteEmailVerificationResponse.Raw, Rivet.auth.identity.CompleteEmailVerificationResponse > = core.serialization.object({ - status: auth_common$$completeStatus, + status: CompleteStatus, }); export declare namespace CompleteEmailVerificationResponse { interface Raw { - status: auth.CompleteStatus.Raw; + status: CompleteStatus.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.ts b/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.ts index 1512e69c27..1def034429 100644 --- a/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.ts @@ -5,22 +5,21 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Config as captcha_config$$config } from "../../../../../../captcha/resources/config/types/Config"; -import { captcha } from "../../../../../../index"; +import { Config } from "../../../../../../captcha/resources/config/types/Config"; export const StartEmailVerificationRequest: core.serialization.ObjectSchema< serializers.auth.identity.StartEmailVerificationRequest.Raw, Rivet.auth.identity.StartEmailVerificationRequest > = core.serialization.object({ email: core.serialization.string(), - captcha: captcha_config$$config.optional(), + captcha: Config.optional(), gameId: core.serialization.property("game_id", core.serialization.string().optional()), }); export declare namespace StartEmailVerificationRequest { interface Raw { email: string; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; game_id?: string | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts b/sdks/full/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts index 1305d71bf1..19f2c18d11 100644 --- a/sdks/full/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { ConfigHcaptcha as captcha_config$$configHcaptcha } from "./ConfigHcaptcha"; -import { ConfigTurnstile as captcha_config$$configTurnstile } from "./ConfigTurnstile"; -import { captcha } from "../../../../index"; +import { ConfigHcaptcha } from "./ConfigHcaptcha"; +import { ConfigTurnstile } from "./ConfigTurnstile"; export const Config: core.serialization.ObjectSchema = core.serialization.object({ - hcaptcha: captcha_config$$configHcaptcha.optional(), - turnstile: captcha_config$$configTurnstile.optional(), + hcaptcha: ConfigHcaptcha.optional(), + turnstile: ConfigTurnstile.optional(), }); export declare namespace Config { interface Raw { - hcaptcha?: captcha.ConfigHcaptcha.Raw | null; - turnstile?: captcha.ConfigTurnstile.Raw | null; + hcaptcha?: ConfigHcaptcha.Raw | null; + turnstile?: ConfigTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/auth/types/InspectResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/auth/types/InspectResponse.ts index 78d5e8507e..93ca2e5bf9 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/auth/types/InspectResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/auth/types/InspectResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { AuthAgent as cloud_common$$authAgent } from "../../common/types/AuthAgent"; -import { cloud } from "../../../../index"; +import { AuthAgent } from "../../common/types/AuthAgent"; export const InspectResponse: core.serialization.ObjectSchema< serializers.cloud.InspectResponse.Raw, Rivet.cloud.InspectResponse > = core.serialization.object({ - agent: cloud_common$$authAgent, + agent: AuthAgent, }); export declare namespace InspectResponse { interface Raw { - agent: cloud.AuthAgent.Raw; + agent: AuthAgent.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/AuthAgent.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/AuthAgent.ts index 682808aa8c..7e5670156a 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/AuthAgent.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/AuthAgent.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { AuthAgentIdentity as cloud_common$$authAgentIdentity } from "./AuthAgentIdentity"; -import { AuthAgentGameCloud as cloud_common$$authAgentGameCloud } from "./AuthAgentGameCloud"; -import { cloud } from "../../../../index"; +import { AuthAgentIdentity } from "./AuthAgentIdentity"; +import { AuthAgentGameCloud } from "./AuthAgentGameCloud"; export const AuthAgent: core.serialization.ObjectSchema = core.serialization.object({ - identity: cloud_common$$authAgentIdentity.optional(), - gameCloud: core.serialization.property("game_cloud", cloud_common$$authAgentGameCloud.optional()), + identity: AuthAgentIdentity.optional(), + gameCloud: core.serialization.property("game_cloud", AuthAgentGameCloud.optional()), }); export declare namespace AuthAgent { interface Raw { - identity?: cloud.AuthAgentIdentity.Raw | null; - game_cloud?: cloud.AuthAgentGameCloud.Raw | null; + identity?: AuthAgentIdentity.Raw | null; + game_cloud?: AuthAgentGameCloud.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/BuildSummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/BuildSummary.ts index 0c18b5a6a6..d9986e8d36 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/BuildSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/BuildSummary.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const BuildSummary: core.serialization.ObjectSchema< serializers.cloud.BuildSummary.Raw, @@ -15,8 +14,8 @@ export const BuildSummary: core.serialization.ObjectSchema< > = core.serialization.object({ buildId: core.serialization.property("build_id", core.serialization.string()), uploadId: core.serialization.property("upload_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - createTs: core.serialization.property("create_ts", common$$timestamp), + displayName: core.serialization.property("display_name", DisplayName), + createTs: core.serialization.property("create_ts", Timestamp), contentLength: core.serialization.property("content_length", core.serialization.number()), complete: core.serialization.boolean(), tags: core.serialization.record(core.serialization.string(), core.serialization.string()), @@ -26,8 +25,8 @@ export declare namespace BuildSummary { interface Raw { build_id: string; upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; content_length: number; complete: boolean; tags: Record; diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.ts index de31680fb3..9d1afbd452 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.ts @@ -5,29 +5,25 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { CdnNamespaceDomain as cloud_common$$cdnNamespaceDomain } from "./CdnNamespaceDomain"; -import { CdnAuthType as cloud_common$$cdnAuthType } from "./CdnAuthType"; -import { CdnNamespaceAuthUser as cloud_common$$cdnNamespaceAuthUser } from "./CdnNamespaceAuthUser"; -import { cloud } from "../../../../index"; +import { CdnNamespaceDomain } from "./CdnNamespaceDomain"; +import { CdnAuthType } from "./CdnAuthType"; +import { CdnNamespaceAuthUser } from "./CdnNamespaceAuthUser"; export const CdnNamespaceConfig: core.serialization.ObjectSchema< serializers.cloud.CdnNamespaceConfig.Raw, Rivet.cloud.CdnNamespaceConfig > = core.serialization.object({ enableDomainPublicAuth: core.serialization.property("enable_domain_public_auth", core.serialization.boolean()), - domains: core.serialization.list(cloud_common$$cdnNamespaceDomain), - authType: core.serialization.property("auth_type", cloud_common$$cdnAuthType), - authUserList: core.serialization.property( - "auth_user_list", - core.serialization.list(cloud_common$$cdnNamespaceAuthUser) - ), + domains: core.serialization.list(CdnNamespaceDomain), + authType: core.serialization.property("auth_type", CdnAuthType), + authUserList: core.serialization.property("auth_user_list", core.serialization.list(CdnNamespaceAuthUser)), }); export declare namespace CdnNamespaceConfig { interface Raw { enable_domain_public_auth: boolean; - domains: cloud.CdnNamespaceDomain.Raw[]; - auth_type: cloud.CdnAuthType.Raw; - auth_user_list: cloud.CdnNamespaceAuthUser.Raw[]; + domains: CdnNamespaceDomain.Raw[]; + auth_type: CdnAuthType.Raw; + auth_user_list: CdnNamespaceAuthUser.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.ts index 978236eb93..8be5e1a926 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.ts @@ -5,25 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { CdnNamespaceDomainVerificationStatus as cloud_common$$cdnNamespaceDomainVerificationStatus } from "./CdnNamespaceDomainVerificationStatus"; -import { CdnNamespaceDomainVerificationMethod as cloud_common$$cdnNamespaceDomainVerificationMethod } from "./CdnNamespaceDomainVerificationMethod"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { CdnNamespaceDomainVerificationStatus } from "./CdnNamespaceDomainVerificationStatus"; +import { CdnNamespaceDomainVerificationMethod } from "./CdnNamespaceDomainVerificationMethod"; export const CdnNamespaceDomain: core.serialization.ObjectSchema< serializers.cloud.CdnNamespaceDomain.Raw, Rivet.cloud.CdnNamespaceDomain > = core.serialization.object({ domain: core.serialization.string(), - createTs: core.serialization.property("create_ts", common$$timestamp), - verificationStatus: core.serialization.property( - "verification_status", - cloud_common$$cdnNamespaceDomainVerificationStatus - ), - verificationMethod: core.serialization.property( - "verification_method", - cloud_common$$cdnNamespaceDomainVerificationMethod - ), + createTs: core.serialization.property("create_ts", Timestamp), + verificationStatus: core.serialization.property("verification_status", CdnNamespaceDomainVerificationStatus), + verificationMethod: core.serialization.property("verification_method", CdnNamespaceDomainVerificationMethod), verificationErrors: core.serialization.property( "verification_errors", core.serialization.list(core.serialization.string()) @@ -33,9 +26,9 @@ export const CdnNamespaceDomain: core.serialization.ObjectSchema< export declare namespace CdnNamespaceDomain { interface Raw { domain: string; - create_ts: common.Timestamp.Raw; - verification_status: cloud.CdnNamespaceDomainVerificationStatus.Raw; - verification_method: cloud.CdnNamespaceDomainVerificationMethod.Raw; + create_ts: Timestamp.Raw; + verification_status: CdnNamespaceDomainVerificationStatus.Raw; + verification_method: CdnNamespaceDomainVerificationMethod.Raw; verification_errors: string[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.ts index 8e6410d669..3990328344 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { EmptyObject as common$$emptyObject } from "../../../../common/types/EmptyObject"; -import { CdnNamespaceDomainVerificationMethodHttp as cloud_common$$cdnNamespaceDomainVerificationMethodHttp } from "./CdnNamespaceDomainVerificationMethodHttp"; -import { common, cloud } from "../../../../index"; +import { EmptyObject } from "../../../../common/types/EmptyObject"; +import { CdnNamespaceDomainVerificationMethodHttp } from "./CdnNamespaceDomainVerificationMethodHttp"; export const CdnNamespaceDomainVerificationMethod: core.serialization.ObjectSchema< serializers.cloud.CdnNamespaceDomainVerificationMethod.Raw, Rivet.cloud.CdnNamespaceDomainVerificationMethod > = core.serialization.object({ - invalid: common$$emptyObject.optional(), - http: cloud_common$$cdnNamespaceDomainVerificationMethodHttp.optional(), + invalid: EmptyObject.optional(), + http: CdnNamespaceDomainVerificationMethodHttp.optional(), }); export declare namespace CdnNamespaceDomainVerificationMethod { interface Raw { - invalid?: common.EmptyObject.Raw | null; - http?: cloud.CdnNamespaceDomainVerificationMethodHttp.Raw | null; + invalid?: EmptyObject.Raw | null; + http?: CdnNamespaceDomainVerificationMethodHttp.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnSiteSummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnSiteSummary.ts index 6ef6ffad70..1ab60c57fc 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnSiteSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CdnSiteSummary.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const CdnSiteSummary: core.serialization.ObjectSchema< serializers.cloud.CdnSiteSummary.Raw, @@ -15,8 +14,8 @@ export const CdnSiteSummary: core.serialization.ObjectSchema< > = core.serialization.object({ siteId: core.serialization.property("site_id", core.serialization.string()), uploadId: core.serialization.property("upload_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - createTs: core.serialization.property("create_ts", common$$timestamp), + displayName: core.serialization.property("display_name", DisplayName), + createTs: core.serialization.property("create_ts", Timestamp), contentLength: core.serialization.property("content_length", core.serialization.number()), complete: core.serialization.boolean(), }); @@ -25,8 +24,8 @@ export declare namespace CdnSiteSummary { interface Raw { site_id: string; upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; content_length: number; complete: boolean; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.ts index cd24328577..f89fafa081 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.ts @@ -5,17 +5,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const CustomAvatarSummary: core.serialization.ObjectSchema< serializers.cloud.CustomAvatarSummary.Raw, Rivet.cloud.CustomAvatarSummary > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - createTs: core.serialization.property("create_ts", common$$timestamp), + displayName: core.serialization.property("display_name", DisplayName), + createTs: core.serialization.property("create_ts", Timestamp), url: core.serialization.string().optional(), contentLength: core.serialization.property("content_length", core.serialization.number()), complete: core.serialization.boolean(), @@ -24,8 +23,8 @@ export const CustomAvatarSummary: core.serialization.ObjectSchema< export declare namespace CustomAvatarSummary { interface Raw { upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; url?: string | null; content_length: number; complete: boolean; diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameFull.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameFull.ts index 5a89cfae9c..f412217913 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameFull.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameFull.ts @@ -5,43 +5,39 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { NamespaceSummary as cloud_common$$namespaceSummary } from "./NamespaceSummary"; -import { Summary as cloud_version$$summary } from "../../version/types/Summary"; -import { RegionSummary as cloud_common$$regionSummary } from "./RegionSummary"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { NamespaceSummary } from "./NamespaceSummary"; +import { Summary } from "../../version/types/Summary"; +import { RegionSummary } from "./RegionSummary"; export const GameFull: core.serialization.ObjectSchema = core.serialization.object({ gameId: core.serialization.property("game_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), + createTs: core.serialization.property("create_ts", Timestamp), nameId: core.serialization.property("name_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), developerGroupId: core.serialization.property("developer_group_id", core.serialization.string()), totalPlayerCount: core.serialization.property("total_player_count", core.serialization.number()), logoUrl: core.serialization.property("logo_url", core.serialization.string().optional()), bannerUrl: core.serialization.property("banner_url", core.serialization.string().optional()), - namespaces: core.serialization.list(cloud_common$$namespaceSummary), - versions: core.serialization.list(cloud_version$$summary), - availableRegions: core.serialization.property( - "available_regions", - core.serialization.list(cloud_common$$regionSummary) - ), + namespaces: core.serialization.list(NamespaceSummary), + versions: core.serialization.list(Summary), + availableRegions: core.serialization.property("available_regions", core.serialization.list(RegionSummary)), }); export declare namespace GameFull { interface Raw { game_id: string; - create_ts: common.Timestamp.Raw; + create_ts: Timestamp.Raw; name_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; developer_group_id: string; total_player_count: number; logo_url?: string | null; banner_url?: string | null; - namespaces: cloud.NamespaceSummary.Raw[]; - versions: cloud.version.Summary.Raw[]; - available_regions: cloud.RegionSummary.Raw[]; + namespaces: NamespaceSummary.Raw[]; + versions: Summary.Raw[]; + available_regions: RegionSummary.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.ts index 55e2de1231..bf20c872a2 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as game_common$$handle } from "../../../../game/resources/common/types/Handle"; -import { NamespaceSummary as cloud_common$$namespaceSummary } from "./NamespaceSummary"; -import { RegionTierExpenses as cloud_common$$regionTierExpenses } from "./RegionTierExpenses"; -import { game, cloud } from "../../../../index"; +import { Handle } from "../../../../game/resources/common/types/Handle"; +import { NamespaceSummary } from "./NamespaceSummary"; +import { RegionTierExpenses } from "./RegionTierExpenses"; export const GameLobbyExpenses: core.serialization.ObjectSchema< serializers.cloud.GameLobbyExpenses.Raw, Rivet.cloud.GameLobbyExpenses > = core.serialization.object({ - game: game_common$$handle, - namespaces: core.serialization.list(cloud_common$$namespaceSummary), - expenses: core.serialization.list(cloud_common$$regionTierExpenses), + game: Handle, + namespaces: core.serialization.list(NamespaceSummary), + expenses: core.serialization.list(RegionTierExpenses), }); export declare namespace GameLobbyExpenses { interface Raw { - game: game.Handle.Raw; - namespaces: cloud.NamespaceSummary.Raw[]; - expenses: cloud.RegionTierExpenses.Raw[]; + game: Handle.Raw; + namespaces: NamespaceSummary.Raw[]; + expenses: RegionTierExpenses.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.ts index 8ed4d75bdf..63ba05b9b0 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const LobbySummaryAnalytics: core.serialization.ObjectSchema< serializers.cloud.LobbySummaryAnalytics.Raw, @@ -16,7 +15,7 @@ export const LobbySummaryAnalytics: core.serialization.ObjectSchema< lobbyGroupId: core.serialization.property("lobby_group_id", core.serialization.string()), lobbyGroupNameId: core.serialization.property("lobby_group_name_id", core.serialization.string()), regionId: core.serialization.property("region_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), + createTs: core.serialization.property("create_ts", Timestamp), isReady: core.serialization.property("is_ready", core.serialization.boolean()), isIdle: core.serialization.property("is_idle", core.serialization.boolean()), isClosed: core.serialization.property("is_closed", core.serialization.boolean()), @@ -34,7 +33,7 @@ export declare namespace LobbySummaryAnalytics { lobby_group_id: string; lobby_group_name_id: string; region_id: string; - create_ts: common.Timestamp.Raw; + create_ts: Timestamp.Raw; is_ready: boolean; is_idle: boolean; is_closed: boolean; diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.ts index 24dd7fabff..cf1237da7b 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { EmptyObject as common$$emptyObject } from "../../../../common/types/EmptyObject"; -import { LogsLobbyStatusStopped as cloud_common$$logsLobbyStatusStopped } from "./LogsLobbyStatusStopped"; -import { common, cloud } from "../../../../index"; +import { EmptyObject } from "../../../../common/types/EmptyObject"; +import { LogsLobbyStatusStopped } from "./LogsLobbyStatusStopped"; export const LogsLobbyStatus: core.serialization.ObjectSchema< serializers.cloud.LogsLobbyStatus.Raw, Rivet.cloud.LogsLobbyStatus > = core.serialization.object({ - running: common$$emptyObject, - stopped: cloud_common$$logsLobbyStatusStopped.optional(), + running: EmptyObject, + stopped: LogsLobbyStatusStopped.optional(), }); export declare namespace LogsLobbyStatus { interface Raw { - running: common.EmptyObject.Raw; - stopped?: cloud.LogsLobbyStatusStopped.Raw | null; + running: EmptyObject.Raw; + stopped?: LogsLobbyStatusStopped.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.ts index e2b9abd52b..82f772e943 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const LogsLobbyStatusStopped: core.serialization.ObjectSchema< serializers.cloud.LogsLobbyStatusStopped.Raw, Rivet.cloud.LogsLobbyStatusStopped > = core.serialization.object({ - stopTs: core.serialization.property("stop_ts", common$$timestamp), + stopTs: core.serialization.property("stop_ts", Timestamp), failed: core.serialization.boolean(), exitCode: core.serialization.property("exit_code", core.serialization.number()), }); export declare namespace LogsLobbyStatusStopped { interface Raw { - stop_ts: common.Timestamp.Raw; + stop_ts: Timestamp.Raw; failed: boolean; exit_code: number; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbySummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbySummary.ts index c7906b216d..fda44b22d1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbySummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsLobbySummary.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { LogsLobbyStatus as cloud_common$$logsLobbyStatus } from "./LogsLobbyStatus"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { LogsLobbyStatus } from "./LogsLobbyStatus"; export const LogsLobbySummary: core.serialization.ObjectSchema< serializers.cloud.LogsLobbySummary.Raw, @@ -17,10 +16,10 @@ export const LogsLobbySummary: core.serialization.ObjectSchema< namespaceId: core.serialization.property("namespace_id", core.serialization.string()), lobbyGroupNameId: core.serialization.property("lobby_group_name_id", core.serialization.string()), regionId: core.serialization.property("region_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), - startTs: core.serialization.property("start_ts", common$$timestamp.optional()), - readyTs: core.serialization.property("ready_ts", common$$timestamp.optional()), - status: cloud_common$$logsLobbyStatus, + createTs: core.serialization.property("create_ts", Timestamp), + startTs: core.serialization.property("start_ts", Timestamp.optional()), + readyTs: core.serialization.property("ready_ts", Timestamp.optional()), + status: LogsLobbyStatus, }); export declare namespace LogsLobbySummary { @@ -29,9 +28,9 @@ export declare namespace LogsLobbySummary { namespace_id: string; lobby_group_name_id: string; region_id: string; - create_ts: common.Timestamp.Raw; - start_ts?: common.Timestamp.Raw | null; - ready_ts?: common.Timestamp.Raw | null; - status: cloud.LogsLobbyStatus.Raw; + create_ts: Timestamp.Raw; + start_ts?: Timestamp.Raw | null; + ready_ts?: Timestamp.Raw | null; + status: LogsLobbyStatus.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfMark.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfMark.ts index b43e354ed4..0539f26045 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfMark.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfMark.ts @@ -5,15 +5,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const LogsPerfMark: core.serialization.ObjectSchema< serializers.cloud.LogsPerfMark.Raw, Rivet.cloud.LogsPerfMark > = core.serialization.object({ label: core.serialization.string(), - ts: common$$timestamp, + ts: Timestamp, rayId: core.serialization.property("ray_id", core.serialization.string().optional()), reqId: core.serialization.property("req_id", core.serialization.string().optional()), }); @@ -21,7 +20,7 @@ export const LogsPerfMark: core.serialization.ObjectSchema< export declare namespace LogsPerfMark { interface Raw { label: string; - ts: common.Timestamp.Raw; + ts: Timestamp.Raw; ray_id?: string | null; req_id?: string | null; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfSpan.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfSpan.ts index 29a0ef6cb1..f2e5758765 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfSpan.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/LogsPerfSpan.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const LogsPerfSpan: core.serialization.ObjectSchema< serializers.cloud.LogsPerfSpan.Raw, Rivet.cloud.LogsPerfSpan > = core.serialization.object({ label: core.serialization.string(), - startTs: core.serialization.property("start_ts", common$$timestamp), - finishTs: core.serialization.property("finish_ts", common$$timestamp.optional()), + startTs: core.serialization.property("start_ts", Timestamp), + finishTs: core.serialization.property("finish_ts", Timestamp.optional()), reqId: core.serialization.property("req_id", core.serialization.string().optional()), }); export declare namespace LogsPerfSpan { interface Raw { label: string; - start_ts: common.Timestamp.Raw; - finish_ts?: common.Timestamp.Raw | null; + start_ts: Timestamp.Raw; + finish_ts?: Timestamp.Raw | null; req_id?: string | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.ts index d14bc37164..717dda33fe 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { PortRange as cloud_version_matchmaker_common$$portRange } from "../../version/resources/matchmaker/resources/common/types/PortRange"; -import { PortProtocol as cloud_version_matchmaker_common$$portProtocol } from "../../version/resources/matchmaker/resources/common/types/PortProtocol"; -import { cloud } from "../../../../index"; +import { PortRange } from "../../version/resources/matchmaker/resources/common/types/PortRange"; +import { PortProtocol } from "../../version/resources/matchmaker/resources/common/types/PortProtocol"; export const MatchmakerDevelopmentPort: core.serialization.ObjectSchema< serializers.cloud.MatchmakerDevelopmentPort.Raw, Rivet.cloud.MatchmakerDevelopmentPort > = core.serialization.object({ port: core.serialization.number().optional(), - portRange: core.serialization.property("port_range", cloud_version_matchmaker_common$$portRange.optional()), - protocol: cloud_version_matchmaker_common$$portProtocol, + portRange: core.serialization.property("port_range", PortRange.optional()), + protocol: PortProtocol, }); export declare namespace MatchmakerDevelopmentPort { interface Raw { port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - protocol: cloud.version.matchmaker.PortProtocol.Raw; + port_range?: PortRange.Raw | null; + protocol: PortProtocol.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceConfig.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceConfig.ts index ce7261a12c..aa68829946 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceConfig.ts @@ -5,27 +5,26 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { CdnNamespaceConfig as cloud_common$$cdnNamespaceConfig } from "./CdnNamespaceConfig"; -import { MatchmakerNamespaceConfig as cloud_common$$matchmakerNamespaceConfig } from "./MatchmakerNamespaceConfig"; -import { KvNamespaceConfig as cloud_common$$kvNamespaceConfig } from "./KvNamespaceConfig"; -import { IdentityNamespaceConfig as cloud_common$$identityNamespaceConfig } from "./IdentityNamespaceConfig"; -import { cloud } from "../../../../index"; +import { CdnNamespaceConfig } from "./CdnNamespaceConfig"; +import { MatchmakerNamespaceConfig } from "./MatchmakerNamespaceConfig"; +import { KvNamespaceConfig } from "./KvNamespaceConfig"; +import { IdentityNamespaceConfig } from "./IdentityNamespaceConfig"; export const NamespaceConfig: core.serialization.ObjectSchema< serializers.cloud.NamespaceConfig.Raw, Rivet.cloud.NamespaceConfig > = core.serialization.object({ - cdn: cloud_common$$cdnNamespaceConfig, - matchmaker: cloud_common$$matchmakerNamespaceConfig, - kv: cloud_common$$kvNamespaceConfig, - identity: cloud_common$$identityNamespaceConfig, + cdn: CdnNamespaceConfig, + matchmaker: MatchmakerNamespaceConfig, + kv: KvNamespaceConfig, + identity: IdentityNamespaceConfig, }); export declare namespace NamespaceConfig { interface Raw { - cdn: cloud.CdnNamespaceConfig.Raw; - matchmaker: cloud.MatchmakerNamespaceConfig.Raw; - kv: cloud.KvNamespaceConfig.Raw; - identity: cloud.IdentityNamespaceConfig.Raw; + cdn: CdnNamespaceConfig.Raw; + matchmaker: MatchmakerNamespaceConfig.Raw; + kv: KvNamespaceConfig.Raw; + identity: IdentityNamespaceConfig.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceFull.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceFull.ts index f65a043ba2..1f02fe707f 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceFull.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceFull.ts @@ -5,30 +5,29 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { NamespaceConfig as cloud_common$$namespaceConfig } from "./NamespaceConfig"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { NamespaceConfig } from "./NamespaceConfig"; export const NamespaceFull: core.serialization.ObjectSchema< serializers.cloud.NamespaceFull.Raw, Rivet.cloud.NamespaceFull > = core.serialization.object({ namespaceId: core.serialization.property("namespace_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), - displayName: core.serialization.property("display_name", common$$displayName), + createTs: core.serialization.property("create_ts", Timestamp), + displayName: core.serialization.property("display_name", DisplayName), versionId: core.serialization.property("version_id", core.serialization.string()), nameId: core.serialization.property("name_id", core.serialization.string()), - config: cloud_common$$namespaceConfig, + config: NamespaceConfig, }); export declare namespace NamespaceFull { interface Raw { namespace_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; - config: cloud.NamespaceConfig.Raw; + config: NamespaceConfig.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceSummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceSummary.ts index 25718f5041..7b2d7c2ce3 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceSummary.ts @@ -5,17 +5,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const NamespaceSummary: core.serialization.ObjectSchema< serializers.cloud.NamespaceSummary.Raw, Rivet.cloud.NamespaceSummary > = core.serialization.object({ namespaceId: core.serialization.property("namespace_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), - displayName: core.serialization.property("display_name", common$$displayName), + createTs: core.serialization.property("create_ts", Timestamp), + displayName: core.serialization.property("display_name", DisplayName), versionId: core.serialization.property("version_id", core.serialization.string()), nameId: core.serialization.property("name_id", core.serialization.string()), }); @@ -23,8 +22,8 @@ export const NamespaceSummary: core.serialization.ObjectSchema< export declare namespace NamespaceSummary { interface Raw { namespace_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceVersion.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceVersion.ts index 5c4c891aab..9c72b1412b 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceVersion.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/NamespaceVersion.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const NamespaceVersion: core.serialization.ObjectSchema< serializers.cloud.NamespaceVersion.Raw, @@ -14,13 +13,13 @@ export const NamespaceVersion: core.serialization.ObjectSchema< > = core.serialization.object({ namespaceId: core.serialization.property("namespace_id", core.serialization.string()), versionId: core.serialization.property("version_id", core.serialization.string()), - deployTs: core.serialization.property("deploy_ts", common$$timestamp), + deployTs: core.serialization.property("deploy_ts", Timestamp), }); export declare namespace NamespaceVersion { interface Raw { namespace_id: string; version_id: string; - deploy_ts: common.Timestamp.Raw; + deploy_ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/RegionSummary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/RegionSummary.ts index 747dcc383b..ffd2613322 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/RegionSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/RegionSummary.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { UniversalRegion as cloud_common$$universalRegion } from "./UniversalRegion"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { cloud, common } from "../../../../index"; +import { UniversalRegion } from "./UniversalRegion"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const RegionSummary: core.serialization.ObjectSchema< serializers.cloud.RegionSummary.Raw, @@ -16,9 +15,9 @@ export const RegionSummary: core.serialization.ObjectSchema< regionId: core.serialization.property("region_id", core.serialization.string()), regionNameId: core.serialization.property("region_name_id", core.serialization.string()), provider: core.serialization.string(), - universalRegion: core.serialization.property("universal_region", cloud_common$$universalRegion), - providerDisplayName: core.serialization.property("provider_display_name", common$$displayName), - regionDisplayName: core.serialization.property("region_display_name", common$$displayName), + universalRegion: core.serialization.property("universal_region", UniversalRegion), + providerDisplayName: core.serialization.property("provider_display_name", DisplayName), + regionDisplayName: core.serialization.property("region_display_name", DisplayName), }); export declare namespace RegionSummary { @@ -26,8 +25,8 @@ export declare namespace RegionSummary { region_id: string; region_name_id: string; provider: string; - universal_region: cloud.UniversalRegion.Raw; - provider_display_name: common.DisplayName.Raw; - region_display_name: common.DisplayName.Raw; + universal_region: UniversalRegion.Raw; + provider_display_name: DisplayName.Raw; + region_display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/SvcPerf.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/SvcPerf.ts index 0e0e565737..bea37129a9 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/SvcPerf.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/common/types/SvcPerf.ts @@ -5,28 +5,27 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { LogsPerfSpan as cloud_common$$logsPerfSpan } from "./LogsPerfSpan"; -import { LogsPerfMark as cloud_common$$logsPerfMark } from "./LogsPerfMark"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { LogsPerfSpan } from "./LogsPerfSpan"; +import { LogsPerfMark } from "./LogsPerfMark"; export const SvcPerf: core.serialization.ObjectSchema = core.serialization.object({ svcName: core.serialization.property("svc_name", core.serialization.string()), - ts: common$$timestamp, + ts: Timestamp, duration: core.serialization.number(), reqId: core.serialization.property("req_id", core.serialization.string().optional()), - spans: core.serialization.list(cloud_common$$logsPerfSpan), - marks: core.serialization.list(cloud_common$$logsPerfMark), + spans: core.serialization.list(LogsPerfSpan), + marks: core.serialization.list(LogsPerfMark), }); export declare namespace SvcPerf { interface Raw { svc_name: string; - ts: common.Timestamp.Raw; + ts: Timestamp.Raw; duration: number; req_id?: string | null; - spans: cloud.LogsPerfSpan.Raw[]; - marks: cloud.LogsPerfMark.Raw[]; + spans: LogsPerfSpan.Raw[]; + marks: LogsPerfMark.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.ts index 0bbf1b9526..cb1f577d1d 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Jwt as common$$jwt } from "../../../../../../common/types/Jwt"; -import { common } from "../../../../../../index"; +import { Jwt } from "../../../../../../common/types/Jwt"; export const CompleteDeviceLinkRequest: core.serialization.ObjectSchema< serializers.cloud.devices.CompleteDeviceLinkRequest.Raw, Rivet.cloud.devices.CompleteDeviceLinkRequest > = core.serialization.object({ - deviceLinkToken: core.serialization.property("device_link_token", common$$jwt), + deviceLinkToken: core.serialization.property("device_link_token", Jwt), gameId: core.serialization.property("game_id", core.serialization.string()), }); export declare namespace CompleteDeviceLinkRequest { interface Raw { - device_link_token: common.Jwt.Raw; + device_link_token: Jwt.Raw; game_id: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.ts index fa97327a19..ec9ad91a76 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { WatchResponse as common$$watchResponse } from "../../../../../../common/types/WatchResponse"; -import { common } from "../../../../../../index"; +import { WatchResponse } from "../../../../../../common/types/WatchResponse"; export const GetDeviceLinkResponse: core.serialization.ObjectSchema< serializers.cloud.devices.GetDeviceLinkResponse.Raw, Rivet.cloud.devices.GetDeviceLinkResponse > = core.serialization.object({ cloudToken: core.serialization.property("cloud_token", core.serialization.string().optional()), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetDeviceLinkResponse { interface Raw { cloud_token?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.ts index 90f8e4d027..78b8bd9860 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.ts @@ -5,21 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CustomAvatarSummary as cloud_common$$customAvatarSummary } from "../../../../common/types/CustomAvatarSummary"; -import { cloud } from "../../../../../../index"; +import { CustomAvatarSummary } from "../../../../common/types/CustomAvatarSummary"; export const ListGameCustomAvatarsResponse: core.serialization.ObjectSchema< serializers.cloud.games.ListGameCustomAvatarsResponse.Raw, Rivet.cloud.games.ListGameCustomAvatarsResponse > = core.serialization.object({ - customAvatars: core.serialization.property( - "custom_avatars", - core.serialization.list(cloud_common$$customAvatarSummary) - ), + customAvatars: core.serialization.property("custom_avatars", core.serialization.list(CustomAvatarSummary)), }); export declare namespace ListGameCustomAvatarsResponse { interface Raw { - custom_avatars: cloud.CustomAvatarSummary.Raw[]; + custom_avatars: CustomAvatarSummary.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.ts index 8e51598fab..6d38ee9747 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export const PrepareCustomAvatarUploadResponse: core.serialization.ObjectSchema< serializers.cloud.games.PrepareCustomAvatarUploadResponse.Raw, Rivet.cloud.games.PrepareCustomAvatarUploadResponse > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequest: core.serialization.property("presigned_request", upload_common$$presignedRequest), + presignedRequest: core.serialization.property("presigned_request", PresignedRequest), }); export declare namespace PrepareCustomAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.ts index c23a4e7f54..aa5747909e 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.ts @@ -5,31 +5,30 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { PrepareFile as upload_common$$prepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; -import { BuildKind as cloud_games_builds$$buildKind } from "./BuildKind"; -import { BuildCompression as cloud_games_builds$$buildCompression } from "./BuildCompression"; -import { common, upload, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { PrepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; +import { BuildKind } from "./BuildKind"; +import { BuildCompression } from "./BuildCompression"; export const CreateGameBuildRequest: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameBuildRequest.Raw, Rivet.cloud.games.CreateGameBuildRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), imageTag: core.serialization.property("image_tag", core.serialization.string()), - imageFile: core.serialization.property("image_file", upload_common$$prepareFile), + imageFile: core.serialization.property("image_file", PrepareFile), multipartUpload: core.serialization.property("multipart_upload", core.serialization.boolean().optional()), - kind: cloud_games_builds$$buildKind.optional(), - compression: cloud_games_builds$$buildCompression.optional(), + kind: BuildKind.optional(), + compression: BuildCompression.optional(), }); export declare namespace CreateGameBuildRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; image_tag: string; - image_file: upload.PrepareFile.Raw; + image_file: PrepareFile.Raw; multipart_upload?: boolean | null; - kind?: cloud.games.BuildKind.Raw | null; - compression?: cloud.games.BuildCompression.Raw | null; + kind?: BuildKind.Raw | null; + compression?: BuildCompression.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.ts index 837c4460d4..f8f1e3c6b7 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export const CreateGameBuildResponse: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameBuildResponse.Raw, @@ -14,13 +13,10 @@ export const CreateGameBuildResponse: core.serialization.ObjectSchema< > = core.serialization.object({ buildId: core.serialization.property("build_id", core.serialization.string()), uploadId: core.serialization.property("upload_id", core.serialization.string()), - imagePresignedRequest: core.serialization.property( - "image_presigned_request", - upload_common$$presignedRequest.optional() - ), + imagePresignedRequest: core.serialization.property("image_presigned_request", PresignedRequest.optional()), imagePresignedRequests: core.serialization.property( "image_presigned_requests", - core.serialization.list(upload_common$$presignedRequest).optional() + core.serialization.list(PresignedRequest).optional() ), }); @@ -28,7 +24,7 @@ export declare namespace CreateGameBuildResponse { interface Raw { build_id: string; upload_id: string; - image_presigned_request?: upload.PresignedRequest.Raw | null; - image_presigned_requests?: upload.PresignedRequest.Raw[] | null; + image_presigned_request?: PresignedRequest.Raw | null; + image_presigned_requests?: PresignedRequest.Raw[] | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.ts index 540ea7991a..edb1c944ba 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { BuildSummary as cloud_common$$buildSummary } from "../../../../common/types/BuildSummary"; -import { cloud } from "../../../../../../index"; +import { BuildSummary } from "../../../../common/types/BuildSummary"; export const ListGameBuildsResponse: core.serialization.ObjectSchema< serializers.cloud.games.ListGameBuildsResponse.Raw, Rivet.cloud.games.ListGameBuildsResponse > = core.serialization.object({ - builds: core.serialization.list(cloud_common$$buildSummary), + builds: core.serialization.list(BuildSummary), }); export declare namespace ListGameBuildsResponse { interface Raw { - builds: cloud.BuildSummary.Raw[]; + builds: BuildSummary.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.ts index efe3ee7902..3d550f19c5 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { PrepareFile as upload_common$$prepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; -import { common, upload } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { PrepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; export const CreateGameCdnSiteRequest: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameCdnSiteRequest.Raw, Rivet.cloud.games.CreateGameCdnSiteRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), - files: core.serialization.list(upload_common$$prepareFile), + displayName: core.serialization.property("display_name", DisplayName), + files: core.serialization.list(PrepareFile), }); export declare namespace CreateGameCdnSiteRequest { interface Raw { - display_name: common.DisplayName.Raw; - files: upload.PrepareFile.Raw[]; + display_name: DisplayName.Raw; + files: PrepareFile.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.ts index b53bab20b5..97a7915405 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export const CreateGameCdnSiteResponse: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameCdnSiteResponse.Raw, @@ -14,16 +13,13 @@ export const CreateGameCdnSiteResponse: core.serialization.ObjectSchema< > = core.serialization.object({ siteId: core.serialization.property("site_id", core.serialization.string()), uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequests: core.serialization.property( - "presigned_requests", - core.serialization.list(upload_common$$presignedRequest) - ), + presignedRequests: core.serialization.property("presigned_requests", core.serialization.list(PresignedRequest)), }); export declare namespace CreateGameCdnSiteResponse { interface Raw { site_id: string; upload_id: string; - presigned_requests: upload.PresignedRequest.Raw[]; + presigned_requests: PresignedRequest.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.ts index 5536756e18..a21ff0ca43 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CdnSiteSummary as cloud_common$$cdnSiteSummary } from "../../../../common/types/CdnSiteSummary"; -import { cloud } from "../../../../../../index"; +import { CdnSiteSummary } from "../../../../common/types/CdnSiteSummary"; export const ListGameCdnSitesResponse: core.serialization.ObjectSchema< serializers.cloud.games.ListGameCdnSitesResponse.Raw, Rivet.cloud.games.ListGameCdnSitesResponse > = core.serialization.object({ - sites: core.serialization.list(cloud_common$$cdnSiteSummary), + sites: core.serialization.list(CdnSiteSummary), }); export declare namespace ListGameCdnSitesResponse { interface Raw { - sites: cloud.CdnSiteSummary.Raw[]; + sites: CdnSiteSummary.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.ts index 2fcddb4e3c..edd1f85fed 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { LogStream as cloud_games_matchmaker$$logStream } from "./LogStream"; -import { cloud } from "../../../../../../index"; +import { LogStream } from "./LogStream"; export const ExportLobbyLogsRequest: core.serialization.ObjectSchema< serializers.cloud.games.ExportLobbyLogsRequest.Raw, Rivet.cloud.games.ExportLobbyLogsRequest > = core.serialization.object({ - stream: cloud_games_matchmaker$$logStream, + stream: LogStream, }); export declare namespace ExportLobbyLogsRequest { interface Raw { - stream: cloud.games.LogStream.Raw; + stream: LogStream.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.ts index 73d1b5d14d..46dc5e0e92 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { WatchResponse as common$$watchResponse } from "../../../../../../common/types/WatchResponse"; -import { common } from "../../../../../../index"; +import { WatchResponse } from "../../../../../../common/types/WatchResponse"; export const GetLobbyLogsResponse: core.serialization.ObjectSchema< serializers.cloud.games.GetLobbyLogsResponse.Raw, @@ -14,13 +13,13 @@ export const GetLobbyLogsResponse: core.serialization.ObjectSchema< > = core.serialization.object({ lines: core.serialization.list(core.serialization.string()), timestamps: core.serialization.list(core.serialization.string()), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetLobbyLogsResponse { interface Raw { lines: string[]; timestamps: string[]; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.ts index 01804ee2d2..80e54f1fc1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LobbySummaryAnalytics as cloud_common$$lobbySummaryAnalytics } from "../../../../../../common/types/LobbySummaryAnalytics"; -import { cloud } from "../../../../../../../../index"; +import { LobbySummaryAnalytics } from "../../../../../../common/types/LobbySummaryAnalytics"; export const GetAnalyticsMatchmakerLiveResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.GetAnalyticsMatchmakerLiveResponse.Raw, Rivet.cloud.games.namespaces.GetAnalyticsMatchmakerLiveResponse > = core.serialization.object({ - lobbies: core.serialization.list(cloud_common$$lobbySummaryAnalytics), + lobbies: core.serialization.list(LobbySummaryAnalytics), }); export declare namespace GetAnalyticsMatchmakerLiveResponse { interface Raw { - lobbies: cloud.LobbySummaryAnalytics.Raw[]; + lobbies: LobbySummaryAnalytics.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.ts index 84d77b2dd9..50d4ef38eb 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.ts @@ -5,17 +5,16 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LogsLobbySummary as cloud_common$$logsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; -import { SvcMetrics as cloud_common$$svcMetrics } from "../../../../../../common/types/SvcMetrics"; -import { SvcPerf as cloud_common$$svcPerf } from "../../../../../../common/types/SvcPerf"; -import { cloud } from "../../../../../../../../index"; +import { LogsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; +import { SvcMetrics } from "../../../../../../common/types/SvcMetrics"; +import { SvcPerf } from "../../../../../../common/types/SvcPerf"; export const GetNamespaceLobbyResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.GetNamespaceLobbyResponse.Raw, Rivet.cloud.games.namespaces.GetNamespaceLobbyResponse > = core.serialization.object({ - lobby: cloud_common$$logsLobbySummary, - metrics: cloud_common$$svcMetrics.optional(), + lobby: LogsLobbySummary, + metrics: SvcMetrics.optional(), stdoutPresignedUrls: core.serialization.property( "stdout_presigned_urls", core.serialization.list(core.serialization.string()) @@ -24,15 +23,15 @@ export const GetNamespaceLobbyResponse: core.serialization.ObjectSchema< "stderr_presigned_urls", core.serialization.list(core.serialization.string()) ), - perfLists: core.serialization.property("perf_lists", core.serialization.list(cloud_common$$svcPerf)), + perfLists: core.serialization.property("perf_lists", core.serialization.list(SvcPerf)), }); export declare namespace GetNamespaceLobbyResponse { interface Raw { - lobby: cloud.LogsLobbySummary.Raw; - metrics?: cloud.SvcMetrics.Raw | null; + lobby: LogsLobbySummary.Raw; + metrics?: SvcMetrics.Raw | null; stdout_presigned_urls: string[]; stderr_presigned_urls: string[]; - perf_lists: cloud.SvcPerf.Raw[]; + perf_lists: SvcPerf.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.ts index fc70c81b4a..951b4997fc 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LogsLobbySummary as cloud_common$$logsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; -import { cloud } from "../../../../../../../../index"; +import { LogsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; export const ListNamespaceLobbiesResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ListNamespaceLobbiesResponse.Raw, Rivet.cloud.games.namespaces.ListNamespaceLobbiesResponse > = core.serialization.object({ - lobbies: core.serialization.list(cloud_common$$logsLobbySummary), + lobbies: core.serialization.list(LogsLobbySummary), }); export declare namespace ListNamespaceLobbiesResponse { interface Raw { - lobbies: cloud.LogsLobbySummary.Raw[]; + lobbies: LogsLobbySummary.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.ts index 8932c16775..86bcb2269a 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export const CreateGameNamespaceRequest: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.CreateGameNamespaceRequest.Raw, Rivet.cloud.games.namespaces.CreateGameNamespaceRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), versionId: core.serialization.property("version_id", core.serialization.string()), nameId: core.serialization.property("name_id", core.serialization.string()), }); export declare namespace CreateGameNamespaceRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.ts index 3efe94e8b3..dae13b152a 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.ts @@ -5,26 +5,25 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { MatchmakerDevelopmentPort as cloud_common$$matchmakerDevelopmentPort } from "../../../../common/types/MatchmakerDevelopmentPort"; -import { LobbyGroupRuntimeDockerPort as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; -import { cloud } from "../../../../../../index"; +import { MatchmakerDevelopmentPort } from "../../../../common/types/MatchmakerDevelopmentPort"; +import { LobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; export const CreateGameNamespaceTokenDevelopmentRequest: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.CreateGameNamespaceTokenDevelopmentRequest.Raw, Rivet.cloud.games.namespaces.CreateGameNamespaceTokenDevelopmentRequest > = core.serialization.object({ hostname: core.serialization.string(), - ports: core.serialization.record(core.serialization.string(), cloud_common$$matchmakerDevelopmentPort).optional(), + ports: core.serialization.record(core.serialization.string(), MatchmakerDevelopmentPort).optional(), lobbyPorts: core.serialization.property( "lobby_ports", - core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort).optional() + core.serialization.list(LobbyGroupRuntimeDockerPort).optional() ), }); export declare namespace CreateGameNamespaceTokenDevelopmentRequest { interface Raw { hostname: string; - ports?: Record | null; - lobby_ports?: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[] | null; + ports?: Record | null; + lobby_ports?: LobbyGroupRuntimeDockerPort.Raw[] | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.ts index f37c769c11..1843cff8ba 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { NamespaceFull as cloud_common$$namespaceFull } from "../../../../common/types/NamespaceFull"; -import { cloud } from "../../../../../../index"; +import { NamespaceFull } from "../../../../common/types/NamespaceFull"; export const GetGameNamespaceByIdResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.GetGameNamespaceByIdResponse.Raw, Rivet.cloud.games.namespaces.GetGameNamespaceByIdResponse > = core.serialization.object({ - namespace: cloud_common$$namespaceFull, + namespace: NamespaceFull, }); export declare namespace GetGameNamespaceByIdResponse { interface Raw { - namespace: cloud.NamespaceFull.Raw; + namespace: NamespaceFull.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.ts index 3b3b1bd408..f61ccd3bb9 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { NamespaceVersion as cloud_common$$namespaceVersion } from "../../../../common/types/NamespaceVersion"; -import { cloud } from "../../../../../../index"; +import { NamespaceVersion } from "../../../../common/types/NamespaceVersion"; export const GetGameNamespaceVersionHistoryResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.GetGameNamespaceVersionHistoryResponse.Raw, Rivet.cloud.games.namespaces.GetGameNamespaceVersionHistoryResponse > = core.serialization.object({ - versions: core.serialization.list(cloud_common$$namespaceVersion), + versions: core.serialization.list(NamespaceVersion), }); export declare namespace GetGameNamespaceVersionHistoryResponse { interface Raw { - versions: cloud.NamespaceVersion.Raw[]; + versions: NamespaceVersion.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.ts index bdebb2d74c..530b7f1deb 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { AuthAgent as cloud_common$$authAgent } from "../../../../common/types/AuthAgent"; -import { cloud } from "../../../../../../index"; +import { AuthAgent } from "../../../../common/types/AuthAgent"; export const InspectResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.InspectResponse.Raw, Rivet.cloud.games.namespaces.InspectResponse > = core.serialization.object({ - agent: cloud_common$$authAgent, + agent: AuthAgent, }); export declare namespace InspectResponse { interface Raw { - agent: cloud.AuthAgent.Raw; + agent: AuthAgent.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.ts index 3aa3a68401..ec95ce49b8 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CdnAuthType as cloud_common$$cdnAuthType } from "../../../../common/types/CdnAuthType"; -import { cloud } from "../../../../../../index"; +import { CdnAuthType } from "../../../../common/types/CdnAuthType"; export const SetNamespaceCdnAuthTypeRequest: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.SetNamespaceCdnAuthTypeRequest.Raw, Rivet.cloud.games.namespaces.SetNamespaceCdnAuthTypeRequest > = core.serialization.object({ - authType: core.serialization.property("auth_type", cloud_common$$cdnAuthType), + authType: core.serialization.property("auth_type", CdnAuthType), }); export declare namespace SetNamespaceCdnAuthTypeRequest { interface Raw { - auth_type: cloud.CdnAuthType.Raw; + auth_type: CdnAuthType.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.ts index 59969b2ba3..2d7ac0d1fe 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../../../common/types/ValidationError"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export const ValidateGameNamespaceMatchmakerConfigResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ValidateGameNamespaceMatchmakerConfigResponse.Raw, Rivet.cloud.games.namespaces.ValidateGameNamespaceMatchmakerConfigResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGameNamespaceMatchmakerConfigResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.ts index 5d15ce85d1..c21c0802ac 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export const ValidateGameNamespaceRequest: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ValidateGameNamespaceRequest.Raw, Rivet.cloud.games.namespaces.ValidateGameNamespaceRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), nameId: core.serialization.property("name_id", core.serialization.string()), }); export declare namespace ValidateGameNamespaceRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; name_id: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.ts index ecccf3d022..7821bab230 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../../../common/types/ValidationError"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export const ValidateGameNamespaceResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ValidateGameNamespaceResponse.Raw, Rivet.cloud.games.namespaces.ValidateGameNamespaceResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGameNamespaceResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.ts index 575f36a7e7..4a78f4fd53 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.ts @@ -5,23 +5,19 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { LobbyGroupRuntimeDockerPort as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; -import { cloud } from "../../../../../../index"; +import { LobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; export const ValidateGameNamespaceTokenDevelopmentRequest: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ValidateGameNamespaceTokenDevelopmentRequest.Raw, Rivet.cloud.games.namespaces.ValidateGameNamespaceTokenDevelopmentRequest > = core.serialization.object({ hostname: core.serialization.string(), - lobbyPorts: core.serialization.property( - "lobby_ports", - core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort) - ), + lobbyPorts: core.serialization.property("lobby_ports", core.serialization.list(LobbyGroupRuntimeDockerPort)), }); export declare namespace ValidateGameNamespaceTokenDevelopmentRequest { interface Raw { hostname: string; - lobby_ports: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[]; + lobby_ports: LobbyGroupRuntimeDockerPort.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.ts index e3f8e85012..3d32304552 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../../../common/types/ValidationError"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export const ValidateGameNamespaceTokenDevelopmentResponse: core.serialization.ObjectSchema< serializers.cloud.games.namespaces.ValidateGameNamespaceTokenDevelopmentResponse.Raw, Rivet.cloud.games.namespaces.ValidateGameNamespaceTokenDevelopmentResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGameNamespaceTokenDevelopmentResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.ts index feea220db8..f69894a31a 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { Config as cloud_version$$config } from "../../../../version/types/Config"; -import { common, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { Config } from "../../../../version/types/Config"; export const CreateGameVersionRequest: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameVersionRequest.Raw, Rivet.cloud.games.CreateGameVersionRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), - config: cloud_version$$config, + displayName: core.serialization.property("display_name", DisplayName), + config: Config, }); export declare namespace CreateGameVersionRequest { interface Raw { - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.ts index e843065978..7510411e32 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Full as cloud_version$$full } from "../../../../version/types/Full"; -import { cloud } from "../../../../../../index"; +import { Full } from "../../../../version/types/Full"; export const GetGameVersionByIdResponse: core.serialization.ObjectSchema< serializers.cloud.games.GetGameVersionByIdResponse.Raw, Rivet.cloud.games.GetGameVersionByIdResponse > = core.serialization.object({ - version: cloud_version$$full, + version: Full, }); export declare namespace GetGameVersionByIdResponse { interface Raw { - version: cloud.version.Full.Raw; + version: Full.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.ts index 0d88756509..2544a3f7c1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export const ReserveVersionNameResponse: core.serialization.ObjectSchema< serializers.cloud.games.ReserveVersionNameResponse.Raw, Rivet.cloud.games.ReserveVersionNameResponse > = core.serialization.object({ - versionDisplayName: core.serialization.property("version_display_name", common$$displayName), + versionDisplayName: core.serialization.property("version_display_name", DisplayName), }); export declare namespace ReserveVersionNameResponse { interface Raw { - version_display_name: common.DisplayName.Raw; + version_display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.ts index e513167e1e..a5fa50d8f9 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { Config as cloud_version$$config } from "../../../../version/types/Config"; -import { common, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { Config } from "../../../../version/types/Config"; export const ValidateGameVersionRequest: core.serialization.ObjectSchema< serializers.cloud.games.ValidateGameVersionRequest.Raw, Rivet.cloud.games.ValidateGameVersionRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), - config: cloud_version$$config, + displayName: core.serialization.property("display_name", DisplayName), + config: Config, }); export declare namespace ValidateGameVersionRequest { interface Raw { - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.ts index 80fa437631..9c46948b38 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../../../common/types/ValidationError"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export const ValidateGameVersionResponse: core.serialization.ObjectSchema< serializers.cloud.games.ValidateGameVersionResponse.Raw, Rivet.cloud.games.ValidateGameVersionResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGameVersionResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/CreateGameRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/CreateGameRequest.ts index 0ad9e81aae..7c2690861e 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/CreateGameRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/CreateGameRequest.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const CreateGameRequest: core.serialization.ObjectSchema< serializers.cloud.games.CreateGameRequest.Raw, Rivet.cloud.games.CreateGameRequest > = core.serialization.object({ - nameId: core.serialization.property("name_id", common$$identifier.optional()), - displayName: core.serialization.property("display_name", common$$displayName), + nameId: core.serialization.property("name_id", Identifier.optional()), + displayName: core.serialization.property("display_name", DisplayName), developerGroupId: core.serialization.property("developer_group_id", core.serialization.string()), }); export declare namespace CreateGameRequest { interface Raw { - name_id?: common.Identifier.Raw | null; - display_name: common.DisplayName.Raw; + name_id?: Identifier.Raw | null; + display_name: DisplayName.Raw; developer_group_id: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.ts index 3b7bd7e2f5..5e4f42268a 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../../../index"; +import { PresignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; export const GameBannerUploadPrepareResponse: core.serialization.ObjectSchema< serializers.cloud.games.GameBannerUploadPrepareResponse.Raw, Rivet.cloud.games.GameBannerUploadPrepareResponse > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequest: core.serialization.property("presigned_request", upload_common$$presignedRequest), + presignedRequest: core.serialization.property("presigned_request", PresignedRequest), }); export declare namespace GameBannerUploadPrepareResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.ts index ff2db50dc4..5a0cbda777 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../../../index"; +import { PresignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; export const GameLogoUploadPrepareResponse: core.serialization.ObjectSchema< serializers.cloud.games.GameLogoUploadPrepareResponse.Raw, Rivet.cloud.games.GameLogoUploadPrepareResponse > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequest: core.serialization.property("presigned_request", upload_common$$presignedRequest), + presignedRequest: core.serialization.property("presigned_request", PresignedRequest), }); export declare namespace GameLogoUploadPrepareResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.ts index 3bf97cef30..6c408a06e1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { GameFull as cloud_common$$gameFull } from "../../common/types/GameFull"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { cloud, common } from "../../../../index"; +import { GameFull } from "../../common/types/GameFull"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const GetGameByIdResponse: core.serialization.ObjectSchema< serializers.cloud.games.GetGameByIdResponse.Raw, Rivet.cloud.games.GetGameByIdResponse > = core.serialization.object({ - game: cloud_common$$gameFull, - watch: common$$watchResponse, + game: GameFull, + watch: WatchResponse, }); export declare namespace GetGameByIdResponse { interface Raw { - game: cloud.GameFull.Raw; - watch: common.WatchResponse.Raw; + game: GameFull.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGamesResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGamesResponse.ts index 7d55c8d9fd..9413993d25 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGamesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/GetGamesResponse.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Summary as game_common$$summary } from "../../../../game/resources/common/types/Summary"; -import { Summary as group_common$$summary } from "../../../../group/resources/common/types/Summary"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { game, group, common } from "../../../../index"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { Summary } from "../../../../group/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const GetGamesResponse: core.serialization.ObjectSchema< serializers.cloud.games.GetGamesResponse.Raw, Rivet.cloud.games.GetGamesResponse > = core.serialization.object({ - games: core.serialization.list(game_common$$summary), - groups: core.serialization.list(group_common$$summary), - watch: common$$watchResponse, + games: core.serialization.list(Summary), + groups: core.serialization.list(Summary), + watch: WatchResponse, }); export declare namespace GetGamesResponse { interface Raw { - games: game.Summary.Raw[]; - groups: group.Summary.Raw[]; - watch: common.WatchResponse.Raw; + games: Summary.Raw[]; + groups: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameRequest.ts index 2dc5f3cf49..d34e6a8ee3 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameRequest.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Identifier } from "../../../../common/types/Identifier"; export const ValidateGameRequest: core.serialization.ObjectSchema< serializers.cloud.games.ValidateGameRequest.Raw, Rivet.cloud.games.ValidateGameRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), - nameId: core.serialization.property("name_id", common$$identifier.optional()), + displayName: core.serialization.property("display_name", DisplayName), + nameId: core.serialization.property("name_id", Identifier.optional()), }); export declare namespace ValidateGameRequest { interface Raw { - display_name: common.DisplayName.Raw; - name_id?: common.Identifier.Raw | null; + display_name: DisplayName.Raw; + name_id?: Identifier.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameResponse.ts index 69a21e6d7f..5ab9f5f908 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/games/types/ValidateGameResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../common/types/ValidationError"; -import { common } from "../../../../index"; +import { ValidationError } from "../../../../common/types/ValidationError"; export const ValidateGameResponse: core.serialization.ObjectSchema< serializers.cloud.games.ValidateGameResponse.Raw, Rivet.cloud.games.ValidateGameResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGameResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.ts index b3f8689f20..32d63b54e6 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const ValidateGroupRequest: core.serialization.ObjectSchema< serializers.cloud.ValidateGroupRequest.Raw, Rivet.cloud.ValidateGroupRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace ValidateGroupRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.ts index fa7ee561b4..21304434d7 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { ValidationError as common$$validationError } from "../../../../common/types/ValidationError"; -import { common } from "../../../../index"; +import { ValidationError } from "../../../../common/types/ValidationError"; export const ValidateGroupResponse: core.serialization.ObjectSchema< serializers.cloud.ValidateGroupResponse.Raw, Rivet.cloud.ValidateGroupResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateGroupResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.ts index 72ad15f697..a5ce7b5e6b 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { SvcPerf as cloud_common$$svcPerf } from "../../common/types/SvcPerf"; -import { cloud } from "../../../../index"; +import { SvcPerf } from "../../common/types/SvcPerf"; export const GetRayPerfLogsResponse: core.serialization.ObjectSchema< serializers.cloud.GetRayPerfLogsResponse.Raw, Rivet.cloud.GetRayPerfLogsResponse > = core.serialization.object({ - perfLists: core.serialization.property("perf_lists", core.serialization.list(cloud_common$$svcPerf)), + perfLists: core.serialization.property("perf_lists", core.serialization.list(SvcPerf)), }); export declare namespace GetRayPerfLogsResponse { interface Raw { - perf_lists: cloud.SvcPerf.Raw[]; + perf_lists: SvcPerf.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.ts index 0e780b3e44..5067f1bc8d 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { RegionTier as cloud_common$$regionTier } from "../../common/types/RegionTier"; -import { cloud } from "../../../../index"; +import { RegionTier } from "../../common/types/RegionTier"; export const GetRegionTiersResponse: core.serialization.ObjectSchema< serializers.cloud.GetRegionTiersResponse.Raw, Rivet.cloud.GetRegionTiersResponse > = core.serialization.object({ - tiers: core.serialization.list(cloud_common$$regionTier), + tiers: core.serialization.list(RegionTier), }); export declare namespace GetRegionTiersResponse { interface Raw { - tiers: cloud.RegionTier.Raw[]; + tiers: RegionTier.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Config.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Config.ts index b5f622b87a..800caccdb3 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Config.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Route as cloud_version_cdn$$route } from "./Route"; -import { cloud } from "../../../../../../index"; +import { Route } from "./Route"; export const Config: core.serialization.ObjectSchema< serializers.cloud.version.cdn.Config.Raw, @@ -19,7 +18,7 @@ export const Config: core.serialization.ObjectSchema< core.serialization.record(core.serialization.string(), core.serialization.string()).optional() ), siteId: core.serialization.property("site_id", core.serialization.string().optional()), - routes: core.serialization.list(cloud_version_cdn$$route).optional(), + routes: core.serialization.list(Route).optional(), }); export declare namespace Config { @@ -28,6 +27,6 @@ export declare namespace Config { build_output?: string | null; build_env?: Record | null; site_id?: string | null; - routes?: cloud.version.cdn.Route.Raw[] | null; + routes?: Route.Raw[] | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.ts index 7ac37a06c8..e7b6e01407 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Header as cloud_version_cdn$$header } from "./Header"; -import { cloud } from "../../../../../../index"; +import { Header } from "./Header"; export const CustomHeadersMiddleware: core.serialization.ObjectSchema< serializers.cloud.version.cdn.CustomHeadersMiddleware.Raw, Rivet.cloud.version.cdn.CustomHeadersMiddleware > = core.serialization.object({ - headers: core.serialization.list(cloud_version_cdn$$header), + headers: core.serialization.list(Header), }); export declare namespace CustomHeadersMiddleware { interface Raw { - headers: cloud.version.cdn.Header.Raw[]; + headers: Header.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.ts index d1f8a287ec..126d18a4b2 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { MiddlewareKind as cloud_version_cdn$$middlewareKind } from "./MiddlewareKind"; -import { cloud } from "../../../../../../index"; +import { MiddlewareKind } from "./MiddlewareKind"; export const Middleware: core.serialization.ObjectSchema< serializers.cloud.version.cdn.Middleware.Raw, Rivet.cloud.version.cdn.Middleware > = core.serialization.object({ - kind: cloud_version_cdn$$middlewareKind, + kind: MiddlewareKind, }); export declare namespace Middleware { interface Raw { - kind: cloud.version.cdn.MiddlewareKind.Raw; + kind: MiddlewareKind.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.ts index 38ea94630d..0488abaf6b 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CustomHeadersMiddleware as cloud_version_cdn$$customHeadersMiddleware } from "./CustomHeadersMiddleware"; -import { cloud } from "../../../../../../index"; +import { CustomHeadersMiddleware } from "./CustomHeadersMiddleware"; export const MiddlewareKind: core.serialization.ObjectSchema< serializers.cloud.version.cdn.MiddlewareKind.Raw, Rivet.cloud.version.cdn.MiddlewareKind > = core.serialization.object({ - customHeaders: core.serialization.property("custom_headers", cloud_version_cdn$$customHeadersMiddleware.optional()), + customHeaders: core.serialization.property("custom_headers", CustomHeadersMiddleware.optional()), }); export declare namespace MiddlewareKind { interface Raw { - custom_headers?: cloud.version.cdn.CustomHeadersMiddleware.Raw | null; + custom_headers?: CustomHeadersMiddleware.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Route.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Route.ts index 9e8af1721c..b6c1c4dca7 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Route.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/cdn/types/Route.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { Middleware as cloud_version_cdn$$middleware } from "./Middleware"; -import { cloud } from "../../../../../../index"; +import { Middleware } from "./Middleware"; export const Route: core.serialization.ObjectSchema< serializers.cloud.version.cdn.Route.Raw, @@ -14,13 +13,13 @@ export const Route: core.serialization.ObjectSchema< > = core.serialization.object({ glob: core.serialization.string(), priority: core.serialization.number(), - middlewares: core.serialization.list(cloud_version_cdn$$middleware), + middlewares: core.serialization.list(Middleware), }); export declare namespace Route { interface Raw { glob: string; priority: number; - middlewares: cloud.version.cdn.Middleware.Raw[]; + middlewares: Middleware.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/engine/types/Config.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/engine/types/Config.ts index da7b42bd46..e65d58deb6 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/engine/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/engine/types/Config.ts @@ -5,30 +5,29 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { UnityConfig as cloud_version_engine_unity$$unityConfig } from "../resources/unity/types/UnityConfig"; -import { UnrealConfig as cloud_version_engine_unreal$$unrealConfig } from "../resources/unreal/types/UnrealConfig"; -import { GodotConfig as cloud_version_engine_godot$$godotConfig } from "../resources/godot/types/GodotConfig"; -import { Html5Config as cloud_version_engine_html_5$$html5Config } from "../resources/html5/types/Html5Config"; -import { CustomConfig as cloud_version_engine_custom$$customConfig } from "../resources/custom/types/CustomConfig"; -import { cloud } from "../../../../../../index"; +import { UnityConfig } from "../resources/unity/types/UnityConfig"; +import { UnrealConfig } from "../resources/unreal/types/UnrealConfig"; +import { GodotConfig } from "../resources/godot/types/GodotConfig"; +import { Html5Config } from "../resources/html5/types/Html5Config"; +import { CustomConfig } from "../resources/custom/types/CustomConfig"; export const Config: core.serialization.ObjectSchema< serializers.cloud.version.engine.Config.Raw, Rivet.cloud.version.engine.Config > = core.serialization.object({ - unity: cloud_version_engine_unity$$unityConfig.optional(), - unreal: cloud_version_engine_unreal$$unrealConfig.optional(), - godot: cloud_version_engine_godot$$godotConfig.optional(), - html5: cloud_version_engine_html_5$$html5Config.optional(), - custom: cloud_version_engine_custom$$customConfig.optional(), + unity: UnityConfig.optional(), + unreal: UnrealConfig.optional(), + godot: GodotConfig.optional(), + html5: Html5Config.optional(), + custom: CustomConfig.optional(), }); export declare namespace Config { interface Raw { - unity?: cloud.version.engine.UnityConfig.Raw | null; - unreal?: cloud.version.engine.UnrealConfig.Raw | null; - godot?: cloud.version.engine.GodotConfig.Raw | null; - html5?: cloud.version.engine.Html5Config.Raw | null; - custom?: cloud.version.engine.CustomConfig.Raw | null; + unity?: UnityConfig.Raw | null; + unreal?: UnrealConfig.Raw | null; + godot?: GodotConfig.Raw | null; + html5?: Html5Config.Raw | null; + custom?: CustomConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/Config.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/Config.ts index 301fbe0391..a9b1be4db1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/Config.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { CustomDisplayName as cloud_version_identity$$customDisplayName } from "./CustomDisplayName"; -import { CustomAvatar as cloud_version_identity$$customAvatar } from "./CustomAvatar"; -import { cloud } from "../../../../../../index"; +import { CustomDisplayName } from "./CustomDisplayName"; +import { CustomAvatar } from "./CustomAvatar"; export const Config: core.serialization.ObjectSchema< serializers.cloud.version.identity.Config.Raw, @@ -20,19 +19,16 @@ export const Config: core.serialization.ObjectSchema< avatars: core.serialization.list(core.serialization.string()).optional(), customDisplayNames: core.serialization.property( "custom_display_names", - core.serialization.list(cloud_version_identity$$customDisplayName).optional() - ), - customAvatars: core.serialization.property( - "custom_avatars", - core.serialization.list(cloud_version_identity$$customAvatar).optional() + core.serialization.list(CustomDisplayName).optional() ), + customAvatars: core.serialization.property("custom_avatars", core.serialization.list(CustomAvatar).optional()), }); export declare namespace Config { interface Raw { display_names?: string[] | null; avatars?: string[] | null; - custom_display_names?: cloud.version.identity.CustomDisplayName.Raw[] | null; - custom_avatars?: cloud.version.identity.CustomAvatar.Raw[] | null; + custom_display_names?: CustomDisplayName.Raw[] | null; + custom_avatars?: CustomAvatar.Raw[] | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.ts index c499e7d67b..a3c48dd6b1 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../../../common/types/DisplayName"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export const CustomDisplayName: core.serialization.ObjectSchema< serializers.cloud.version.identity.CustomDisplayName.Raw, Rivet.cloud.version.identity.CustomDisplayName > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace CustomDisplayName { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.ts index 82f854d0fe..c95581fcb8 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { CaptchaHcaptcha as cloud_version_matchmaker_common$$captchaHcaptcha } from "./CaptchaHcaptcha"; -import { CaptchaTurnstile as cloud_version_matchmaker_common$$captchaTurnstile } from "./CaptchaTurnstile"; -import { cloud } from "../../../../../../../../index"; +import { CaptchaHcaptcha } from "./CaptchaHcaptcha"; +import { CaptchaTurnstile } from "./CaptchaTurnstile"; export const Captcha: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.Captcha.Raw, @@ -15,15 +14,15 @@ export const Captcha: core.serialization.ObjectSchema< > = core.serialization.object({ requestsBeforeReverify: core.serialization.property("requests_before_reverify", core.serialization.number()), verificationTtl: core.serialization.property("verification_ttl", core.serialization.number()), - hcaptcha: cloud_version_matchmaker_common$$captchaHcaptcha.optional(), - turnstile: cloud_version_matchmaker_common$$captchaTurnstile.optional(), + hcaptcha: CaptchaHcaptcha.optional(), + turnstile: CaptchaTurnstile.optional(), }); export declare namespace Captcha { interface Raw { requests_before_reverify: number; verification_ttl: number; - hcaptcha?: cloud.version.matchmaker.CaptchaHcaptcha.Raw | null; - turnstile?: cloud.version.matchmaker.CaptchaTurnstile.Raw | null; + hcaptcha?: CaptchaHcaptcha.Raw | null; + turnstile?: CaptchaTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.ts index 806255eb1a..1138e02cde 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { CaptchaHcaptchaLevel as cloud_version_matchmaker_common$$captchaHcaptchaLevel } from "./CaptchaHcaptchaLevel"; -import { cloud } from "../../../../../../../../index"; +import { CaptchaHcaptchaLevel } from "./CaptchaHcaptchaLevel"; export const CaptchaHcaptcha: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.CaptchaHcaptcha.Raw, Rivet.cloud.version.matchmaker.CaptchaHcaptcha > = core.serialization.object({ - level: cloud_version_matchmaker_common$$captchaHcaptchaLevel.optional(), + level: CaptchaHcaptchaLevel.optional(), siteKey: core.serialization.property("site_key", core.serialization.string().optional()), secretKey: core.serialization.property("secret_key", core.serialization.string().optional()), }); export declare namespace CaptchaHcaptcha { interface Raw { - level?: cloud.version.matchmaker.CaptchaHcaptchaLevel.Raw | null; + level?: CaptchaHcaptchaLevel.Raw | null; site_key?: string | null; secret_key?: string | null; } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.ts index 1639fdbfe3..e1d356a4c8 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.ts @@ -5,49 +5,43 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeRegion as cloud_version_matchmaker_game_mode$$gameModeRegion } from "./GameModeRegion"; -import { GameModeRuntimeDocker as cloud_version_matchmaker_game_mode$$gameModeRuntimeDocker } from "./GameModeRuntimeDocker"; -import { GameModeActions as cloud_version_matchmaker_game_mode$$gameModeActions } from "./GameModeActions"; -import { GameModeIdleLobbiesConfig as cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeRegion } from "./GameModeRegion"; +import { GameModeRuntimeDocker } from "./GameModeRuntimeDocker"; +import { GameModeActions } from "./GameModeActions"; +import { GameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; export const GameMode: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameMode.Raw, Rivet.cloud.version.matchmaker.GameMode > = core.serialization.object({ - regions: core.serialization - .record(core.serialization.string(), cloud_version_matchmaker_game_mode$$gameModeRegion) - .optional(), + regions: core.serialization.record(core.serialization.string(), GameModeRegion).optional(), maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), maxPlayersDirect: core.serialization.property("max_players_direct", core.serialization.number().optional()), maxPlayersParty: core.serialization.property("max_players_party", core.serialization.number().optional()), - docker: cloud_version_matchmaker_game_mode$$gameModeRuntimeDocker.optional(), + docker: GameModeRuntimeDocker.optional(), listable: core.serialization.boolean().optional(), taggable: core.serialization.boolean().optional(), allowDynamicMaxPlayers: core.serialization.property( "allow_dynamic_max_players", core.serialization.boolean().optional() ), - actions: cloud_version_matchmaker_game_mode$$gameModeActions.optional(), + actions: GameModeActions.optional(), tier: core.serialization.string().optional(), - idleLobbies: core.serialization.property( - "idle_lobbies", - cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig.optional() - ), + idleLobbies: core.serialization.property("idle_lobbies", GameModeIdleLobbiesConfig.optional()), }); export declare namespace GameMode { interface Raw { - regions?: Record | null; + regions?: Record | null; max_players?: number | null; max_players_direct?: number | null; max_players_party?: number | null; - docker?: cloud.version.matchmaker.GameModeRuntimeDocker.Raw | null; + docker?: GameModeRuntimeDocker.Raw | null; listable?: boolean | null; taggable?: boolean | null; allow_dynamic_max_players?: boolean | null; - actions?: cloud.version.matchmaker.GameModeActions.Raw | null; + actions?: GameModeActions.Raw | null; tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.ts index acea8ce8bf..f189a2873e 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeFindConfig as cloud_version_matchmaker_game_mode$$gameModeFindConfig } from "./GameModeFindConfig"; -import { GameModeJoinConfig as cloud_version_matchmaker_game_mode$$gameModeJoinConfig } from "./GameModeJoinConfig"; -import { GameModeCreateConfig as cloud_version_matchmaker_game_mode$$gameModeCreateConfig } from "./GameModeCreateConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeFindConfig } from "./GameModeFindConfig"; +import { GameModeJoinConfig } from "./GameModeJoinConfig"; +import { GameModeCreateConfig } from "./GameModeCreateConfig"; export const GameModeActions: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeActions.Raw, Rivet.cloud.version.matchmaker.GameModeActions > = core.serialization.object({ - find: cloud_version_matchmaker_game_mode$$gameModeFindConfig.optional(), - join: cloud_version_matchmaker_game_mode$$gameModeJoinConfig.optional(), - create: cloud_version_matchmaker_game_mode$$gameModeCreateConfig.optional(), + find: GameModeFindConfig.optional(), + join: GameModeJoinConfig.optional(), + create: GameModeCreateConfig.optional(), }); export declare namespace GameModeActions { interface Raw { - find?: cloud.version.matchmaker.GameModeFindConfig.Raw | null; - join?: cloud.version.matchmaker.GameModeJoinConfig.Raw | null; - create?: cloud.version.matchmaker.GameModeCreateConfig.Raw | null; + find?: GameModeFindConfig.Raw | null; + join?: GameModeJoinConfig.Raw | null; + create?: GameModeCreateConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.ts index 733ef0d382..1b95cfa6d0 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.ts @@ -5,20 +5,16 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeIdentityRequirement as cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement } from "./GameModeIdentityRequirement"; -import { GameModeVerificationConfig as cloud_version_matchmaker_game_mode$$gameModeVerificationConfig } from "./GameModeVerificationConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export const GameModeCreateConfig: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeCreateConfig.Raw, Rivet.cloud.version.matchmaker.GameModeCreateConfig > = core.serialization.object({ enabled: core.serialization.boolean(), - identityRequirement: core.serialization.property( - "identity_requirement", - cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement.optional() - ), - verification: cloud_version_matchmaker_game_mode$$gameModeVerificationConfig.optional(), + identityRequirement: core.serialization.property("identity_requirement", GameModeIdentityRequirement.optional()), + verification: GameModeVerificationConfig.optional(), enablePublic: core.serialization.property("enable_public", core.serialization.boolean().optional()), enablePrivate: core.serialization.property("enable_private", core.serialization.boolean().optional()), maxLobbiesPerIdentity: core.serialization.property( @@ -30,8 +26,8 @@ export const GameModeCreateConfig: core.serialization.ObjectSchema< export declare namespace GameModeCreateConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; enable_public?: boolean | null; enable_private?: boolean | null; max_lobbies_per_identity?: number | null; diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.ts index d2b86d5950..ed0ddd6112 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.ts @@ -5,26 +5,22 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeIdentityRequirement as cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement } from "./GameModeIdentityRequirement"; -import { GameModeVerificationConfig as cloud_version_matchmaker_game_mode$$gameModeVerificationConfig } from "./GameModeVerificationConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export const GameModeFindConfig: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeFindConfig.Raw, Rivet.cloud.version.matchmaker.GameModeFindConfig > = core.serialization.object({ enabled: core.serialization.boolean(), - identityRequirement: core.serialization.property( - "identity_requirement", - cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement.optional() - ), - verification: cloud_version_matchmaker_game_mode$$gameModeVerificationConfig.optional(), + identityRequirement: core.serialization.property("identity_requirement", GameModeIdentityRequirement.optional()), + verification: GameModeVerificationConfig.optional(), }); export declare namespace GameModeFindConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.ts index 6ac312324b..23980ee0bf 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.ts @@ -5,26 +5,22 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeIdentityRequirement as cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement } from "./GameModeIdentityRequirement"; -import { GameModeVerificationConfig as cloud_version_matchmaker_game_mode$$gameModeVerificationConfig } from "./GameModeVerificationConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export const GameModeJoinConfig: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeJoinConfig.Raw, Rivet.cloud.version.matchmaker.GameModeJoinConfig > = core.serialization.object({ enabled: core.serialization.boolean(), - identityRequirement: core.serialization.property( - "identity_requirement", - cloud_version_matchmaker_game_mode$$gameModeIdentityRequirement.optional() - ), - verification: cloud_version_matchmaker_game_mode$$gameModeVerificationConfig.optional(), + identityRequirement: core.serialization.property("identity_requirement", GameModeIdentityRequirement.optional()), + verification: GameModeVerificationConfig.optional(), }); export declare namespace GameModeJoinConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.ts index e7d6291acc..f7bf171258 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.ts @@ -5,23 +5,19 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { GameModeIdleLobbiesConfig as cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; export const GameModeRegion: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeRegion.Raw, Rivet.cloud.version.matchmaker.GameModeRegion > = core.serialization.object({ tier: core.serialization.string().optional(), - idleLobbies: core.serialization.property( - "idle_lobbies", - cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig.optional() - ), + idleLobbies: core.serialization.property("idle_lobbies", GameModeIdleLobbiesConfig.optional()), }); export declare namespace GameModeRegion { interface Raw { tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.ts index 15fc3ed80d..fc56f9ce50 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { NetworkMode as cloud_version_matchmaker_common$$networkMode } from "../../common/types/NetworkMode"; -import { GameModeRuntimeDockerPort as cloud_version_matchmaker_game_mode$$gameModeRuntimeDockerPort } from "./GameModeRuntimeDockerPort"; -import { cloud } from "../../../../../../../../index"; +import { NetworkMode } from "../../common/types/NetworkMode"; +import { GameModeRuntimeDockerPort } from "./GameModeRuntimeDockerPort"; export const GameModeRuntimeDocker: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeRuntimeDocker.Raw, @@ -22,10 +21,8 @@ export const GameModeRuntimeDocker: core.serialization.ObjectSchema< imageId: core.serialization.property("image_id", core.serialization.string().optional()), args: core.serialization.list(core.serialization.string()).optional(), env: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), - networkMode: core.serialization.property("network_mode", cloud_version_matchmaker_common$$networkMode.optional()), - ports: core.serialization - .record(core.serialization.string(), cloud_version_matchmaker_game_mode$$gameModeRuntimeDockerPort) - .optional(), + networkMode: core.serialization.property("network_mode", NetworkMode.optional()), + ports: core.serialization.record(core.serialization.string(), GameModeRuntimeDockerPort).optional(), }); export declare namespace GameModeRuntimeDocker { @@ -36,7 +33,7 @@ export declare namespace GameModeRuntimeDocker { image_id?: string | null; args?: string[] | null; env?: Record | null; - network_mode?: cloud.version.matchmaker.NetworkMode.Raw | null; - ports?: Record | null; + network_mode?: NetworkMode.Raw | null; + ports?: Record | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.ts index 4dd35a45df..73ee77fb4d 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.ts @@ -5,32 +5,31 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { PortRange as cloud_version_matchmaker_common$$portRange } from "../../common/types/PortRange"; -import { PortProtocol as cloud_version_matchmaker_common$$portProtocol } from "../../common/types/PortProtocol"; -import { ProxyKind as cloud_version_matchmaker_common$$proxyKind } from "../../common/types/ProxyKind"; -import { cloud } from "../../../../../../../../index"; +import { PortRange } from "../../common/types/PortRange"; +import { PortProtocol } from "../../common/types/PortProtocol"; +import { ProxyKind } from "../../common/types/ProxyKind"; export const GameModeRuntimeDockerPort: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.GameModeRuntimeDockerPort.Raw, Rivet.cloud.version.matchmaker.GameModeRuntimeDockerPort > = core.serialization.object({ port: core.serialization.number().optional(), - portRange: core.serialization.property("port_range", cloud_version_matchmaker_common$$portRange.optional()), - protocol: cloud_version_matchmaker_common$$portProtocol.optional(), - proxy: cloud_version_matchmaker_common$$proxyKind.optional(), + portRange: core.serialization.property("port_range", PortRange.optional()), + protocol: PortProtocol.optional(), + proxy: ProxyKind.optional(), devPort: core.serialization.property("dev_port", core.serialization.number().optional()), - devPortRange: core.serialization.property("dev_port_range", cloud_version_matchmaker_common$$portRange.optional()), - devProtocol: core.serialization.property("dev_protocol", cloud_version_matchmaker_common$$portProtocol.optional()), + devPortRange: core.serialization.property("dev_port_range", PortRange.optional()), + devProtocol: core.serialization.property("dev_protocol", PortProtocol.optional()), }); export declare namespace GameModeRuntimeDockerPort { interface Raw { port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - protocol?: cloud.version.matchmaker.PortProtocol.Raw | null; - proxy?: cloud.version.matchmaker.ProxyKind.Raw | null; + port_range?: PortRange.Raw | null; + protocol?: PortProtocol.Raw | null; + proxy?: ProxyKind.Raw | null; dev_port?: number | null; - dev_port_range?: cloud.version.matchmaker.PortRange.Raw | null; - dev_protocol?: cloud.version.matchmaker.PortProtocol.Raw | null; + dev_port_range?: PortRange.Raw | null; + dev_protocol?: PortProtocol.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.ts index db3fcfbafc..cd4ec8ed47 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.ts @@ -5,29 +5,28 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LobbyGroupRegion as cloud_version_matchmaker_lobby_group$$lobbyGroupRegion } from "./LobbyGroupRegion"; -import { LobbyGroupRuntime as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntime } from "./LobbyGroupRuntime"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRegion } from "./LobbyGroupRegion"; +import { LobbyGroupRuntime } from "./LobbyGroupRuntime"; export const LobbyGroup: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.LobbyGroup.Raw, Rivet.cloud.version.matchmaker.LobbyGroup > = core.serialization.object({ nameId: core.serialization.property("name_id", core.serialization.string()), - regions: core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroupRegion), + regions: core.serialization.list(LobbyGroupRegion), maxPlayersNormal: core.serialization.property("max_players_normal", core.serialization.number()), maxPlayersDirect: core.serialization.property("max_players_direct", core.serialization.number()), maxPlayersParty: core.serialization.property("max_players_party", core.serialization.number()), - runtime: cloud_version_matchmaker_lobby_group$$lobbyGroupRuntime, + runtime: LobbyGroupRuntime, }); export declare namespace LobbyGroup { interface Raw { name_id: string; - regions: cloud.version.matchmaker.LobbyGroupRegion.Raw[]; + regions: LobbyGroupRegion.Raw[]; max_players_normal: number; max_players_direct: number; max_players_party: number; - runtime: cloud.version.matchmaker.LobbyGroupRuntime.Raw; + runtime: LobbyGroupRuntime.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.ts index 031e50f3dc..9c87a5e205 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LobbyGroupIdleLobbiesConfig as cloud_version_matchmaker_lobby_group$$lobbyGroupIdleLobbiesConfig } from "./LobbyGroupIdleLobbiesConfig"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupIdleLobbiesConfig } from "./LobbyGroupIdleLobbiesConfig"; export const LobbyGroupRegion: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.LobbyGroupRegion.Raw, @@ -14,16 +13,13 @@ export const LobbyGroupRegion: core.serialization.ObjectSchema< > = core.serialization.object({ regionId: core.serialization.property("region_id", core.serialization.string()), tierNameId: core.serialization.property("tier_name_id", core.serialization.string()), - idleLobbies: core.serialization.property( - "idle_lobbies", - cloud_version_matchmaker_lobby_group$$lobbyGroupIdleLobbiesConfig.optional() - ), + idleLobbies: core.serialization.property("idle_lobbies", LobbyGroupIdleLobbiesConfig.optional()), }); export declare namespace LobbyGroupRegion { interface Raw { region_id: string; tier_name_id: string; - idle_lobbies?: cloud.version.matchmaker.LobbyGroupIdleLobbiesConfig.Raw | null; + idle_lobbies?: LobbyGroupIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.ts index bd0c9ce82d..3f9a167b92 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LobbyGroupRuntimeDocker as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDocker } from "./LobbyGroupRuntimeDocker"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRuntimeDocker } from "./LobbyGroupRuntimeDocker"; export const LobbyGroupRuntime: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.LobbyGroupRuntime.Raw, Rivet.cloud.version.matchmaker.LobbyGroupRuntime > = core.serialization.object({ - docker: cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDocker.optional(), + docker: LobbyGroupRuntimeDocker.optional(), }); export declare namespace LobbyGroupRuntime { interface Raw { - docker?: cloud.version.matchmaker.LobbyGroupRuntimeDocker.Raw | null; + docker?: LobbyGroupRuntimeDocker.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.ts index 9774364ede..3448308246 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.ts @@ -5,10 +5,9 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { LobbyGroupRuntimeDockerEnvVar as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerEnvVar } from "./LobbyGroupRuntimeDockerEnvVar"; -import { NetworkMode as cloud_version_matchmaker_common$$networkMode } from "../../common/types/NetworkMode"; -import { LobbyGroupRuntimeDockerPort as cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort } from "./LobbyGroupRuntimeDockerPort"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRuntimeDockerEnvVar } from "./LobbyGroupRuntimeDockerEnvVar"; +import { NetworkMode } from "../../common/types/NetworkMode"; +import { LobbyGroupRuntimeDockerPort } from "./LobbyGroupRuntimeDockerPort"; export const LobbyGroupRuntimeDocker: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.LobbyGroupRuntimeDocker.Raw, @@ -16,20 +15,17 @@ export const LobbyGroupRuntimeDocker: core.serialization.ObjectSchema< > = core.serialization.object({ buildId: core.serialization.property("build_id", core.serialization.string().optional()), args: core.serialization.list(core.serialization.string()), - envVars: core.serialization.property( - "env_vars", - core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerEnvVar) - ), - networkMode: core.serialization.property("network_mode", cloud_version_matchmaker_common$$networkMode.optional()), - ports: core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroupRuntimeDockerPort), + envVars: core.serialization.property("env_vars", core.serialization.list(LobbyGroupRuntimeDockerEnvVar)), + networkMode: core.serialization.property("network_mode", NetworkMode.optional()), + ports: core.serialization.list(LobbyGroupRuntimeDockerPort), }); export declare namespace LobbyGroupRuntimeDocker { interface Raw { build_id?: string | null; args: string[]; - env_vars: cloud.version.matchmaker.LobbyGroupRuntimeDockerEnvVar.Raw[]; - network_mode?: cloud.version.matchmaker.NetworkMode.Raw | null; - ports: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[]; + env_vars: LobbyGroupRuntimeDockerEnvVar.Raw[]; + network_mode?: NetworkMode.Raw | null; + ports: LobbyGroupRuntimeDockerPort.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.ts index c12b2314ed..d35efab367 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { PortRange as cloud_version_matchmaker_common$$portRange } from "../../common/types/PortRange"; -import { PortProtocol as cloud_version_matchmaker_common$$portProtocol } from "../../common/types/PortProtocol"; -import { cloud } from "../../../../../../../../index"; +import { PortRange } from "../../common/types/PortRange"; +import { PortProtocol } from "../../common/types/PortProtocol"; export const LobbyGroupRuntimeDockerPort: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw, @@ -15,15 +14,15 @@ export const LobbyGroupRuntimeDockerPort: core.serialization.ObjectSchema< > = core.serialization.object({ label: core.serialization.string(), targetPort: core.serialization.property("target_port", core.serialization.number().optional()), - portRange: core.serialization.property("port_range", cloud_version_matchmaker_common$$portRange.optional()), - proxyProtocol: core.serialization.property("proxy_protocol", cloud_version_matchmaker_common$$portProtocol), + portRange: core.serialization.property("port_range", PortRange.optional()), + proxyProtocol: core.serialization.property("proxy_protocol", PortProtocol), }); export declare namespace LobbyGroupRuntimeDockerPort { interface Raw { label: string; target_port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - proxy_protocol: cloud.version.matchmaker.PortProtocol.Raw; + port_range?: PortRange.Raw | null; + proxy_protocol: PortProtocol.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.ts index 07632347e0..c41603b3ff 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.ts @@ -5,13 +5,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { GameMode as cloud_version_matchmaker_game_mode$$gameMode } from "../resources/gameMode/types/GameMode"; -import { Captcha as cloud_version_matchmaker_common$$captcha } from "../resources/common/types/Captcha"; -import { GameModeRegion as cloud_version_matchmaker_game_mode$$gameModeRegion } from "../resources/gameMode/types/GameModeRegion"; -import { GameModeRuntimeDocker as cloud_version_matchmaker_game_mode$$gameModeRuntimeDocker } from "../resources/gameMode/types/GameModeRuntimeDocker"; -import { GameModeIdleLobbiesConfig as cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig } from "../resources/gameMode/types/GameModeIdleLobbiesConfig"; -import { LobbyGroup as cloud_version_matchmaker_lobby_group$$lobbyGroup } from "../resources/lobbyGroup/types/LobbyGroup"; -import { cloud } from "../../../../../../index"; +import { GameMode } from "../resources/gameMode/types/GameMode"; +import { Captcha } from "../resources/common/types/Captcha"; +import { GameModeRegion } from "../resources/gameMode/types/GameModeRegion"; +import { GameModeRuntimeDocker } from "../resources/gameMode/types/GameModeRuntimeDocker"; +import { GameModeIdleLobbiesConfig } from "../resources/gameMode/types/GameModeIdleLobbiesConfig"; +import { LobbyGroup } from "../resources/lobbyGroup/types/LobbyGroup"; export const Config: core.serialization.ObjectSchema< serializers.cloud.version.matchmaker.Config.Raw, @@ -19,40 +18,32 @@ export const Config: core.serialization.ObjectSchema< > = core.serialization.object({ gameModes: core.serialization.property( "game_modes", - core.serialization.record(core.serialization.string(), cloud_version_matchmaker_game_mode$$gameMode).optional() + core.serialization.record(core.serialization.string(), GameMode).optional() ), - captcha: cloud_version_matchmaker_common$$captcha.optional(), + captcha: Captcha.optional(), devHostname: core.serialization.property("dev_hostname", core.serialization.string().optional()), - regions: core.serialization - .record(core.serialization.string(), cloud_version_matchmaker_game_mode$$gameModeRegion) - .optional(), + regions: core.serialization.record(core.serialization.string(), GameModeRegion).optional(), maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), maxPlayersDirect: core.serialization.property("max_players_direct", core.serialization.number().optional()), maxPlayersParty: core.serialization.property("max_players_party", core.serialization.number().optional()), - docker: cloud_version_matchmaker_game_mode$$gameModeRuntimeDocker.optional(), + docker: GameModeRuntimeDocker.optional(), tier: core.serialization.string().optional(), - idleLobbies: core.serialization.property( - "idle_lobbies", - cloud_version_matchmaker_game_mode$$gameModeIdleLobbiesConfig.optional() - ), - lobbyGroups: core.serialization.property( - "lobby_groups", - core.serialization.list(cloud_version_matchmaker_lobby_group$$lobbyGroup).optional() - ), + idleLobbies: core.serialization.property("idle_lobbies", GameModeIdleLobbiesConfig.optional()), + lobbyGroups: core.serialization.property("lobby_groups", core.serialization.list(LobbyGroup).optional()), }); export declare namespace Config { interface Raw { - game_modes?: Record | null; - captcha?: cloud.version.matchmaker.Captcha.Raw | null; + game_modes?: Record | null; + captcha?: Captcha.Raw | null; dev_hostname?: string | null; - regions?: Record | null; + regions?: Record | null; max_players?: number | null; max_players_direct?: number | null; max_players_party?: number | null; - docker?: cloud.version.matchmaker.GameModeRuntimeDocker.Raw | null; + docker?: GameModeRuntimeDocker.Raw | null; tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; - lobby_groups?: cloud.version.matchmaker.LobbyGroup.Raw[] | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; + lobby_groups?: LobbyGroup.Raw[] | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Config.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Config.ts index 40930a8350..bee5ae2339 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Config.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Config.ts @@ -5,30 +5,29 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Config as cloud_version_engine$$config } from "../resources/engine/types/Config"; -import { Config as cloud_version_cdn$$config } from "../resources/cdn/types/Config"; -import { Config as cloud_version_matchmaker$$config } from "../resources/matchmaker/types/Config"; -import { Config as cloud_version_kv$$config } from "../resources/kv/types/Config"; -import { Config as cloud_version_identity$$config } from "../resources/identity/types/Config"; -import { cloud } from "../../../../index"; +import { Config } from "../resources/engine/types/Config"; +import { Config } from "../resources/cdn/types/Config"; +import { Config } from "../resources/matchmaker/types/Config"; +import { Config } from "../resources/kv/types/Config"; +import { Config } from "../resources/identity/types/Config"; export const Config: core.serialization.ObjectSchema = core.serialization.object({ scripts: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), - engine: cloud_version_engine$$config.optional(), - cdn: cloud_version_cdn$$config.optional(), - matchmaker: cloud_version_matchmaker$$config.optional(), - kv: cloud_version_kv$$config.optional(), - identity: cloud_version_identity$$config.optional(), + engine: Config.optional(), + cdn: Config.optional(), + matchmaker: Config.optional(), + kv: Config.optional(), + identity: Config.optional(), }); export declare namespace Config { interface Raw { scripts?: Record | null; - engine?: cloud.version.engine.Config.Raw | null; - cdn?: cloud.version.cdn.Config.Raw | null; - matchmaker?: cloud.version.matchmaker.Config.Raw | null; - kv?: cloud.version.kv.Config.Raw | null; - identity?: cloud.version.identity.Config.Raw | null; + engine?: Config.Raw | null; + cdn?: Config.Raw | null; + matchmaker?: Config.Raw | null; + kv?: Config.Raw | null; + identity?: Config.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Full.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Full.ts index dc9b7fce03..a182f4847b 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Full.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Full.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Config as cloud_version$$config } from "./Config"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Config } from "./Config"; export const Full: core.serialization.ObjectSchema = core.serialization.object({ versionId: core.serialization.property("version_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), - displayName: core.serialization.property("display_name", common$$displayName), - config: cloud_version$$config, + createTs: core.serialization.property("create_ts", Timestamp), + displayName: core.serialization.property("display_name", DisplayName), + config: Config, }); export declare namespace Full { interface Raw { version_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Summary.ts b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Summary.ts index ccfaba0fc9..2603115fe0 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Summary.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/resources/version/types/Summary.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const Summary: core.serialization.ObjectSchema< serializers.cloud.version.Summary.Raw, Rivet.cloud.version.Summary > = core.serialization.object({ versionId: core.serialization.property("version_id", core.serialization.string()), - createTs: core.serialization.property("create_ts", common$$timestamp), - displayName: core.serialization.property("display_name", common$$displayName), + createTs: core.serialization.property("create_ts", Timestamp), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace Summary { interface Raw { version_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapCaptcha.ts b/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapCaptcha.ts index 4fa3292482..a4ef591401 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapCaptcha.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapCaptcha.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { BootstrapCaptchaTurnstile as cloud$$bootstrapCaptchaTurnstile } from "./BootstrapCaptchaTurnstile"; -import { cloud } from "../../index"; +import { BootstrapCaptchaTurnstile } from "./BootstrapCaptchaTurnstile"; export const BootstrapCaptcha: core.serialization.ObjectSchema< serializers.cloud.BootstrapCaptcha.Raw, Rivet.cloud.BootstrapCaptcha > = core.serialization.object({ - turnstile: cloud$$bootstrapCaptchaTurnstile.optional(), + turnstile: BootstrapCaptchaTurnstile.optional(), }); export declare namespace BootstrapCaptcha { interface Raw { - turnstile?: cloud.BootstrapCaptchaTurnstile.Raw | null; + turnstile?: BootstrapCaptchaTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapResponse.ts b/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapResponse.ts index 5ba54c5f6b..fc7d876bea 100644 --- a/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/cloud/types/BootstrapResponse.ts @@ -5,35 +5,34 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { BootstrapCluster as cloud$$bootstrapCluster } from "./BootstrapCluster"; -import { BootstrapAccess as cloud$$bootstrapAccess } from "./BootstrapAccess"; -import { BootstrapDomains as cloud$$bootstrapDomains } from "./BootstrapDomains"; -import { BootstrapOrigins as cloud$$bootstrapOrigins } from "./BootstrapOrigins"; -import { BootstrapCaptcha as cloud$$bootstrapCaptcha } from "./BootstrapCaptcha"; -import { BootstrapLoginMethods as cloud$$bootstrapLoginMethods } from "./BootstrapLoginMethods"; -import { cloud } from "../../index"; +import { BootstrapCluster } from "./BootstrapCluster"; +import { BootstrapAccess } from "./BootstrapAccess"; +import { BootstrapDomains } from "./BootstrapDomains"; +import { BootstrapOrigins } from "./BootstrapOrigins"; +import { BootstrapCaptcha } from "./BootstrapCaptcha"; +import { BootstrapLoginMethods } from "./BootstrapLoginMethods"; export const BootstrapResponse: core.serialization.ObjectSchema< serializers.cloud.BootstrapResponse.Raw, Rivet.cloud.BootstrapResponse > = core.serialization.object({ - cluster: cloud$$bootstrapCluster, - access: cloud$$bootstrapAccess, - domains: cloud$$bootstrapDomains, - origins: cloud$$bootstrapOrigins, - captcha: cloud$$bootstrapCaptcha, - loginMethods: core.serialization.property("login_methods", cloud$$bootstrapLoginMethods), + cluster: BootstrapCluster, + access: BootstrapAccess, + domains: BootstrapDomains, + origins: BootstrapOrigins, + captcha: BootstrapCaptcha, + loginMethods: core.serialization.property("login_methods", BootstrapLoginMethods), deployHash: core.serialization.property("deploy_hash", core.serialization.string()), }); export declare namespace BootstrapResponse { interface Raw { - cluster: cloud.BootstrapCluster.Raw; - access: cloud.BootstrapAccess.Raw; - domains: cloud.BootstrapDomains.Raw; - origins: cloud.BootstrapOrigins.Raw; - captcha: cloud.BootstrapCaptcha.Raw; - login_methods: cloud.BootstrapLoginMethods.Raw; + cluster: BootstrapCluster.Raw; + access: BootstrapAccess.Raw; + domains: BootstrapDomains.Raw; + origins: BootstrapOrigins.Raw; + captcha: BootstrapCaptcha.Raw; + login_methods: BootstrapLoginMethods.Raw; deploy_hash: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/common/types/ErrorBody.ts b/sdks/full/typescript/src/serialization/resources/common/types/ErrorBody.ts index 6360c55333..8f81f08206 100644 --- a/sdks/full/typescript/src/serialization/resources/common/types/ErrorBody.ts +++ b/sdks/full/typescript/src/serialization/resources/common/types/ErrorBody.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { ErrorMetadata as common$$errorMetadata } from "./ErrorMetadata"; -import { common } from "../../index"; +import { ErrorMetadata } from "./ErrorMetadata"; export const ErrorBody: core.serialization.ObjectSchema = core.serialization.object({ @@ -14,7 +13,7 @@ export const ErrorBody: core.serialization.ObjectSchema = core.serialization.object({ gameId: core.serialization.property("game_id", core.serialization.string()), - nameId: core.serialization.property("name_id", common$$identifier), - displayName: core.serialization.property("display_name", common$$displayName), + nameId: core.serialization.property("name_id", Identifier), + displayName: core.serialization.property("display_name", DisplayName), logoUrl: core.serialization.property("logo_url", core.serialization.string().optional()), bannerUrl: core.serialization.property("banner_url", core.serialization.string().optional()), }); @@ -21,8 +20,8 @@ export const Handle: core.serialization.ObjectSchema = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace LeaderboardCategory { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/PlatformLink.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/PlatformLink.ts index 7e8c60744b..89802745db 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/PlatformLink.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/PlatformLink.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const PlatformLink: core.serialization.ObjectSchema = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), url: core.serialization.string(), }); export declare namespace PlatformLink { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; url: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Profile.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Profile.ts index 545d01f398..6335e4e315 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Profile.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Profile.ts @@ -5,35 +5,31 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Summary as group_common$$summary } from "../../../../group/resources/common/types/Summary"; -import { PlatformLink as game_common$$platformLink } from "./PlatformLink"; -import { LeaderboardCategory as game_common$$leaderboardCategory } from "./LeaderboardCategory"; -import { common, group, game } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Summary } from "../../../../group/resources/common/types/Summary"; +import { PlatformLink } from "./PlatformLink"; +import { LeaderboardCategory } from "./LeaderboardCategory"; export const Profile: core.serialization.ObjectSchema = core.serialization.object({ gameId: core.serialization.property("game_id", core.serialization.string()), nameId: core.serialization.property("name_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), logoUrl: core.serialization.property("logo_url", core.serialization.string().optional()), bannerUrl: core.serialization.property("banner_url", core.serialization.string().optional()), url: core.serialization.string(), - developer: group_common$$summary, + developer: Summary, tags: core.serialization.list(core.serialization.string()), description: core.serialization.string(), - platforms: core.serialization.list(game_common$$platformLink), - recommendedGroups: core.serialization.property( - "recommended_groups", - core.serialization.list(group_common$$summary) - ), + platforms: core.serialization.list(PlatformLink), + recommendedGroups: core.serialization.property("recommended_groups", core.serialization.list(Summary)), identityLeaderboardCategories: core.serialization.property( "identity_leaderboard_categories", - core.serialization.list(game_common$$leaderboardCategory) + core.serialization.list(LeaderboardCategory) ), groupLeaderboardCategories: core.serialization.property( "group_leaderboard_categories", - core.serialization.list(game_common$$leaderboardCategory) + core.serialization.list(LeaderboardCategory) ), }); @@ -41,16 +37,16 @@ export declare namespace Profile { interface Raw { game_id: string; name_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; logo_url?: string | null; banner_url?: string | null; url: string; - developer: group.Summary.Raw; + developer: Summary.Raw; tags: string[]; description: string; - platforms: game.PlatformLink.Raw[]; - recommended_groups: group.Summary.Raw[]; - identity_leaderboard_categories: game.LeaderboardCategory.Raw[]; - group_leaderboard_categories: game.LeaderboardCategory.Raw[]; + platforms: PlatformLink.Raw[]; + recommended_groups: Summary.Raw[]; + identity_leaderboard_categories: LeaderboardCategory.Raw[]; + group_leaderboard_categories: LeaderboardCategory.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Stat.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Stat.ts index 47944a448f..226dc554d0 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Stat.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Stat.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { StatConfig as game_common$$statConfig } from "./StatConfig"; -import { game } from "../../../../index"; +import { StatConfig } from "./StatConfig"; export const Stat: core.serialization.ObjectSchema = core.serialization.object({ - config: game_common$$statConfig, + config: StatConfig, overallValue: core.serialization.property("overall_value", core.serialization.number()), }); export declare namespace Stat { interface Raw { - config: game.StatConfig.Raw; + config: StatConfig.Raw; overall_value: number; } } diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatConfig.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatConfig.ts index d5acc6d6cb..81269f5d3d 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatConfig.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatConfig.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { StatFormatMethod as game_common$$statFormatMethod } from "./StatFormatMethod"; -import { StatAggregationMethod as game_common$$statAggregationMethod } from "./StatAggregationMethod"; -import { StatSortingMethod as game_common$$statSortingMethod } from "./StatSortingMethod"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { game, common } from "../../../../index"; +import { StatFormatMethod } from "./StatFormatMethod"; +import { StatAggregationMethod } from "./StatAggregationMethod"; +import { StatSortingMethod } from "./StatSortingMethod"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const StatConfig: core.serialization.ObjectSchema = core.serialization.object({ recordId: core.serialization.property("record_id", core.serialization.string()), iconId: core.serialization.property("icon_id", core.serialization.string()), - format: game_common$$statFormatMethod, - aggregation: game_common$$statAggregationMethod, - sorting: game_common$$statSortingMethod, + format: StatFormatMethod, + aggregation: StatAggregationMethod, + sorting: StatSortingMethod, priority: core.serialization.number(), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), postfixSingular: core.serialization.property("postfix_singular", core.serialization.string().optional()), postfixPlural: core.serialization.property("postfix_plural", core.serialization.string().optional()), prefixSingular: core.serialization.property("prefix_singular", core.serialization.string().optional()), @@ -30,11 +29,11 @@ export declare namespace StatConfig { interface Raw { record_id: string; icon_id: string; - format: game.StatFormatMethod.Raw; - aggregation: game.StatAggregationMethod.Raw; - sorting: game.StatSortingMethod.Raw; + format: StatFormatMethod.Raw; + aggregation: StatAggregationMethod.Raw; + sorting: StatSortingMethod.Raw; priority: number; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; postfix_singular?: string | null; postfix_plural?: string | null; prefix_singular?: string | null; diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatSummary.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatSummary.ts index ca643493a1..a61a7f40c0 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatSummary.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/StatSummary.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as game_common$$handle } from "./Handle"; -import { Stat as game_common$$stat } from "./Stat"; -import { game } from "../../../../index"; +import { Handle } from "./Handle"; +import { Stat } from "./Stat"; export const StatSummary: core.serialization.ObjectSchema = core.serialization.object({ - game: game_common$$handle, - stats: core.serialization.list(game_common$$stat), + game: Handle, + stats: core.serialization.list(Stat), }); export declare namespace StatSummary { interface Raw { - game: game.Handle.Raw; - stats: game.Stat.Raw[]; + game: Handle.Raw; + stats: Stat.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Summary.ts b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Summary.ts index 3f1d1ad3e1..9729fb2d02 100644 --- a/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Summary.ts +++ b/sdks/full/typescript/src/serialization/resources/game/resources/common/types/Summary.ts @@ -5,32 +5,31 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Handle as group_common$$handle } from "../../../../group/resources/common/types/Handle"; -import { common, group } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Handle } from "../../../../group/resources/common/types/Handle"; export const Summary: core.serialization.ObjectSchema = core.serialization.object({ gameId: core.serialization.property("game_id", core.serialization.string()), - nameId: core.serialization.property("name_id", common$$identifier), - displayName: core.serialization.property("display_name", common$$displayName), + nameId: core.serialization.property("name_id", Identifier), + displayName: core.serialization.property("display_name", DisplayName), logoUrl: core.serialization.property("logo_url", core.serialization.string().optional()), bannerUrl: core.serialization.property("banner_url", core.serialization.string().optional()), url: core.serialization.string(), - developer: group_common$$handle, + developer: Handle, totalPlayerCount: core.serialization.property("total_player_count", core.serialization.number()), }); export declare namespace Summary { interface Raw { game_id: string; - name_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; + name_id: Identifier.Raw; + display_name: DisplayName.Raw; logo_url?: string | null; banner_url?: string | null; url: string; - developer: group.Handle.Raw; + developer: Handle.Raw; total_player_count: number; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/BannedIdentity.ts b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/BannedIdentity.ts index e49237f9d6..089aac4abd 100644 --- a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/BannedIdentity.ts +++ b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/BannedIdentity.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as identity_common$$handle } from "../../../../identity/resources/common/types/Handle"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { identity, common } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const BannedIdentity: core.serialization.ObjectSchema< serializers.group.BannedIdentity.Raw, Rivet.group.BannedIdentity > = core.serialization.object({ - identity: identity_common$$handle, - banTs: core.serialization.property("ban_ts", common$$timestamp), + identity: Handle, + banTs: core.serialization.property("ban_ts", Timestamp), }); export declare namespace BannedIdentity { interface Raw { - identity: identity.Handle.Raw; - ban_ts: common.Timestamp.Raw; + identity: Handle.Raw; + ban_ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Handle.ts b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Handle.ts index 14e78f940a..222932c6cf 100644 --- a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Handle.ts +++ b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Handle.ts @@ -5,25 +5,24 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { ExternalLinks as group_common$$externalLinks } from "./ExternalLinks"; -import { common, group } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { ExternalLinks } from "./ExternalLinks"; export const Handle: core.serialization.ObjectSchema = core.serialization.object({ groupId: core.serialization.property("group_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), avatarUrl: core.serialization.property("avatar_url", core.serialization.string().optional()), - external: group_common$$externalLinks, + external: ExternalLinks, isDeveloper: core.serialization.property("is_developer", core.serialization.boolean().optional()), }); export declare namespace Handle { interface Raw { group_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; avatar_url?: string | null; - external: group.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_developer?: boolean | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/JoinRequest.ts b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/JoinRequest.ts index a49a22ac6e..59e6efae06 100644 --- a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/JoinRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/JoinRequest.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as identity_common$$handle } from "../../../../identity/resources/common/types/Handle"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { identity, common } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; +import { Timestamp } from "../../../../common/types/Timestamp"; export const JoinRequest: core.serialization.ObjectSchema = core.serialization.object({ - identity: identity_common$$handle, - ts: common$$timestamp, + identity: Handle, + ts: Timestamp, }); export declare namespace JoinRequest { interface Raw { - identity: identity.Handle.Raw; - ts: common.Timestamp.Raw; + identity: Handle.Raw; + ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Member.ts b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Member.ts index c2c68f9aa1..e0ef873442 100644 --- a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Member.ts +++ b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Member.ts @@ -5,16 +5,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as identity_common$$handle } from "../../../../identity/resources/common/types/Handle"; -import { identity } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; export const Member: core.serialization.ObjectSchema = core.serialization.object({ - identity: identity_common$$handle, + identity: Handle, }); export declare namespace Member { interface Raw { - identity: identity.Handle.Raw; + identity: Handle.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Profile.ts b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Profile.ts index 5fba945853..557cf7b11e 100644 --- a/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Profile.ts +++ b/sdks/full/typescript/src/serialization/resources/group/resources/common/types/Profile.ts @@ -5,29 +5,28 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { ExternalLinks as group_common$$externalLinks } from "./ExternalLinks"; -import { Publicity as group_common$$publicity } from "./Publicity"; -import { Member as group_common$$member } from "./Member"; -import { JoinRequest as group_common$$joinRequest } from "./JoinRequest"; -import { common, group } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { ExternalLinks } from "./ExternalLinks"; +import { Publicity } from "./Publicity"; +import { Member } from "./Member"; +import { JoinRequest } from "./JoinRequest"; export const Profile: core.serialization.ObjectSchema = core.serialization.object({ groupId: core.serialization.property("group_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), avatarUrl: core.serialization.property("avatar_url", core.serialization.string().optional()), - external: group_common$$externalLinks, + external: ExternalLinks, isDeveloper: core.serialization.property("is_developer", core.serialization.boolean().optional()), bio: core.serialization.string(), isCurrentIdentityMember: core.serialization.property( "is_current_identity_member", core.serialization.boolean().optional() ), - publicity: group_common$$publicity, + publicity: Publicity, memberCount: core.serialization.property("member_count", core.serialization.number().optional()), - members: core.serialization.list(group_common$$member), - joinRequests: core.serialization.property("join_requests", core.serialization.list(group_common$$joinRequest)), + members: core.serialization.list(Member), + joinRequests: core.serialization.property("join_requests", core.serialization.list(JoinRequest)), isCurrentIdentityRequestingJoin: core.serialization.property( "is_current_identity_requesting_join", core.serialization.boolean().optional() @@ -38,16 +37,16 @@ export const Profile: core.serialization.ObjectSchema = core.serialization.object({ groupId: core.serialization.property("group_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), avatarUrl: core.serialization.property("avatar_url", core.serialization.string().optional()), - external: group_common$$externalLinks, + external: ExternalLinks, isDeveloper: core.serialization.property("is_developer", core.serialization.boolean()), - bio: common$$bio, + bio: Bio, isCurrentIdentityMember: core.serialization.property( "is_current_identity_member", core.serialization.boolean() ), - publicity: group_common$$publicity, + publicity: Publicity, memberCount: core.serialization.property("member_count", core.serialization.number()), ownerIdentityId: core.serialization.property("owner_identity_id", core.serialization.string()), }); @@ -31,13 +30,13 @@ export const Summary: core.serialization.ObjectSchema = core.serialization.object({ - group: group_common$$handle, + group: Handle, }); export declare namespace GetInviteResponse { interface Raw { - group: group.Handle.Raw; + group: Handle.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/CreateRequest.ts b/sdks/full/typescript/src/serialization/resources/group/types/CreateRequest.ts index 1aaf3ec8a7..0d741f8390 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/CreateRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/CreateRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { DisplayName as common$$displayName } from "../../common/types/DisplayName"; -import { common } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; export const CreateRequest: core.serialization.ObjectSchema< serializers.group.CreateRequest.Raw, Rivet.group.CreateRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace CreateRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/GetBansResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/GetBansResponse.ts index 80fcd5f6e1..73a98e075b 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/GetBansResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/GetBansResponse.ts @@ -5,26 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { BannedIdentity as group_common$$bannedIdentity } from "../resources/common/types/BannedIdentity"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { group, common } from "../../index"; +import { BannedIdentity } from "../resources/common/types/BannedIdentity"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetBansResponse: core.serialization.ObjectSchema< serializers.group.GetBansResponse.Raw, Rivet.group.GetBansResponse > = core.serialization.object({ - bannedIdentities: core.serialization.property( - "banned_identities", - core.serialization.list(group_common$$bannedIdentity) - ), + bannedIdentities: core.serialization.property("banned_identities", core.serialization.list(BannedIdentity)), anchor: core.serialization.string().optional(), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetBansResponse { interface Raw { - banned_identities: group.BannedIdentity.Raw[]; + banned_identities: BannedIdentity.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/GetJoinRequestsResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/GetJoinRequestsResponse.ts index 587da8bf0d..f8e5924d97 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/GetJoinRequestsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/GetJoinRequestsResponse.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { JoinRequest as group_common$$joinRequest } from "../resources/common/types/JoinRequest"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { group, common } from "../../index"; +import { JoinRequest } from "../resources/common/types/JoinRequest"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetJoinRequestsResponse: core.serialization.ObjectSchema< serializers.group.GetJoinRequestsResponse.Raw, Rivet.group.GetJoinRequestsResponse > = core.serialization.object({ - joinRequests: core.serialization.property("join_requests", core.serialization.list(group_common$$joinRequest)), + joinRequests: core.serialization.property("join_requests", core.serialization.list(JoinRequest)), anchor: core.serialization.string().optional(), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetJoinRequestsResponse { interface Raw { - join_requests: group.JoinRequest.Raw[]; + join_requests: JoinRequest.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/GetMembersResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/GetMembersResponse.ts index 9d677bc399..5caef1b35e 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/GetMembersResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/GetMembersResponse.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Member as group_common$$member } from "../resources/common/types/Member"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { group, common } from "../../index"; +import { Member } from "../resources/common/types/Member"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetMembersResponse: core.serialization.ObjectSchema< serializers.group.GetMembersResponse.Raw, Rivet.group.GetMembersResponse > = core.serialization.object({ - members: core.serialization.list(group_common$$member), + members: core.serialization.list(Member), anchor: core.serialization.string().optional(), - watch: common$$watchResponse, + watch: WatchResponse, }); export declare namespace GetMembersResponse { interface Raw { - members: group.Member.Raw[]; + members: Member.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/GetProfileResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/GetProfileResponse.ts index ea26ff542c..6344c62324 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/GetProfileResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/GetProfileResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Profile as group_common$$profile } from "../resources/common/types/Profile"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { group, common } from "../../index"; +import { Profile } from "../resources/common/types/Profile"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetProfileResponse: core.serialization.ObjectSchema< serializers.group.GetProfileResponse.Raw, Rivet.group.GetProfileResponse > = core.serialization.object({ - group: group_common$$profile, - watch: common$$watchResponse, + group: Profile, + watch: WatchResponse, }); export declare namespace GetProfileResponse { interface Raw { - group: group.Profile.Raw; - watch: common.WatchResponse.Raw; + group: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/GetSummaryResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/GetSummaryResponse.ts index 525dce7925..03c68adb03 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/GetSummaryResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/GetSummaryResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Summary as group_common$$summary } from "../resources/common/types/Summary"; -import { group } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; export const GetSummaryResponse: core.serialization.ObjectSchema< serializers.group.GetSummaryResponse.Raw, Rivet.group.GetSummaryResponse > = core.serialization.object({ - group: group_common$$summary, + group: Summary, }); export declare namespace GetSummaryResponse { interface Raw { - group: group.Summary.Raw; + group: Summary.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/ListSuggestedResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/ListSuggestedResponse.ts index 74df3989b1..b65d038803 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/ListSuggestedResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/ListSuggestedResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Summary as group_common$$summary } from "../resources/common/types/Summary"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { group, common } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const ListSuggestedResponse: core.serialization.ObjectSchema< serializers.group.ListSuggestedResponse.Raw, Rivet.group.ListSuggestedResponse > = core.serialization.object({ - groups: core.serialization.list(group_common$$summary), - watch: common$$watchResponse, + groups: core.serialization.list(Summary), + watch: WatchResponse, }); export declare namespace ListSuggestedResponse { interface Raw { - groups: group.Summary.Raw[]; - watch: common.WatchResponse.Raw; + groups: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/PrepareAvatarUploadResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/PrepareAvatarUploadResponse.ts index 8b39c4f2c4..abe64d39a1 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/PrepareAvatarUploadResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/PrepareAvatarUploadResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../index"; +import { PresignedRequest } from "../../upload/resources/common/types/PresignedRequest"; export const PrepareAvatarUploadResponse: core.serialization.ObjectSchema< serializers.group.PrepareAvatarUploadResponse.Raw, Rivet.group.PrepareAvatarUploadResponse > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequest: core.serialization.property("presigned_request", upload_common$$presignedRequest), + presignedRequest: core.serialization.property("presigned_request", PresignedRequest), }); export declare namespace PrepareAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/UpdateProfileRequest.ts b/sdks/full/typescript/src/serialization/resources/group/types/UpdateProfileRequest.ts index c9c487d7be..e2d3658ca0 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/UpdateProfileRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/UpdateProfileRequest.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { DisplayName as common$$displayName } from "../../common/types/DisplayName"; -import { Publicity as group_common$$publicity } from "../resources/common/types/Publicity"; -import { common, group } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; +import { Publicity } from "../resources/common/types/Publicity"; export const UpdateProfileRequest: core.serialization.ObjectSchema< serializers.group.UpdateProfileRequest.Raw, Rivet.group.UpdateProfileRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName.optional()), + displayName: core.serialization.property("display_name", DisplayName.optional()), bio: core.serialization.string().optional(), - publicity: group_common$$publicity.optional(), + publicity: Publicity.optional(), }); export declare namespace UpdateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; + display_name?: DisplayName.Raw | null; bio?: string | null; - publicity?: group.Publicity.Raw | null; + publicity?: Publicity.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileRequest.ts b/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileRequest.ts index 4d1ccd112c..9e8a6b656b 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileRequest.ts @@ -5,23 +5,22 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { DisplayName as common$$displayName } from "../../common/types/DisplayName"; -import { Publicity as group_common$$publicity } from "../resources/common/types/Publicity"; -import { common, group } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; +import { Publicity } from "../resources/common/types/Publicity"; export const ValidateProfileRequest: core.serialization.ObjectSchema< serializers.group.ValidateProfileRequest.Raw, Rivet.group.ValidateProfileRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName.optional()), - bio: common$$displayName.optional(), - publicity: group_common$$publicity.optional(), + displayName: core.serialization.property("display_name", DisplayName.optional()), + bio: DisplayName.optional(), + publicity: Publicity.optional(), }); export declare namespace ValidateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - bio?: common.DisplayName.Raw | null; - publicity?: group.Publicity.Raw | null; + display_name?: DisplayName.Raw | null; + bio?: DisplayName.Raw | null; + publicity?: Publicity.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileResponse.ts b/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileResponse.ts index d6f12b640b..b781e5f5aa 100644 --- a/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/group/types/ValidateProfileResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { ValidationError as common$$validationError } from "../../common/types/ValidationError"; -import { common } from "../../index"; +import { ValidationError } from "../../common/types/ValidationError"; export const ValidateProfileResponse: core.serialization.ObjectSchema< serializers.group.ValidateProfileResponse.Raw, Rivet.group.ValidateProfileResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateProfileResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetGameActivityRequest.ts b/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetGameActivityRequest.ts index 46073b4079..9ee2fbf3b9 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetGameActivityRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetGameActivityRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { UpdateGameActivity as identity_common$$updateGameActivity } from "../../resources/common/types/UpdateGameActivity"; -import { identity } from "../../../index"; +import { UpdateGameActivity } from "../../resources/common/types/UpdateGameActivity"; export const SetGameActivityRequest: core.serialization.Schema< serializers.identity.SetGameActivityRequest.Raw, Rivet.identity.SetGameActivityRequest > = core.serialization.object({ - gameActivity: core.serialization.property("game_activity", identity_common$$updateGameActivity), + gameActivity: core.serialization.property("game_activity", UpdateGameActivity), }); export declare namespace SetGameActivityRequest { interface Raw { - game_activity: identity.UpdateGameActivity.Raw; + game_activity: UpdateGameActivity.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetupRequest.ts b/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetupRequest.ts index 02f89d984c..391e60d0de 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetupRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/client/requests/SetupRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { Jwt as common$$jwt } from "../../../common/types/Jwt"; -import { common } from "../../../index"; +import { Jwt } from "../../../common/types/Jwt"; export const SetupRequest: core.serialization.Schema< serializers.identity.SetupRequest.Raw, Rivet.identity.SetupRequest > = core.serialization.object({ - existingIdentityToken: core.serialization.property("existing_identity_token", common$$jwt.optional()), + existingIdentityToken: core.serialization.property("existing_identity_token", Jwt.optional()), }); export declare namespace SetupRequest { interface Raw { - existing_identity_token?: common.Jwt.Raw | null; + existing_identity_token?: Jwt.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateProfileRequest.ts b/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateProfileRequest.ts index dc0992e76b..d130133795 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateProfileRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateProfileRequest.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { DisplayName as common$$displayName } from "../../../common/types/DisplayName"; -import { AccountNumber as common$$accountNumber } from "../../../common/types/AccountNumber"; -import { Bio as common$$bio } from "../../../common/types/Bio"; -import { common } from "../../../index"; +import { DisplayName } from "../../../common/types/DisplayName"; +import { AccountNumber } from "../../../common/types/AccountNumber"; +import { Bio } from "../../../common/types/Bio"; export const UpdateProfileRequest: core.serialization.Schema< serializers.identity.UpdateProfileRequest.Raw, Rivet.identity.UpdateProfileRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName.optional()), - accountNumber: core.serialization.property("account_number", common$$accountNumber.optional()), - bio: common$$bio.optional(), + displayName: core.serialization.property("display_name", DisplayName.optional()), + accountNumber: core.serialization.property("account_number", AccountNumber.optional()), + bio: Bio.optional(), }); export declare namespace UpdateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - account_number?: common.AccountNumber.Raw | null; - bio?: common.Bio.Raw | null; + display_name?: DisplayName.Raw | null; + account_number?: AccountNumber.Raw | null; + bio?: Bio.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateStatusRequest.ts b/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateStatusRequest.ts index abf1289349..4273db2c55 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateStatusRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/client/requests/UpdateStatusRequest.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { Status as identity_common$$status } from "../../resources/common/types/Status"; -import { identity } from "../../../index"; +import { Status } from "../../resources/common/types/Status"; export const UpdateStatusRequest: core.serialization.Schema< serializers.identity.UpdateStatusRequest.Raw, Rivet.identity.UpdateStatusRequest > = core.serialization.object({ - status: identity_common$$status, + status: Status, }); export declare namespace UpdateStatusRequest { interface Raw { - status: identity.Status.Raw; + status: Status.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/client/requests/ValidateProfileRequest.ts b/sdks/full/typescript/src/serialization/resources/identity/client/requests/ValidateProfileRequest.ts index 972d2edf87..968adf33ed 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/client/requests/ValidateProfileRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/client/requests/ValidateProfileRequest.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { DisplayName as common$$displayName } from "../../../common/types/DisplayName"; -import { AccountNumber as common$$accountNumber } from "../../../common/types/AccountNumber"; -import { Bio as common$$bio } from "../../../common/types/Bio"; -import { common } from "../../../index"; +import { DisplayName } from "../../../common/types/DisplayName"; +import { AccountNumber } from "../../../common/types/AccountNumber"; +import { Bio } from "../../../common/types/Bio"; export const ValidateProfileRequest: core.serialization.Schema< serializers.identity.ValidateProfileRequest.Raw, Rivet.identity.ValidateProfileRequest > = core.serialization.object({ - displayName: core.serialization.property("display_name", common$$displayName.optional()), - accountNumber: core.serialization.property("account_number", common$$accountNumber.optional()), - bio: common$$bio.optional(), + displayName: core.serialization.property("display_name", DisplayName.optional()), + accountNumber: core.serialization.property("account_number", AccountNumber.optional()), + bio: Bio.optional(), }); export declare namespace ValidateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - account_number?: common.AccountNumber.Raw | null; - bio?: common.Bio.Raw | null; + display_name?: DisplayName.Raw | null; + account_number?: AccountNumber.Raw | null; + bio?: Bio.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.ts index a0ad9caa2e..a33652e31f 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.ts @@ -5,32 +5,28 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as identity_common$$handle } from "../../common/types/Handle"; -import { Summary as game_common$$summary } from "../../../../game/resources/common/types/Summary"; -import { Summary as group_common$$summary } from "../../../../group/resources/common/types/Summary"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { identity, game, group, common } from "../../../../index"; +import { Handle } from "../../common/types/Handle"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { Summary } from "../../../../group/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const ListActivitiesResponse: core.serialization.ObjectSchema< serializers.identity.ListActivitiesResponse.Raw, Rivet.identity.ListActivitiesResponse > = core.serialization.object({ - identities: core.serialization.list(identity_common$$handle), - games: core.serialization.list(game_common$$summary), - suggestedGroups: core.serialization.property("suggested_groups", core.serialization.list(group_common$$summary)), - suggestedPlayers: core.serialization.property( - "suggested_players", - core.serialization.list(identity_common$$handle) - ), - watch: common$$watchResponse, + identities: core.serialization.list(Handle), + games: core.serialization.list(Summary), + suggestedGroups: core.serialization.property("suggested_groups", core.serialization.list(Summary)), + suggestedPlayers: core.serialization.property("suggested_players", core.serialization.list(Handle)), + watch: WatchResponse, }); export declare namespace ListActivitiesResponse { interface Raw { - identities: identity.Handle.Raw[]; - games: game.Summary.Raw[]; - suggested_groups: group.Summary.Raw[]; - suggested_players: identity.Handle.Raw[]; - watch: common.WatchResponse.Raw; + identities: Handle.Raw[]; + games: Summary.Raw[]; + suggested_groups: Summary.Raw[]; + suggested_players: Handle.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/EmailLinkedAccount.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/EmailLinkedAccount.ts index 1d1c54f5a3..4992909688 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/EmailLinkedAccount.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/EmailLinkedAccount.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Email as common$$email } from "../../../../common/types/Email"; -import { common } from "../../../../index"; +import { Email } from "../../../../common/types/Email"; export const EmailLinkedAccount: core.serialization.ObjectSchema< serializers.identity.EmailLinkedAccount.Raw, Rivet.identity.EmailLinkedAccount > = core.serialization.object({ - email: common$$email, + email: Email, }); export declare namespace EmailLinkedAccount { interface Raw { - email: common.Email.Raw; + email: Email.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GameActivity.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GameActivity.ts index c5ccdcbaa4..eac9607b82 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GameActivity.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GameActivity.ts @@ -5,14 +5,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as game_common$$handle } from "../../../../game/resources/common/types/Handle"; -import { game } from "../../../../index"; +import { Handle } from "../../../../game/resources/common/types/Handle"; export const GameActivity: core.serialization.ObjectSchema< serializers.identity.GameActivity.Raw, Rivet.identity.GameActivity > = core.serialization.object({ - game: game_common$$handle, + game: Handle, message: core.serialization.string(), publicMetadata: core.serialization.property("public_metadata", core.serialization.unknown().optional()), mutualMetadata: core.serialization.property("mutual_metadata", core.serialization.unknown().optional()), @@ -20,7 +19,7 @@ export const GameActivity: core.serialization.ObjectSchema< export declare namespace GameActivity { interface Raw { - game: game.Handle.Raw; + game: Handle.Raw; message: string; public_metadata?: unknown | null; mutual_metadata?: unknown | null; diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEvent.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEvent.ts index 5bab96cc1e..746427c74b 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEvent.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEvent.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { GlobalEventKind as identity_common$$globalEventKind } from "./GlobalEventKind"; -import { GlobalEventNotification as identity_common$$globalEventNotification } from "./GlobalEventNotification"; -import { common, identity } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { GlobalEventKind } from "./GlobalEventKind"; +import { GlobalEventNotification } from "./GlobalEventNotification"; export const GlobalEvent: core.serialization.ObjectSchema< serializers.identity.GlobalEvent.Raw, Rivet.identity.GlobalEvent > = core.serialization.object({ - ts: common$$timestamp, - kind: identity_common$$globalEventKind, - notification: identity_common$$globalEventNotification.optional(), + ts: Timestamp, + kind: GlobalEventKind, + notification: GlobalEventNotification.optional(), }); export declare namespace GlobalEvent { interface Raw { - ts: common.Timestamp.Raw; - kind: identity.GlobalEventKind.Raw; - notification?: identity.GlobalEventNotification.Raw | null; + ts: Timestamp.Raw; + kind: GlobalEventKind.Raw; + notification?: GlobalEventNotification.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.ts index 46a43eea96..6820aa5461 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Profile as identity_common$$profile } from "./Profile"; -import { identity } from "../../../../index"; +import { Profile } from "./Profile"; export const GlobalEventIdentityUpdate: core.serialization.ObjectSchema< serializers.identity.GlobalEventIdentityUpdate.Raw, Rivet.identity.GlobalEventIdentityUpdate > = core.serialization.object({ - identity: identity_common$$profile, + identity: Profile, }); export declare namespace GlobalEventIdentityUpdate { interface Raw { - identity: identity.Profile.Raw; + identity: Profile.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventKind.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventKind.ts index a11078fd82..8e32f759de 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventKind.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/GlobalEventKind.ts @@ -5,21 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { GlobalEventIdentityUpdate as identity_common$$globalEventIdentityUpdate } from "./GlobalEventIdentityUpdate"; -import { identity } from "../../../../index"; +import { GlobalEventIdentityUpdate } from "./GlobalEventIdentityUpdate"; export const GlobalEventKind: core.serialization.ObjectSchema< serializers.identity.GlobalEventKind.Raw, Rivet.identity.GlobalEventKind > = core.serialization.object({ - identityUpdate: core.serialization.property( - "identity_update", - identity_common$$globalEventIdentityUpdate.optional() - ), + identityUpdate: core.serialization.property("identity_update", GlobalEventIdentityUpdate.optional()), }); export declare namespace GlobalEventKind { interface Raw { - identity_update?: identity.GlobalEventIdentityUpdate.Raw | null; + identity_update?: GlobalEventIdentityUpdate.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Group.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Group.ts index 073fc5f42f..a9861c17ef 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Group.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Group.ts @@ -5,16 +5,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Handle as group_common$$handle } from "../../../../group/resources/common/types/Handle"; -import { group } from "../../../../index"; +import { Handle } from "../../../../group/resources/common/types/Handle"; export const Group: core.serialization.ObjectSchema = core.serialization.object({ - group: group_common$$handle, + group: Handle, }); export declare namespace Group { interface Raw { - group: group.Handle.Raw; + group: Handle.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Handle.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Handle.ts index 9f7b50d68c..6eb96841a8 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Handle.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Handle.ts @@ -5,28 +5,27 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { AccountNumber as common$$accountNumber } from "../../../../common/types/AccountNumber"; -import { ExternalLinks as identity_common$$externalLinks } from "./ExternalLinks"; -import { common, identity } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; export const Handle: core.serialization.ObjectSchema = core.serialization.object({ identityId: core.serialization.property("identity_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - accountNumber: core.serialization.property("account_number", common$$accountNumber), + displayName: core.serialization.property("display_name", DisplayName), + accountNumber: core.serialization.property("account_number", AccountNumber), avatarUrl: core.serialization.property("avatar_url", core.serialization.string()), isRegistered: core.serialization.property("is_registered", core.serialization.boolean()), - external: identity_common$$externalLinks, + external: ExternalLinks, }); export declare namespace Handle { interface Raw { identity_id: string; - display_name: common.DisplayName.Raw; - account_number: common.AccountNumber.Raw; + display_name: DisplayName.Raw; + account_number: AccountNumber.Raw; avatar_url: string; is_registered: boolean; - external: identity.ExternalLinks.Raw; + external: ExternalLinks.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/LinkedAccount.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/LinkedAccount.ts index 0e1a56c79e..8aa7eb0348 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/LinkedAccount.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/LinkedAccount.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { EmailLinkedAccount as identity_common$$emailLinkedAccount } from "./EmailLinkedAccount"; -import { identity } from "../../../../index"; +import { EmailLinkedAccount } from "./EmailLinkedAccount"; export const LinkedAccount: core.serialization.ObjectSchema< serializers.identity.LinkedAccount.Raw, Rivet.identity.LinkedAccount > = core.serialization.object({ - email: identity_common$$emailLinkedAccount.optional(), + email: EmailLinkedAccount.optional(), defaultUser: core.serialization.property("default_user", core.serialization.boolean().optional()), }); export declare namespace LinkedAccount { interface Raw { - email?: identity.EmailLinkedAccount.Raw | null; + email?: EmailLinkedAccount.Raw | null; default_user?: boolean | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Profile.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Profile.ts index 198131e263..8eb80e4db0 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Profile.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Profile.ts @@ -5,65 +5,61 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { AccountNumber as common$$accountNumber } from "../../../../common/types/AccountNumber"; -import { ExternalLinks as identity_common$$externalLinks } from "./ExternalLinks"; -import { DevState as identity_common$$devState } from "./DevState"; -import { Timestamp as common$$timestamp } from "../../../../common/types/Timestamp"; -import { Bio as common$$bio } from "../../../../common/types/Bio"; -import { LinkedAccount as identity_common$$linkedAccount } from "./LinkedAccount"; -import { Group as identity_common$$group } from "./Group"; -import { StatSummary as game_common$$statSummary } from "../../../../game/resources/common/types/StatSummary"; -import { common, identity, game } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; +import { DevState } from "./DevState"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { Bio } from "../../../../common/types/Bio"; +import { LinkedAccount } from "./LinkedAccount"; +import { Group } from "./Group"; +import { StatSummary } from "../../../../game/resources/common/types/StatSummary"; export const Profile: core.serialization.ObjectSchema = core.serialization.object({ identityId: core.serialization.property("identity_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - accountNumber: core.serialization.property("account_number", common$$accountNumber), + displayName: core.serialization.property("display_name", DisplayName), + accountNumber: core.serialization.property("account_number", AccountNumber), avatarUrl: core.serialization.property("avatar_url", core.serialization.string()), isRegistered: core.serialization.property("is_registered", core.serialization.boolean()), - external: identity_common$$externalLinks, + external: ExternalLinks, isAdmin: core.serialization.property("is_admin", core.serialization.boolean()), isGameLinked: core.serialization.property("is_game_linked", core.serialization.boolean().optional()), - devState: core.serialization.property("dev_state", identity_common$$devState.optional()), + devState: core.serialization.property("dev_state", DevState.optional()), followerCount: core.serialization.property("follower_count", core.serialization.number()), followingCount: core.serialization.property("following_count", core.serialization.number()), following: core.serialization.boolean(), isFollowingMe: core.serialization.property("is_following_me", core.serialization.boolean()), isMutualFollowing: core.serialization.property("is_mutual_following", core.serialization.boolean()), - joinTs: core.serialization.property("join_ts", common$$timestamp), - bio: common$$bio, - linkedAccounts: core.serialization.property( - "linked_accounts", - core.serialization.list(identity_common$$linkedAccount) - ), - groups: core.serialization.list(identity_common$$group), - games: core.serialization.list(game_common$$statSummary), + joinTs: core.serialization.property("join_ts", Timestamp), + bio: Bio, + linkedAccounts: core.serialization.property("linked_accounts", core.serialization.list(LinkedAccount)), + groups: core.serialization.list(Group), + games: core.serialization.list(StatSummary), awaitingDeletion: core.serialization.property("awaiting_deletion", core.serialization.boolean().optional()), }); export declare namespace Profile { interface Raw { identity_id: string; - display_name: common.DisplayName.Raw; - account_number: common.AccountNumber.Raw; + display_name: DisplayName.Raw; + account_number: AccountNumber.Raw; avatar_url: string; is_registered: boolean; - external: identity.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_admin: boolean; is_game_linked?: boolean | null; - dev_state?: identity.DevState.Raw | null; + dev_state?: DevState.Raw | null; follower_count: number; following_count: number; following: boolean; is_following_me: boolean; is_mutual_following: boolean; - join_ts: common.Timestamp.Raw; - bio: common.Bio.Raw; - linked_accounts: identity.LinkedAccount.Raw[]; - groups: identity.Group.Raw[]; - games: game.StatSummary.Raw[]; + join_ts: Timestamp.Raw; + bio: Bio.Raw; + linked_accounts: LinkedAccount.Raw[]; + groups: Group.Raw[]; + games: StatSummary.Raw[]; awaiting_deletion?: boolean | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Summary.ts b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Summary.ts index 3bcc1b8537..89fee8a39e 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Summary.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/resources/common/types/Summary.ts @@ -5,19 +5,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { AccountNumber as common$$accountNumber } from "../../../../common/types/AccountNumber"; -import { ExternalLinks as identity_common$$externalLinks } from "./ExternalLinks"; -import { common, identity } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; export const Summary: core.serialization.ObjectSchema = core.serialization.object({ identityId: core.serialization.property("identity_id", core.serialization.string()), - displayName: core.serialization.property("display_name", common$$displayName), - accountNumber: core.serialization.property("account_number", common$$accountNumber), + displayName: core.serialization.property("display_name", DisplayName), + accountNumber: core.serialization.property("account_number", AccountNumber), avatarUrl: core.serialization.property("avatar_url", core.serialization.string()), isRegistered: core.serialization.property("is_registered", core.serialization.boolean()), - external: identity_common$$externalLinks, + external: ExternalLinks, following: core.serialization.boolean(), isFollowingMe: core.serialization.property("is_following_me", core.serialization.boolean()), isMutualFollowing: core.serialization.property("is_mutual_following", core.serialization.boolean()), @@ -26,11 +25,11 @@ export const Summary: core.serialization.ObjectSchema = core.serialization.object({ - events: core.serialization.list(identity_common$$globalEvent), - watch: common$$watchResponse, + events: core.serialization.list(GlobalEvent), + watch: WatchResponse, }); export declare namespace WatchEventsResponse { interface Raw { - events: identity.GlobalEvent.Raw[]; - watch: common.WatchResponse.Raw; + events: GlobalEvent.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/GetHandlesResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/GetHandlesResponse.ts index f39ca83128..628df55e1d 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/GetHandlesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/GetHandlesResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Handle as identity_common$$handle } from "../resources/common/types/Handle"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { identity, common } from "../../index"; +import { Handle } from "../resources/common/types/Handle"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetHandlesResponse: core.serialization.ObjectSchema< serializers.identity.GetHandlesResponse.Raw, Rivet.identity.GetHandlesResponse > = core.serialization.object({ - identities: core.serialization.list(identity_common$$handle), - watch: common$$watchResponse, + identities: core.serialization.list(Handle), + watch: WatchResponse, }); export declare namespace GetHandlesResponse { interface Raw { - identities: identity.Handle.Raw[]; - watch: common.WatchResponse.Raw; + identities: Handle.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/GetProfileResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/GetProfileResponse.ts index bfa98ce461..010d0aa5a1 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/GetProfileResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/GetProfileResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Profile as identity_common$$profile } from "../resources/common/types/Profile"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { identity, common } from "../../index"; +import { Profile } from "../resources/common/types/Profile"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetProfileResponse: core.serialization.ObjectSchema< serializers.identity.GetProfileResponse.Raw, Rivet.identity.GetProfileResponse > = core.serialization.object({ - identity: identity_common$$profile, - watch: common$$watchResponse, + identity: Profile, + watch: WatchResponse, }); export declare namespace GetProfileResponse { interface Raw { - identity: identity.Profile.Raw; - watch: common.WatchResponse.Raw; + identity: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/GetSummariesResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/GetSummariesResponse.ts index d8527eb5c1..a76c4e2f1a 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/GetSummariesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/GetSummariesResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Summary as identity_common$$summary } from "../resources/common/types/Summary"; -import { WatchResponse as common$$watchResponse } from "../../common/types/WatchResponse"; -import { identity, common } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; +import { WatchResponse } from "../../common/types/WatchResponse"; export const GetSummariesResponse: core.serialization.ObjectSchema< serializers.identity.GetSummariesResponse.Raw, Rivet.identity.GetSummariesResponse > = core.serialization.object({ - identities: core.serialization.list(identity_common$$summary), - watch: common$$watchResponse, + identities: core.serialization.list(Summary), + watch: WatchResponse, }); export declare namespace GetSummariesResponse { interface Raw { - identities: identity.Summary.Raw[]; - watch: common.WatchResponse.Raw; + identities: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/PrepareAvatarUploadResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/PrepareAvatarUploadResponse.ts index df575c4e47..d8e2fc34a8 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/PrepareAvatarUploadResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/PrepareAvatarUploadResponse.ts @@ -5,20 +5,19 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { PresignedRequest as upload_common$$presignedRequest } from "../../upload/resources/common/types/PresignedRequest"; -import { upload } from "../../index"; +import { PresignedRequest } from "../../upload/resources/common/types/PresignedRequest"; export const PrepareAvatarUploadResponse: core.serialization.ObjectSchema< serializers.identity.PrepareAvatarUploadResponse.Raw, Rivet.identity.PrepareAvatarUploadResponse > = core.serialization.object({ uploadId: core.serialization.property("upload_id", core.serialization.string()), - presignedRequest: core.serialization.property("presigned_request", upload_common$$presignedRequest), + presignedRequest: core.serialization.property("presigned_request", PresignedRequest), }); export declare namespace PrepareAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/SetupResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/SetupResponse.ts index 3e4fe35992..256afe9830 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/SetupResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/SetupResponse.ts @@ -5,26 +5,25 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { Jwt as common$$jwt } from "../../common/types/Jwt"; -import { Timestamp as common$$timestamp } from "../../common/types/Timestamp"; -import { Profile as identity_common$$profile } from "../resources/common/types/Profile"; -import { common, identity } from "../../index"; +import { Jwt } from "../../common/types/Jwt"; +import { Timestamp } from "../../common/types/Timestamp"; +import { Profile } from "../resources/common/types/Profile"; export const SetupResponse: core.serialization.ObjectSchema< serializers.identity.SetupResponse.Raw, Rivet.identity.SetupResponse > = core.serialization.object({ - identityToken: core.serialization.property("identity_token", common$$jwt), - identityTokenExpireTs: core.serialization.property("identity_token_expire_ts", common$$timestamp), - identity: identity_common$$profile, + identityToken: core.serialization.property("identity_token", Jwt), + identityTokenExpireTs: core.serialization.property("identity_token_expire_ts", Timestamp), + identity: Profile, gameId: core.serialization.property("game_id", core.serialization.string()), }); export declare namespace SetupResponse { interface Raw { - identity_token: common.Jwt.Raw; - identity_token_expire_ts: common.Timestamp.Raw; - identity: identity.Profile.Raw; + identity_token: Jwt.Raw; + identity_token_expire_ts: Timestamp.Raw; + identity: Profile.Raw; game_id: string; } } diff --git a/sdks/full/typescript/src/serialization/resources/identity/types/ValidateProfileResponse.ts b/sdks/full/typescript/src/serialization/resources/identity/types/ValidateProfileResponse.ts index 8f3ef6f0e5..61571c8e65 100644 --- a/sdks/full/typescript/src/serialization/resources/identity/types/ValidateProfileResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/identity/types/ValidateProfileResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { ValidationError as common$$validationError } from "../../common/types/ValidationError"; -import { common } from "../../index"; +import { ValidationError } from "../../common/types/ValidationError"; export const ValidateProfileResponse: core.serialization.ObjectSchema< serializers.identity.ValidateProfileResponse.Raw, Rivet.identity.ValidateProfileResponse > = core.serialization.object({ - errors: core.serialization.list(common$$validationError), + errors: core.serialization.list(ValidationError), }); export declare namespace ValidateProfileResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts index 893198efad..a8b8027fc4 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; export const GameModeInfo: core.serialization.ObjectSchema< serializers.matchmaker.GameModeInfo.Raw, Rivet.matchmaker.GameModeInfo > = core.serialization.object({ - gameModeId: core.serialization.property("game_mode_id", common$$identifier), + gameModeId: core.serialization.property("game_mode_id", Identifier), }); export declare namespace GameModeInfo { interface Raw { - game_mode_id: common.Identifier.Raw; + game_mode_id: Identifier.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts index 8d0fed2835..d57c0bcc5a 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts @@ -5,26 +5,25 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { JoinRegion as matchmaker_common$$joinRegion } from "./JoinRegion"; -import { JoinPort as matchmaker_common$$joinPort } from "./JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "./JoinPlayer"; -import { matchmaker } from "../../../../index"; +import { JoinRegion } from "./JoinRegion"; +import { JoinPort } from "./JoinPort"; +import { JoinPlayer } from "./JoinPlayer"; export const JoinLobby: core.serialization.ObjectSchema< serializers.matchmaker.JoinLobby.Raw, Rivet.matchmaker.JoinLobby > = core.serialization.object({ lobbyId: core.serialization.property("lobby_id", core.serialization.string()), - region: matchmaker_common$$joinRegion, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, + region: JoinRegion, + ports: core.serialization.record(core.serialization.string(), JoinPort), + player: JoinPlayer, }); export declare namespace JoinLobby { interface Raw { lobby_id: string; - region: matchmaker.JoinRegion.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + region: JoinRegion.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts index d2ceb3cd5a..cd402df7bc 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Jwt as common$$jwt } from "../../../../common/types/Jwt"; -import { common } from "../../../../index"; +import { Jwt } from "../../../../common/types/Jwt"; export const JoinPlayer: core.serialization.ObjectSchema< serializers.matchmaker.JoinPlayer.Raw, Rivet.matchmaker.JoinPlayer > = core.serialization.object({ - token: common$$jwt, + token: Jwt, }); export declare namespace JoinPlayer { interface Raw { - token: common.Jwt.Raw; + token: Jwt.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts index 397de3d732..0e77887971 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts @@ -5,15 +5,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { JoinPortRange as matchmaker_common$$joinPortRange } from "./JoinPortRange"; -import { matchmaker } from "../../../../index"; +import { JoinPortRange } from "./JoinPortRange"; export const JoinPort: core.serialization.ObjectSchema = core.serialization.object({ host: core.serialization.string().optional(), hostname: core.serialization.string(), port: core.serialization.number().optional(), - portRange: core.serialization.property("port_range", matchmaker_common$$joinPortRange.optional()), + portRange: core.serialization.property("port_range", JoinPortRange.optional()), isTls: core.serialization.property("is_tls", core.serialization.boolean()), }); @@ -22,7 +21,7 @@ export declare namespace JoinPort { host?: string | null; hostname: string; port?: number | null; - port_range?: matchmaker.JoinPortRange.Raw | null; + port_range?: JoinPortRange.Raw | null; is_tls: boolean; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts index 90fef0a73b..a0251ffc3b 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; export const JoinRegion: core.serialization.ObjectSchema< serializers.matchmaker.JoinRegion.Raw, Rivet.matchmaker.JoinRegion > = core.serialization.object({ - regionId: core.serialization.property("region_id", common$$identifier), - displayName: core.serialization.property("display_name", common$$displayName), + regionId: core.serialization.property("region_id", Identifier), + displayName: core.serialization.property("display_name", DisplayName), }); export declare namespace JoinRegion { interface Raw { - region_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; + region_id: Identifier.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts index 09cd474cea..e6c2398e90 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts @@ -5,29 +5,28 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Coord as geo_common$$coord } from "../../../../geo/resources/common/types/Coord"; -import { Distance as geo_common$$distance } from "../../../../geo/resources/common/types/Distance"; -import { common, geo } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Coord } from "../../../../geo/resources/common/types/Coord"; +import { Distance } from "../../../../geo/resources/common/types/Distance"; export const RegionInfo: core.serialization.ObjectSchema< serializers.matchmaker.RegionInfo.Raw, Rivet.matchmaker.RegionInfo > = core.serialization.object({ - regionId: core.serialization.property("region_id", common$$identifier), - providerDisplayName: core.serialization.property("provider_display_name", common$$displayName), - regionDisplayName: core.serialization.property("region_display_name", common$$displayName), - datacenterCoord: core.serialization.property("datacenter_coord", geo_common$$coord), - datacenterDistanceFromClient: core.serialization.property("datacenter_distance_from_client", geo_common$$distance), + regionId: core.serialization.property("region_id", Identifier), + providerDisplayName: core.serialization.property("provider_display_name", DisplayName), + regionDisplayName: core.serialization.property("region_display_name", DisplayName), + datacenterCoord: core.serialization.property("datacenter_coord", Coord), + datacenterDistanceFromClient: core.serialization.property("datacenter_distance_from_client", Distance), }); export declare namespace RegionInfo { interface Raw { - region_id: common.Identifier.Raw; - provider_display_name: common.DisplayName.Raw; - region_display_name: common.DisplayName.Raw; - datacenter_coord: geo.Coord.Raw; - datacenter_distance_from_client: geo.Distance.Raw; + region_id: Identifier.Raw; + provider_display_name: DisplayName.Raw; + region_display_name: DisplayName.Raw; + datacenter_coord: Coord.Raw; + datacenter_distance_from_client: Distance.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts index f18e1cbbcc..8b23636030 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts @@ -5,9 +5,8 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { CustomLobbyPublicity as matchmaker_common$$customLobbyPublicity } from "../../../common/types/CustomLobbyPublicity"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { matchmaker, captcha } from "../../../../../index"; +import { CustomLobbyPublicity } from "../../../common/types/CustomLobbyPublicity"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export const CreateLobbyRequest: core.serialization.Schema< serializers.matchmaker.CreateLobbyRequest.Raw, @@ -15,11 +14,11 @@ export const CreateLobbyRequest: core.serialization.Schema< > = core.serialization.object({ gameMode: core.serialization.property("game_mode", core.serialization.string()), region: core.serialization.string().optional(), - publicity: matchmaker_common$$customLobbyPublicity.optional(), + publicity: CustomLobbyPublicity.optional(), tags: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), lobbyConfig: core.serialization.property("lobby_config", core.serialization.unknown().optional()), - captcha: captcha_config$$config.optional(), + captcha: Config.optional(), verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), }); @@ -27,11 +26,11 @@ export declare namespace CreateLobbyRequest { interface Raw { game_mode: string; region?: string | null; - publicity?: matchmaker.CustomLobbyPublicity.Raw | null; + publicity?: CustomLobbyPublicity.Raw | null; tags?: Record | null; max_players?: number | null; lobby_config?: unknown | null; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts index 3a3c260e3b..b92a64c2da 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { captcha } from "../../../../../index"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export const FindLobbyRequest: core.serialization.Schema< serializers.matchmaker.FindLobbyRequest.Raw, @@ -20,7 +19,7 @@ export const FindLobbyRequest: core.serialization.Schema< ), tags: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), - captcha: captcha_config$$config.optional(), + captcha: Config.optional(), verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), }); @@ -31,7 +30,7 @@ export declare namespace FindLobbyRequest { prevent_auto_create_lobby?: boolean | null; tags?: Record | null; max_players?: number | null; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts index 511e171a4b..904b2df9bf 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts @@ -5,22 +5,21 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { captcha } from "../../../../../index"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export const JoinLobbyRequest: core.serialization.Schema< serializers.matchmaker.JoinLobbyRequest.Raw, Rivet.matchmaker.JoinLobbyRequest > = core.serialization.object({ lobbyId: core.serialization.property("lobby_id", core.serialization.string()), - captcha: captcha_config$$config.optional(), + captcha: Config.optional(), verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), }); export declare namespace JoinLobbyRequest { interface Raw { lobby_id: string; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts index b128c857ac..76e0bcca56 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export const CreateLobbyResponse: core.serialization.ObjectSchema< serializers.matchmaker.CreateLobbyResponse.Raw, Rivet.matchmaker.CreateLobbyResponse > = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, + lobby: JoinLobby, + ports: core.serialization.record(core.serialization.string(), JoinPort), + player: JoinPlayer, }); export declare namespace CreateLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts index 375882ae9c..c6938f82d8 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export const FindLobbyResponse: core.serialization.ObjectSchema< serializers.matchmaker.FindLobbyResponse.Raw, Rivet.matchmaker.FindLobbyResponse > = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, + lobby: JoinLobby, + ports: core.serialization.record(core.serialization.string(), JoinPort), + player: JoinPlayer, }); export declare namespace FindLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts index a721e3eb07..058978c8db 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export const JoinLobbyResponse: core.serialization.ObjectSchema< serializers.matchmaker.JoinLobbyResponse.Raw, Rivet.matchmaker.JoinLobbyResponse > = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, + lobby: JoinLobby, + ports: core.serialization.record(core.serialization.string(), JoinPort), + player: JoinPlayer, }); export declare namespace JoinLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts index 7b6eae5b12..43e6081278 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts @@ -5,24 +5,23 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { GameModeInfo as matchmaker_common$$gameModeInfo } from "../../common/types/GameModeInfo"; -import { RegionInfo as matchmaker_common$$regionInfo } from "../../common/types/RegionInfo"; -import { LobbyInfo as matchmaker_common$$lobbyInfo } from "../../common/types/LobbyInfo"; -import { matchmaker } from "../../../../index"; +import { GameModeInfo } from "../../common/types/GameModeInfo"; +import { RegionInfo } from "../../common/types/RegionInfo"; +import { LobbyInfo } from "../../common/types/LobbyInfo"; export const ListLobbiesResponse: core.serialization.ObjectSchema< serializers.matchmaker.ListLobbiesResponse.Raw, Rivet.matchmaker.ListLobbiesResponse > = core.serialization.object({ - gameModes: core.serialization.property("game_modes", core.serialization.list(matchmaker_common$$gameModeInfo)), - regions: core.serialization.list(matchmaker_common$$regionInfo), - lobbies: core.serialization.list(matchmaker_common$$lobbyInfo), + gameModes: core.serialization.property("game_modes", core.serialization.list(GameModeInfo)), + regions: core.serialization.list(RegionInfo), + lobbies: core.serialization.list(LobbyInfo), }); export declare namespace ListLobbiesResponse { interface Raw { - game_modes: matchmaker.GameModeInfo.Raw[]; - regions: matchmaker.RegionInfo.Raw[]; - lobbies: matchmaker.LobbyInfo.Raw[]; + game_modes: GameModeInfo.Raw[]; + regions: RegionInfo.Raw[]; + lobbies: LobbyInfo.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts index 8f2c6bddeb..bf9d4f2151 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { RegionStatistics as matchmaker_players$$regionStatistics } from "./RegionStatistics"; -import { common, matchmaker } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { RegionStatistics } from "./RegionStatistics"; export const GameModeStatistics: core.serialization.ObjectSchema< serializers.matchmaker.GameModeStatistics.Raw, Rivet.matchmaker.GameModeStatistics > = core.serialization.object({ playerCount: core.serialization.property("player_count", core.serialization.number()), - regions: core.serialization.record(common$$identifier, matchmaker_players$$regionStatistics), + regions: core.serialization.record(Identifier, RegionStatistics), }); export declare namespace GameModeStatistics { interface Raw { player_count: number; - regions: Record; + regions: Record; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts index 1cde117ac3..52803ab865 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts @@ -5,24 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { GameModeStatistics as matchmaker_players$$gameModeStatistics } from "./GameModeStatistics"; -import { common, matchmaker } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { GameModeStatistics } from "./GameModeStatistics"; export const GetStatisticsResponse: core.serialization.ObjectSchema< serializers.matchmaker.GetStatisticsResponse.Raw, Rivet.matchmaker.GetStatisticsResponse > = core.serialization.object({ playerCount: core.serialization.property("player_count", core.serialization.number()), - gameModes: core.serialization.property( - "game_modes", - core.serialization.record(common$$identifier, matchmaker_players$$gameModeStatistics) - ), + gameModes: core.serialization.property("game_modes", core.serialization.record(Identifier, GameModeStatistics)), }); export declare namespace GetStatisticsResponse { interface Raw { player_count: number; - game_modes: Record; + game_modes: Record; } } diff --git a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts index 52b47b98d7..28c25528e8 100644 --- a/sdks/full/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { RegionInfo as matchmaker_common$$regionInfo } from "../../common/types/RegionInfo"; -import { matchmaker } from "../../../../index"; +import { RegionInfo } from "../../common/types/RegionInfo"; export const ListRegionsResponse: core.serialization.ObjectSchema< serializers.matchmaker.ListRegionsResponse.Raw, Rivet.matchmaker.ListRegionsResponse > = core.serialization.object({ - regions: core.serialization.list(matchmaker_common$$regionInfo), + regions: core.serialization.list(RegionInfo), }); export declare namespace ListRegionsResponse { interface Raw { - regions: matchmaker.RegionInfo.Raw[]; + regions: RegionInfo.Raw[]; } } diff --git a/sdks/full/typescript/src/serialization/resources/portal/resources/common/types/NotificationRegisterService.ts b/sdks/full/typescript/src/serialization/resources/portal/resources/common/types/NotificationRegisterService.ts index e55ea6e11b..09a940d843 100644 --- a/sdks/full/typescript/src/serialization/resources/portal/resources/common/types/NotificationRegisterService.ts +++ b/sdks/full/typescript/src/serialization/resources/portal/resources/common/types/NotificationRegisterService.ts @@ -5,18 +5,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { NotificationRegisterFirebaseService as portal_common$$notificationRegisterFirebaseService } from "./NotificationRegisterFirebaseService"; -import { portal } from "../../../../index"; +import { NotificationRegisterFirebaseService } from "./NotificationRegisterFirebaseService"; export const NotificationRegisterService: core.serialization.ObjectSchema< serializers.portal.NotificationRegisterService.Raw, Rivet.portal.NotificationRegisterService > = core.serialization.object({ - firebase: portal_common$$notificationRegisterFirebaseService.optional(), + firebase: NotificationRegisterFirebaseService.optional(), }); export declare namespace NotificationRegisterService { interface Raw { - firebase?: portal.NotificationRegisterFirebaseService.Raw | null; + firebase?: NotificationRegisterFirebaseService.Raw | null; } } diff --git a/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetGameProfileResponse.ts b/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetGameProfileResponse.ts index 853db77c5f..3b065cbcf5 100644 --- a/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetGameProfileResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetGameProfileResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Profile as game_common$$profile } from "../../../../game/resources/common/types/Profile"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { game, common } from "../../../../index"; +import { Profile } from "../../../../game/resources/common/types/Profile"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const GetGameProfileResponse: core.serialization.ObjectSchema< serializers.portal.GetGameProfileResponse.Raw, Rivet.portal.GetGameProfileResponse > = core.serialization.object({ - game: game_common$$profile, - watch: common$$watchResponse, + game: Profile, + watch: WatchResponse, }); export declare namespace GetGameProfileResponse { interface Raw { - game: game.Profile.Raw; - watch: common.WatchResponse.Raw; + game: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.ts b/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.ts index 6dae5dab4b..f4a0e8c448 100644 --- a/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.ts +++ b/sdks/full/typescript/src/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.ts @@ -5,21 +5,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { Summary as game_common$$summary } from "../../../../game/resources/common/types/Summary"; -import { WatchResponse as common$$watchResponse } from "../../../../common/types/WatchResponse"; -import { game, common } from "../../../../index"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export const GetSuggestedGamesResponse: core.serialization.ObjectSchema< serializers.portal.GetSuggestedGamesResponse.Raw, Rivet.portal.GetSuggestedGamesResponse > = core.serialization.object({ - games: core.serialization.list(game_common$$summary), - watch: common$$watchResponse, + games: core.serialization.list(Summary), + watch: WatchResponse, }); export declare namespace GetSuggestedGamesResponse { interface Raw { - games: game.Summary.Raw[]; - watch: common.WatchResponse.Raw; + games: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/api/resources/actor/client/Client.d.ts b/sdks/full/typescript/types/api/resources/actor/client/Client.d.ts index 0c00538069..76a85473d0 100644 --- a/sdks/full/typescript/types/api/resources/actor/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/actor/client/Client.d.ts @@ -99,7 +99,7 @@ export declare class Actor { * } * }, * network: { - * mode: Rivet.actor.NetworkMode.Bridge, + * mode: "bridge", * ports: {} * }, * resources: { diff --git a/sdks/full/typescript/types/api/resources/actor/resources/builds/client/Client.d.ts b/sdks/full/typescript/types/api/resources/actor/resources/builds/client/Client.d.ts index fb199c007e..a85ee34df4 100644 --- a/sdks/full/typescript/types/api/resources/actor/resources/builds/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/actor/resources/builds/client/Client.d.ts @@ -115,8 +115,8 @@ export declare class Builds { * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.actor.BuildKind.DockerImage, - * compression: Rivet.actor.BuildCompression.None, + * kind: "docker_image", + * compression: "none", * prewarmRegions: ["string"] * } * }) diff --git a/sdks/full/typescript/types/api/resources/actor/resources/common/types/PortRouting.d.ts b/sdks/full/typescript/types/api/resources/actor/resources/common/types/PortRouting.d.ts index 853bea27f1..649c2bdfad 100644 --- a/sdks/full/typescript/types/api/resources/actor/resources/common/types/PortRouting.d.ts +++ b/sdks/full/typescript/types/api/resources/actor/resources/common/types/PortRouting.d.ts @@ -3,6 +3,6 @@ */ import * as Rivet from "../../../../../index"; export interface PortRouting { - gameGuard?: Rivet.actor.GameGuardRouting; + guard?: Rivet.actor.GuardRouting; host?: Rivet.actor.HostRouting; } diff --git a/sdks/full/typescript/types/api/resources/actor/resources/common/types/index.d.ts b/sdks/full/typescript/types/api/resources/actor/resources/common/types/index.d.ts index 89bf5598f2..24ce1387ca 100644 --- a/sdks/full/typescript/types/api/resources/actor/resources/common/types/index.d.ts +++ b/sdks/full/typescript/types/api/resources/actor/resources/common/types/index.d.ts @@ -7,7 +7,7 @@ export * from "./NetworkMode"; export * from "./Port"; export * from "./PortProtocol"; export * from "./PortRouting"; -export * from "./GameGuardRouting"; +export * from "./GuardRouting"; export * from "./PortAuthorization"; export * from "./PortQueryAuthorization"; export * from "./HostRouting"; diff --git a/sdks/full/typescript/types/api/resources/actor/resources/logs/client/Client.d.ts b/sdks/full/typescript/types/api/resources/actor/resources/logs/client/Client.d.ts index 6b10a859c2..d15d10f3d6 100644 --- a/sdks/full/typescript/types/api/resources/actor/resources/logs/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/actor/resources/logs/client/Client.d.ts @@ -40,7 +40,7 @@ export declare class Logs { * await client.actor.logs.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { * project: "string", * environment: "string", - * stream: Rivet.actor.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * }) */ diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/builds/client/Client.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/builds/client/Client.d.ts index 39187f9cad..bef948b981 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/builds/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/builds/client/Client.d.ts @@ -63,8 +63,8 @@ export declare class Builds { * contentLength: 1000000 * }, * multipartUpload: true, - * kind: Rivet.cloud.games.BuildKind.DockerImage, - * compression: Rivet.cloud.games.BuildCompression.None + * kind: "docker_image", + * compression: "none" * }) */ createGameBuild(gameId: string, request: Rivet.cloud.games.CreateGameBuildRequest, requestOptions?: Builds.RequestOptions): Promise; diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/Client.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/Client.d.ts index 99d88cb6ef..2fdba23bb0 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/Client.d.ts @@ -78,7 +78,7 @@ export declare class Matchmaker { * * @example * await client.cloud.games.matchmaker.getLobbyLogs("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * stream: Rivet.cloud.games.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * }) */ @@ -100,7 +100,7 @@ export declare class Matchmaker { * * @example * await client.cloud.games.matchmaker.exportLobbyLogs("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * stream: Rivet.cloud.games.LogStream.StdOut + * stream: "std_out" * }) */ exportLobbyLogs(gameId: string, lobbyId: string, request: Rivet.cloud.games.ExportLobbyLogsRequest, requestOptions?: Matchmaker.RequestOptions): Promise; diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.d.ts index 2b8a8ab598..420c2b1af7 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/matchmaker/client/requests/GetLobbyLogsRequest.d.ts @@ -5,7 +5,7 @@ import * as Rivet from "../../../../../../../../index"; /** * @example * { - * stream: Rivet.cloud.games.LogStream.StdOut, + * stream: "std_out", * watchIndex: "string" * } */ diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/client/Client.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/client/Client.d.ts index 7e6680b219..8d0421f5f5 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/client/Client.d.ts @@ -143,7 +143,7 @@ export declare class Namespaces { * * @example * await client.cloud.games.namespaces.setNamespaceCdnAuthType("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * authType: Rivet.cloud.CdnAuthType.None + * authType: "none" * }) */ setNamespaceCdnAuthType(gameId: string, namespaceId: string, request: Rivet.cloud.games.namespaces.SetNamespaceCdnAuthTypeRequest, requestOptions?: Namespaces.RequestOptions): Promise; @@ -296,14 +296,14 @@ export declare class Namespaces { * "string": { * port: undefined, * portRange: undefined, - * protocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * protocol: "http" * } * }, * lobbyPorts: [{ * label: "string", * targetPort: undefined, * portRange: undefined, - * proxyProtocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * proxyProtocol: "http" * }] * }) */ @@ -330,7 +330,7 @@ export declare class Namespaces { * label: "string", * targetPort: undefined, * portRange: undefined, - * proxyProtocol: Rivet.cloud.version.matchmaker.PortProtocol.Http + * proxyProtocol: "http" * }] * }) */ diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.d.ts index d4b753b0f6..052b816013 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/Client.d.ts @@ -39,7 +39,7 @@ export declare class Logs { * * @example * await client.cloud.games.namespaces.logs.listNamespaceLobbies("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { - * beforeCreateTs: new Date("2024-01-15T09:30:00.000Z") + * beforeCreateTs: "2024-01-15T09:30:00Z" * }) */ listNamespaceLobbies(gameId: string, namespaceId: string, request?: Rivet.cloud.games.namespaces.ListNamespaceLobbiesRequest, requestOptions?: Logs.RequestOptions): Promise; diff --git a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.d.ts b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.d.ts index 4af45e476f..44cb468c9b 100644 --- a/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.d.ts +++ b/sdks/full/typescript/types/api/resources/cloud/resources/games/resources/namespaces/resources/logs/client/requests/ListNamespaceLobbiesRequest.d.ts @@ -5,7 +5,7 @@ import * as Rivet from "../../../../../../../../../../index"; /** * @example * { - * beforeCreateTs: new Date("2024-01-15T09:30:00.000Z") + * beforeCreateTs: "2024-01-15T09:30:00Z" * } */ export interface ListNamespaceLobbiesRequest { diff --git a/sdks/full/typescript/types/api/resources/group/client/Client.d.ts b/sdks/full/typescript/types/api/resources/group/client/Client.d.ts index 892e3de94f..c2cd4ba941 100644 --- a/sdks/full/typescript/types/api/resources/group/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/group/client/Client.d.ts @@ -101,7 +101,7 @@ export declare class Group { * await client.group.validateProfile({ * displayName: "string", * bio: "string", - * publicity: Rivet.group.Publicity.Open + * publicity: "open" * }) */ validateProfile(request: Rivet.group.ValidateProfileRequest, requestOptions?: Group.RequestOptions): Promise; @@ -298,7 +298,7 @@ export declare class Group { * await client.group.updateProfile("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { * displayName: "string", * bio: "string", - * publicity: Rivet.group.Publicity.Open + * publicity: "open" * }) */ updateProfile(groupId: string, request: Rivet.group.UpdateProfileRequest, requestOptions?: Group.RequestOptions): Promise; diff --git a/sdks/full/typescript/types/api/resources/identity/client/Client.d.ts b/sdks/full/typescript/types/api/resources/identity/client/Client.d.ts index b86d925379..38dc195277 100644 --- a/sdks/full/typescript/types/api/resources/identity/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/identity/client/Client.d.ts @@ -226,7 +226,7 @@ export declare class Identity { * * @example * await client.identity.updateStatus({ - * status: Rivet.identity.Status.Online + * status: "online" * }) */ updateStatus(request: Rivet.identity.UpdateStatusRequest, requestOptions?: Identity.RequestOptions): Promise; diff --git a/sdks/full/typescript/types/api/resources/identity/client/requests/UpdateStatusRequest.d.ts b/sdks/full/typescript/types/api/resources/identity/client/requests/UpdateStatusRequest.d.ts index 3329eeabb2..0b79a238a0 100644 --- a/sdks/full/typescript/types/api/resources/identity/client/requests/UpdateStatusRequest.d.ts +++ b/sdks/full/typescript/types/api/resources/identity/client/requests/UpdateStatusRequest.d.ts @@ -5,7 +5,7 @@ import * as Rivet from "../../../../index"; /** * @example * { - * status: Rivet.identity.Status.Online + * status: "online" * } */ export interface UpdateStatusRequest { diff --git a/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/Client.d.ts b/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/Client.d.ts index 7cb187f5ad..fd1d2a45a2 100644 --- a/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/Client.d.ts +++ b/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/Client.d.ts @@ -218,7 +218,7 @@ export declare class Lobbies { * await client.matchmaker.lobbies.create({ * gameMode: "string", * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, + * publicity: "public", * tags: { * "string": "string" * }, diff --git a/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts b/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts index 7ee20734be..3eb9f15afc 100644 --- a/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts +++ b/sdks/full/typescript/types/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts @@ -7,7 +7,7 @@ import * as Rivet from "../../../../../../index"; * { * gameMode: "string", * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, + * publicity: "public", * tags: { * "string": "string" * }, diff --git a/sdks/full/typescript/types/core/fetcher/Fetcher.d.ts b/sdks/full/typescript/types/core/fetcher/Fetcher.d.ts index 801c336517..0afcdfafbe 100644 --- a/sdks/full/typescript/types/core/fetcher/Fetcher.d.ts +++ b/sdks/full/typescript/types/core/fetcher/Fetcher.d.ts @@ -13,7 +13,7 @@ export declare namespace Fetcher { withCredentials?: boolean; abortSignal?: AbortSignal; requestType?: "json" | "file" | "bytes"; - responseType?: "json" | "blob" | "sse" | "streaming" | "text"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; duplex?: "half"; } type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; diff --git a/sdks/full/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts b/sdks/full/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts index ed7dbfd818..0554b6a4cc 100644 --- a/sdks/full/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +++ b/sdks/full/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts @@ -1,24 +1,23 @@ -/// -import type { Writable } from "stream"; +import type { Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; -export declare class Node18UniversalStreamWrapper implements StreamWrapper, Uint8Array> { +export declare class Node18UniversalStreamWrapper implements StreamWrapper | Writable | WritableStream, ReadFormat> { private readableStream; private reader; private events; private paused; private resumeCallback; private encoding; - constructor(readableStream: ReadableStream); + constructor(readableStream: ReadableStream); on(event: string, callback: EventCallback): void; off(event: string, callback: EventCallback): void; - pipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; - pipeTo(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; - unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void; + pipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; + pipeTo(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; + unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void; destroy(error?: Error): void; pause(): void; resume(): void; get isPaused(): boolean; - read(): Promise; + read(): Promise; setEncoding(encoding: string): void; text(): Promise; json(): Promise; @@ -27,4 +26,5 @@ export declare class Node18UniversalStreamWrapper implements StreamWrapper; } diff --git a/sdks/full/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts b/sdks/full/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts index be718e3d4f..fb9858be9a 100644 --- a/sdks/full/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +++ b/sdks/full/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts @@ -1,5 +1,5 @@ /// -import type { Readable, Writable } from "stream"; +import type { Readable, Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export declare class NodePre18StreamWrapper implements StreamWrapper { private readableStream; @@ -18,4 +18,5 @@ export declare class NodePre18StreamWrapper implements StreamWrapper; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } diff --git a/sdks/full/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts b/sdks/full/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts index a6574aa91b..434b355783 100644 --- a/sdks/full/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +++ b/sdks/full/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts @@ -12,7 +12,7 @@ export declare class UndiciStreamWrapper | WritableStream): UndiciStreamWrapper | WritableStream; pipeTo(dest: UndiciStreamWrapper | WritableStream): UndiciStreamWrapper | WritableStream; - unpipe(dest: UndiciStreamWrapper | WritableStream): void; + unpipe(dest: UndiciStreamWrapper | WritableStream): void; destroy(error?: Error): void; pause(): void; resume(): void; @@ -26,5 +26,6 @@ export declare class UndiciStreamWrapper; } export {}; diff --git a/sdks/full/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts b/sdks/full/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts index ba7d363747..939c617d70 100644 --- a/sdks/full/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +++ b/sdks/full/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts @@ -13,5 +13,6 @@ export interface StreamWrapper { read(): Promise; text(): Promise; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } export declare function chooseStreamWrapper(responseBody: any): Promise>>; diff --git a/sdks/full/typescript/types/core/index.d.ts b/sdks/full/typescript/types/core/index.d.ts index f0a8603dec..2d20c46f3e 100644 --- a/sdks/full/typescript/types/core/index.d.ts +++ b/sdks/full/typescript/types/core/index.d.ts @@ -1,4 +1,4 @@ -export * from "./runtime"; export * from "./fetcher"; export * from "./auth"; +export * from "./runtime"; export * as serialization from "./schemas"; diff --git a/sdks/full/typescript/types/core/schemas/Schema.d.ts b/sdks/full/typescript/types/core/schemas/Schema.d.ts index 66fd54db3d..e58726b3fc 100644 --- a/sdks/full/typescript/types/core/schemas/Schema.d.ts +++ b/sdks/full/typescript/types/core/schemas/Schema.d.ts @@ -8,6 +8,7 @@ export interface BaseSchema { getType: () => SchemaType | SchemaType; } export declare const SchemaType: { + readonly BIGINT: "bigint"; readonly DATE: "date"; readonly ENUM: "enum"; readonly LIST: "list"; diff --git a/sdks/full/typescript/types/core/schemas/builders/index.d.ts b/sdks/full/typescript/types/core/schemas/builders/index.d.ts index 050cd2c4ef..65211f9252 100644 --- a/sdks/full/typescript/types/core/schemas/builders/index.d.ts +++ b/sdks/full/typescript/types/core/schemas/builders/index.d.ts @@ -1,3 +1,4 @@ +export * from "./bigint"; export * from "./date"; export * from "./enum"; export * from "./lazy"; diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/GetBuildResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/GetBuildResponse.d.ts index 6a723b2ce4..d1061e69a4 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/GetBuildResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/GetBuildResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { Build } from "../../common/types/Build"; export declare const GetBuildResponse: core.serialization.ObjectSchema; export declare namespace GetBuildResponse { interface Raw { - build: actor.Build.Raw; + build: Build.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/ListBuildsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/ListBuildsResponse.d.ts index 1e47061404..855bd1deab 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/ListBuildsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/builds/types/ListBuildsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { Build } from "../../common/types/Build"; export declare const ListBuildsResponse: core.serialization.ObjectSchema; export declare namespace ListBuildsResponse { interface Raw { - builds: actor.Build.Raw[]; + builds: Build.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Actor.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Actor.d.ts index bff3187b42..f9641b0f7c 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Actor.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Actor.d.ts @@ -4,17 +4,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { Runtime } from "./Runtime"; +import { Network } from "./Network"; +import { Resources } from "./Resources"; +import { Lifecycle } from "./Lifecycle"; export declare const Actor: core.serialization.ObjectSchema; export declare namespace Actor { interface Raw { id: string; region: string; tags?: unknown; - runtime: actor.Runtime.Raw; - network: actor.Network.Raw; - resources: actor.Resources.Raw; - lifecycle: actor.Lifecycle.Raw; + runtime: Runtime.Raw; + network: Network.Raw; + resources: Resources.Raw; + lifecycle: Lifecycle.Raw; created_at: number; started_at?: number | null; destroyed_at?: number | null; diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Build.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Build.d.ts index 431ed4f15b..c60c38e84b 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Build.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Build.d.ts @@ -4,13 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const Build: core.serialization.ObjectSchema; export declare namespace Build { interface Raw { id: string; name: string; - created_at: common.Timestamp.Raw; + created_at: Timestamp.Raw; content_length: number; tags: Record; } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Network.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Network.d.ts index 503ca6236a..1d8b7d16db 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Network.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Network.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { NetworkMode } from "./NetworkMode"; +import { Port } from "./Port"; export declare const Network: core.serialization.ObjectSchema; export declare namespace Network { interface Raw { - mode: actor.NetworkMode.Raw; - ports: Record; + mode: NetworkMode.Raw; + ports: Record; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Port.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Port.d.ts index 0c25fdef3d..6fa77dbc31 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Port.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/Port.d.ts @@ -4,14 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { PortProtocol } from "./PortProtocol"; +import { PortRouting } from "./PortRouting"; export declare const Port: core.serialization.ObjectSchema; export declare namespace Port { interface Raw { - protocol: actor.PortProtocol.Raw; + protocol: PortProtocol.Raw; internal_port?: number | null; public_hostname?: string | null; public_port?: number | null; - routing: actor.PortRouting.Raw; + routing: PortRouting.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/PortRouting.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/PortRouting.d.ts index bcad00c63c..564c220e1c 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/PortRouting.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/PortRouting.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { actor } from "../../../../index"; +import { GuardRouting } from "./GuardRouting"; +import { HostRouting } from "./HostRouting"; export declare const PortRouting: core.serialization.ObjectSchema; export declare namespace PortRouting { interface Raw { - game_guard?: actor.GameGuardRouting.Raw | null; - host?: actor.HostRouting.Raw | null; + guard?: GuardRouting.Raw | null; + host?: HostRouting.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/index.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/index.d.ts index 89bf5598f2..24ce1387ca 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/index.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/common/types/index.d.ts @@ -7,7 +7,7 @@ export * from "./NetworkMode"; export * from "./Port"; export * from "./PortProtocol"; export * from "./PortRouting"; -export * from "./GameGuardRouting"; +export * from "./GuardRouting"; export * from "./PortAuthorization"; export * from "./PortQueryAuthorization"; export * from "./HostRouting"; diff --git a/sdks/full/typescript/types/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.d.ts index 231d6d3fc5..469cc275a0 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/resources/logs/types/GetActorLogsResponse.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const GetActorLogsResponse: core.serialization.ObjectSchema; export declare namespace GetActorLogsResponse { interface Raw { lines: string[]; timestamps: string[]; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorNetworkRequest.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorNetworkRequest.d.ts index 792ce8fb2f..f8c0160e9e 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorNetworkRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorNetworkRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { NetworkMode } from "../resources/common/types/NetworkMode"; +import { CreateActorPortRequest } from "./CreateActorPortRequest"; export declare const CreateActorNetworkRequest: core.serialization.ObjectSchema; export declare namespace CreateActorNetworkRequest { interface Raw { - mode?: actor.NetworkMode.Raw | null; - ports?: Record | null; + mode?: NetworkMode.Raw | null; + ports?: Record | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorPortRequest.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorPortRequest.d.ts index 0aa41582e6..d13b705718 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorPortRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorPortRequest.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { PortProtocol } from "../resources/common/types/PortProtocol"; +import { PortRouting } from "../resources/common/types/PortRouting"; export declare const CreateActorPortRequest: core.serialization.ObjectSchema; export declare namespace CreateActorPortRequest { interface Raw { - protocol: actor.PortProtocol.Raw; + protocol: PortProtocol.Raw; internal_port?: number | null; - routing?: actor.PortRouting.Raw | null; + routing?: PortRouting.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorRequest.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorRequest.d.ts index 4ace93a1e5..5fb5408646 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorRequest.d.ts @@ -4,15 +4,18 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { CreateActorRuntimeRequest } from "./CreateActorRuntimeRequest"; +import { CreateActorNetworkRequest } from "./CreateActorNetworkRequest"; +import { Resources } from "../resources/common/types/Resources"; +import { Lifecycle } from "../resources/common/types/Lifecycle"; export declare const CreateActorRequest: core.serialization.ObjectSchema; export declare namespace CreateActorRequest { interface Raw { region: string; tags?: unknown; - runtime: actor.CreateActorRuntimeRequest.Raw; - network?: actor.CreateActorNetworkRequest.Raw | null; - resources: actor.Resources.Raw; - lifecycle?: actor.Lifecycle.Raw | null; + runtime: CreateActorRuntimeRequest.Raw; + network?: CreateActorNetworkRequest.Raw | null; + resources: Resources.Raw; + lifecycle?: Lifecycle.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorResponse.d.ts index 5fd53ac2c5..97c608acd1 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/CreateActorResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export declare const CreateActorResponse: core.serialization.ObjectSchema; export declare namespace CreateActorResponse { interface Raw { - actor: actor.Actor.Raw; + actor: Actor.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/GetActorResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/GetActorResponse.d.ts index 4521487d9e..c533b3e499 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/GetActorResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/GetActorResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export declare const GetActorResponse: core.serialization.ObjectSchema; export declare namespace GetActorResponse { interface Raw { - actor: actor.Actor.Raw; + actor: Actor.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/actor/types/ListActorsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/actor/types/ListActorsResponse.d.ts index d8d9211003..c8afc3ef42 100644 --- a/sdks/full/typescript/types/serialization/resources/actor/types/ListActorsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/actor/types/ListActorsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { actor } from "../../index"; +import { Actor } from "../resources/common/types/Actor"; export declare const ListActorsResponse: core.serialization.ObjectSchema; export declare namespace ListActorsResponse { interface Raw { - actors: actor.Actor.Raw[]; + actors: Actor.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.d.ts b/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.d.ts index 97495faad9..d2a7360681 100644 --- a/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/CompleteEmailVerificationResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { auth } from "../../../../../../index"; +import { CompleteStatus } from "../../../../common/types/CompleteStatus"; export declare const CompleteEmailVerificationResponse: core.serialization.ObjectSchema; export declare namespace CompleteEmailVerificationResponse { interface Raw { - status: auth.CompleteStatus.Raw; + status: CompleteStatus.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.d.ts b/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.d.ts index 148852118f..1bbae31b5c 100644 --- a/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/auth/resources/identity/resources/email/types/StartEmailVerificationRequest.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { captcha } from "../../../../../../index"; +import { Config } from "../../../../../../captcha/resources/config/types/Config"; export declare const StartEmailVerificationRequest: core.serialization.ObjectSchema; export declare namespace StartEmailVerificationRequest { interface Raw { email: string; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; game_id?: string | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/captcha/resources/config/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/captcha/resources/config/types/Config.d.ts index 1774ffa45c..482c300aee 100644 --- a/sdks/full/typescript/types/serialization/resources/captcha/resources/config/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/captcha/resources/config/types/Config.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { captcha } from "../../../../index"; +import { ConfigHcaptcha } from "./ConfigHcaptcha"; +import { ConfigTurnstile } from "./ConfigTurnstile"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { - hcaptcha?: captcha.ConfigHcaptcha.Raw | null; - turnstile?: captcha.ConfigTurnstile.Raw | null; + hcaptcha?: ConfigHcaptcha.Raw | null; + turnstile?: ConfigTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/auth/types/InspectResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/auth/types/InspectResponse.d.ts index fcc17a6ef7..3209059ef0 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/auth/types/InspectResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/auth/types/InspectResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { AuthAgent } from "../../common/types/AuthAgent"; export declare const InspectResponse: core.serialization.ObjectSchema; export declare namespace InspectResponse { interface Raw { - agent: cloud.AuthAgent.Raw; + agent: AuthAgent.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/AuthAgent.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/AuthAgent.d.ts index da963e9255..9830bcbd75 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/AuthAgent.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/AuthAgent.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { AuthAgentIdentity } from "./AuthAgentIdentity"; +import { AuthAgentGameCloud } from "./AuthAgentGameCloud"; export declare const AuthAgent: core.serialization.ObjectSchema; export declare namespace AuthAgent { interface Raw { - identity?: cloud.AuthAgentIdentity.Raw | null; - game_cloud?: cloud.AuthAgentGameCloud.Raw | null; + identity?: AuthAgentIdentity.Raw | null; + game_cloud?: AuthAgentGameCloud.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/BuildSummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/BuildSummary.d.ts index 87ab52fbc3..0de29b07e6 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/BuildSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/BuildSummary.d.ts @@ -4,14 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const BuildSummary: core.serialization.ObjectSchema; export declare namespace BuildSummary { interface Raw { build_id: string; upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; content_length: number; complete: boolean; tags: Record; diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.d.ts index c32246c583..da6aee493b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceConfig.d.ts @@ -4,13 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { CdnNamespaceDomain } from "./CdnNamespaceDomain"; +import { CdnAuthType } from "./CdnAuthType"; +import { CdnNamespaceAuthUser } from "./CdnNamespaceAuthUser"; export declare const CdnNamespaceConfig: core.serialization.ObjectSchema; export declare namespace CdnNamespaceConfig { interface Raw { enable_domain_public_auth: boolean; - domains: cloud.CdnNamespaceDomain.Raw[]; - auth_type: cloud.CdnAuthType.Raw; - auth_user_list: cloud.CdnNamespaceAuthUser.Raw[]; + domains: CdnNamespaceDomain.Raw[]; + auth_type: CdnAuthType.Raw; + auth_user_list: CdnNamespaceAuthUser.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.d.ts index 30c482bc8c..923b13b415 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomain.d.ts @@ -4,14 +4,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { CdnNamespaceDomainVerificationStatus } from "./CdnNamespaceDomainVerificationStatus"; +import { CdnNamespaceDomainVerificationMethod } from "./CdnNamespaceDomainVerificationMethod"; export declare const CdnNamespaceDomain: core.serialization.ObjectSchema; export declare namespace CdnNamespaceDomain { interface Raw { domain: string; - create_ts: common.Timestamp.Raw; - verification_status: cloud.CdnNamespaceDomainVerificationStatus.Raw; - verification_method: cloud.CdnNamespaceDomainVerificationMethod.Raw; + create_ts: Timestamp.Raw; + verification_status: CdnNamespaceDomainVerificationStatus.Raw; + verification_method: CdnNamespaceDomainVerificationMethod.Raw; verification_errors: string[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.d.ts index 0146e0e018..a44a13bc0f 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnNamespaceDomainVerificationMethod.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { EmptyObject } from "../../../../common/types/EmptyObject"; +import { CdnNamespaceDomainVerificationMethodHttp } from "./CdnNamespaceDomainVerificationMethodHttp"; export declare const CdnNamespaceDomainVerificationMethod: core.serialization.ObjectSchema; export declare namespace CdnNamespaceDomainVerificationMethod { interface Raw { - invalid?: common.EmptyObject.Raw | null; - http?: cloud.CdnNamespaceDomainVerificationMethodHttp.Raw | null; + invalid?: EmptyObject.Raw | null; + http?: CdnNamespaceDomainVerificationMethodHttp.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnSiteSummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnSiteSummary.d.ts index 448c4c75df..cb2a6d9d34 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnSiteSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CdnSiteSummary.d.ts @@ -4,14 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const CdnSiteSummary: core.serialization.ObjectSchema; export declare namespace CdnSiteSummary { interface Raw { site_id: string; upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; content_length: number; complete: boolean; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.d.ts index edcdeb8f07..df453a7beb 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/CustomAvatarSummary.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const CustomAvatarSummary: core.serialization.ObjectSchema; export declare namespace CustomAvatarSummary { interface Raw { upload_id: string; - display_name: common.DisplayName.Raw; - create_ts: common.Timestamp.Raw; + display_name: DisplayName.Raw; + create_ts: Timestamp.Raw; url?: string | null; content_length: number; complete: boolean; diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameFull.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameFull.d.ts index 5169c0b812..ebb91f34ea 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameFull.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameFull.d.ts @@ -4,20 +4,24 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { NamespaceSummary } from "./NamespaceSummary"; +import { Summary } from "../../version/types/Summary"; +import { RegionSummary } from "./RegionSummary"; export declare const GameFull: core.serialization.ObjectSchema; export declare namespace GameFull { interface Raw { game_id: string; - create_ts: common.Timestamp.Raw; + create_ts: Timestamp.Raw; name_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; developer_group_id: string; total_player_count: number; logo_url?: string | null; banner_url?: string | null; - namespaces: cloud.NamespaceSummary.Raw[]; - versions: cloud.version.Summary.Raw[]; - available_regions: cloud.RegionSummary.Raw[]; + namespaces: NamespaceSummary.Raw[]; + versions: Summary.Raw[]; + available_regions: RegionSummary.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.d.ts index 99eae6e343..3bcba28fde 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/GameLobbyExpenses.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game, cloud } from "../../../../index"; +import { Handle } from "../../../../game/resources/common/types/Handle"; +import { NamespaceSummary } from "./NamespaceSummary"; +import { RegionTierExpenses } from "./RegionTierExpenses"; export declare const GameLobbyExpenses: core.serialization.ObjectSchema; export declare namespace GameLobbyExpenses { interface Raw { - game: game.Handle.Raw; - namespaces: cloud.NamespaceSummary.Raw[]; - expenses: cloud.RegionTierExpenses.Raw[]; + game: Handle.Raw; + namespaces: NamespaceSummary.Raw[]; + expenses: RegionTierExpenses.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.d.ts index 563a2d2bac..36f777a1a3 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LobbySummaryAnalytics.d.ts @@ -4,7 +4,7 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const LobbySummaryAnalytics: core.serialization.ObjectSchema; export declare namespace LobbySummaryAnalytics { interface Raw { @@ -12,7 +12,7 @@ export declare namespace LobbySummaryAnalytics { lobby_group_id: string; lobby_group_name_id: string; region_id: string; - create_ts: common.Timestamp.Raw; + create_ts: Timestamp.Raw; is_ready: boolean; is_idle: boolean; is_closed: boolean; diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.d.ts index be3f9c51f0..79cbe0aa8f 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatus.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { EmptyObject } from "../../../../common/types/EmptyObject"; +import { LogsLobbyStatusStopped } from "./LogsLobbyStatusStopped"; export declare const LogsLobbyStatus: core.serialization.ObjectSchema; export declare namespace LogsLobbyStatus { interface Raw { - running: common.EmptyObject.Raw; - stopped?: cloud.LogsLobbyStatusStopped.Raw | null; + running: EmptyObject.Raw; + stopped?: LogsLobbyStatusStopped.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.d.ts index 5ba3121b28..51f755c5a5 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbyStatusStopped.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const LogsLobbyStatusStopped: core.serialization.ObjectSchema; export declare namespace LogsLobbyStatusStopped { interface Raw { - stop_ts: common.Timestamp.Raw; + stop_ts: Timestamp.Raw; failed: boolean; exit_code: number; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbySummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbySummary.d.ts index b570011ed5..ba909bf1c5 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbySummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsLobbySummary.d.ts @@ -4,7 +4,8 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { LogsLobbyStatus } from "./LogsLobbyStatus"; export declare const LogsLobbySummary: core.serialization.ObjectSchema; export declare namespace LogsLobbySummary { interface Raw { @@ -12,9 +13,9 @@ export declare namespace LogsLobbySummary { namespace_id: string; lobby_group_name_id: string; region_id: string; - create_ts: common.Timestamp.Raw; - start_ts?: common.Timestamp.Raw | null; - ready_ts?: common.Timestamp.Raw | null; - status: cloud.LogsLobbyStatus.Raw; + create_ts: Timestamp.Raw; + start_ts?: Timestamp.Raw | null; + ready_ts?: Timestamp.Raw | null; + status: LogsLobbyStatus.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfMark.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfMark.d.ts index dcc7cb9ddf..497f715477 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfMark.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfMark.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const LogsPerfMark: core.serialization.ObjectSchema; export declare namespace LogsPerfMark { interface Raw { label: string; - ts: common.Timestamp.Raw; + ts: Timestamp.Raw; ray_id?: string | null; req_id?: string | null; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfSpan.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfSpan.d.ts index c1d085b805..c6cbce43f7 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfSpan.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/LogsPerfSpan.d.ts @@ -4,13 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const LogsPerfSpan: core.serialization.ObjectSchema; export declare namespace LogsPerfSpan { interface Raw { label: string; - start_ts: common.Timestamp.Raw; - finish_ts?: common.Timestamp.Raw | null; + start_ts: Timestamp.Raw; + finish_ts?: Timestamp.Raw | null; req_id?: string | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.d.ts index bd772f7eba..19bc059e09 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/MatchmakerDevelopmentPort.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { PortRange } from "../../version/resources/matchmaker/resources/common/types/PortRange"; +import { PortProtocol } from "../../version/resources/matchmaker/resources/common/types/PortProtocol"; export declare const MatchmakerDevelopmentPort: core.serialization.ObjectSchema; export declare namespace MatchmakerDevelopmentPort { interface Raw { port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - protocol: cloud.version.matchmaker.PortProtocol.Raw; + port_range?: PortRange.Raw | null; + protocol: PortProtocol.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceConfig.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceConfig.d.ts index 01c918735d..e48e0157af 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceConfig.d.ts @@ -4,13 +4,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { CdnNamespaceConfig } from "./CdnNamespaceConfig"; +import { MatchmakerNamespaceConfig } from "./MatchmakerNamespaceConfig"; +import { KvNamespaceConfig } from "./KvNamespaceConfig"; +import { IdentityNamespaceConfig } from "./IdentityNamespaceConfig"; export declare const NamespaceConfig: core.serialization.ObjectSchema; export declare namespace NamespaceConfig { interface Raw { - cdn: cloud.CdnNamespaceConfig.Raw; - matchmaker: cloud.MatchmakerNamespaceConfig.Raw; - kv: cloud.KvNamespaceConfig.Raw; - identity: cloud.IdentityNamespaceConfig.Raw; + cdn: CdnNamespaceConfig.Raw; + matchmaker: MatchmakerNamespaceConfig.Raw; + kv: KvNamespaceConfig.Raw; + identity: IdentityNamespaceConfig.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceFull.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceFull.d.ts index 7e1165736f..94f93d454d 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceFull.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceFull.d.ts @@ -4,15 +4,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { NamespaceConfig } from "./NamespaceConfig"; export declare const NamespaceFull: core.serialization.ObjectSchema; export declare namespace NamespaceFull { interface Raw { namespace_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; - config: cloud.NamespaceConfig.Raw; + config: NamespaceConfig.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceSummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceSummary.d.ts index 8fb4ebd52e..cdecadb080 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceSummary.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const NamespaceSummary: core.serialization.ObjectSchema; export declare namespace NamespaceSummary { interface Raw { namespace_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceVersion.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceVersion.d.ts index 7bdaf0fd88..2a27addfc1 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceVersion.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/NamespaceVersion.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const NamespaceVersion: core.serialization.ObjectSchema; export declare namespace NamespaceVersion { interface Raw { namespace_id: string; version_id: string; - deploy_ts: common.Timestamp.Raw; + deploy_ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/RegionSummary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/RegionSummary.d.ts index 8917e29046..8eb6c428fb 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/RegionSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/RegionSummary.d.ts @@ -4,15 +4,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud, common } from "../../../../index"; +import { UniversalRegion } from "./UniversalRegion"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const RegionSummary: core.serialization.ObjectSchema; export declare namespace RegionSummary { interface Raw { region_id: string; region_name_id: string; provider: string; - universal_region: cloud.UniversalRegion.Raw; - provider_display_name: common.DisplayName.Raw; - region_display_name: common.DisplayName.Raw; + universal_region: UniversalRegion.Raw; + provider_display_name: DisplayName.Raw; + region_display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/SvcPerf.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/SvcPerf.d.ts index 42e84225be..5b34e10ebf 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/SvcPerf.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/common/types/SvcPerf.d.ts @@ -4,15 +4,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { LogsPerfSpan } from "./LogsPerfSpan"; +import { LogsPerfMark } from "./LogsPerfMark"; export declare const SvcPerf: core.serialization.ObjectSchema; export declare namespace SvcPerf { interface Raw { svc_name: string; - ts: common.Timestamp.Raw; + ts: Timestamp.Raw; duration: number; req_id?: string | null; - spans: cloud.LogsPerfSpan.Raw[]; - marks: cloud.LogsPerfMark.Raw[]; + spans: LogsPerfSpan.Raw[]; + marks: LogsPerfMark.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.d.ts index fd52691277..307326a937 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/CompleteDeviceLinkRequest.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { Jwt } from "../../../../../../common/types/Jwt"; export declare const CompleteDeviceLinkRequest: core.serialization.ObjectSchema; export declare namespace CompleteDeviceLinkRequest { interface Raw { - device_link_token: common.Jwt.Raw; + device_link_token: Jwt.Raw; game_id: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.d.ts index d0f966d888..e40e73888e 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/devices/resources/links/types/GetDeviceLinkResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { WatchResponse } from "../../../../../../common/types/WatchResponse"; export declare const GetDeviceLinkResponse: core.serialization.ObjectSchema; export declare namespace GetDeviceLinkResponse { interface Raw { cloud_token?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.d.ts index d56618690c..7965083073 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/ListGameCustomAvatarsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { CustomAvatarSummary } from "../../../../common/types/CustomAvatarSummary"; export declare const ListGameCustomAvatarsResponse: core.serialization.ObjectSchema; export declare namespace ListGameCustomAvatarsResponse { interface Raw { - custom_avatars: cloud.CustomAvatarSummary.Raw[]; + custom_avatars: CustomAvatarSummary.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.d.ts index d55a949fd1..d78fad8918 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/avatars/types/PrepareCustomAvatarUploadResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export declare const PrepareCustomAvatarUploadResponse: core.serialization.ObjectSchema; export declare namespace PrepareCustomAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.d.ts index a3dfae5694..9accf63437 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildRequest.d.ts @@ -4,15 +4,18 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common, upload, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { PrepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; +import { BuildKind } from "./BuildKind"; +import { BuildCompression } from "./BuildCompression"; export declare const CreateGameBuildRequest: core.serialization.ObjectSchema; export declare namespace CreateGameBuildRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; image_tag: string; - image_file: upload.PrepareFile.Raw; + image_file: PrepareFile.Raw; multipart_upload?: boolean | null; - kind?: cloud.games.BuildKind.Raw | null; - compression?: cloud.games.BuildCompression.Raw | null; + kind?: BuildKind.Raw | null; + compression?: BuildCompression.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.d.ts index 15ac02fe3a..f36e37ed46 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/CreateGameBuildResponse.d.ts @@ -4,13 +4,13 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export declare const CreateGameBuildResponse: core.serialization.ObjectSchema; export declare namespace CreateGameBuildResponse { interface Raw { build_id: string; upload_id: string; - image_presigned_request?: upload.PresignedRequest.Raw | null; - image_presigned_requests?: upload.PresignedRequest.Raw[] | null; + image_presigned_request?: PresignedRequest.Raw | null; + image_presigned_requests?: PresignedRequest.Raw[] | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.d.ts index 3b6bf3ea15..79f3e0942a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/builds/types/ListGameBuildsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { BuildSummary } from "../../../../common/types/BuildSummary"; export declare const ListGameBuildsResponse: core.serialization.ObjectSchema; export declare namespace ListGameBuildsResponse { interface Raw { - builds: cloud.BuildSummary.Raw[]; + builds: BuildSummary.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.d.ts index 5118d64b8f..6be51e17ca 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common, upload } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { PrepareFile } from "../../../../../../upload/resources/common/types/PrepareFile"; export declare const CreateGameCdnSiteRequest: core.serialization.ObjectSchema; export declare namespace CreateGameCdnSiteRequest { interface Raw { - display_name: common.DisplayName.Raw; - files: upload.PrepareFile.Raw[]; + display_name: DisplayName.Raw; + files: PrepareFile.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.d.ts index 6505a3d41a..e6365ed742 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/CreateGameCdnSiteResponse.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { upload } from "../../../../../../index"; +import { PresignedRequest } from "../../../../../../upload/resources/common/types/PresignedRequest"; export declare const CreateGameCdnSiteResponse: core.serialization.ObjectSchema; export declare namespace CreateGameCdnSiteResponse { interface Raw { site_id: string; upload_id: string; - presigned_requests: upload.PresignedRequest.Raw[]; + presigned_requests: PresignedRequest.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.d.ts index 0cad67379d..04c92afa5a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/cdn/types/ListGameCdnSitesResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { CdnSiteSummary } from "../../../../common/types/CdnSiteSummary"; export declare const ListGameCdnSitesResponse: core.serialization.ObjectSchema; export declare namespace ListGameCdnSitesResponse { interface Raw { - sites: cloud.CdnSiteSummary.Raw[]; + sites: CdnSiteSummary.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.d.ts index 5da4873e26..25ac12102f 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/ExportLobbyLogsRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { LogStream } from "./LogStream"; export declare const ExportLobbyLogsRequest: core.serialization.ObjectSchema; export declare namespace ExportLobbyLogsRequest { interface Raw { - stream: cloud.games.LogStream.Raw; + stream: LogStream.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.d.ts index 4288d3c879..e372236d84 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/matchmaker/types/GetLobbyLogsResponse.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { WatchResponse } from "../../../../../../common/types/WatchResponse"; export declare const GetLobbyLogsResponse: core.serialization.ObjectSchema; export declare namespace GetLobbyLogsResponse { interface Raw { lines: string[]; timestamps: string[]; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.d.ts index 026890fc2c..27050ace1e 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/analytics/types/GetAnalyticsMatchmakerLiveResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LobbySummaryAnalytics } from "../../../../../../common/types/LobbySummaryAnalytics"; export declare const GetAnalyticsMatchmakerLiveResponse: core.serialization.ObjectSchema; export declare namespace GetAnalyticsMatchmakerLiveResponse { interface Raw { - lobbies: cloud.LobbySummaryAnalytics.Raw[]; + lobbies: LobbySummaryAnalytics.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.d.ts index e318190332..ae631d791d 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/GetNamespaceLobbyResponse.d.ts @@ -4,14 +4,16 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LogsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; +import { SvcMetrics } from "../../../../../../common/types/SvcMetrics"; +import { SvcPerf } from "../../../../../../common/types/SvcPerf"; export declare const GetNamespaceLobbyResponse: core.serialization.ObjectSchema; export declare namespace GetNamespaceLobbyResponse { interface Raw { - lobby: cloud.LogsLobbySummary.Raw; - metrics?: cloud.SvcMetrics.Raw | null; + lobby: LogsLobbySummary.Raw; + metrics?: SvcMetrics.Raw | null; stdout_presigned_urls: string[]; stderr_presigned_urls: string[]; - perf_lists: cloud.SvcPerf.Raw[]; + perf_lists: SvcPerf.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.d.ts index 2f46f21ace..fc06bfd597 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/resources/logs/types/ListNamespaceLobbiesResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LogsLobbySummary } from "../../../../../../common/types/LogsLobbySummary"; export declare const ListNamespaceLobbiesResponse: core.serialization.ObjectSchema; export declare namespace ListNamespaceLobbiesResponse { interface Raw { - lobbies: cloud.LogsLobbySummary.Raw[]; + lobbies: LogsLobbySummary.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.d.ts index d23fac134d..668226198a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceRequest.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export declare const CreateGameNamespaceRequest: core.serialization.ObjectSchema; export declare namespace CreateGameNamespaceRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; version_id: string; name_id: string; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.d.ts index 6514ea96e5..47cc32102f 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/CreateGameNamespaceTokenDevelopmentRequest.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { MatchmakerDevelopmentPort } from "../../../../common/types/MatchmakerDevelopmentPort"; +import { LobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; export declare const CreateGameNamespaceTokenDevelopmentRequest: core.serialization.ObjectSchema; export declare namespace CreateGameNamespaceTokenDevelopmentRequest { interface Raw { hostname: string; - ports?: Record | null; - lobby_ports?: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[] | null; + ports?: Record | null; + lobby_ports?: LobbyGroupRuntimeDockerPort.Raw[] | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.d.ts index 262fe86858..652c2d618d 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceByIdResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { NamespaceFull } from "../../../../common/types/NamespaceFull"; export declare const GetGameNamespaceByIdResponse: core.serialization.ObjectSchema; export declare namespace GetGameNamespaceByIdResponse { interface Raw { - namespace: cloud.NamespaceFull.Raw; + namespace: NamespaceFull.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.d.ts index cd0b9fb8b3..ed32db61d6 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/GetGameNamespaceVersionHistoryResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { NamespaceVersion } from "../../../../common/types/NamespaceVersion"; export declare const GetGameNamespaceVersionHistoryResponse: core.serialization.ObjectSchema; export declare namespace GetGameNamespaceVersionHistoryResponse { interface Raw { - versions: cloud.NamespaceVersion.Raw[]; + versions: NamespaceVersion.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.d.ts index 144a9532c7..2ebb73dafd 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/InspectResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { AuthAgent } from "../../../../common/types/AuthAgent"; export declare const InspectResponse: core.serialization.ObjectSchema; export declare namespace InspectResponse { interface Raw { - agent: cloud.AuthAgent.Raw; + agent: AuthAgent.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.d.ts index 43418653ff..730bb64587 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/SetNamespaceCdnAuthTypeRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { CdnAuthType } from "../../../../common/types/CdnAuthType"; export declare const SetNamespaceCdnAuthTypeRequest: core.serialization.ObjectSchema; export declare namespace SetNamespaceCdnAuthTypeRequest { interface Raw { - auth_type: cloud.CdnAuthType.Raw; + auth_type: CdnAuthType.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.d.ts index 62bfadbe88..c499841da3 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceMatchmakerConfigResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export declare const ValidateGameNamespaceMatchmakerConfigResponse: core.serialization.ObjectSchema; export declare namespace ValidateGameNamespaceMatchmakerConfigResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.d.ts index 2531b933ab..31dc2a5665 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceRequest.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export declare const ValidateGameNamespaceRequest: core.serialization.ObjectSchema; export declare namespace ValidateGameNamespaceRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; name_id: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.d.ts index 149e672f90..203fbbbf3a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export declare const ValidateGameNamespaceResponse: core.serialization.ObjectSchema; export declare namespace ValidateGameNamespaceResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.d.ts index edccd28842..d6f1bbda42 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentRequest.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { LobbyGroupRuntimeDockerPort } from "../../../../version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort"; export declare const ValidateGameNamespaceTokenDevelopmentRequest: core.serialization.ObjectSchema; export declare namespace ValidateGameNamespaceTokenDevelopmentRequest { interface Raw { hostname: string; - lobby_ports: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[]; + lobby_ports: LobbyGroupRuntimeDockerPort.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.d.ts index b3df0cf814..134c830976 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/namespaces/types/ValidateGameNamespaceTokenDevelopmentResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export declare const ValidateGameNamespaceTokenDevelopmentResponse: core.serialization.ObjectSchema; export declare namespace ValidateGameNamespaceTokenDevelopmentResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.d.ts index 4475865be5..8d3c5de883 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/CreateGameVersionRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { Config } from "../../../../version/types/Config"; export declare const CreateGameVersionRequest: core.serialization.ObjectSchema; export declare namespace CreateGameVersionRequest { interface Raw { - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.d.ts index 27ca9da35f..b1749c4a4b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/GetGameVersionByIdResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { Full } from "../../../../version/types/Full"; export declare const GetGameVersionByIdResponse: core.serialization.ObjectSchema; export declare namespace GetGameVersionByIdResponse { interface Raw { - version: cloud.version.Full.Raw; + version: Full.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.d.ts index 1f1b23d638..e91d47b570 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ReserveVersionNameResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export declare const ReserveVersionNameResponse: core.serialization.ObjectSchema; export declare namespace ReserveVersionNameResponse { interface Raw { - version_display_name: common.DisplayName.Raw; + version_display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.d.ts index e2c481bdeb..32a369656a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common, cloud } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; +import { Config } from "../../../../version/types/Config"; export declare const ValidateGameVersionRequest: core.serialization.ObjectSchema; export declare namespace ValidateGameVersionRequest { interface Raw { - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.d.ts index 2ebc711fe8..d4ca5c78cf 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/resources/versions/types/ValidateGameVersionResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { ValidationError } from "../../../../../../common/types/ValidationError"; export declare const ValidateGameVersionResponse: core.serialization.ObjectSchema; export declare namespace ValidateGameVersionResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/CreateGameRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/CreateGameRequest.d.ts index ab168d3366..7690e31a8d 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/CreateGameRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/CreateGameRequest.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const CreateGameRequest: core.serialization.ObjectSchema; export declare namespace CreateGameRequest { interface Raw { - name_id?: common.Identifier.Raw | null; - display_name: common.DisplayName.Raw; + name_id?: Identifier.Raw | null; + display_name: DisplayName.Raw; developer_group_id: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.d.ts index 956ce0fc1e..a17735c10b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameBannerUploadPrepareResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { upload } from "../../../../index"; +import { PresignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; export declare const GameBannerUploadPrepareResponse: core.serialization.ObjectSchema; export declare namespace GameBannerUploadPrepareResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.d.ts index 93104f71d9..98fbcd6584 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GameLogoUploadPrepareResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { upload } from "../../../../index"; +import { PresignedRequest } from "../../../../upload/resources/common/types/PresignedRequest"; export declare const GameLogoUploadPrepareResponse: core.serialization.ObjectSchema; export declare namespace GameLogoUploadPrepareResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.d.ts index 6a20127945..3f87873588 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGameByIdResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud, common } from "../../../../index"; +import { GameFull } from "../../common/types/GameFull"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const GetGameByIdResponse: core.serialization.ObjectSchema; export declare namespace GetGameByIdResponse { interface Raw { - game: cloud.GameFull.Raw; - watch: common.WatchResponse.Raw; + game: GameFull.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGamesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGamesResponse.d.ts index f90440589a..1abf7ab943 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGamesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/GetGamesResponse.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game, group, common } from "../../../../index"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const GetGamesResponse: core.serialization.ObjectSchema; export declare namespace GetGamesResponse { interface Raw { - games: game.Summary.Raw[]; - groups: group.Summary.Raw[]; - watch: common.WatchResponse.Raw; + games: Summary.Raw[]; + groups: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameRequest.d.ts index b552afc821..91430553be 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Identifier } from "../../../../common/types/Identifier"; export declare const ValidateGameRequest: core.serialization.ObjectSchema; export declare namespace ValidateGameRequest { interface Raw { - display_name: common.DisplayName.Raw; - name_id?: common.Identifier.Raw | null; + display_name: DisplayName.Raw; + name_id?: Identifier.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameResponse.d.ts index 4d38b58cd9..9cff0eab12 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/games/types/ValidateGameResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { ValidationError } from "../../../../common/types/ValidationError"; export declare const ValidateGameResponse: core.serialization.ObjectSchema; export declare namespace ValidateGameResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.d.ts index 241c77d87c..8362bf62a5 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const ValidateGroupRequest: core.serialization.ObjectSchema; export declare namespace ValidateGroupRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.d.ts index 78bcba0676..e4e6a837c1 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/groups/types/ValidateGroupResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { ValidationError } from "../../../../common/types/ValidationError"; export declare const ValidateGroupResponse: core.serialization.ObjectSchema; export declare namespace ValidateGroupResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.d.ts index 42261b6043..22fec295d8 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/logs/types/GetRayPerfLogsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { SvcPerf } from "../../common/types/SvcPerf"; export declare const GetRayPerfLogsResponse: core.serialization.ObjectSchema; export declare namespace GetRayPerfLogsResponse { interface Raw { - perf_lists: cloud.SvcPerf.Raw[]; + perf_lists: SvcPerf.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.d.ts index 5262b43612..55e42ebe6c 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/tiers/types/GetRegionTiersResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { RegionTier } from "../../common/types/RegionTier"; export declare const GetRegionTiersResponse: core.serialization.ObjectSchema; export declare namespace GetRegionTiersResponse { interface Raw { - tiers: cloud.RegionTier.Raw[]; + tiers: RegionTier.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Config.d.ts index 403a4b63b1..5981d95e6b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Config.d.ts @@ -4,7 +4,7 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { Route } from "./Route"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { @@ -12,6 +12,6 @@ export declare namespace Config { build_output?: string | null; build_env?: Record | null; site_id?: string | null; - routes?: cloud.version.cdn.Route.Raw[] | null; + routes?: Route.Raw[] | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.d.ts index 627d93343f..944975e12c 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/CustomHeadersMiddleware.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { Header } from "./Header"; export declare const CustomHeadersMiddleware: core.serialization.ObjectSchema; export declare namespace CustomHeadersMiddleware { interface Raw { - headers: cloud.version.cdn.Header.Raw[]; + headers: Header.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.d.ts index e3fb5e54dd..3312570dd7 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Middleware.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { MiddlewareKind } from "./MiddlewareKind"; export declare const Middleware: core.serialization.ObjectSchema; export declare namespace Middleware { interface Raw { - kind: cloud.version.cdn.MiddlewareKind.Raw; + kind: MiddlewareKind.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.d.ts index 02c073fff2..843eced2a0 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/MiddlewareKind.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { CustomHeadersMiddleware } from "./CustomHeadersMiddleware"; export declare const MiddlewareKind: core.serialization.ObjectSchema; export declare namespace MiddlewareKind { interface Raw { - custom_headers?: cloud.version.cdn.CustomHeadersMiddleware.Raw | null; + custom_headers?: CustomHeadersMiddleware.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Route.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Route.d.ts index 6cb1709c36..b483bf4165 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Route.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/cdn/types/Route.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { Middleware } from "./Middleware"; export declare const Route: core.serialization.ObjectSchema; export declare namespace Route { interface Raw { glob: string; priority: number; - middlewares: cloud.version.cdn.Middleware.Raw[]; + middlewares: Middleware.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/engine/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/engine/types/Config.d.ts index 0cc03a22f4..010652d131 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/engine/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/engine/types/Config.d.ts @@ -4,14 +4,18 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { UnityConfig } from "../resources/unity/types/UnityConfig"; +import { UnrealConfig } from "../resources/unreal/types/UnrealConfig"; +import { GodotConfig } from "../resources/godot/types/GodotConfig"; +import { Html5Config } from "../resources/html5/types/Html5Config"; +import { CustomConfig } from "../resources/custom/types/CustomConfig"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { - unity?: cloud.version.engine.UnityConfig.Raw | null; - unreal?: cloud.version.engine.UnrealConfig.Raw | null; - godot?: cloud.version.engine.GodotConfig.Raw | null; - html5?: cloud.version.engine.Html5Config.Raw | null; - custom?: cloud.version.engine.CustomConfig.Raw | null; + unity?: UnityConfig.Raw | null; + unreal?: UnrealConfig.Raw | null; + godot?: GodotConfig.Raw | null; + html5?: Html5Config.Raw | null; + custom?: CustomConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/Config.d.ts index 0f4bef27a7..ff7eab697b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/Config.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { CustomDisplayName } from "./CustomDisplayName"; +import { CustomAvatar } from "./CustomAvatar"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { display_names?: string[] | null; avatars?: string[] | null; - custom_display_names?: cloud.version.identity.CustomDisplayName.Raw[] | null; - custom_avatars?: cloud.version.identity.CustomAvatar.Raw[] | null; + custom_display_names?: CustomDisplayName.Raw[] | null; + custom_avatars?: CustomAvatar.Raw[] | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.d.ts index 82f9829958..28b20b0f5d 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/identity/types/CustomDisplayName.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { common } from "../../../../../../index"; +import { DisplayName } from "../../../../../../common/types/DisplayName"; export declare const CustomDisplayName: core.serialization.ObjectSchema; export declare namespace CustomDisplayName { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.d.ts index 284a0d99c6..ea031ce731 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/Captcha.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { CaptchaHcaptcha } from "./CaptchaHcaptcha"; +import { CaptchaTurnstile } from "./CaptchaTurnstile"; export declare const Captcha: core.serialization.ObjectSchema; export declare namespace Captcha { interface Raw { requests_before_reverify: number; verification_ttl: number; - hcaptcha?: cloud.version.matchmaker.CaptchaHcaptcha.Raw | null; - turnstile?: cloud.version.matchmaker.CaptchaTurnstile.Raw | null; + hcaptcha?: CaptchaHcaptcha.Raw | null; + turnstile?: CaptchaTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.d.ts index 97344c84d6..cd0dafe321 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/common/types/CaptchaHcaptcha.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { CaptchaHcaptchaLevel } from "./CaptchaHcaptchaLevel"; export declare const CaptchaHcaptcha: core.serialization.ObjectSchema; export declare namespace CaptchaHcaptcha { interface Raw { - level?: cloud.version.matchmaker.CaptchaHcaptchaLevel.Raw | null; + level?: CaptchaHcaptchaLevel.Raw | null; site_key?: string | null; secret_key?: string | null; } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.d.ts index e905e4a1d2..3cdfa9aea3 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameMode.d.ts @@ -4,20 +4,23 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeRegion } from "./GameModeRegion"; +import { GameModeRuntimeDocker } from "./GameModeRuntimeDocker"; +import { GameModeActions } from "./GameModeActions"; +import { GameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; export declare const GameMode: core.serialization.ObjectSchema; export declare namespace GameMode { interface Raw { - regions?: Record | null; + regions?: Record | null; max_players?: number | null; max_players_direct?: number | null; max_players_party?: number | null; - docker?: cloud.version.matchmaker.GameModeRuntimeDocker.Raw | null; + docker?: GameModeRuntimeDocker.Raw | null; listable?: boolean | null; taggable?: boolean | null; allow_dynamic_max_players?: boolean | null; - actions?: cloud.version.matchmaker.GameModeActions.Raw | null; + actions?: GameModeActions.Raw | null; tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.d.ts index 64744d03c0..e9fe24a28b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeActions.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeFindConfig } from "./GameModeFindConfig"; +import { GameModeJoinConfig } from "./GameModeJoinConfig"; +import { GameModeCreateConfig } from "./GameModeCreateConfig"; export declare const GameModeActions: core.serialization.ObjectSchema; export declare namespace GameModeActions { interface Raw { - find?: cloud.version.matchmaker.GameModeFindConfig.Raw | null; - join?: cloud.version.matchmaker.GameModeJoinConfig.Raw | null; - create?: cloud.version.matchmaker.GameModeCreateConfig.Raw | null; + find?: GameModeFindConfig.Raw | null; + join?: GameModeJoinConfig.Raw | null; + create?: GameModeCreateConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.d.ts index d6477317de..57103f109e 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeCreateConfig.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export declare const GameModeCreateConfig: core.serialization.ObjectSchema; export declare namespace GameModeCreateConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; enable_public?: boolean | null; enable_private?: boolean | null; max_lobbies_per_identity?: number | null; diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.d.ts index b2cbbbd0eb..5f354ebb2f 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeFindConfig.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export declare const GameModeFindConfig: core.serialization.ObjectSchema; export declare namespace GameModeFindConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.d.ts index 9c7bd60cf6..93d3eaf285 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeJoinConfig.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdentityRequirement } from "./GameModeIdentityRequirement"; +import { GameModeVerificationConfig } from "./GameModeVerificationConfig"; export declare const GameModeJoinConfig: core.serialization.ObjectSchema; export declare namespace GameModeJoinConfig { interface Raw { enabled: boolean; - identity_requirement?: cloud.version.matchmaker.GameModeIdentityRequirement.Raw | null; - verification?: cloud.version.matchmaker.GameModeVerificationConfig.Raw | null; + identity_requirement?: GameModeIdentityRequirement.Raw | null; + verification?: GameModeVerificationConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.d.ts index 8488ea818f..ec048f5cba 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRegion.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { GameModeIdleLobbiesConfig } from "./GameModeIdleLobbiesConfig"; export declare const GameModeRegion: core.serialization.ObjectSchema; export declare namespace GameModeRegion { interface Raw { tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.d.ts index ea996df3c0..827e235794 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDocker.d.ts @@ -4,7 +4,8 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { NetworkMode } from "../../common/types/NetworkMode"; +import { GameModeRuntimeDockerPort } from "./GameModeRuntimeDockerPort"; export declare const GameModeRuntimeDocker: core.serialization.ObjectSchema; export declare namespace GameModeRuntimeDocker { interface Raw { @@ -14,7 +15,7 @@ export declare namespace GameModeRuntimeDocker { image_id?: string | null; args?: string[] | null; env?: Record | null; - network_mode?: cloud.version.matchmaker.NetworkMode.Raw | null; - ports?: Record | null; + network_mode?: NetworkMode.Raw | null; + ports?: Record | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.d.ts index 0e2fba8301..d865f67c0e 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/gameMode/types/GameModeRuntimeDockerPort.d.ts @@ -4,16 +4,18 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { PortRange } from "../../common/types/PortRange"; +import { PortProtocol } from "../../common/types/PortProtocol"; +import { ProxyKind } from "../../common/types/ProxyKind"; export declare const GameModeRuntimeDockerPort: core.serialization.ObjectSchema; export declare namespace GameModeRuntimeDockerPort { interface Raw { port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - protocol?: cloud.version.matchmaker.PortProtocol.Raw | null; - proxy?: cloud.version.matchmaker.ProxyKind.Raw | null; + port_range?: PortRange.Raw | null; + protocol?: PortProtocol.Raw | null; + proxy?: ProxyKind.Raw | null; dev_port?: number | null; - dev_port_range?: cloud.version.matchmaker.PortRange.Raw | null; - dev_protocol?: cloud.version.matchmaker.PortProtocol.Raw | null; + dev_port_range?: PortRange.Raw | null; + dev_protocol?: PortProtocol.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.d.ts index 21e3002340..c423115eba 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroup.d.ts @@ -4,15 +4,16 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRegion } from "./LobbyGroupRegion"; +import { LobbyGroupRuntime } from "./LobbyGroupRuntime"; export declare const LobbyGroup: core.serialization.ObjectSchema; export declare namespace LobbyGroup { interface Raw { name_id: string; - regions: cloud.version.matchmaker.LobbyGroupRegion.Raw[]; + regions: LobbyGroupRegion.Raw[]; max_players_normal: number; max_players_direct: number; max_players_party: number; - runtime: cloud.version.matchmaker.LobbyGroupRuntime.Raw; + runtime: LobbyGroupRuntime.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.d.ts index 94fb2ce4d6..c6b96aabed 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRegion.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupIdleLobbiesConfig } from "./LobbyGroupIdleLobbiesConfig"; export declare const LobbyGroupRegion: core.serialization.ObjectSchema; export declare namespace LobbyGroupRegion { interface Raw { region_id: string; tier_name_id: string; - idle_lobbies?: cloud.version.matchmaker.LobbyGroupIdleLobbiesConfig.Raw | null; + idle_lobbies?: LobbyGroupIdleLobbiesConfig.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.d.ts index 0cf46f8ea8..9198a44015 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntime.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRuntimeDocker } from "./LobbyGroupRuntimeDocker"; export declare const LobbyGroupRuntime: core.serialization.ObjectSchema; export declare namespace LobbyGroupRuntime { interface Raw { - docker?: cloud.version.matchmaker.LobbyGroupRuntimeDocker.Raw | null; + docker?: LobbyGroupRuntimeDocker.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.d.ts index b2e03f6883..e7886770e8 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDocker.d.ts @@ -4,14 +4,16 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { LobbyGroupRuntimeDockerEnvVar } from "./LobbyGroupRuntimeDockerEnvVar"; +import { NetworkMode } from "../../common/types/NetworkMode"; +import { LobbyGroupRuntimeDockerPort } from "./LobbyGroupRuntimeDockerPort"; export declare const LobbyGroupRuntimeDocker: core.serialization.ObjectSchema; export declare namespace LobbyGroupRuntimeDocker { interface Raw { build_id?: string | null; args: string[]; - env_vars: cloud.version.matchmaker.LobbyGroupRuntimeDockerEnvVar.Raw[]; - network_mode?: cloud.version.matchmaker.NetworkMode.Raw | null; - ports: cloud.version.matchmaker.LobbyGroupRuntimeDockerPort.Raw[]; + env_vars: LobbyGroupRuntimeDockerEnvVar.Raw[]; + network_mode?: NetworkMode.Raw | null; + ports: LobbyGroupRuntimeDockerPort.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.d.ts index 95efa0cf9f..477b4d03bb 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/resources/lobbyGroup/types/LobbyGroupRuntimeDockerPort.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../../../../../index"; import * as Rivet from "../../../../../../../../../../api/index"; import * as core from "../../../../../../../../../../core"; -import { cloud } from "../../../../../../../../index"; +import { PortRange } from "../../common/types/PortRange"; +import { PortProtocol } from "../../common/types/PortProtocol"; export declare const LobbyGroupRuntimeDockerPort: core.serialization.ObjectSchema; export declare namespace LobbyGroupRuntimeDockerPort { interface Raw { label: string; target_port?: number | null; - port_range?: cloud.version.matchmaker.PortRange.Raw | null; - proxy_protocol: cloud.version.matchmaker.PortProtocol.Raw; + port_range?: PortRange.Raw | null; + proxy_protocol: PortProtocol.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.d.ts index 52f275f562..30b81f1596 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/resources/matchmaker/types/Config.d.ts @@ -4,20 +4,25 @@ import * as serializers from "../../../../../../../index"; import * as Rivet from "../../../../../../../../api/index"; import * as core from "../../../../../../../../core"; -import { cloud } from "../../../../../../index"; +import { GameMode } from "../resources/gameMode/types/GameMode"; +import { Captcha } from "../resources/common/types/Captcha"; +import { GameModeRegion } from "../resources/gameMode/types/GameModeRegion"; +import { GameModeRuntimeDocker } from "../resources/gameMode/types/GameModeRuntimeDocker"; +import { GameModeIdleLobbiesConfig } from "../resources/gameMode/types/GameModeIdleLobbiesConfig"; +import { LobbyGroup } from "../resources/lobbyGroup/types/LobbyGroup"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { - game_modes?: Record | null; - captcha?: cloud.version.matchmaker.Captcha.Raw | null; + game_modes?: Record | null; + captcha?: Captcha.Raw | null; dev_hostname?: string | null; - regions?: Record | null; + regions?: Record | null; max_players?: number | null; max_players_direct?: number | null; max_players_party?: number | null; - docker?: cloud.version.matchmaker.GameModeRuntimeDocker.Raw | null; + docker?: GameModeRuntimeDocker.Raw | null; tier?: string | null; - idle_lobbies?: cloud.version.matchmaker.GameModeIdleLobbiesConfig.Raw | null; - lobby_groups?: cloud.version.matchmaker.LobbyGroup.Raw[] | null; + idle_lobbies?: GameModeIdleLobbiesConfig.Raw | null; + lobby_groups?: LobbyGroup.Raw[] | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Config.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Config.d.ts index fe008b9cb1..47b8fa4c5b 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Config.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Config.d.ts @@ -4,15 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { cloud } from "../../../../index"; +import { Config } from "../resources/engine/types/Config"; export declare const Config: core.serialization.ObjectSchema; export declare namespace Config { interface Raw { scripts?: Record | null; - engine?: cloud.version.engine.Config.Raw | null; - cdn?: cloud.version.cdn.Config.Raw | null; - matchmaker?: cloud.version.matchmaker.Config.Raw | null; - kv?: cloud.version.kv.Config.Raw | null; - identity?: cloud.version.identity.Config.Raw | null; + engine?: Config.Raw | null; + cdn?: Config.Raw | null; + matchmaker?: Config.Raw | null; + kv?: Config.Raw | null; + identity?: Config.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Full.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Full.d.ts index 6b5cc7fc0a..261bfd2ca9 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Full.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Full.d.ts @@ -4,13 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, cloud } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Config } from "./Config"; export declare const Full: core.serialization.ObjectSchema; export declare namespace Full { interface Raw { version_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; - config: cloud.version.Config.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; + config: Config.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Summary.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Summary.d.ts index 3f7322834c..f6b4ba276a 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Summary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/resources/version/types/Summary.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const Summary: core.serialization.ObjectSchema; export declare namespace Summary { interface Raw { version_id: string; - create_ts: common.Timestamp.Raw; - display_name: common.DisplayName.Raw; + create_ts: Timestamp.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapCaptcha.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapCaptcha.d.ts index 7c554bfdea..de80b7cfa6 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapCaptcha.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapCaptcha.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { cloud } from "../../index"; +import { BootstrapCaptchaTurnstile } from "./BootstrapCaptchaTurnstile"; export declare const BootstrapCaptcha: core.serialization.ObjectSchema; export declare namespace BootstrapCaptcha { interface Raw { - turnstile?: cloud.BootstrapCaptchaTurnstile.Raw | null; + turnstile?: BootstrapCaptchaTurnstile.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapResponse.d.ts b/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapResponse.d.ts index 1c947f84ff..426acffb20 100644 --- a/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/cloud/types/BootstrapResponse.d.ts @@ -4,16 +4,21 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { cloud } from "../../index"; +import { BootstrapCluster } from "./BootstrapCluster"; +import { BootstrapAccess } from "./BootstrapAccess"; +import { BootstrapDomains } from "./BootstrapDomains"; +import { BootstrapOrigins } from "./BootstrapOrigins"; +import { BootstrapCaptcha } from "./BootstrapCaptcha"; +import { BootstrapLoginMethods } from "./BootstrapLoginMethods"; export declare const BootstrapResponse: core.serialization.ObjectSchema; export declare namespace BootstrapResponse { interface Raw { - cluster: cloud.BootstrapCluster.Raw; - access: cloud.BootstrapAccess.Raw; - domains: cloud.BootstrapDomains.Raw; - origins: cloud.BootstrapOrigins.Raw; - captcha: cloud.BootstrapCaptcha.Raw; - login_methods: cloud.BootstrapLoginMethods.Raw; + cluster: BootstrapCluster.Raw; + access: BootstrapAccess.Raw; + domains: BootstrapDomains.Raw; + origins: BootstrapOrigins.Raw; + captcha: BootstrapCaptcha.Raw; + login_methods: BootstrapLoginMethods.Raw; deploy_hash: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/common/types/ErrorBody.d.ts b/sdks/full/typescript/types/serialization/resources/common/types/ErrorBody.d.ts index 36f1711853..492b1eb1b9 100644 --- a/sdks/full/typescript/types/serialization/resources/common/types/ErrorBody.d.ts +++ b/sdks/full/typescript/types/serialization/resources/common/types/ErrorBody.d.ts @@ -4,7 +4,7 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common } from "../../index"; +import { ErrorMetadata } from "./ErrorMetadata"; export declare const ErrorBody: core.serialization.ObjectSchema; export declare namespace ErrorBody { interface Raw { @@ -12,6 +12,6 @@ export declare namespace ErrorBody { message: string; ray_id: string; documentation?: string | null; - metadata?: (common.ErrorMetadata.Raw | undefined) | null; + metadata?: (ErrorMetadata.Raw | undefined) | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Handle.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Handle.d.ts index 9c6f87688d..1d36656538 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Handle.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Handle.d.ts @@ -4,13 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const Handle: core.serialization.ObjectSchema; export declare namespace Handle { interface Raw { game_id: string; - name_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; + name_id: Identifier.Raw; + display_name: DisplayName.Raw; logo_url?: string | null; banner_url?: string | null; } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/LeaderboardCategory.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/LeaderboardCategory.d.ts index b4161fe3a3..61dabb91ed 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/LeaderboardCategory.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/LeaderboardCategory.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const LeaderboardCategory: core.serialization.ObjectSchema; export declare namespace LeaderboardCategory { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/PlatformLink.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/PlatformLink.d.ts index 6ad42cd7ab..03a270397e 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/PlatformLink.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/PlatformLink.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const PlatformLink: core.serialization.ObjectSchema; export declare namespace PlatformLink { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; url: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Profile.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Profile.d.ts index 334ff48ba4..4c4cf4cbb3 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Profile.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Profile.d.ts @@ -4,22 +4,25 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, group, game } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Summary } from "../../../../group/resources/common/types/Summary"; +import { PlatformLink } from "./PlatformLink"; +import { LeaderboardCategory } from "./LeaderboardCategory"; export declare const Profile: core.serialization.ObjectSchema; export declare namespace Profile { interface Raw { game_id: string; name_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; logo_url?: string | null; banner_url?: string | null; url: string; - developer: group.Summary.Raw; + developer: Summary.Raw; tags: string[]; description: string; - platforms: game.PlatformLink.Raw[]; - recommended_groups: group.Summary.Raw[]; - identity_leaderboard_categories: game.LeaderboardCategory.Raw[]; - group_leaderboard_categories: game.LeaderboardCategory.Raw[]; + platforms: PlatformLink.Raw[]; + recommended_groups: Summary.Raw[]; + identity_leaderboard_categories: LeaderboardCategory.Raw[]; + group_leaderboard_categories: LeaderboardCategory.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Stat.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Stat.d.ts index ef2c705f5e..b844a92c78 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Stat.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Stat.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game } from "../../../../index"; +import { StatConfig } from "./StatConfig"; export declare const Stat: core.serialization.ObjectSchema; export declare namespace Stat { interface Raw { - config: game.StatConfig.Raw; + config: StatConfig.Raw; overall_value: number; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatConfig.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatConfig.d.ts index dbb252ba28..8465c33741 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatConfig.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatConfig.d.ts @@ -4,17 +4,20 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game, common } from "../../../../index"; +import { StatFormatMethod } from "./StatFormatMethod"; +import { StatAggregationMethod } from "./StatAggregationMethod"; +import { StatSortingMethod } from "./StatSortingMethod"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const StatConfig: core.serialization.ObjectSchema; export declare namespace StatConfig { interface Raw { record_id: string; icon_id: string; - format: game.StatFormatMethod.Raw; - aggregation: game.StatAggregationMethod.Raw; - sorting: game.StatSortingMethod.Raw; + format: StatFormatMethod.Raw; + aggregation: StatAggregationMethod.Raw; + sorting: StatSortingMethod.Raw; priority: number; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; postfix_singular?: string | null; postfix_plural?: string | null; prefix_singular?: string | null; diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatSummary.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatSummary.d.ts index 0eace48190..1c35749d77 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatSummary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/StatSummary.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game } from "../../../../index"; +import { Handle } from "./Handle"; +import { Stat } from "./Stat"; export declare const StatSummary: core.serialization.ObjectSchema; export declare namespace StatSummary { interface Raw { - game: game.Handle.Raw; - stats: game.Stat.Raw[]; + game: Handle.Raw; + stats: Stat.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Summary.d.ts b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Summary.d.ts index 6e36e95553..907f5e61ae 100644 --- a/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Summary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/game/resources/common/types/Summary.d.ts @@ -4,17 +4,19 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, group } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Handle } from "../../../../group/resources/common/types/Handle"; export declare const Summary: core.serialization.ObjectSchema; export declare namespace Summary { interface Raw { game_id: string; - name_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; + name_id: Identifier.Raw; + display_name: DisplayName.Raw; logo_url?: string | null; banner_url?: string | null; url: string; - developer: group.Handle.Raw; + developer: Handle.Raw; total_player_count: number; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/BannedIdentity.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/BannedIdentity.d.ts index 6dbabe0425..cd91be20c4 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/BannedIdentity.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/BannedIdentity.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity, common } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const BannedIdentity: core.serialization.ObjectSchema; export declare namespace BannedIdentity { interface Raw { - identity: identity.Handle.Raw; - ban_ts: common.Timestamp.Raw; + identity: Handle.Raw; + ban_ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Handle.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Handle.d.ts index 5df26a58c2..2eb4a46edc 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Handle.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Handle.d.ts @@ -4,14 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, group } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { ExternalLinks } from "./ExternalLinks"; export declare const Handle: core.serialization.ObjectSchema; export declare namespace Handle { interface Raw { group_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; avatar_url?: string | null; - external: group.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_developer?: boolean | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/JoinRequest.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/JoinRequest.d.ts index f72bef9df0..c38e330334 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/JoinRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/JoinRequest.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity, common } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; +import { Timestamp } from "../../../../common/types/Timestamp"; export declare const JoinRequest: core.serialization.ObjectSchema; export declare namespace JoinRequest { interface Raw { - identity: identity.Handle.Raw; - ts: common.Timestamp.Raw; + identity: Handle.Raw; + ts: Timestamp.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Member.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Member.d.ts index 7d2ba80c60..9f06fd6ec5 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Member.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Member.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity } from "../../../../index"; +import { Handle } from "../../../../identity/resources/common/types/Handle"; export declare const Member: core.serialization.ObjectSchema; export declare namespace Member { interface Raw { - identity: identity.Handle.Raw; + identity: Handle.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Profile.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Profile.d.ts index 5c40a04984..422a4ed511 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Profile.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Profile.d.ts @@ -4,21 +4,25 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, group } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { ExternalLinks } from "./ExternalLinks"; +import { Publicity } from "./Publicity"; +import { Member } from "./Member"; +import { JoinRequest } from "./JoinRequest"; export declare const Profile: core.serialization.ObjectSchema; export declare namespace Profile { interface Raw { group_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; avatar_url?: string | null; - external: group.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_developer?: boolean | null; bio: string; is_current_identity_member?: boolean | null; - publicity: group.Publicity.Raw; + publicity: Publicity.Raw; member_count?: number | null; - members: group.Member.Raw[]; - join_requests: group.JoinRequest.Raw[]; + members: Member.Raw[]; + join_requests: JoinRequest.Raw[]; is_current_identity_requesting_join?: boolean | null; owner_identity_id: string; } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Summary.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Summary.d.ts index de4d4e2eba..a6b5789d56 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Summary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/common/types/Summary.d.ts @@ -4,18 +4,21 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, group } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { ExternalLinks } from "./ExternalLinks"; +import { Bio } from "../../../../common/types/Bio"; +import { Publicity } from "./Publicity"; export declare const Summary: core.serialization.ObjectSchema; export declare namespace Summary { interface Raw { group_id: string; - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; avatar_url?: string | null; - external: group.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_developer: boolean; - bio: common.Bio.Raw; + bio: Bio.Raw; is_current_identity_member: boolean; - publicity: group.Publicity.Raw; + publicity: Publicity.Raw; member_count: number; owner_identity_id: string; } diff --git a/sdks/full/typescript/types/serialization/resources/group/resources/invites/types/GetInviteResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/resources/invites/types/GetInviteResponse.d.ts index 83cf942298..ca5235c2aa 100644 --- a/sdks/full/typescript/types/serialization/resources/group/resources/invites/types/GetInviteResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/resources/invites/types/GetInviteResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { group } from "../../../../index"; +import { Handle } from "../../common/types/Handle"; export declare const GetInviteResponse: core.serialization.ObjectSchema; export declare namespace GetInviteResponse { interface Raw { - group: group.Handle.Raw; + group: Handle.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/CreateRequest.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/CreateRequest.d.ts index a68be1740f..ae8300a17b 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/CreateRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/CreateRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; export declare const CreateRequest: core.serialization.ObjectSchema; export declare namespace CreateRequest { interface Raw { - display_name: common.DisplayName.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/GetBansResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/GetBansResponse.d.ts index ccdbec1f4f..7071e06508 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/GetBansResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/GetBansResponse.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group, common } from "../../index"; +import { BannedIdentity } from "../resources/common/types/BannedIdentity"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetBansResponse: core.serialization.ObjectSchema; export declare namespace GetBansResponse { interface Raw { - banned_identities: group.BannedIdentity.Raw[]; + banned_identities: BannedIdentity.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/GetJoinRequestsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/GetJoinRequestsResponse.d.ts index db878dd3d2..966b028e19 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/GetJoinRequestsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/GetJoinRequestsResponse.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group, common } from "../../index"; +import { JoinRequest } from "../resources/common/types/JoinRequest"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetJoinRequestsResponse: core.serialization.ObjectSchema; export declare namespace GetJoinRequestsResponse { interface Raw { - join_requests: group.JoinRequest.Raw[]; + join_requests: JoinRequest.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/GetMembersResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/GetMembersResponse.d.ts index dc31ef285e..f25945f2e7 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/GetMembersResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/GetMembersResponse.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group, common } from "../../index"; +import { Member } from "../resources/common/types/Member"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetMembersResponse: core.serialization.ObjectSchema; export declare namespace GetMembersResponse { interface Raw { - members: group.Member.Raw[]; + members: Member.Raw[]; anchor?: string | null; - watch: common.WatchResponse.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/GetProfileResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/GetProfileResponse.d.ts index bb98b2f484..17454eac5e 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/GetProfileResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/GetProfileResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group, common } from "../../index"; +import { Profile } from "../resources/common/types/Profile"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetProfileResponse: core.serialization.ObjectSchema; export declare namespace GetProfileResponse { interface Raw { - group: group.Profile.Raw; - watch: common.WatchResponse.Raw; + group: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/GetSummaryResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/GetSummaryResponse.d.ts index a6929920e5..1ffe5dc82b 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/GetSummaryResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/GetSummaryResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; export declare const GetSummaryResponse: core.serialization.ObjectSchema; export declare namespace GetSummaryResponse { interface Raw { - group: group.Summary.Raw; + group: Summary.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/ListSuggestedResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/ListSuggestedResponse.d.ts index ae7eb066cf..a35376defb 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/ListSuggestedResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/ListSuggestedResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { group, common } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const ListSuggestedResponse: core.serialization.ObjectSchema; export declare namespace ListSuggestedResponse { interface Raw { - groups: group.Summary.Raw[]; - watch: common.WatchResponse.Raw; + groups: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/PrepareAvatarUploadResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/PrepareAvatarUploadResponse.d.ts index 34e71e63b8..b62c065209 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/PrepareAvatarUploadResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/PrepareAvatarUploadResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { upload } from "../../index"; +import { PresignedRequest } from "../../upload/resources/common/types/PresignedRequest"; export declare const PrepareAvatarUploadResponse: core.serialization.ObjectSchema; export declare namespace PrepareAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/UpdateProfileRequest.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/UpdateProfileRequest.d.ts index d9d53dfa8a..7939ca814e 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/UpdateProfileRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/UpdateProfileRequest.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common, group } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; +import { Publicity } from "../resources/common/types/Publicity"; export declare const UpdateProfileRequest: core.serialization.ObjectSchema; export declare namespace UpdateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; + display_name?: DisplayName.Raw | null; bio?: string | null; - publicity?: group.Publicity.Raw | null; + publicity?: Publicity.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileRequest.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileRequest.d.ts index 7026e8738d..6e7e16fb17 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileRequest.d.ts @@ -4,12 +4,13 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common, group } from "../../index"; +import { DisplayName } from "../../common/types/DisplayName"; +import { Publicity } from "../resources/common/types/Publicity"; export declare const ValidateProfileRequest: core.serialization.ObjectSchema; export declare namespace ValidateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - bio?: common.DisplayName.Raw | null; - publicity?: group.Publicity.Raw | null; + display_name?: DisplayName.Raw | null; + bio?: DisplayName.Raw | null; + publicity?: Publicity.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileResponse.d.ts b/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileResponse.d.ts index eef359ad34..c0b2cf519c 100644 --- a/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/group/types/ValidateProfileResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common } from "../../index"; +import { ValidationError } from "../../common/types/ValidationError"; export declare const ValidateProfileResponse: core.serialization.ObjectSchema; export declare namespace ValidateProfileResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetGameActivityRequest.d.ts b/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetGameActivityRequest.d.ts index 851381f46b..1757475f51 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetGameActivityRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetGameActivityRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { identity } from "../../../index"; +import { UpdateGameActivity } from "../../resources/common/types/UpdateGameActivity"; export declare const SetGameActivityRequest: core.serialization.Schema; export declare namespace SetGameActivityRequest { interface Raw { - game_activity: identity.UpdateGameActivity.Raw; + game_activity: UpdateGameActivity.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetupRequest.d.ts b/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetupRequest.d.ts index 8ba73aedaf..b51a1432c0 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetupRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/client/requests/SetupRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { common } from "../../../index"; +import { Jwt } from "../../../common/types/Jwt"; export declare const SetupRequest: core.serialization.Schema; export declare namespace SetupRequest { interface Raw { - existing_identity_token?: common.Jwt.Raw | null; + existing_identity_token?: Jwt.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateProfileRequest.d.ts b/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateProfileRequest.d.ts index 82bb4e8589..9fa9fc36fa 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateProfileRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateProfileRequest.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { common } from "../../../index"; +import { DisplayName } from "../../../common/types/DisplayName"; +import { AccountNumber } from "../../../common/types/AccountNumber"; +import { Bio } from "../../../common/types/Bio"; export declare const UpdateProfileRequest: core.serialization.Schema; export declare namespace UpdateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - account_number?: common.AccountNumber.Raw | null; - bio?: common.Bio.Raw | null; + display_name?: DisplayName.Raw | null; + account_number?: AccountNumber.Raw | null; + bio?: Bio.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateStatusRequest.d.ts b/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateStatusRequest.d.ts index 0376b4356a..374aef253d 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateStatusRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/client/requests/UpdateStatusRequest.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { identity } from "../../../index"; +import { Status } from "../../resources/common/types/Status"; export declare const UpdateStatusRequest: core.serialization.Schema; export declare namespace UpdateStatusRequest { interface Raw { - status: identity.Status.Raw; + status: Status.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/client/requests/ValidateProfileRequest.d.ts b/sdks/full/typescript/types/serialization/resources/identity/client/requests/ValidateProfileRequest.d.ts index 0f1fe7c6f7..ed286bdd6a 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/client/requests/ValidateProfileRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/client/requests/ValidateProfileRequest.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../index"; import * as Rivet from "../../../../../api/index"; import * as core from "../../../../../core"; -import { common } from "../../../index"; +import { DisplayName } from "../../../common/types/DisplayName"; +import { AccountNumber } from "../../../common/types/AccountNumber"; +import { Bio } from "../../../common/types/Bio"; export declare const ValidateProfileRequest: core.serialization.Schema; export declare namespace ValidateProfileRequest { interface Raw { - display_name?: common.DisplayName.Raw | null; - account_number?: common.AccountNumber.Raw | null; - bio?: common.Bio.Raw | null; + display_name?: DisplayName.Raw | null; + account_number?: AccountNumber.Raw | null; + bio?: Bio.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.d.ts index d2e022bceb..4531b138ea 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/activities/types/ListActivitiesResponse.d.ts @@ -4,14 +4,16 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity, game, group, common } from "../../../../index"; +import { Handle } from "../../common/types/Handle"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const ListActivitiesResponse: core.serialization.ObjectSchema; export declare namespace ListActivitiesResponse { interface Raw { - identities: identity.Handle.Raw[]; - games: game.Summary.Raw[]; - suggested_groups: group.Summary.Raw[]; - suggested_players: identity.Handle.Raw[]; - watch: common.WatchResponse.Raw; + identities: Handle.Raw[]; + games: Summary.Raw[]; + suggested_groups: Summary.Raw[]; + suggested_players: Handle.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/EmailLinkedAccount.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/EmailLinkedAccount.d.ts index 2ef7f5978b..48839190d1 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/EmailLinkedAccount.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/EmailLinkedAccount.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Email } from "../../../../common/types/Email"; export declare const EmailLinkedAccount: core.serialization.ObjectSchema; export declare namespace EmailLinkedAccount { interface Raw { - email: common.Email.Raw; + email: Email.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GameActivity.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GameActivity.d.ts index 0231e2e64c..60679de4fa 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GameActivity.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GameActivity.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game } from "../../../../index"; +import { Handle } from "../../../../game/resources/common/types/Handle"; export declare const GameActivity: core.serialization.ObjectSchema; export declare namespace GameActivity { interface Raw { - game: game.Handle.Raw; + game: Handle.Raw; message: string; public_metadata?: unknown | null; mutual_metadata?: unknown | null; diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEvent.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEvent.d.ts index 74262f0d7f..771f568a6a 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEvent.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEvent.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, identity } from "../../../../index"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { GlobalEventKind } from "./GlobalEventKind"; +import { GlobalEventNotification } from "./GlobalEventNotification"; export declare const GlobalEvent: core.serialization.ObjectSchema; export declare namespace GlobalEvent { interface Raw { - ts: common.Timestamp.Raw; - kind: identity.GlobalEventKind.Raw; - notification?: identity.GlobalEventNotification.Raw | null; + ts: Timestamp.Raw; + kind: GlobalEventKind.Raw; + notification?: GlobalEventNotification.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.d.ts index 2d7563ce13..eaf3f2e0a2 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventIdentityUpdate.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity } from "../../../../index"; +import { Profile } from "./Profile"; export declare const GlobalEventIdentityUpdate: core.serialization.ObjectSchema; export declare namespace GlobalEventIdentityUpdate { interface Raw { - identity: identity.Profile.Raw; + identity: Profile.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventKind.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventKind.d.ts index cc79f68208..654dd78d21 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventKind.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/GlobalEventKind.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity } from "../../../../index"; +import { GlobalEventIdentityUpdate } from "./GlobalEventIdentityUpdate"; export declare const GlobalEventKind: core.serialization.ObjectSchema; export declare namespace GlobalEventKind { interface Raw { - identity_update?: identity.GlobalEventIdentityUpdate.Raw | null; + identity_update?: GlobalEventIdentityUpdate.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Group.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Group.d.ts index 2232e87ec8..be0b33649c 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Group.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Group.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { group } from "../../../../index"; +import { Handle } from "../../../../group/resources/common/types/Handle"; export declare const Group: core.serialization.ObjectSchema; export declare namespace Group { interface Raw { - group: group.Handle.Raw; + group: Handle.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Handle.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Handle.d.ts index 624b2bef75..41325fdf8c 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Handle.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Handle.d.ts @@ -4,15 +4,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, identity } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; export declare const Handle: core.serialization.ObjectSchema; export declare namespace Handle { interface Raw { identity_id: string; - display_name: common.DisplayName.Raw; - account_number: common.AccountNumber.Raw; + display_name: DisplayName.Raw; + account_number: AccountNumber.Raw; avatar_url: string; is_registered: boolean; - external: identity.ExternalLinks.Raw; + external: ExternalLinks.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/LinkedAccount.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/LinkedAccount.d.ts index 0136ceb180..4ebe261aa3 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/LinkedAccount.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/LinkedAccount.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity } from "../../../../index"; +import { EmailLinkedAccount } from "./EmailLinkedAccount"; export declare const LinkedAccount: core.serialization.ObjectSchema; export declare namespace LinkedAccount { interface Raw { - email?: identity.EmailLinkedAccount.Raw | null; + email?: EmailLinkedAccount.Raw | null; default_user?: boolean | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Profile.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Profile.d.ts index efc042940d..edb74222b1 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Profile.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Profile.d.ts @@ -4,29 +4,37 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, identity, game } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; +import { DevState } from "./DevState"; +import { Timestamp } from "../../../../common/types/Timestamp"; +import { Bio } from "../../../../common/types/Bio"; +import { LinkedAccount } from "./LinkedAccount"; +import { Group } from "./Group"; +import { StatSummary } from "../../../../game/resources/common/types/StatSummary"; export declare const Profile: core.serialization.ObjectSchema; export declare namespace Profile { interface Raw { identity_id: string; - display_name: common.DisplayName.Raw; - account_number: common.AccountNumber.Raw; + display_name: DisplayName.Raw; + account_number: AccountNumber.Raw; avatar_url: string; is_registered: boolean; - external: identity.ExternalLinks.Raw; + external: ExternalLinks.Raw; is_admin: boolean; is_game_linked?: boolean | null; - dev_state?: identity.DevState.Raw | null; + dev_state?: DevState.Raw | null; follower_count: number; following_count: number; following: boolean; is_following_me: boolean; is_mutual_following: boolean; - join_ts: common.Timestamp.Raw; - bio: common.Bio.Raw; - linked_accounts: identity.LinkedAccount.Raw[]; - groups: identity.Group.Raw[]; - games: game.StatSummary.Raw[]; + join_ts: Timestamp.Raw; + bio: Bio.Raw; + linked_accounts: LinkedAccount.Raw[]; + groups: Group.Raw[]; + games: StatSummary.Raw[]; awaiting_deletion?: boolean | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Summary.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Summary.d.ts index b6500e3769..b43ae0c2e5 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Summary.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/common/types/Summary.d.ts @@ -4,16 +4,18 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, identity } from "../../../../index"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { AccountNumber } from "../../../../common/types/AccountNumber"; +import { ExternalLinks } from "./ExternalLinks"; export declare const Summary: core.serialization.ObjectSchema; export declare namespace Summary { interface Raw { identity_id: string; - display_name: common.DisplayName.Raw; - account_number: common.AccountNumber.Raw; + display_name: DisplayName.Raw; + account_number: AccountNumber.Raw; avatar_url: string; is_registered: boolean; - external: identity.ExternalLinks.Raw; + external: ExternalLinks.Raw; following: boolean; is_following_me: boolean; is_mutual_following: boolean; diff --git a/sdks/full/typescript/types/serialization/resources/identity/resources/events/types/WatchEventsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/resources/events/types/WatchEventsResponse.d.ts index 11d7f23cc1..7eb5db4105 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/resources/events/types/WatchEventsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/resources/events/types/WatchEventsResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { identity, common } from "../../../../index"; +import { GlobalEvent } from "../../common/types/GlobalEvent"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const WatchEventsResponse: core.serialization.ObjectSchema; export declare namespace WatchEventsResponse { interface Raw { - events: identity.GlobalEvent.Raw[]; - watch: common.WatchResponse.Raw; + events: GlobalEvent.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/GetHandlesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/GetHandlesResponse.d.ts index 9e922a9b1b..427de8166e 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/GetHandlesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/GetHandlesResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { identity, common } from "../../index"; +import { Handle } from "../resources/common/types/Handle"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetHandlesResponse: core.serialization.ObjectSchema; export declare namespace GetHandlesResponse { interface Raw { - identities: identity.Handle.Raw[]; - watch: common.WatchResponse.Raw; + identities: Handle.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/GetProfileResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/GetProfileResponse.d.ts index a14b53d8a2..5627c9d4a2 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/GetProfileResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/GetProfileResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { identity, common } from "../../index"; +import { Profile } from "../resources/common/types/Profile"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetProfileResponse: core.serialization.ObjectSchema; export declare namespace GetProfileResponse { interface Raw { - identity: identity.Profile.Raw; - watch: common.WatchResponse.Raw; + identity: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/GetSummariesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/GetSummariesResponse.d.ts index a760bf4318..1ad3c7cfe1 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/GetSummariesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/GetSummariesResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { identity, common } from "../../index"; +import { Summary } from "../resources/common/types/Summary"; +import { WatchResponse } from "../../common/types/WatchResponse"; export declare const GetSummariesResponse: core.serialization.ObjectSchema; export declare namespace GetSummariesResponse { interface Raw { - identities: identity.Summary.Raw[]; - watch: common.WatchResponse.Raw; + identities: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/PrepareAvatarUploadResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/PrepareAvatarUploadResponse.d.ts index a1fa12741f..cc861467b2 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/PrepareAvatarUploadResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/PrepareAvatarUploadResponse.d.ts @@ -4,11 +4,11 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { upload } from "../../index"; +import { PresignedRequest } from "../../upload/resources/common/types/PresignedRequest"; export declare const PrepareAvatarUploadResponse: core.serialization.ObjectSchema; export declare namespace PrepareAvatarUploadResponse { interface Raw { upload_id: string; - presigned_request: upload.PresignedRequest.Raw; + presigned_request: PresignedRequest.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/SetupResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/SetupResponse.d.ts index 139c9f045d..001532d9a2 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/SetupResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/SetupResponse.d.ts @@ -4,13 +4,15 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common, identity } from "../../index"; +import { Jwt } from "../../common/types/Jwt"; +import { Timestamp } from "../../common/types/Timestamp"; +import { Profile } from "../resources/common/types/Profile"; export declare const SetupResponse: core.serialization.ObjectSchema; export declare namespace SetupResponse { interface Raw { - identity_token: common.Jwt.Raw; - identity_token_expire_ts: common.Timestamp.Raw; - identity: identity.Profile.Raw; + identity_token: Jwt.Raw; + identity_token_expire_ts: Timestamp.Raw; + identity: Profile.Raw; game_id: string; } } diff --git a/sdks/full/typescript/types/serialization/resources/identity/types/ValidateProfileResponse.d.ts b/sdks/full/typescript/types/serialization/resources/identity/types/ValidateProfileResponse.d.ts index 9b19b63015..63df4d6efa 100644 --- a/sdks/full/typescript/types/serialization/resources/identity/types/ValidateProfileResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/identity/types/ValidateProfileResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common } from "../../index"; +import { ValidationError } from "../../common/types/ValidationError"; export declare const ValidateProfileResponse: core.serialization.ObjectSchema; export declare namespace ValidateProfileResponse { interface Raw { - errors: common.ValidationError.Raw[]; + errors: ValidationError.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/GameModeInfo.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/GameModeInfo.d.ts index 76a76bb6d7..dcd05f7da4 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/GameModeInfo.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/GameModeInfo.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; export declare const GameModeInfo: core.serialization.ObjectSchema; export declare namespace GameModeInfo { interface Raw { - game_mode_id: common.Identifier.Raw; + game_mode_id: Identifier.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinLobby.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinLobby.d.ts index 023421438f..aca7a301dd 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinLobby.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinLobby.d.ts @@ -4,13 +4,15 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { JoinRegion } from "./JoinRegion"; +import { JoinPort } from "./JoinPort"; +import { JoinPlayer } from "./JoinPlayer"; export declare const JoinLobby: core.serialization.ObjectSchema; export declare namespace JoinLobby { interface Raw { lobby_id: string; - region: matchmaker.JoinRegion.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + region: JoinRegion.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPlayer.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPlayer.d.ts index 707e160f28..778f78c94c 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPlayer.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPlayer.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Jwt } from "../../../../common/types/Jwt"; export declare const JoinPlayer: core.serialization.ObjectSchema; export declare namespace JoinPlayer { interface Raw { - token: common.Jwt.Raw; + token: Jwt.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPort.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPort.d.ts index ca313c8fc1..19bcfabee7 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPort.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinPort.d.ts @@ -4,14 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { JoinPortRange } from "./JoinPortRange"; export declare const JoinPort: core.serialization.ObjectSchema; export declare namespace JoinPort { interface Raw { host?: string | null; hostname: string; port?: number | null; - port_range?: matchmaker.JoinPortRange.Raw | null; + port_range?: JoinPortRange.Raw | null; is_tls: boolean; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinRegion.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinRegion.d.ts index 4b1458ffbc..9acb506083 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinRegion.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/JoinRegion.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; export declare const JoinRegion: core.serialization.ObjectSchema; export declare namespace JoinRegion { interface Raw { - region_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; + region_id: Identifier.Raw; + display_name: DisplayName.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/RegionInfo.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/RegionInfo.d.ts index 12f821e169..f056ecbdcd 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/RegionInfo.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/common/types/RegionInfo.d.ts @@ -4,14 +4,17 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, geo } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { DisplayName } from "../../../../common/types/DisplayName"; +import { Coord } from "../../../../geo/resources/common/types/Coord"; +import { Distance } from "../../../../geo/resources/common/types/Distance"; export declare const RegionInfo: core.serialization.ObjectSchema; export declare namespace RegionInfo { interface Raw { - region_id: common.Identifier.Raw; - provider_display_name: common.DisplayName.Raw; - region_display_name: common.DisplayName.Raw; - datacenter_coord: geo.Coord.Raw; - datacenter_distance_from_client: geo.Distance.Raw; + region_id: Identifier.Raw; + provider_display_name: DisplayName.Raw; + region_display_name: DisplayName.Raw; + datacenter_coord: Coord.Raw; + datacenter_distance_from_client: Distance.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts index 2cf41129a8..4f38d42518 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.d.ts @@ -4,17 +4,18 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { matchmaker, captcha } from "../../../../../index"; +import { CustomLobbyPublicity } from "../../../common/types/CustomLobbyPublicity"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export declare const CreateLobbyRequest: core.serialization.Schema; export declare namespace CreateLobbyRequest { interface Raw { game_mode: string; region?: string | null; - publicity?: matchmaker.CustomLobbyPublicity.Raw | null; + publicity?: CustomLobbyPublicity.Raw | null; tags?: Record | null; max_players?: number | null; lobby_config?: unknown | null; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.d.ts index cd9a3b6b10..6cdc79804a 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.d.ts @@ -4,7 +4,7 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { captcha } from "../../../../../index"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export declare const FindLobbyRequest: core.serialization.Schema>; export declare namespace FindLobbyRequest { interface Raw { @@ -13,7 +13,7 @@ export declare namespace FindLobbyRequest { prevent_auto_create_lobby?: boolean | null; tags?: Record | null; max_players?: number | null; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.d.ts index 2588d4ea27..05746bb9cb 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.d.ts @@ -4,12 +4,12 @@ import * as serializers from "../../../../../../index"; import * as Rivet from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; -import { captcha } from "../../../../../index"; +import { Config } from "../../../../../captcha/resources/config/types/Config"; export declare const JoinLobbyRequest: core.serialization.Schema; export declare namespace JoinLobbyRequest { interface Raw { lobby_id: string; - captcha?: captcha.Config.Raw | null; + captcha?: Config.Raw | null; verification_data?: unknown | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.d.ts index 8313467be8..b44f2731ae 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export declare const CreateLobbyResponse: core.serialization.ObjectSchema; export declare namespace CreateLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.d.ts index ae6de316d7..0b8aa04aeb 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export declare const FindLobbyResponse: core.serialization.ObjectSchema; export declare namespace FindLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.d.ts index f06a6815be..5fc8b8d3e5 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { JoinLobby } from "../../common/types/JoinLobby"; +import { JoinPort } from "../../common/types/JoinPort"; +import { JoinPlayer } from "../../common/types/JoinPlayer"; export declare const JoinLobbyResponse: core.serialization.ObjectSchema; export declare namespace JoinLobbyResponse { interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; + lobby: JoinLobby.Raw; + ports: Record; + player: JoinPlayer.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.d.ts index 4cd05d8622..8871408a90 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.d.ts @@ -4,12 +4,14 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { GameModeInfo } from "../../common/types/GameModeInfo"; +import { RegionInfo } from "../../common/types/RegionInfo"; +import { LobbyInfo } from "../../common/types/LobbyInfo"; export declare const ListLobbiesResponse: core.serialization.ObjectSchema; export declare namespace ListLobbiesResponse { interface Raw { - game_modes: matchmaker.GameModeInfo.Raw[]; - regions: matchmaker.RegionInfo.Raw[]; - lobbies: matchmaker.LobbyInfo.Raw[]; + game_modes: GameModeInfo.Raw[]; + regions: RegionInfo.Raw[]; + lobbies: LobbyInfo.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.d.ts index fb12a8e1a6..972434e4e7 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, matchmaker } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { RegionStatistics } from "./RegionStatistics"; export declare const GameModeStatistics: core.serialization.ObjectSchema; export declare namespace GameModeStatistics { interface Raw { player_count: number; - regions: Record; + regions: Record; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.d.ts index 2af8e53566..65016a30d9 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { common, matchmaker } from "../../../../index"; +import { Identifier } from "../../../../common/types/Identifier"; +import { GameModeStatistics } from "./GameModeStatistics"; export declare const GetStatisticsResponse: core.serialization.ObjectSchema; export declare namespace GetStatisticsResponse { interface Raw { player_count: number; - game_modes: Record; + game_modes: Record; } } diff --git a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.d.ts b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.d.ts index 0c79fa92a3..991efbf49f 100644 --- a/sdks/full/typescript/types/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { matchmaker } from "../../../../index"; +import { RegionInfo } from "../../common/types/RegionInfo"; export declare const ListRegionsResponse: core.serialization.ObjectSchema; export declare namespace ListRegionsResponse { interface Raw { - regions: matchmaker.RegionInfo.Raw[]; + regions: RegionInfo.Raw[]; } } diff --git a/sdks/full/typescript/types/serialization/resources/portal/resources/common/types/NotificationRegisterService.d.ts b/sdks/full/typescript/types/serialization/resources/portal/resources/common/types/NotificationRegisterService.d.ts index 0f6afbfe94..4293483e51 100644 --- a/sdks/full/typescript/types/serialization/resources/portal/resources/common/types/NotificationRegisterService.d.ts +++ b/sdks/full/typescript/types/serialization/resources/portal/resources/common/types/NotificationRegisterService.d.ts @@ -4,10 +4,10 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { portal } from "../../../../index"; +import { NotificationRegisterFirebaseService } from "./NotificationRegisterFirebaseService"; export declare const NotificationRegisterService: core.serialization.ObjectSchema; export declare namespace NotificationRegisterService { interface Raw { - firebase?: portal.NotificationRegisterFirebaseService.Raw | null; + firebase?: NotificationRegisterFirebaseService.Raw | null; } } diff --git a/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetGameProfileResponse.d.ts b/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetGameProfileResponse.d.ts index 78165a0324..bf0cb02019 100644 --- a/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetGameProfileResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetGameProfileResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game, common } from "../../../../index"; +import { Profile } from "../../../../game/resources/common/types/Profile"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const GetGameProfileResponse: core.serialization.ObjectSchema; export declare namespace GetGameProfileResponse { interface Raw { - game: game.Profile.Raw; - watch: common.WatchResponse.Raw; + game: Profile.Raw; + watch: WatchResponse.Raw; } } diff --git a/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.d.ts b/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.d.ts index b00943d5f5..6bc18f50ea 100644 --- a/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.d.ts +++ b/sdks/full/typescript/types/serialization/resources/portal/resources/games/types/GetSuggestedGamesResponse.d.ts @@ -4,11 +4,12 @@ import * as serializers from "../../../../../index"; import * as Rivet from "../../../../../../api/index"; import * as core from "../../../../../../core"; -import { game, common } from "../../../../index"; +import { Summary } from "../../../../game/resources/common/types/Summary"; +import { WatchResponse } from "../../../../common/types/WatchResponse"; export declare const GetSuggestedGamesResponse: core.serialization.ObjectSchema; export declare namespace GetSuggestedGamesResponse { interface Raw { - games: game.Summary.Raw[]; - watch: common.WatchResponse.Raw; + games: Summary.Raw[]; + watch: WatchResponse.Raw; } } diff --git a/sdks/runtime/go/actor/actor.go b/sdks/runtime/go/actor/actor.go new file mode 100644 index 0000000000..2e4c9214ea --- /dev/null +++ b/sdks/runtime/go/actor/actor.go @@ -0,0 +1,159 @@ +// This file was auto-generated by Fern from our API Definition. + +package actor + +import ( + json "encoding/json" + fmt "fmt" + core "sdk/core" +) + +type CreateActorRequest struct { + Region string `json:"region"` + Tags interface{} `json:"tags,omitempty"` + Runtime *CreateActorRuntimeRequest `json:"runtime,omitempty"` + Network *CreateActorNetworkRequest `json:"network,omitempty"` + Resources *Resources `json:"resources,omitempty"` + Lifecycle *Lifecycle `json:"lifecycle,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CreateActorRequest) UnmarshalJSON(data []byte) error { + type unmarshaler CreateActorRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CreateActorRequest(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CreateActorRequest) String() string { + if len(c._rawJSON) > 0 { + if value, err := core.StringifyJSON(c._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(c); err == nil { + return value + } + return fmt.Sprintf("%#v", c) +} + +type CreateActorResponse struct { + // The actor that was created + Actor *Actor `json:"actor,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CreateActorResponse) UnmarshalJSON(data []byte) error { + type unmarshaler CreateActorResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CreateActorResponse(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CreateActorResponse) String() string { + if len(c._rawJSON) > 0 { + if value, err := core.StringifyJSON(c._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(c); err == nil { + return value + } + return fmt.Sprintf("%#v", c) +} + +type DestroyActorResponse struct { + _rawJSON json.RawMessage +} + +func (d *DestroyActorResponse) UnmarshalJSON(data []byte) error { + type unmarshaler DestroyActorResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *d = DestroyActorResponse(value) + d._rawJSON = json.RawMessage(data) + return nil +} + +func (d *DestroyActorResponse) String() string { + if len(d._rawJSON) > 0 { + if value, err := core.StringifyJSON(d._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(d); err == nil { + return value + } + return fmt.Sprintf("%#v", d) +} + +type GetActorResponse struct { + Actor *Actor `json:"actor,omitempty"` + + _rawJSON json.RawMessage +} + +func (g *GetActorResponse) UnmarshalJSON(data []byte) error { + type unmarshaler GetActorResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *g = GetActorResponse(value) + g._rawJSON = json.RawMessage(data) + return nil +} + +func (g *GetActorResponse) String() string { + if len(g._rawJSON) > 0 { + if value, err := core.StringifyJSON(g._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(g); err == nil { + return value + } + return fmt.Sprintf("%#v", g) +} + +type ListActorsResponse struct { + // A list of actors for the project associated with the token. + Actors []*Actor `json:"actors,omitempty"` + + _rawJSON json.RawMessage +} + +func (l *ListActorsResponse) UnmarshalJSON(data []byte) error { + type unmarshaler ListActorsResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *l = ListActorsResponse(value) + l._rawJSON = json.RawMessage(data) + return nil +} + +func (l *ListActorsResponse) String() string { + if len(l._rawJSON) > 0 { + if value, err := core.StringifyJSON(l._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(l); err == nil { + return value + } + return fmt.Sprintf("%#v", l) +} diff --git a/sdks/runtime/go/actor/builds.go b/sdks/runtime/go/actor/builds.go new file mode 100644 index 0000000000..b86a895b35 --- /dev/null +++ b/sdks/runtime/go/actor/builds.go @@ -0,0 +1,249 @@ +// This file was auto-generated by Fern from our API Definition. + +package actor + +import ( + json "encoding/json" + fmt "fmt" + uuid "github.com/google/uuid" + core "sdk/core" + upload "sdk/upload" +) + +type CompleteBuildRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` +} + +type GetBuildRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` +} + +type ListBuildsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + TagsJson *string `json:"-"` +} + +type PatchBuildTagsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + Body *PatchBuildTagsRequest `json:"-"` +} + +func (p *PatchBuildTagsRequestQuery) UnmarshalJSON(data []byte) error { + body := new(PatchBuildTagsRequest) + if err := json.Unmarshal(data, &body); err != nil { + return err + } + p.Body = body + return nil +} + +func (p *PatchBuildTagsRequestQuery) MarshalJSON() ([]byte, error) { + return json.Marshal(p.Body) +} + +type PrepareBuildRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + Body *PrepareBuildRequest `json:"-"` +} + +func (p *PrepareBuildRequestQuery) UnmarshalJSON(data []byte) error { + body := new(PrepareBuildRequest) + if err := json.Unmarshal(data, &body); err != nil { + return err + } + p.Body = body + return nil +} + +func (p *PrepareBuildRequestQuery) MarshalJSON() ([]byte, error) { + return json.Marshal(p.Body) +} + +type GetBuildResponse struct { + Build *Build `json:"build,omitempty"` + + _rawJSON json.RawMessage +} + +func (g *GetBuildResponse) UnmarshalJSON(data []byte) error { + type unmarshaler GetBuildResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *g = GetBuildResponse(value) + g._rawJSON = json.RawMessage(data) + return nil +} + +func (g *GetBuildResponse) String() string { + if len(g._rawJSON) > 0 { + if value, err := core.StringifyJSON(g._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(g); err == nil { + return value + } + return fmt.Sprintf("%#v", g) +} + +type ListBuildsResponse struct { + // A list of builds for the project associated with the token. + Builds []*Build `json:"builds,omitempty"` + + _rawJSON json.RawMessage +} + +func (l *ListBuildsResponse) UnmarshalJSON(data []byte) error { + type unmarshaler ListBuildsResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *l = ListBuildsResponse(value) + l._rawJSON = json.RawMessage(data) + return nil +} + +func (l *ListBuildsResponse) String() string { + if len(l._rawJSON) > 0 { + if value, err := core.StringifyJSON(l._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(l); err == nil { + return value + } + return fmt.Sprintf("%#v", l) +} + +type PatchBuildTagsRequest struct { + Tags interface{} `json:"tags,omitempty"` + // Removes the given tag keys from all other builds. + ExclusiveTags []string `json:"exclusive_tags,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *PatchBuildTagsRequest) UnmarshalJSON(data []byte) error { + type unmarshaler PatchBuildTagsRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PatchBuildTagsRequest(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PatchBuildTagsRequest) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PatchBuildTagsResponse struct { + _rawJSON json.RawMessage +} + +func (p *PatchBuildTagsResponse) UnmarshalJSON(data []byte) error { + type unmarshaler PatchBuildTagsResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PatchBuildTagsResponse(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PatchBuildTagsResponse) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PrepareBuildRequest struct { + Name string `json:"name"` + // A tag given to the project build. + ImageTag *string `json:"image_tag,omitempty"` + ImageFile *upload.PrepareFile `json:"image_file,omitempty"` + MultipartUpload *bool `json:"multipart_upload,omitempty"` + Kind *BuildKind `json:"kind,omitempty"` + Compression *BuildCompression `json:"compression,omitempty"` + PrewarmRegions []string `json:"prewarm_regions,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *PrepareBuildRequest) UnmarshalJSON(data []byte) error { + type unmarshaler PrepareBuildRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PrepareBuildRequest(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PrepareBuildRequest) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PrepareBuildResponse struct { + Build uuid.UUID `json:"build"` + ImagePresignedRequest *upload.PresignedRequest `json:"image_presigned_request,omitempty"` + ImagePresignedRequests []*upload.PresignedRequest `json:"image_presigned_requests,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *PrepareBuildResponse) UnmarshalJSON(data []byte) error { + type unmarshaler PrepareBuildResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PrepareBuildResponse(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PrepareBuildResponse) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} diff --git a/sdks/runtime/go/actor/builds/client.go b/sdks/runtime/go/actor/builds/client.go new file mode 100644 index 0000000000..1e38eec4fb --- /dev/null +++ b/sdks/runtime/go/actor/builds/client.go @@ -0,0 +1,483 @@ +// This file was auto-generated by Fern from our API Definition. + +package builds + +import ( + bytes "bytes" + context "context" + json "encoding/json" + errors "errors" + fmt "fmt" + uuid "github.com/google/uuid" + io "io" + http "net/http" + url "net/url" + sdk "sdk" + actor "sdk/actor" + core "sdk/core" +) + +type Client struct { + baseURL string + caller *core.Caller + header http.Header +} + +func NewClient(opts ...core.ClientOption) *Client { + options := core.NewClientOptions() + for _, opt := range opts { + opt(options) + } + return &Client{ + baseURL: options.BaseURL, + caller: core.NewCaller(options.HTTPClient), + header: options.ToHeader(), + } +} + +// Get a build. +func (c *Client) Get(ctx context.Context, build uuid.UUID, request *actor.GetBuildRequestQuery) (*actor.GetBuildResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := fmt.Sprintf(baseURL+"/"+"builds/%v", build) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *actor.GetBuildResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodGet, + Headers: c.header, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} + +// Lists all builds of the project associated with the token used. Can be filtered by tags in the query string. +func (c *Client) List(ctx context.Context, request *actor.ListBuildsRequestQuery) (*actor.ListBuildsResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := baseURL + "/" + "builds" + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if request.TagsJson != nil { + queryParams.Add("tags_json", fmt.Sprintf("%v", *request.TagsJson)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *actor.ListBuildsResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodGet, + Headers: c.header, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} + +func (c *Client) PatchTags(ctx context.Context, build uuid.UUID, request *actor.PatchBuildTagsRequestQuery) (*actor.PatchBuildTagsResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := fmt.Sprintf(baseURL+"/"+"builds/%v/tags", build) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *actor.PatchBuildTagsResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodPatch, + Headers: c.header, + Request: request, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} + +// Creates a new project build for the given project. +func (c *Client) Prepare(ctx context.Context, request *actor.PrepareBuildRequestQuery) (*actor.PrepareBuildResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := baseURL + "/" + "builds/prepare" + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *actor.PrepareBuildResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodPost, + Headers: c.header, + Request: request, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} + +// Marks an upload as complete. +func (c *Client) Complete(ctx context.Context, build uuid.UUID, request *actor.CompleteBuildRequestQuery) error { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := fmt.Sprintf(baseURL+"/"+"builds/%v/complete", build) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodPost, + Headers: c.header, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return err + } + return nil +} diff --git a/sdks/runtime/go/matchmaker/players/client.go b/sdks/runtime/go/actor/client/client.go similarity index 51% rename from sdks/runtime/go/matchmaker/players/client.go rename to sdks/runtime/go/actor/client/client.go index c11a162874..ca2e484a38 100644 --- a/sdks/runtime/go/matchmaker/players/client.go +++ b/sdks/runtime/go/actor/client/client.go @@ -1,23 +1,33 @@ // This file was auto-generated by Fern from our API Definition. -package players +package client import ( bytes "bytes" context "context" json "encoding/json" errors "errors" + fmt "fmt" + uuid "github.com/google/uuid" io "io" http "net/http" + url "net/url" sdk "sdk" + sdkactor "sdk/actor" + builds "sdk/actor/builds" + logs "sdk/actor/logs" + regions "sdk/actor/regions" core "sdk/core" - matchmaker "sdk/matchmaker" ) type Client struct { baseURL string caller *core.Caller header http.Header + + Builds *builds.Client + Logs *logs.Client + Regions *regions.Client } func NewClient(opts ...core.ClientOption) *Client { @@ -29,50 +39,32 @@ func NewClient(opts ...core.ClientOption) *Client { baseURL: options.BaseURL, caller: core.NewCaller(options.HTTPClient), header: options.ToHeader(), + Builds: builds.NewClient(opts...), + Logs: logs.NewClient(opts...), + Regions: regions.NewClient(opts...), } } -// Validates the player token is valid and has not already been consumed then -// marks the player as connected. -// -// # Player Tokens and Reserved Slots -// -// Player tokens reserve a spot in the lobby until they expire. This allows for -// precise matchmaking up to exactly the lobby's player limit, which is -// important for games with small lobbies and a high influx of players. -// By calling this endpoint with the player token, the player's spot is marked -// as connected and will not expire. If this endpoint is never called, the -// player's token will expire and this spot will be filled by another player. -// -// # Anti-Botting +// Gets a dynamic actor. // -// Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, or -// from the `GlobalEventMatchmakerLobbyJoin` event. -// These endpoints have anti-botting measures (i.e. enforcing max player -// limits, captchas, and detecting bots), so valid player tokens provide some -// confidence that the player is not a bot. -// Therefore, it's important to make sure the token is valid by waiting for -// this endpoint to return OK before allowing the connected socket to do -// anything else. If this endpoint returns an error, the socket should be -// disconnected immediately. -// -// # How to Transmit the Player Token -// -// The client is responsible for acquiring the player token by caling -// `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` -// event. Beyond that, it's up to the developer how the player token is -// transmitted to the lobby. -// If using WebSockets, the player token can be transmitted as a query -// parameter. -// Otherwise, the player token will likely be automatically sent by the client -// once the socket opens. As mentioned above, nothing else should happen until -// the player token is validated. -func (c *Client) Connected(ctx context.Context, request *matchmaker.PlayerConnectedRequest) error { +// The id of the actor to destroy +func (c *Client) Get(ctx context.Context, actor uuid.UUID, request *sdkactor.ListActorsRequestQuery) (*sdkactor.GetActorResponse, error) { baseURL := "https://api.rivet.gg" if c.baseURL != "" { baseURL = c.baseURL } - endpointURL := baseURL + "/" + "matchmaker/players/connected" + endpointURL := fmt.Sprintf(baseURL+"/"+"actors/%v", actor) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } errorDecoder := func(statusCode int, body io.Reader) error { raw, err := io.ReadAll(body) @@ -128,28 +120,49 @@ func (c *Client) Connected(ctx context.Context, request *matchmaker.PlayerConnec return apiError } + var response *sdkactor.GetActorResponse if err := c.caller.Call( ctx, &core.CallParams{ URL: endpointURL, - Method: http.MethodPost, + Method: http.MethodGet, Headers: c.header, - Request: request, + Response: &response, ErrorDecoder: errorDecoder, }, ); err != nil { - return err + return nil, err } - return nil + return response, nil } -// Marks a player as disconnected. # Ghost Players If players are not marked as disconnected, lobbies will result with "ghost players" that the matchmaker thinks exist but are no longer connected to the lobby. -func (c *Client) Disconnected(ctx context.Context, request *matchmaker.PlayerDisconnectedRequest) error { +// Lists all actors associated with the token used. Can be filtered by tags in the query string. +func (c *Client) List(ctx context.Context, request *sdkactor.GetActorsRequestQuery) (*sdkactor.ListActorsResponse, error) { baseURL := "https://api.rivet.gg" if c.baseURL != "" { baseURL = c.baseURL } - endpointURL := baseURL + "/" + "matchmaker/players/disconnected" + endpointURL := baseURL + "/" + "actors" + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if request.TagsJson != nil { + queryParams.Add("tags_json", fmt.Sprintf("%v", *request.TagsJson)) + } + if request.IncludeDestroyed != nil { + queryParams.Add("include_destroyed", fmt.Sprintf("%v", *request.IncludeDestroyed)) + } + if request.Cursor != nil { + queryParams.Add("cursor", fmt.Sprintf("%v", *request.Cursor)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } errorDecoder := func(statusCode int, body io.Reader) error { raw, err := io.ReadAll(body) @@ -205,6 +218,96 @@ func (c *Client) Disconnected(ctx context.Context, request *matchmaker.PlayerDis return apiError } + var response *sdkactor.ListActorsResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodGet, + Headers: c.header, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} + +// Create a new dynamic actor. +func (c *Client) Create(ctx context.Context, request *sdkactor.CreateActorRequestQuery) (*sdkactor.CreateActorResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := baseURL + "/" + "actors" + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *sdkactor.CreateActorResponse if err := c.caller.Call( ctx, &core.CallParams{ @@ -212,21 +315,38 @@ func (c *Client) Disconnected(ctx context.Context, request *matchmaker.PlayerDis Method: http.MethodPost, Headers: c.header, Request: request, + Response: &response, ErrorDecoder: errorDecoder, }, ); err != nil { - return err + return nil, err } - return nil + return response, nil } -// Gives matchmaker statistics about the players in game. -func (c *Client) GetStatistics(ctx context.Context) (*matchmaker.GetStatisticsResponse, error) { +// Destroy a dynamic actor. +// +// The id of the actor to destroy +func (c *Client) Destroy(ctx context.Context, actor uuid.UUID, request *sdkactor.DestroyActorRequestQuery) (*sdkactor.DestroyActorResponse, error) { baseURL := "https://api.rivet.gg" if c.baseURL != "" { baseURL = c.baseURL } - endpointURL := baseURL + "/" + "matchmaker/players/statistics" + endpointURL := fmt.Sprintf(baseURL+"/"+"actors/%v", actor) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if request.OverrideKillTimeout != nil { + queryParams.Add("override_kill_timeout", fmt.Sprintf("%v", *request.OverrideKillTimeout)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } errorDecoder := func(statusCode int, body io.Reader) error { raw, err := io.ReadAll(body) @@ -282,12 +402,12 @@ func (c *Client) GetStatistics(ctx context.Context) (*matchmaker.GetStatisticsRe return apiError } - var response *matchmaker.GetStatisticsResponse + var response *sdkactor.DestroyActorResponse if err := c.caller.Call( ctx, &core.CallParams{ URL: endpointURL, - Method: http.MethodGet, + Method: http.MethodDelete, Headers: c.header, Response: &response, ErrorDecoder: errorDecoder, diff --git a/sdks/runtime/go/actor/logs.go b/sdks/runtime/go/actor/logs.go new file mode 100644 index 0000000000..1d04cb0601 --- /dev/null +++ b/sdks/runtime/go/actor/logs.go @@ -0,0 +1,73 @@ +// This file was auto-generated by Fern from our API Definition. + +package actor + +import ( + json "encoding/json" + fmt "fmt" + sdk "sdk" + core "sdk/core" +) + +type GetActorLogsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + Stream LogStream `json:"-"` + // A query parameter denoting the requests watch index. + WatchIndex *string `json:"-"` +} + +type GetActorLogsResponse struct { + // Sorted old to new. + Lines []string `json:"lines,omitempty"` + // Sorted old to new. + Timestamps []string `json:"timestamps,omitempty"` + Watch *sdk.WatchResponse `json:"watch,omitempty"` + + _rawJSON json.RawMessage +} + +func (g *GetActorLogsResponse) UnmarshalJSON(data []byte) error { + type unmarshaler GetActorLogsResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *g = GetActorLogsResponse(value) + g._rawJSON = json.RawMessage(data) + return nil +} + +func (g *GetActorLogsResponse) String() string { + if len(g._rawJSON) > 0 { + if value, err := core.StringifyJSON(g._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(g); err == nil { + return value + } + return fmt.Sprintf("%#v", g) +} + +type LogStream string + +const ( + LogStreamStdOut LogStream = "std_out" + LogStreamStdErr LogStream = "std_err" +) + +func NewLogStreamFromString(s string) (LogStream, error) { + switch s { + case "std_out": + return LogStreamStdOut, nil + case "std_err": + return LogStreamStdErr, nil + } + var t LogStream + return "", fmt.Errorf("%s is not a valid %T", s, t) +} + +func (l LogStream) Ptr() *LogStream { + return &l +} diff --git a/sdks/runtime/go/actor/logs/client.go b/sdks/runtime/go/actor/logs/client.go new file mode 100644 index 0000000000..abd7a7fad1 --- /dev/null +++ b/sdks/runtime/go/actor/logs/client.go @@ -0,0 +1,129 @@ +// This file was auto-generated by Fern from our API Definition. + +package logs + +import ( + bytes "bytes" + context "context" + json "encoding/json" + errors "errors" + fmt "fmt" + uuid "github.com/google/uuid" + io "io" + http "net/http" + url "net/url" + sdk "sdk" + sdkactor "sdk/actor" + core "sdk/core" +) + +type Client struct { + baseURL string + caller *core.Caller + header http.Header +} + +func NewClient(opts ...core.ClientOption) *Client { + options := core.NewClientOptions() + for _, opt := range opts { + opt(options) + } + return &Client{ + baseURL: options.BaseURL, + caller: core.NewCaller(options.HTTPClient), + header: options.ToHeader(), + } +} + +// Returns the logs for a given actor. +func (c *Client) Get(ctx context.Context, actor uuid.UUID, request *sdkactor.GetActorLogsRequestQuery) (*sdkactor.GetActorLogsResponse, error) { + baseURL := "https://api.rivet.gg" + if c.baseURL != "" { + baseURL = c.baseURL + } + endpointURL := fmt.Sprintf(baseURL+"/"+"actors/%v/logs", actor) + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + queryParams.Add("stream", fmt.Sprintf("%v", request.Stream)) + if request.WatchIndex != nil { + queryParams.Add("watch_index", fmt.Sprintf("%v", *request.WatchIndex)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } + + errorDecoder := func(statusCode int, body io.Reader) error { + raw, err := io.ReadAll(body) + if err != nil { + return err + } + apiError := core.NewAPIError(statusCode, errors.New(string(raw))) + decoder := json.NewDecoder(bytes.NewReader(raw)) + switch statusCode { + case 500: + value := new(sdk.InternalError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 429: + value := new(sdk.RateLimitError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 403: + value := new(sdk.ForbiddenError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 408: + value := new(sdk.UnauthorizedError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 404: + value := new(sdk.NotFoundError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + case 400: + value := new(sdk.BadRequestError) + value.APIError = apiError + if err := decoder.Decode(value); err != nil { + return apiError + } + return value + } + return apiError + } + + var response *sdkactor.GetActorLogsResponse + if err := c.caller.Call( + ctx, + &core.CallParams{ + URL: endpointURL, + Method: http.MethodGet, + Headers: c.header, + Response: &response, + ErrorDecoder: errorDecoder, + }, + ); err != nil { + return nil, err + } + return response, nil +} diff --git a/sdks/runtime/go/matchmaker/regions.go b/sdks/runtime/go/actor/regions.go similarity index 81% rename from sdks/runtime/go/matchmaker/regions.go rename to sdks/runtime/go/actor/regions.go index d6d27ec8a5..5ae87f7ab1 100644 --- a/sdks/runtime/go/matchmaker/regions.go +++ b/sdks/runtime/go/actor/regions.go @@ -1,6 +1,6 @@ // This file was auto-generated by Fern from our API Definition. -package matchmaker +package actor import ( json "encoding/json" @@ -8,8 +8,13 @@ import ( core "sdk/core" ) +type ListRegionsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` +} + type ListRegionsResponse struct { - Regions []*RegionInfo `json:"regions,omitempty"` + Regions []*Region `json:"regions,omitempty"` _rawJSON json.RawMessage } diff --git a/sdks/runtime/go/matchmaker/regions/client.go b/sdks/runtime/go/actor/regions/client.go similarity index 79% rename from sdks/runtime/go/matchmaker/regions/client.go rename to sdks/runtime/go/actor/regions/client.go index 2a8ca60148..fefeed7e92 100644 --- a/sdks/runtime/go/matchmaker/regions/client.go +++ b/sdks/runtime/go/actor/regions/client.go @@ -7,11 +7,13 @@ import ( context "context" json "encoding/json" errors "errors" + fmt "fmt" io "io" http "net/http" + url "net/url" sdk "sdk" + actor "sdk/actor" core "sdk/core" - matchmaker "sdk/matchmaker" ) type Client struct { @@ -32,15 +34,23 @@ func NewClient(opts ...core.ClientOption) *Client { } } -// Returns a list of regions available to this namespace. -// Regions are sorted by most optimal to least optimal. The player's IP address -// is used to calculate the regions' optimality. -func (c *Client) List(ctx context.Context) (*matchmaker.ListRegionsResponse, error) { +func (c *Client) List(ctx context.Context, request *actor.ListRegionsRequestQuery) (*actor.ListRegionsResponse, error) { baseURL := "https://api.rivet.gg" if c.baseURL != "" { baseURL = c.baseURL } - endpointURL := baseURL + "/" + "matchmaker/regions" + endpointURL := baseURL + "/" + "regions" + + queryParams := make(url.Values) + if request.Project != nil { + queryParams.Add("project", fmt.Sprintf("%v", *request.Project)) + } + if request.Environment != nil { + queryParams.Add("environment", fmt.Sprintf("%v", *request.Environment)) + } + if len(queryParams) > 0 { + endpointURL += "?" + queryParams.Encode() + } errorDecoder := func(statusCode int, body io.Reader) error { raw, err := io.ReadAll(body) @@ -96,7 +106,7 @@ func (c *Client) List(ctx context.Context) (*matchmaker.ListRegionsResponse, err return apiError } - var response *matchmaker.ListRegionsResponse + var response *actor.ListRegionsResponse if err := c.caller.Call( ctx, &core.CallParams{ diff --git a/sdks/runtime/go/actor/types.go b/sdks/runtime/go/actor/types.go new file mode 100644 index 0000000000..085d7dd33e --- /dev/null +++ b/sdks/runtime/go/actor/types.go @@ -0,0 +1,654 @@ +// This file was auto-generated by Fern from our API Definition. + +package actor + +import ( + json "encoding/json" + fmt "fmt" + uuid "github.com/google/uuid" + sdk "sdk" + core "sdk/core" +) + +type CreateActorRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + Body *CreateActorRequest `json:"-"` +} + +func (c *CreateActorRequestQuery) UnmarshalJSON(data []byte) error { + body := new(CreateActorRequest) + if err := json.Unmarshal(data, &body); err != nil { + return err + } + c.Body = body + return nil +} + +func (c *CreateActorRequestQuery) MarshalJSON() ([]byte, error) { + return json.Marshal(c.Body) +} + +type DestroyActorRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + // The duration to wait for in milliseconds before killing the actor. This should be used to override the default kill timeout if a faster time is needed, say for ignoring a graceful shutdown. + OverrideKillTimeout *int64 `json:"-"` +} + +type ListActorsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` +} + +type GetActorsRequestQuery struct { + Project *string `json:"-"` + Environment *string `json:"-"` + TagsJson *string `json:"-"` + IncludeDestroyed *bool `json:"-"` + Cursor *uuid.UUID `json:"-"` +} + +type BuildCompression string + +const ( + // None compression. + BuildCompressionNone BuildCompression = "none" + // LZ4 compression. Use the minimum compression level. + BuildCompressionLz4 BuildCompression = "lz4" +) + +func NewBuildCompressionFromString(s string) (BuildCompression, error) { + switch s { + case "none": + return BuildCompressionNone, nil + case "lz4": + return BuildCompressionLz4, nil + } + var t BuildCompression + return "", fmt.Errorf("%s is not a valid %T", s, t) +} + +func (b BuildCompression) Ptr() *BuildCompression { + return &b +} + +type BuildKind string + +const ( + // Docker image archive generated by `docker save`. + BuildKindDockerImage BuildKind = "docker_image" + // OCI-compliant bundle. + BuildKindOciBundle BuildKind = "oci_bundle" + // A JavaScript file. + BuildKindJavascript BuildKind = "javascript" +) + +func NewBuildKindFromString(s string) (BuildKind, error) { + switch s { + case "docker_image": + return BuildKindDockerImage, nil + case "oci_bundle": + return BuildKindOciBundle, nil + case "javascript": + return BuildKindJavascript, nil + } + var t BuildKind + return "", fmt.Errorf("%s is not a valid %T", s, t) +} + +func (b BuildKind) Ptr() *BuildKind { + return &b +} + +type Actor struct { + Id uuid.UUID `json:"id"` + Region string `json:"region"` + Tags interface{} `json:"tags,omitempty"` + Runtime *Runtime `json:"runtime,omitempty"` + Network *Network `json:"network,omitempty"` + Resources *Resources `json:"resources,omitempty"` + Lifecycle *Lifecycle `json:"lifecycle,omitempty"` + CreatedAt int64 `json:"created_at"` + StartedAt *int64 `json:"started_at,omitempty"` + DestroyedAt *int64 `json:"destroyed_at,omitempty"` + + _rawJSON json.RawMessage +} + +func (a *Actor) UnmarshalJSON(data []byte) error { + type unmarshaler Actor + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *a = Actor(value) + a._rawJSON = json.RawMessage(data) + return nil +} + +func (a *Actor) String() string { + if len(a._rawJSON) > 0 { + if value, err := core.StringifyJSON(a._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(a); err == nil { + return value + } + return fmt.Sprintf("%#v", a) +} + +type Build struct { + Id uuid.UUID `json:"id"` + Name string `json:"name"` + CreatedAt sdk.Timestamp `json:"created_at"` + // Unsigned 64 bit integer. + ContentLength int64 `json:"content_length"` + // Tags of this build + Tags map[string]string `json:"tags,omitempty"` + + _rawJSON json.RawMessage +} + +func (b *Build) UnmarshalJSON(data []byte) error { + type unmarshaler Build + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *b = Build(value) + b._rawJSON = json.RawMessage(data) + return nil +} + +func (b *Build) String() string { + if len(b._rawJSON) > 0 { + if value, err := core.StringifyJSON(b._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(b); err == nil { + return value + } + return fmt.Sprintf("%#v", b) +} + +type GuardRouting struct { + Authorization *PortAuthorization `json:"authorization,omitempty"` + + _rawJSON json.RawMessage +} + +func (g *GuardRouting) UnmarshalJSON(data []byte) error { + type unmarshaler GuardRouting + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *g = GuardRouting(value) + g._rawJSON = json.RawMessage(data) + return nil +} + +func (g *GuardRouting) String() string { + if len(g._rawJSON) > 0 { + if value, err := core.StringifyJSON(g._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(g); err == nil { + return value + } + return fmt.Sprintf("%#v", g) +} + +type HostRouting struct { + _rawJSON json.RawMessage +} + +func (h *HostRouting) UnmarshalJSON(data []byte) error { + type unmarshaler HostRouting + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *h = HostRouting(value) + h._rawJSON = json.RawMessage(data) + return nil +} + +func (h *HostRouting) String() string { + if len(h._rawJSON) > 0 { + if value, err := core.StringifyJSON(h._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(h); err == nil { + return value + } + return fmt.Sprintf("%#v", h) +} + +type Lifecycle struct { + // The duration to wait for in milliseconds before killing the actor. This should be set to a safe default, and can be overridden during a DELETE request if needed. + KillTimeout *int64 `json:"kill_timeout,omitempty"` + + _rawJSON json.RawMessage +} + +func (l *Lifecycle) UnmarshalJSON(data []byte) error { + type unmarshaler Lifecycle + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *l = Lifecycle(value) + l._rawJSON = json.RawMessage(data) + return nil +} + +func (l *Lifecycle) String() string { + if len(l._rawJSON) > 0 { + if value, err := core.StringifyJSON(l._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(l); err == nil { + return value + } + return fmt.Sprintf("%#v", l) +} + +type Network struct { + Mode NetworkMode `json:"mode,omitempty"` + Ports map[string]*Port `json:"ports,omitempty"` + + _rawJSON json.RawMessage +} + +func (n *Network) UnmarshalJSON(data []byte) error { + type unmarshaler Network + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *n = Network(value) + n._rawJSON = json.RawMessage(data) + return nil +} + +func (n *Network) String() string { + if len(n._rawJSON) > 0 { + if value, err := core.StringifyJSON(n._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(n); err == nil { + return value + } + return fmt.Sprintf("%#v", n) +} + +type NetworkMode string + +const ( + NetworkModeBridge NetworkMode = "bridge" + NetworkModeHost NetworkMode = "host" +) + +func NewNetworkModeFromString(s string) (NetworkMode, error) { + switch s { + case "bridge": + return NetworkModeBridge, nil + case "host": + return NetworkModeHost, nil + } + var t NetworkMode + return "", fmt.Errorf("%s is not a valid %T", s, t) +} + +func (n NetworkMode) Ptr() *NetworkMode { + return &n +} + +type Port struct { + Protocol PortProtocol `json:"protocol,omitempty"` + InternalPort *int `json:"internal_port,omitempty"` + PublicHostname *string `json:"public_hostname,omitempty"` + PublicPort *int `json:"public_port,omitempty"` + Routing *PortRouting `json:"routing,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *Port) UnmarshalJSON(data []byte) error { + type unmarshaler Port + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = Port(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *Port) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PortAuthorization struct { + Bearer *string `json:"bearer,omitempty"` + Query *PortQueryAuthorization `json:"query,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *PortAuthorization) UnmarshalJSON(data []byte) error { + type unmarshaler PortAuthorization + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PortAuthorization(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PortAuthorization) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PortProtocol string + +const ( + PortProtocolHttp PortProtocol = "http" + PortProtocolHttps PortProtocol = "https" + PortProtocolTcp PortProtocol = "tcp" + PortProtocolTcpTls PortProtocol = "tcp_tls" + PortProtocolUdp PortProtocol = "udp" +) + +func NewPortProtocolFromString(s string) (PortProtocol, error) { + switch s { + case "http": + return PortProtocolHttp, nil + case "https": + return PortProtocolHttps, nil + case "tcp": + return PortProtocolTcp, nil + case "tcp_tls": + return PortProtocolTcpTls, nil + case "udp": + return PortProtocolUdp, nil + } + var t PortProtocol + return "", fmt.Errorf("%s is not a valid %T", s, t) +} + +func (p PortProtocol) Ptr() *PortProtocol { + return &p +} + +type PortQueryAuthorization struct { + Key string `json:"key"` + Value string `json:"value"` + + _rawJSON json.RawMessage +} + +func (p *PortQueryAuthorization) UnmarshalJSON(data []byte) error { + type unmarshaler PortQueryAuthorization + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PortQueryAuthorization(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PortQueryAuthorization) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type PortRouting struct { + Guard *GuardRouting `json:"guard,omitempty"` + Host *HostRouting `json:"host,omitempty"` + + _rawJSON json.RawMessage +} + +func (p *PortRouting) UnmarshalJSON(data []byte) error { + type unmarshaler PortRouting + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PortRouting(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PortRouting) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +type Region struct { + Id string `json:"id"` + Name string `json:"name"` + + _rawJSON json.RawMessage +} + +func (r *Region) UnmarshalJSON(data []byte) error { + type unmarshaler Region + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *r = Region(value) + r._rawJSON = json.RawMessage(data) + return nil +} + +func (r *Region) String() string { + if len(r._rawJSON) > 0 { + if value, err := core.StringifyJSON(r._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(r); err == nil { + return value + } + return fmt.Sprintf("%#v", r) +} + +type Resources struct { + // The number of CPU cores in millicores, or 1/1000 of a core. For example, + // 1/8 of a core would be 125 millicores, and 1 core would be 1000 + // millicores. + Cpu int `json:"cpu"` + // The amount of memory in megabytes + Memory int `json:"memory"` + + _rawJSON json.RawMessage +} + +func (r *Resources) UnmarshalJSON(data []byte) error { + type unmarshaler Resources + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *r = Resources(value) + r._rawJSON = json.RawMessage(data) + return nil +} + +func (r *Resources) String() string { + if len(r._rawJSON) > 0 { + if value, err := core.StringifyJSON(r._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(r); err == nil { + return value + } + return fmt.Sprintf("%#v", r) +} + +type Runtime struct { + Build uuid.UUID `json:"build"` + Arguments []string `json:"arguments,omitempty"` + Environment map[string]string `json:"environment,omitempty"` + + _rawJSON json.RawMessage +} + +func (r *Runtime) UnmarshalJSON(data []byte) error { + type unmarshaler Runtime + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *r = Runtime(value) + r._rawJSON = json.RawMessage(data) + return nil +} + +func (r *Runtime) String() string { + if len(r._rawJSON) > 0 { + if value, err := core.StringifyJSON(r._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(r); err == nil { + return value + } + return fmt.Sprintf("%#v", r) +} + +type CreateActorNetworkRequest struct { + Mode *NetworkMode `json:"mode,omitempty"` + Ports map[string]*CreateActorPortRequest `json:"ports,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CreateActorNetworkRequest) UnmarshalJSON(data []byte) error { + type unmarshaler CreateActorNetworkRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CreateActorNetworkRequest(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CreateActorNetworkRequest) String() string { + if len(c._rawJSON) > 0 { + if value, err := core.StringifyJSON(c._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(c); err == nil { + return value + } + return fmt.Sprintf("%#v", c) +} + +type CreateActorPortRequest struct { + Protocol PortProtocol `json:"protocol,omitempty"` + InternalPort *int `json:"internal_port,omitempty"` + Routing *PortRouting `json:"routing,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CreateActorPortRequest) UnmarshalJSON(data []byte) error { + type unmarshaler CreateActorPortRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CreateActorPortRequest(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CreateActorPortRequest) String() string { + if len(c._rawJSON) > 0 { + if value, err := core.StringifyJSON(c._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(c); err == nil { + return value + } + return fmt.Sprintf("%#v", c) +} + +type CreateActorRuntimeRequest struct { + Build uuid.UUID `json:"build"` + Arguments []string `json:"arguments,omitempty"` + Environment map[string]string `json:"environment,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CreateActorRuntimeRequest) UnmarshalJSON(data []byte) error { + type unmarshaler CreateActorRuntimeRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CreateActorRuntimeRequest(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CreateActorRuntimeRequest) String() string { + if len(c._rawJSON) > 0 { + if value, err := core.StringifyJSON(c._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(c); err == nil { + return value + } + return fmt.Sprintf("%#v", c) +} diff --git a/sdks/runtime/go/captcha/types.go b/sdks/runtime/go/captcha/types.go deleted file mode 100644 index 49b613947b..0000000000 --- a/sdks/runtime/go/captcha/types.go +++ /dev/null @@ -1,100 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package captcha - -import ( - json "encoding/json" - fmt "fmt" - core "sdk/core" -) - -// Methods to verify a captcha -type Config struct { - Hcaptcha *ConfigHcaptcha `json:"hcaptcha,omitempty"` - Turnstile *ConfigTurnstile `json:"turnstile,omitempty"` - - _rawJSON json.RawMessage -} - -func (c *Config) UnmarshalJSON(data []byte) error { - type unmarshaler Config - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = Config(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *Config) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -// Captcha configuration. -type ConfigHcaptcha struct { - ClientResponse string `json:"client_response"` - - _rawJSON json.RawMessage -} - -func (c *ConfigHcaptcha) UnmarshalJSON(data []byte) error { - type unmarshaler ConfigHcaptcha - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = ConfigHcaptcha(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *ConfigHcaptcha) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -// Captcha configuration. -type ConfigTurnstile struct { - ClientResponse string `json:"client_response"` - - _rawJSON json.RawMessage -} - -func (c *ConfigTurnstile) UnmarshalJSON(data []byte) error { - type unmarshaler ConfigTurnstile - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = ConfigTurnstile(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *ConfigTurnstile) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} diff --git a/sdks/runtime/go/client/client.go b/sdks/runtime/go/client/client.go index a98b7c545a..2563e6a4a5 100644 --- a/sdks/runtime/go/client/client.go +++ b/sdks/runtime/go/client/client.go @@ -4,8 +4,8 @@ package client import ( http "net/http" + actorclient "sdk/actor/client" core "sdk/core" - matchmakerclient "sdk/matchmaker/client" ) type Client struct { @@ -13,7 +13,7 @@ type Client struct { caller *core.Caller header http.Header - Matchmaker *matchmakerclient.Client + Actor *actorclient.Client } func NewClient(opts ...core.ClientOption) *Client { @@ -22,9 +22,9 @@ func NewClient(opts ...core.ClientOption) *Client { opt(options) } return &Client{ - baseURL: options.BaseURL, - caller: core.NewCaller(options.HTTPClient), - header: options.ToHeader(), - Matchmaker: matchmakerclient.NewClient(opts...), + baseURL: options.BaseURL, + caller: core.NewCaller(options.HTTPClient), + header: options.ToHeader(), + Actor: actorclient.NewClient(opts...), } } diff --git a/sdks/runtime/go/geo/types.go b/sdks/runtime/go/geo/types.go deleted file mode 100644 index 67f6469dcb..0000000000 --- a/sdks/runtime/go/geo/types.go +++ /dev/null @@ -1,71 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package geo - -import ( - json "encoding/json" - fmt "fmt" - core "sdk/core" -) - -// Geographical coordinates for a location on Planet Earth. -type Coord struct { - Latitude float64 `json:"latitude"` - Longitude float64 `json:"longitude"` - - _rawJSON json.RawMessage -} - -func (c *Coord) UnmarshalJSON(data []byte) error { - type unmarshaler Coord - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = Coord(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *Coord) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -// Distance available in multiple units. -type Distance struct { - Kilometers float64 `json:"kilometers"` - Miles float64 `json:"miles"` - - _rawJSON json.RawMessage -} - -func (d *Distance) UnmarshalJSON(data []byte) error { - type unmarshaler Distance - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *d = Distance(value) - d._rawJSON = json.RawMessage(data) - return nil -} - -func (d *Distance) String() string { - if len(d._rawJSON) > 0 { - if value, err := core.StringifyJSON(d._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(d); err == nil { - return value - } - return fmt.Sprintf("%#v", d) -} diff --git a/sdks/runtime/go/matchmaker/client/client.go b/sdks/runtime/go/matchmaker/client/client.go deleted file mode 100644 index c721140e0c..0000000000 --- a/sdks/runtime/go/matchmaker/client/client.go +++ /dev/null @@ -1,36 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package client - -import ( - http "net/http" - core "sdk/core" - lobbies "sdk/matchmaker/lobbies" - players "sdk/matchmaker/players" - regions "sdk/matchmaker/regions" -) - -type Client struct { - baseURL string - caller *core.Caller - header http.Header - - Lobbies *lobbies.Client - Players *players.Client - Regions *regions.Client -} - -func NewClient(opts ...core.ClientOption) *Client { - options := core.NewClientOptions() - for _, opt := range opts { - opt(options) - } - return &Client{ - baseURL: options.BaseURL, - caller: core.NewCaller(options.HTTPClient), - header: options.ToHeader(), - Lobbies: lobbies.NewClient(opts...), - Players: players.NewClient(opts...), - Regions: regions.NewClient(opts...), - } -} diff --git a/sdks/runtime/go/matchmaker/lobbies.go b/sdks/runtime/go/matchmaker/lobbies.go deleted file mode 100644 index 9f8ef55945..0000000000 --- a/sdks/runtime/go/matchmaker/lobbies.go +++ /dev/null @@ -1,192 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package matchmaker - -import ( - json "encoding/json" - fmt "fmt" - captcha "sdk/captcha" - core "sdk/core" -) - -type CreateLobbyRequest struct { - GameMode string `json:"game_mode"` - Region *string `json:"region,omitempty"` - Publicity *CustomLobbyPublicity `json:"publicity,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - MaxPlayers *int `json:"max_players,omitempty"` - LobbyConfig interface{} `json:"lobby_config,omitempty"` - Captcha *captcha.Config `json:"captcha,omitempty"` - VerificationData interface{} `json:"verification_data,omitempty"` -} - -type FindLobbyRequest struct { - Origin *string `json:"-"` - GameModes []string `json:"game_modes,omitempty"` - Regions []string `json:"regions,omitempty"` - PreventAutoCreateLobby *bool `json:"prevent_auto_create_lobby,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - MaxPlayers *int `json:"max_players,omitempty"` - Captcha *captcha.Config `json:"captcha,omitempty"` - VerificationData interface{} `json:"verification_data,omitempty"` -} - -type JoinLobbyRequest struct { - LobbyId string `json:"lobby_id"` - Captcha *captcha.Config `json:"captcha,omitempty"` - VerificationData interface{} `json:"verification_data,omitempty"` -} - -type ListLobbiesRequest struct { - IncludeState *bool `json:"-"` -} - -type SetLobbyClosedRequest struct { - IsClosed bool `json:"is_closed"` -} - -type CustomLobbyPublicity string - -const ( - CustomLobbyPublicityPublic CustomLobbyPublicity = "public" - CustomLobbyPublicityPrivate CustomLobbyPublicity = "private" -) - -func NewCustomLobbyPublicityFromString(s string) (CustomLobbyPublicity, error) { - switch s { - case "public": - return CustomLobbyPublicityPublic, nil - case "private": - return CustomLobbyPublicityPrivate, nil - } - var t CustomLobbyPublicity - return "", fmt.Errorf("%s is not a valid %T", s, t) -} - -func (c CustomLobbyPublicity) Ptr() *CustomLobbyPublicity { - return &c -} - -type CreateLobbyResponse struct { - Lobby *JoinLobby `json:"lobby,omitempty"` - Ports map[string]*JoinPort `json:"ports,omitempty"` - Player *JoinPlayer `json:"player,omitempty"` - - _rawJSON json.RawMessage -} - -func (c *CreateLobbyResponse) UnmarshalJSON(data []byte) error { - type unmarshaler CreateLobbyResponse - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = CreateLobbyResponse(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *CreateLobbyResponse) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -type FindLobbyResponse struct { - Lobby *JoinLobby `json:"lobby,omitempty"` - Ports map[string]*JoinPort `json:"ports,omitempty"` - Player *JoinPlayer `json:"player,omitempty"` - - _rawJSON json.RawMessage -} - -func (f *FindLobbyResponse) UnmarshalJSON(data []byte) error { - type unmarshaler FindLobbyResponse - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *f = FindLobbyResponse(value) - f._rawJSON = json.RawMessage(data) - return nil -} - -func (f *FindLobbyResponse) String() string { - if len(f._rawJSON) > 0 { - if value, err := core.StringifyJSON(f._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(f); err == nil { - return value - } - return fmt.Sprintf("%#v", f) -} - -type JoinLobbyResponse struct { - Lobby *JoinLobby `json:"lobby,omitempty"` - Ports map[string]*JoinPort `json:"ports,omitempty"` - Player *JoinPlayer `json:"player,omitempty"` - - _rawJSON json.RawMessage -} - -func (j *JoinLobbyResponse) UnmarshalJSON(data []byte) error { - type unmarshaler JoinLobbyResponse - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinLobbyResponse(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinLobbyResponse) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -type ListLobbiesResponse struct { - GameModes []*GameModeInfo `json:"game_modes,omitempty"` - Regions []*RegionInfo `json:"regions,omitempty"` - Lobbies []*LobbyInfo `json:"lobbies,omitempty"` - - _rawJSON json.RawMessage -} - -func (l *ListLobbiesResponse) UnmarshalJSON(data []byte) error { - type unmarshaler ListLobbiesResponse - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *l = ListLobbiesResponse(value) - l._rawJSON = json.RawMessage(data) - return nil -} - -func (l *ListLobbiesResponse) String() string { - if len(l._rawJSON) > 0 { - if value, err := core.StringifyJSON(l._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(l); err == nil { - return value - } - return fmt.Sprintf("%#v", l) -} diff --git a/sdks/runtime/go/matchmaker/lobbies/client.go b/sdks/runtime/go/matchmaker/lobbies/client.go deleted file mode 100644 index a67a635bbe..0000000000 --- a/sdks/runtime/go/matchmaker/lobbies/client.go +++ /dev/null @@ -1,720 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package lobbies - -import ( - bytes "bytes" - context "context" - json "encoding/json" - errors "errors" - fmt "fmt" - uuid "github.com/google/uuid" - io "io" - http "net/http" - url "net/url" - sdk "sdk" - core "sdk/core" - matchmaker "sdk/matchmaker" -) - -type Client struct { - baseURL string - caller *core.Caller - header http.Header -} - -func NewClient(opts ...core.ClientOption) *Client { - options := core.NewClientOptions() - for _, opt := range opts { - opt(options) - } - return &Client{ - baseURL: options.BaseURL, - caller: core.NewCaller(options.HTTPClient), - header: options.ToHeader(), - } -} - -// Marks the current lobby as ready to accept connections. Players will not be able to connect to this lobby until the lobby is flagged as ready. -// This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -func (c *Client) Ready(ctx context.Context) error { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/ready" - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPost, - Headers: c.header, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return err - } - return nil -} - -// If `is_closed` is `true`, the matchmaker will no longer route players to the lobby. Players can still -// join using the /join endpoint (this can be disabled by the developer by rejecting all new connections -// after setting the lobby to closed). -// Does not shutdown the lobby. -// -// This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for -// authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) -// for mock responses. When running on Rivet servers, you can access the given lobby token from the -// [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -func (c *Client) SetClosed(ctx context.Context, request *matchmaker.SetLobbyClosedRequest) error { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/closed" - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPut, - Headers: c.header, - Request: request, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return err - } - return nil -} - -// Sets the state JSON of the current lobby. -// -// This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for -// authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) -// for mock responses. When running on Rivet servers, you can access the given lobby token from the -// [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -func (c *Client) SetState(ctx context.Context, request interface{}) error { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/state" - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPut, - Headers: c.header, - Request: request, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return err - } - return nil -} - -// Get the state of any lobby. -// -// This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for -// authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) -// for mock responses. When running on Rivet servers, you can access the given lobby token from the -// [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -func (c *Client) GetState(ctx context.Context, lobbyId uuid.UUID) (interface{}, error) { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := fmt.Sprintf(baseURL+"/"+"matchmaker/lobbies/%v/state", lobbyId) - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - var response interface{} - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodGet, - Headers: c.header, - Response: &response, - ResponseIsOptional: true, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return nil, err - } - return response, nil -} - -// Finds a lobby based on the given criteria. -// If a lobby is not found and `prevent_auto_create_lobby` is `false`, -// a new lobby will be created. -// -// When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in -// your game namespace, this endpoint does not require a token to authenticate. Otherwise, a -// [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used -// for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) -// can be used for general authentication. -func (c *Client) Find(ctx context.Context, request *matchmaker.FindLobbyRequest) (*matchmaker.FindLobbyResponse, error) { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/find" - - headers := c.header.Clone() - if request.Origin != nil { - headers.Add("origin", fmt.Sprintf("%v", *request.Origin)) - } - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - var response *matchmaker.FindLobbyResponse - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPost, - Headers: headers, - Request: request, - Response: &response, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return nil, err - } - return response, nil -} - -// Joins a specific lobby. -// This request will use the direct player count configured for the -// lobby group. -// -// When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in -// your game namespace, this endpoint does not require a token to authenticate. Otherwise, a -// [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used -// for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) -// can be used for general authentication. -func (c *Client) Join(ctx context.Context, request *matchmaker.JoinLobbyRequest) (*matchmaker.JoinLobbyResponse, error) { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/join" - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - var response *matchmaker.JoinLobbyResponse - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPost, - Headers: c.header, - Request: request, - Response: &response, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return nil, err - } - return response, nil -} - -// Creates a custom lobby. -// -// When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in -// your game namespace, this endpoint does not require a token to authenticate. Otherwise, a -// [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used -// for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) -// can be used for general authentication. -func (c *Client) Create(ctx context.Context, request *matchmaker.CreateLobbyRequest) (*matchmaker.CreateLobbyResponse, error) { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/create" - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - var response *matchmaker.CreateLobbyResponse - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodPost, - Headers: c.header, - Request: request, - Response: &response, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return nil, err - } - return response, nil -} - -// Lists all open lobbies. -// -// When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in -// your game namespace, this endpoint does not require a token to authenticate. Otherwise, a -// [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used -// for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) -// can be used for general authentication. -func (c *Client) List(ctx context.Context, request *matchmaker.ListLobbiesRequest) (*matchmaker.ListLobbiesResponse, error) { - baseURL := "https://api.rivet.gg" - if c.baseURL != "" { - baseURL = c.baseURL - } - endpointURL := baseURL + "/" + "matchmaker/lobbies/list" - - queryParams := make(url.Values) - if request.IncludeState != nil { - queryParams.Add("include_state", fmt.Sprintf("%v", *request.IncludeState)) - } - if len(queryParams) > 0 { - endpointURL += "?" + queryParams.Encode() - } - - errorDecoder := func(statusCode int, body io.Reader) error { - raw, err := io.ReadAll(body) - if err != nil { - return err - } - apiError := core.NewAPIError(statusCode, errors.New(string(raw))) - decoder := json.NewDecoder(bytes.NewReader(raw)) - switch statusCode { - case 500: - value := new(sdk.InternalError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 429: - value := new(sdk.RateLimitError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 403: - value := new(sdk.ForbiddenError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 408: - value := new(sdk.UnauthorizedError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 404: - value := new(sdk.NotFoundError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - case 400: - value := new(sdk.BadRequestError) - value.APIError = apiError - if err := decoder.Decode(value); err != nil { - return apiError - } - return value - } - return apiError - } - - var response *matchmaker.ListLobbiesResponse - if err := c.caller.Call( - ctx, - &core.CallParams{ - URL: endpointURL, - Method: http.MethodGet, - Headers: c.header, - Response: &response, - ErrorDecoder: errorDecoder, - }, - ); err != nil { - return nil, err - } - return response, nil -} diff --git a/sdks/runtime/go/matchmaker/players.go b/sdks/runtime/go/matchmaker/players.go deleted file mode 100644 index 10c388e5e2..0000000000 --- a/sdks/runtime/go/matchmaker/players.go +++ /dev/null @@ -1,48 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package matchmaker - -import ( - json "encoding/json" - fmt "fmt" - sdk "sdk" - core "sdk/core" -) - -type PlayerConnectedRequest struct { - PlayerToken string `json:"player_token"` -} - -type PlayerDisconnectedRequest struct { - PlayerToken string `json:"player_token"` -} - -type GetStatisticsResponse struct { - PlayerCount int64 `json:"player_count"` - GameModes map[sdk.Identifier]*GameModeStatistics `json:"game_modes,omitempty"` - - _rawJSON json.RawMessage -} - -func (g *GetStatisticsResponse) UnmarshalJSON(data []byte) error { - type unmarshaler GetStatisticsResponse - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *g = GetStatisticsResponse(value) - g._rawJSON = json.RawMessage(data) - return nil -} - -func (g *GetStatisticsResponse) String() string { - if len(g._rawJSON) > 0 { - if value, err := core.StringifyJSON(g._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(g); err == nil { - return value - } - return fmt.Sprintf("%#v", g) -} diff --git a/sdks/runtime/go/matchmaker/types.go b/sdks/runtime/go/matchmaker/types.go deleted file mode 100644 index bcaed2d7df..0000000000 --- a/sdks/runtime/go/matchmaker/types.go +++ /dev/null @@ -1,338 +0,0 @@ -// This file was auto-generated by Fern from our API Definition. - -package matchmaker - -import ( - json "encoding/json" - fmt "fmt" - uuid "github.com/google/uuid" - sdk "sdk" - core "sdk/core" - geo "sdk/geo" -) - -// A game mode that the player can join. -type GameModeInfo struct { - GameModeId sdk.Identifier `json:"game_mode_id"` - - _rawJSON json.RawMessage -} - -func (g *GameModeInfo) UnmarshalJSON(data []byte) error { - type unmarshaler GameModeInfo - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *g = GameModeInfo(value) - g._rawJSON = json.RawMessage(data) - return nil -} - -func (g *GameModeInfo) String() string { - if len(g._rawJSON) > 0 { - if value, err := core.StringifyJSON(g._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(g); err == nil { - return value - } - return fmt.Sprintf("%#v", g) -} - -// A matchmaker lobby. -type JoinLobby struct { - LobbyId uuid.UUID `json:"lobby_id"` - Region *JoinRegion `json:"region,omitempty"` - // **Deprecated** - Ports map[string]*JoinPort `json:"ports,omitempty"` - // **Deprecated** - Player *JoinPlayer `json:"player,omitempty"` - - _rawJSON json.RawMessage -} - -func (j *JoinLobby) UnmarshalJSON(data []byte) error { - type unmarshaler JoinLobby - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinLobby(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinLobby) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -// A matchmaker lobby player. -type JoinPlayer struct { - // Pass this token through the socket to the lobby server. The lobby server will validate this token with `PlayerConnected.player_token` - Token sdk.Jwt `json:"token"` - - _rawJSON json.RawMessage -} - -func (j *JoinPlayer) UnmarshalJSON(data []byte) error { - type unmarshaler JoinPlayer - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinPlayer(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinPlayer) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -type JoinPort struct { - // The host for the given port. Will be null if using a port range. - Host *string `json:"host,omitempty"` - Hostname string `json:"hostname"` - // The port number for this lobby. Will be null if using a port range. - Port *int `json:"port,omitempty"` - PortRange *JoinPortRange `json:"port_range,omitempty"` - // Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. - IsTls bool `json:"is_tls"` - - _rawJSON json.RawMessage -} - -func (j *JoinPort) UnmarshalJSON(data []byte) error { - type unmarshaler JoinPort - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinPort(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinPort) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -// Inclusive range of ports that can be connected to. -type JoinPortRange struct { - // Minimum port that can be connected to. Inclusive range. - Min int `json:"min"` - // Maximum port that can be connected to. Inclusive range. - Max int `json:"max"` - - _rawJSON json.RawMessage -} - -func (j *JoinPortRange) UnmarshalJSON(data []byte) error { - type unmarshaler JoinPortRange - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinPortRange(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinPortRange) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -// A matchmaker lobby region. -type JoinRegion struct { - RegionId sdk.Identifier `json:"region_id"` - DisplayName sdk.DisplayName `json:"display_name"` - - _rawJSON json.RawMessage -} - -func (j *JoinRegion) UnmarshalJSON(data []byte) error { - type unmarshaler JoinRegion - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *j = JoinRegion(value) - j._rawJSON = json.RawMessage(data) - return nil -} - -func (j *JoinRegion) String() string { - if len(j._rawJSON) > 0 { - if value, err := core.StringifyJSON(j._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(j); err == nil { - return value - } - return fmt.Sprintf("%#v", j) -} - -// A public lobby in the lobby list. -type LobbyInfo struct { - RegionId string `json:"region_id"` - GameModeId string `json:"game_mode_id"` - LobbyId uuid.UUID `json:"lobby_id"` - MaxPlayersNormal int `json:"max_players_normal"` - MaxPlayersDirect int `json:"max_players_direct"` - MaxPlayersParty int `json:"max_players_party"` - TotalPlayerCount int `json:"total_player_count"` - State interface{} `json:"state,omitempty"` - - _rawJSON json.RawMessage -} - -func (l *LobbyInfo) UnmarshalJSON(data []byte) error { - type unmarshaler LobbyInfo - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *l = LobbyInfo(value) - l._rawJSON = json.RawMessage(data) - return nil -} - -func (l *LobbyInfo) String() string { - if len(l._rawJSON) > 0 { - if value, err := core.StringifyJSON(l._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(l); err == nil { - return value - } - return fmt.Sprintf("%#v", l) -} - -// A region that the player can connect to. -type RegionInfo struct { - RegionId sdk.Identifier `json:"region_id"` - ProviderDisplayName sdk.DisplayName `json:"provider_display_name"` - RegionDisplayName sdk.DisplayName `json:"region_display_name"` - DatacenterCoord *geo.Coord `json:"datacenter_coord,omitempty"` - DatacenterDistanceFromClient *geo.Distance `json:"datacenter_distance_from_client,omitempty"` - - _rawJSON json.RawMessage -} - -func (r *RegionInfo) UnmarshalJSON(data []byte) error { - type unmarshaler RegionInfo - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *r = RegionInfo(value) - r._rawJSON = json.RawMessage(data) - return nil -} - -func (r *RegionInfo) String() string { - if len(r._rawJSON) > 0 { - if value, err := core.StringifyJSON(r._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(r); err == nil { - return value - } - return fmt.Sprintf("%#v", r) -} - -type GameModeStatistics struct { - PlayerCount int64 `json:"player_count"` - Regions map[sdk.Identifier]*RegionStatistics `json:"regions,omitempty"` - - _rawJSON json.RawMessage -} - -func (g *GameModeStatistics) UnmarshalJSON(data []byte) error { - type unmarshaler GameModeStatistics - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *g = GameModeStatistics(value) - g._rawJSON = json.RawMessage(data) - return nil -} - -func (g *GameModeStatistics) String() string { - if len(g._rawJSON) > 0 { - if value, err := core.StringifyJSON(g._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(g); err == nil { - return value - } - return fmt.Sprintf("%#v", g) -} - -type RegionStatistics struct { - PlayerCount int64 `json:"player_count"` - - _rawJSON json.RawMessage -} - -func (r *RegionStatistics) UnmarshalJSON(data []byte) error { - type unmarshaler RegionStatistics - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *r = RegionStatistics(value) - r._rawJSON = json.RawMessage(data) - return nil -} - -func (r *RegionStatistics) String() string { - if len(r._rawJSON) > 0 { - if value, err := core.StringifyJSON(r._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(r); err == nil { - return value - } - return fmt.Sprintf("%#v", r) -} diff --git a/sdks/runtime/go/types.go b/sdks/runtime/go/types.go index 0aff886c97..8580736a38 100644 --- a/sdks/runtime/go/types.go +++ b/sdks/runtime/go/types.go @@ -6,11 +6,9 @@ import ( json "encoding/json" fmt "fmt" core "sdk/core" + time "time" ) -// Represent a resource's readable display name. -type DisplayName = string - type ErrorBody struct { Code string `json:"code"` Message string `json:"message"` @@ -47,8 +45,37 @@ func (e *ErrorBody) String() string { // Unstructured metadata relating to an error. Must be manually parsed. type ErrorMetadata = interface{} -// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. -type Identifier = string +// RFC3339 timestamp +type Timestamp = time.Time + +// Provided by watchable endpoints used in blocking loops. +type WatchResponse struct { + // Index indicating the version of the data responded. + // Pass this to `WatchQuery` to block and wait for the next response. + Index string `json:"index"` + + _rawJSON json.RawMessage +} + +func (w *WatchResponse) UnmarshalJSON(data []byte) error { + type unmarshaler WatchResponse + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *w = WatchResponse(value) + w._rawJSON = json.RawMessage(data) + return nil +} -// Documentation at https://jwt.io/ -type Jwt = string +func (w *WatchResponse) String() string { + if len(w._rawJSON) > 0 { + if value, err := core.StringifyJSON(w._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(w); err == nil { + return value + } + return fmt.Sprintf("%#v", w) +} diff --git a/sdks/runtime/go/upload/types.go b/sdks/runtime/go/upload/types.go new file mode 100644 index 0000000000..a22a35ab56 --- /dev/null +++ b/sdks/runtime/go/upload/types.go @@ -0,0 +1,81 @@ +// This file was auto-generated by Fern from our API Definition. + +package upload + +import ( + json "encoding/json" + fmt "fmt" + core "sdk/core" +) + +// A file being prepared to upload. +type PrepareFile struct { + // The path/filename of the file. + Path string `json:"path"` + // The MIME type of the file. + ContentType *string `json:"content_type,omitempty"` + // Unsigned 64 bit integer. + ContentLength int64 `json:"content_length"` + + _rawJSON json.RawMessage +} + +func (p *PrepareFile) UnmarshalJSON(data []byte) error { + type unmarshaler PrepareFile + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PrepareFile(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PrepareFile) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} + +// A presigned request used to upload files. Upload your file to the given URL via a PUT request. +type PresignedRequest struct { + // The name of the file to upload. This is the same as the one given in the upload prepare file. + Path string `json:"path"` + // The URL of the presigned request for which to upload your file to. + Url string `json:"url"` + // The byte offset for this multipart chunk. Always 0 if not a multipart upload. + ByteOffset int64 `json:"byte_offset"` + // Expected size of this upload. + ContentLength int64 `json:"content_length"` + + _rawJSON json.RawMessage +} + +func (p *PresignedRequest) UnmarshalJSON(data []byte) error { + type unmarshaler PresignedRequest + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *p = PresignedRequest(value) + p._rawJSON = json.RawMessage(data) + return nil +} + +func (p *PresignedRequest) String() string { + if len(p._rawJSON) > 0 { + if value, err := core.StringifyJSON(p._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(p); err == nil { + return value + } + return fmt.Sprintf("%#v", p) +} diff --git a/sdks/runtime/openapi/openapi.yml b/sdks/runtime/openapi/openapi.yml index 06659b0695..7c5a578262 100644 --- a/sdks/runtime/openapi/openapi.yml +++ b/sdks/runtime/openapi/openapi.yml @@ -3,27 +3,37 @@ info: title: Rivet API version: '' paths: - /matchmaker/lobbies/ready: - post: - description: >- - Marks the current lobby as ready to accept connections. Players will not - be able to connect to this lobby until the lobby is flagged as ready. - - This endpoint requires a [lobby - token](/docs/general/concepts/token-types#matchmaker-lobby) for - authentication, or a [development namespace - token](/docs/general/concepts/token-types#namespace-development) for - mock responses. When running on Rivet servers, you can access the given - lobby token from the - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment - variable. - operationId: matchmaker_lobbies_ready + /actors/{actor}: + get: + description: Gets a dynamic actor. + operationId: actor_get tags: - - MatchmakerLobbies - parameters: [] + - Actor + parameters: + - name: actor + in: path + description: The id of the actor to destroy + required: true + schema: + type: string + format: uuid + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string responses: - '204': + '200': description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ActorGetActorResponse' '400': description: '' content: @@ -62,38 +72,46 @@ paths: $ref: '#/components/schemas/ErrorBody' security: &ref_0 - BearerAuth: [] - /matchmaker/lobbies/closed: - put: - description: >- - If `is_closed` is `true`, the matchmaker will no longer route players to - the lobby. Players can still - - join using the /join endpoint (this can be disabled by the developer by - rejecting all new connections - - after setting the lobby to closed). - - Does not shutdown the lobby. - - - This endpoint requires a [lobby - token](/docs/general/concepts/token-types#matchmaker-lobby) for - - authentication, or a [development namespace - token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the - given lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment - variable. - operationId: matchmaker_lobbies_setClosed + delete: + description: Destroy a dynamic actor. + operationId: actor_destroy tags: - - MatchmakerLobbies - parameters: [] + - Actor + parameters: + - name: actor + in: path + description: The id of the actor to destroy + required: true + schema: + type: string + format: uuid + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string + - name: override_kill_timeout + in: query + description: >- + The duration to wait for in milliseconds before killing the actor. + This should be used to override the default kill timeout if a faster + time is needed, say for ignoring a graceful shutdown. + required: false + schema: + type: integer + format: int64 responses: - '204': + '200': description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ActorDestroyActorResponse' '400': description: '' content: @@ -131,41 +149,108 @@ paths: schema: $ref: '#/components/schemas/ErrorBody' security: *ref_0 - requestBody: - required: true - content: - application/json: - schema: - type: object - properties: - is_closed: - type: boolean - required: - - is_closed - /matchmaker/lobbies/state: - put: + /actors: + get: description: >- - Sets the state JSON of the current lobby. - - - This endpoint requires a [lobby - token](/docs/general/concepts/token-types#matchmaker-lobby) for - - authentication, or a [development namespace - token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the - given lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment - variable. - operationId: matchmaker_lobbies_setState + Lists all actors associated with the token used. Can be filtered by tags + in the query string. + operationId: actor_list tags: - - MatchmakerLobbies - parameters: [] + - Actor + parameters: + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string + - name: tags_json + in: query + required: false + schema: + type: string + - name: include_destroyed + in: query + required: false + schema: + type: boolean + - name: cursor + in: query + required: false + schema: + type: string + format: uuid responses: - '204': + '200': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ActorListActorsResponse' + '400': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + '403': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + '404': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + '408': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + '429': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + '500': + description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorBody' + security: *ref_0 + post: + description: Create a new dynamic actor. + operationId: actor_create + tags: + - Actor + parameters: + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string + responses: + '200': description: '' + content: + application/json: + schema: + $ref: '#/components/schemas/ActorCreateActorResponse' '400': description: '' content: @@ -204,43 +289,41 @@ paths: $ref: '#/components/schemas/ErrorBody' security: *ref_0 requestBody: - required: false + required: true content: application/json: - schema: {} - /matchmaker/lobbies/{lobby_id}/state: + schema: + $ref: '#/components/schemas/ActorCreateActorRequest' + /builds/{build}: get: - description: >- - Get the state of any lobby. - - - This endpoint requires a [lobby - token](/docs/general/concepts/token-types#matchmaker-lobby) for - - authentication, or a [development namespace - token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the - given lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment - variable. - operationId: matchmaker_lobbies_getState + description: Get a build. + operationId: actor_builds_get tags: - - MatchmakerLobbies + - ActorBuilds parameters: - - name: lobby_id + - name: build in: path required: true schema: type: string format: uuid + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string responses: '200': description: '' content: application/json: - schema: {} + schema: + $ref: '#/components/schemas/ActorGetBuildResponse' '400': description: '' content: @@ -278,37 +361,27 @@ paths: schema: $ref: '#/components/schemas/ErrorBody' security: *ref_0 - /matchmaker/lobbies/find: - post: + /builds: + get: description: >- - Finds a lobby based on the given criteria. - - If a lobby is not found and `prevent_auto_create_lobby` is `false`, - - a new lobby will be created. - - - When [tokenless - authentication](/docs/general/concepts/tokenless-authentication/web) is - enabled in - - your game namespace, this endpoint does not require a token to - authenticate. Otherwise, a - - [development namespace - token](/docs/general/concepts/token-types#namespace-development) can be - used - - for mock responses and a [public namespace - token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication. - operationId: matchmaker_lobbies_find + Lists all builds of the project associated with the token used. Can be + filtered by tags in the query string. + operationId: actor_builds_list tags: - - MatchmakerLobbies + - ActorBuilds parameters: - - name: origin - in: header + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string + - name: tags_json + in: query required: false schema: type: string @@ -318,7 +391,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/MatchmakerFindLobbyResponse' + $ref: '#/components/schemas/ActorListBuildsResponse' '400': description: '' content: @@ -356,70 +429,35 @@ paths: schema: $ref: '#/components/schemas/ErrorBody' security: *ref_0 - requestBody: - required: true - content: - application/json: - schema: - type: object - properties: - game_modes: - type: array - items: - type: string - regions: - type: array - items: - type: string - prevent_auto_create_lobby: - type: boolean - tags: - type: object - additionalProperties: - type: string - max_players: - type: integer - captcha: - $ref: '#/components/schemas/CaptchaConfig' - verification_data: {} - required: - - game_modes - /matchmaker/lobbies/join: - post: - description: >- - Joins a specific lobby. - - This request will use the direct player count configured for the - - lobby group. - - - When [tokenless - authentication](/docs/general/concepts/tokenless-authentication/web) is - enabled in - - your game namespace, this endpoint does not require a token to - authenticate. Otherwise, a - - [development namespace - token](/docs/general/concepts/token-types#namespace-development) can be - used - - for mock responses and a [public namespace - token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication. - operationId: matchmaker_lobbies_join + /builds/{build}/tags: + patch: + operationId: actor_builds_patchTags tags: - - MatchmakerLobbies - parameters: [] + - ActorBuilds + parameters: + - name: build + in: path + required: true + schema: + type: string + format: uuid + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string responses: '200': description: '' content: application/json: schema: - $ref: '#/components/schemas/MatchmakerJoinLobbyResponse' + $ref: '#/components/schemas/ActorPatchBuildTagsResponse' '400': description: '' content: @@ -462,47 +500,31 @@ paths: content: application/json: schema: - type: object - properties: - lobby_id: - type: string - captcha: - $ref: '#/components/schemas/CaptchaConfig' - verification_data: {} - required: - - lobby_id - /matchmaker/lobbies/create: + $ref: '#/components/schemas/ActorPatchBuildTagsRequest' + /builds/prepare: post: - description: >- - Creates a custom lobby. - - - When [tokenless - authentication](/docs/general/concepts/tokenless-authentication/web) is - enabled in - - your game namespace, this endpoint does not require a token to - authenticate. Otherwise, a - - [development namespace - token](/docs/general/concepts/token-types#namespace-development) can be - used - - for mock responses and a [public namespace - token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication. - operationId: matchmaker_lobbies_create + description: Creates a new project build for the given project. + operationId: actor_builds_prepare tags: - - MatchmakerLobbies - parameters: [] + - ActorBuilds + parameters: + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string responses: '200': description: '' content: application/json: schema: - $ref: '#/components/schemas/MatchmakerCreateLobbyResponse' + $ref: '#/components/schemas/ActorPrepareBuildResponse' '400': description: '' content: @@ -545,63 +567,33 @@ paths: content: application/json: schema: - type: object - properties: - game_mode: - type: string - region: - type: string - publicity: - $ref: '#/components/schemas/MatchmakerCustomLobbyPublicity' - tags: - type: object - additionalProperties: - type: string - max_players: - type: integer - lobby_config: {} - captcha: - $ref: '#/components/schemas/CaptchaConfig' - verification_data: {} - required: - - game_mode - /matchmaker/lobbies/list: - get: - description: >- - Lists all open lobbies. - - - When [tokenless - authentication](/docs/general/concepts/tokenless-authentication/web) is - enabled in - - your game namespace, this endpoint does not require a token to - authenticate. Otherwise, a - - [development namespace - token](/docs/general/concepts/token-types#namespace-development) can be - used - - for mock responses and a [public namespace - token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication. - operationId: matchmaker_lobbies_list + $ref: '#/components/schemas/ActorPrepareBuildRequest' + /builds/{build}/complete: + post: + description: Marks an upload as complete. + operationId: actor_builds_complete tags: - - MatchmakerLobbies + - ActorBuilds parameters: - - name: include_state + - name: build + in: path + required: true + schema: + type: string + format: uuid + - name: project in: query required: false schema: - type: boolean + type: string + - name: environment + in: query + required: false + schema: + type: string responses: - '200': + '204': description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/MatchmakerListLobbiesResponse' '400': description: '' content: @@ -639,211 +631,47 @@ paths: schema: $ref: '#/components/schemas/ErrorBody' security: *ref_0 - /matchmaker/players/connected: - post: - description: >- - Validates the player token is valid and has not already been consumed - then - - marks the player as connected. - - - # Player Tokens and Reserved Slots - - - Player tokens reserve a spot in the lobby until they expire. This allows - for - - precise matchmaking up to exactly the lobby's player limit, which is - - important for games with small lobbies and a high influx of players. - - By calling this endpoint with the player token, the player's spot is - marked - - as connected and will not expire. If this endpoint is never called, the - - player's token will expire and this spot will be filled by another - player. - - - # Anti-Botting - - - Player tokens are only issued by caling `lobbies.join`, calling - `lobbies.find`, or - - from the `GlobalEventMatchmakerLobbyJoin` event. - - These endpoints have anti-botting measures (i.e. enforcing max player - - limits, captchas, and detecting bots), so valid player tokens provide - some - - confidence that the player is not a bot. - - Therefore, it's important to make sure the token is valid by waiting for - - this endpoint to return OK before allowing the connected socket to do - - anything else. If this endpoint returns an error, the socket should be - - disconnected immediately. - - - # How to Transmit the Player Token - - - The client is responsible for acquiring the player token by caling - - `lobbies.join`, calling `lobbies.find`, or from the - `GlobalEventMatchmakerLobbyJoin` - - event. Beyond that, it's up to the developer how the player token is - - transmitted to the lobby. - - If using WebSockets, the player token can be transmitted as a query - - parameter. - - Otherwise, the player token will likely be automatically sent by the - client - - once the socket opens. As mentioned above, nothing else should happen - until - - the player token is validated. - operationId: matchmaker_players_connected - tags: - - MatchmakerPlayers - parameters: [] - responses: - '204': - description: '' - '400': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '403': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '404': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '408': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '429': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '500': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - security: *ref_0 - requestBody: - required: true - content: - application/json: - schema: - type: object - properties: - player_token: - type: string - required: - - player_token - /matchmaker/players/disconnected: - post: - description: >- - Marks a player as disconnected. # Ghost Players If players are not - marked as disconnected, lobbies will result with "ghost players" that - the matchmaker thinks exist but are no longer connected to the lobby. - operationId: matchmaker_players_disconnected - tags: - - MatchmakerPlayers - parameters: [] - responses: - '204': - description: '' - '400': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '403': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '404': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '408': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '429': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - '500': - description: '' - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - security: *ref_0 - requestBody: - required: true - content: - application/json: - schema: - type: object - properties: - player_token: - type: string - required: - - player_token - /matchmaker/players/statistics: + /actors/{actor}/logs: get: - description: Gives matchmaker statistics about the players in game. - operationId: matchmaker_players_getStatistics + description: Returns the logs for a given actor. + operationId: actor_logs_get tags: - - MatchmakerPlayers - parameters: [] + - ActorLogs + parameters: + - name: actor + in: path + required: true + schema: + type: string + format: uuid + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string + - name: stream + in: query + required: true + schema: + $ref: '#/components/schemas/ActorLogStream' + - name: watch_index + in: query + description: A query parameter denoting the requests watch index. + required: false + schema: + type: string responses: '200': description: '' content: application/json: schema: - $ref: '#/components/schemas/MatchmakerGetStatisticsResponse' + $ref: '#/components/schemas/ActorGetActorLogsResponse' '400': description: '' content: @@ -881,26 +709,29 @@ paths: schema: $ref: '#/components/schemas/ErrorBody' security: *ref_0 - /matchmaker/regions: + /regions: get: - description: >- - Returns a list of regions available to this namespace. - - Regions are sorted by most optimal to least optimal. The player's IP - address - - is used to calculate the regions' optimality. - operationId: matchmaker_regions_list + operationId: actor_regions_list tags: - - MatchmakerRegions - parameters: [] + - ActorRegions + parameters: + - name: project + in: query + required: false + schema: + type: string + - name: environment + in: query + required: false + schema: + type: string responses: '200': description: '' content: application/json: schema: - $ref: '#/components/schemas/MatchmakerListRegionsResponse' + $ref: '#/components/schemas/ActorListRegionsResponse' '400': description: '' content: @@ -940,334 +771,468 @@ paths: security: *ref_0 components: schemas: - CaptchaConfig: + ActorGetActorResponse: type: object - description: Methods to verify a captcha properties: - hcaptcha: - $ref: '#/components/schemas/CaptchaConfigHcaptcha' - turnstile: - $ref: '#/components/schemas/CaptchaConfigTurnstile' - CaptchaConfigHcaptcha: + actor: + $ref: '#/components/schemas/ActorActor' + required: + - actor + ActorCreateActorRequest: type: object - description: Captcha configuration. properties: - client_response: + region: type: string + tags: {} + runtime: + $ref: '#/components/schemas/ActorCreateActorRuntimeRequest' + network: + $ref: '#/components/schemas/ActorCreateActorNetworkRequest' + resources: + $ref: '#/components/schemas/ActorResources' + lifecycle: + $ref: '#/components/schemas/ActorLifecycle' required: - - client_response - CaptchaConfigTurnstile: + - region + - tags + - runtime + - resources + ActorCreateActorRuntimeRequest: type: object - description: Captcha configuration. properties: - client_response: + build: type: string + format: uuid + arguments: + type: array + items: + type: string + environment: + type: object + additionalProperties: + type: string required: - - client_response - Identifier: - type: string - description: >- - A human readable short identifier used to references resources. - Different than a `uuid` because this is intended to be human readable. - Different than `DisplayName` because this should not include special - characters and be short. - Jwt: - type: string - description: Documentation at https://jwt.io/ - DisplayName: - type: string - description: Represent a resource's readable display name. - ErrorMetadata: - description: Unstructured metadata relating to an error. Must be manually parsed. - ErrorBody: + - build + ActorCreateActorNetworkRequest: type: object properties: - code: - type: string - message: - type: string - ray_id: - type: string - documentation: - type: string - metadata: - $ref: '#/components/schemas/ErrorMetadata' + mode: + $ref: '#/components/schemas/ActorNetworkMode' + ports: + type: object + additionalProperties: + $ref: '#/components/schemas/ActorCreateActorPortRequest' + ActorCreateActorPortRequest: + type: object + properties: + protocol: + $ref: '#/components/schemas/ActorPortProtocol' + internal_port: + type: integer + routing: + $ref: '#/components/schemas/ActorPortRouting' required: - - code - - message - - ray_id - GeoCoord: + - protocol + ActorCreateActorResponse: type: object - description: Geographical coordinates for a location on Planet Earth. properties: - latitude: - type: number - format: double - longitude: - type: number - format: double + actor: + $ref: '#/components/schemas/ActorActor' + description: The actor that was created required: - - latitude - - longitude - GeoDistance: + - actor + ActorDestroyActorResponse: + type: object + properties: {} + ActorListActorsResponse: type: object - description: Distance available in multiple units. properties: - kilometers: - type: number - format: double - miles: - type: number - format: double + actors: + type: array + items: + $ref: '#/components/schemas/ActorActor' + description: A list of actors for the project associated with the token. required: - - kilometers - - miles - MatchmakerLobbyInfo: + - actors + ActorGetBuildResponse: type: object - description: A public lobby in the lobby list. properties: - region_id: - type: string - game_mode_id: - type: string - lobby_id: - type: string - format: uuid - max_players_normal: - type: integer - max_players_direct: - type: integer - max_players_party: - type: integer - total_player_count: - type: integer - state: {} + build: + $ref: '#/components/schemas/ActorBuild' required: - - region_id - - game_mode_id - - lobby_id - - max_players_normal - - max_players_direct - - max_players_party - - total_player_count - MatchmakerGameModeInfo: + - build + ActorListBuildsResponse: type: object - description: A game mode that the player can join. properties: - game_mode_id: - $ref: '#/components/schemas/Identifier' + builds: + type: array + items: + $ref: '#/components/schemas/ActorBuild' + description: A list of builds for the project associated with the token. required: - - game_mode_id - MatchmakerRegionInfo: + - builds + ActorPatchBuildTagsRequest: type: object - description: A region that the player can connect to. properties: - region_id: - $ref: '#/components/schemas/Identifier' - provider_display_name: - $ref: '#/components/schemas/DisplayName' - region_display_name: - $ref: '#/components/schemas/DisplayName' - datacenter_coord: - $ref: '#/components/schemas/GeoCoord' - datacenter_distance_from_client: - $ref: '#/components/schemas/GeoDistance' + tags: {} + exclusive_tags: + type: array + items: + type: string + description: Removes the given tag keys from all other builds. required: - - region_id - - provider_display_name - - region_display_name - - datacenter_coord - - datacenter_distance_from_client - MatchmakerJoinLobby: + - tags + ActorPatchBuildTagsResponse: + type: object + properties: {} + ActorPrepareBuildRequest: type: object - description: A matchmaker lobby. properties: - lobby_id: + name: type: string - format: uuid - region: - $ref: '#/components/schemas/MatchmakerJoinRegion' - ports: - type: object - additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - description: '**Deprecated**' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' - description: '**Deprecated**' + image_tag: + type: string + description: A tag given to the project build. + image_file: + $ref: '#/components/schemas/UploadPrepareFile' + multipart_upload: + type: boolean + kind: + $ref: '#/components/schemas/ActorBuildKind' + compression: + $ref: '#/components/schemas/ActorBuildCompression' + prewarm_regions: + type: array + items: + type: string required: - - lobby_id - - region - - ports - - player - MatchmakerJoinRegion: + - name + - image_file + ActorPrepareBuildResponse: type: object - description: A matchmaker lobby region. properties: - region_id: - $ref: '#/components/schemas/Identifier' - display_name: - $ref: '#/components/schemas/DisplayName' + build: + type: string + format: uuid + image_presigned_request: + $ref: '#/components/schemas/UploadPresignedRequest' + image_presigned_requests: + type: array + items: + $ref: '#/components/schemas/UploadPresignedRequest' required: - - region_id - - display_name - MatchmakerJoinPort: + - build + ActorBuildKind: + type: string + enum: + - docker_image + - oci_bundle + - javascript + ActorBuildCompression: + type: string + enum: + - none + - lz4 + ActorActor: type: object properties: - host: + id: type: string - description: The host for the given port. Will be null if using a port range. - hostname: + format: uuid + region: type: string - port: + tags: {} + runtime: + $ref: '#/components/schemas/ActorRuntime' + network: + $ref: '#/components/schemas/ActorNetwork' + resources: + $ref: '#/components/schemas/ActorResources' + lifecycle: + $ref: '#/components/schemas/ActorLifecycle' + created_at: type: integer - description: The port number for this lobby. Will be null if using a port range. - port_range: - $ref: '#/components/schemas/MatchmakerJoinPortRange' - is_tls: - type: boolean - description: >- - Whether or not this lobby port uses TLS. You cannot mix a non-TLS - and TLS ports. + format: int64 + started_at: + type: integer + format: int64 + destroyed_at: + type: integer + format: int64 required: - - hostname - - is_tls - MatchmakerJoinPortRange: + - id + - region + - tags + - runtime + - network + - resources + - lifecycle + - created_at + ActorRuntime: type: object - description: Inclusive range of ports that can be connected to. properties: - min: - type: integer - description: Minimum port that can be connected to. Inclusive range. - max: - type: integer - description: Maximum port that can be connected to. Inclusive range. + build: + type: string + format: uuid + arguments: + type: array + items: + type: string + environment: + type: object + additionalProperties: + type: string required: - - min - - max - MatchmakerJoinPlayer: + - build + ActorLifecycle: + type: object + properties: + kill_timeout: + type: integer + format: int64 + description: >- + The duration to wait for in milliseconds before killing the actor. + This should be set to a safe default, and can be overridden during a + DELETE request if needed. + ActorResources: type: object - description: A matchmaker lobby player. properties: - token: - $ref: '#/components/schemas/Jwt' + cpu: + type: integer description: >- - Pass this token through the socket to the lobby server. The lobby - server will validate this token with `PlayerConnected.player_token` + The number of CPU cores in millicores, or 1/1000 of a core. For + example, + + 1/8 of a core would be 125 millicores, and 1 core would be 1000 + + millicores. + memory: + type: integer + description: The amount of memory in megabytes required: - - token - MatchmakerCustomLobbyPublicity: - type: string - enum: - - public - - private - MatchmakerFindLobbyResponse: + - cpu + - memory + ActorNetwork: type: object properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' + mode: + $ref: '#/components/schemas/ActorNetworkMode' ports: type: object additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' + $ref: '#/components/schemas/ActorPort' required: - - lobby + - mode - ports - - player - MatchmakerJoinLobbyResponse: + ActorNetworkMode: + type: string + enum: + - bridge + - host + ActorPort: type: object properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' - ports: - type: object - additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' + protocol: + $ref: '#/components/schemas/ActorPortProtocol' + internal_port: + type: integer + public_hostname: + type: string + public_port: + type: integer + routing: + $ref: '#/components/schemas/ActorPortRouting' required: - - lobby - - ports - - player - MatchmakerCreateLobbyResponse: + - protocol + - routing + ActorPortProtocol: + type: string + enum: + - http + - https + - tcp + - tcp_tls + - udp + ActorPortRouting: type: object properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' - ports: + guard: + $ref: '#/components/schemas/ActorGuardRouting' + host: + $ref: '#/components/schemas/ActorHostRouting' + ActorGuardRouting: + type: object + properties: + authorization: + $ref: '#/components/schemas/ActorPortAuthorization' + ActorPortAuthorization: + type: object + properties: + bearer: + type: string + query: + $ref: '#/components/schemas/ActorPortQueryAuthorization' + ActorPortQueryAuthorization: + type: object + properties: + key: + type: string + value: + type: string + required: + - key + - value + ActorHostRouting: + type: object + properties: {} + ActorBuild: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + created_at: + $ref: '#/components/schemas/Timestamp' + content_length: + type: integer + format: int64 + description: Unsigned 64 bit integer. + tags: type: object additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' + type: string + description: Tags of this build required: - - lobby - - ports - - player - MatchmakerListLobbiesResponse: + - id + - name + - created_at + - content_length + - tags + ActorRegion: + type: object + properties: + id: + type: string + name: + type: string + required: + - id + - name + ActorGetActorLogsResponse: type: object properties: - game_modes: + lines: type: array items: - $ref: '#/components/schemas/MatchmakerGameModeInfo' - regions: + type: string + description: Sorted old to new. + timestamps: type: array items: - $ref: '#/components/schemas/MatchmakerRegionInfo' - lobbies: + type: string + description: Sorted old to new. + watch: + $ref: '#/components/schemas/WatchResponse' + required: + - lines + - timestamps + - watch + ActorLogStream: + type: string + enum: + - std_out + - std_err + ActorListRegionsResponse: + type: object + properties: + regions: type: array items: - $ref: '#/components/schemas/MatchmakerLobbyInfo' + $ref: '#/components/schemas/ActorRegion' required: - - game_modes - regions - - lobbies - MatchmakerGetStatisticsResponse: + WatchResponse: type: object + description: Provided by watchable endpoints used in blocking loops. properties: - player_count: - type: integer - format: int64 - game_modes: - type: object - additionalProperties: - $ref: '#/components/schemas/MatchmakerGameModeStatistics' + index: + type: string + description: |- + Index indicating the version of the data responded. + Pass this to `WatchQuery` to block and wait for the next response. required: - - player_count - - game_modes - MatchmakerGameModeStatistics: + - index + Timestamp: + type: string + format: date-time + description: RFC3339 timestamp + ErrorMetadata: + description: Unstructured metadata relating to an error. Must be manually parsed. + ErrorBody: type: object properties: - player_count: - type: integer - format: int64 - regions: - type: object - additionalProperties: - $ref: '#/components/schemas/MatchmakerRegionStatistics' + code: + type: string + message: + type: string + ray_id: + type: string + documentation: + type: string + metadata: + $ref: '#/components/schemas/ErrorMetadata' required: - - player_count - - regions - MatchmakerRegionStatistics: + - code + - message + - ray_id + UploadPresignedRequest: type: object + description: >- + A presigned request used to upload files. Upload your file to the given + URL via a PUT request. properties: - player_count: + path: + type: string + description: >- + The name of the file to upload. This is the same as the one given in + the upload prepare file. + url: + type: string + description: The URL of the presigned request for which to upload your file to. + byte_offset: type: integer format: int64 + description: >- + The byte offset for this multipart chunk. Always 0 if not a + multipart upload. + content_length: + type: integer + format: int64 + description: Expected size of this upload. required: - - player_count - MatchmakerListRegionsResponse: + - path + - url + - byte_offset + - content_length + UploadPrepareFile: type: object + description: A file being prepared to upload. properties: - regions: - type: array - items: - $ref: '#/components/schemas/MatchmakerRegionInfo' + path: + type: string + description: The path/filename of the file. + content_type: + type: string + description: The MIME type of the file. + content_length: + type: integer + format: int64 + description: Unsigned 64 bit integer. required: - - regions + - path + - content_length securitySchemes: BearerAuth: type: http diff --git a/sdks/runtime/openapi_compat/openapi.yml b/sdks/runtime/openapi_compat/openapi.yml index d28e3aa8c4..4eab377736 100644 --- a/sdks/runtime/openapi_compat/openapi.yml +++ b/sdks/runtime/openapi_compat/openapi.yml @@ -1,330 +1,462 @@ components: schemas: - CaptchaConfig: - description: Methods to verify a captcha + ActorActor: properties: - hcaptcha: - $ref: '#/components/schemas/CaptchaConfigHcaptcha' - turnstile: - $ref: '#/components/schemas/CaptchaConfigTurnstile' - type: object - CaptchaConfigHcaptcha: - description: Captcha configuration. - properties: - client_response: + created_at: + format: int64 + type: integer + destroyed_at: + format: int64 + type: integer + id: + format: uuid + type: string + lifecycle: + $ref: '#/components/schemas/ActorLifecycle' + network: + $ref: '#/components/schemas/ActorNetwork' + region: type: string + resources: + $ref: '#/components/schemas/ActorResources' + runtime: + $ref: '#/components/schemas/ActorRuntime' + started_at: + format: int64 + type: integer + tags: {} required: - - client_response + - id + - region + - tags + - runtime + - network + - resources + - lifecycle + - created_at type: object - CaptchaConfigTurnstile: - description: Captcha configuration. + ActorBuild: properties: - client_response: + content_length: + description: Unsigned 64 bit integer. + format: int64 + type: integer + created_at: + $ref: '#/components/schemas/Timestamp' + id: + format: uuid + type: string + name: type: string + tags: + additionalProperties: + type: string + description: Tags of this build + type: object required: - - client_response + - id + - name + - created_at + - content_length + - tags type: object - DisplayName: - description: Represent a resource's readable display name. + ActorBuildCompression: + enum: + - none + - lz4 type: string - ErrorBody: + ActorBuildKind: + enum: + - docker_image + - oci_bundle + - javascript + type: string + ActorCreateActorNetworkRequest: properties: - code: - type: string - documentation: - type: string - message: - type: string - metadata: - $ref: '#/components/schemas/ErrorMetadata' - ray_id: - type: string + mode: + $ref: '#/components/schemas/ActorNetworkMode' + ports: + additionalProperties: + $ref: '#/components/schemas/ActorCreateActorPortRequest' + type: object + type: object + ActorCreateActorPortRequest: + properties: + internal_port: + type: integer + protocol: + $ref: '#/components/schemas/ActorPortProtocol' + routing: + $ref: '#/components/schemas/ActorPortRouting' required: - - code - - message - - ray_id + - protocol type: object - ErrorMetadata: - description: Unstructured metadata relating to an error. Must be manually parsed. - GeoCoord: - description: Geographical coordinates for a location on Planet Earth. + ActorCreateActorRequest: properties: - latitude: - format: double - type: number - longitude: - format: double - type: number + lifecycle: + $ref: '#/components/schemas/ActorLifecycle' + network: + $ref: '#/components/schemas/ActorCreateActorNetworkRequest' + region: + type: string + resources: + $ref: '#/components/schemas/ActorResources' + runtime: + $ref: '#/components/schemas/ActorCreateActorRuntimeRequest' + tags: {} required: - - latitude - - longitude + - region + - tags + - runtime + - resources type: object - GeoDistance: - description: Distance available in multiple units. + ActorCreateActorResponse: properties: - kilometers: - format: double - type: number - miles: - format: double - type: number + actor: + $ref: '#/components/schemas/ActorActor' + description: The actor that was created required: - - kilometers - - miles + - actor type: object - Identifier: - description: A human readable short identifier used to references resources. - Different than a `uuid` because this is intended to be human readable. Different - than `DisplayName` because this should not include special characters and - be short. - type: string - Jwt: - description: Documentation at https://jwt.io/ - type: string - MatchmakerCreateLobbyResponse: + ActorCreateActorRuntimeRequest: properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' - ports: + arguments: + items: + type: string + type: array + build: + format: uuid + type: string + environment: additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' + type: string type: object required: - - lobby - - ports - - player + - build type: object - MatchmakerCustomLobbyPublicity: - enum: - - public - - private - type: string - MatchmakerFindLobbyResponse: + ActorDestroyActorResponse: + properties: {} + type: object + ActorGetActorLogsResponse: properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' - ports: - additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - type: object + lines: + description: Sorted old to new. + items: + type: string + type: array + timestamps: + description: Sorted old to new. + items: + type: string + type: array + watch: + $ref: '#/components/schemas/WatchResponse' required: - - lobby - - ports - - player + - lines + - timestamps + - watch type: object - MatchmakerGameModeInfo: - description: A game mode that the player can join. + ActorGetActorResponse: properties: - game_mode_id: - $ref: '#/components/schemas/Identifier' + actor: + $ref: '#/components/schemas/ActorActor' required: - - game_mode_id + - actor type: object - MatchmakerGameModeStatistics: + ActorGetBuildResponse: properties: - player_count: - format: int64 - type: integer - regions: - additionalProperties: - $ref: '#/components/schemas/MatchmakerRegionStatistics' - type: object + build: + $ref: '#/components/schemas/ActorBuild' required: - - player_count - - regions + - build type: object - MatchmakerGetStatisticsResponse: + ActorGuardRouting: properties: - game_modes: - additionalProperties: - $ref: '#/components/schemas/MatchmakerGameModeStatistics' - type: object - player_count: + authorization: + $ref: '#/components/schemas/ActorPortAuthorization' + type: object + ActorHostRouting: + properties: {} + type: object + ActorLifecycle: + properties: + kill_timeout: + description: The duration to wait for in milliseconds before killing the + actor. This should be set to a safe default, and can be overridden during + a DELETE request if needed. format: int64 type: integer + type: object + ActorListActorsResponse: + properties: + actors: + description: A list of actors for the project associated with the token. + items: + $ref: '#/components/schemas/ActorActor' + type: array required: - - player_count - - game_modes + - actors type: object - MatchmakerJoinLobby: - description: A matchmaker lobby. + ActorListBuildsResponse: properties: - lobby_id: - format: uuid - type: string - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' - description: '**Deprecated**' - ports: - additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' - description: '**Deprecated**' - type: object - region: - $ref: '#/components/schemas/MatchmakerJoinRegion' + builds: + description: A list of builds for the project associated with the token. + items: + $ref: '#/components/schemas/ActorBuild' + type: array required: - - lobby_id - - region - - ports - - player + - builds type: object - MatchmakerJoinLobbyResponse: + ActorListRegionsResponse: properties: - lobby: - $ref: '#/components/schemas/MatchmakerJoinLobby' - player: - $ref: '#/components/schemas/MatchmakerJoinPlayer' + regions: + items: + $ref: '#/components/schemas/ActorRegion' + type: array + required: + - regions + type: object + ActorLogStream: + enum: + - std_out + - std_err + type: string + ActorNetwork: + properties: + mode: + $ref: '#/components/schemas/ActorNetworkMode' ports: additionalProperties: - $ref: '#/components/schemas/MatchmakerJoinPort' + $ref: '#/components/schemas/ActorPort' type: object required: - - lobby + - mode - ports - - player type: object - MatchmakerJoinPlayer: - description: A matchmaker lobby player. + ActorNetworkMode: + enum: + - bridge + - host + type: string + ActorPatchBuildTagsRequest: properties: - token: - $ref: '#/components/schemas/Jwt' - description: Pass this token through the socket to the lobby server. The - lobby server will validate this token with `PlayerConnected.player_token` + exclusive_tags: + description: Removes the given tag keys from all other builds. + items: + type: string + type: array + tags: {} required: - - token + - tags type: object - MatchmakerJoinPort: + ActorPatchBuildTagsResponse: + properties: {} + type: object + ActorPort: properties: - host: - description: The host for the given port. Will be null if using a port range. - type: string - hostname: + internal_port: + type: integer + protocol: + $ref: '#/components/schemas/ActorPortProtocol' + public_hostname: type: string - is_tls: - description: Whether or not this lobby port uses TLS. You cannot mix a non-TLS - and TLS ports. - type: boolean - port: - description: The port number for this lobby. Will be null if using a port - range. + public_port: type: integer - port_range: - $ref: '#/components/schemas/MatchmakerJoinPortRange' + routing: + $ref: '#/components/schemas/ActorPortRouting' required: - - hostname - - is_tls + - protocol + - routing type: object - MatchmakerJoinPortRange: - description: Inclusive range of ports that can be connected to. + ActorPortAuthorization: properties: - max: - description: Maximum port that can be connected to. Inclusive range. - type: integer - min: - description: Minimum port that can be connected to. Inclusive range. - type: integer - required: - - min - - max + bearer: + type: string + query: + $ref: '#/components/schemas/ActorPortQueryAuthorization' type: object - MatchmakerJoinRegion: - description: A matchmaker lobby region. + ActorPortProtocol: + enum: + - http + - https + - tcp + - tcp_tls + - udp + type: string + ActorPortQueryAuthorization: properties: - display_name: - $ref: '#/components/schemas/DisplayName' - region_id: - $ref: '#/components/schemas/Identifier' + key: + type: string + value: + type: string required: - - region_id - - display_name + - key + - value type: object - MatchmakerListLobbiesResponse: + ActorPortRouting: properties: - game_modes: - items: - $ref: '#/components/schemas/MatchmakerGameModeInfo' - type: array - lobbies: - items: - $ref: '#/components/schemas/MatchmakerLobbyInfo' - type: array - regions: + guard: + $ref: '#/components/schemas/ActorGuardRouting' + host: + $ref: '#/components/schemas/ActorHostRouting' + type: object + ActorPrepareBuildRequest: + properties: + compression: + $ref: '#/components/schemas/ActorBuildCompression' + image_file: + $ref: '#/components/schemas/UploadPrepareFile' + image_tag: + description: A tag given to the project build. + type: string + kind: + $ref: '#/components/schemas/ActorBuildKind' + multipart_upload: + type: boolean + name: + type: string + prewarm_regions: items: - $ref: '#/components/schemas/MatchmakerRegionInfo' + type: string type: array required: - - game_modes - - regions - - lobbies + - name + - image_file type: object - MatchmakerListRegionsResponse: + ActorPrepareBuildResponse: properties: - regions: + build: + format: uuid + type: string + image_presigned_request: + $ref: '#/components/schemas/UploadPresignedRequest' + image_presigned_requests: items: - $ref: '#/components/schemas/MatchmakerRegionInfo' + $ref: '#/components/schemas/UploadPresignedRequest' type: array required: - - regions + - build type: object - MatchmakerLobbyInfo: - description: A public lobby in the lobby list. + ActorRegion: properties: - game_mode_id: + id: type: string - lobby_id: - format: uuid + name: type: string - max_players_direct: - type: integer - max_players_normal: + required: + - id + - name + type: object + ActorResources: + properties: + cpu: + description: 'The number of CPU cores in millicores, or 1/1000 of a core. + For example, + + 1/8 of a core would be 125 millicores, and 1 core would be 1000 + + millicores.' type: integer - max_players_party: + memory: + description: The amount of memory in megabytes type: integer - region_id: + required: + - cpu + - memory + type: object + ActorRuntime: + properties: + arguments: + items: + type: string + type: array + build: + format: uuid type: string - state: {} - total_player_count: - type: integer + environment: + additionalProperties: + type: string + type: object required: - - region_id - - game_mode_id - - lobby_id - - max_players_normal - - max_players_direct - - max_players_party - - total_player_count + - build type: object - MatchmakerRegionInfo: - description: A region that the player can connect to. + ErrorBody: properties: - datacenter_coord: - $ref: '#/components/schemas/GeoCoord' - datacenter_distance_from_client: - $ref: '#/components/schemas/GeoDistance' - provider_display_name: - $ref: '#/components/schemas/DisplayName' - region_display_name: - $ref: '#/components/schemas/DisplayName' - region_id: - $ref: '#/components/schemas/Identifier' + code: + type: string + documentation: + type: string + message: + type: string + metadata: + $ref: '#/components/schemas/ErrorMetadata' + ray_id: + type: string + required: + - code + - message + - ray_id + type: object + ErrorMetadata: + description: Unstructured metadata relating to an error. Must be manually parsed. + Timestamp: + description: RFC3339 timestamp + format: date-time + type: string + UploadPrepareFile: + description: A file being prepared to upload. + properties: + content_length: + description: Unsigned 64 bit integer. + format: int64 + type: integer + content_type: + description: The MIME type of the file. + type: string + path: + description: The path/filename of the file. + type: string required: - - region_id - - provider_display_name - - region_display_name - - datacenter_coord - - datacenter_distance_from_client + - path + - content_length type: object - MatchmakerRegionStatistics: + UploadPresignedRequest: + description: A presigned request used to upload files. Upload your file to the + given URL via a PUT request. properties: - player_count: + byte_offset: + description: The byte offset for this multipart chunk. Always 0 if not a + multipart upload. + format: int64 + type: integer + content_length: + description: Expected size of this upload. format: int64 type: integer + path: + description: The name of the file to upload. This is the same as the one + given in the upload prepare file. + type: string + url: + description: The URL of the presigned request for which to upload your file + to. + type: string required: - - player_count + - path + - url + - byte_offset + - content_length + type: object + WatchResponse: + description: Provided by watchable endpoints used in blocking loops. + properties: + index: + description: 'Index indicating the version of the data responded. + + Pass this to `WatchQuery` to block and wait for the next response.' + type: string + required: + - index type: object securitySchemes: BearerAuth: @@ -335,43 +467,44 @@ info: version: 0.0.1 openapi: 3.0.1 paths: - /matchmaker/lobbies/closed: - put: - description: 'If `is_closed` is `true`, the matchmaker will no longer route - players to the lobby. Players can still - - join using the /join endpoint (this can be disabled by the developer by rejecting - all new connections - - after setting the lobby to closed). - - Does not shutdown the lobby. - - - This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) - for - - authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the given - lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable.' - operationId: matchmaker_lobbies_setClosed - parameters: [] - requestBody: - content: - application/json: - schema: - properties: - is_closed: - type: boolean - required: - - is_closed - type: object - required: true + /actors: + get: + description: Lists all actors associated with the token used. Can be filtered + by tags in the query string. + operationId: actor_list + parameters: + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string + - in: query + name: tags_json + required: false + schema: + type: string + - in: query + name: include_destroyed + required: false + schema: + type: boolean + - in: query + name: cursor + required: false + schema: + format: uuid + type: string responses: - '204': + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ActorListActorsResponse' description: '' '400': content: @@ -412,57 +545,33 @@ paths: security: &id001 - BearerAuth: [] tags: - - MatchmakerLobbies - /matchmaker/lobbies/create: + - Actor post: - description: 'Creates a custom lobby. - - - When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) - is enabled in - - your game namespace, this endpoint does not require a token to authenticate. - Otherwise, a - - [development namespace token](/docs/general/concepts/token-types#namespace-development) - can be used - - for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication.' - operationId: matchmaker_lobbies_create - parameters: [] + description: Create a new dynamic actor. + operationId: actor_create + parameters: + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string requestBody: content: application/json: schema: - properties: - captcha: - $ref: '#/components/schemas/CaptchaConfig' - game_mode: - type: string - lobby_config: {} - max_players: - type: integer - publicity: - $ref: '#/components/schemas/MatchmakerCustomLobbyPublicity' - region: - type: string - tags: - additionalProperties: - type: string - type: object - verification_data: {} - required: - - game_mode - type: object + $ref: '#/components/schemas/ActorCreateActorRequest' required: true responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerCreateLobbyResponse' + $ref: '#/components/schemas/ActorCreateActorResponse' description: '' '400': content: @@ -502,69 +611,44 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/find: - post: - description: 'Finds a lobby based on the given criteria. - - If a lobby is not found and `prevent_auto_create_lobby` is `false`, - - a new lobby will be created. - - - When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) - is enabled in - - your game namespace, this endpoint does not require a token to authenticate. - Otherwise, a - - [development namespace token](/docs/general/concepts/token-types#namespace-development) - can be used - - for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication.' - operationId: matchmaker_lobbies_find + - Actor + /actors/{actor}: + delete: + description: Destroy a dynamic actor. + operationId: actor_destroy parameters: - - in: header - name: origin + - description: The id of the actor to destroy + in: path + name: actor + required: true + schema: + format: uuid + type: string + - in: query + name: project required: false schema: type: string - requestBody: - content: - application/json: - schema: - properties: - captcha: - $ref: '#/components/schemas/CaptchaConfig' - game_modes: - items: - type: string - type: array - max_players: - type: integer - prevent_auto_create_lobby: - type: boolean - regions: - items: - type: string - type: array - tags: - additionalProperties: - type: string - type: object - verification_data: {} - required: - - game_modes - type: object - required: true + - in: query + name: environment + required: false + schema: + type: string + - description: The duration to wait for in milliseconds before killing the actor. + This should be used to override the default kill timeout if a faster time + is needed, say for ignoring a graceful shutdown. + in: query + name: override_kill_timeout + required: false + schema: + format: int64 + type: integer responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerFindLobbyResponse' + $ref: '#/components/schemas/ActorDestroyActorResponse' description: '' '400': content: @@ -604,50 +688,34 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/join: - post: - description: 'Joins a specific lobby. - - This request will use the direct player count configured for the - - lobby group. - - - When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) - is enabled in - - your game namespace, this endpoint does not require a token to authenticate. - Otherwise, a - - [development namespace token](/docs/general/concepts/token-types#namespace-development) - can be used - - for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication.' - operationId: matchmaker_lobbies_join - parameters: [] - requestBody: - content: - application/json: - schema: - properties: - captcha: - $ref: '#/components/schemas/CaptchaConfig' - lobby_id: - type: string - verification_data: {} - required: - - lobby_id - type: object + - Actor + get: + description: Gets a dynamic actor. + operationId: actor_get + parameters: + - description: The id of the actor to destroy + in: path + name: actor required: true + schema: + format: uuid + type: string + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerJoinLobbyResponse' + $ref: '#/components/schemas/ActorGetActorResponse' description: '' '400': content: @@ -687,37 +755,45 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/list: + - Actor + /actors/{actor}/logs: get: - description: 'Lists all open lobbies. - - - When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) - is enabled in - - your game namespace, this endpoint does not require a token to authenticate. - Otherwise, a - - [development namespace token](/docs/general/concepts/token-types#namespace-development) - can be used - - for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - - can be used for general authentication.' - operationId: matchmaker_lobbies_list + description: Returns the logs for a given actor. + operationId: actor_logs_get parameters: + - in: path + name: actor + required: true + schema: + format: uuid + type: string - in: query - name: include_state + name: project required: false schema: - type: boolean + type: string + - in: query + name: environment + required: false + schema: + type: string + - in: query + name: stream + required: true + schema: + $ref: '#/components/schemas/ActorLogStream' + - description: A query parameter denoting the requests watch index. + in: query + name: watch_index + required: false + schema: + type: string responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerListLobbiesResponse' + $ref: '#/components/schemas/ActorGetActorLogsResponse' description: '' '400': content: @@ -757,21 +833,34 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/ready: - post: - description: 'Marks the current lobby as ready to accept connections. Players - will not be able to connect to this lobby until the lobby is flagged as ready. - - This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) - for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - for mock responses. When running on Rivet servers, you can access the given - lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) - environment variable.' - operationId: matchmaker_lobbies_ready - parameters: [] + - ActorLogs + /builds: + get: + description: Lists all builds of the project associated with the token used. + Can be filtered by tags in the query string. + operationId: actor_builds_list + parameters: + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string + - in: query + name: tags_json + required: false + schema: + type: string responses: - '204': + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ActorListBuildsResponse' description: '' '400': content: @@ -811,30 +900,34 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/state: - put: - description: 'Sets the state JSON of the current lobby. - - - This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) - for - - authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the given - lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable.' - operationId: matchmaker_lobbies_setState - parameters: [] + - ActorBuilds + /builds/prepare: + post: + description: Creates a new project build for the given project. + operationId: actor_builds_prepare + parameters: + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string requestBody: content: application/json: - schema: {} - required: false + schema: + $ref: '#/components/schemas/ActorPrepareBuildRequest' + required: true responses: - '204': + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ActorPrepareBuildResponse' description: '' '400': content: @@ -874,34 +967,34 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/lobbies/{lobby_id}/state: + - ActorBuilds + /builds/{build}: get: - description: 'Get the state of any lobby. - - - This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) - for - - authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - - for mock responses. When running on Rivet servers, you can access the given - lobby token from the - - [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable.' - operationId: matchmaker_lobbies_getState + description: Get a build. + operationId: actor_builds_get parameters: - in: path - name: lobby_id + name: build required: true schema: format: uuid type: string + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string responses: '200': content: application/json: - schema: {} + schema: + $ref: '#/components/schemas/ActorGetBuildResponse' description: '' '400': content: @@ -941,87 +1034,28 @@ paths: description: '' security: *id001 tags: - - MatchmakerLobbies - /matchmaker/players/connected: + - ActorBuilds + /builds/{build}/complete: post: - description: 'Validates the player token is valid and has not already been consumed - then - - marks the player as connected. - - - # Player Tokens and Reserved Slots - - - Player tokens reserve a spot in the lobby until they expire. This allows for - - precise matchmaking up to exactly the lobby''s player limit, which is - - important for games with small lobbies and a high influx of players. - - By calling this endpoint with the player token, the player''s spot is marked - - as connected and will not expire. If this endpoint is never called, the - - player''s token will expire and this spot will be filled by another player. - - - # Anti-Botting - - - Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, - or - - from the `GlobalEventMatchmakerLobbyJoin` event. - - These endpoints have anti-botting measures (i.e. enforcing max player - - limits, captchas, and detecting bots), so valid player tokens provide some - - confidence that the player is not a bot. - - Therefore, it''s important to make sure the token is valid by waiting for - - this endpoint to return OK before allowing the connected socket to do - - anything else. If this endpoint returns an error, the socket should be - - disconnected immediately. - - - # How to Transmit the Player Token - - - The client is responsible for acquiring the player token by caling - - `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` - - event. Beyond that, it''s up to the developer how the player token is - - transmitted to the lobby. - - If using WebSockets, the player token can be transmitted as a query - - parameter. - - Otherwise, the player token will likely be automatically sent by the client - - once the socket opens. As mentioned above, nothing else should happen until - - the player token is validated.' - operationId: matchmaker_players_connected - parameters: [] - requestBody: - content: - application/json: - schema: - properties: - player_token: - type: string - required: - - player_token - type: object + description: Marks an upload as complete. + operationId: actor_builds_complete + parameters: + - in: path + name: build required: true + schema: + format: uuid + type: string + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string responses: '204': description: '' @@ -1063,78 +1097,39 @@ paths: description: '' security: *id001 tags: - - MatchmakerPlayers - /matchmaker/players/disconnected: - post: - description: 'Marks a player as disconnected. # Ghost Players If players are - not marked as disconnected, lobbies will result with "ghost players" that - the matchmaker thinks exist but are no longer connected to the lobby.' - operationId: matchmaker_players_disconnected - parameters: [] + - ActorBuilds + /builds/{build}/tags: + patch: + operationId: actor_builds_patchTags + parameters: + - in: path + name: build + required: true + schema: + format: uuid + type: string + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string requestBody: content: application/json: schema: - properties: - player_token: - type: string - required: - - player_token - type: object + $ref: '#/components/schemas/ActorPatchBuildTagsRequest' required: true - responses: - '204': - description: '' - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - '403': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - '404': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - '408': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - '429': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorBody' - description: '' - security: *id001 - tags: - - MatchmakerPlayers - /matchmaker/players/statistics: - get: - description: Gives matchmaker statistics about the players in game. - operationId: matchmaker_players_getStatistics - parameters: [] responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerGetStatisticsResponse' + $ref: '#/components/schemas/ActorPatchBuildTagsResponse' description: '' '400': content: @@ -1174,22 +1169,27 @@ paths: description: '' security: *id001 tags: - - MatchmakerPlayers - /matchmaker/regions: + - ActorBuilds + /regions: get: - description: 'Returns a list of regions available to this namespace. - - Regions are sorted by most optimal to least optimal. The player''s IP address - - is used to calculate the regions'' optimality.' - operationId: matchmaker_regions_list - parameters: [] + operationId: actor_regions_list + parameters: + - in: query + name: project + required: false + schema: + type: string + - in: query + name: environment + required: false + schema: + type: string responses: '200': content: application/json: schema: - $ref: '#/components/schemas/MatchmakerListRegionsResponse' + $ref: '#/components/schemas/ActorListRegionsResponse' description: '' '400': content: @@ -1229,7 +1229,7 @@ paths: description: '' security: *id001 tags: - - MatchmakerRegions + - ActorRegions servers: - description: Production url: https://api.rivet.gg diff --git a/sdks/runtime/rust/.openapi-generator/FILES b/sdks/runtime/rust/.openapi-generator/FILES index 3ae89dda8f..7cb840cfcc 100644 --- a/sdks/runtime/rust/.openapi-generator/FILES +++ b/sdks/runtime/rust/.openapi-generator/FILES @@ -3,70 +3,86 @@ .travis.yml Cargo.toml README.md -docs/CaptchaConfig.md -docs/CaptchaConfigHcaptcha.md -docs/CaptchaConfigTurnstile.md +docs/ActorActor.md +docs/ActorApi.md +docs/ActorBuild.md +docs/ActorBuildCompression.md +docs/ActorBuildKind.md +docs/ActorBuildsApi.md +docs/ActorCreateActorNetworkRequest.md +docs/ActorCreateActorPortRequest.md +docs/ActorCreateActorRequest.md +docs/ActorCreateActorResponse.md +docs/ActorCreateActorRuntimeRequest.md +docs/ActorGetActorLogsResponse.md +docs/ActorGetActorResponse.md +docs/ActorGetBuildResponse.md +docs/ActorGuardRouting.md +docs/ActorLifecycle.md +docs/ActorListActorsResponse.md +docs/ActorListBuildsResponse.md +docs/ActorListRegionsResponse.md +docs/ActorLogStream.md +docs/ActorLogsApi.md +docs/ActorNetwork.md +docs/ActorNetworkMode.md +docs/ActorPatchBuildTagsRequest.md +docs/ActorPort.md +docs/ActorPortAuthorization.md +docs/ActorPortProtocol.md +docs/ActorPortQueryAuthorization.md +docs/ActorPortRouting.md +docs/ActorPrepareBuildRequest.md +docs/ActorPrepareBuildResponse.md +docs/ActorRegion.md +docs/ActorRegionsApi.md +docs/ActorResources.md +docs/ActorRuntime.md docs/ErrorBody.md -docs/GeoCoord.md -docs/GeoDistance.md -docs/MatchmakerCreateLobbyResponse.md -docs/MatchmakerCustomLobbyPublicity.md -docs/MatchmakerFindLobbyResponse.md -docs/MatchmakerGameModeInfo.md -docs/MatchmakerGameModeStatistics.md -docs/MatchmakerGetStatisticsResponse.md -docs/MatchmakerJoinLobby.md -docs/MatchmakerJoinLobbyResponse.md -docs/MatchmakerJoinPlayer.md -docs/MatchmakerJoinPort.md -docs/MatchmakerJoinPortRange.md -docs/MatchmakerJoinRegion.md -docs/MatchmakerListLobbiesResponse.md -docs/MatchmakerListRegionsResponse.md -docs/MatchmakerLobbiesApi.md -docs/MatchmakerLobbiesCreateRequest.md -docs/MatchmakerLobbiesFindRequest.md -docs/MatchmakerLobbiesJoinRequest.md -docs/MatchmakerLobbiesSetClosedRequest.md -docs/MatchmakerLobbyInfo.md -docs/MatchmakerPlayersApi.md -docs/MatchmakerPlayersConnectedRequest.md -docs/MatchmakerRegionInfo.md -docs/MatchmakerRegionStatistics.md -docs/MatchmakerRegionsApi.md +docs/UploadPrepareFile.md +docs/UploadPresignedRequest.md +docs/WatchResponse.md git_push.sh +src/apis/actor_api.rs +src/apis/actor_builds_api.rs +src/apis/actor_logs_api.rs +src/apis/actor_regions_api.rs src/apis/configuration.rs -src/apis/matchmaker_lobbies_api.rs -src/apis/matchmaker_players_api.rs -src/apis/matchmaker_regions_api.rs src/apis/mod.rs src/lib.rs -src/models/captcha_config.rs -src/models/captcha_config_hcaptcha.rs -src/models/captcha_config_turnstile.rs +src/models/actor_actor.rs +src/models/actor_build.rs +src/models/actor_build_compression.rs +src/models/actor_build_kind.rs +src/models/actor_create_actor_network_request.rs +src/models/actor_create_actor_port_request.rs +src/models/actor_create_actor_request.rs +src/models/actor_create_actor_response.rs +src/models/actor_create_actor_runtime_request.rs +src/models/actor_get_actor_logs_response.rs +src/models/actor_get_actor_response.rs +src/models/actor_get_build_response.rs +src/models/actor_guard_routing.rs +src/models/actor_lifecycle.rs +src/models/actor_list_actors_response.rs +src/models/actor_list_builds_response.rs +src/models/actor_list_regions_response.rs +src/models/actor_log_stream.rs +src/models/actor_network.rs +src/models/actor_network_mode.rs +src/models/actor_patch_build_tags_request.rs +src/models/actor_port.rs +src/models/actor_port_authorization.rs +src/models/actor_port_protocol.rs +src/models/actor_port_query_authorization.rs +src/models/actor_port_routing.rs +src/models/actor_prepare_build_request.rs +src/models/actor_prepare_build_response.rs +src/models/actor_region.rs +src/models/actor_resources.rs +src/models/actor_runtime.rs src/models/error_body.rs -src/models/geo_coord.rs -src/models/geo_distance.rs -src/models/matchmaker_create_lobby_response.rs -src/models/matchmaker_custom_lobby_publicity.rs -src/models/matchmaker_find_lobby_response.rs -src/models/matchmaker_game_mode_info.rs -src/models/matchmaker_game_mode_statistics.rs -src/models/matchmaker_get_statistics_response.rs -src/models/matchmaker_join_lobby.rs -src/models/matchmaker_join_lobby_response.rs -src/models/matchmaker_join_player.rs -src/models/matchmaker_join_port.rs -src/models/matchmaker_join_port_range.rs -src/models/matchmaker_join_region.rs -src/models/matchmaker_list_lobbies_response.rs -src/models/matchmaker_list_regions_response.rs -src/models/matchmaker_lobbies_create_request.rs -src/models/matchmaker_lobbies_find_request.rs -src/models/matchmaker_lobbies_join_request.rs -src/models/matchmaker_lobbies_set_closed_request.rs -src/models/matchmaker_lobby_info.rs -src/models/matchmaker_players_connected_request.rs -src/models/matchmaker_region_info.rs -src/models/matchmaker_region_statistics.rs src/models/mod.rs +src/models/upload_prepare_file.rs +src/models/upload_presigned_request.rs +src/models/watch_response.rs diff --git a/sdks/runtime/rust/Cargo.toml b/sdks/runtime/rust/Cargo.toml index ea7f2b8551..6a448ded68 100644 --- a/sdks/runtime/rust/Cargo.toml +++ b/sdks/runtime/rust/Cargo.toml @@ -14,7 +14,6 @@ serde_with = "^2.0" serde_json = "^1.0" url = "^2.2" uuid = { version = "^1.0", features = ["serde"] } - [dependencies.reqwest] version = "^0.11" features = ["json", "multipart"] diff --git a/sdks/runtime/rust/README.md b/sdks/runtime/rust/README.md index 85ce7f37aa..55e0b82c9a 100644 --- a/sdks/runtime/rust/README.md +++ b/sdks/runtime/rust/README.md @@ -25,50 +25,56 @@ All URIs are relative to *https://api.rivet.gg* Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_create**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_create) | **POST** /matchmaker/lobbies/create | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_find**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_find) | **POST** /matchmaker/lobbies/find | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_get_state**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_get_state) | **GET** /matchmaker/lobbies/{lobby_id}/state | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_join**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_join) | **POST** /matchmaker/lobbies/join | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_list**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_list) | **GET** /matchmaker/lobbies/list | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_ready**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_ready) | **POST** /matchmaker/lobbies/ready | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_set_closed**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_set_closed) | **PUT** /matchmaker/lobbies/closed | -*MatchmakerLobbiesApi* | [**matchmaker_lobbies_set_state**](docs/MatchmakerLobbiesApi.md#matchmaker_lobbies_set_state) | **PUT** /matchmaker/lobbies/state | -*MatchmakerPlayersApi* | [**matchmaker_players_connected**](docs/MatchmakerPlayersApi.md#matchmaker_players_connected) | **POST** /matchmaker/players/connected | -*MatchmakerPlayersApi* | [**matchmaker_players_disconnected**](docs/MatchmakerPlayersApi.md#matchmaker_players_disconnected) | **POST** /matchmaker/players/disconnected | -*MatchmakerPlayersApi* | [**matchmaker_players_get_statistics**](docs/MatchmakerPlayersApi.md#matchmaker_players_get_statistics) | **GET** /matchmaker/players/statistics | -*MatchmakerRegionsApi* | [**matchmaker_regions_list**](docs/MatchmakerRegionsApi.md#matchmaker_regions_list) | **GET** /matchmaker/regions | +*ActorApi* | [**actor_create**](docs/ActorApi.md#actor_create) | **POST** /actors | +*ActorApi* | [**actor_destroy**](docs/ActorApi.md#actor_destroy) | **DELETE** /actors/{actor} | +*ActorApi* | [**actor_get**](docs/ActorApi.md#actor_get) | **GET** /actors/{actor} | +*ActorApi* | [**actor_list**](docs/ActorApi.md#actor_list) | **GET** /actors | +*ActorBuildsApi* | [**actor_builds_complete**](docs/ActorBuildsApi.md#actor_builds_complete) | **POST** /builds/{build}/complete | +*ActorBuildsApi* | [**actor_builds_get**](docs/ActorBuildsApi.md#actor_builds_get) | **GET** /builds/{build} | +*ActorBuildsApi* | [**actor_builds_list**](docs/ActorBuildsApi.md#actor_builds_list) | **GET** /builds | +*ActorBuildsApi* | [**actor_builds_patch_tags**](docs/ActorBuildsApi.md#actor_builds_patch_tags) | **PATCH** /builds/{build}/tags | +*ActorBuildsApi* | [**actor_builds_prepare**](docs/ActorBuildsApi.md#actor_builds_prepare) | **POST** /builds/prepare | +*ActorLogsApi* | [**actor_logs_get**](docs/ActorLogsApi.md#actor_logs_get) | **GET** /actors/{actor}/logs | +*ActorRegionsApi* | [**actor_regions_list**](docs/ActorRegionsApi.md#actor_regions_list) | **GET** /regions | ## Documentation For Models - - [CaptchaConfig](docs/CaptchaConfig.md) - - [CaptchaConfigHcaptcha](docs/CaptchaConfigHcaptcha.md) - - [CaptchaConfigTurnstile](docs/CaptchaConfigTurnstile.md) + - [ActorActor](docs/ActorActor.md) + - [ActorBuild](docs/ActorBuild.md) + - [ActorBuildCompression](docs/ActorBuildCompression.md) + - [ActorBuildKind](docs/ActorBuildKind.md) + - [ActorCreateActorNetworkRequest](docs/ActorCreateActorNetworkRequest.md) + - [ActorCreateActorPortRequest](docs/ActorCreateActorPortRequest.md) + - [ActorCreateActorRequest](docs/ActorCreateActorRequest.md) + - [ActorCreateActorResponse](docs/ActorCreateActorResponse.md) + - [ActorCreateActorRuntimeRequest](docs/ActorCreateActorRuntimeRequest.md) + - [ActorGetActorLogsResponse](docs/ActorGetActorLogsResponse.md) + - [ActorGetActorResponse](docs/ActorGetActorResponse.md) + - [ActorGetBuildResponse](docs/ActorGetBuildResponse.md) + - [ActorGuardRouting](docs/ActorGuardRouting.md) + - [ActorLifecycle](docs/ActorLifecycle.md) + - [ActorListActorsResponse](docs/ActorListActorsResponse.md) + - [ActorListBuildsResponse](docs/ActorListBuildsResponse.md) + - [ActorListRegionsResponse](docs/ActorListRegionsResponse.md) + - [ActorLogStream](docs/ActorLogStream.md) + - [ActorNetwork](docs/ActorNetwork.md) + - [ActorNetworkMode](docs/ActorNetworkMode.md) + - [ActorPatchBuildTagsRequest](docs/ActorPatchBuildTagsRequest.md) + - [ActorPort](docs/ActorPort.md) + - [ActorPortAuthorization](docs/ActorPortAuthorization.md) + - [ActorPortProtocol](docs/ActorPortProtocol.md) + - [ActorPortQueryAuthorization](docs/ActorPortQueryAuthorization.md) + - [ActorPortRouting](docs/ActorPortRouting.md) + - [ActorPrepareBuildRequest](docs/ActorPrepareBuildRequest.md) + - [ActorPrepareBuildResponse](docs/ActorPrepareBuildResponse.md) + - [ActorRegion](docs/ActorRegion.md) + - [ActorResources](docs/ActorResources.md) + - [ActorRuntime](docs/ActorRuntime.md) - [ErrorBody](docs/ErrorBody.md) - - [GeoCoord](docs/GeoCoord.md) - - [GeoDistance](docs/GeoDistance.md) - - [MatchmakerCreateLobbyResponse](docs/MatchmakerCreateLobbyResponse.md) - - [MatchmakerCustomLobbyPublicity](docs/MatchmakerCustomLobbyPublicity.md) - - [MatchmakerFindLobbyResponse](docs/MatchmakerFindLobbyResponse.md) - - [MatchmakerGameModeInfo](docs/MatchmakerGameModeInfo.md) - - [MatchmakerGameModeStatistics](docs/MatchmakerGameModeStatistics.md) - - [MatchmakerGetStatisticsResponse](docs/MatchmakerGetStatisticsResponse.md) - - [MatchmakerJoinLobby](docs/MatchmakerJoinLobby.md) - - [MatchmakerJoinLobbyResponse](docs/MatchmakerJoinLobbyResponse.md) - - [MatchmakerJoinPlayer](docs/MatchmakerJoinPlayer.md) - - [MatchmakerJoinPort](docs/MatchmakerJoinPort.md) - - [MatchmakerJoinPortRange](docs/MatchmakerJoinPortRange.md) - - [MatchmakerJoinRegion](docs/MatchmakerJoinRegion.md) - - [MatchmakerListLobbiesResponse](docs/MatchmakerListLobbiesResponse.md) - - [MatchmakerListRegionsResponse](docs/MatchmakerListRegionsResponse.md) - - [MatchmakerLobbiesCreateRequest](docs/MatchmakerLobbiesCreateRequest.md) - - [MatchmakerLobbiesFindRequest](docs/MatchmakerLobbiesFindRequest.md) - - [MatchmakerLobbiesJoinRequest](docs/MatchmakerLobbiesJoinRequest.md) - - [MatchmakerLobbiesSetClosedRequest](docs/MatchmakerLobbiesSetClosedRequest.md) - - [MatchmakerLobbyInfo](docs/MatchmakerLobbyInfo.md) - - [MatchmakerPlayersConnectedRequest](docs/MatchmakerPlayersConnectedRequest.md) - - [MatchmakerRegionInfo](docs/MatchmakerRegionInfo.md) - - [MatchmakerRegionStatistics](docs/MatchmakerRegionStatistics.md) + - [UploadPrepareFile](docs/UploadPrepareFile.md) + - [UploadPresignedRequest](docs/UploadPresignedRequest.md) + - [WatchResponse](docs/WatchResponse.md) To get access to the crate's generated documentation, use: diff --git a/sdks/runtime/rust/docs/ActorActor.md b/sdks/runtime/rust/docs/ActorActor.md new file mode 100644 index 0000000000..5274613ed0 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorActor.md @@ -0,0 +1,20 @@ +# ActorActor + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**created_at** | **i64** | | +**destroyed_at** | Option<**i64**> | | [optional] +**id** | [**uuid::Uuid**](uuid::Uuid.md) | | +**lifecycle** | [**crate::models::ActorLifecycle**](ActorLifecycle.md) | | +**network** | [**crate::models::ActorNetwork**](ActorNetwork.md) | | +**region** | **String** | | +**resources** | [**crate::models::ActorResources**](ActorResources.md) | | +**runtime** | [**crate::models::ActorRuntime**](ActorRuntime.md) | | +**started_at** | Option<**i64**> | | [optional] +**tags** | Option<[**serde_json::Value**](.md)> | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorApi.md b/sdks/runtime/rust/docs/ActorApi.md new file mode 100644 index 0000000000..1f67f65178 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorApi.md @@ -0,0 +1,143 @@ +# \ActorApi + +All URIs are relative to *https://api.rivet.gg* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**actor_create**](ActorApi.md#actor_create) | **POST** /actors | +[**actor_destroy**](ActorApi.md#actor_destroy) | **DELETE** /actors/{actor} | +[**actor_get**](ActorApi.md#actor_get) | **GET** /actors/{actor} | +[**actor_list**](ActorApi.md#actor_list) | **GET** /actors | + + + +## actor_create + +> crate::models::ActorCreateActorResponse actor_create(actor_create_actor_request, project, environment) + + +Create a new dynamic actor. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**actor_create_actor_request** | [**ActorCreateActorRequest**](ActorCreateActorRequest.md) | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorCreateActorResponse**](ActorCreateActorResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### 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) + + +## actor_destroy + +> serde_json::Value actor_destroy(actor, project, environment, override_kill_timeout) + + +Destroy a dynamic actor. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**actor** | **uuid::Uuid** | The id of the actor to destroy | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | +**override_kill_timeout** | Option<**i64**> | The duration to wait for in milliseconds before killing the actor. This should be used to override the default kill timeout if a faster time is needed, say for ignoring a graceful shutdown. | | + +### Return type + +[**serde_json::Value**](serde_json::Value.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + + +## actor_get + +> crate::models::ActorGetActorResponse actor_get(actor, project, environment) + + +Gets a dynamic actor. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**actor** | **uuid::Uuid** | The id of the actor to destroy | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorGetActorResponse**](ActorGetActorResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + + +## actor_list + +> crate::models::ActorListActorsResponse actor_list(project, environment, tags_json, include_destroyed, cursor) + + +Lists all actors associated with the token used. Can be filtered by tags in the query string. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | +**tags_json** | Option<**String**> | | | +**include_destroyed** | Option<**bool**> | | | +**cursor** | Option<**uuid::Uuid**> | | | + +### Return type + +[**crate::models::ActorListActorsResponse**](ActorListActorsResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + diff --git a/sdks/runtime/rust/docs/ActorBuild.md b/sdks/runtime/rust/docs/ActorBuild.md new file mode 100644 index 0000000000..2b953553bc --- /dev/null +++ b/sdks/runtime/rust/docs/ActorBuild.md @@ -0,0 +1,15 @@ +# ActorBuild + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**content_length** | **i64** | Unsigned 64 bit integer. | +**created_at** | **String** | RFC3339 timestamp | +**id** | [**uuid::Uuid**](uuid::Uuid.md) | | +**name** | **String** | | +**tags** | **::std::collections::HashMap** | Tags of this build | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/MatchmakerCustomLobbyPublicity.md b/sdks/runtime/rust/docs/ActorBuildCompression.md similarity index 89% rename from sdks/runtime/rust/docs/MatchmakerCustomLobbyPublicity.md rename to sdks/runtime/rust/docs/ActorBuildCompression.md index 9ef8998a74..2903bf515f 100644 --- a/sdks/runtime/rust/docs/MatchmakerCustomLobbyPublicity.md +++ b/sdks/runtime/rust/docs/ActorBuildCompression.md @@ -1,4 +1,4 @@ -# MatchmakerCustomLobbyPublicity +# ActorBuildCompression ## Properties diff --git a/sdks/runtime/rust/docs/MatchmakerRegionStatistics.md b/sdks/runtime/rust/docs/ActorBuildKind.md similarity index 81% rename from sdks/runtime/rust/docs/MatchmakerRegionStatistics.md rename to sdks/runtime/rust/docs/ActorBuildKind.md index ab5cdba9f8..da74c36245 100644 --- a/sdks/runtime/rust/docs/MatchmakerRegionStatistics.md +++ b/sdks/runtime/rust/docs/ActorBuildKind.md @@ -1,10 +1,9 @@ -# MatchmakerRegionStatistics +# ActorBuildKind ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**player_count** | **i64** | | [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/sdks/runtime/rust/docs/ActorBuildsApi.md b/sdks/runtime/rust/docs/ActorBuildsApi.md new file mode 100644 index 0000000000..c189e9ab36 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorBuildsApi.md @@ -0,0 +1,172 @@ +# \ActorBuildsApi + +All URIs are relative to *https://api.rivet.gg* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**actor_builds_complete**](ActorBuildsApi.md#actor_builds_complete) | **POST** /builds/{build}/complete | +[**actor_builds_get**](ActorBuildsApi.md#actor_builds_get) | **GET** /builds/{build} | +[**actor_builds_list**](ActorBuildsApi.md#actor_builds_list) | **GET** /builds | +[**actor_builds_patch_tags**](ActorBuildsApi.md#actor_builds_patch_tags) | **PATCH** /builds/{build}/tags | +[**actor_builds_prepare**](ActorBuildsApi.md#actor_builds_prepare) | **POST** /builds/prepare | + + + +## actor_builds_complete + +> actor_builds_complete(build, project, environment) + + +Marks an upload as complete. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**build** | **uuid::Uuid** | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + + (empty response body) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + + +## actor_builds_get + +> crate::models::ActorGetBuildResponse actor_builds_get(build, project, environment) + + +Get a build. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**build** | **uuid::Uuid** | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorGetBuildResponse**](ActorGetBuildResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + + +## actor_builds_list + +> crate::models::ActorListBuildsResponse actor_builds_list(project, environment, tags_json) + + +Lists all builds of the project associated with the token used. Can be filtered by tags in the query string. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | +**tags_json** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorListBuildsResponse**](ActorListBuildsResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + + +## actor_builds_patch_tags + +> serde_json::Value actor_builds_patch_tags(build, actor_patch_build_tags_request, project, environment) + + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**build** | **uuid::Uuid** | | [required] | +**actor_patch_build_tags_request** | [**ActorPatchBuildTagsRequest**](ActorPatchBuildTagsRequest.md) | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**serde_json::Value**](serde_json::Value.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### 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) + + +## actor_builds_prepare + +> crate::models::ActorPrepareBuildResponse actor_builds_prepare(actor_prepare_build_request, project, environment) + + +Creates a new project build for the given project. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**actor_prepare_build_request** | [**ActorPrepareBuildRequest**](ActorPrepareBuildRequest.md) | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorPrepareBuildResponse**](ActorPrepareBuildResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### 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) + diff --git a/sdks/runtime/rust/docs/ActorCreateActorNetworkRequest.md b/sdks/runtime/rust/docs/ActorCreateActorNetworkRequest.md new file mode 100644 index 0000000000..2f1fedc1cc --- /dev/null +++ b/sdks/runtime/rust/docs/ActorCreateActorNetworkRequest.md @@ -0,0 +1,12 @@ +# ActorCreateActorNetworkRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**mode** | Option<[**crate::models::ActorNetworkMode**](ActorNetworkMode.md)> | | [optional] +**ports** | Option<[**::std::collections::HashMap**](ActorCreateActorPortRequest.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorCreateActorPortRequest.md b/sdks/runtime/rust/docs/ActorCreateActorPortRequest.md new file mode 100644 index 0000000000..5a0576981e --- /dev/null +++ b/sdks/runtime/rust/docs/ActorCreateActorPortRequest.md @@ -0,0 +1,13 @@ +# ActorCreateActorPortRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**internal_port** | Option<**i32**> | | [optional] +**protocol** | [**crate::models::ActorPortProtocol**](ActorPortProtocol.md) | | +**routing** | Option<[**crate::models::ActorPortRouting**](ActorPortRouting.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorCreateActorRequest.md b/sdks/runtime/rust/docs/ActorCreateActorRequest.md new file mode 100644 index 0000000000..135e736c2b --- /dev/null +++ b/sdks/runtime/rust/docs/ActorCreateActorRequest.md @@ -0,0 +1,16 @@ +# ActorCreateActorRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**lifecycle** | Option<[**crate::models::ActorLifecycle**](ActorLifecycle.md)> | | [optional] +**network** | Option<[**crate::models::ActorCreateActorNetworkRequest**](ActorCreateActorNetworkRequest.md)> | | [optional] +**region** | **String** | | +**resources** | [**crate::models::ActorResources**](ActorResources.md) | | +**runtime** | [**crate::models::ActorCreateActorRuntimeRequest**](ActorCreateActorRuntimeRequest.md) | | +**tags** | Option<[**serde_json::Value**](.md)> | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorCreateActorResponse.md b/sdks/runtime/rust/docs/ActorCreateActorResponse.md new file mode 100644 index 0000000000..03556ae3a0 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorCreateActorResponse.md @@ -0,0 +1,11 @@ +# ActorCreateActorResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**actor** | [**crate::models::ActorActor**](ActorActor.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorCreateActorRuntimeRequest.md b/sdks/runtime/rust/docs/ActorCreateActorRuntimeRequest.md new file mode 100644 index 0000000000..2f48f0ad99 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorCreateActorRuntimeRequest.md @@ -0,0 +1,13 @@ +# ActorCreateActorRuntimeRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**arguments** | Option<**Vec**> | | [optional] +**build** | [**uuid::Uuid**](uuid::Uuid.md) | | +**environment** | Option<**::std::collections::HashMap**> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorGetActorLogsResponse.md b/sdks/runtime/rust/docs/ActorGetActorLogsResponse.md new file mode 100644 index 0000000000..661ab3c4df --- /dev/null +++ b/sdks/runtime/rust/docs/ActorGetActorLogsResponse.md @@ -0,0 +1,13 @@ +# ActorGetActorLogsResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**lines** | **Vec** | Sorted old to new. | +**timestamps** | **Vec** | Sorted old to new. | +**watch** | [**crate::models::WatchResponse**](WatchResponse.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/GeoDistance.md b/sdks/runtime/rust/docs/ActorGetActorResponse.md similarity index 75% rename from sdks/runtime/rust/docs/GeoDistance.md rename to sdks/runtime/rust/docs/ActorGetActorResponse.md index b06e5575f0..f13b8fd6b4 100644 --- a/sdks/runtime/rust/docs/GeoDistance.md +++ b/sdks/runtime/rust/docs/ActorGetActorResponse.md @@ -1,11 +1,10 @@ -# GeoDistance +# ActorGetActorResponse ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**kilometers** | **f64** | | -**miles** | **f64** | | +**actor** | [**crate::models::ActorActor**](ActorActor.md) | | [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/sdks/runtime/rust/docs/ActorGetBuildResponse.md b/sdks/runtime/rust/docs/ActorGetBuildResponse.md new file mode 100644 index 0000000000..8c5a50a151 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorGetBuildResponse.md @@ -0,0 +1,11 @@ +# ActorGetBuildResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**build** | [**crate::models::ActorBuild**](ActorBuild.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorGuardRouting.md b/sdks/runtime/rust/docs/ActorGuardRouting.md new file mode 100644 index 0000000000..cbac90e5f8 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorGuardRouting.md @@ -0,0 +1,11 @@ +# ActorGuardRouting + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**authorization** | Option<[**crate::models::ActorPortAuthorization**](ActorPortAuthorization.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorLifecycle.md b/sdks/runtime/rust/docs/ActorLifecycle.md new file mode 100644 index 0000000000..aad23365b8 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorLifecycle.md @@ -0,0 +1,11 @@ +# ActorLifecycle + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**kill_timeout** | Option<**i64**> | The duration to wait for in milliseconds before killing the actor. This should be set to a safe default, and can be overridden during a DELETE request if needed. | [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) + + diff --git a/sdks/runtime/rust/docs/ActorListActorsResponse.md b/sdks/runtime/rust/docs/ActorListActorsResponse.md new file mode 100644 index 0000000000..fd4b2983b0 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorListActorsResponse.md @@ -0,0 +1,11 @@ +# ActorListActorsResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**actors** | [**Vec**](ActorActor.md) | A list of actors for the project associated with the token. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorListBuildsResponse.md b/sdks/runtime/rust/docs/ActorListBuildsResponse.md new file mode 100644 index 0000000000..3ce3baa590 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorListBuildsResponse.md @@ -0,0 +1,11 @@ +# ActorListBuildsResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**builds** | [**Vec**](ActorBuild.md) | A list of builds for the project associated with the token. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorListRegionsResponse.md b/sdks/runtime/rust/docs/ActorListRegionsResponse.md new file mode 100644 index 0000000000..93089ddae3 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorListRegionsResponse.md @@ -0,0 +1,11 @@ +# ActorListRegionsResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**regions** | [**Vec**](ActorRegion.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/CaptchaConfigHcaptcha.md b/sdks/runtime/rust/docs/ActorLogStream.md similarity index 81% rename from sdks/runtime/rust/docs/CaptchaConfigHcaptcha.md rename to sdks/runtime/rust/docs/ActorLogStream.md index 42d89248b4..db06a741ca 100644 --- a/sdks/runtime/rust/docs/CaptchaConfigHcaptcha.md +++ b/sdks/runtime/rust/docs/ActorLogStream.md @@ -1,10 +1,9 @@ -# CaptchaConfigHcaptcha +# ActorLogStream ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**client_response** | **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) diff --git a/sdks/runtime/rust/docs/ActorLogsApi.md b/sdks/runtime/rust/docs/ActorLogsApi.md new file mode 100644 index 0000000000..6e73bc65c7 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorLogsApi.md @@ -0,0 +1,43 @@ +# \ActorLogsApi + +All URIs are relative to *https://api.rivet.gg* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**actor_logs_get**](ActorLogsApi.md#actor_logs_get) | **GET** /actors/{actor}/logs | + + + +## actor_logs_get + +> crate::models::ActorGetActorLogsResponse actor_logs_get(actor, stream, project, environment, watch_index) + + +Returns the logs for a given actor. + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**actor** | **uuid::Uuid** | | [required] | +**stream** | [**ActorLogStream**](.md) | | [required] | +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | +**watch_index** | Option<**String**> | A query parameter denoting the requests watch index. | | + +### Return type + +[**crate::models::ActorGetActorLogsResponse**](ActorGetActorLogsResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + diff --git a/sdks/runtime/rust/docs/ActorNetwork.md b/sdks/runtime/rust/docs/ActorNetwork.md new file mode 100644 index 0000000000..adfb693379 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorNetwork.md @@ -0,0 +1,12 @@ +# ActorNetwork + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**mode** | [**crate::models::ActorNetworkMode**](ActorNetworkMode.md) | | +**ports** | [**::std::collections::HashMap**](ActorPort.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/CaptchaConfigTurnstile.md b/sdks/runtime/rust/docs/ActorNetworkMode.md similarity index 81% rename from sdks/runtime/rust/docs/CaptchaConfigTurnstile.md rename to sdks/runtime/rust/docs/ActorNetworkMode.md index 7816b9984f..844c412c3b 100644 --- a/sdks/runtime/rust/docs/CaptchaConfigTurnstile.md +++ b/sdks/runtime/rust/docs/ActorNetworkMode.md @@ -1,10 +1,9 @@ -# CaptchaConfigTurnstile +# ActorNetworkMode ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**client_response** | **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) diff --git a/sdks/runtime/rust/docs/ActorPatchBuildTagsRequest.md b/sdks/runtime/rust/docs/ActorPatchBuildTagsRequest.md new file mode 100644 index 0000000000..bce9677c6f --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPatchBuildTagsRequest.md @@ -0,0 +1,12 @@ +# ActorPatchBuildTagsRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**exclusive_tags** | Option<**Vec**> | Removes the given tag keys from all other builds. | [optional] +**tags** | Option<[**serde_json::Value**](.md)> | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorPort.md b/sdks/runtime/rust/docs/ActorPort.md new file mode 100644 index 0000000000..f157a2e8aa --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPort.md @@ -0,0 +1,15 @@ +# ActorPort + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**internal_port** | Option<**i32**> | | [optional] +**protocol** | [**crate::models::ActorPortProtocol**](ActorPortProtocol.md) | | +**public_hostname** | Option<**String**> | | [optional] +**public_port** | Option<**i32**> | | [optional] +**routing** | [**crate::models::ActorPortRouting**](ActorPortRouting.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/ActorPortAuthorization.md b/sdks/runtime/rust/docs/ActorPortAuthorization.md new file mode 100644 index 0000000000..4ba4fa9e78 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPortAuthorization.md @@ -0,0 +1,12 @@ +# ActorPortAuthorization + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**bearer** | Option<**String**> | | [optional] +**query** | Option<[**crate::models::ActorPortQueryAuthorization**](ActorPortQueryAuthorization.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorPortProtocol.md b/sdks/runtime/rust/docs/ActorPortProtocol.md new file mode 100644 index 0000000000..7e96d39c9b --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPortProtocol.md @@ -0,0 +1,10 @@ +# ActorPortProtocol + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/GeoCoord.md b/sdks/runtime/rust/docs/ActorPortQueryAuthorization.md similarity index 76% rename from sdks/runtime/rust/docs/GeoCoord.md rename to sdks/runtime/rust/docs/ActorPortQueryAuthorization.md index 4ca238d544..a0d2f11c8a 100644 --- a/sdks/runtime/rust/docs/GeoCoord.md +++ b/sdks/runtime/rust/docs/ActorPortQueryAuthorization.md @@ -1,11 +1,11 @@ -# GeoCoord +# ActorPortQueryAuthorization ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**latitude** | **f64** | | -**longitude** | **f64** | | +**key** | **String** | | +**value** | **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) diff --git a/sdks/runtime/rust/docs/ActorPortRouting.md b/sdks/runtime/rust/docs/ActorPortRouting.md new file mode 100644 index 0000000000..72921d39ac --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPortRouting.md @@ -0,0 +1,12 @@ +# ActorPortRouting + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**guard** | Option<[**crate::models::ActorGuardRouting**](ActorGuardRouting.md)> | | [optional] +**host** | Option<[**serde_json::Value**](.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorPrepareBuildRequest.md b/sdks/runtime/rust/docs/ActorPrepareBuildRequest.md new file mode 100644 index 0000000000..e96e8012e3 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPrepareBuildRequest.md @@ -0,0 +1,17 @@ +# ActorPrepareBuildRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**compression** | Option<[**crate::models::ActorBuildCompression**](ActorBuildCompression.md)> | | [optional] +**image_file** | [**crate::models::UploadPrepareFile**](UploadPrepareFile.md) | | +**image_tag** | Option<**String**> | A tag given to the project build. | [optional] +**kind** | Option<[**crate::models::ActorBuildKind**](ActorBuildKind.md)> | | [optional] +**multipart_upload** | Option<**bool**> | | [optional] +**name** | **String** | | +**prewarm_regions** | Option<**Vec**> | | [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) + + diff --git a/sdks/runtime/rust/docs/ActorPrepareBuildResponse.md b/sdks/runtime/rust/docs/ActorPrepareBuildResponse.md new file mode 100644 index 0000000000..5943b524e0 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorPrepareBuildResponse.md @@ -0,0 +1,13 @@ +# ActorPrepareBuildResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**build** | [**uuid::Uuid**](uuid::Uuid.md) | | +**image_presigned_request** | Option<[**crate::models::UploadPresignedRequest**](UploadPresignedRequest.md)> | | [optional] +**image_presigned_requests** | Option<[**Vec**](UploadPresignedRequest.md)> | | [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) + + diff --git a/sdks/runtime/rust/docs/MatchmakerLobbiesSetClosedRequest.md b/sdks/runtime/rust/docs/ActorRegion.md similarity index 80% rename from sdks/runtime/rust/docs/MatchmakerLobbiesSetClosedRequest.md rename to sdks/runtime/rust/docs/ActorRegion.md index 687632d9b8..64bd99d824 100644 --- a/sdks/runtime/rust/docs/MatchmakerLobbiesSetClosedRequest.md +++ b/sdks/runtime/rust/docs/ActorRegion.md @@ -1,10 +1,11 @@ -# MatchmakerLobbiesSetClosedRequest +# ActorRegion ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**is_closed** | **bool** | | +**id** | **String** | | +**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) diff --git a/sdks/runtime/rust/docs/ActorRegionsApi.md b/sdks/runtime/rust/docs/ActorRegionsApi.md new file mode 100644 index 0000000000..87ffaefcbd --- /dev/null +++ b/sdks/runtime/rust/docs/ActorRegionsApi.md @@ -0,0 +1,38 @@ +# \ActorRegionsApi + +All URIs are relative to *https://api.rivet.gg* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**actor_regions_list**](ActorRegionsApi.md#actor_regions_list) | **GET** /regions | + + + +## actor_regions_list + +> crate::models::ActorListRegionsResponse actor_regions_list(project, environment) + + +### Parameters + + +Name | Type | Description | Required | Notes +------------- | ------------- | ------------- | ------------- | ------------- +**project** | Option<**String**> | | | +**environment** | Option<**String**> | | | + +### Return type + +[**crate::models::ActorListRegionsResponse**](ActorListRegionsResponse.md) + +### Authorization + +[BearerAuth](../README.md#BearerAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **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) + diff --git a/sdks/runtime/rust/docs/CaptchaConfig.md b/sdks/runtime/rust/docs/ActorResources.md similarity index 52% rename from sdks/runtime/rust/docs/CaptchaConfig.md rename to sdks/runtime/rust/docs/ActorResources.md index ccbccbd355..5fe5a114de 100644 --- a/sdks/runtime/rust/docs/CaptchaConfig.md +++ b/sdks/runtime/rust/docs/ActorResources.md @@ -1,11 +1,11 @@ -# CaptchaConfig +# ActorResources ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hcaptcha** | Option<[**crate::models::CaptchaConfigHcaptcha**](CaptchaConfigHcaptcha.md)> | | [optional] -**turnstile** | Option<[**crate::models::CaptchaConfigTurnstile**](CaptchaConfigTurnstile.md)> | | [optional] +**cpu** | **i32** | The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. | +**memory** | **i32** | The amount of memory in megabytes | [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/sdks/runtime/rust/docs/ActorRuntime.md b/sdks/runtime/rust/docs/ActorRuntime.md new file mode 100644 index 0000000000..00d4503b97 --- /dev/null +++ b/sdks/runtime/rust/docs/ActorRuntime.md @@ -0,0 +1,13 @@ +# ActorRuntime + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**arguments** | Option<**Vec**> | | [optional] +**build** | [**uuid::Uuid**](uuid::Uuid.md) | | +**environment** | Option<**::std::collections::HashMap**> | | [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) + + diff --git a/sdks/runtime/rust/docs/MatchmakerCreateLobbyResponse.md b/sdks/runtime/rust/docs/MatchmakerCreateLobbyResponse.md deleted file mode 100644 index d00ff19503..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerCreateLobbyResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# MatchmakerCreateLobbyResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**lobby** | [**crate::models::MatchmakerJoinLobby**](MatchmakerJoinLobby.md) | | -**player** | [**crate::models::MatchmakerJoinPlayer**](MatchmakerJoinPlayer.md) | | -**ports** | [**::std::collections::HashMap**](MatchmakerJoinPort.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerFindLobbyResponse.md b/sdks/runtime/rust/docs/MatchmakerFindLobbyResponse.md deleted file mode 100644 index de44dba1a0..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerFindLobbyResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# MatchmakerFindLobbyResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**lobby** | [**crate::models::MatchmakerJoinLobby**](MatchmakerJoinLobby.md) | | -**player** | [**crate::models::MatchmakerJoinPlayer**](MatchmakerJoinPlayer.md) | | -**ports** | [**::std::collections::HashMap**](MatchmakerJoinPort.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerGameModeInfo.md b/sdks/runtime/rust/docs/MatchmakerGameModeInfo.md deleted file mode 100644 index 2fd265125b..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerGameModeInfo.md +++ /dev/null @@ -1,11 +0,0 @@ -# MatchmakerGameModeInfo - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**game_mode_id** | **String** | A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerGameModeStatistics.md b/sdks/runtime/rust/docs/MatchmakerGameModeStatistics.md deleted file mode 100644 index 50ac1752c3..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerGameModeStatistics.md +++ /dev/null @@ -1,12 +0,0 @@ -# MatchmakerGameModeStatistics - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**player_count** | **i64** | | -**regions** | [**::std::collections::HashMap**](MatchmakerRegionStatistics.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerGetStatisticsResponse.md b/sdks/runtime/rust/docs/MatchmakerGetStatisticsResponse.md deleted file mode 100644 index ecc9cd7b94..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerGetStatisticsResponse.md +++ /dev/null @@ -1,12 +0,0 @@ -# MatchmakerGetStatisticsResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**game_modes** | [**::std::collections::HashMap**](MatchmakerGameModeStatistics.md) | | -**player_count** | **i64** | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinLobby.md b/sdks/runtime/rust/docs/MatchmakerJoinLobby.md deleted file mode 100644 index ed37af2873..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinLobby.md +++ /dev/null @@ -1,14 +0,0 @@ -# MatchmakerJoinLobby - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**lobby_id** | [**uuid::Uuid**](uuid::Uuid.md) | | -**player** | [**crate::models::MatchmakerJoinPlayer**](MatchmakerJoinPlayer.md) | | -**ports** | [**::std::collections::HashMap**](MatchmakerJoinPort.md) | **Deprecated** | -**region** | [**crate::models::MatchmakerJoinRegion**](MatchmakerJoinRegion.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinLobbyResponse.md b/sdks/runtime/rust/docs/MatchmakerJoinLobbyResponse.md deleted file mode 100644 index c6b79ab84a..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinLobbyResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# MatchmakerJoinLobbyResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**lobby** | [**crate::models::MatchmakerJoinLobby**](MatchmakerJoinLobby.md) | | -**player** | [**crate::models::MatchmakerJoinPlayer**](MatchmakerJoinPlayer.md) | | -**ports** | [**::std::collections::HashMap**](MatchmakerJoinPort.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinPlayer.md b/sdks/runtime/rust/docs/MatchmakerJoinPlayer.md deleted file mode 100644 index ec77d5f315..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinPlayer.md +++ /dev/null @@ -1,11 +0,0 @@ -# MatchmakerJoinPlayer - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**token** | **String** | Documentation at https://jwt.io/ | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinPort.md b/sdks/runtime/rust/docs/MatchmakerJoinPort.md deleted file mode 100644 index d32c534f6b..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinPort.md +++ /dev/null @@ -1,15 +0,0 @@ -# MatchmakerJoinPort - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**host** | Option<**String**> | The host for the given port. Will be null if using a port range. | [optional] -**hostname** | **String** | | -**is_tls** | **bool** | Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. | -**port** | Option<**i32**> | The port number for this lobby. Will be null if using a port range. | [optional] -**port_range** | Option<[**crate::models::MatchmakerJoinPortRange**](MatchmakerJoinPortRange.md)> | | [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) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinPortRange.md b/sdks/runtime/rust/docs/MatchmakerJoinPortRange.md deleted file mode 100644 index 28f302c2c1..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinPortRange.md +++ /dev/null @@ -1,12 +0,0 @@ -# MatchmakerJoinPortRange - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**max** | **i32** | Maximum port that can be connected to. Inclusive range. | -**min** | **i32** | Minimum port that can be connected to. Inclusive range. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerJoinRegion.md b/sdks/runtime/rust/docs/MatchmakerJoinRegion.md deleted file mode 100644 index 0ba22c74ff..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerJoinRegion.md +++ /dev/null @@ -1,12 +0,0 @@ -# MatchmakerJoinRegion - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**display_name** | **String** | Represent a resource's readable display name. | -**region_id** | **String** | A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerListLobbiesResponse.md b/sdks/runtime/rust/docs/MatchmakerListLobbiesResponse.md deleted file mode 100644 index 2c037b2b1a..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerListLobbiesResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# MatchmakerListLobbiesResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**game_modes** | [**Vec**](MatchmakerGameModeInfo.md) | | -**lobbies** | [**Vec**](MatchmakerLobbyInfo.md) | | -**regions** | [**Vec**](MatchmakerRegionInfo.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerListRegionsResponse.md b/sdks/runtime/rust/docs/MatchmakerListRegionsResponse.md deleted file mode 100644 index 2ee5e5be0c..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerListRegionsResponse.md +++ /dev/null @@ -1,11 +0,0 @@ -# MatchmakerListRegionsResponse - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**regions** | [**Vec**](MatchmakerRegionInfo.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerLobbiesApi.md b/sdks/runtime/rust/docs/MatchmakerLobbiesApi.md deleted file mode 100644 index cbecd8d12f..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerLobbiesApi.md +++ /dev/null @@ -1,254 +0,0 @@ -# \MatchmakerLobbiesApi - -All URIs are relative to *https://api.rivet.gg* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**matchmaker_lobbies_create**](MatchmakerLobbiesApi.md#matchmaker_lobbies_create) | **POST** /matchmaker/lobbies/create | -[**matchmaker_lobbies_find**](MatchmakerLobbiesApi.md#matchmaker_lobbies_find) | **POST** /matchmaker/lobbies/find | -[**matchmaker_lobbies_get_state**](MatchmakerLobbiesApi.md#matchmaker_lobbies_get_state) | **GET** /matchmaker/lobbies/{lobby_id}/state | -[**matchmaker_lobbies_join**](MatchmakerLobbiesApi.md#matchmaker_lobbies_join) | **POST** /matchmaker/lobbies/join | -[**matchmaker_lobbies_list**](MatchmakerLobbiesApi.md#matchmaker_lobbies_list) | **GET** /matchmaker/lobbies/list | -[**matchmaker_lobbies_ready**](MatchmakerLobbiesApi.md#matchmaker_lobbies_ready) | **POST** /matchmaker/lobbies/ready | -[**matchmaker_lobbies_set_closed**](MatchmakerLobbiesApi.md#matchmaker_lobbies_set_closed) | **PUT** /matchmaker/lobbies/closed | -[**matchmaker_lobbies_set_state**](MatchmakerLobbiesApi.md#matchmaker_lobbies_set_state) | **PUT** /matchmaker/lobbies/state | - - - -## matchmaker_lobbies_create - -> crate::models::MatchmakerCreateLobbyResponse matchmaker_lobbies_create(matchmaker_lobbies_create_request) - - -Creates a custom lobby. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_lobbies_create_request** | [**MatchmakerLobbiesCreateRequest**](MatchmakerLobbiesCreateRequest.md) | | [required] | - -### Return type - -[**crate::models::MatchmakerCreateLobbyResponse**](MatchmakerCreateLobbyResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_lobbies_find - -> crate::models::MatchmakerFindLobbyResponse matchmaker_lobbies_find(matchmaker_lobbies_find_request, origin) - - -Finds a lobby based on the given criteria. If a lobby is not found and `prevent_auto_create_lobby` is `false`, a new lobby will be created. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_lobbies_find_request** | [**MatchmakerLobbiesFindRequest**](MatchmakerLobbiesFindRequest.md) | | [required] | -**origin** | Option<**String**> | | | - -### Return type - -[**crate::models::MatchmakerFindLobbyResponse**](MatchmakerFindLobbyResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_lobbies_get_state - -> serde_json::Value matchmaker_lobbies_get_state(lobby_id) - - -Get the state of any lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**lobby_id** | **uuid::Uuid** | | [required] | - -### Return type - -[**serde_json::Value**](serde_json::Value.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### HTTP request headers - -- **Content-Type**: Not defined -- **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) - - -## matchmaker_lobbies_join - -> crate::models::MatchmakerJoinLobbyResponse matchmaker_lobbies_join(matchmaker_lobbies_join_request) - - -Joins a specific lobby. This request will use the direct player count configured for the lobby group. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_lobbies_join_request** | [**MatchmakerLobbiesJoinRequest**](MatchmakerLobbiesJoinRequest.md) | | [required] | - -### Return type - -[**crate::models::MatchmakerJoinLobbyResponse**](MatchmakerJoinLobbyResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_lobbies_list - -> crate::models::MatchmakerListLobbiesResponse matchmaker_lobbies_list(include_state) - - -Lists all open lobbies. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**include_state** | Option<**bool**> | | | - -### Return type - -[**crate::models::MatchmakerListLobbiesResponse**](MatchmakerListLobbiesResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### HTTP request headers - -- **Content-Type**: Not defined -- **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) - - -## matchmaker_lobbies_ready - -> matchmaker_lobbies_ready() - - -Marks the current lobby as ready to accept connections. Players will not be able to connect to this lobby until the lobby is flagged as ready. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - -### Parameters - -This endpoint does not need any parameter. - -### Return type - - (empty response body) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### HTTP request headers - -- **Content-Type**: Not defined -- **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) - - -## matchmaker_lobbies_set_closed - -> matchmaker_lobbies_set_closed(matchmaker_lobbies_set_closed_request) - - -If `is_closed` is `true`, the matchmaker will no longer route players to the lobby. Players can still join using the /join endpoint (this can be disabled by the developer by rejecting all new connections after setting the lobby to closed). Does not shutdown the lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_lobbies_set_closed_request** | [**MatchmakerLobbiesSetClosedRequest**](MatchmakerLobbiesSetClosedRequest.md) | | [required] | - -### Return type - - (empty response body) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_lobbies_set_state - -> matchmaker_lobbies_set_state(body) - - -Sets the state JSON of the current lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**body** | Option<**serde_json::Value**> | | | - -### Return type - - (empty response body) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - diff --git a/sdks/runtime/rust/docs/MatchmakerLobbiesCreateRequest.md b/sdks/runtime/rust/docs/MatchmakerLobbiesCreateRequest.md deleted file mode 100644 index d31bd7ab63..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerLobbiesCreateRequest.md +++ /dev/null @@ -1,18 +0,0 @@ -# MatchmakerLobbiesCreateRequest - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**captcha** | Option<[**crate::models::CaptchaConfig**](CaptchaConfig.md)> | | [optional] -**game_mode** | **String** | | -**lobby_config** | Option<[**serde_json::Value**](.md)> | | [optional] -**max_players** | Option<**i32**> | | [optional] -**publicity** | Option<[**crate::models::MatchmakerCustomLobbyPublicity**](MatchmakerCustomLobbyPublicity.md)> | | [optional] -**region** | Option<**String**> | | [optional] -**tags** | Option<**::std::collections::HashMap**> | | [optional] -**verification_data** | Option<[**serde_json::Value**](.md)> | | [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) - - diff --git a/sdks/runtime/rust/docs/MatchmakerLobbiesFindRequest.md b/sdks/runtime/rust/docs/MatchmakerLobbiesFindRequest.md deleted file mode 100644 index a0cdc87c19..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerLobbiesFindRequest.md +++ /dev/null @@ -1,17 +0,0 @@ -# MatchmakerLobbiesFindRequest - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**captcha** | Option<[**crate::models::CaptchaConfig**](CaptchaConfig.md)> | | [optional] -**game_modes** | **Vec** | | -**max_players** | Option<**i32**> | | [optional] -**prevent_auto_create_lobby** | Option<**bool**> | | [optional] -**regions** | Option<**Vec**> | | [optional] -**tags** | Option<**::std::collections::HashMap**> | | [optional] -**verification_data** | Option<[**serde_json::Value**](.md)> | | [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) - - diff --git a/sdks/runtime/rust/docs/MatchmakerLobbiesJoinRequest.md b/sdks/runtime/rust/docs/MatchmakerLobbiesJoinRequest.md deleted file mode 100644 index afffc6e3b2..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerLobbiesJoinRequest.md +++ /dev/null @@ -1,13 +0,0 @@ -# MatchmakerLobbiesJoinRequest - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**captcha** | Option<[**crate::models::CaptchaConfig**](CaptchaConfig.md)> | | [optional] -**lobby_id** | **String** | | -**verification_data** | Option<[**serde_json::Value**](.md)> | | [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) - - diff --git a/sdks/runtime/rust/docs/MatchmakerLobbyInfo.md b/sdks/runtime/rust/docs/MatchmakerLobbyInfo.md deleted file mode 100644 index 02f40bef1a..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerLobbyInfo.md +++ /dev/null @@ -1,18 +0,0 @@ -# MatchmakerLobbyInfo - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**game_mode_id** | **String** | | -**lobby_id** | [**uuid::Uuid**](uuid::Uuid.md) | | -**max_players_direct** | **i32** | | -**max_players_normal** | **i32** | | -**max_players_party** | **i32** | | -**region_id** | **String** | | -**state** | Option<[**serde_json::Value**](.md)> | | [optional] -**total_player_count** | **i32** | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerPlayersApi.md b/sdks/runtime/rust/docs/MatchmakerPlayersApi.md deleted file mode 100644 index 6e2549b32b..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerPlayersApi.md +++ /dev/null @@ -1,98 +0,0 @@ -# \MatchmakerPlayersApi - -All URIs are relative to *https://api.rivet.gg* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**matchmaker_players_connected**](MatchmakerPlayersApi.md#matchmaker_players_connected) | **POST** /matchmaker/players/connected | -[**matchmaker_players_disconnected**](MatchmakerPlayersApi.md#matchmaker_players_disconnected) | **POST** /matchmaker/players/disconnected | -[**matchmaker_players_get_statistics**](MatchmakerPlayersApi.md#matchmaker_players_get_statistics) | **GET** /matchmaker/players/statistics | - - - -## matchmaker_players_connected - -> matchmaker_players_connected(matchmaker_players_connected_request) - - -Validates the player token is valid and has not already been consumed then marks the player as connected. # Player Tokens and Reserved Slots Player tokens reserve a spot in the lobby until they expire. This allows for precise matchmaking up to exactly the lobby's player limit, which is important for games with small lobbies and a high influx of players. By calling this endpoint with the player token, the player's spot is marked as connected and will not expire. If this endpoint is never called, the player's token will expire and this spot will be filled by another player. # Anti-Botting Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. These endpoints have anti-botting measures (i.e. enforcing max player limits, captchas, and detecting bots), so valid player tokens provide some confidence that the player is not a bot. Therefore, it's important to make sure the token is valid by waiting for this endpoint to return OK before allowing the connected socket to do anything else. If this endpoint returns an error, the socket should be disconnected immediately. # How to Transmit the Player Token The client is responsible for acquiring the player token by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. Beyond that, it's up to the developer how the player token is transmitted to the lobby. If using WebSockets, the player token can be transmitted as a query parameter. Otherwise, the player token will likely be automatically sent by the client once the socket opens. As mentioned above, nothing else should happen until the player token is validated. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_players_connected_request** | [**MatchmakerPlayersConnectedRequest**](MatchmakerPlayersConnectedRequest.md) | | [required] | - -### Return type - - (empty response body) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_players_disconnected - -> matchmaker_players_disconnected(matchmaker_players_connected_request) - - -Marks a player as disconnected. # Ghost Players If players are not marked as disconnected, lobbies will result with \"ghost players\" that the matchmaker thinks exist but are no longer connected to the lobby. - -### Parameters - - -Name | Type | Description | Required | Notes -------------- | ------------- | ------------- | ------------- | ------------- -**matchmaker_players_connected_request** | [**MatchmakerPlayersConnectedRequest**](MatchmakerPlayersConnectedRequest.md) | | [required] | - -### Return type - - (empty response body) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### 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) - - -## matchmaker_players_get_statistics - -> crate::models::MatchmakerGetStatisticsResponse matchmaker_players_get_statistics() - - -Gives matchmaker statistics about the players in game. - -### Parameters - -This endpoint does not need any parameter. - -### Return type - -[**crate::models::MatchmakerGetStatisticsResponse**](MatchmakerGetStatisticsResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### HTTP request headers - -- **Content-Type**: Not defined -- **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) - diff --git a/sdks/runtime/rust/docs/MatchmakerPlayersConnectedRequest.md b/sdks/runtime/rust/docs/MatchmakerPlayersConnectedRequest.md deleted file mode 100644 index b4b004fe35..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerPlayersConnectedRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# MatchmakerPlayersConnectedRequest - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**player_token** | **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) - - diff --git a/sdks/runtime/rust/docs/MatchmakerRegionInfo.md b/sdks/runtime/rust/docs/MatchmakerRegionInfo.md deleted file mode 100644 index 10a2ff6747..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerRegionInfo.md +++ /dev/null @@ -1,15 +0,0 @@ -# MatchmakerRegionInfo - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**datacenter_coord** | [**crate::models::GeoCoord**](GeoCoord.md) | | -**datacenter_distance_from_client** | [**crate::models::GeoDistance**](GeoDistance.md) | | -**provider_display_name** | **String** | Represent a resource's readable display name. | -**region_display_name** | **String** | Represent a resource's readable display name. | -**region_id** | **String** | A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/sdks/runtime/rust/docs/MatchmakerRegionsApi.md b/sdks/runtime/rust/docs/MatchmakerRegionsApi.md deleted file mode 100644 index 8855453e63..0000000000 --- a/sdks/runtime/rust/docs/MatchmakerRegionsApi.md +++ /dev/null @@ -1,36 +0,0 @@ -# \MatchmakerRegionsApi - -All URIs are relative to *https://api.rivet.gg* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**matchmaker_regions_list**](MatchmakerRegionsApi.md#matchmaker_regions_list) | **GET** /matchmaker/regions | - - - -## matchmaker_regions_list - -> crate::models::MatchmakerListRegionsResponse matchmaker_regions_list() - - -Returns a list of regions available to this namespace. Regions are sorted by most optimal to least optimal. The player's IP address is used to calculate the regions' optimality. - -### Parameters - -This endpoint does not need any parameter. - -### Return type - -[**crate::models::MatchmakerListRegionsResponse**](MatchmakerListRegionsResponse.md) - -### Authorization - -[BearerAuth](../README.md#BearerAuth) - -### HTTP request headers - -- **Content-Type**: Not defined -- **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) - diff --git a/sdks/runtime/rust/docs/UploadPrepareFile.md b/sdks/runtime/rust/docs/UploadPrepareFile.md new file mode 100644 index 0000000000..1d9005c4f8 --- /dev/null +++ b/sdks/runtime/rust/docs/UploadPrepareFile.md @@ -0,0 +1,13 @@ +# UploadPrepareFile + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**content_length** | **i64** | Unsigned 64 bit integer. | +**content_type** | Option<**String**> | The MIME type of the file. | [optional] +**path** | **String** | The path/filename of the file. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/UploadPresignedRequest.md b/sdks/runtime/rust/docs/UploadPresignedRequest.md new file mode 100644 index 0000000000..dcefbbcaba --- /dev/null +++ b/sdks/runtime/rust/docs/UploadPresignedRequest.md @@ -0,0 +1,14 @@ +# UploadPresignedRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**byte_offset** | **i64** | The byte offset for this multipart chunk. Always 0 if not a multipart upload. | +**content_length** | **i64** | Expected size of this upload. | +**path** | **String** | The name of the file to upload. This is the same as the one given in the upload prepare file. | +**url** | **String** | The URL of the presigned request for which to upload your file to. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/docs/WatchResponse.md b/sdks/runtime/rust/docs/WatchResponse.md new file mode 100644 index 0000000000..9b64aba4f0 --- /dev/null +++ b/sdks/runtime/rust/docs/WatchResponse.md @@ -0,0 +1,11 @@ +# WatchResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**index** | **String** | Index indicating the version of the data responded. Pass this to `WatchQuery` to block and wait for the next response. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/sdks/runtime/rust/src/apis/actor_api.rs b/sdks/runtime/rust/src/apis/actor_api.rs new file mode 100644 index 0000000000..2d51849e5e --- /dev/null +++ b/sdks/runtime/rust/src/apis/actor_api.rs @@ -0,0 +1,231 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +use reqwest; + +use crate::apis::ResponseContent; +use super::{Error, configuration}; + + +/// struct for typed errors of method [`actor_create`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorCreateError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_destroy`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorDestroyError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_get`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorGetError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_list`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorListError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + + +/// Create a new dynamic actor. +pub async fn actor_create(configuration: &configuration::Configuration, actor_create_actor_request: crate::models::ActorCreateActorRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors", 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_create_actor_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +/// Destroy a dynamic actor. +pub async fn actor_destroy(configuration: &configuration::Configuration, actor: &str, project: Option<&str>, environment: Option<&str>, override_kill_timeout: Option) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors/{actor}", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = override_kill_timeout { + local_var_req_builder = local_var_req_builder.query(&[("override_kill_timeout", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +/// Gets a dynamic actor. +pub async fn actor_get(configuration: &configuration::Configuration, actor: &str, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors/{actor}", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +/// Lists all actors associated with the token used. Can be filtered by tags in the query string. +pub async fn actor_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>, tags_json: Option<&str>, include_destroyed: Option, cursor: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = include_destroyed { + local_var_req_builder = local_var_req_builder.query(&[("include_destroyed", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = cursor { + local_var_req_builder = local_var_req_builder.query(&[("cursor", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + diff --git a/sdks/runtime/rust/src/apis/actor_builds_api.rs b/sdks/runtime/rust/src/apis/actor_builds_api.rs new file mode 100644 index 0000000000..ed106893ef --- /dev/null +++ b/sdks/runtime/rust/src/apis/actor_builds_api.rs @@ -0,0 +1,272 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +use reqwest; + +use crate::apis::ResponseContent; +use super::{Error, configuration}; + + +/// struct for typed errors of method [`actor_builds_complete`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorBuildsCompleteError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_builds_get`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorBuildsGetError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_builds_list`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorBuildsListError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_builds_patch_tags`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorBuildsPatchTagsError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + +/// struct for typed errors of method [`actor_builds_prepare`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorBuildsPrepareError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + + +/// Marks an upload as complete. +pub async fn actor_builds_complete(configuration: &configuration::Configuration, build: &str, project: Option<&str>, environment: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}/complete", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + if !local_var_status.is_client_error() && !local_var_status.is_server_error() { + Ok(()) + } else { + let local_var_entity: Option = 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)) + } +} + +/// Get a build. +pub async fn actor_builds_get(configuration: &configuration::Configuration, build: &str, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +/// Lists all builds of the project associated with the token used. Can be filtered by tags in the query string. +pub async fn actor_builds_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>, tags_json: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds", local_var_configuration.base_path); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = tags_json { + local_var_req_builder = local_var_req_builder.query(&[("tags_json", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +pub async fn actor_builds_patch_tags(configuration: &configuration::Configuration, build: &str, actor_patch_build_tags_request: crate::models::ActorPatchBuildTagsRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/{build}/tags", local_var_configuration.base_path, build=crate::apis::urlencode(build)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::PATCH, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_patch_build_tags_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + +/// Creates a new project build for the given project. +pub async fn actor_builds_prepare(configuration: &configuration::Configuration, actor_prepare_build_request: crate::models::ActorPrepareBuildRequest, project: Option<&str>, environment: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/builds/prepare", 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_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + local_var_req_builder = local_var_req_builder.json(&actor_prepare_build_request); + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + diff --git a/sdks/runtime/rust/src/apis/actor_logs_api.rs b/sdks/runtime/rust/src/apis/actor_logs_api.rs new file mode 100644 index 0000000000..b82cf206cf --- /dev/null +++ b/sdks/runtime/rust/src/apis/actor_logs_api.rs @@ -0,0 +1,72 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +use reqwest; + +use crate::apis::ResponseContent; +use super::{Error, configuration}; + + +/// struct for typed errors of method [`actor_logs_get`] +#[derive(Debug, Clone, Serialize, Deserialize)] +#[serde(untagged)] +pub enum ActorLogsGetError { + Status400(crate::models::ErrorBody), + Status403(crate::models::ErrorBody), + Status404(crate::models::ErrorBody), + Status408(crate::models::ErrorBody), + Status429(crate::models::ErrorBody), + Status500(crate::models::ErrorBody), + UnknownValue(serde_json::Value), +} + + +/// Returns the logs for a given actor. +pub async fn actor_logs_get(configuration: &configuration::Configuration, actor: &str, stream: ActorLogStream, project: Option<&str>, environment: Option<&str>, watch_index: Option<&str>) -> Result> { + let local_var_configuration = configuration; + + let local_var_client = &local_var_configuration.client; + + let local_var_uri_str = format!("{}/actors/{actor}/logs", local_var_configuration.base_path, actor=crate::apis::urlencode(actor)); + let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &local_var_str.to_string())]); + } + local_var_req_builder = local_var_req_builder.query(&[("stream", &stream.to_string())]); + if let Some(ref local_var_str) = watch_index { + local_var_req_builder = local_var_req_builder.query(&[("watch_index", &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()); + } + if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { + local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); + }; + + let local_var_req = local_var_req_builder.build()?; + let local_var_resp = local_var_client.execute(local_var_req).await?; + + let local_var_status = local_var_resp.status(); + let local_var_content = local_var_resp.text().await?; + + 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 = 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)) + } +} + diff --git a/sdks/runtime/rust/src/apis/matchmaker_regions_api.rs b/sdks/runtime/rust/src/apis/actor_regions_api.rs similarity index 69% rename from sdks/runtime/rust/src/apis/matchmaker_regions_api.rs rename to sdks/runtime/rust/src/apis/actor_regions_api.rs index f70241924f..4dacb2916b 100644 --- a/sdks/runtime/rust/src/apis/matchmaker_regions_api.rs +++ b/sdks/runtime/rust/src/apis/actor_regions_api.rs @@ -15,10 +15,10 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method [`matchmaker_regions_list`] +/// struct for typed errors of method [`actor_regions_list`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] -pub enum MatchmakerRegionsListError { +pub enum ActorRegionsListError { Status400(crate::models::ErrorBody), Status403(crate::models::ErrorBody), Status404(crate::models::ErrorBody), @@ -29,15 +29,20 @@ pub enum MatchmakerRegionsListError { } -/// Returns a list of regions available to this namespace. Regions are sorted by most optimal to least optimal. The player's IP address is used to calculate the regions' optimality. -pub async fn matchmaker_regions_list(configuration: &configuration::Configuration, ) -> Result> { +pub async fn actor_regions_list(configuration: &configuration::Configuration, project: Option<&str>, environment: Option<&str>) -> Result> { let local_var_configuration = configuration; let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/matchmaker/regions", local_var_configuration.base_path); + let local_var_uri_str = format!("{}/regions", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); + if let Some(ref local_var_str) = project { + local_var_req_builder = local_var_req_builder.query(&[("project", &local_var_str.to_string())]); + } + if let Some(ref local_var_str) = environment { + local_var_req_builder = local_var_req_builder.query(&[("environment", &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()); } @@ -54,7 +59,7 @@ pub async fn matchmaker_regions_list(configuration: &configuration::Configuratio 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 = serde_json::from_str(&local_var_content).ok(); + let local_var_entity: Option = 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)) } diff --git a/sdks/runtime/rust/src/apis/matchmaker_lobbies_api.rs b/sdks/runtime/rust/src/apis/matchmaker_lobbies_api.rs deleted file mode 100644 index 50c2f0f0c6..0000000000 --- a/sdks/runtime/rust/src/apis/matchmaker_lobbies_api.rs +++ /dev/null @@ -1,381 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - -use reqwest; - -use crate::apis::ResponseContent; -use super::{Error, configuration}; - - -/// struct for typed errors of method [`matchmaker_lobbies_create`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesCreateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_find`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesFindError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_get_state`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesGetStateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_join`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesJoinError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_list`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesListError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_ready`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesReadyError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_set_closed`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesSetClosedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_lobbies_set_state`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerLobbiesSetStateError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - - -/// Creates a custom lobby. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_create(configuration: &configuration::Configuration, matchmaker_lobbies_create_request: crate::models::MatchmakerLobbiesCreateRequest) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/create", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_create_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - -/// Finds a lobby based on the given criteria. If a lobby is not found and `prevent_auto_create_lobby` is `false`, a new lobby will be created. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_find(configuration: &configuration::Configuration, matchmaker_lobbies_find_request: crate::models::MatchmakerLobbiesFindRequest, origin: Option<&str>) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/find", 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()); - } - if let Some(local_var_param_value) = origin { - local_var_req_builder = local_var_req_builder.header("origin", local_var_param_value.to_string()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_find_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - -/// Get the state of any lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_get_state(configuration: &configuration::Configuration, lobby_id: &str) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/{lobby_id}/state", local_var_configuration.base_path, lobby_id=crate::apis::urlencode(lobby_id)); - let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - -/// Joins a specific lobby. This request will use the direct player count configured for the lobby group. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_join(configuration: &configuration::Configuration, matchmaker_lobbies_join_request: crate::models::MatchmakerLobbiesJoinRequest) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/join", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_join_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - -/// Lists all open lobbies. When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in your game namespace, this endpoint does not require a token to authenticate. Otherwise, a [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) can be used for general authentication. -pub async fn matchmaker_lobbies_list(configuration: &configuration::Configuration, include_state: Option) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/list", local_var_configuration.base_path); - let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - - if let Some(ref local_var_str) = include_state { - local_var_req_builder = local_var_req_builder.query(&[("include_state", &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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - -/// Marks the current lobby as ready to accept connections. Players will not be able to connect to this lobby until the lobby is flagged as ready. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_ready(configuration: &configuration::Configuration, ) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/ready", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = 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)) - } -} - -/// If `is_closed` is `true`, the matchmaker will no longer route players to the lobby. Players can still join using the /join endpoint (this can be disabled by the developer by rejecting all new connections after setting the lobby to closed). Does not shutdown the lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_set_closed(configuration: &configuration::Configuration, matchmaker_lobbies_set_closed_request: crate::models::MatchmakerLobbiesSetClosedRequest) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/closed", local_var_configuration.base_path); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_lobbies_set_closed_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = 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)) - } -} - -/// Sets the state JSON of the current lobby. This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. -pub async fn matchmaker_lobbies_set_state(configuration: &configuration::Configuration, body: Option) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/lobbies/state", local_var_configuration.base_path); - 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&body); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = 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)) - } -} - diff --git a/sdks/runtime/rust/src/apis/matchmaker_players_api.rs b/sdks/runtime/rust/src/apis/matchmaker_players_api.rs deleted file mode 100644 index e0cb52729e..0000000000 --- a/sdks/runtime/rust/src/apis/matchmaker_players_api.rs +++ /dev/null @@ -1,152 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - -use reqwest; - -use crate::apis::ResponseContent; -use super::{Error, configuration}; - - -/// struct for typed errors of method [`matchmaker_players_connected`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerPlayersConnectedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_players_disconnected`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerPlayersDisconnectedError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - -/// struct for typed errors of method [`matchmaker_players_get_statistics`] -#[derive(Debug, Clone, Serialize, Deserialize)] -#[serde(untagged)] -pub enum MatchmakerPlayersGetStatisticsError { - Status400(crate::models::ErrorBody), - Status403(crate::models::ErrorBody), - Status404(crate::models::ErrorBody), - Status408(crate::models::ErrorBody), - Status429(crate::models::ErrorBody), - Status500(crate::models::ErrorBody), - UnknownValue(serde_json::Value), -} - - -/// Validates the player token is valid and has not already been consumed then marks the player as connected. # Player Tokens and Reserved Slots Player tokens reserve a spot in the lobby until they expire. This allows for precise matchmaking up to exactly the lobby's player limit, which is important for games with small lobbies and a high influx of players. By calling this endpoint with the player token, the player's spot is marked as connected and will not expire. If this endpoint is never called, the player's token will expire and this spot will be filled by another player. # Anti-Botting Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. These endpoints have anti-botting measures (i.e. enforcing max player limits, captchas, and detecting bots), so valid player tokens provide some confidence that the player is not a bot. Therefore, it's important to make sure the token is valid by waiting for this endpoint to return OK before allowing the connected socket to do anything else. If this endpoint returns an error, the socket should be disconnected immediately. # How to Transmit the Player Token The client is responsible for acquiring the player token by caling `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` event. Beyond that, it's up to the developer how the player token is transmitted to the lobby. If using WebSockets, the player token can be transmitted as a query parameter. Otherwise, the player token will likely be automatically sent by the client once the socket opens. As mentioned above, nothing else should happen until the player token is validated. -pub async fn matchmaker_players_connected(configuration: &configuration::Configuration, matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/players/connected", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = 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)) - } -} - -/// Marks a player as disconnected. # Ghost Players If players are not marked as disconnected, lobbies will result with \"ghost players\" that the matchmaker thinks exist but are no longer connected to the lobby. -pub async fn matchmaker_players_disconnected(configuration: &configuration::Configuration, matchmaker_players_connected_request: crate::models::MatchmakerPlayersConnectedRequest) -> Result<(), Error> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/players/disconnected", 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - local_var_req_builder = local_var_req_builder.json(&matchmaker_players_connected_request); - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - if !local_var_status.is_client_error() && !local_var_status.is_server_error() { - Ok(()) - } else { - let local_var_entity: Option = 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)) - } -} - -/// Gives matchmaker statistics about the players in game. -pub async fn matchmaker_players_get_statistics(configuration: &configuration::Configuration, ) -> Result> { - let local_var_configuration = configuration; - - let local_var_client = &local_var_configuration.client; - - let local_var_uri_str = format!("{}/matchmaker/players/statistics", local_var_configuration.base_path); - let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, 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()); - } - if let Some(ref local_var_token) = local_var_configuration.bearer_access_token { - local_var_req_builder = local_var_req_builder.bearer_auth(local_var_token.to_owned()); - }; - - let local_var_req = local_var_req_builder.build()?; - let local_var_resp = local_var_client.execute(local_var_req).await?; - - let local_var_status = local_var_resp.status(); - let local_var_content = local_var_resp.text().await?; - - 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 = 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)) - } -} - diff --git a/sdks/runtime/rust/src/apis/mod.rs b/sdks/runtime/rust/src/apis/mod.rs index 4a8fe5ba73..5079f3c0a6 100644 --- a/sdks/runtime/rust/src/apis/mod.rs +++ b/sdks/runtime/rust/src/apis/mod.rs @@ -90,8 +90,9 @@ pub fn parse_deep_object(prefix: &str, value: &serde_json::Value) -> Vec<(String unimplemented!("Only objects are supported with style=deepObject") } -pub mod matchmaker_lobbies_api; -pub mod matchmaker_players_api; -pub mod matchmaker_regions_api; +pub mod actor_api; +pub mod actor_builds_api; +pub mod actor_logs_api; +pub mod actor_regions_api; pub mod configuration; diff --git a/sdks/runtime/rust/src/models/actor_actor.rs b/sdks/runtime/rust/src/models/actor_actor.rs new file mode 100644 index 0000000000..15bbcbdf6b --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_actor.rs @@ -0,0 +1,55 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorActor { + #[serde(rename = "created_at")] + pub created_at: i64, + #[serde(rename = "destroyed_at", skip_serializing_if = "Option::is_none")] + pub destroyed_at: Option, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "lifecycle")] + pub lifecycle: Box, + #[serde(rename = "network")] + pub network: Box, + #[serde(rename = "region")] + pub region: String, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "started_at", skip_serializing_if = "Option::is_none")] + pub started_at: Option, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, +} + +impl ActorActor { + pub fn new(created_at: i64, id: uuid::Uuid, lifecycle: crate::models::ActorLifecycle, network: crate::models::ActorNetwork, region: String, resources: crate::models::ActorResources, runtime: crate::models::ActorRuntime, tags: Option) -> ActorActor { + ActorActor { + created_at, + destroyed_at: None, + id, + lifecycle: Box::new(lifecycle), + network: Box::new(network), + region, + resources: Box::new(resources), + runtime: Box::new(runtime), + started_at: None, + tags, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_build.rs b/sdks/runtime/rust/src/models/actor_build.rs new file mode 100644 index 0000000000..15122033fb --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_build.rs @@ -0,0 +1,43 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorBuild { + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// RFC3339 timestamp + #[serde(rename = "created_at")] + pub created_at: String, + #[serde(rename = "id")] + pub id: uuid::Uuid, + #[serde(rename = "name")] + pub name: String, + /// Tags of this build + #[serde(rename = "tags")] + pub tags: ::std::collections::HashMap, +} + +impl ActorBuild { + pub fn new(content_length: i64, created_at: String, id: uuid::Uuid, name: String, tags: ::std::collections::HashMap) -> ActorBuild { + ActorBuild { + content_length, + created_at, + id, + name, + tags, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/matchmaker_custom_lobby_publicity.rs b/sdks/runtime/rust/src/models/actor_build_compression.rs similarity index 50% rename from sdks/runtime/rust/src/models/matchmaker_custom_lobby_publicity.rs rename to sdks/runtime/rust/src/models/actor_build_compression.rs index e3dcead796..9554afe9c0 100644 --- a/sdks/runtime/rust/src/models/matchmaker_custom_lobby_publicity.rs +++ b/sdks/runtime/rust/src/models/actor_build_compression.rs @@ -11,26 +11,26 @@ /// #[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] -pub enum MatchmakerCustomLobbyPublicity { - #[serde(rename = "public")] - Public, - #[serde(rename = "private")] - Private, +pub enum ActorBuildCompression { + #[serde(rename = "none")] + None, + #[serde(rename = "lz4")] + Lz4, } -impl ToString for MatchmakerCustomLobbyPublicity { +impl ToString for ActorBuildCompression { fn to_string(&self) -> String { match self { - Self::Public => String::from("public"), - Self::Private => String::from("private"), + Self::None => String::from("none"), + Self::Lz4 => String::from("lz4"), } } } -impl Default for MatchmakerCustomLobbyPublicity { - fn default() -> MatchmakerCustomLobbyPublicity { - Self::Public +impl Default for ActorBuildCompression { + fn default() -> ActorBuildCompression { + Self::None } } diff --git a/sdks/runtime/rust/src/models/actor_build_kind.rs b/sdks/runtime/rust/src/models/actor_build_kind.rs new file mode 100644 index 0000000000..9e9fd07ff3 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_build_kind.rs @@ -0,0 +1,42 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +/// +#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] +pub enum ActorBuildKind { + #[serde(rename = "docker_image")] + DockerImage, + #[serde(rename = "oci_bundle")] + OciBundle, + #[serde(rename = "javascript")] + Javascript, + +} + +impl ToString for ActorBuildKind { + fn to_string(&self) -> String { + match self { + Self::DockerImage => String::from("docker_image"), + Self::OciBundle => String::from("oci_bundle"), + Self::Javascript => String::from("javascript"), + } + } +} + +impl Default for ActorBuildKind { + fn default() -> ActorBuildKind { + Self::DockerImage + } +} + + + + diff --git a/sdks/runtime/rust/src/models/actor_create_actor_network_request.rs b/sdks/runtime/rust/src/models/actor_create_actor_network_request.rs new file mode 100644 index 0000000000..1f8bb0e290 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_create_actor_network_request.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorCreateActorNetworkRequest { + #[serde(rename = "mode", skip_serializing_if = "Option::is_none")] + pub mode: Option, + #[serde(rename = "ports", skip_serializing_if = "Option::is_none")] + pub ports: Option<::std::collections::HashMap>, +} + +impl ActorCreateActorNetworkRequest { + pub fn new() -> ActorCreateActorNetworkRequest { + ActorCreateActorNetworkRequest { + mode: None, + ports: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_create_actor_port_request.rs b/sdks/runtime/rust/src/models/actor_create_actor_port_request.rs new file mode 100644 index 0000000000..74497965ba --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_create_actor_port_request.rs @@ -0,0 +1,34 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorCreateActorPortRequest { + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ActorPortProtocol, + #[serde(rename = "routing", skip_serializing_if = "Option::is_none")] + pub routing: Option>, +} + +impl ActorCreateActorPortRequest { + pub fn new(protocol: crate::models::ActorPortProtocol) -> ActorCreateActorPortRequest { + ActorCreateActorPortRequest { + internal_port: None, + protocol, + routing: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_create_actor_request.rs b/sdks/runtime/rust/src/models/actor_create_actor_request.rs new file mode 100644 index 0000000000..482c9ac50c --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_create_actor_request.rs @@ -0,0 +1,43 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorCreateActorRequest { + #[serde(rename = "lifecycle", skip_serializing_if = "Option::is_none")] + pub lifecycle: Option>, + #[serde(rename = "network", skip_serializing_if = "Option::is_none")] + pub network: Option>, + #[serde(rename = "region")] + pub region: String, + #[serde(rename = "resources")] + pub resources: Box, + #[serde(rename = "runtime")] + pub runtime: Box, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, +} + +impl ActorCreateActorRequest { + pub fn new(region: String, resources: crate::models::ActorResources, runtime: crate::models::ActorCreateActorRuntimeRequest, tags: Option) -> ActorCreateActorRequest { + ActorCreateActorRequest { + lifecycle: None, + network: None, + region, + resources: Box::new(resources), + runtime: Box::new(runtime), + tags, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/matchmaker_players_connected_request.rs b/sdks/runtime/rust/src/models/actor_create_actor_response.rs similarity index 52% rename from sdks/runtime/rust/src/models/matchmaker_players_connected_request.rs rename to sdks/runtime/rust/src/models/actor_create_actor_response.rs index c5de54c33c..bed37f45b7 100644 --- a/sdks/runtime/rust/src/models/matchmaker_players_connected_request.rs +++ b/sdks/runtime/rust/src/models/actor_create_actor_response.rs @@ -12,15 +12,15 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerPlayersConnectedRequest { - #[serde(rename = "player_token")] - pub player_token: String, +pub struct ActorCreateActorResponse { + #[serde(rename = "actor")] + pub actor: Box, } -impl MatchmakerPlayersConnectedRequest { - pub fn new(player_token: String) -> MatchmakerPlayersConnectedRequest { - MatchmakerPlayersConnectedRequest { - player_token, +impl ActorCreateActorResponse { + pub fn new(actor: crate::models::ActorActor) -> ActorCreateActorResponse { + ActorCreateActorResponse { + actor: Box::new(actor), } } } diff --git a/sdks/runtime/rust/src/models/actor_create_actor_runtime_request.rs b/sdks/runtime/rust/src/models/actor_create_actor_runtime_request.rs new file mode 100644 index 0000000000..502cbdc320 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_create_actor_runtime_request.rs @@ -0,0 +1,34 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorCreateActorRuntimeRequest { + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, +} + +impl ActorCreateActorRuntimeRequest { + pub fn new(build: uuid::Uuid) -> ActorCreateActorRuntimeRequest { + ActorCreateActorRuntimeRequest { + arguments: None, + build, + environment: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_get_actor_logs_response.rs b/sdks/runtime/rust/src/models/actor_get_actor_logs_response.rs new file mode 100644 index 0000000000..7475d6b35b --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_get_actor_logs_response.rs @@ -0,0 +1,36 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorGetActorLogsResponse { + /// Sorted old to new. + #[serde(rename = "lines")] + pub lines: Vec, + /// Sorted old to new. + #[serde(rename = "timestamps")] + pub timestamps: Vec, + #[serde(rename = "watch")] + pub watch: Box, +} + +impl ActorGetActorLogsResponse { + pub fn new(lines: Vec, timestamps: Vec, watch: crate::models::WatchResponse) -> ActorGetActorLogsResponse { + ActorGetActorLogsResponse { + lines, + timestamps, + watch: Box::new(watch), + } + } +} + + diff --git a/sdks/runtime/rust/src/models/matchmaker_lobbies_set_closed_request.rs b/sdks/runtime/rust/src/models/actor_get_actor_response.rs similarity index 53% rename from sdks/runtime/rust/src/models/matchmaker_lobbies_set_closed_request.rs rename to sdks/runtime/rust/src/models/actor_get_actor_response.rs index 32b2a4cfe2..39f675add9 100644 --- a/sdks/runtime/rust/src/models/matchmaker_lobbies_set_closed_request.rs +++ b/sdks/runtime/rust/src/models/actor_get_actor_response.rs @@ -12,15 +12,15 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerLobbiesSetClosedRequest { - #[serde(rename = "is_closed")] - pub is_closed: bool, +pub struct ActorGetActorResponse { + #[serde(rename = "actor")] + pub actor: Box, } -impl MatchmakerLobbiesSetClosedRequest { - pub fn new(is_closed: bool) -> MatchmakerLobbiesSetClosedRequest { - MatchmakerLobbiesSetClosedRequest { - is_closed, +impl ActorGetActorResponse { + pub fn new(actor: crate::models::ActorActor) -> ActorGetActorResponse { + ActorGetActorResponse { + actor: Box::new(actor), } } } diff --git a/sdks/runtime/rust/src/models/actor_get_build_response.rs b/sdks/runtime/rust/src/models/actor_get_build_response.rs new file mode 100644 index 0000000000..6b3176958d --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_get_build_response.rs @@ -0,0 +1,28 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorGetBuildResponse { + #[serde(rename = "build")] + pub build: Box, +} + +impl ActorGetBuildResponse { + pub fn new(build: crate::models::ActorBuild) -> ActorGetBuildResponse { + ActorGetBuildResponse { + build: Box::new(build), + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_guard_routing.rs b/sdks/runtime/rust/src/models/actor_guard_routing.rs new file mode 100644 index 0000000000..4ea1eccbc1 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_guard_routing.rs @@ -0,0 +1,28 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorGuardRouting { + #[serde(rename = "authorization", skip_serializing_if = "Option::is_none")] + pub authorization: Option>, +} + +impl ActorGuardRouting { + pub fn new() -> ActorGuardRouting { + ActorGuardRouting { + authorization: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_lifecycle.rs b/sdks/runtime/rust/src/models/actor_lifecycle.rs new file mode 100644 index 0000000000..bb91f243a0 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_lifecycle.rs @@ -0,0 +1,29 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorLifecycle { + /// The duration to wait for in milliseconds before killing the actor. This should be set to a safe default, and can be overridden during a DELETE request if needed. + #[serde(rename = "kill_timeout", skip_serializing_if = "Option::is_none")] + pub kill_timeout: Option, +} + +impl ActorLifecycle { + pub fn new() -> ActorLifecycle { + ActorLifecycle { + kill_timeout: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_list_actors_response.rs b/sdks/runtime/rust/src/models/actor_list_actors_response.rs new file mode 100644 index 0000000000..36c315efc1 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_list_actors_response.rs @@ -0,0 +1,29 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorListActorsResponse { + /// A list of actors for the project associated with the token. + #[serde(rename = "actors")] + pub actors: Vec, +} + +impl ActorListActorsResponse { + pub fn new(actors: Vec) -> ActorListActorsResponse { + ActorListActorsResponse { + actors, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_list_builds_response.rs b/sdks/runtime/rust/src/models/actor_list_builds_response.rs new file mode 100644 index 0000000000..d7aa8fc073 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_list_builds_response.rs @@ -0,0 +1,29 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorListBuildsResponse { + /// A list of builds for the project associated with the token. + #[serde(rename = "builds")] + pub builds: Vec, +} + +impl ActorListBuildsResponse { + pub fn new(builds: Vec) -> ActorListBuildsResponse { + ActorListBuildsResponse { + builds, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/matchmaker_list_regions_response.rs b/sdks/runtime/rust/src/models/actor_list_regions_response.rs similarity index 57% rename from sdks/runtime/rust/src/models/matchmaker_list_regions_response.rs rename to sdks/runtime/rust/src/models/actor_list_regions_response.rs index 07eae13752..cee15d56f7 100644 --- a/sdks/runtime/rust/src/models/matchmaker_list_regions_response.rs +++ b/sdks/runtime/rust/src/models/actor_list_regions_response.rs @@ -12,14 +12,14 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerListRegionsResponse { +pub struct ActorListRegionsResponse { #[serde(rename = "regions")] - pub regions: Vec, + pub regions: Vec, } -impl MatchmakerListRegionsResponse { - pub fn new(regions: Vec) -> MatchmakerListRegionsResponse { - MatchmakerListRegionsResponse { +impl ActorListRegionsResponse { + pub fn new(regions: Vec) -> ActorListRegionsResponse { + ActorListRegionsResponse { regions, } } diff --git a/sdks/runtime/rust/src/models/actor_log_stream.rs b/sdks/runtime/rust/src/models/actor_log_stream.rs new file mode 100644 index 0000000000..e4ec433d4f --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_log_stream.rs @@ -0,0 +1,39 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +/// +#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] +pub enum ActorLogStream { + #[serde(rename = "std_out")] + StdOut, + #[serde(rename = "std_err")] + StdErr, + +} + +impl ToString for ActorLogStream { + fn to_string(&self) -> String { + match self { + Self::StdOut => String::from("std_out"), + Self::StdErr => String::from("std_err"), + } + } +} + +impl Default for ActorLogStream { + fn default() -> ActorLogStream { + Self::StdOut + } +} + + + + diff --git a/sdks/runtime/rust/src/models/actor_network.rs b/sdks/runtime/rust/src/models/actor_network.rs new file mode 100644 index 0000000000..00c077b796 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_network.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorNetwork { + #[serde(rename = "mode")] + pub mode: crate::models::ActorNetworkMode, + #[serde(rename = "ports")] + pub ports: ::std::collections::HashMap, +} + +impl ActorNetwork { + pub fn new(mode: crate::models::ActorNetworkMode, ports: ::std::collections::HashMap) -> ActorNetwork { + ActorNetwork { + mode, + ports, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_network_mode.rs b/sdks/runtime/rust/src/models/actor_network_mode.rs new file mode 100644 index 0000000000..db460774fb --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_network_mode.rs @@ -0,0 +1,39 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +/// +#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] +pub enum ActorNetworkMode { + #[serde(rename = "bridge")] + Bridge, + #[serde(rename = "host")] + Host, + +} + +impl ToString for ActorNetworkMode { + fn to_string(&self) -> String { + match self { + Self::Bridge => String::from("bridge"), + Self::Host => String::from("host"), + } + } +} + +impl Default for ActorNetworkMode { + fn default() -> ActorNetworkMode { + Self::Bridge + } +} + + + + diff --git a/sdks/runtime/rust/src/models/actor_patch_build_tags_request.rs b/sdks/runtime/rust/src/models/actor_patch_build_tags_request.rs new file mode 100644 index 0000000000..26ec7f51b9 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_patch_build_tags_request.rs @@ -0,0 +1,32 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPatchBuildTagsRequest { + /// Removes the given tag keys from all other builds. + #[serde(rename = "exclusive_tags", skip_serializing_if = "Option::is_none")] + pub exclusive_tags: Option>, + #[serde(rename = "tags", deserialize_with = "Option::deserialize")] + pub tags: Option, +} + +impl ActorPatchBuildTagsRequest { + pub fn new(tags: Option) -> ActorPatchBuildTagsRequest { + ActorPatchBuildTagsRequest { + exclusive_tags: None, + tags, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_port.rs b/sdks/runtime/rust/src/models/actor_port.rs new file mode 100644 index 0000000000..a217927b23 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_port.rs @@ -0,0 +1,40 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPort { + #[serde(rename = "internal_port", skip_serializing_if = "Option::is_none")] + pub internal_port: Option, + #[serde(rename = "protocol")] + pub protocol: crate::models::ActorPortProtocol, + #[serde(rename = "public_hostname", skip_serializing_if = "Option::is_none")] + pub public_hostname: Option, + #[serde(rename = "public_port", skip_serializing_if = "Option::is_none")] + pub public_port: Option, + #[serde(rename = "routing")] + pub routing: Box, +} + +impl ActorPort { + pub fn new(protocol: crate::models::ActorPortProtocol, routing: crate::models::ActorPortRouting) -> ActorPort { + ActorPort { + internal_port: None, + protocol, + public_hostname: None, + public_port: None, + routing: Box::new(routing), + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_port_authorization.rs b/sdks/runtime/rust/src/models/actor_port_authorization.rs new file mode 100644 index 0000000000..c3962e01ac --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_port_authorization.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPortAuthorization { + #[serde(rename = "bearer", skip_serializing_if = "Option::is_none")] + pub bearer: Option, + #[serde(rename = "query", skip_serializing_if = "Option::is_none")] + pub query: Option>, +} + +impl ActorPortAuthorization { + pub fn new() -> ActorPortAuthorization { + ActorPortAuthorization { + bearer: None, + query: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_port_protocol.rs b/sdks/runtime/rust/src/models/actor_port_protocol.rs new file mode 100644 index 0000000000..06ef550fe2 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_port_protocol.rs @@ -0,0 +1,48 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + +/// +#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)] +pub enum ActorPortProtocol { + #[serde(rename = "http")] + Http, + #[serde(rename = "https")] + Https, + #[serde(rename = "tcp")] + Tcp, + #[serde(rename = "tcp_tls")] + TcpTls, + #[serde(rename = "udp")] + Udp, + +} + +impl ToString for ActorPortProtocol { + fn to_string(&self) -> String { + match self { + Self::Http => String::from("http"), + Self::Https => String::from("https"), + Self::Tcp => String::from("tcp"), + Self::TcpTls => String::from("tcp_tls"), + Self::Udp => String::from("udp"), + } + } +} + +impl Default for ActorPortProtocol { + fn default() -> ActorPortProtocol { + Self::Http + } +} + + + + diff --git a/sdks/runtime/rust/src/models/actor_port_query_authorization.rs b/sdks/runtime/rust/src/models/actor_port_query_authorization.rs new file mode 100644 index 0000000000..ea8b447713 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_port_query_authorization.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPortQueryAuthorization { + #[serde(rename = "key")] + pub key: String, + #[serde(rename = "value")] + pub value: String, +} + +impl ActorPortQueryAuthorization { + pub fn new(key: String, value: String) -> ActorPortQueryAuthorization { + ActorPortQueryAuthorization { + key, + value, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_port_routing.rs b/sdks/runtime/rust/src/models/actor_port_routing.rs new file mode 100644 index 0000000000..d360b659fe --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_port_routing.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPortRouting { + #[serde(rename = "guard", skip_serializing_if = "Option::is_none")] + pub guard: Option>, + #[serde(rename = "host", skip_serializing_if = "Option::is_none")] + pub host: Option, +} + +impl ActorPortRouting { + pub fn new() -> ActorPortRouting { + ActorPortRouting { + guard: None, + host: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_prepare_build_request.rs b/sdks/runtime/rust/src/models/actor_prepare_build_request.rs new file mode 100644 index 0000000000..ddf999bf9c --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_prepare_build_request.rs @@ -0,0 +1,47 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPrepareBuildRequest { + #[serde(rename = "compression", skip_serializing_if = "Option::is_none")] + pub compression: Option, + #[serde(rename = "image_file")] + pub image_file: Box, + /// A tag given to the project build. + #[serde(rename = "image_tag", skip_serializing_if = "Option::is_none")] + pub image_tag: Option, + #[serde(rename = "kind", skip_serializing_if = "Option::is_none")] + pub kind: Option, + #[serde(rename = "multipart_upload", skip_serializing_if = "Option::is_none")] + pub multipart_upload: Option, + #[serde(rename = "name")] + pub name: String, + #[serde(rename = "prewarm_regions", skip_serializing_if = "Option::is_none")] + pub prewarm_regions: Option>, +} + +impl ActorPrepareBuildRequest { + pub fn new(image_file: crate::models::UploadPrepareFile, name: String) -> ActorPrepareBuildRequest { + ActorPrepareBuildRequest { + compression: None, + image_file: Box::new(image_file), + image_tag: None, + kind: None, + multipart_upload: None, + name, + prewarm_regions: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_prepare_build_response.rs b/sdks/runtime/rust/src/models/actor_prepare_build_response.rs new file mode 100644 index 0000000000..9dd9f19ece --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_prepare_build_response.rs @@ -0,0 +1,34 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorPrepareBuildResponse { + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "image_presigned_request", skip_serializing_if = "Option::is_none")] + pub image_presigned_request: Option>, + #[serde(rename = "image_presigned_requests", skip_serializing_if = "Option::is_none")] + pub image_presigned_requests: Option>, +} + +impl ActorPrepareBuildResponse { + pub fn new(build: uuid::Uuid) -> ActorPrepareBuildResponse { + ActorPrepareBuildResponse { + build, + image_presigned_request: None, + image_presigned_requests: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/matchmaker_region_statistics.rs b/sdks/runtime/rust/src/models/actor_region.rs similarity index 55% rename from sdks/runtime/rust/src/models/matchmaker_region_statistics.rs rename to sdks/runtime/rust/src/models/actor_region.rs index 1f213d2419..9d89f0371e 100644 --- a/sdks/runtime/rust/src/models/matchmaker_region_statistics.rs +++ b/sdks/runtime/rust/src/models/actor_region.rs @@ -12,15 +12,18 @@ #[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerRegionStatistics { - #[serde(rename = "player_count")] - pub player_count: i64, +pub struct ActorRegion { + #[serde(rename = "id")] + pub id: String, + #[serde(rename = "name")] + pub name: String, } -impl MatchmakerRegionStatistics { - pub fn new(player_count: i64) -> MatchmakerRegionStatistics { - MatchmakerRegionStatistics { - player_count, +impl ActorRegion { + pub fn new(id: String, name: String) -> ActorRegion { + ActorRegion { + id, + name, } } } diff --git a/sdks/runtime/rust/src/models/actor_resources.rs b/sdks/runtime/rust/src/models/actor_resources.rs new file mode 100644 index 0000000000..57d7dc7ed4 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_resources.rs @@ -0,0 +1,33 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorResources { + /// The number of CPU cores in millicores, or 1/1000 of a core. For example, 1/8 of a core would be 125 millicores, and 1 core would be 1000 millicores. + #[serde(rename = "cpu")] + pub cpu: i32, + /// The amount of memory in megabytes + #[serde(rename = "memory")] + pub memory: i32, +} + +impl ActorResources { + pub fn new(cpu: i32, memory: i32) -> ActorResources { + ActorResources { + cpu, + memory, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/actor_runtime.rs b/sdks/runtime/rust/src/models/actor_runtime.rs new file mode 100644 index 0000000000..63ba97b4e7 --- /dev/null +++ b/sdks/runtime/rust/src/models/actor_runtime.rs @@ -0,0 +1,34 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct ActorRuntime { + #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")] + pub arguments: Option>, + #[serde(rename = "build")] + pub build: uuid::Uuid, + #[serde(rename = "environment", skip_serializing_if = "Option::is_none")] + pub environment: Option<::std::collections::HashMap>, +} + +impl ActorRuntime { + pub fn new(build: uuid::Uuid) -> ActorRuntime { + ActorRuntime { + arguments: None, + build, + environment: None, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/captcha_config.rs b/sdks/runtime/rust/src/models/captcha_config.rs deleted file mode 100644 index d285073ecd..0000000000 --- a/sdks/runtime/rust/src/models/captcha_config.rs +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// CaptchaConfig : Methods to verify a captcha - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct CaptchaConfig { - #[serde(rename = "hcaptcha", skip_serializing_if = "Option::is_none")] - pub hcaptcha: Option>, - #[serde(rename = "turnstile", skip_serializing_if = "Option::is_none")] - pub turnstile: Option>, -} - -impl CaptchaConfig { - /// Methods to verify a captcha - pub fn new() -> CaptchaConfig { - CaptchaConfig { - hcaptcha: None, - turnstile: None, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/captcha_config_hcaptcha.rs b/sdks/runtime/rust/src/models/captcha_config_hcaptcha.rs deleted file mode 100644 index a342255d1d..0000000000 --- a/sdks/runtime/rust/src/models/captcha_config_hcaptcha.rs +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// CaptchaConfigHcaptcha : Captcha configuration. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct CaptchaConfigHcaptcha { - #[serde(rename = "client_response")] - pub client_response: String, -} - -impl CaptchaConfigHcaptcha { - /// Captcha configuration. - pub fn new(client_response: String) -> CaptchaConfigHcaptcha { - CaptchaConfigHcaptcha { - client_response, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/captcha_config_turnstile.rs b/sdks/runtime/rust/src/models/captcha_config_turnstile.rs deleted file mode 100644 index ca74d127c0..0000000000 --- a/sdks/runtime/rust/src/models/captcha_config_turnstile.rs +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// CaptchaConfigTurnstile : Captcha configuration. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct CaptchaConfigTurnstile { - #[serde(rename = "client_response")] - pub client_response: String, -} - -impl CaptchaConfigTurnstile { - /// Captcha configuration. - pub fn new(client_response: String) -> CaptchaConfigTurnstile { - CaptchaConfigTurnstile { - client_response, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/geo_coord.rs b/sdks/runtime/rust/src/models/geo_coord.rs deleted file mode 100644 index 6ebb7e3346..0000000000 --- a/sdks/runtime/rust/src/models/geo_coord.rs +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// GeoCoord : Geographical coordinates for a location on Planet Earth. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct GeoCoord { - #[serde(rename = "latitude")] - pub latitude: f64, - #[serde(rename = "longitude")] - pub longitude: f64, -} - -impl GeoCoord { - /// Geographical coordinates for a location on Planet Earth. - pub fn new(latitude: f64, longitude: f64) -> GeoCoord { - GeoCoord { - latitude, - longitude, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/geo_distance.rs b/sdks/runtime/rust/src/models/geo_distance.rs deleted file mode 100644 index 19b1f82bf0..0000000000 --- a/sdks/runtime/rust/src/models/geo_distance.rs +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// GeoDistance : Distance available in multiple units. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct GeoDistance { - #[serde(rename = "kilometers")] - pub kilometers: f64, - #[serde(rename = "miles")] - pub miles: f64, -} - -impl GeoDistance { - /// Distance available in multiple units. - pub fn new(kilometers: f64, miles: f64) -> GeoDistance { - GeoDistance { - kilometers, - miles, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_create_lobby_response.rs b/sdks/runtime/rust/src/models/matchmaker_create_lobby_response.rs deleted file mode 100644 index 0d1bcc029a..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_create_lobby_response.rs +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerCreateLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, -} - -impl MatchmakerCreateLobbyResponse { - pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerCreateLobbyResponse { - MatchmakerCreateLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_find_lobby_response.rs b/sdks/runtime/rust/src/models/matchmaker_find_lobby_response.rs deleted file mode 100644 index 0a72c11058..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_find_lobby_response.rs +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerFindLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, -} - -impl MatchmakerFindLobbyResponse { - pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerFindLobbyResponse { - MatchmakerFindLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_game_mode_info.rs b/sdks/runtime/rust/src/models/matchmaker_game_mode_info.rs deleted file mode 100644 index d3d921a688..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_game_mode_info.rs +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerGameModeInfo : A game mode that the player can join. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerGameModeInfo { - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "game_mode_id")] - pub game_mode_id: String, -} - -impl MatchmakerGameModeInfo { - /// A game mode that the player can join. - pub fn new(game_mode_id: String) -> MatchmakerGameModeInfo { - MatchmakerGameModeInfo { - game_mode_id, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_game_mode_statistics.rs b/sdks/runtime/rust/src/models/matchmaker_game_mode_statistics.rs deleted file mode 100644 index d2da15d2d9..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_game_mode_statistics.rs +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerGameModeStatistics { - #[serde(rename = "player_count")] - pub player_count: i64, - #[serde(rename = "regions")] - pub regions: ::std::collections::HashMap, -} - -impl MatchmakerGameModeStatistics { - pub fn new(player_count: i64, regions: ::std::collections::HashMap) -> MatchmakerGameModeStatistics { - MatchmakerGameModeStatistics { - player_count, - regions, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_get_statistics_response.rs b/sdks/runtime/rust/src/models/matchmaker_get_statistics_response.rs deleted file mode 100644 index 4275e93a5e..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_get_statistics_response.rs +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerGetStatisticsResponse { - #[serde(rename = "game_modes")] - pub game_modes: ::std::collections::HashMap, - #[serde(rename = "player_count")] - pub player_count: i64, -} - -impl MatchmakerGetStatisticsResponse { - pub fn new(game_modes: ::std::collections::HashMap, player_count: i64) -> MatchmakerGetStatisticsResponse { - MatchmakerGetStatisticsResponse { - game_modes, - player_count, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_lobby.rs b/sdks/runtime/rust/src/models/matchmaker_join_lobby.rs deleted file mode 100644 index aaf5bd9cd7..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_lobby.rs +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerJoinLobby : A matchmaker lobby. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinLobby { - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - #[serde(rename = "player")] - pub player: Box, - /// **Deprecated** - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, - #[serde(rename = "region")] - pub region: Box, -} - -impl MatchmakerJoinLobby { - /// A matchmaker lobby. - pub fn new(lobby_id: uuid::Uuid, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap, region: crate::models::MatchmakerJoinRegion) -> MatchmakerJoinLobby { - MatchmakerJoinLobby { - lobby_id, - player: Box::new(player), - ports, - region: Box::new(region), - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_lobby_response.rs b/sdks/runtime/rust/src/models/matchmaker_join_lobby_response.rs deleted file mode 100644 index d284339b25..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_lobby_response.rs +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinLobbyResponse { - #[serde(rename = "lobby")] - pub lobby: Box, - #[serde(rename = "player")] - pub player: Box, - #[serde(rename = "ports")] - pub ports: ::std::collections::HashMap, -} - -impl MatchmakerJoinLobbyResponse { - pub fn new(lobby: crate::models::MatchmakerJoinLobby, player: crate::models::MatchmakerJoinPlayer, ports: ::std::collections::HashMap) -> MatchmakerJoinLobbyResponse { - MatchmakerJoinLobbyResponse { - lobby: Box::new(lobby), - player: Box::new(player), - ports, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_player.rs b/sdks/runtime/rust/src/models/matchmaker_join_player.rs deleted file mode 100644 index 198434b8ac..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_player.rs +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerJoinPlayer : A matchmaker lobby player. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinPlayer { - /// Documentation at https://jwt.io/ - #[serde(rename = "token")] - pub token: String, -} - -impl MatchmakerJoinPlayer { - /// A matchmaker lobby player. - pub fn new(token: String) -> MatchmakerJoinPlayer { - MatchmakerJoinPlayer { - token, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_port.rs b/sdks/runtime/rust/src/models/matchmaker_join_port.rs deleted file mode 100644 index 86e07f170a..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_port.rs +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinPort { - /// The host for the given port. Will be null if using a port range. - #[serde(rename = "host", skip_serializing_if = "Option::is_none")] - pub host: Option, - #[serde(rename = "hostname")] - pub hostname: String, - /// Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. - #[serde(rename = "is_tls")] - pub is_tls: bool, - /// The port number for this lobby. Will be null if using a port range. - #[serde(rename = "port", skip_serializing_if = "Option::is_none")] - pub port: Option, - #[serde(rename = "port_range", skip_serializing_if = "Option::is_none")] - pub port_range: Option>, -} - -impl MatchmakerJoinPort { - pub fn new(hostname: String, is_tls: bool) -> MatchmakerJoinPort { - MatchmakerJoinPort { - host: None, - hostname, - is_tls, - port: None, - port_range: None, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_port_range.rs b/sdks/runtime/rust/src/models/matchmaker_join_port_range.rs deleted file mode 100644 index 5b793d5c52..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_port_range.rs +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerJoinPortRange : Inclusive range of ports that can be connected to. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinPortRange { - /// Maximum port that can be connected to. Inclusive range. - #[serde(rename = "max")] - pub max: i32, - /// Minimum port that can be connected to. Inclusive range. - #[serde(rename = "min")] - pub min: i32, -} - -impl MatchmakerJoinPortRange { - /// Inclusive range of ports that can be connected to. - pub fn new(max: i32, min: i32) -> MatchmakerJoinPortRange { - MatchmakerJoinPortRange { - max, - min, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_join_region.rs b/sdks/runtime/rust/src/models/matchmaker_join_region.rs deleted file mode 100644 index 7f38d680cf..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_join_region.rs +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerJoinRegion : A matchmaker lobby region. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerJoinRegion { - /// Represent a resource's readable display name. - #[serde(rename = "display_name")] - pub display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "region_id")] - pub region_id: String, -} - -impl MatchmakerJoinRegion { - /// A matchmaker lobby region. - pub fn new(display_name: String, region_id: String) -> MatchmakerJoinRegion { - MatchmakerJoinRegion { - display_name, - region_id, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_list_lobbies_response.rs b/sdks/runtime/rust/src/models/matchmaker_list_lobbies_response.rs deleted file mode 100644 index 181d6b0bd0..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_list_lobbies_response.rs +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerListLobbiesResponse { - #[serde(rename = "game_modes")] - pub game_modes: Vec, - #[serde(rename = "lobbies")] - pub lobbies: Vec, - #[serde(rename = "regions")] - pub regions: Vec, -} - -impl MatchmakerListLobbiesResponse { - pub fn new(game_modes: Vec, lobbies: Vec, regions: Vec) -> MatchmakerListLobbiesResponse { - MatchmakerListLobbiesResponse { - game_modes, - lobbies, - regions, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_lobbies_create_request.rs b/sdks/runtime/rust/src/models/matchmaker_lobbies_create_request.rs deleted file mode 100644 index 4a61128a8f..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_lobbies_create_request.rs +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerLobbiesCreateRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "game_mode")] - pub game_mode: String, - #[serde(rename = "lobby_config", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] - pub lobby_config: Option>, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde(rename = "publicity", skip_serializing_if = "Option::is_none")] - pub publicity: Option, - #[serde(rename = "region", skip_serializing_if = "Option::is_none")] - pub region: Option, - #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option<::std::collections::HashMap>, - #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] - pub verification_data: Option>, -} - -impl MatchmakerLobbiesCreateRequest { - pub fn new(game_mode: String) -> MatchmakerLobbiesCreateRequest { - MatchmakerLobbiesCreateRequest { - captcha: None, - game_mode, - lobby_config: None, - max_players: None, - publicity: None, - region: None, - tags: None, - verification_data: None, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_lobbies_find_request.rs b/sdks/runtime/rust/src/models/matchmaker_lobbies_find_request.rs deleted file mode 100644 index 6761c70629..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_lobbies_find_request.rs +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerLobbiesFindRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "game_modes")] - pub game_modes: Vec, - #[serde(rename = "max_players", skip_serializing_if = "Option::is_none")] - pub max_players: Option, - #[serde(rename = "prevent_auto_create_lobby", skip_serializing_if = "Option::is_none")] - pub prevent_auto_create_lobby: Option, - #[serde(rename = "regions", skip_serializing_if = "Option::is_none")] - pub regions: Option>, - #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option<::std::collections::HashMap>, - #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] - pub verification_data: Option>, -} - -impl MatchmakerLobbiesFindRequest { - pub fn new(game_modes: Vec) -> MatchmakerLobbiesFindRequest { - MatchmakerLobbiesFindRequest { - captcha: None, - game_modes, - max_players: None, - prevent_auto_create_lobby: None, - regions: None, - tags: None, - verification_data: None, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_lobbies_join_request.rs b/sdks/runtime/rust/src/models/matchmaker_lobbies_join_request.rs deleted file mode 100644 index 6f622e00a1..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_lobbies_join_request.rs +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerLobbiesJoinRequest { - #[serde(rename = "captcha", skip_serializing_if = "Option::is_none")] - pub captcha: Option>, - #[serde(rename = "lobby_id")] - pub lobby_id: String, - #[serde(rename = "verification_data", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] - pub verification_data: Option>, -} - -impl MatchmakerLobbiesJoinRequest { - pub fn new(lobby_id: String) -> MatchmakerLobbiesJoinRequest { - MatchmakerLobbiesJoinRequest { - captcha: None, - lobby_id, - verification_data: None, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_lobby_info.rs b/sdks/runtime/rust/src/models/matchmaker_lobby_info.rs deleted file mode 100644 index bdae0cba81..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_lobby_info.rs +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerLobbyInfo : A public lobby in the lobby list. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerLobbyInfo { - #[serde(rename = "game_mode_id")] - pub game_mode_id: String, - #[serde(rename = "lobby_id")] - pub lobby_id: uuid::Uuid, - #[serde(rename = "max_players_direct")] - pub max_players_direct: i32, - #[serde(rename = "max_players_normal")] - pub max_players_normal: i32, - #[serde(rename = "max_players_party")] - pub max_players_party: i32, - #[serde(rename = "region_id")] - pub region_id: String, - #[serde(rename = "state", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")] - pub state: Option>, - #[serde(rename = "total_player_count")] - pub total_player_count: i32, -} - -impl MatchmakerLobbyInfo { - /// A public lobby in the lobby list. - pub fn new(game_mode_id: String, lobby_id: uuid::Uuid, max_players_direct: i32, max_players_normal: i32, max_players_party: i32, region_id: String, total_player_count: i32) -> MatchmakerLobbyInfo { - MatchmakerLobbyInfo { - game_mode_id, - lobby_id, - max_players_direct, - max_players_normal, - max_players_party, - region_id, - state: None, - total_player_count, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/matchmaker_region_info.rs b/sdks/runtime/rust/src/models/matchmaker_region_info.rs deleted file mode 100644 index ed5df899d6..0000000000 --- a/sdks/runtime/rust/src/models/matchmaker_region_info.rs +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Rivet API - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 0.0.1 - * - * Generated by: https://openapi-generator.tech - */ - -/// MatchmakerRegionInfo : A region that the player can connect to. - - - -#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] -pub struct MatchmakerRegionInfo { - #[serde(rename = "datacenter_coord")] - pub datacenter_coord: Box, - #[serde(rename = "datacenter_distance_from_client")] - pub datacenter_distance_from_client: Box, - /// Represent a resource's readable display name. - #[serde(rename = "provider_display_name")] - pub provider_display_name: String, - /// Represent a resource's readable display name. - #[serde(rename = "region_display_name")] - pub region_display_name: String, - /// A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - #[serde(rename = "region_id")] - pub region_id: String, -} - -impl MatchmakerRegionInfo { - /// A region that the player can connect to. - pub fn new(datacenter_coord: crate::models::GeoCoord, datacenter_distance_from_client: crate::models::GeoDistance, provider_display_name: String, region_display_name: String, region_id: String) -> MatchmakerRegionInfo { - MatchmakerRegionInfo { - datacenter_coord: Box::new(datacenter_coord), - datacenter_distance_from_client: Box::new(datacenter_distance_from_client), - provider_display_name, - region_display_name, - region_id, - } - } -} - - diff --git a/sdks/runtime/rust/src/models/mod.rs b/sdks/runtime/rust/src/models/mod.rs index 7a3f446b64..7e9ac95834 100644 --- a/sdks/runtime/rust/src/models/mod.rs +++ b/sdks/runtime/rust/src/models/mod.rs @@ -1,56 +1,70 @@ -pub mod captcha_config; -pub use self::captcha_config::CaptchaConfig; -pub mod captcha_config_hcaptcha; -pub use self::captcha_config_hcaptcha::CaptchaConfigHcaptcha; -pub mod captcha_config_turnstile; -pub use self::captcha_config_turnstile::CaptchaConfigTurnstile; +pub mod actor_actor; +pub use self::actor_actor::ActorActor; +pub mod actor_build; +pub use self::actor_build::ActorBuild; +pub mod actor_build_compression; +pub use self::actor_build_compression::ActorBuildCompression; +pub mod actor_build_kind; +pub use self::actor_build_kind::ActorBuildKind; +pub mod actor_create_actor_network_request; +pub use self::actor_create_actor_network_request::ActorCreateActorNetworkRequest; +pub mod actor_create_actor_port_request; +pub use self::actor_create_actor_port_request::ActorCreateActorPortRequest; +pub mod actor_create_actor_request; +pub use self::actor_create_actor_request::ActorCreateActorRequest; +pub mod actor_create_actor_response; +pub use self::actor_create_actor_response::ActorCreateActorResponse; +pub mod actor_create_actor_runtime_request; +pub use self::actor_create_actor_runtime_request::ActorCreateActorRuntimeRequest; +pub mod actor_get_actor_logs_response; +pub use self::actor_get_actor_logs_response::ActorGetActorLogsResponse; +pub mod actor_get_actor_response; +pub use self::actor_get_actor_response::ActorGetActorResponse; +pub mod actor_get_build_response; +pub use self::actor_get_build_response::ActorGetBuildResponse; +pub mod actor_guard_routing; +pub use self::actor_guard_routing::ActorGuardRouting; +pub mod actor_lifecycle; +pub use self::actor_lifecycle::ActorLifecycle; +pub mod actor_list_actors_response; +pub use self::actor_list_actors_response::ActorListActorsResponse; +pub mod actor_list_builds_response; +pub use self::actor_list_builds_response::ActorListBuildsResponse; +pub mod actor_list_regions_response; +pub use self::actor_list_regions_response::ActorListRegionsResponse; +pub mod actor_log_stream; +pub use self::actor_log_stream::ActorLogStream; +pub mod actor_network; +pub use self::actor_network::ActorNetwork; +pub mod actor_network_mode; +pub use self::actor_network_mode::ActorNetworkMode; +pub mod actor_patch_build_tags_request; +pub use self::actor_patch_build_tags_request::ActorPatchBuildTagsRequest; +pub mod actor_port; +pub use self::actor_port::ActorPort; +pub mod actor_port_authorization; +pub use self::actor_port_authorization::ActorPortAuthorization; +pub mod actor_port_protocol; +pub use self::actor_port_protocol::ActorPortProtocol; +pub mod actor_port_query_authorization; +pub use self::actor_port_query_authorization::ActorPortQueryAuthorization; +pub mod actor_port_routing; +pub use self::actor_port_routing::ActorPortRouting; +pub mod actor_prepare_build_request; +pub use self::actor_prepare_build_request::ActorPrepareBuildRequest; +pub mod actor_prepare_build_response; +pub use self::actor_prepare_build_response::ActorPrepareBuildResponse; +pub mod actor_region; +pub use self::actor_region::ActorRegion; +pub mod actor_resources; +pub use self::actor_resources::ActorResources; +pub mod actor_runtime; +pub use self::actor_runtime::ActorRuntime; pub mod error_body; pub use self::error_body::ErrorBody; -pub mod geo_coord; -pub use self::geo_coord::GeoCoord; -pub mod geo_distance; -pub use self::geo_distance::GeoDistance; -pub mod matchmaker_create_lobby_response; -pub use self::matchmaker_create_lobby_response::MatchmakerCreateLobbyResponse; -pub mod matchmaker_custom_lobby_publicity; -pub use self::matchmaker_custom_lobby_publicity::MatchmakerCustomLobbyPublicity; -pub mod matchmaker_find_lobby_response; -pub use self::matchmaker_find_lobby_response::MatchmakerFindLobbyResponse; -pub mod matchmaker_game_mode_info; -pub use self::matchmaker_game_mode_info::MatchmakerGameModeInfo; -pub mod matchmaker_game_mode_statistics; -pub use self::matchmaker_game_mode_statistics::MatchmakerGameModeStatistics; -pub mod matchmaker_get_statistics_response; -pub use self::matchmaker_get_statistics_response::MatchmakerGetStatisticsResponse; -pub mod matchmaker_join_lobby; -pub use self::matchmaker_join_lobby::MatchmakerJoinLobby; -pub mod matchmaker_join_lobby_response; -pub use self::matchmaker_join_lobby_response::MatchmakerJoinLobbyResponse; -pub mod matchmaker_join_player; -pub use self::matchmaker_join_player::MatchmakerJoinPlayer; -pub mod matchmaker_join_port; -pub use self::matchmaker_join_port::MatchmakerJoinPort; -pub mod matchmaker_join_port_range; -pub use self::matchmaker_join_port_range::MatchmakerJoinPortRange; -pub mod matchmaker_join_region; -pub use self::matchmaker_join_region::MatchmakerJoinRegion; -pub mod matchmaker_list_lobbies_response; -pub use self::matchmaker_list_lobbies_response::MatchmakerListLobbiesResponse; -pub mod matchmaker_list_regions_response; -pub use self::matchmaker_list_regions_response::MatchmakerListRegionsResponse; -pub mod matchmaker_lobbies_create_request; -pub use self::matchmaker_lobbies_create_request::MatchmakerLobbiesCreateRequest; -pub mod matchmaker_lobbies_find_request; -pub use self::matchmaker_lobbies_find_request::MatchmakerLobbiesFindRequest; -pub mod matchmaker_lobbies_join_request; -pub use self::matchmaker_lobbies_join_request::MatchmakerLobbiesJoinRequest; -pub mod matchmaker_lobbies_set_closed_request; -pub use self::matchmaker_lobbies_set_closed_request::MatchmakerLobbiesSetClosedRequest; -pub mod matchmaker_lobby_info; -pub use self::matchmaker_lobby_info::MatchmakerLobbyInfo; -pub mod matchmaker_players_connected_request; -pub use self::matchmaker_players_connected_request::MatchmakerPlayersConnectedRequest; -pub mod matchmaker_region_info; -pub use self::matchmaker_region_info::MatchmakerRegionInfo; -pub mod matchmaker_region_statistics; -pub use self::matchmaker_region_statistics::MatchmakerRegionStatistics; +pub mod upload_prepare_file; +pub use self::upload_prepare_file::UploadPrepareFile; +pub mod upload_presigned_request; +pub use self::upload_presigned_request::UploadPresignedRequest; +pub mod watch_response; +pub use self::watch_response::WatchResponse; diff --git a/sdks/runtime/rust/src/models/upload_prepare_file.rs b/sdks/runtime/rust/src/models/upload_prepare_file.rs new file mode 100644 index 0000000000..0d197af99b --- /dev/null +++ b/sdks/runtime/rust/src/models/upload_prepare_file.rs @@ -0,0 +1,39 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + +/// UploadPrepareFile : A file being prepared to upload. + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct UploadPrepareFile { + /// Unsigned 64 bit integer. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The MIME type of the file. + #[serde(rename = "content_type", skip_serializing_if = "Option::is_none")] + pub content_type: Option, + /// The path/filename of the file. + #[serde(rename = "path")] + pub path: String, +} + +impl UploadPrepareFile { + /// A file being prepared to upload. + pub fn new(content_length: i64, path: String) -> UploadPrepareFile { + UploadPrepareFile { + content_length, + content_type: None, + path, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/upload_presigned_request.rs b/sdks/runtime/rust/src/models/upload_presigned_request.rs new file mode 100644 index 0000000000..7f2ca3aad5 --- /dev/null +++ b/sdks/runtime/rust/src/models/upload_presigned_request.rs @@ -0,0 +1,43 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + +/// UploadPresignedRequest : A presigned request used to upload files. Upload your file to the given URL via a PUT request. + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct UploadPresignedRequest { + /// The byte offset for this multipart chunk. Always 0 if not a multipart upload. + #[serde(rename = "byte_offset")] + pub byte_offset: i64, + /// Expected size of this upload. + #[serde(rename = "content_length")] + pub content_length: i64, + /// The name of the file to upload. This is the same as the one given in the upload prepare file. + #[serde(rename = "path")] + pub path: String, + /// The URL of the presigned request for which to upload your file to. + #[serde(rename = "url")] + pub url: String, +} + +impl UploadPresignedRequest { + /// A presigned request used to upload files. Upload your file to the given URL via a PUT request. + pub fn new(byte_offset: i64, content_length: i64, path: String, url: String) -> UploadPresignedRequest { + UploadPresignedRequest { + byte_offset, + content_length, + path, + url, + } + } +} + + diff --git a/sdks/runtime/rust/src/models/watch_response.rs b/sdks/runtime/rust/src/models/watch_response.rs new file mode 100644 index 0000000000..d1ca872c6c --- /dev/null +++ b/sdks/runtime/rust/src/models/watch_response.rs @@ -0,0 +1,31 @@ +/* + * Rivet API + * + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 0.0.1 + * + * Generated by: https://openapi-generator.tech + */ + +/// WatchResponse : Provided by watchable endpoints used in blocking loops. + + + +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] +pub struct WatchResponse { + /// Index indicating the version of the data responded. Pass this to `WatchQuery` to block and wait for the next response. + #[serde(rename = "index")] + pub index: String, +} + +impl WatchResponse { + /// Provided by watchable endpoints used in blocking loops. + pub fn new(index: String) -> WatchResponse { + WatchResponse { + index, + } + } +} + + diff --git a/sdks/runtime/typescript/src/Client.ts b/sdks/runtime/typescript/src/Client.ts index c569205f09..729bdb3662 100644 --- a/sdks/runtime/typescript/src/Client.ts +++ b/sdks/runtime/typescript/src/Client.ts @@ -4,7 +4,7 @@ import * as environments from "./environments"; import * as core from "./core"; -import { Matchmaker } from "./api/resources/matchmaker/client/Client"; +import { Actor } from "./api/resources/actor/client/Client"; export declare namespace RivetClient { interface Options { @@ -26,9 +26,9 @@ export declare namespace RivetClient { export class RivetClient { constructor(protected readonly _options: RivetClient.Options) {} - protected _matchmaker: Matchmaker | undefined; + protected _actor: Actor | undefined; - public get matchmaker(): Matchmaker { - return (this._matchmaker ??= new Matchmaker(this._options)); + public get actor(): Actor { + return (this._actor ??= new Actor(this._options)); } } diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts b/sdks/runtime/typescript/src/api/resources/actor/client/Client.ts similarity index 54% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts rename to sdks/runtime/typescript/src/api/resources/actor/client/Client.ts index a58dd115a6..979ba694be 100644 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/Client.ts +++ b/sdks/runtime/typescript/src/api/resources/actor/client/Client.ts @@ -2,14 +2,17 @@ * This file was auto-generated by Fern from our API Definition. */ -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Rivet from "../../../../../index"; -import * as serializers from "../../../../../../serialization/index"; +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Rivet from "../../../index"; import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import * as serializers from "../../../../serialization/index"; +import * as errors from "../../../../errors/index"; +import { Builds } from "../resources/builds/client/Client"; +import { Logs } from "../resources/logs/client/Client"; +import { Regions } from "../resources/regions/client/Client"; -export declare namespace Players { +export declare namespace Actor { interface Options { environment?: core.Supplier; token: core.Supplier; @@ -26,48 +29,163 @@ export declare namespace Players { } } -export class Players { - constructor(protected readonly _options: Players.Options) {} +export class Actor { + constructor(protected readonly _options: Actor.Options) {} /** - * Validates the player token is valid and has not already been consumed then - * marks the player as connected. + * Gets a dynamic actor. * - * # Player Tokens and Reserved Slots + * @param {string} actor - The id of the actor to destroy + * @param {Rivet.actor.ListActorsRequestQuery} request + * @param {Actor.RequestOptions} requestOptions - Request-specific configuration. * - * Player tokens reserve a spot in the lobby until they expire. This allows for - * precise matchmaking up to exactly the lobby's player limit, which is - * important for games with small lobbies and a high influx of players. - * By calling this endpoint with the player token, the player's spot is marked - * as connected and will not expire. If this endpoint is never called, the - * player's token will expire and this spot will be filled by another player. - * - * # Anti-Botting - * - * Player tokens are only issued by caling `lobbies.join`, calling `lobbies.find`, or - * from the `GlobalEventMatchmakerLobbyJoin` event. - * These endpoints have anti-botting measures (i.e. enforcing max player - * limits, captchas, and detecting bots), so valid player tokens provide some - * confidence that the player is not a bot. - * Therefore, it's important to make sure the token is valid by waiting for - * this endpoint to return OK before allowing the connected socket to do - * anything else. If this endpoint returns an error, the socket should be - * disconnected immediately. - * - * # How to Transmit the Player Token + * @throws {@link Rivet.InternalError} + * @throws {@link Rivet.RateLimitError} + * @throws {@link Rivet.ForbiddenError} + * @throws {@link Rivet.UnauthorizedError} + * @throws {@link Rivet.NotFoundError} + * @throws {@link Rivet.BadRequestError} * - * The client is responsible for acquiring the player token by caling - * `lobbies.join`, calling `lobbies.find`, or from the `GlobalEventMatchmakerLobbyJoin` - * event. Beyond that, it's up to the developer how the player token is - * transmitted to the lobby. - * If using WebSockets, the player token can be transmitted as a query - * parameter. - * Otherwise, the player token will likely be automatically sent by the client - * once the socket opens. As mentioned above, nothing else should happen until - * the player token is validated. + * @example + * await client.actor.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string" + * }) + */ + public async get( + actor: string, + request: Rivet.actor.ListActorsRequestQuery = {}, + requestOptions?: Actor.RequestOptions + ): Promise { + const { project, environment } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, + `/actors/${encodeURIComponent(actor)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return serializers.actor.GetActorResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }); + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 500: + throw new Rivet.InternalError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 429: + throw new Rivet.RateLimitError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 403: + throw new Rivet.ForbiddenError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 408: + throw new Rivet.UnauthorizedError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 404: + throw new Rivet.NotFoundError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 400: + throw new Rivet.BadRequestError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + default: + throw new errors.RivetError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.RivetError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.RivetTimeoutError(); + case "unknown": + throw new errors.RivetError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * Lists all actors associated with the token used. Can be filtered by tags in the query string. * - * @param {Rivet.matchmaker.PlayerConnectedRequest} request - * @param {Players.RequestOptions} requestOptions - Request-specific configuration. + * @param {Rivet.actor.GetActorsRequestQuery} request + * @param {Actor.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -77,34 +195,67 @@ export class Players { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.players.connected({ - * playerToken: "string" + * await client.actor.list({ + * project: "string", + * environment: "string", + * tagsJson: "string", + * includeDestroyed: true, + * cursor: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32" * }) */ - public async connected( - request: Rivet.matchmaker.PlayerConnectedRequest, - requestOptions?: Players.RequestOptions - ): Promise { + public async list( + request: Rivet.actor.GetActorsRequestQuery = {}, + requestOptions?: Actor.RequestOptions + ): Promise { + const { project, environment, tagsJson, includeDestroyed, cursor } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + + if (tagsJson != null) { + _queryParams["tags_json"] = tagsJson; + } + + if (includeDestroyed != null) { + _queryParams["include_destroyed"] = includeDestroyed.toString(); + } + + if (cursor != null) { + _queryParams["cursor"] = cursor; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/players/connected" + "/actors" ), - method: "POST", + method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", - body: serializers.matchmaker.PlayerConnectedRequest.jsonOrThrow(request, { - unrecognizedObjectKeys: "strip", - }), timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return serializers.actor.ListActorsResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }); } if (_response.error.reason === "status-code") { @@ -193,10 +344,10 @@ export class Players { } /** - * Marks a player as disconnected. # Ghost Players If players are not marked as disconnected, lobbies will result with "ghost players" that the matchmaker thinks exist but are no longer connected to the lobby. + * Create a new dynamic actor. * - * @param {Rivet.matchmaker.PlayerDisconnectedRequest} request - * @param {Players.RequestOptions} requestOptions - Request-specific configuration. + * @param {Rivet.actor.CreateActorRequestQuery} request + * @param {Actor.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -206,34 +357,77 @@ export class Players { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.players.disconnected({ - * playerToken: "string" + * await client.actor.create({ + * project: "string", + * environment: "string", + * body: { + * region: "string", + * tags: { + * "key": "value" + * }, + * runtime: { + * build: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", + * arguments: ["string"], + * environment: { + * "string": "string" + * } + * }, + * network: { + * mode: "bridge", + * ports: {} + * }, + * resources: { + * cpu: 1, + * memory: 1 + * }, + * lifecycle: { + * killTimeout: 1000000 + * } + * } * }) */ - public async disconnected( - request: Rivet.matchmaker.PlayerDisconnectedRequest, - requestOptions?: Players.RequestOptions - ): Promise { + public async create( + request: Rivet.actor.CreateActorRequestQuery, + requestOptions?: Actor.RequestOptions + ): Promise { + const { project, environment, body: _body } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/players/disconnected" + "/actors" ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", - body: serializers.matchmaker.PlayerDisconnectedRequest.jsonOrThrow(request, { - unrecognizedObjectKeys: "strip", - }), + body: serializers.actor.CreateActorRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }), timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return serializers.actor.CreateActorResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }); } if (_response.error.reason === "status-code") { @@ -322,9 +516,11 @@ export class Players { } /** - * Gives matchmaker statistics about the players in game. + * Destroy a dynamic actor. * - * @param {Players.RequestOptions} requestOptions - Request-specific configuration. + * @param {string} actor - The id of the actor to destroy + * @param {Rivet.actor.DestroyActorRequestQuery} request + * @param {Actor.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -334,28 +530,52 @@ export class Players { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.players.getStatistics() + * await client.actor.destroy("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string", + * overrideKillTimeout: 1000000 + * }) */ - public async getStatistics( - requestOptions?: Players.RequestOptions - ): Promise { + public async destroy( + actor: string, + request: Rivet.actor.DestroyActorRequestQuery = {}, + requestOptions?: Actor.RequestOptions + ): Promise { + const { project, environment, overrideKillTimeout } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + + if (overrideKillTimeout != null) { + _queryParams["override_kill_timeout"] = overrideKillTimeout.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/players/statistics" + `/actors/${encodeURIComponent(actor)}` ), - method: "GET", + method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.GetStatisticsResponse.parseOrThrow(_response.body, { + return serializers.actor.DestroyActorResponse.parseOrThrow(_response.body, { unrecognizedObjectKeys: "passthrough", allowUnrecognizedUnionMembers: true, allowUnrecognizedEnumValues: true, @@ -449,6 +669,24 @@ export class Players { } } + protected _builds: Builds | undefined; + + public get builds(): Builds { + return (this._builds ??= new Builds(this._options)); + } + + protected _logs: Logs | undefined; + + public get logs(): Logs { + return (this._logs ??= new Logs(this._options)); + } + + protected _regions: Regions | undefined; + + public get regions(): Regions { + return (this._regions ??= new Regions(this._options)); + } + protected async _getAuthorizationHeader(): Promise { return `Bearer ${await core.Supplier.get(this._options.token)}`; } diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/index.ts b/sdks/runtime/typescript/src/api/resources/actor/client/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/client/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts new file mode 100644 index 0000000000..10fc850b7e --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/client/requests/CreateActorRequestQuery.ts @@ -0,0 +1,42 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Rivet from "../../../../index"; + +/** + * @example + * { + * project: "string", + * environment: "string", + * body: { + * region: "string", + * tags: { + * "key": "value" + * }, + * runtime: { + * build: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", + * arguments: ["string"], + * environment: { + * "string": "string" + * } + * }, + * network: { + * mode: "bridge", + * ports: {} + * }, + * resources: { + * cpu: 1, + * memory: 1 + * }, + * lifecycle: { + * killTimeout: 1000000 + * } + * } + * } + */ +export interface CreateActorRequestQuery { + project?: string; + environment?: string; + body: Rivet.actor.CreateActorRequest; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/client/requests/DestroyActorRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/client/requests/DestroyActorRequestQuery.ts new file mode 100644 index 0000000000..9c20113f85 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/client/requests/DestroyActorRequestQuery.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string", + * overrideKillTimeout: 1000000 + * } + */ +export interface DestroyActorRequestQuery { + project?: string; + environment?: string; + /** + * The duration to wait for in milliseconds before killing the actor. This should be used to override the default kill timeout if a faster time is needed, say for ignoring a graceful shutdown. + */ + overrideKillTimeout?: number; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/client/requests/GetActorsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/client/requests/GetActorsRequestQuery.ts new file mode 100644 index 0000000000..4b044b10b4 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/client/requests/GetActorsRequestQuery.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string", + * tagsJson: "string", + * includeDestroyed: true, + * cursor: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32" + * } + */ +export interface GetActorsRequestQuery { + project?: string; + environment?: string; + tagsJson?: string; + includeDestroyed?: boolean; + cursor?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/client/requests/ListActorsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/client/requests/ListActorsRequestQuery.ts new file mode 100644 index 0000000000..be0ca334b0 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/client/requests/ListActorsRequestQuery.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string" + * } + */ +export interface ListActorsRequestQuery { + project?: string; + environment?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/actor/client/requests/index.ts new file mode 100644 index 0000000000..d5f14ef88f --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/client/requests/index.ts @@ -0,0 +1,4 @@ +export { type ListActorsRequestQuery } from "./ListActorsRequestQuery"; +export { type GetActorsRequestQuery } from "./GetActorsRequestQuery"; +export { type CreateActorRequestQuery } from "./CreateActorRequestQuery"; +export { type DestroyActorRequestQuery } from "./DestroyActorRequestQuery"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/index.ts b/sdks/runtime/typescript/src/api/resources/actor/index.ts similarity index 68% rename from sdks/runtime/typescript/src/api/resources/matchmaker/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/index.ts index 4ce0f39077..a931b36375 100644 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/index.ts +++ b/sdks/runtime/typescript/src/api/resources/actor/index.ts @@ -1,2 +1,3 @@ +export * from "./types"; export * from "./resources"; export * from "./client"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/Client.ts similarity index 51% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/Client.ts index cbb0857f0b..074f4b6205 100644 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/Client.ts +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/Client.ts @@ -6,10 +6,10 @@ import * as environments from "../../../../../../environments"; import * as core from "../../../../../../core"; import * as Rivet from "../../../../../index"; import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; import * as serializers from "../../../../../../serialization/index"; +import * as errors from "../../../../../../errors/index"; -export declare namespace Lobbies { +export declare namespace Builds { interface Options { environment?: core.Supplier; token: core.Supplier; @@ -26,14 +26,15 @@ export declare namespace Lobbies { } } -export class Lobbies { - constructor(protected readonly _options: Lobbies.Options) {} +export class Builds { + constructor(protected readonly _options: Builds.Options) {} /** - * Marks the current lobby as ready to accept connections. Players will not be able to connect to this lobby until the lobby is flagged as ready. - * This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) for mock responses. When running on Rivet servers, you can access the given lobby token from the [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. + * Get a build. * - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. + * @param {string} build + * @param {Rivet.actor.GetBuildRequestQuery} request + * @param {Builds.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -43,163 +44,53 @@ export class Lobbies { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.lobbies.ready() + * await client.actor.builds.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string" + * }) */ - public async ready(requestOptions?: Lobbies.RequestOptions): Promise { - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/ready" - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return; + public async get( + build: string, + request: Rivet.actor.GetBuildRequestQuery = {}, + requestOptions?: Builds.RequestOptions + ): Promise { + const { project, environment } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 500: - throw new Rivet.InternalError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 429: - throw new Rivet.RateLimitError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 403: - throw new Rivet.ForbiddenError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 408: - throw new Rivet.UnauthorizedError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 404: - throw new Rivet.NotFoundError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 400: - throw new Rivet.BadRequestError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - default: - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.body, - }); - } + if (environment != null) { + _queryParams["environment"] = environment; } - switch (_response.error.reason) { - case "non-json": - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.RivetTimeoutError(); - case "unknown": - throw new errors.RivetError({ - message: _response.error.errorMessage, - }); - } - } - - /** - * If `is_closed` is `true`, the matchmaker will no longer route players to the lobby. Players can still - * join using the /join endpoint (this can be disabled by the developer by rejecting all new connections - * after setting the lobby to closed). - * Does not shutdown the lobby. - * - * This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for - * authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - * for mock responses. When running on Rivet servers, you can access the given lobby token from the - * [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - * - * @param {Rivet.matchmaker.SetLobbyClosedRequest} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. - * - * @throws {@link Rivet.InternalError} - * @throws {@link Rivet.RateLimitError} - * @throws {@link Rivet.ForbiddenError} - * @throws {@link Rivet.UnauthorizedError} - * @throws {@link Rivet.NotFoundError} - * @throws {@link Rivet.BadRequestError} - * - * @example - * await client.matchmaker.lobbies.setClosed({ - * isClosed: true - * }) - */ - public async setClosed( - request: Rivet.matchmaker.SetLobbyClosedRequest, - requestOptions?: Lobbies.RequestOptions - ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/closed" + `/builds/${encodeURIComponent(build)}` ), - method: "PUT", + method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", - body: serializers.matchmaker.SetLobbyClosedRequest.jsonOrThrow(request, { - unrecognizedObjectKeys: "strip", - }), timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return serializers.actor.GetBuildResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }); } if (_response.error.reason === "status-code") { @@ -288,15 +179,10 @@ export class Lobbies { } /** - * Sets the state JSON of the current lobby. + * Lists all builds of the project associated with the token used. Can be filtered by tags in the query string. * - * This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for - * authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - * for mock responses. When running on Rivet servers, you can access the given lobby token from the - * [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - * - * @param {unknown} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. + * @param {Rivet.actor.ListBuildsRequestQuery} request + * @param {Builds.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -306,160 +192,51 @@ export class Lobbies { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.lobbies.setState({ - * "key": "value" + * await client.actor.builds.list({ + * project: "string", + * environment: "string", + * tagsJson: "string" * }) */ - public async setState(request?: unknown, requestOptions?: Lobbies.RequestOptions): Promise { - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/state" - ), - method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - }, - contentType: "application/json", - requestType: "json", - body: - request != null - ? serializers.matchmaker.lobbies.setState.Request.jsonOrThrow(request, { - unrecognizedObjectKeys: "strip", - }) - : undefined, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return; + public async list( + request: Rivet.actor.ListBuildsRequestQuery = {}, + requestOptions?: Builds.RequestOptions + ): Promise { + const { project, environment, tagsJson } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 500: - throw new Rivet.InternalError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 429: - throw new Rivet.RateLimitError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 403: - throw new Rivet.ForbiddenError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 408: - throw new Rivet.UnauthorizedError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 404: - throw new Rivet.NotFoundError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 400: - throw new Rivet.BadRequestError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - default: - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.body, - }); - } + if (environment != null) { + _queryParams["environment"] = environment; } - switch (_response.error.reason) { - case "non-json": - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.RivetTimeoutError(); - case "unknown": - throw new errors.RivetError({ - message: _response.error.errorMessage, - }); + if (tagsJson != null) { + _queryParams["tags_json"] = tagsJson; } - } - /** - * Get the state of any lobby. - * - * This endpoint requires a [lobby token](/docs/general/concepts/token-types#matchmaker-lobby) for - * authentication, or a [development namespace token](/docs/general/concepts/token-types#namespace-development) - * for mock responses. When running on Rivet servers, you can access the given lobby token from the - * [`RIVET_TOKEN`](/docs/matchmaker/concepts/lobby-env) environment variable. - * - * @param {string} lobbyId - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. - * - * @throws {@link Rivet.InternalError} - * @throws {@link Rivet.RateLimitError} - * @throws {@link Rivet.ForbiddenError} - * @throws {@link Rivet.UnauthorizedError} - * @throws {@link Rivet.NotFoundError} - * @throws {@link Rivet.BadRequestError} - * - * @example - * await client.matchmaker.lobbies.getState("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32") - */ - public async getState(lobbyId: string, requestOptions?: Lobbies.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - `/matchmaker/lobbies/${encodeURIComponent(lobbyId)}/state` + "/builds" ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.lobbies.getState.Response.parseOrThrow(_response.body, { + return serializers.actor.ListBuildsResponse.parseOrThrow(_response.body, { unrecognizedObjectKeys: "passthrough", allowUnrecognizedUnionMembers: true, allowUnrecognizedEnumValues: true, @@ -554,18 +331,9 @@ export class Lobbies { } /** - * Finds a lobby based on the given criteria. - * If a lobby is not found and `prevent_auto_create_lobby` is `false`, - * a new lobby will be created. - * - * When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in - * your game namespace, this endpoint does not require a token to authenticate. Otherwise, a - * [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used - * for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - * can be used for general authentication. - * - * @param {Rivet.matchmaker.FindLobbyRequest} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. + * @param {string} build + * @param {Rivet.actor.PatchBuildTagsRequestQuery} request + * @param {Builds.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -575,204 +343,54 @@ export class Lobbies { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.lobbies.find({ - * origin: "string", - * gameModes: ["string"], - * regions: ["string"], - * preventAutoCreateLobby: true, - * tags: { - * "string": "string" - * }, - * maxPlayers: 1, - * captcha: { - * hcaptcha: { - * clientResponse: "string" + * await client.actor.builds.patchTags("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string", + * body: { + * tags: { + * "key": "value" * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" + * exclusiveTags: ["string"] * } * }) */ - public async find( - request: Rivet.matchmaker.FindLobbyRequest, - requestOptions?: Lobbies.RequestOptions - ): Promise { - const { origin, ..._body } = request; - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/find" - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - origin: origin != null ? origin : undefined, - }, - contentType: "application/json", - requestType: "json", - body: serializers.matchmaker.FindLobbyRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }), - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return serializers.matchmaker.FindLobbyResponse.parseOrThrow(_response.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }); - } - - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 500: - throw new Rivet.InternalError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 429: - throw new Rivet.RateLimitError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 403: - throw new Rivet.ForbiddenError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 408: - throw new Rivet.UnauthorizedError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 404: - throw new Rivet.NotFoundError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - case 400: - throw new Rivet.BadRequestError( - serializers.ErrorBody.parseOrThrow(_response.error.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }) - ); - default: - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.body, - }); - } + public async patchTags( + build: string, + request: Rivet.actor.PatchBuildTagsRequestQuery, + requestOptions?: Builds.RequestOptions + ): Promise { + const { project, environment, body: _body } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; } - switch (_response.error.reason) { - case "non-json": - throw new errors.RivetError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.RivetTimeoutError(); - case "unknown": - throw new errors.RivetError({ - message: _response.error.errorMessage, - }); + if (environment != null) { + _queryParams["environment"] = environment; } - } - /** - * Joins a specific lobby. - * This request will use the direct player count configured for the - * lobby group. - * - * When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in - * your game namespace, this endpoint does not require a token to authenticate. Otherwise, a - * [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used - * for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - * can be used for general authentication. - * - * @param {Rivet.matchmaker.JoinLobbyRequest} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. - * - * @throws {@link Rivet.InternalError} - * @throws {@link Rivet.RateLimitError} - * @throws {@link Rivet.ForbiddenError} - * @throws {@link Rivet.UnauthorizedError} - * @throws {@link Rivet.NotFoundError} - * @throws {@link Rivet.BadRequestError} - * - * @example - * await client.matchmaker.lobbies.join({ - * lobbyId: "string", - * captcha: { - * hcaptcha: { - * clientResponse: "string" - * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" - * } - * }) - */ - public async join( - request: Rivet.matchmaker.JoinLobbyRequest, - requestOptions?: Lobbies.RequestOptions - ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/join" + `/builds/${encodeURIComponent(build)}/tags` ), - method: "POST", + method: "PATCH", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", - body: serializers.matchmaker.JoinLobbyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }), + body: serializers.actor.PatchBuildTagsRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }), timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.JoinLobbyResponse.parseOrThrow(_response.body, { + return serializers.actor.PatchBuildTagsResponse.parseOrThrow(_response.body, { unrecognizedObjectKeys: "passthrough", allowUnrecognizedUnionMembers: true, allowUnrecognizedEnumValues: true, @@ -867,16 +485,10 @@ export class Lobbies { } /** - * Creates a custom lobby. + * Creates a new project build for the given project. * - * When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in - * your game namespace, this endpoint does not require a token to authenticate. Otherwise, a - * [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used - * for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - * can be used for general authentication. - * - * @param {Rivet.matchmaker.CreateLobbyRequest} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. + * @param {Rivet.actor.PrepareBuildRequestQuery} request + * @param {Builds.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -886,52 +498,60 @@ export class Lobbies { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.lobbies.create({ - * gameMode: "string", - * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, - * tags: { - * "string": "string" - * }, - * maxPlayers: 1, - * lobbyConfig: { - * "key": "value" - * }, - * captcha: { - * hcaptcha: { - * clientResponse: "string" + * await client.actor.builds.prepare({ + * project: "string", + * environment: "string", + * body: { + * name: "string", + * imageTag: "string", + * imageFile: { + * path: "string", + * contentType: "string", + * contentLength: 1000000 * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" + * multipartUpload: true, + * kind: "docker_image", + * compression: "none", + * prewarmRegions: ["string"] * } * }) */ - public async create( - request: Rivet.matchmaker.CreateLobbyRequest, - requestOptions?: Lobbies.RequestOptions - ): Promise { + public async prepare( + request: Rivet.actor.PrepareBuildRequestQuery, + requestOptions?: Builds.RequestOptions + ): Promise { + const { project, environment, body: _body } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/create" + "/builds/prepare" ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", - body: serializers.matchmaker.CreateLobbyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }), + body: serializers.actor.PrepareBuildRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }), timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.CreateLobbyResponse.parseOrThrow(_response.body, { + return serializers.actor.PrepareBuildResponse.parseOrThrow(_response.body, { unrecognizedObjectKeys: "passthrough", allowUnrecognizedUnionMembers: true, allowUnrecognizedEnumValues: true, @@ -1026,16 +646,11 @@ export class Lobbies { } /** - * Lists all open lobbies. - * - * When [tokenless authentication](/docs/general/concepts/tokenless-authentication/web) is enabled in - * your game namespace, this endpoint does not require a token to authenticate. Otherwise, a - * [development namespace token](/docs/general/concepts/token-types#namespace-development) can be used - * for mock responses and a [public namespace token](/docs/general/concepts/token-types#namespace-public) - * can be used for general authentication. + * Marks an upload as complete. * - * @param {Rivet.matchmaker.ListLobbiesRequest} request - * @param {Lobbies.RequestOptions} requestOptions - Request-specific configuration. + * @param {string} build + * @param {Rivet.actor.CompleteBuildRequestQuery} request + * @param {Builds.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} * @throws {@link Rivet.RateLimitError} @@ -1045,28 +660,37 @@ export class Lobbies { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.lobbies.list({ - * includeState: true + * await client.actor.builds.complete("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string" * }) */ - public async list( - request: Rivet.matchmaker.ListLobbiesRequest = {}, - requestOptions?: Lobbies.RequestOptions - ): Promise { - const { includeState } = request; + public async complete( + build: string, + request: Rivet.actor.CompleteBuildRequestQuery = {}, + requestOptions?: Builds.RequestOptions + ): Promise { + const { project, environment } = request; const _queryParams: Record = {}; - if (includeState != null) { - _queryParams["include_state"] = includeState.toString(); + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/lobbies/list" + `/builds/${encodeURIComponent(build)}/complete` ), - method: "GET", + method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", queryParameters: _queryParams, @@ -1076,13 +700,7 @@ export class Lobbies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.ListLobbiesResponse.parseOrThrow(_response.body, { - unrecognizedObjectKeys: "passthrough", - allowUnrecognizedUnionMembers: true, - allowUnrecognizedEnumValues: true, - skipValidation: true, - breadcrumbsPrefix: ["response"], - }); + return; } if (_response.error.reason === "status-code") { diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/CompleteBuildRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/CompleteBuildRequestQuery.ts new file mode 100644 index 0000000000..f528a3e173 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/CompleteBuildRequestQuery.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string" + * } + */ +export interface CompleteBuildRequestQuery { + project?: string; + environment?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/GetBuildRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/GetBuildRequestQuery.ts new file mode 100644 index 0000000000..191b55ec6b --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/GetBuildRequestQuery.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string" + * } + */ +export interface GetBuildRequestQuery { + project?: string; + environment?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/ListBuildsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/ListBuildsRequestQuery.ts new file mode 100644 index 0000000000..4da1260ff5 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/ListBuildsRequestQuery.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string", + * tagsJson: "string" + * } + */ +export interface ListBuildsRequestQuery { + project?: string; + environment?: string; + tagsJson?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PatchBuildTagsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PatchBuildTagsRequestQuery.ts new file mode 100644 index 0000000000..ddcc97fd15 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PatchBuildTagsRequestQuery.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Rivet from "../../../../../../index"; + +/** + * @example + * { + * project: "string", + * environment: "string", + * body: { + * tags: { + * "key": "value" + * }, + * exclusiveTags: ["string"] + * } + * } + */ +export interface PatchBuildTagsRequestQuery { + project?: string; + environment?: string; + body: Rivet.actor.PatchBuildTagsRequest; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts new file mode 100644 index 0000000000..0be804ec84 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/PrepareBuildRequestQuery.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Rivet from "../../../../../../index"; + +/** + * @example + * { + * project: "string", + * environment: "string", + * body: { + * name: "string", + * imageTag: "string", + * imageFile: { + * path: "string", + * contentType: "string", + * contentLength: 1000000 + * }, + * multipartUpload: true, + * kind: "docker_image", + * compression: "none", + * prewarmRegions: ["string"] + * } + * } + */ +export interface PrepareBuildRequestQuery { + project?: string; + environment?: string; + body: Rivet.actor.PrepareBuildRequest; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/index.ts new file mode 100644 index 0000000000..adf29ccbe9 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type GetBuildRequestQuery } from "./GetBuildRequestQuery"; +export { type ListBuildsRequestQuery } from "./ListBuildsRequestQuery"; +export { type PatchBuildTagsRequestQuery } from "./PatchBuildTagsRequestQuery"; +export { type PrepareBuildRequestQuery } from "./PrepareBuildRequestQuery"; +export { type CompleteBuildRequestQuery } from "./CompleteBuildRequestQuery"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/builds/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/builds/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/common/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/captcha/resources/config/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/common/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/index.ts new file mode 100644 index 0000000000..b36ad988e5 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/index.ts @@ -0,0 +1,11 @@ +export * as builds from "./builds"; +export * from "./builds/types"; +export * as common from "./common"; +export * from "./common/types"; +export * as logs from "./logs"; +export * from "./logs/types"; +export * as regions from "./regions"; +export * from "./regions/types"; +export * from "./builds/client/requests"; +export * from "./logs/client/requests"; +export * from "./regions/client/requests"; diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/Client.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/Client.ts new file mode 100644 index 0000000000..ea418175ba --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/Client.ts @@ -0,0 +1,191 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Rivet from "../../../../../index"; +import urlJoin from "url-join"; +import * as serializers from "../../../../../../serialization/index"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Logs { + interface Options { + environment?: core.Supplier; + token: core.Supplier; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + } +} + +export class Logs { + constructor(protected readonly _options: Logs.Options) {} + + /** + * Returns the logs for a given actor. + * + * @param {string} actor + * @param {Rivet.actor.GetActorLogsRequestQuery} request + * @param {Logs.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Rivet.InternalError} + * @throws {@link Rivet.RateLimitError} + * @throws {@link Rivet.ForbiddenError} + * @throws {@link Rivet.UnauthorizedError} + * @throws {@link Rivet.NotFoundError} + * @throws {@link Rivet.BadRequestError} + * + * @example + * await client.actor.logs.get("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", { + * project: "string", + * environment: "string", + * stream: "std_out", + * watchIndex: "string" + * }) + */ + public async get( + actor: string, + request: Rivet.actor.GetActorLogsRequestQuery, + requestOptions?: Logs.RequestOptions + ): Promise { + const { project, environment, stream, watchIndex } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + + _queryParams["stream"] = stream; + if (watchIndex != null) { + _queryParams["watch_index"] = watchIndex; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, + `/actors/${encodeURIComponent(actor)}/logs` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return serializers.actor.GetActorLogsResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }); + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 500: + throw new Rivet.InternalError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 429: + throw new Rivet.RateLimitError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 403: + throw new Rivet.ForbiddenError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 408: + throw new Rivet.UnauthorizedError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 404: + throw new Rivet.NotFoundError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + case 400: + throw new Rivet.BadRequestError( + serializers.ErrorBody.parseOrThrow(_response.error.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }) + ); + default: + throw new errors.RivetError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.RivetError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.RivetTimeoutError(); + case "unknown": + throw new errors.RivetError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + return `Bearer ${await core.Supplier.get(this._options.token)}`; + } +} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts new file mode 100644 index 0000000000..eb1587c3e1 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/GetActorLogsRequestQuery.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Rivet from "../../../../../../index"; + +/** + * @example + * { + * project: "string", + * environment: "string", + * stream: "std_out", + * watchIndex: "string" + * } + */ +export interface GetActorLogsRequestQuery { + project?: string; + environment?: string; + stream: Rivet.actor.LogStream; + /** + * A query parameter denoting the requests watch index. + */ + watchIndex?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/index.ts new file mode 100644 index 0000000000..599c89b601 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/client/requests/index.ts @@ -0,0 +1 @@ +export { type GetActorLogsRequestQuery } from "./GetActorLogsRequestQuery"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/logs/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/logs/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/Client.ts similarity index 86% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/Client.ts index 03f846c1f4..6ca7610eab 100644 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/Client.ts +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/Client.ts @@ -30,10 +30,7 @@ export class Regions { constructor(protected readonly _options: Regions.Options) {} /** - * Returns a list of regions available to this namespace. - * Regions are sorted by most optimal to least optimal. The player's IP address - * is used to calculate the regions' optimality. - * + * @param {Rivet.actor.ListRegionsRequestQuery} request * @param {Regions.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Rivet.InternalError} @@ -44,26 +41,46 @@ export class Regions { * @throws {@link Rivet.BadRequestError} * * @example - * await client.matchmaker.regions.list() + * await client.actor.regions.list({ + * project: "string", + * environment: "string" + * }) */ - public async list(requestOptions?: Regions.RequestOptions): Promise { + public async list( + request: Rivet.actor.ListRegionsRequestQuery = {}, + requestOptions?: Regions.RequestOptions + ): Promise { + const { project, environment } = request; + const _queryParams: Record = {}; + if (project != null) { + _queryParams["project"] = project; + } + + if (environment != null) { + _queryParams["environment"] = environment; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.environment)) ?? environments.RivetEnvironment.Production, - "/matchmaker/regions" + "/regions" ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, }, contentType: "application/json", + queryParameters: _queryParams, requestType: "json", timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 180000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return serializers.matchmaker.ListRegionsResponse.parseOrThrow(_response.body, { + return serializers.actor.ListRegionsResponse.parseOrThrow(_response.body, { unrecognizedObjectKeys: "passthrough", allowUnrecognizedUnionMembers: true, allowUnrecognizedEnumValues: true, diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/index.ts new file mode 100644 index 0000000000..415726b7fe --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/ListRegionsRequestQuery.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/ListRegionsRequestQuery.ts new file mode 100644 index 0000000000..5a6fd625e9 --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/ListRegionsRequestQuery.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * project: "string", + * environment: "string" + * } + */ +export interface ListRegionsRequestQuery { + project?: string; + environment?: string; +} diff --git a/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/index.ts new file mode 100644 index 0000000000..1033881feb --- /dev/null +++ b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/client/requests/index.ts @@ -0,0 +1 @@ +export { type ListRegionsRequestQuery } from "./ListRegionsRequestQuery"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/index.ts b/sdks/runtime/typescript/src/api/resources/actor/resources/regions/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/index.ts rename to sdks/runtime/typescript/src/api/resources/actor/resources/regions/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/Config.ts b/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/Config.ts deleted file mode 100644 index a51a51aee9..0000000000 --- a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/Config.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * Methods to verify a captcha - */ -export interface Config { - hcaptcha?: Rivet.captcha.ConfigHcaptcha; - turnstile?: Rivet.captcha.ConfigTurnstile; -} diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigHcaptcha.ts b/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigHcaptcha.ts deleted file mode 100644 index d0b57ca2f2..0000000000 --- a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigHcaptcha.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Captcha configuration. - */ -export interface ConfigHcaptcha { - clientResponse: string; -} diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigTurnstile.ts b/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigTurnstile.ts deleted file mode 100644 index 2a55d75c5d..0000000000 --- a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/ConfigTurnstile.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Captcha configuration. - */ -export interface ConfigTurnstile { - clientResponse: string; -} diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/index.ts b/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/index.ts deleted file mode 100644 index e3d7f9330e..0000000000 --- a/sdks/runtime/typescript/src/api/resources/captcha/resources/config/types/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from "./Config"; -export * from "./ConfigHcaptcha"; -export * from "./ConfigTurnstile"; diff --git a/sdks/runtime/typescript/src/api/resources/captcha/resources/index.ts b/sdks/runtime/typescript/src/api/resources/captcha/resources/index.ts deleted file mode 100644 index 020463c11c..0000000000 --- a/sdks/runtime/typescript/src/api/resources/captcha/resources/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * as config from "./config"; -export * from "./config/types"; diff --git a/sdks/runtime/typescript/src/api/resources/common/types/DisplayName.ts b/sdks/runtime/typescript/src/api/resources/common/types/DisplayName.ts deleted file mode 100644 index 1baa23f256..0000000000 --- a/sdks/runtime/typescript/src/api/resources/common/types/DisplayName.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Represent a resource's readable display name. - */ -export type DisplayName = string; diff --git a/sdks/runtime/typescript/src/api/resources/common/types/Identifier.ts b/sdks/runtime/typescript/src/api/resources/common/types/Identifier.ts deleted file mode 100644 index 616b2523d0..0000000000 --- a/sdks/runtime/typescript/src/api/resources/common/types/Identifier.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A human readable short identifier used to references resources. Different than a `uuid` because this is intended to be human readable. Different than `DisplayName` because this should not include special characters and be short. - */ -export type Identifier = string; diff --git a/sdks/runtime/typescript/src/api/resources/common/types/Jwt.ts b/sdks/runtime/typescript/src/api/resources/common/types/Jwt.ts deleted file mode 100644 index f2ef4c535d..0000000000 --- a/sdks/runtime/typescript/src/api/resources/common/types/Jwt.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Documentation at https://jwt.io/ - */ -export type Jwt = string; diff --git a/sdks/runtime/typescript/src/api/resources/common/types/index.ts b/sdks/runtime/typescript/src/api/resources/common/types/index.ts index f7e3891adb..eb53c3b2d6 100644 --- a/sdks/runtime/typescript/src/api/resources/common/types/index.ts +++ b/sdks/runtime/typescript/src/api/resources/common/types/index.ts @@ -1,5 +1,4 @@ -export * from "./Identifier"; -export * from "./Jwt"; -export * from "./DisplayName"; +export * from "./WatchResponse"; +export * from "./Timestamp"; export * from "./ErrorMetadata"; export * from "./ErrorBody"; diff --git a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Coord.ts b/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Coord.ts deleted file mode 100644 index 30efaf6eb9..0000000000 --- a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Coord.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Geographical coordinates for a location on Planet Earth. - */ -export interface Coord { - latitude: number; - longitude: number; -} diff --git a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Distance.ts b/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Distance.ts deleted file mode 100644 index 2775c9cc42..0000000000 --- a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/Distance.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Distance available in multiple units. - */ -export interface Distance { - kilometers: number; - miles: number; -} diff --git a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/index.ts b/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/index.ts deleted file mode 100644 index 9bedc827df..0000000000 --- a/sdks/runtime/typescript/src/api/resources/geo/resources/common/types/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from "./Coord"; -export * from "./Distance"; diff --git a/sdks/runtime/typescript/src/api/resources/index.ts b/sdks/runtime/typescript/src/api/resources/index.ts index 6222bce3e8..b1134b49e8 100644 --- a/sdks/runtime/typescript/src/api/resources/index.ts +++ b/sdks/runtime/typescript/src/api/resources/index.ts @@ -1,6 +1,5 @@ -export * as captcha from "./captcha"; +export * as actor from "./actor"; export * as common from "./common"; export * from "./common/types"; -export * as geo from "./geo"; -export * as matchmaker from "./matchmaker"; +export * as upload from "./upload"; export * from "./common/errors"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/client/Client.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/client/Client.ts deleted file mode 100644 index 734f320327..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/client/Client.ts +++ /dev/null @@ -1,48 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import { Lobbies } from "../resources/lobbies/client/Client"; -import { Players } from "../resources/players/client/Client"; -import { Regions } from "../resources/regions/client/Client"; - -export declare namespace Matchmaker { - interface Options { - environment?: core.Supplier; - token: core.Supplier; - fetcher?: core.FetchFunction; - } - - interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - } -} - -export class Matchmaker { - constructor(protected readonly _options: Matchmaker.Options) {} - - protected _lobbies: Lobbies | undefined; - - public get lobbies(): Lobbies { - return (this._lobbies ??= new Lobbies(this._options)); - } - - protected _players: Players | undefined; - - public get players(): Players { - return (this._players ??= new Players(this._options)); - } - - protected _regions: Regions | undefined; - - public get regions(): Regions { - return (this._regions ??= new Regions(this._options)); - } -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/client/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/client/index.ts deleted file mode 100644 index cb0ff5c3b5..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/client/index.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts deleted file mode 100644 index bc4b6f7af0..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -export type CustomLobbyPublicity = "public" | "private"; - -export const CustomLobbyPublicity = { - Public: "public", - Private: "private", -} as const; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/GameModeInfo.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/GameModeInfo.ts deleted file mode 100644 index 6995a490ec..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/GameModeInfo.ts +++ /dev/null @@ -1,12 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * A game mode that the player can join. - */ -export interface GameModeInfo { - gameModeId: Rivet.Identifier; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinLobby.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinLobby.ts deleted file mode 100644 index bf253efda7..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinLobby.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * A matchmaker lobby. - */ -export interface JoinLobby { - lobbyId: string; - region: Rivet.matchmaker.JoinRegion; - /** **Deprecated** */ - ports: Record; - /** **Deprecated** */ - player: Rivet.matchmaker.JoinPlayer; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPlayer.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPlayer.ts deleted file mode 100644 index f640d289ae..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPlayer.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * A matchmaker lobby player. - */ -export interface JoinPlayer { - /** Pass this token through the socket to the lobby server. The lobby server will validate this token with `PlayerConnected.player_token` */ - token: Rivet.Jwt; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPort.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPort.ts deleted file mode 100644 index 17a8dbdb4b..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPort.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface JoinPort { - /** The host for the given port. Will be null if using a port range. */ - host?: string; - hostname: string; - /** The port number for this lobby. Will be null if using a port range. */ - port?: number; - portRange?: Rivet.matchmaker.JoinPortRange; - /** Whether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports. */ - isTls: boolean; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPortRange.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPortRange.ts deleted file mode 100644 index ecb7e81ba2..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinPortRange.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Inclusive range of ports that can be connected to. - */ -export interface JoinPortRange { - /** Minimum port that can be connected to. Inclusive range. */ - min: number; - /** Maximum port that can be connected to. Inclusive range. */ - max: number; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinRegion.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinRegion.ts deleted file mode 100644 index b4070ecfa4..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/JoinRegion.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * A matchmaker lobby region. - */ -export interface JoinRegion { - regionId: Rivet.Identifier; - displayName: Rivet.DisplayName; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/LobbyInfo.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/LobbyInfo.ts deleted file mode 100644 index 31018c92d8..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/LobbyInfo.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A public lobby in the lobby list. - */ -export interface LobbyInfo { - regionId: string; - gameModeId: string; - lobbyId: string; - maxPlayersNormal: number; - maxPlayersDirect: number; - maxPlayersParty: number; - totalPlayerCount: number; - state?: unknown; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/RegionInfo.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/RegionInfo.ts deleted file mode 100644 index 8ed9a3cb6e..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/RegionInfo.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -/** - * A region that the player can connect to. - */ -export interface RegionInfo { - regionId: Rivet.Identifier; - providerDisplayName: Rivet.DisplayName; - regionDisplayName: Rivet.DisplayName; - datacenterCoord: Rivet.geo.Coord; - datacenterDistanceFromClient: Rivet.geo.Distance; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/index.ts deleted file mode 100644 index 5519ce0ef7..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/types/index.ts +++ /dev/null @@ -1,9 +0,0 @@ -export * from "./LobbyInfo"; -export * from "./GameModeInfo"; -export * from "./RegionInfo"; -export * from "./JoinLobby"; -export * from "./JoinRegion"; -export * from "./JoinPort"; -export * from "./JoinPortRange"; -export * from "./JoinPlayer"; -export * from "./CustomLobbyPublicity"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/index.ts deleted file mode 100644 index 263cd6ef8a..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -export * as common from "./common"; -export * from "./common/types"; -export * as lobbies from "./lobbies"; -export * from "./lobbies/types"; -export * as players from "./players"; -export * from "./players/types"; -export * as regions from "./regions"; -export * from "./regions/types"; -export * from "./lobbies/client/requests"; -export * from "./players/client/requests"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts deleted file mode 100644 index ac532c8c03..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts +++ /dev/null @@ -1,42 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../../index"; - -/** - * @example - * { - * gameMode: "string", - * region: "string", - * publicity: Rivet.matchmaker.CustomLobbyPublicity.Public, - * tags: { - * "string": "string" - * }, - * maxPlayers: 1, - * lobbyConfig: { - * "key": "value" - * }, - * captcha: { - * hcaptcha: { - * clientResponse: "string" - * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" - * } - * } - */ -export interface CreateLobbyRequest { - gameMode: string; - region?: string; - publicity?: Rivet.matchmaker.CustomLobbyPublicity; - tags?: Record; - maxPlayers?: number; - lobbyConfig?: unknown; - captcha?: Rivet.captcha.Config; - verificationData?: unknown; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts deleted file mode 100644 index 729be8a158..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../../index"; - -/** - * @example - * { - * origin: "string", - * gameModes: ["string"], - * regions: ["string"], - * preventAutoCreateLobby: true, - * tags: { - * "string": "string" - * }, - * maxPlayers: 1, - * captcha: { - * hcaptcha: { - * clientResponse: "string" - * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" - * } - * } - */ -export interface FindLobbyRequest { - origin?: string; - gameModes: string[]; - regions?: string[]; - preventAutoCreateLobby?: boolean; - tags?: Record; - maxPlayers?: number; - captcha?: Rivet.captcha.Config; - verificationData?: unknown; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts deleted file mode 100644 index a6efde4869..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../../index"; - -/** - * @example - * { - * lobbyId: "string", - * captcha: { - * hcaptcha: { - * clientResponse: "string" - * }, - * turnstile: { - * clientResponse: "string" - * } - * }, - * verificationData: { - * "key": "value" - * } - * } - */ -export interface JoinLobbyRequest { - lobbyId: string; - captcha?: Rivet.captcha.Config; - verificationData?: unknown; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/ListLobbiesRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/ListLobbiesRequest.ts deleted file mode 100644 index 31c4be4ab6..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/ListLobbiesRequest.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * includeState: true - * } - */ -export interface ListLobbiesRequest { - includeState?: boolean; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts deleted file mode 100644 index c8c03f252d..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * isClosed: true - * } - */ -export interface SetLobbyClosedRequest { - isClosed: boolean; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/index.ts deleted file mode 100644 index 0e3df8e08a..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/client/requests/index.ts +++ /dev/null @@ -1,5 +0,0 @@ -export { type SetLobbyClosedRequest } from "./SetLobbyClosedRequest"; -export { type FindLobbyRequest } from "./FindLobbyRequest"; -export { type JoinLobbyRequest } from "./JoinLobbyRequest"; -export { type CreateLobbyRequest } from "./CreateLobbyRequest"; -export { type ListLobbiesRequest } from "./ListLobbiesRequest"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts deleted file mode 100644 index 9ec13da24f..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface CreateLobbyResponse { - lobby: Rivet.matchmaker.JoinLobby; - ports: Record; - player: Rivet.matchmaker.JoinPlayer; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts deleted file mode 100644 index e32b79cae3..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface FindLobbyResponse { - lobby: Rivet.matchmaker.JoinLobby; - ports: Record; - player: Rivet.matchmaker.JoinPlayer; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts deleted file mode 100644 index 06ec55d55b..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface JoinLobbyResponse { - lobby: Rivet.matchmaker.JoinLobby; - ports: Record; - player: Rivet.matchmaker.JoinPlayer; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts deleted file mode 100644 index fa234058bc..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface ListLobbiesResponse { - gameModes: Rivet.matchmaker.GameModeInfo[]; - regions: Rivet.matchmaker.RegionInfo[]; - lobbies: Rivet.matchmaker.LobbyInfo[]; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/index.ts deleted file mode 100644 index 13491dd556..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/lobbies/types/index.ts +++ /dev/null @@ -1,4 +0,0 @@ -export * from "./FindLobbyResponse"; -export * from "./JoinLobbyResponse"; -export * from "./CreateLobbyResponse"; -export * from "./ListLobbiesResponse"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts deleted file mode 100644 index 12170bcfef..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * playerToken: "string" - * } - */ -export interface PlayerConnectedRequest { - playerToken: string; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts deleted file mode 100644 index 354f0a83a4..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * playerToken: "string" - * } - */ -export interface PlayerDisconnectedRequest { - playerToken: string; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/index.ts deleted file mode 100644 index 8dbaaea743..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/client/requests/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { type PlayerConnectedRequest } from "./PlayerConnectedRequest"; -export { type PlayerDisconnectedRequest } from "./PlayerDisconnectedRequest"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GameModeStatistics.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GameModeStatistics.ts deleted file mode 100644 index 42c7eef739..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GameModeStatistics.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface GameModeStatistics { - playerCount: number; - regions: Record; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts deleted file mode 100644 index c14c2208fe..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface GetStatisticsResponse { - playerCount: number; - gameModes: Record; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/RegionStatistics.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/RegionStatistics.ts deleted file mode 100644 index bf547e60c4..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/RegionStatistics.ts +++ /dev/null @@ -1,7 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -export interface RegionStatistics { - playerCount: number; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/index.ts deleted file mode 100644 index e6a2666580..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/players/types/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from "./GetStatisticsResponse"; -export * from "./GameModeStatistics"; -export * from "./RegionStatistics"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/index.ts deleted file mode 100644 index cb0ff5c3b5..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/client/index.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts deleted file mode 100644 index f31f4c32f5..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts +++ /dev/null @@ -1,9 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Rivet from "../../../../../index"; - -export interface ListRegionsResponse { - regions: Rivet.matchmaker.RegionInfo[]; -} diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/index.ts b/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/index.ts deleted file mode 100644 index dd60cc81be..0000000000 --- a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/regions/types/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./ListRegionsResponse"; diff --git a/sdks/runtime/typescript/src/api/resources/captcha/index.ts b/sdks/runtime/typescript/src/api/resources/upload/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/captcha/index.ts rename to sdks/runtime/typescript/src/api/resources/upload/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/geo/resources/common/index.ts b/sdks/runtime/typescript/src/api/resources/upload/resources/common/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/geo/resources/common/index.ts rename to sdks/runtime/typescript/src/api/resources/upload/resources/common/index.ts diff --git a/sdks/runtime/typescript/src/api/resources/geo/resources/index.ts b/sdks/runtime/typescript/src/api/resources/upload/resources/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/geo/resources/index.ts rename to sdks/runtime/typescript/src/api/resources/upload/resources/index.ts diff --git a/sdks/runtime/typescript/src/core/fetcher/Fetcher.ts b/sdks/runtime/typescript/src/core/fetcher/Fetcher.ts index d67bc04210..b8f23717b6 100644 --- a/sdks/runtime/typescript/src/core/fetcher/Fetcher.ts +++ b/sdks/runtime/typescript/src/core/fetcher/Fetcher.ts @@ -21,7 +21,7 @@ export declare namespace Fetcher { withCredentials?: boolean; abortSignal?: AbortSignal; requestType?: "json" | "file" | "bytes"; - responseType?: "json" | "blob" | "sse" | "streaming" | "text"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; duplex?: "half"; } diff --git a/sdks/runtime/typescript/src/core/fetcher/getResponseBody.ts b/sdks/runtime/typescript/src/core/fetcher/getResponseBody.ts index a7a9c50877..d046e6ea27 100644 --- a/sdks/runtime/typescript/src/core/fetcher/getResponseBody.ts +++ b/sdks/runtime/typescript/src/core/fetcher/getResponseBody.ts @@ -3,6 +3,8 @@ import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; export async function getResponseBody(response: Response, responseType?: string): Promise { if (response.body != null && responseType === "blob") { return await response.blob(); + } else if (response.body != null && responseType === "arrayBuffer") { + return await response.arrayBuffer(); } else if (response.body != null && responseType === "sse") { return response.body; } else if (response.body != null && responseType === "streaming") { diff --git a/sdks/runtime/typescript/src/core/fetcher/requestWithRetries.ts b/sdks/runtime/typescript/src/core/fetcher/requestWithRetries.ts index ff5dc3bbab..8d5af9d5a8 100644 --- a/sdks/runtime/typescript/src/core/fetcher/requestWithRetries.ts +++ b/sdks/runtime/typescript/src/core/fetcher/requestWithRetries.ts @@ -1,6 +1,13 @@ -const INITIAL_RETRY_DELAY = 1; -const MAX_RETRY_DELAY = 60; +const INITIAL_RETRY_DELAY = 1000; // in milliseconds +const MAX_RETRY_DELAY = 60000; // in milliseconds const DEFAULT_MAX_RETRIES = 2; +const JITTER_FACTOR = 0.2; // 20% random jitter + +function addJitter(delay: number): number { + // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR + const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; + return delay * jitterMultiplier; +} export async function requestWithRetries( requestFn: () => Promise, @@ -10,8 +17,13 @@ export async function requestWithRetries( for (let i = 0; i < maxRetries; ++i) { if ([408, 409, 429].includes(response.status) || response.status >= 500) { - const delay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); - await new Promise((resolve) => setTimeout(resolve, delay)); + // Calculate base delay using exponential backoff (in milliseconds) + const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); + + // Add jitter to the delay + const delayWithJitter = addJitter(baseDelay); + + await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); response = await requestFn(); } else { break; diff --git a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts index 5cc74b6b1b..4d7b7d52e8 100644 --- a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts +++ b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -1,17 +1,18 @@ -import type { Writable } from "stream"; +import type { Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; -export class Node18UniversalStreamWrapper - implements StreamWrapper, Uint8Array> +export class Node18UniversalStreamWrapper + implements + StreamWrapper | Writable | WritableStream, ReadFormat> { - private readableStream: ReadableStream; - private reader: ReadableStreamDefaultReader; + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; private events: Record; private paused: boolean; private resumeCallback: ((value?: unknown) => void) | null; private encoding: string | null; - constructor(readableStream: ReadableStream) { + constructor(readableStream: ReadableStream) { this.readableStream = readableStream; this.reader = this.readableStream.getReader(); this.events = { @@ -37,8 +38,8 @@ export class Node18UniversalStreamWrapper } public pipe( - dest: Node18UniversalStreamWrapper | Writable | WritableStream - ): Node18UniversalStreamWrapper | Writable | WritableStream { + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { this.on("data", async (chunk) => { if (dest instanceof Node18UniversalStreamWrapper) { dest._write(chunk); @@ -78,12 +79,12 @@ export class Node18UniversalStreamWrapper } public pipeTo( - dest: Node18UniversalStreamWrapper | Writable | WritableStream - ): Node18UniversalStreamWrapper | Writable | WritableStream { + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { return this.pipe(dest); } - public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { + public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { this.off("data", async (chunk) => { if (dest instanceof Node18UniversalStreamWrapper) { dest._write(chunk); @@ -149,7 +150,7 @@ export class Node18UniversalStreamWrapper return this.paused; } - public async read(): Promise { + public async read(): Promise { if (this.paused) { await new Promise((resolve) => { this.resumeCallback = resolve; @@ -168,12 +169,16 @@ export class Node18UniversalStreamWrapper } public async text(): Promise { - const chunks: Uint8Array[] = []; + const chunks: ReadFormat[] = []; while (true) { const { done, value } = await this.reader.read(); - if (done) break; - if (value) chunks.push(value); + if (done) { + break; + } + if (value) { + chunks.push(value); + } } const decoder = new TextDecoder(this.encoding || "utf-8"); @@ -185,7 +190,7 @@ export class Node18UniversalStreamWrapper return JSON.parse(text); } - private _write(chunk: Uint8Array): void { + private _write(chunk: ReadFormat): void { this._emit("data", chunk); } @@ -228,4 +233,24 @@ export class Node18UniversalStreamWrapper this._emit("error", error); } } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts index d73daba8ce..ba5f727675 100644 --- a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts +++ b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -1,4 +1,4 @@ -import type { Readable, Writable } from "stream"; +import type { Readable, Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export class NodePre18StreamWrapper implements StreamWrapper { @@ -87,4 +87,20 @@ export class NodePre18StreamWrapper implements StreamWrapper { const text = await this.text(); return JSON.parse(text); } + + public [Symbol.asyncIterator](): AsyncIterableIterator { + const readableStream = this.readableStream; + const iterator = readableStream[Symbol.asyncIterator](); + + // Create and return an async iterator that yields buffers + return { + async next(): Promise> { + const { value, done } = await iterator.next(); + return { value: value as Buffer, done }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts index 55c048732c..263af00911 100644 --- a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts +++ b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -78,7 +78,7 @@ export class UndiciStreamWrapper | WritableStream): void { + public unpipe(dest: UndiciStreamWrapper | WritableStream): void { this.off("data", (chunk) => { if (dest instanceof UndiciStreamWrapper) { dest._write(chunk); @@ -160,8 +160,12 @@ export class UndiciStreamWrapper { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } } diff --git a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts index 3295582d02..2abd6b2ba1 100644 --- a/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts +++ b/sdks/runtime/typescript/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -1,4 +1,4 @@ -import type { Readable } from "stream"; +import type { Readable } from "readable-stream"; import { RUNTIME } from "../../runtime"; export type EventCallback = (data?: any) => void; @@ -17,6 +17,7 @@ export interface StreamWrapper { read(): Promise; text(): Promise; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } export async function chooseStreamWrapper(responseBody: any): Promise>> { @@ -24,7 +25,7 @@ export async function chooseStreamWrapper(responseBody: any): Promise { } export const SchemaType = { + BIGINT: "bigint", DATE: "date", ENUM: "enum", LIST: "list", diff --git a/sdks/runtime/typescript/src/core/schemas/builders/bigint/bigint.ts b/sdks/runtime/typescript/src/core/schemas/builders/bigint/bigint.ts new file mode 100644 index 0000000000..dc9c742e00 --- /dev/null +++ b/sdks/runtime/typescript/src/core/schemas/builders/bigint/bigint.ts @@ -0,0 +1,50 @@ +import { BaseSchema, Schema, SchemaType } from "../../Schema"; +import { getErrorMessageForIncorrectType } from "../../utils/getErrorMessageForIncorrectType"; +import { maybeSkipValidation } from "../../utils/maybeSkipValidation"; +import { getSchemaUtils } from "../schema-utils"; + +export function bigint(): Schema { + const baseSchema: BaseSchema = { + parse: (raw, { breadcrumbsPrefix = [] } = {}) => { + if (typeof raw !== "string") { + return { + ok: false, + errors: [ + { + path: breadcrumbsPrefix, + message: getErrorMessageForIncorrectType(raw, "string"), + }, + ], + }; + } + return { + ok: true, + value: BigInt(raw), + }; + }, + json: (bigint, { breadcrumbsPrefix = [] } = {}) => { + if (typeof bigint === "bigint") { + return { + ok: true, + value: bigint.toString(), + }; + } else { + return { + ok: false, + errors: [ + { + path: breadcrumbsPrefix, + message: getErrorMessageForIncorrectType(bigint, "bigint"), + }, + ], + }; + } + }, + getType: () => SchemaType.BIGINT, + }; + + return { + ...maybeSkipValidation(baseSchema), + ...getSchemaUtils(baseSchema), + }; +} diff --git a/sdks/runtime/typescript/src/core/schemas/builders/bigint/index.ts b/sdks/runtime/typescript/src/core/schemas/builders/bigint/index.ts new file mode 100644 index 0000000000..e5843043fc --- /dev/null +++ b/sdks/runtime/typescript/src/core/schemas/builders/bigint/index.ts @@ -0,0 +1 @@ +export { bigint } from "./bigint"; diff --git a/sdks/runtime/typescript/src/core/schemas/builders/index.ts b/sdks/runtime/typescript/src/core/schemas/builders/index.ts index 050cd2c4ef..65211f9252 100644 --- a/sdks/runtime/typescript/src/core/schemas/builders/index.ts +++ b/sdks/runtime/typescript/src/core/schemas/builders/index.ts @@ -1,3 +1,4 @@ +export * from "./bigint"; export * from "./date"; export * from "./enum"; export * from "./lazy"; diff --git a/sdks/runtime/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts b/sdks/runtime/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts index 438012df41..1a5c31027c 100644 --- a/sdks/runtime/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts +++ b/sdks/runtime/typescript/src/core/schemas/utils/getErrorMessageForIncorrectType.ts @@ -9,9 +9,13 @@ function getTypeAsString(value: unknown): string { if (value === null) { return "null"; } + if (value instanceof BigInt) { + return "BigInt"; + } switch (typeof value) { case "string": return `"${value}"`; + case "bigint": case "number": case "boolean": case "undefined": diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/index.ts similarity index 53% rename from sdks/runtime/typescript/src/serialization/resources/captcha/index.ts rename to sdks/runtime/typescript/src/serialization/resources/actor/index.ts index 3e5335fe42..3ce0a3e38e 100644 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/index.ts +++ b/sdks/runtime/typescript/src/serialization/resources/actor/index.ts @@ -1 +1,2 @@ +export * from "./types"; export * from "./resources"; diff --git a/sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/resources/builds/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/matchmaker/resources/common/index.ts rename to sdks/runtime/typescript/src/serialization/resources/actor/resources/builds/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/resources/common/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/index.ts rename to sdks/runtime/typescript/src/serialization/resources/actor/resources/common/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/actor/resources/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/resources/index.ts new file mode 100644 index 0000000000..b022548476 --- /dev/null +++ b/sdks/runtime/typescript/src/serialization/resources/actor/resources/index.ts @@ -0,0 +1,8 @@ +export * as builds from "./builds"; +export * from "./builds/types"; +export * as common from "./common"; +export * from "./common/types"; +export * as logs from "./logs"; +export * from "./logs/types"; +export * as regions from "./regions"; +export * from "./regions/types"; diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/resources/logs/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/geo/resources/common/index.ts rename to sdks/runtime/typescript/src/serialization/resources/actor/resources/logs/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/index.ts b/sdks/runtime/typescript/src/serialization/resources/actor/resources/regions/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/index.ts rename to sdks/runtime/typescript/src/serialization/resources/actor/resources/regions/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts b/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts deleted file mode 100644 index 1305d71bf1..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/Config.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { ConfigHcaptcha as captcha_config$$configHcaptcha } from "./ConfigHcaptcha"; -import { ConfigTurnstile as captcha_config$$configTurnstile } from "./ConfigTurnstile"; -import { captcha } from "../../../../index"; - -export const Config: core.serialization.ObjectSchema = - core.serialization.object({ - hcaptcha: captcha_config$$configHcaptcha.optional(), - turnstile: captcha_config$$configTurnstile.optional(), - }); - -export declare namespace Config { - interface Raw { - hcaptcha?: captcha.ConfigHcaptcha.Raw | null; - turnstile?: captcha.ConfigTurnstile.Raw | null; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigHcaptcha.ts b/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigHcaptcha.ts deleted file mode 100644 index 9f82e146f6..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigHcaptcha.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const ConfigHcaptcha: core.serialization.ObjectSchema< - serializers.captcha.ConfigHcaptcha.Raw, - Rivet.captcha.ConfigHcaptcha -> = core.serialization.object({ - clientResponse: core.serialization.property("client_response", core.serialization.string()), -}); - -export declare namespace ConfigHcaptcha { - interface Raw { - client_response: string; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigTurnstile.ts b/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigTurnstile.ts deleted file mode 100644 index fdb270007e..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/ConfigTurnstile.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const ConfigTurnstile: core.serialization.ObjectSchema< - serializers.captcha.ConfigTurnstile.Raw, - Rivet.captcha.ConfigTurnstile -> = core.serialization.object({ - clientResponse: core.serialization.property("client_response", core.serialization.string()), -}); - -export declare namespace ConfigTurnstile { - interface Raw { - client_response: string; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/index.ts deleted file mode 100644 index e3d7f9330e..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/config/types/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from "./Config"; -export * from "./ConfigHcaptcha"; -export * from "./ConfigTurnstile"; diff --git a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/index.ts b/sdks/runtime/typescript/src/serialization/resources/captcha/resources/index.ts deleted file mode 100644 index 020463c11c..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/captcha/resources/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * as config from "./config"; -export * from "./config/types"; diff --git a/sdks/runtime/typescript/src/serialization/resources/common/types/DisplayName.ts b/sdks/runtime/typescript/src/serialization/resources/common/types/DisplayName.ts deleted file mode 100644 index e9852bbde3..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/common/types/DisplayName.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../index"; -import * as Rivet from "../../../../api/index"; -import * as core from "../../../../core"; - -export const DisplayName: core.serialization.Schema = - core.serialization.string(); - -export declare namespace DisplayName { - type Raw = string; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/common/types/ErrorBody.ts b/sdks/runtime/typescript/src/serialization/resources/common/types/ErrorBody.ts index 6360c55333..8f81f08206 100644 --- a/sdks/runtime/typescript/src/serialization/resources/common/types/ErrorBody.ts +++ b/sdks/runtime/typescript/src/serialization/resources/common/types/ErrorBody.ts @@ -5,8 +5,7 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { ErrorMetadata as common$$errorMetadata } from "./ErrorMetadata"; -import { common } from "../../index"; +import { ErrorMetadata } from "./ErrorMetadata"; export const ErrorBody: core.serialization.ObjectSchema = core.serialization.object({ @@ -14,7 +13,7 @@ export const ErrorBody: core.serialization.ObjectSchema = - core.serialization.string(); - -export declare namespace Identifier { - type Raw = string; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/common/types/Jwt.ts b/sdks/runtime/typescript/src/serialization/resources/common/types/Jwt.ts deleted file mode 100644 index 0527bf6e24..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/common/types/Jwt.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../index"; -import * as Rivet from "../../../../api/index"; -import * as core from "../../../../core"; - -export const Jwt: core.serialization.Schema = core.serialization.string(); - -export declare namespace Jwt { - type Raw = string; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/common/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/common/types/index.ts index f7e3891adb..eb53c3b2d6 100644 --- a/sdks/runtime/typescript/src/serialization/resources/common/types/index.ts +++ b/sdks/runtime/typescript/src/serialization/resources/common/types/index.ts @@ -1,5 +1,4 @@ -export * from "./Identifier"; -export * from "./Jwt"; -export * from "./DisplayName"; +export * from "./WatchResponse"; +export * from "./Timestamp"; export * from "./ErrorMetadata"; export * from "./ErrorBody"; diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/index.ts b/sdks/runtime/typescript/src/serialization/resources/geo/index.ts deleted file mode 100644 index 3e5335fe42..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/geo/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./resources"; diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Coord.ts b/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Coord.ts deleted file mode 100644 index 7d74fc7318..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Coord.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const Coord: core.serialization.ObjectSchema = - core.serialization.object({ - latitude: core.serialization.number(), - longitude: core.serialization.number(), - }); - -export declare namespace Coord { - interface Raw { - latitude: number; - longitude: number; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Distance.ts b/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Distance.ts deleted file mode 100644 index 4e3185c4df..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/Distance.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const Distance: core.serialization.ObjectSchema = - core.serialization.object({ - kilometers: core.serialization.number(), - miles: core.serialization.number(), - }); - -export declare namespace Distance { - interface Raw { - kilometers: number; - miles: number; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/index.ts deleted file mode 100644 index 9bedc827df..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/geo/resources/common/types/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from "./Coord"; -export * from "./Distance"; diff --git a/sdks/runtime/typescript/src/serialization/resources/index.ts b/sdks/runtime/typescript/src/serialization/resources/index.ts index ba5cb3d62a..8377c4d6f2 100644 --- a/sdks/runtime/typescript/src/serialization/resources/index.ts +++ b/sdks/runtime/typescript/src/serialization/resources/index.ts @@ -1,5 +1,4 @@ -export * as captcha from "./captcha"; +export * as actor from "./actor"; export * as common from "./common"; export * from "./common/types"; -export * as geo from "./geo"; -export * as matchmaker from "./matchmaker"; +export * as upload from "./upload"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/index.ts deleted file mode 100644 index 3e5335fe42..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./resources"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts deleted file mode 100644 index 10885e8489..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/CustomLobbyPublicity.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const CustomLobbyPublicity: core.serialization.Schema< - serializers.matchmaker.CustomLobbyPublicity.Raw, - Rivet.matchmaker.CustomLobbyPublicity -> = core.serialization.enum_(["public", "private"]); - -export declare namespace CustomLobbyPublicity { - type Raw = "public" | "private"; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts deleted file mode 100644 index 893198efad..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/GameModeInfo.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { common } from "../../../../index"; - -export const GameModeInfo: core.serialization.ObjectSchema< - serializers.matchmaker.GameModeInfo.Raw, - Rivet.matchmaker.GameModeInfo -> = core.serialization.object({ - gameModeId: core.serialization.property("game_mode_id", common$$identifier), -}); - -export declare namespace GameModeInfo { - interface Raw { - game_mode_id: common.Identifier.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts deleted file mode 100644 index 8d0fed2835..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinLobby.ts +++ /dev/null @@ -1,30 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { JoinRegion as matchmaker_common$$joinRegion } from "./JoinRegion"; -import { JoinPort as matchmaker_common$$joinPort } from "./JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "./JoinPlayer"; -import { matchmaker } from "../../../../index"; - -export const JoinLobby: core.serialization.ObjectSchema< - serializers.matchmaker.JoinLobby.Raw, - Rivet.matchmaker.JoinLobby -> = core.serialization.object({ - lobbyId: core.serialization.property("lobby_id", core.serialization.string()), - region: matchmaker_common$$joinRegion, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, -}); - -export declare namespace JoinLobby { - interface Raw { - lobby_id: string; - region: matchmaker.JoinRegion.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts deleted file mode 100644 index d2ceb3cd5a..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPlayer.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Jwt as common$$jwt } from "../../../../common/types/Jwt"; -import { common } from "../../../../index"; - -export const JoinPlayer: core.serialization.ObjectSchema< - serializers.matchmaker.JoinPlayer.Raw, - Rivet.matchmaker.JoinPlayer -> = core.serialization.object({ - token: common$$jwt, -}); - -export declare namespace JoinPlayer { - interface Raw { - token: common.Jwt.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts deleted file mode 100644 index 397de3d732..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPort.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { JoinPortRange as matchmaker_common$$joinPortRange } from "./JoinPortRange"; -import { matchmaker } from "../../../../index"; - -export const JoinPort: core.serialization.ObjectSchema = - core.serialization.object({ - host: core.serialization.string().optional(), - hostname: core.serialization.string(), - port: core.serialization.number().optional(), - portRange: core.serialization.property("port_range", matchmaker_common$$joinPortRange.optional()), - isTls: core.serialization.property("is_tls", core.serialization.boolean()), - }); - -export declare namespace JoinPort { - interface Raw { - host?: string | null; - hostname: string; - port?: number | null; - port_range?: matchmaker.JoinPortRange.Raw | null; - is_tls: boolean; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPortRange.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPortRange.ts deleted file mode 100644 index fa51f669e5..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinPortRange.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const JoinPortRange: core.serialization.ObjectSchema< - serializers.matchmaker.JoinPortRange.Raw, - Rivet.matchmaker.JoinPortRange -> = core.serialization.object({ - min: core.serialization.number(), - max: core.serialization.number(), -}); - -export declare namespace JoinPortRange { - interface Raw { - min: number; - max: number; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts deleted file mode 100644 index 90fef0a73b..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/JoinRegion.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { common } from "../../../../index"; - -export const JoinRegion: core.serialization.ObjectSchema< - serializers.matchmaker.JoinRegion.Raw, - Rivet.matchmaker.JoinRegion -> = core.serialization.object({ - regionId: core.serialization.property("region_id", common$$identifier), - displayName: core.serialization.property("display_name", common$$displayName), -}); - -export declare namespace JoinRegion { - interface Raw { - region_id: common.Identifier.Raw; - display_name: common.DisplayName.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/LobbyInfo.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/LobbyInfo.ts deleted file mode 100644 index bac822d7b6..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/LobbyInfo.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const LobbyInfo: core.serialization.ObjectSchema< - serializers.matchmaker.LobbyInfo.Raw, - Rivet.matchmaker.LobbyInfo -> = core.serialization.object({ - regionId: core.serialization.property("region_id", core.serialization.string()), - gameModeId: core.serialization.property("game_mode_id", core.serialization.string()), - lobbyId: core.serialization.property("lobby_id", core.serialization.string()), - maxPlayersNormal: core.serialization.property("max_players_normal", core.serialization.number()), - maxPlayersDirect: core.serialization.property("max_players_direct", core.serialization.number()), - maxPlayersParty: core.serialization.property("max_players_party", core.serialization.number()), - totalPlayerCount: core.serialization.property("total_player_count", core.serialization.number()), - state: core.serialization.unknown().optional(), -}); - -export declare namespace LobbyInfo { - interface Raw { - region_id: string; - game_mode_id: string; - lobby_id: string; - max_players_normal: number; - max_players_direct: number; - max_players_party: number; - total_player_count: number; - state?: unknown | null; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts deleted file mode 100644 index 09cd474cea..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/RegionInfo.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { DisplayName as common$$displayName } from "../../../../common/types/DisplayName"; -import { Coord as geo_common$$coord } from "../../../../geo/resources/common/types/Coord"; -import { Distance as geo_common$$distance } from "../../../../geo/resources/common/types/Distance"; -import { common, geo } from "../../../../index"; - -export const RegionInfo: core.serialization.ObjectSchema< - serializers.matchmaker.RegionInfo.Raw, - Rivet.matchmaker.RegionInfo -> = core.serialization.object({ - regionId: core.serialization.property("region_id", common$$identifier), - providerDisplayName: core.serialization.property("provider_display_name", common$$displayName), - regionDisplayName: core.serialization.property("region_display_name", common$$displayName), - datacenterCoord: core.serialization.property("datacenter_coord", geo_common$$coord), - datacenterDistanceFromClient: core.serialization.property("datacenter_distance_from_client", geo_common$$distance), -}); - -export declare namespace RegionInfo { - interface Raw { - region_id: common.Identifier.Raw; - provider_display_name: common.DisplayName.Raw; - region_display_name: common.DisplayName.Raw; - datacenter_coord: geo.Coord.Raw; - datacenter_distance_from_client: geo.Distance.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/index.ts deleted file mode 100644 index 5519ce0ef7..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/common/types/index.ts +++ /dev/null @@ -1,9 +0,0 @@ -export * from "./LobbyInfo"; -export * from "./GameModeInfo"; -export * from "./RegionInfo"; -export * from "./JoinLobby"; -export * from "./JoinRegion"; -export * from "./JoinPort"; -export * from "./JoinPortRange"; -export * from "./JoinPlayer"; -export * from "./CustomLobbyPublicity"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/index.ts deleted file mode 100644 index 263cd6ef8a..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -export * as common from "./common"; -export * from "./common/types"; -export * as lobbies from "./lobbies"; -export * from "./lobbies/types"; -export * as players from "./players"; -export * from "./players/types"; -export * as regions from "./regions"; -export * from "./regions/types"; -export * from "./lobbies/client/requests"; -export * from "./players/client/requests"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/getState.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/getState.ts deleted file mode 100644 index b442673254..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/getState.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as core from "../../../../../../core"; - -export const Response: core.serialization.Schema< - serializers.matchmaker.lobbies.getState.Response.Raw, - unknown | undefined -> = core.serialization.unknown().optional(); - -export declare namespace Response { - type Raw = unknown | null | undefined; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/index.ts deleted file mode 100644 index 4593fc0125..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * as setState from "./setState"; -export * as getState from "./getState"; -export * from "./requests"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts deleted file mode 100644 index f18e1cbbcc..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/CreateLobbyRequest.ts +++ /dev/null @@ -1,37 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; -import { CustomLobbyPublicity as matchmaker_common$$customLobbyPublicity } from "../../../common/types/CustomLobbyPublicity"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { matchmaker, captcha } from "../../../../../index"; - -export const CreateLobbyRequest: core.serialization.Schema< - serializers.matchmaker.CreateLobbyRequest.Raw, - Rivet.matchmaker.CreateLobbyRequest -> = core.serialization.object({ - gameMode: core.serialization.property("game_mode", core.serialization.string()), - region: core.serialization.string().optional(), - publicity: matchmaker_common$$customLobbyPublicity.optional(), - tags: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), - maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), - lobbyConfig: core.serialization.property("lobby_config", core.serialization.unknown().optional()), - captcha: captcha_config$$config.optional(), - verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), -}); - -export declare namespace CreateLobbyRequest { - interface Raw { - game_mode: string; - region?: string | null; - publicity?: matchmaker.CustomLobbyPublicity.Raw | null; - tags?: Record | null; - max_players?: number | null; - lobby_config?: unknown | null; - captcha?: captcha.Config.Raw | null; - verification_data?: unknown | null; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts deleted file mode 100644 index 3a3c260e3b..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/FindLobbyRequest.ts +++ /dev/null @@ -1,37 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { captcha } from "../../../../../index"; - -export const FindLobbyRequest: core.serialization.Schema< - serializers.matchmaker.FindLobbyRequest.Raw, - Omit -> = core.serialization.object({ - gameModes: core.serialization.property("game_modes", core.serialization.list(core.serialization.string())), - regions: core.serialization.list(core.serialization.string()).optional(), - preventAutoCreateLobby: core.serialization.property( - "prevent_auto_create_lobby", - core.serialization.boolean().optional() - ), - tags: core.serialization.record(core.serialization.string(), core.serialization.string()).optional(), - maxPlayers: core.serialization.property("max_players", core.serialization.number().optional()), - captcha: captcha_config$$config.optional(), - verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), -}); - -export declare namespace FindLobbyRequest { - interface Raw { - game_modes: string[]; - regions?: string[] | null; - prevent_auto_create_lobby?: boolean | null; - tags?: Record | null; - max_players?: number | null; - captcha?: captcha.Config.Raw | null; - verification_data?: unknown | null; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts deleted file mode 100644 index 511e171a4b..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/JoinLobbyRequest.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; -import { Config as captcha_config$$config } from "../../../../../captcha/resources/config/types/Config"; -import { captcha } from "../../../../../index"; - -export const JoinLobbyRequest: core.serialization.Schema< - serializers.matchmaker.JoinLobbyRequest.Raw, - Rivet.matchmaker.JoinLobbyRequest -> = core.serialization.object({ - lobbyId: core.serialization.property("lobby_id", core.serialization.string()), - captcha: captcha_config$$config.optional(), - verificationData: core.serialization.property("verification_data", core.serialization.unknown().optional()), -}); - -export declare namespace JoinLobbyRequest { - interface Raw { - lobby_id: string; - captcha?: captcha.Config.Raw | null; - verification_data?: unknown | null; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts deleted file mode 100644 index dc16f64f1f..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/SetLobbyClosedRequest.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; - -export const SetLobbyClosedRequest: core.serialization.Schema< - serializers.matchmaker.SetLobbyClosedRequest.Raw, - Rivet.matchmaker.SetLobbyClosedRequest -> = core.serialization.object({ - isClosed: core.serialization.property("is_closed", core.serialization.boolean()), -}); - -export declare namespace SetLobbyClosedRequest { - interface Raw { - is_closed: boolean; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/index.ts deleted file mode 100644 index 97f931ec1a..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/requests/index.ts +++ /dev/null @@ -1,4 +0,0 @@ -export { SetLobbyClosedRequest } from "./SetLobbyClosedRequest"; -export { FindLobbyRequest } from "./FindLobbyRequest"; -export { JoinLobbyRequest } from "./JoinLobbyRequest"; -export { CreateLobbyRequest } from "./CreateLobbyRequest"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/setState.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/setState.ts deleted file mode 100644 index 87703edf93..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/client/setState.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as core from "../../../../../../core"; - -export const Request: core.serialization.Schema< - serializers.matchmaker.lobbies.setState.Request.Raw, - unknown | undefined -> = core.serialization.unknown().optional(); - -export declare namespace Request { - type Raw = unknown | null | undefined; -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/index.ts deleted file mode 100644 index c9240f83b4..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from "./types"; -export * from "./client"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts deleted file mode 100644 index b128c857ac..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/CreateLobbyResponse.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; - -export const CreateLobbyResponse: core.serialization.ObjectSchema< - serializers.matchmaker.CreateLobbyResponse.Raw, - Rivet.matchmaker.CreateLobbyResponse -> = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, -}); - -export declare namespace CreateLobbyResponse { - interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts deleted file mode 100644 index 375882ae9c..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/FindLobbyResponse.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; - -export const FindLobbyResponse: core.serialization.ObjectSchema< - serializers.matchmaker.FindLobbyResponse.Raw, - Rivet.matchmaker.FindLobbyResponse -> = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, -}); - -export declare namespace FindLobbyResponse { - interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts deleted file mode 100644 index a721e3eb07..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/JoinLobbyResponse.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { JoinLobby as matchmaker_common$$joinLobby } from "../../common/types/JoinLobby"; -import { JoinPort as matchmaker_common$$joinPort } from "../../common/types/JoinPort"; -import { JoinPlayer as matchmaker_common$$joinPlayer } from "../../common/types/JoinPlayer"; -import { matchmaker } from "../../../../index"; - -export const JoinLobbyResponse: core.serialization.ObjectSchema< - serializers.matchmaker.JoinLobbyResponse.Raw, - Rivet.matchmaker.JoinLobbyResponse -> = core.serialization.object({ - lobby: matchmaker_common$$joinLobby, - ports: core.serialization.record(core.serialization.string(), matchmaker_common$$joinPort), - player: matchmaker_common$$joinPlayer, -}); - -export declare namespace JoinLobbyResponse { - interface Raw { - lobby: matchmaker.JoinLobby.Raw; - ports: Record; - player: matchmaker.JoinPlayer.Raw; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts deleted file mode 100644 index 7b6eae5b12..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/ListLobbiesResponse.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { GameModeInfo as matchmaker_common$$gameModeInfo } from "../../common/types/GameModeInfo"; -import { RegionInfo as matchmaker_common$$regionInfo } from "../../common/types/RegionInfo"; -import { LobbyInfo as matchmaker_common$$lobbyInfo } from "../../common/types/LobbyInfo"; -import { matchmaker } from "../../../../index"; - -export const ListLobbiesResponse: core.serialization.ObjectSchema< - serializers.matchmaker.ListLobbiesResponse.Raw, - Rivet.matchmaker.ListLobbiesResponse -> = core.serialization.object({ - gameModes: core.serialization.property("game_modes", core.serialization.list(matchmaker_common$$gameModeInfo)), - regions: core.serialization.list(matchmaker_common$$regionInfo), - lobbies: core.serialization.list(matchmaker_common$$lobbyInfo), -}); - -export declare namespace ListLobbiesResponse { - interface Raw { - game_modes: matchmaker.GameModeInfo.Raw[]; - regions: matchmaker.RegionInfo.Raw[]; - lobbies: matchmaker.LobbyInfo.Raw[]; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/index.ts deleted file mode 100644 index 13491dd556..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/lobbies/types/index.ts +++ /dev/null @@ -1,4 +0,0 @@ -export * from "./FindLobbyResponse"; -export * from "./JoinLobbyResponse"; -export * from "./CreateLobbyResponse"; -export * from "./ListLobbiesResponse"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts deleted file mode 100644 index 9a01e7e1a9..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerConnectedRequest.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; - -export const PlayerConnectedRequest: core.serialization.Schema< - serializers.matchmaker.PlayerConnectedRequest.Raw, - Rivet.matchmaker.PlayerConnectedRequest -> = core.serialization.object({ - playerToken: core.serialization.property("player_token", core.serialization.string()), -}); - -export declare namespace PlayerConnectedRequest { - interface Raw { - player_token: string; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts deleted file mode 100644 index 4af2aab40d..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/PlayerDisconnectedRequest.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../../index"; -import * as Rivet from "../../../../../../../api/index"; -import * as core from "../../../../../../../core"; - -export const PlayerDisconnectedRequest: core.serialization.Schema< - serializers.matchmaker.PlayerDisconnectedRequest.Raw, - Rivet.matchmaker.PlayerDisconnectedRequest -> = core.serialization.object({ - playerToken: core.serialization.property("player_token", core.serialization.string()), -}); - -export declare namespace PlayerDisconnectedRequest { - interface Raw { - player_token: string; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/index.ts deleted file mode 100644 index 254ba86ed3..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/client/requests/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { PlayerConnectedRequest } from "./PlayerConnectedRequest"; -export { PlayerDisconnectedRequest } from "./PlayerDisconnectedRequest"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/index.ts deleted file mode 100644 index c9240f83b4..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from "./types"; -export * from "./client"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts deleted file mode 100644 index 8f2c6bddeb..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GameModeStatistics.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { RegionStatistics as matchmaker_players$$regionStatistics } from "./RegionStatistics"; -import { common, matchmaker } from "../../../../index"; - -export const GameModeStatistics: core.serialization.ObjectSchema< - serializers.matchmaker.GameModeStatistics.Raw, - Rivet.matchmaker.GameModeStatistics -> = core.serialization.object({ - playerCount: core.serialization.property("player_count", core.serialization.number()), - regions: core.serialization.record(common$$identifier, matchmaker_players$$regionStatistics), -}); - -export declare namespace GameModeStatistics { - interface Raw { - player_count: number; - regions: Record; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts deleted file mode 100644 index 1cde117ac3..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/GetStatisticsResponse.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { Identifier as common$$identifier } from "../../../../common/types/Identifier"; -import { GameModeStatistics as matchmaker_players$$gameModeStatistics } from "./GameModeStatistics"; -import { common, matchmaker } from "../../../../index"; - -export const GetStatisticsResponse: core.serialization.ObjectSchema< - serializers.matchmaker.GetStatisticsResponse.Raw, - Rivet.matchmaker.GetStatisticsResponse -> = core.serialization.object({ - playerCount: core.serialization.property("player_count", core.serialization.number()), - gameModes: core.serialization.property( - "game_modes", - core.serialization.record(common$$identifier, matchmaker_players$$gameModeStatistics) - ), -}); - -export declare namespace GetStatisticsResponse { - interface Raw { - player_count: number; - game_modes: Record; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/RegionStatistics.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/RegionStatistics.ts deleted file mode 100644 index 179f5ce3b9..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/RegionStatistics.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; - -export const RegionStatistics: core.serialization.ObjectSchema< - serializers.matchmaker.RegionStatistics.Raw, - Rivet.matchmaker.RegionStatistics -> = core.serialization.object({ - playerCount: core.serialization.property("player_count", core.serialization.number()), -}); - -export declare namespace RegionStatistics { - interface Raw { - player_count: number; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/index.ts deleted file mode 100644 index e6a2666580..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/players/types/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from "./GetStatisticsResponse"; -export * from "./GameModeStatistics"; -export * from "./RegionStatistics"; diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts deleted file mode 100644 index 52b47b98d7..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/ListRegionsResponse.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Rivet from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { RegionInfo as matchmaker_common$$regionInfo } from "../../common/types/RegionInfo"; -import { matchmaker } from "../../../../index"; - -export const ListRegionsResponse: core.serialization.ObjectSchema< - serializers.matchmaker.ListRegionsResponse.Raw, - Rivet.matchmaker.ListRegionsResponse -> = core.serialization.object({ - regions: core.serialization.list(matchmaker_common$$regionInfo), -}); - -export declare namespace ListRegionsResponse { - interface Raw { - regions: matchmaker.RegionInfo.Raw[]; - } -} diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/index.ts b/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/index.ts deleted file mode 100644 index dd60cc81be..0000000000 --- a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/types/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./ListRegionsResponse"; diff --git a/sdks/runtime/typescript/src/api/resources/geo/index.ts b/sdks/runtime/typescript/src/serialization/resources/upload/index.ts similarity index 100% rename from sdks/runtime/typescript/src/api/resources/geo/index.ts rename to sdks/runtime/typescript/src/serialization/resources/upload/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/index.ts b/sdks/runtime/typescript/src/serialization/resources/upload/resources/common/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/matchmaker/resources/regions/index.ts rename to sdks/runtime/typescript/src/serialization/resources/upload/resources/common/index.ts diff --git a/sdks/runtime/typescript/src/serialization/resources/geo/resources/index.ts b/sdks/runtime/typescript/src/serialization/resources/upload/resources/index.ts similarity index 100% rename from sdks/runtime/typescript/src/serialization/resources/geo/resources/index.ts rename to sdks/runtime/typescript/src/serialization/resources/upload/resources/index.ts diff --git a/sdks/runtime/typescript/types/Client.d.ts b/sdks/runtime/typescript/types/Client.d.ts index fe50a9eeb0..8c12e0e89f 100644 --- a/sdks/runtime/typescript/types/Client.d.ts +++ b/sdks/runtime/typescript/types/Client.d.ts @@ -3,7 +3,7 @@ */ import * as environments from "./environments"; import * as core from "./core"; -import { Matchmaker } from "./api/resources/matchmaker/client/Client"; +import { Actor } from "./api/resources/actor/client/Client"; export declare namespace RivetClient { interface Options { environment?: core.Supplier; @@ -22,6 +22,6 @@ export declare namespace RivetClient { export declare class RivetClient { protected readonly _options: RivetClient.Options; constructor(_options: RivetClient.Options); - protected _matchmaker: Matchmaker | undefined; - get matchmaker(): Matchmaker; + protected _actor: Actor | undefined; + get actor(): Actor; } diff --git a/sdks/runtime/typescript/types/api/resources/common/types/index.d.ts b/sdks/runtime/typescript/types/api/resources/common/types/index.d.ts index f7e3891adb..eb53c3b2d6 100644 --- a/sdks/runtime/typescript/types/api/resources/common/types/index.d.ts +++ b/sdks/runtime/typescript/types/api/resources/common/types/index.d.ts @@ -1,5 +1,4 @@ -export * from "./Identifier"; -export * from "./Jwt"; -export * from "./DisplayName"; +export * from "./WatchResponse"; +export * from "./Timestamp"; export * from "./ErrorMetadata"; export * from "./ErrorBody"; diff --git a/sdks/runtime/typescript/types/api/resources/index.d.ts b/sdks/runtime/typescript/types/api/resources/index.d.ts index 6222bce3e8..b1134b49e8 100644 --- a/sdks/runtime/typescript/types/api/resources/index.d.ts +++ b/sdks/runtime/typescript/types/api/resources/index.d.ts @@ -1,6 +1,5 @@ -export * as captcha from "./captcha"; +export * as actor from "./actor"; export * as common from "./common"; export * from "./common/types"; -export * as geo from "./geo"; -export * as matchmaker from "./matchmaker"; +export * as upload from "./upload"; export * from "./common/errors"; diff --git a/sdks/runtime/typescript/types/core/fetcher/Fetcher.d.ts b/sdks/runtime/typescript/types/core/fetcher/Fetcher.d.ts index 801c336517..0afcdfafbe 100644 --- a/sdks/runtime/typescript/types/core/fetcher/Fetcher.d.ts +++ b/sdks/runtime/typescript/types/core/fetcher/Fetcher.d.ts @@ -13,7 +13,7 @@ export declare namespace Fetcher { withCredentials?: boolean; abortSignal?: AbortSignal; requestType?: "json" | "file" | "bytes"; - responseType?: "json" | "blob" | "sse" | "streaming" | "text"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; duplex?: "half"; } type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; diff --git a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts index ed7dbfd818..0554b6a4cc 100644 --- a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +++ b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts @@ -1,24 +1,23 @@ -/// -import type { Writable } from "stream"; +import type { Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; -export declare class Node18UniversalStreamWrapper implements StreamWrapper, Uint8Array> { +export declare class Node18UniversalStreamWrapper implements StreamWrapper | Writable | WritableStream, ReadFormat> { private readableStream; private reader; private events; private paused; private resumeCallback; private encoding; - constructor(readableStream: ReadableStream); + constructor(readableStream: ReadableStream); on(event: string, callback: EventCallback): void; off(event: string, callback: EventCallback): void; - pipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; - pipeTo(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; - unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void; + pipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; + pipeTo(dest: Node18UniversalStreamWrapper | Writable | WritableStream): Node18UniversalStreamWrapper | Writable | WritableStream; + unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void; destroy(error?: Error): void; pause(): void; resume(): void; get isPaused(): boolean; - read(): Promise; + read(): Promise; setEncoding(encoding: string): void; text(): Promise; json(): Promise; @@ -27,4 +26,5 @@ export declare class Node18UniversalStreamWrapper implements StreamWrapper; } diff --git a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts index be718e3d4f..fb9858be9a 100644 --- a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +++ b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts @@ -1,5 +1,5 @@ /// -import type { Readable, Writable } from "stream"; +import type { Readable, Writable } from "readable-stream"; import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export declare class NodePre18StreamWrapper implements StreamWrapper { private readableStream; @@ -18,4 +18,5 @@ export declare class NodePre18StreamWrapper implements StreamWrapper; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } diff --git a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts index a6574aa91b..434b355783 100644 --- a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +++ b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts @@ -12,7 +12,7 @@ export declare class UndiciStreamWrapper | WritableStream): UndiciStreamWrapper | WritableStream; pipeTo(dest: UndiciStreamWrapper | WritableStream): UndiciStreamWrapper | WritableStream; - unpipe(dest: UndiciStreamWrapper | WritableStream): void; + unpipe(dest: UndiciStreamWrapper | WritableStream): void; destroy(error?: Error): void; pause(): void; resume(): void; @@ -26,5 +26,6 @@ export declare class UndiciStreamWrapper; } export {}; diff --git a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts index ba7d363747..939c617d70 100644 --- a/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +++ b/sdks/runtime/typescript/types/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts @@ -13,5 +13,6 @@ export interface StreamWrapper { read(): Promise; text(): Promise; json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; } export declare function chooseStreamWrapper(responseBody: any): Promise>>; diff --git a/sdks/runtime/typescript/types/core/index.d.ts b/sdks/runtime/typescript/types/core/index.d.ts index f0a8603dec..2d20c46f3e 100644 --- a/sdks/runtime/typescript/types/core/index.d.ts +++ b/sdks/runtime/typescript/types/core/index.d.ts @@ -1,4 +1,4 @@ -export * from "./runtime"; export * from "./fetcher"; export * from "./auth"; +export * from "./runtime"; export * as serialization from "./schemas"; diff --git a/sdks/runtime/typescript/types/core/schemas/Schema.d.ts b/sdks/runtime/typescript/types/core/schemas/Schema.d.ts index 66fd54db3d..e58726b3fc 100644 --- a/sdks/runtime/typescript/types/core/schemas/Schema.d.ts +++ b/sdks/runtime/typescript/types/core/schemas/Schema.d.ts @@ -8,6 +8,7 @@ export interface BaseSchema { getType: () => SchemaType | SchemaType; } export declare const SchemaType: { + readonly BIGINT: "bigint"; readonly DATE: "date"; readonly ENUM: "enum"; readonly LIST: "list"; diff --git a/sdks/runtime/typescript/types/core/schemas/builders/index.d.ts b/sdks/runtime/typescript/types/core/schemas/builders/index.d.ts index 050cd2c4ef..65211f9252 100644 --- a/sdks/runtime/typescript/types/core/schemas/builders/index.d.ts +++ b/sdks/runtime/typescript/types/core/schemas/builders/index.d.ts @@ -1,3 +1,4 @@ +export * from "./bigint"; export * from "./date"; export * from "./enum"; export * from "./lazy"; diff --git a/sdks/runtime/typescript/types/serialization/resources/common/types/ErrorBody.d.ts b/sdks/runtime/typescript/types/serialization/resources/common/types/ErrorBody.d.ts index 36f1711853..492b1eb1b9 100644 --- a/sdks/runtime/typescript/types/serialization/resources/common/types/ErrorBody.d.ts +++ b/sdks/runtime/typescript/types/serialization/resources/common/types/ErrorBody.d.ts @@ -4,7 +4,7 @@ import * as serializers from "../../../index"; import * as Rivet from "../../../../api/index"; import * as core from "../../../../core"; -import { common } from "../../index"; +import { ErrorMetadata } from "./ErrorMetadata"; export declare const ErrorBody: core.serialization.ObjectSchema; export declare namespace ErrorBody { interface Raw { @@ -12,6 +12,6 @@ export declare namespace ErrorBody { message: string; ray_id: string; documentation?: string | null; - metadata?: (common.ErrorMetadata.Raw | undefined) | null; + metadata?: (ErrorMetadata.Raw | undefined) | null; } } diff --git a/sdks/runtime/typescript/types/serialization/resources/common/types/index.d.ts b/sdks/runtime/typescript/types/serialization/resources/common/types/index.d.ts index f7e3891adb..eb53c3b2d6 100644 --- a/sdks/runtime/typescript/types/serialization/resources/common/types/index.d.ts +++ b/sdks/runtime/typescript/types/serialization/resources/common/types/index.d.ts @@ -1,5 +1,4 @@ -export * from "./Identifier"; -export * from "./Jwt"; -export * from "./DisplayName"; +export * from "./WatchResponse"; +export * from "./Timestamp"; export * from "./ErrorMetadata"; export * from "./ErrorBody"; diff --git a/sdks/runtime/typescript/types/serialization/resources/index.d.ts b/sdks/runtime/typescript/types/serialization/resources/index.d.ts index ba5cb3d62a..8377c4d6f2 100644 --- a/sdks/runtime/typescript/types/serialization/resources/index.d.ts +++ b/sdks/runtime/typescript/types/serialization/resources/index.d.ts @@ -1,5 +1,4 @@ -export * as captcha from "./captcha"; +export * as actor from "./actor"; export * as common from "./common"; export * from "./common/types"; -export * as geo from "./geo"; -export * as matchmaker from "./matchmaker"; +export * as upload from "./upload";