1
This commit is contained in:
@@ -13,6 +13,12 @@ pub struct CreateMatch3DAgentSessionRequest {
|
||||
pub clear_count: Option<u32>,
|
||||
#[serde(default)]
|
||||
pub difficulty: Option<u32>,
|
||||
#[serde(default)]
|
||||
pub asset_style_id: Option<String>,
|
||||
#[serde(default)]
|
||||
pub asset_style_label: Option<String>,
|
||||
#[serde(default)]
|
||||
pub asset_style_prompt: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]
|
||||
@@ -52,6 +58,12 @@ pub struct Match3DCreatorConfigResponse {
|
||||
pub reference_image_src: Option<String>,
|
||||
pub clear_count: u32,
|
||||
pub difficulty: u32,
|
||||
#[serde(default)]
|
||||
pub asset_style_id: Option<String>,
|
||||
#[serde(default)]
|
||||
pub asset_style_label: Option<String>,
|
||||
#[serde(default)]
|
||||
pub asset_style_prompt: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq)]
|
||||
@@ -73,6 +85,32 @@ pub struct Match3DResultDraftResponse {
|
||||
pub total_item_count: u32,
|
||||
pub publish_ready: bool,
|
||||
pub blockers: Vec<String>,
|
||||
#[serde(default, skip_serializing_if = "Vec::is_empty")]
|
||||
pub generated_item_assets: Vec<Match3DGeneratedItemAssetResponse>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct Match3DGeneratedItemAssetResponse {
|
||||
pub item_id: String,
|
||||
pub item_name: String,
|
||||
#[serde(default)]
|
||||
pub image_src: Option<String>,
|
||||
#[serde(default)]
|
||||
pub image_object_key: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_src: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_object_key: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_file_name: Option<String>,
|
||||
#[serde(default)]
|
||||
pub task_uuid: Option<String>,
|
||||
#[serde(default)]
|
||||
pub subscription_key: Option<String>,
|
||||
pub status: String,
|
||||
#[serde(default)]
|
||||
pub error: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq)]
|
||||
@@ -147,6 +185,9 @@ mod tests {
|
||||
reference_image_src: Some("data:image/png;base64,abc".to_string()),
|
||||
clear_count: Some(4),
|
||||
difficulty: Some(3),
|
||||
asset_style_id: Some("clay-toy".to_string()),
|
||||
asset_style_label: Some("黏土手作".to_string()),
|
||||
asset_style_prompt: Some("圆润黏土手作风".to_string()),
|
||||
})
|
||||
.expect("payload should serialize");
|
||||
|
||||
@@ -157,5 +198,6 @@ mod tests {
|
||||
json!("data:image/png;base64,abc")
|
||||
);
|
||||
assert_eq!(payload["clearCount"], json!(4));
|
||||
assert_eq!(payload["assetStyleId"], json!("clay-toy"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,6 +40,32 @@ pub struct Match3DWorkSummaryResponse {
|
||||
#[serde(default)]
|
||||
pub published_at: Option<String>,
|
||||
pub publish_ready: bool,
|
||||
#[serde(default, skip_serializing_if = "Vec::is_empty")]
|
||||
pub generated_item_assets: Vec<Match3DGeneratedItemAssetResponse>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct Match3DGeneratedItemAssetResponse {
|
||||
pub item_id: String,
|
||||
pub item_name: String,
|
||||
#[serde(default)]
|
||||
pub image_src: Option<String>,
|
||||
#[serde(default)]
|
||||
pub image_object_key: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_src: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_object_key: Option<String>,
|
||||
#[serde(default)]
|
||||
pub model_file_name: Option<String>,
|
||||
#[serde(default)]
|
||||
pub task_uuid: Option<String>,
|
||||
#[serde(default)]
|
||||
pub subscription_key: Option<String>,
|
||||
pub status: String,
|
||||
#[serde(default)]
|
||||
pub error: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]
|
||||
|
||||
@@ -85,6 +85,8 @@ pub struct PuzzleLeaderboardEntryResponse {
|
||||
pub nickname: String,
|
||||
pub elapsed_ms: u64,
|
||||
#[serde(default)]
|
||||
pub visible_tags: Vec<String>,
|
||||
#[serde(default)]
|
||||
pub is_current_player: bool,
|
||||
}
|
||||
|
||||
|
||||
@@ -486,6 +486,8 @@ pub struct AdminUpsertProfileInviteCodeRequest {
|
||||
#[serde(default)]
|
||||
pub metadata: Option<serde_json::Value>,
|
||||
#[serde(default)]
|
||||
pub granted_user_tags: Vec<String>,
|
||||
#[serde(default)]
|
||||
pub starts_at: Option<String>,
|
||||
#[serde(default)]
|
||||
pub expires_at: Option<String>,
|
||||
@@ -524,6 +526,7 @@ pub struct ProfileInviteCodeAdminResponse {
|
||||
pub user_id: String,
|
||||
pub invite_code: String,
|
||||
pub metadata: serde_json::Value,
|
||||
pub granted_user_tags: Vec<String>,
|
||||
pub starts_at: Option<String>,
|
||||
pub expires_at: Option<String>,
|
||||
pub status: String,
|
||||
|
||||
Reference in New Issue
Block a user