figma_api/models/
error_response_payload_with_err_message.rs

1/*
2 * Figma API
3 *
4 * This is the OpenAPI specification for the [Figma REST API](https://www.figma.com/developers/api).  Note: we are releasing the OpenAPI specification as a beta given the large surface area and complexity of the REST API. If you notice any inaccuracies with the specification, please [file an issue](https://github.com/figma/rest-api-spec/issues).
5 *
6 * The version of the OpenAPI document: 0.31.0
7 * Contact: support@figma.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// ErrorResponsePayloadWithErrMessage : A response indicating an error occurred.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct ErrorResponsePayloadWithErrMessage {
17    /// Status code
18    #[serde(rename = "status")]
19    pub status: f64,
20    /// A string describing the error
21    #[serde(rename = "err")]
22    pub err: String,
23}
24
25impl ErrorResponsePayloadWithErrMessage {
26    /// A response indicating an error occurred.
27    pub fn new(status: f64, err: String) -> ErrorResponsePayloadWithErrMessage {
28        ErrorResponsePayloadWithErrMessage {
29            status,
30            err,
31        }
32    }
33}
34