// SPDX-FileCopyrightText: Politik im Blick developers
// SPDX-FileCopyrightText: Wolfgang Silbermayr <wolfgang@silbermayr.at>
//
// SPDX-License-Identifier: AGPL-3.0-or-later OR EUPL-1.2

use oparl_types::Date;
use pib_service_core_types::OrganizationId;
use serde::{Deserialize, Serialize};

pub mod get;
pub mod post;

pub mod by_id;

pub use crate::body::by_id::membership::{Membership, UpdateMembership};

#[derive(Debug, Clone, PartialEq, Eq, Deserialize, Serialize)]
pub struct NewMembership {
    pub organization_id: OrganizationId,

    pub role: Option<String>,
    pub voting_right: Option<bool>,
    pub start_date: Option<Date>,
    pub end_date: Option<Date>,
    pub on_behalf_of: Option<OrganizationId>,
    pub keyword: Option<Vec<String>>,
    pub license: Option<String>,
    pub web: Option<String>,
}
