repo stringlengths 6 65 | file_url stringlengths 81 311 | file_path stringlengths 6 227 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 7
values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-04 15:31:58 2026-01-04 20:25:31 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/payments/payment_attempt.rs | crates/hyperswitch_domain_models/src/payments/payment_attempt.rs | #[cfg(all(feature = "v1", feature = "olap"))]
use api_models::enums::Connector;
use common_enums as storage_enums;
#[cfg(feature = "v2")]
use common_types::payments as common_payments_types;
#[cfg(feature = "v1")]
use common_types::primitive_wrappers::{
ExtendedAuthorizationAppliedBool, OvercaptureEnabledBool, Requ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | true |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/payments/payment_intent.rs | crates/hyperswitch_domain_models/src/payments/payment_intent.rs | use common_types::primitive_wrappers;
#[cfg(feature = "v1")]
use common_utils::consts::PAYMENTS_LIST_MAX_LIMIT_V2;
#[cfg(feature = "v2")]
use common_utils::errors::ParsingError;
#[cfg(feature = "v2")]
use common_utils::ext_traits::{Encode, ValueExt};
use common_utils::{
consts::PAYMENTS_LIST_MAX_LIMIT_V1,
crypt... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | true |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/payments/split_payments.rs | crates/hyperswitch_domain_models/src/payments/split_payments.rs | use api_models::payments::PaymentMethodData;
use common_utils::types::MinorUnit;
#[derive(Clone, Debug)]
pub struct PaymentMethodDetails {
pub payment_method_data: PaymentMethodData,
pub payment_method_type: common_enums::PaymentMethod,
pub payment_method_subtype: common_enums::PaymentMethodType,
}
/// The... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/payouts/payout_attempt.rs | crates/hyperswitch_domain_models/src/payouts/payout_attempt.rs | use api_models::enums::PayoutConnectors;
use common_enums as storage_enums;
use common_utils::{
id_type, payout_method_utils, pii,
types::{UnifiedCode, UnifiedMessage},
};
use serde::{Deserialize, Serialize};
use storage_enums::MerchantStorageScheme;
use time::PrimitiveDateTime;
use super::payouts::Payouts;
#... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/payouts/payouts.rs | crates/hyperswitch_domain_models/src/payouts/payouts.rs | use common_enums as storage_enums;
use common_utils::{id_type, pii, types::MinorUnit};
use serde::{Deserialize, Serialize};
use storage_enums::MerchantStorageScheme;
use time::PrimitiveDateTime;
use super::payout_attempt::PayoutAttempt;
#[cfg(feature = "olap")]
use super::PayoutFetchConstraints;
#[async_trait::async_... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_response_types/fraud_check.rs | crates/hyperswitch_domain_models/src/router_response_types/fraud_check.rs | use serde::Serialize;
use crate::router_response_types::ResponseId;
#[derive(Debug, Clone, Serialize)]
#[serde(untagged)]
pub enum FraudCheckResponseData {
TransactionResponse {
resource_id: ResponseId,
status: diesel_models::enums::FraudCheckStatus,
connector_metadata: Option<serde_json::... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_response_types/disputes.rs | crates/hyperswitch_domain_models/src/router_response_types/disputes.rs | #[derive(Default, Clone, Debug)]
pub struct AcceptDisputeResponse {
pub dispute_status: api_models::enums::DisputeStatus,
pub connector_status: Option<String>,
}
#[derive(Default, Clone, Debug)]
pub struct SubmitEvidenceResponse {
pub dispute_status: api_models::enums::DisputeStatus,
pub connector_stat... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_response_types/revenue_recovery.rs | crates/hyperswitch_domain_models/src/router_response_types/revenue_recovery.rs | use common_utils::types::MinorUnit;
use time::PrimitiveDateTime;
#[derive(Debug, Clone, serde::Deserialize, serde::Serialize)]
pub struct BillingConnectorPaymentsSyncResponse {
/// transaction amount against invoice, accepted in minor unit.
pub amount: MinorUnit,
/// currency of the transaction
pub curr... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_response_types/subscriptions.rs | crates/hyperswitch_domain_models/src/router_response_types/subscriptions.rs | use common_enums::Currency;
use common_utils::{id_type, types::MinorUnit};
use time::PrimitiveDateTime;
#[derive(Debug, Clone)]
pub struct SubscriptionCreateResponse {
pub subscription_id: id_type::SubscriptionId,
pub status: SubscriptionStatus,
pub customer_id: id_type::CustomerId,
pub currency_code: C... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/errors/api_error_response.rs | crates/hyperswitch_domain_models/src/errors/api_error_response.rs | use api_models::errors::types::Extra;
use common_utils::errors::ErrorSwitch;
use http::StatusCode;
use crate::router_data;
#[derive(Clone, Debug, serde::Serialize)]
#[serde(rename_all = "snake_case")]
pub enum ErrorType {
InvalidRequestError,
ObjectNotFound,
RouterError,
ProcessingError,
BadGatewa... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | true |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_request_types/fraud_check.rs | crates/hyperswitch_domain_models/src/router_request_types/fraud_check.rs | use common_utils::{
events::{ApiEventMetric, ApiEventsType},
pii::Email,
};
use diesel_models::types::OrderDetailsWithAmount;
use masking::Secret;
use serde::{Deserialize, Serialize};
use utoipa::ToSchema;
use crate::router_request_types;
#[derive(Debug, Clone)]
pub struct FraudCheckSaleData {
pub amount: ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_request_types/revenue_recovery.rs | crates/hyperswitch_domain_models/src/router_request_types/revenue_recovery.rs | use common_enums::enums;
use crate::connector_endpoints;
#[derive(Debug, Clone)]
pub struct BillingConnectorPaymentsSyncRequest {
/// unique id for making billing connector psync call
pub billing_connector_psync_id: String,
/// connector params of the connector
pub connector_params: connector_endpoint... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_request_types/unified_authentication_service.rs | crates/hyperswitch_domain_models/src/router_request_types/unified_authentication_service.rs | use api_models::payments::DeviceChannel;
use common_enums::MerchantCategoryCode;
use common_types::payments::MerchantCountryCode;
use common_utils::types::MinorUnit;
use masking::Secret;
use crate::address::Address;
#[derive(Clone, Debug)]
pub struct UasPreAuthenticationRequestData {
pub service_details: Option<C... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_request_types/subscriptions.rs | crates/hyperswitch_domain_models/src/router_request_types/subscriptions.rs | use api_models::{payments::Address, subscription};
use common_utils::id_type;
use crate::connector_endpoints;
#[derive(Debug, Clone)]
pub struct SubscriptionItem {
pub item_price_id: String,
pub quantity: Option<u32>,
}
#[derive(Debug, Clone)]
pub struct SubscriptionCreateRequest {
pub customer_id: id_ty... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_request_types/authentication.rs | crates/hyperswitch_domain_models/src/router_request_types/authentication.rs | use common_utils::{ext_traits::OptionExt, pii::Email};
use error_stack::{Report, ResultExt};
use serde::{Deserialize, Serialize};
use crate::{
address, authentication,
errors::api_error_response::ApiErrorResponse,
payment_method_data::{Card, PaymentMethodData},
router_request_types::BrowserInformation,... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs | crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs | use common_utils::{pii, types::MinorUnit};
use crate::{
payment_address::PaymentAddress,
payment_method_data::ApplePayFlow,
router_data::{
AccessToken, ConnectorResponseData, PaymentMethodBalance, PaymentMethodToken,
RecurringMandatePaymentData,
},
};
#[derive(Debug, Clone)]
pub struct... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/vault.rs | crates/hyperswitch_domain_models/src/router_flow_types/vault.rs | #[derive(Debug, Clone)]
pub struct ExternalVaultInsertFlow;
#[derive(Debug, Clone)]
pub struct ExternalVaultRetrieveFlow;
#[derive(Debug, Clone)]
pub struct ExternalVaultDeleteFlow;
#[derive(Debug, Clone)]
pub struct ExternalVaultCreateFlow;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/fraud_check.rs | crates/hyperswitch_domain_models/src/router_flow_types/fraud_check.rs | #[derive(Debug, Clone)]
pub struct Sale;
#[derive(Debug, Clone)]
pub struct Checkout;
#[derive(Debug, Clone)]
pub struct Transaction;
#[derive(Debug, Clone)]
pub struct Fulfillment;
#[derive(Debug, Clone)]
pub struct RecordReturn;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/refunds.rs | crates/hyperswitch_domain_models/src/router_flow_types/refunds.rs | #[derive(Debug, Clone)]
pub struct Execute;
#[derive(Debug, Clone)]
pub struct RSync;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/access_token_auth.rs | crates/hyperswitch_domain_models/src/router_flow_types/access_token_auth.rs | use serde;
#[derive(Clone, Debug)]
pub struct AccessTokenAuthentication;
#[derive(Clone, Debug, serde::Serialize)]
pub struct AccessTokenAuth;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/revenue_recovery.rs | crates/hyperswitch_domain_models/src/router_flow_types/revenue_recovery.rs | #[derive(Debug, Clone)]
pub struct BillingConnectorPaymentsSync;
#[derive(Debug, Clone)]
pub struct InvoiceRecordBack;
#[derive(Debug, Clone)]
pub struct BillingConnectorInvoiceSync;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/dispute.rs | crates/hyperswitch_domain_models/src/router_flow_types/dispute.rs | #[derive(Debug, Clone)]
pub struct Accept;
#[derive(Debug, Clone)]
pub struct Evidence;
#[derive(Debug, Clone)]
pub struct Defend;
#[derive(Debug, Clone)]
pub struct Fetch;
#[derive(Debug, Clone)]
pub struct Dsync;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/unified_authentication_service.rs | crates/hyperswitch_domain_models/src/router_flow_types/unified_authentication_service.rs | #[derive(Debug, Clone)]
pub struct PreAuthenticate;
#[derive(Debug, Clone)]
pub struct PostAuthenticate;
#[derive(Debug, Clone)]
pub struct AuthenticationConfirmation;
#[derive(Debug, Clone)]
pub struct Authenticate;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/webhooks.rs | crates/hyperswitch_domain_models/src/router_flow_types/webhooks.rs | use serde::Serialize;
#[derive(Clone, Debug)]
pub struct VerifyWebhookSource;
#[derive(Debug, Clone, Serialize)]
pub struct ConnectorMandateDetails {
pub connector_mandate_id: masking::Secret<String>,
}
#[derive(Debug, Clone, Serialize)]
pub struct ConnectorNetworkTxnId(masking::Secret<String>);
impl ConnectorN... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/payouts.rs | crates/hyperswitch_domain_models/src/router_flow_types/payouts.rs | #[derive(Debug, Clone)]
pub struct PoCancel;
#[derive(Debug, Clone)]
pub struct PoCreate;
#[derive(Debug, Clone)]
pub struct PoEligibility;
#[derive(Debug, Clone)]
pub struct PoFulfill;
#[derive(Debug, Clone)]
pub struct PoQuote;
#[derive(Debug, Clone)]
pub struct PoRecipient;
#[derive(Debug, Clone)]
pub struct P... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/mandate_revoke.rs | crates/hyperswitch_domain_models/src/router_flow_types/mandate_revoke.rs | #[derive(Clone, Debug)]
pub struct MandateRevoke;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/subscriptions.rs | crates/hyperswitch_domain_models/src/router_flow_types/subscriptions.rs | use common_enums::connector_enums::InvoiceStatus;
#[derive(Debug, Clone)]
pub struct SubscriptionCreate;
#[derive(Debug, Clone)]
pub struct SubscriptionPause;
#[derive(Debug, Clone)]
pub struct SubscriptionResume;
#[derive(Debug, Clone)]
pub struct SubscriptionCancel;
#[derive(Debug, Clone)]
pub struct GetSubscriptionI... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/authentication.rs | crates/hyperswitch_domain_models/src/router_flow_types/authentication.rs | #[derive(Debug, Clone)]
pub struct PreAuthentication;
#[derive(Debug, Clone)]
pub struct PreAuthenticationVersionCall;
#[derive(Debug, Clone)]
pub struct Authentication;
#[derive(Debug, Clone)]
pub struct PostAuthentication;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/files.rs | crates/hyperswitch_domain_models/src/router_flow_types/files.rs | #[derive(Debug, Clone)]
pub struct Retrieve;
#[derive(Debug, Clone)]
pub struct Upload;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_domain_models/src/router_flow_types/payments.rs | crates/hyperswitch_domain_models/src/router_flow_types/payments.rs | // Core related api layer.
#[derive(Debug, Clone)]
pub struct Authorize;
#[derive(Debug, Clone)]
pub struct AuthorizeSessionToken;
#[derive(Debug, Clone)]
pub struct CompleteAuthorize;
#[derive(Debug, Clone)]
pub struct Approve;
// Used in gift cards balance check
#[derive(Debug, Clone)]
pub struct Balance;
#[deri... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/cards/src/lib.rs | crates/cards/src/lib.rs | pub mod validate;
use std::ops::Deref;
use common_utils::{date_time, errors};
use error_stack::report;
use masking::{PeekInterface, StrongSecret};
use serde::{de, Deserialize, Serialize};
use time::{Date, Duration, PrimitiveDateTime, Time};
pub use crate::validate::{CardNumber, CardNumberStrategy, CardNumberValidatio... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/cards/src/validate.rs | crates/cards/src/validate.rs | use std::{collections::HashMap, fmt, ops::Deref, str::FromStr, sync::LazyLock};
use common_utils::errors::ValidationError;
use error_stack::report;
use masking::{PeekInterface, Strategy, StrongSecret, WithType};
use regex::Regex;
#[cfg(not(target_arch = "wasm32"))]
use router_env::{logger, which as router_env_which, E... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/cards/tests/basic.rs | crates/cards/tests/basic.rs | #![allow(clippy::unwrap_used, clippy::expect_used)]
use cards::{CardExpiration, CardExpirationMonth, CardExpirationYear, CardSecurityCode};
use common_utils::date_time;
use masking::PeekInterface;
#[test]
fn test_card_security_code() {
// no panic
let valid_card_security_code = CardSecurityCode::try_from(1234... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/errors.rs | crates/hyperswitch_interfaces/src/errors.rs | //! Errors interface
use common_enums::ApiClientError;
use common_utils::errors::ErrorSwitch;
use hyperswitch_domain_models::errors::api_error_response::ApiErrorResponse;
/// Connector Errors
#[allow(missing_docs, missing_debug_implementations)]
#[derive(Debug, thiserror::Error, PartialEq)]
pub enum ConnectorError {
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/consts.rs | crates/hyperswitch_interfaces/src/consts.rs | //! connector integration related const declarations
/// No error message string const
pub const NO_ERROR_MESSAGE: &str = "No error message";
/// No error code string const
pub const NO_ERROR_CODE: &str = "No error code";
/// Accepted format for request
pub const ACCEPT_HEADER: &str = "text/html,application/json";
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/connector_integration_v2.rs | crates/hyperswitch_interfaces/src/connector_integration_v2.rs | //! definition of the new connector integration trait
use common_utils::{
errors::CustomResult,
request::{Method, Request, RequestBuilder, RequestContent},
};
use hyperswitch_domain_models::{router_data::ErrorResponse, router_data_v2::RouterDataV2};
use masking::Maskable;
use serde_json::json;
use crate::{
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/lib.rs | crates/hyperswitch_interfaces/src/lib.rs | //! Hyperswitch interface
#![warn(missing_docs, missing_debug_implementations)]
pub mod api;
/// API client interface module
pub mod api_client;
pub mod authentication;
/// Configuration related functionalities
pub mod configs;
/// Connector integration interface module
pub mod connector_integration_interface;
/// def... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/disputes.rs | crates/hyperswitch_interfaces/src/disputes.rs | //! Disputes interface
use common_utils::types::StringMinorUnit;
use hyperswitch_domain_models::router_response_types::DisputeSyncResponse;
use time::PrimitiveDateTime;
/// struct DisputePayload
#[derive(Default, Debug)]
pub struct DisputePayload {
/// amount
pub amount: StringMinorUnit,
/// currency
p... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/secrets_interface.rs | crates/hyperswitch_interfaces/src/secrets_interface.rs | //! Secrets management interface
pub mod secret_handler;
pub mod secret_state;
use common_utils::errors::CustomResult;
use masking::Secret;
/// Trait defining the interface for managing application secrets
#[async_trait::async_trait]
pub trait SecretManagementInterface: Send + Sync {
/*
/// Given an input, ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/helpers.rs | crates/hyperswitch_interfaces/src/helpers.rs | use common_utils::{
consts::{X_CONNECTOR_NAME, X_SUB_FLOW_NAME},
errors as common_utils_errors, request,
};
use error_stack::ResultExt;
use hyperswitch_domain_models::router_data;
use masking;
use router_env::{logger, tracing};
use crate::{api_client, consts, errors, types};
/// Trait for converting from one f... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/encryption_interface.rs | crates/hyperswitch_interfaces/src/encryption_interface.rs | //! Encryption related interface and error types
#![warn(missing_docs, missing_debug_implementations)]
use common_utils::errors::CustomResult;
/// Trait defining the interface for encryption management
#[async_trait::async_trait]
pub trait EncryptionManagementInterface: Sync + Send + dyn_clone::DynClone {
/// En... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/webhooks.rs | crates/hyperswitch_interfaces/src/webhooks.rs | //! Webhooks interface
use common_utils::{crypto, errors::CustomResult, ext_traits::ValueExt};
use error_stack::ResultExt;
use hyperswitch_domain_models::{
api::ApplicationResponse, errors::api_error_response::ApiErrorResponse,
};
use masking::{ExposeInterface, Secret};
use crate::{api::ConnectorCommon, errors};
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api.rs | crates/hyperswitch_interfaces/src/api.rs | //! API interface
/// authentication module
pub mod authentication;
/// authentication_v2 module
pub mod authentication_v2;
pub mod disputes;
pub mod disputes_v2;
pub mod files;
pub mod files_v2;
#[cfg(feature = "frm")]
pub mod fraud_check;
#[cfg(feature = "frm")]
pub mod fraud_check_v2;
pub mod gateway;
pub mod payme... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/types.rs | crates/hyperswitch_interfaces/src/types.rs | //! Types interface
use common_utils::types::Url;
use hyperswitch_domain_models::{
router_data::{AccessToken, AccessTokenAuthenticationResponse},
router_data_v2::flow_common_types,
router_flow_types::{
access_token_auth::AccessTokenAuth,
dispute::{Accept, Defend, Dsync, Evidence, Fetch},
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api_client.rs | crates/hyperswitch_interfaces/src/api_client.rs | use std::{
fmt::Debug,
time::{Duration, Instant},
};
use common_enums::ApiClientError;
use common_utils::{
consts::{X_CONNECTOR_NAME, X_FLOW_NAME, X_REQUEST_ID},
errors::CustomResult,
request::{Request, RequestContent},
};
use error_stack::{report, ResultExt};
use http::Method;
use hyperswitch_doma... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/authentication.rs | crates/hyperswitch_interfaces/src/authentication.rs | //! Authentication interface
/// struct ExternalAuthenticationPayload
#[derive(Clone, serde::Deserialize, Debug, serde::Serialize, PartialEq, Eq)]
pub struct ExternalAuthenticationPayload {
/// trans_status
pub trans_status: common_enums::TransactionStatus,
/// authentication_value
pub authentication_v... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/events.rs | crates/hyperswitch_interfaces/src/events.rs | use crate::events::connector_api_logs::ConnectorEvent;
pub mod connector_api_logs;
pub mod routing_api_logs;
/// Event handling interface
#[async_trait::async_trait]
pub trait EventHandlerInterface: dyn_clone::DynClone
where
Self: Send + Sync,
{
/// Logs connector events
#[track_caller]
fn log_connect... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/metrics.rs | crates/hyperswitch_interfaces/src/metrics.rs | //! Metrics interface
use router_env::{counter_metric, global_meter};
global_meter!(GLOBAL_METER, "ROUTER_API");
counter_metric!(UNIMPLEMENTED_FLOW, GLOBAL_METER);
counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed
counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER);
counter_metr... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/connector_integration_interface.rs | crates/hyperswitch_interfaces/src/connector_integration_interface.rs | use api_models::webhooks::{IncomingWebhookEvent, ObjectReferenceId};
use common_enums::PaymentAction;
use common_utils::{crypto, errors::CustomResult, request::Request};
use hyperswitch_domain_models::{
api::ApplicationResponse,
connector_endpoints::Connectors,
errors::api_error_response::ApiErrorResponse,
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | true |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/configs.rs | crates/hyperswitch_interfaces/src/configs.rs | use common_utils::{crypto::Encryptable, errors::CustomResult, id_type};
pub use hyperswitch_domain_models::{
connector_endpoints::Connectors, errors::api_error_response, merchant_connector_account,
};
use masking::{PeekInterface, Secret};
use serde::Deserialize;
#[allow(missing_docs)]
#[derive(Debug, Clone)]
pub s... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/crm.rs | crates/hyperswitch_interfaces/src/crm.rs | use common_enums::CountryAlpha2;
use common_utils::{
errors::CustomResult,
request::{Request, RequestContent},
};
use masking::Secret;
use super::types::Proxy;
use crate::errors::HttpClientError;
/// Crm Payload structure
#[derive(Clone, Debug, serde::Serialize, Default)]
pub struct CrmPayload {
/// The l... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/conversion_impls.rs | crates/hyperswitch_interfaces/src/conversion_impls.rs | use common_utils::{errors::CustomResult, id_type};
use error_stack::ResultExt;
#[cfg(feature = "frm")]
use hyperswitch_domain_models::router_data_v2::flow_common_types::FrmFlowData;
#[cfg(feature = "payouts")]
use hyperswitch_domain_models::router_data_v2::flow_common_types::PayoutFlowData;
use hyperswitch_domain_model... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | true |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/integrity.rs | crates/hyperswitch_interfaces/src/integrity.rs | use common_utils::errors::IntegrityCheckError;
use hyperswitch_domain_models::router_request_types::{
AuthoriseIntegrityObject, CaptureIntegrityObject, PaymentsAuthorizeData, PaymentsCaptureData,
PaymentsSyncData, RefundIntegrityObject, RefundsData, SyncIntegrityObject,
};
/// Connector Integrity trait to chec... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/unified_connector_service.rs | crates/hyperswitch_interfaces/src/unified_connector_service.rs | use common_enums::AttemptStatus;
use common_utils::errors::CustomResult;
use error_stack::ResultExt;
use hyperswitch_domain_models::{
router_data::ErrorResponse, router_response_types::PaymentsResponseData,
};
use unified_connector_service_client::payments as payments_grpc;
use crate::helpers::ForeignTryFrom;
///... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/unified_connector_service/transformers.rs | crates/hyperswitch_interfaces/src/unified_connector_service/transformers.rs | use common_enums::AttemptStatus;
use common_types::primitive_wrappers::{ExtendedAuthorizationAppliedBool, OvercaptureEnabledBool};
use hyperswitch_domain_models::{
router_data::{
AdditionalPaymentMethodConnectorResponse, ConnectorResponseData, ErrorResponse,
ExtendedAuthorizationResponseData,
},... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/secrets_interface/secret_state.rs | crates/hyperswitch_interfaces/src/secrets_interface/secret_state.rs | //! Module to manage encrypted and decrypted states for a given type.
use std::marker::PhantomData;
use serde::{Deserialize, Deserializer};
/// Trait defining the states of a secret
pub trait SecretState {}
/// Decrypted state
#[derive(Debug, Clone, Deserialize, Default)]
pub struct RawSecret {}
/// Encrypted stat... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/secrets_interface/secret_handler.rs | crates/hyperswitch_interfaces/src/secrets_interface/secret_handler.rs | //! Module containing trait for raw secret retrieval
use common_utils::errors::CustomResult;
use crate::secrets_interface::{
secret_state::{RawSecret, SecretStateContainer, SecuredSecret},
SecretManagementInterface, SecretsManagementError,
};
/// Trait defining the interface for retrieving a raw secret value... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/refunds_v2.rs | crates/hyperswitch_interfaces/src/api/refunds_v2.rs | //! Refunds V2 interface
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::RefundFlowData,
router_flow_types::refunds::{Execute, RSync},
router_request_types::RefundsData,
router_response_types::RefundsResponseData,
};
use crate::api::{ConnectorCommon, ConnectorIntegrationV2};
/// t... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/vault.rs | crates/hyperswitch_interfaces/src/api/vault.rs | //! Vault interface
use hyperswitch_domain_models::{
router_flow_types::vault::{
ExternalVaultCreateFlow, ExternalVaultDeleteFlow, ExternalVaultInsertFlow,
ExternalVaultRetrieveFlow,
},
router_request_types::VaultRequestData,
router_response_types::VaultResponseData,
};
use super::Conn... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/vault_v2.rs | crates/hyperswitch_interfaces/src/api/vault_v2.rs | //! Vault V2 interface
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::VaultConnectorFlowData,
router_flow_types::vault::{
ExternalVaultCreateFlow, ExternalVaultDeleteFlow, ExternalVaultInsertFlow,
ExternalVaultRetrieveFlow,
},
router_request_types::VaultRequestData,
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/fraud_check.rs | crates/hyperswitch_interfaces/src/api/fraud_check.rs | //! FRM interface
use hyperswitch_domain_models::{
router_flow_types::{Checkout, Fulfillment, RecordReturn, Sale, Transaction},
router_request_types::fraud_check::{
FraudCheckCheckoutData, FraudCheckFulfillmentData, FraudCheckRecordReturnData,
FraudCheckSaleData, FraudCheckTransactionData,
}... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/payments_v2.rs | crates/hyperswitch_interfaces/src/api/payments_v2.rs | //! Payments V2 interface
use hyperswitch_domain_models::{
router_data_v2::{flow_common_types::GiftCardBalanceCheckFlowData, PaymentFlowData},
router_flow_types::{
payments::{
Approve, Authorize, AuthorizeSessionToken, CalculateTax, Capture, CompleteAuthorize,
CreateConnectorCus... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/payouts_v2.rs | crates/hyperswitch_interfaces/src/api/payouts_v2.rs | //! Payouts V2 interface
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::PayoutFlowData,
router_flow_types::payouts::{
PoCancel, PoCreate, PoEligibility, PoFulfill, PoQuote, PoRecipient, PoRecipientAccount,
PoSync,
},
router_request_types::PayoutsData,
router_resp... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/refunds.rs | crates/hyperswitch_interfaces/src/api/refunds.rs | //! Refunds interface
use hyperswitch_domain_models::{
router_flow_types::{Execute, RSync},
router_request_types::RefundsData,
router_response_types::RefundsResponseData,
};
use crate::api::{self, ConnectorCommon};
/// trait RefundExecute
pub trait RefundExecute:
api::ConnectorIntegration<Execute, Re... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs | crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs | //! SubscriptionsV2
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::{
GetSubscriptionEstimateData, GetSubscriptionItemPricesData, GetSubscriptionItemsData,
InvoiceRecordBackData, SubscriptionCancelData, SubscriptionCreateData,
SubscriptionCustomerData, SubscriptionPauseDa... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/disputes.rs | crates/hyperswitch_interfaces/src/api/disputes.rs | //! Disputes interface
use hyperswitch_domain_models::{
router_flow_types::dispute::{Accept, Defend, Dsync, Evidence, Fetch},
router_request_types::{
AcceptDisputeRequestData, DefendDisputeRequestData, DisputeSyncData,
FetchDisputesRequestData, SubmitEvidenceRequestData,
},
router_respo... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/revenue_recovery.rs | crates/hyperswitch_interfaces/src/api/revenue_recovery.rs | //! Revenue Recovery Interface
use hyperswitch_domain_models::{
router_flow_types::{
BillingConnectorInvoiceSync, BillingConnectorPaymentsSync, InvoiceRecordBack,
},
router_request_types::revenue_recovery::{
BillingConnectorInvoiceSyncRequest, BillingConnectorPaymentsSyncRequest,
In... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/payouts.rs | crates/hyperswitch_interfaces/src/api/payouts.rs | //! Payouts interface
use hyperswitch_domain_models::{
router_flow_types::payouts::{
PoCancel, PoCreate, PoEligibility, PoFulfill, PoQuote, PoRecipient, PoRecipientAccount,
PoSync,
},
router_request_types::PayoutsData,
router_response_types::PayoutsResponseData,
};
use super::Connector... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/gateway.rs | crates/hyperswitch_interfaces/src/api/gateway.rs | //! Gateway abstraction layer for unified connector execution
//!
//! This module provides a unified interface for executing payment operations through either:
//! - Direct connector integration (traditional HTTP-based)
//! - Unified Connector Service (UCS) via gRPC
//!
//! The gateway abstraction allows seamless switc... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/files_v2.rs | crates/hyperswitch_interfaces/src/api/files_v2.rs | //! Files V2 interface
use hyperswitch_domain_models::{
router_data_v2::FilesFlowData,
router_flow_types::{Retrieve, Upload},
router_request_types::{RetrieveFileRequestData, UploadFileRequestData},
router_response_types::{RetrieveFileResponse, UploadFileResponse},
};
use crate::api::{errors, files::Fi... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/fraud_check_v2.rs | crates/hyperswitch_interfaces/src/api/fraud_check_v2.rs | //! FRM V2 interface
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::FrmFlowData,
router_flow_types::{Checkout, Fulfillment, RecordReturn, Sale, Transaction},
router_request_types::fraud_check::{
FraudCheckCheckoutData, FraudCheckFulfillmentData, FraudCheckRecordReturnData,
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/authentication_v2.rs | crates/hyperswitch_interfaces/src/api/authentication_v2.rs | use hyperswitch_domain_models::{
router_data_v2::ExternalAuthenticationFlowData,
router_flow_types::authentication::{
Authentication, PostAuthentication, PreAuthentication, PreAuthenticationVersionCall,
},
router_request_types::authentication::{
ConnectorAuthenticationRequestData, Connec... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/revenue_recovery_v2.rs | crates/hyperswitch_interfaces/src/api/revenue_recovery_v2.rs | //! Revenue Recovery Interface V2
use hyperswitch_domain_models::{
router_data_v2::flow_common_types::{
BillingConnectorInvoiceSyncFlowData, BillingConnectorPaymentsSyncFlowData,
InvoiceRecordBackData,
},
router_flow_types::{
BillingConnectorInvoiceSync, BillingConnectorPaymentsSync... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/subscriptions.rs | crates/hyperswitch_interfaces/src/api/subscriptions.rs | //! Subscriptions Interface for V1
use hyperswitch_domain_models::{
router_flow_types::{
subscriptions::{
GetSubscriptionEstimate, GetSubscriptionItemPrices, GetSubscriptionItems,
SubscriptionCreate as SubscriptionCreateFlow,
},
InvoiceRecordBack,
},
router_r... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/authentication.rs | crates/hyperswitch_interfaces/src/api/authentication.rs | use hyperswitch_domain_models::{
router_flow_types::authentication::{
Authentication, PostAuthentication, PreAuthentication, PreAuthenticationVersionCall,
},
router_request_types::authentication::{
ConnectorAuthenticationRequestData, ConnectorPostAuthenticationRequestData,
PreAuthNRe... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/files.rs | crates/hyperswitch_interfaces/src/api/files.rs | //! Files interface
use hyperswitch_domain_models::{
router_flow_types::files::{Retrieve, Upload},
router_request_types::{RetrieveFileRequestData, UploadFileRequestData},
router_response_types::{RetrieveFileResponse, UploadFileResponse},
};
use crate::{
api::{ConnectorCommon, ConnectorIntegration},
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/disputes_v2.rs | crates/hyperswitch_interfaces/src/api/disputes_v2.rs | //! Disputes V2 interface
use hyperswitch_domain_models::{
router_data_v2::DisputesFlowData,
router_flow_types::dispute::{Accept, Defend, Dsync, Evidence, Fetch},
router_request_types::{
AcceptDisputeRequestData, DefendDisputeRequestData, DisputeSyncData,
FetchDisputesRequestData, SubmitEvid... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/api/payments.rs | crates/hyperswitch_interfaces/src/api/payments.rs | //! Payments interface
use hyperswitch_domain_models::{
router_flow_types::{
payments::{
Approve, Authorize, AuthorizeSessionToken, CalculateTax, Capture, CompleteAuthorize,
CreateConnectorCustomer, ExtendAuthorization, IncrementalAuthorization, PSync,
PaymentMethodToken... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/events/routing_api_logs.rs | crates/hyperswitch_interfaces/src/events/routing_api_logs.rs | //! Routing API logs interface
use std::fmt;
use api_models::routing::RoutableConnectorChoice;
use common_utils::request::Method;
use router_env::RequestId;
use serde::Serialize;
use serde_json::json;
use time::OffsetDateTime;
/// RoutingEngine enum
#[derive(Debug, Clone, Copy, Serialize)]
#[serde(rename_all = "snak... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/hyperswitch_interfaces/src/events/connector_api_logs.rs | crates/hyperswitch_interfaces/src/events/connector_api_logs.rs | //! Connector API logs interface
use common_utils::request::Method;
use router_env::RequestId;
use serde::Serialize;
use serde_json::json;
use time::OffsetDateTime;
/// struct ConnectorEvent
#[derive(Debug, Serialize)]
pub struct ConnectorEvent {
tenant_id: common_utils::id_type::TenantId,
connector_name: Str... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/lib.rs | crates/router_derive/src/lib.rs | //! Utility macros for the `router` crate.
#![warn(missing_docs)]
use syn::parse_macro_input;
use crate::macros::diesel::DieselEnumMeta;
mod macros;
/// Uses the [`Debug`][Debug] implementation of a type to derive its [`Display`][Display]
/// implementation.
///
/// Causes a compilation error if the type doesn't impl... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros.rs | crates/router_derive/src/macros.rs | pub(crate) mod api_error;
pub(crate) mod diesel;
pub(crate) mod generate_permissions;
pub(crate) mod generate_schema;
pub(crate) mod misc;
pub(crate) mod operation;
pub(crate) mod schema;
pub(crate) mod to_encryptable;
pub(crate) mod try_get_enum;
mod helpers;
use proc_macro2::TokenStream;
use quote::quote;
use syn::... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/try_get_enum.rs | crates/router_derive/src/macros/try_get_enum.rs | use proc_macro2::Span;
use quote::ToTokens;
use syn::{parse::Parse, punctuated::Punctuated};
mod try_get_keyword {
use syn::custom_keyword;
custom_keyword!(error_type);
}
#[derive(Debug)]
pub struct TryGetEnumMeta {
error_type: syn::Ident,
variant: syn::Ident,
}
impl Parse for TryGetEnumMeta {
f... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/misc.rs | crates/router_derive/src/macros/misc.rs | pub fn get_field_type(field_type: syn::Type) -> Option<syn::Ident> {
if let syn::Type::Path(path) = field_type {
path.path
.segments
.last()
.map(|last_path_segment| last_path_segment.ident.to_owned())
} else {
None
}
}
/// Implement the `validate` functi... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/generate_schema.rs | crates/router_derive/src/macros/generate_schema.rs | use std::collections::{HashMap, HashSet};
use indexmap::IndexMap;
use syn::{self, parse::Parse, parse_quote, punctuated::Punctuated, Token};
use crate::macros::helpers;
/// Parse schemas from attribute
/// Example
///
/// #[mandatory_in(PaymentsCreateRequest, PaymentsUpdateRequest)]
/// would return
///
/// [Payment... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/helpers.rs | crates/router_derive/src/macros/helpers.rs | use proc_macro2::Span;
use quote::ToTokens;
use syn::{parse::Parse, punctuated::Punctuated, spanned::Spanned, Attribute, Token};
pub fn non_enum_error() -> syn::Error {
syn::Error::new(Span::call_site(), "This macro only supports enums.")
}
pub(super) fn occurrence_error<T: ToTokens>(
first_keyword: T,
se... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/to_encryptable.rs | crates/router_derive/src/macros/to_encryptable.rs | use std::iter::Iterator;
use quote::{format_ident, quote};
use syn::{parse::Parse, punctuated::Punctuated, token::Comma, Field, Ident, Type as SynType};
use crate::macros::{helpers::get_struct_fields, misc::get_field_type};
pub struct FieldMeta {
_meta_type: Ident,
pub value: Ident,
}
impl Parse for FieldMe... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/schema.rs | crates/router_derive/src/macros/schema.rs | mod helpers;
use quote::quote;
use crate::macros::{
helpers as macro_helpers,
schema::helpers::{HasSchemaParameters, IsSchemaFieldApplicableForValidation},
};
pub fn validate_schema_derive(input: syn::DeriveInput) -> syn::Result<proc_macro2::TokenStream> {
let name = &input.ident;
// Extract struct ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/generate_permissions.rs | crates/router_derive/src/macros/generate_permissions.rs | use proc_macro::TokenStream;
use quote::{format_ident, quote};
use syn::{
braced, bracketed,
parse::{Parse, ParseBuffer, ParseStream},
parse_macro_input,
punctuated::Punctuated,
token::Comma,
Ident, Token,
};
struct ResourceInput {
resource_name: Ident,
scopes: Punctuated<Ident, Token![... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/api_error.rs | crates/router_derive/src/macros/api_error.rs | mod helpers;
use std::collections::HashMap;
use proc_macro2::TokenStream;
use quote::quote;
use syn::{
punctuated::Punctuated, token::Comma, Data, DeriveInput, Fields, Ident, ImplGenerics,
TypeGenerics, Variant, WhereClause,
};
use crate::macros::{
api_error::helpers::{
check_missing_attributes, ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/diesel.rs | crates/router_derive/src/macros/diesel.rs | use proc_macro2::{Span, TokenStream};
use quote::{format_ident, quote, ToTokens};
use syn::{parse::Parse, Data, DeriveInput, ItemEnum};
use crate::macros::helpers;
pub(crate) fn diesel_enum_text_derive_inner(ast: &DeriveInput) -> syn::Result<TokenStream> {
let name = &ast.ident;
let (impl_generics, ty_generic... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/operation.rs | crates/router_derive/src/macros/operation.rs | use std::str::FromStr;
use proc_macro2::{Span, TokenStream};
use quote::{quote, ToTokens};
use strum::IntoEnumIterator;
use syn::{self, parse::Parse, DeriveInput};
use crate::macros::helpers;
#[derive(Debug, Clone, Copy, strum::EnumString, strum::EnumIter, strum::Display)]
#[strum(serialize_all = "snake_case")]
pub ... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/schema/helpers.rs | crates/router_derive/src/macros/schema/helpers.rs | use proc_macro2::TokenStream;
use quote::ToTokens;
use syn::{parse::Parse, Field, LitInt, LitStr, Token, TypePath};
use crate::macros::helpers::{get_metadata_inner, occurrence_error};
mod keyword {
use syn::custom_keyword;
// Schema metadata
custom_keyword!(value_type);
custom_keyword!(min_length);
... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/router_derive/src/macros/api_error/helpers.rs | crates/router_derive/src/macros/api_error/helpers.rs | use proc_macro2::TokenStream;
use quote::ToTokens;
use syn::{
parse::Parse, spanned::Spanned, DeriveInput, Field, Fields, LitStr, Token, TypePath, Variant,
};
use crate::macros::helpers::{get_metadata_inner, occurrence_error};
mod keyword {
use syn::custom_keyword;
// Enum metadata
custom_keyword!(er... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/smithy-core/src/lib.rs | crates/smithy-core/src/lib.rs | // // crates/smithy-core/lib.rs
pub mod generator;
pub mod types;
pub use generator::SmithyGenerator;
pub use types::*;
| rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/smithy-core/src/types.rs | crates/smithy-core/src/types.rs | // crates/smithy-core/types.rs
use std::collections::HashMap;
use serde::{Deserialize, Serialize};
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct SmithyModel {
pub namespace: String,
pub shapes: HashMap<String, SmithyShape>,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(tag = "type")... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/smithy-core/src/generator.rs | crates/smithy-core/src/generator.rs | // crates/smithy-core/generator.rs
use std::{collections::HashMap, fs, path::Path};
use crate::types::{self as types, SmithyModel};
/// Generator for creating Smithy IDL files from models
pub struct SmithyGenerator {
models: Vec<SmithyModel>,
}
impl SmithyGenerator {
pub fn new() -> Self {
Self { mo... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/common_utils/src/errors.rs | crates/common_utils/src/errors.rs | //! Errors and error specific types for universal use
use serde::Serialize;
use crate::types::MinorUnit;
/// Custom Result
/// A custom datatype that wraps the error variant <E> into a report, allowing
/// error_stack::Report<E> specific extendability
///
/// Effectively, equivalent to `Result<T, error_stack::Report... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/common_utils/src/consts.rs | crates/common_utils/src/consts.rs | //! Commonly used constants
/// Number of characters in a generated ID
pub const ID_LENGTH: usize = 20;
/// Characters to use for generating NanoID
pub(crate) const ALPHABETS: [char; 62] = [
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i',
'j', 'k', 'l', 'm', 'n',... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
juspay/hyperswitch | https://github.com/juspay/hyperswitch/blob/4201e04a8f0f1d46b57f24868f4f943a9be50bda/crates/common_utils/src/payout_method_utils.rs | crates/common_utils/src/payout_method_utils.rs | //! This module has common utilities for payout method data in HyperSwitch
use diesel::{sql_types::Jsonb, AsExpression, FromSqlRow};
use masking::Secret;
use serde::{Deserialize, Serialize};
use utoipa::ToSchema;
use crate::new_type::{
MaskedBankAccount, MaskedBic, MaskedEmail, MaskedIban, MaskedPhoneNumber, Mask... | rust | Apache-2.0 | 4201e04a8f0f1d46b57f24868f4f943a9be50bda | 2026-01-04T15:31:59.475325Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.