You've already forked AstralRinth
forked from didirus/AstralRinth
* wip: muralpay integration * Basic Mural Pay API bindings * Fix clippy * use dotenvy in muralpay example * Refactor payout creation code * wip: muralpay payout requests * Mural Pay payouts work * Fix clippy * add mural pay fees API * Work on payout fee API * Fees API for more payment methods * Fix CI * Temporarily disable Venmo and PayPal methods from frontend * wip: counterparties * Start on counterparties and payment methods API * Mural Pay multiple methods when fetching * Don't send supported_countries to frontend * Add countries to muralpay fiat methods * Compile fix * Add exchange rate info to fees endpoint * Add fees to premium Tremendous options * Add delivery email field to Tremendous payouts * Add Tremendous product category to payout methods * Add bank details API to muralpay * Fix CI * Fix CI * Remove prepaid visa, compute fees properly for Tremendous methods * Add more details to Tremendous errors * Add fees to Mural * Payout history route and bank details * Re-add legacy PayPal/Venmo options for US * move the mural bank details route * Add utoipa support to payout endpoints * address some PR comments * add CORS to new utoipa routes * Immediately approve mural payouts * Add currency support to Tremendous payouts * Currency forex * add forex to tremendous fee request * Add Mural balance to bank balance info * Add more Tremendous currencies support * Transaction payouts available use the correct date * Address my own review comment * Address PR comments * Change Mural withdrawal limit to 3k * maybe fix tremendous gift cards * Change how Mural minimum withdrawals are calculated * Tweak min/max withdrawal values --------- Co-authored-by: Calum H. <contact@cal.engineer> Co-authored-by: Alejandro González <me@alegon.dev>
75 lines
2.0 KiB
Rust
75 lines
2.0 KiB
Rust
pub use super::ApiError;
|
|
use crate::util::cors::default_cors;
|
|
use actix_web::{HttpResponse, web};
|
|
use serde_json::json;
|
|
|
|
pub mod analytics_get;
|
|
pub mod collections;
|
|
pub mod friends;
|
|
pub mod images;
|
|
pub mod limits;
|
|
pub mod notifications;
|
|
pub mod organizations;
|
|
pub mod payouts;
|
|
pub mod project_creation;
|
|
pub mod projects;
|
|
pub mod reports;
|
|
pub mod shared_instance_version_creation;
|
|
pub mod shared_instances;
|
|
pub mod statistics;
|
|
pub mod tags;
|
|
pub mod teams;
|
|
pub mod threads;
|
|
pub mod users;
|
|
pub mod version_creation;
|
|
pub mod version_file;
|
|
pub mod versions;
|
|
|
|
pub mod oauth_clients;
|
|
|
|
pub fn config(cfg: &mut web::ServiceConfig) {
|
|
cfg.service(
|
|
web::scope("v3")
|
|
.wrap(default_cors())
|
|
.configure(limits::config)
|
|
.configure(collections::config)
|
|
.configure(images::config)
|
|
.configure(notifications::config)
|
|
.configure(organizations::config)
|
|
.configure(project_creation::config)
|
|
.configure(projects::config)
|
|
.configure(reports::config)
|
|
.configure(shared_instance_version_creation::config)
|
|
.configure(shared_instances::config)
|
|
.configure(statistics::config)
|
|
.configure(tags::config)
|
|
.configure(teams::config)
|
|
.configure(threads::config)
|
|
.configure(users::config)
|
|
.configure(version_file::config)
|
|
.configure(versions::config)
|
|
.configure(friends::config),
|
|
);
|
|
}
|
|
|
|
pub fn utoipa_config(
|
|
cfg: &mut utoipa_actix_web::service_config::ServiceConfig,
|
|
) {
|
|
cfg.service(
|
|
utoipa_actix_web::scope("/v3/analytics")
|
|
.wrap(default_cors())
|
|
.configure(analytics_get::config),
|
|
);
|
|
cfg.service(
|
|
utoipa_actix_web::scope("/v3/payout")
|
|
.wrap(default_cors())
|
|
.configure(payouts::config),
|
|
);
|
|
}
|
|
|
|
pub async fn hello_world() -> Result<HttpResponse, ApiError> {
|
|
Ok(HttpResponse::Ok().json(json!({
|
|
"hello": "world",
|
|
})))
|
|
}
|