autogen-stedi 0.3.2

Auto-generated, strongly-typed Rust client for the Stedi APIs
Documentation
/*
 * Core
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 2023-08-01
 * Contact: core@stedi.com
 * Generated by: https://openapi-generator.tech
 */

use crate::core::models;
use serde::{Deserialize, Serialize};

/// Partnership : Information about the associated partnership.  A partnership describes all aspects of the EDI relationship between two profiles in your Stedi account, such as which transaction sets they will exchange and other important information for processing EDI files. If you're sending or receiving transactions through the Stedi clearinghouse, Stedi configures the necessary partnership for you automatically when you set up your account.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Partnership {
    /// The unique identifier for the partnership within the Stedi platform.  A partnership describes all aspects of the EDI relationship between two profiles in your Stedi account, such as which transaction sets they will exchange and other important information for processing EDI files. If you're sending or receiving transactions through the Stedi clearinghouse, Stedi configures the necessary partnerships for you automatically when you set up your account.
    #[serde(rename = "partnershipId")]
    pub partnership_id: String,
    #[serde(rename = "partnershipType")]
    pub partnership_type: models::PartnershipType,
    #[serde(rename = "sender")]
    pub sender: Box<models::PartnershipSender>,
    #[serde(rename = "receiver")]
    pub receiver: Box<models::PartnershipReceiver>,
}

impl Partnership {
    /// Information about the associated partnership.  A partnership describes all aspects of the EDI relationship between two profiles in your Stedi account, such as which transaction sets they will exchange and other important information for processing EDI files. If you're sending or receiving transactions through the Stedi clearinghouse, Stedi configures the necessary partnership for you automatically when you set up your account.
    pub fn new(partnership_id: String, partnership_type: models::PartnershipType, sender: models::PartnershipSender, receiver: models::PartnershipReceiver) -> Partnership {
        Partnership {
            partnership_id,
            partnership_type,
            sender: Box::new(sender),
            receiver: Box::new(receiver),
        }
    }
}