diff --git a/crates/manifest/src/schema/json_schema.rs b/crates/manifest/src/schema/json_schema.rs index d7922b1573..bbdf719426 100644 --- a/crates/manifest/src/schema/json_schema.rs +++ b/crates/manifest/src/schema/json_schema.rs @@ -30,6 +30,8 @@ pub struct HttpTriggerSchema { /// `components = { ... }` #[serde(default, skip_serializing_if = "Map::is_empty")] pub components: Map, + /// `static_response = { ... }` + pub static_response: Option, /// `dependencies.middleware = { ... }` #[serde(default, skip_serializing_if = "Map::is_empty")] pub dependencies: Map, @@ -74,6 +76,19 @@ pub struct HttpPrivateEndpoint { pub private: bool, } +#[allow(dead_code)] +#[derive(JsonSchema)] +#[schemars(deny_unknown_fields)] +pub struct StaticResponseSchema { + /// The status code for the static response. Default is 200. + status_code: Option, + #[serde(default)] + /// The headers for the static response. Default is an empty map. + headers: Map, + /// The body of the static response. Default is an empty body. + body: Option, +} + #[allow(dead_code)] #[derive(JsonSchema)] #[schemars(deny_unknown_fields)]