fastly_api/models/bot_management_not_found_error.rs
1/*
2 * Fastly API
3 *
4 * Via the Fastly API you can perform any of the operations that are possible within the management console, including creating services, domains, and backends, configuring rules or uploading your own application code, as well as account operations such as user administration and billing reports. The API is organized into collections of endpoints that allow manipulation of objects related to Fastly services and accounts. For the most accurate and up-to-date API reference content, visit our [Developer Hub](https://www.fastly.com/documentation/reference/api/)
5 *
6 */
7
8
9
10
11#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
12pub struct BotManagementNotFoundError {
13 #[serde(rename = "title")]
14 pub title: String,
15 #[serde(rename = "status")]
16 pub status: Status,
17 /// An explanation of the problem, specific to this occurrence.
18 #[serde(rename = "detail", skip_serializing_if = "Option::is_none")]
19 pub detail: Option<String>,
20}
21
22impl BotManagementNotFoundError {
23 pub fn new(title: String, status: Status) -> BotManagementNotFoundError {
24 BotManagementNotFoundError {
25 title,
26 status,
27 detail: None,
28 }
29 }
30}
31
32///
33#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
34pub enum Status {
35 #[serde(rename = "404")]
36 Status404,
37}
38
39impl Default for Status {
40 fn default() -> Status {
41 Self::Status404
42 }
43}
44