text string | file_path string | module string | type string | tokens int64 | language string | struct_name string | type_name string | trait_name string | impl_type string | function_name string | source string | section string | keys list | macro_type string | url string | title string | chunk_index int64 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
impl api::PayoutCancel for Ebanx {} | crates/hyperswitch_connectors/src/connectors/ebanx.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Ebanx | api::PayoutCancel for | impl api::PayoutCancel for for Ebanx | null | null | null | null | null | null | null | null |
pub fn update_merchant_creation_status_in_decision_engine(&mut self, is_created: bool) {
self.is_merchant_created_in_decision_engine = is_created;
} | crates/api_models/src/routing.rs | api_models | function_signature | 35 | rust | null | null | null | null | update_merchant_creation_status_in_decision_engine | null | null | null | null | null | null | null |
File: crates/hyperswitch_domain_models/src/api.rs
Public functions: 1
Public structs: 7
use std::{collections::HashSet, fmt::Display};
use common_utils::{
events::{ApiEventMetric, ApiEventsType},
impl_api_event_type,
};
use super::payment_method_data::PaymentMethodData;
#[derive(Debug, PartialEq)]
pub enu... | crates/hyperswitch_domain_models/src/api.rs | hyperswitch_domain_models | full_file | 1,002 | null | null | null | null | null | null | null | null | null | null | null | null | null |
File: crates/euclid/src/dssa.rs
//! Domain Specific Static Analyzer
pub mod analyzer;
pub mod graph;
pub mod state_machine;
pub mod truth;
pub mod types;
pub mod utils;
| crates/euclid/src/dssa.rs | euclid | full_file | 42 | null | null | null | null | null | null | null | null | null | null | null | null | null |
impl<Secret: ZeroizableSecret, MaskingStrategy> Default for StrongSecret<Secret, MaskingStrategy>
where
Secret: ZeroizableSecret + Default,
{
fn default() -> Self {
Secret::default().into()
}
} | crates/masking/src/strong_secret.rs | masking | impl_block | 52 | rust | null | StrongSecret | Default for | impl Default for for StrongSecret | null | null | null | null | null | null | null | null |
impl api::PaymentsCompleteAuthorize for Powertranz {} | crates/hyperswitch_connectors/src/connectors/powertranz.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Powertranz | api::PaymentsCompleteAuthorize for | impl api::PaymentsCompleteAuthorize for for Powertranz | null | null | null | null | null | null | null | null |
pub async fn set_config(state: SessionState, config: api::Config) -> RouterResponse<api::Config> {
let store = state.store.as_ref();
let config = store
.insert_config(diesel_models::configs::ConfigNew {
key: config.key,
config: config.value,
})
.await
.to_... | crates/router/src/core/configs.rs | router | function_signature | 111 | rust | null | null | null | null | set_config | null | null | null | null | null | null | null |
pub struct BlackhawknetworkRouterData<T> {
pub amount: StringMajorUnit,
pub router_data: T,
} | crates/hyperswitch_connectors/src/connectors/blackhawknetwork/transformers.rs | hyperswitch_connectors | struct_definition | 26 | rust | BlackhawknetworkRouterData | null | null | null | null | null | null | null | null | null | null | null |
pub struct CalculateTax; | crates/hyperswitch_domain_models/src/router_flow_types/payments.rs | hyperswitch_domain_models | struct_definition | 5 | rust | CalculateTax | null | null | null | null | null | null | null | null | null | null | null |
impl api::Payment for Paytm {} | crates/hyperswitch_connectors/src/connectors/paytm.rs | hyperswitch_connectors | impl_block | 8 | rust | null | Paytm | api::Payment for | impl api::Payment for for Paytm | null | null | null | null | null | null | null | null |
pub async fn find_by_merchant_id_event_id(
conn: &PgPooledConn,
merchant_id: &common_utils::id_type::MerchantId,
event_id: &str,
) -> StorageResult<Self> {
generics::generic_find_one::<<Self as HasTable>::Table, _, _>(
conn,
dsl::merchant_id
.e... | crates/diesel_models/src/query/events.rs | diesel_models | function_signature | 108 | rust | null | null | null | null | find_by_merchant_id_event_id | null | null | null | null | null | null | null |
pub struct OpenIdConnectPrivateConfig {
pub base_url: String,
pub client_id: Secret<String>,
pub client_secret: Secret<String>,
pub private_key: Option<Secret<String>>,
} | crates/api_models/src/user.rs | api_models | struct_definition | 42 | rust | OpenIdConnectPrivateConfig | null | null | null | null | null | null | null | null | null | null | null |
pub async fn call_multiple_connectors_service<F, Op, Req, D>(
state: &SessionState,
merchant_context: &domain::MerchantContext,
connectors: api::SessionConnectorDatas,
_operation: &Op,
mut payment_data: D,
customer: &Option<domain::Customer>,
session_surcharge_details: Option<api::SessionSur... | crates/router/src/core/payments.rs | router | function_signature | 941 | rust | null | null | null | null | call_multiple_connectors_service | null | null | null | null | null | null | null |
impl webhooks::IncomingWebhook for Worldpayvantiv {
fn get_webhook_object_reference_id(
&self,
_request: &webhooks::IncomingWebhookRequestDetails<'_>,
) -> CustomResult<api_models::webhooks::ObjectReferenceId, errors::ConnectorError> {
Err(report!(errors::ConnectorError::WebhooksNotImple... | crates/hyperswitch_connectors/src/connectors/worldpayvantiv.rs | hyperswitch_connectors | impl_block | 212 | rust | null | Worldpayvantiv | webhooks::IncomingWebhook for | impl webhooks::IncomingWebhook for for Worldpayvantiv | null | null | null | null | null | null | null | null |
File: crates/kgraph_utils/src/mca.rs
Public functions: 1
#[cfg(feature = "v1")]
use std::str::FromStr;
#[cfg(feature = "v1")]
use api_models::payment_methods::RequestPaymentMethodTypes;
use api_models::{admin as admin_api, enums as api_enums, refunds::MinorUnit};
use euclid::{
dirval,
frontend::{ast, dir},
... | crates/kgraph_utils/src/mca.rs#chunk0 | kgraph_utils | chunk | 8,191 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct WorldlineRefundRequest {
amount_of_money: AmountOfMoney,
} | crates/hyperswitch_connectors/src/connectors/worldline/transformers.rs | hyperswitch_connectors | struct_definition | 18 | rust | WorldlineRefundRequest | null | null | null | null | null | null | null | null | null | null | null |
pub async fn update_v1_and_v2_user_roles_in_db(
state: &SessionState,
user_id: &str,
tenant_id: &id_type::TenantId,
org_id: &id_type::OrganizationId,
merchant_id: Option<&id_type::MerchantId>,
profile_id: Option<&id_type::ProfileId>,
update: UserRoleUpdate,
) -> (
Result<UserRole, Report... | crates/router/src/utils/user_role.rs | router | function_signature | 295 | rust | null | null | null | null | update_v1_and_v2_user_roles_in_db | null | null | null | null | null | null | null |
pub struct EbanxRouterData<T> {
pub amount: FloatMajorUnit, // The type of amount that a connector accepts, for example, String, i64, f64, etc.
pub router_data: T,
} | crates/hyperswitch_connectors/src/connectors/ebanx/transformers.rs | hyperswitch_connectors | struct_definition | 51 | rust | EbanxRouterData | null | null | null | null | null | null | null | null | null | null | null |
pub struct SdkPaymentsSessionUpdateData {
pub order_tax_amount: MinorUnit,
// amount here would include amount, surcharge_amount, order_tax_amount and shipping_cost
pub amount: MinorUnit,
/// original amount sent by the merchant
pub order_amount: MinorUnit,
pub currency: storage_enums::Currency,... | crates/hyperswitch_domain_models/src/router_request_types.rs | hyperswitch_domain_models | struct_definition | 90 | rust | SdkPaymentsSessionUpdateData | null | null | null | null | null | null | null | null | null | null | null |
impl Responder {
let flow = Flow::PayoutLinkInitiate;
let (merchant_id, payout_id) = path.into_inner();
let payload = PayoutLinkInitiateRequest {
merchant_id: merchant_id.clone(),
payout_id,
};
let headers = req.headers();
Box::pin(api::server_wrap(
flow,
state,
... | crates/router/src/routes/payout_link.rs | router | impl_block | 172 | rust | null | Responder | null | impl Responder | null | null | null | null | null | null | null | null |
pub trait ApiEventMetric<T>
where
T: AnalyticsDataSource + ApiEventMetricAnalytics,
{
async fn load_metrics(
&self,
dimensions: &[ApiEventDimensions],
merchant_id: &common_utils::id_type::MerchantId,
filters: &ApiEventFilters,
granularity: Option<Granularity>,
tim... | crates/analytics/src/api_event/metrics.rs | analytics | trait_definition | 104 | rust | null | null | ApiEventMetric | null | null | null | null | null | null | null | null | null |
pub struct ClientProcessorInformation {
network_transaction_id: Option<String>,
avs: Option<Avs>,
card_verification: Option<CardVerification>,
merchant_advice: Option<MerchantAdvice>,
response_code: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/cybersource/transformers.rs | hyperswitch_connectors | struct_definition | 49 | rust | ClientProcessorInformation | null | null | null | null | null | null | null | null | null | null | null |
impl Responder {
let flow = Flow::PaymentsSessionToken;
let payload = json_payload.into_inner();
let header_payload = match HeaderPayload::foreign_try_from(req.headers()) {
Ok(headers) => headers,
Err(error) => {
logger::error!(
?error,
"Failed to... | crates/router/src/routes/payments.rs | router | impl_block | 308 | rust | null | Responder | null | impl Responder | null | null | null | null | null | null | null | null |
pub async fn insert(self, conn: &PgPooledConn) -> StorageResult<Relay> {
generics::generic_insert(conn, self).await
} | crates/diesel_models/src/query/relay.rs | diesel_models | function_signature | 35 | rust | null | null | null | null | insert | null | null | null | null | null | null | null |
pub fn read(db_table: &Value) -> Result<Self, toml::de::Error> {
db_table.clone().try_into()
} | crates/hsdev/src/input_file.rs | hsdev | function_signature | 31 | rust | null | null | null | null | read | null | null | null | null | null | null | null |
pub fn get_tax_processor_config(
connector: TaxConnectors,
) -> Result<Option<ConnectorTomlConfig>, String> {
let connector_data = Self::new()?;
match connector {
TaxConnectors::Taxjar => Ok(connector_data.taxjar),
}
} | crates/connector_configs/src/connector.rs | connector_configs | function_signature | 60 | rust | null | null | null | null | get_tax_processor_config | null | null | null | null | null | null | null |
pub fn get_jwt_from_authorization_header(headers: &HeaderMap) -> RouterResult<&str> {
headers
.get(headers::AUTHORIZATION)
.get_required_value(headers::AUTHORIZATION)?
.to_str()
.change_context(errors::ApiErrorResponse::InternalServerError)
.attach_printable("Failed to conver... | crates/router/src/services/authentication.rs | router | function_signature | 95 | rust | null | null | null | null | get_jwt_from_authorization_header | null | null | null | null | null | null | null |
pub struct ShoppingCart {
pub items: Vec<Item>,
} | crates/hyperswitch_connectors/src/connectors/multisafepay/transformers.rs | hyperswitch_connectors | struct_definition | 12 | rust | ShoppingCart | null | null | null | null | null | null | null | null | null | null | null |
impl api::PaymentAuthorize for Nomupay {} | crates/hyperswitch_connectors/src/connectors/nomupay.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Nomupay | api::PaymentAuthorize for | impl api::PaymentAuthorize for for Nomupay | null | null | null | null | null | null | null | null |
impl ApiErrorResponse {
pub(crate) fn get_internal_error(&self) -> &ApiError {
match self {
Self::Unauthorized(i)
| Self::ForbiddenCommonResource(i)
| Self::ForbiddenPrivateResource(i)
| Self::Conflict(i)
| Self::Gone(i)
| Self::Unproce... | crates/api_models/src/errors/types.rs | api_models | impl_block | 396 | rust | null | ApiErrorResponse | null | impl ApiErrorResponse | null | null | null | null | null | null | null | null |
impl api::Payment for Billwerk {} | crates/hyperswitch_connectors/src/connectors/billwerk.rs | hyperswitch_connectors | impl_block | 8 | rust | null | Billwerk | api::Payment for | impl api::Payment for for Billwerk | null | null | null | null | null | null | null | null |
pub struct RoutingEventsWrapper<Req>
where
Req: Serialize + Clone,
{
pub tenant_id: id_type::TenantId,
pub request_id: Option<RequestId>,
pub payment_id: String,
pub profile_id: id_type::ProfileId,
pub merchant_id: id_type::MerchantId,
pub flow: String,
pub request: Option<Req>,
pub ... | crates/router/src/core/payments/routing/utils.rs | router | struct_definition | 109 | rust | RoutingEventsWrapper | null | null | null | null | null | null | null | null | null | null | null |
pub fn new(to_factor: Decimal, from_factor: Decimal) -> Self {
Self {
to_factor,
from_factor,
}
} | crates/currency_conversion/src/types.rs | currency_conversion | function_signature | 31 | rust | null | null | null | null | new | null | null | null | null | null | null | null |
pub fn get_enable_payment_response_hash(&self) -> bool {
self.enable_payment_response_hash.unwrap_or(true)
} | crates/api_models/src/admin.rs | api_models | function_signature | 25 | rust | null | null | null | null | get_enable_payment_response_hash | null | null | null | null | null | null | null |
pub struct DashboardMetadataNew {
pub user_id: Option<String>,
pub merchant_id: id_type::MerchantId,
pub org_id: id_type::OrganizationId,
pub data_key: enums::DashboardMetadata,
pub data_value: Secret<serde_json::Value>,
pub created_by: String,
pub created_at: PrimitiveDateTime,
pub last... | crates/diesel_models/src/user/dashboard_metadata.rs | diesel_models | struct_definition | 91 | rust | DashboardMetadataNew | null | null | null | null | null | null | null | null | null | null | null |
pub trait RefundDistributionAnalytics: LoadRow<RefundDistributionRow> {} | crates/analytics/src/refunds/distribution.rs | analytics | trait_definition | 16 | rust | null | null | RefundDistributionAnalytics | null | null | null | null | null | null | null | null | null |
impl api::PaymentToken for Fiserv {} | crates/hyperswitch_connectors/src/connectors/fiserv.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Fiserv | api::PaymentToken for | impl api::PaymentToken for for Fiserv | null | null | null | null | null | null | null | null |
File: crates/scheduler/src/consumer/workflows.rs
use async_trait::async_trait;
use common_utils::errors::CustomResult;
pub use diesel_models::process_tracker as storage;
use diesel_models::process_tracker::business_status;
use router_env::logger;
use crate::{errors, SchedulerSessionState};
pub type WorkflowSelectorF... | crates/scheduler/src/consumer/workflows.rs | scheduler | full_file | 609 | null | null | null | null | null | null | null | null | null | null | null | null | null |
}
fn get_off_session(
mandate_id: Option<&MandateIds>,
off_session_flag: Option<bool>,
) -> Option<bool> {
match (mandate_id, off_session_flag) {
(_, Some(false)) => Some(false),
(Some(_), _) | (_, Some(true)) => Some(true),
(None, None) => None,
}
}
#[cfg(feature = "v1")]
impl... | crates/router/src/core/payments/transformers.rs#chunk4 | router | chunk | 8,188 | null | null | null | null | null | null | null | null | null | null | null | null | null |
File: crates/external_services/src/hubspot_proxy.rs
Public functions: 1
Public structs: 1
use masking::Secret;
/// Lead source constant for Hubspot
pub const HUBSPOT_LEAD_SOURCE: &str = "Hyperswitch Dashboard";
/// Struct representing a request to Hubspot
#[derive(Clone, Debug, serde::Serialize, Default)]
pub stru... | crates/external_services/src/hubspot_proxy.rs | external_services | full_file | 488 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct PaymentMetaData {
payment_reference: String,
} | crates/hyperswitch_connectors/src/connectors/gocardless/transformers.rs | hyperswitch_connectors | struct_definition | 12 | rust | PaymentMetaData | null | null | null | null | null | null | null | null | null | null | null |
pub struct RazorpayPaymentsResponse {
pub razorpay_payment_id: String,
} | crates/hyperswitch_connectors/src/connectors/razorpay/transformers.rs | hyperswitch_connectors | struct_definition | 17 | rust | RazorpayPaymentsResponse | null | null | null | null | null | null | null | null | null | null | null |
OpenAPI Block Path: paths."/payments/{payment_id}/cancel_post_capture"
{
"post": {
"tags": [
"Payments"
],
"summary": "Payments - Cancel Post Capture",
"description": "A Payment could can be cancelled when it is in one of these statuses: `succeeded`, `partially_captured`, `partially_captured_and... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 365 | .json | null | null | null | null | null | openapi_spec | paths | [
"/payments/{payment_id}/cancel_post_capture"
] | null | null | null | null |
impl ConnectorRedirectResponse for Worldpay {
fn get_flow_type(
&self,
_query_params: &str,
_json_payload: Option<serde_json::Value>,
action: PaymentAction,
) -> CustomResult<enums::CallConnectorAction, errors::ConnectorError> {
match action {
PaymentAction::C... | crates/hyperswitch_connectors/src/connectors/worldpay.rs | hyperswitch_connectors | impl_block | 117 | rust | null | Worldpay | ConnectorRedirectResponse for | impl ConnectorRedirectResponse for for Worldpay | null | null | null | null | null | null | null | null |
pub struct WiseRouterData<T> {
pub amount: FloatMajorUnit,
pub router_data: T,
} | crates/hyperswitch_connectors/src/connectors/wise/transformers.rs | hyperswitch_connectors | struct_definition | 24 | rust | WiseRouterData | null | null | null | null | null | null | null | null | null | null | null |
File: crates/router/tests/connectors/globepay.rs
use masking::Secret;
use router::types::{self, domain, storage::enums};
use crate::{
connector_auth,
utils::{self, ConnectorActions},
};
#[derive(Clone, Copy)]
struct GlobepayTest;
impl ConnectorActions for GlobepayTest {}
impl utils::Connector for GlobepayTes... | crates/router/tests/connectors/globepay.rs | router | full_file | 2,938 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct CheckoutAuthType {
pub(super) api_key: Secret<String>,
pub(super) processing_channel_id: Secret<String>,
pub(super) api_secret: Secret<String>,
} | crates/hyperswitch_connectors/src/connectors/checkout/transformers.rs | hyperswitch_connectors | struct_definition | 38 | rust | CheckoutAuthType | null | null | null | null | null | null | null | null | null | null | null |
File: crates/hyperswitch_connectors/src/connectors/dwolla/transformers.rs
Public functions: 1
Public structs: 20
use common_enums::{enums, AttemptStatus};
use common_utils::{errors::CustomResult, types::StringMajorUnit};
use error_stack::{report, ResultExt};
use hyperswitch_domain_models::{
payment_method_data::... | crates/hyperswitch_connectors/src/connectors/dwolla/transformers.rs | hyperswitch_connectors | full_file | 4,591 | null | null | null | null | null | null | null | null | null | null | null | null | null |
Web Documentation: Revenue Recovery | Hyperswitch
# Type: Web Doc
Revenue Recovery module of Hyperswitch is designed to act as a failsafe for recurring payments. It seamlessly integrates with merchants' existing subscription management systems and performs intelligent retries to recover failed transactions. With minim... | https://docs.hyperswitch.io/about-hyperswitch/payments-modules/revenue-recovery | null | web_doc_file | 477 | doc | null | null | null | null | null | web | null | null | null | https://docs.hyperswitch.io/about-hyperswitch/payments-modules/revenue-recovery | Revenue Recovery | Hyperswitch | null |
pub struct QueryResponse {
response: SyncResponse,
} | crates/hyperswitch_connectors/src/connectors/bamboraapac/transformers.rs | hyperswitch_connectors | struct_definition | 12 | rust | QueryResponse | null | null | null | null | null | null | null | null | null | null | null |
File: crates/hyperswitch_connectors/src/connectors/digitalvirgo/transformers.rs
Public structs: 11
use common_enums::enums;
use common_utils::types::FloatMajorUnit;
use error_stack::ResultExt;
use hyperswitch_domain_models::{
payment_method_data::{MobilePaymentData, PaymentMethodData},
router_data::{Connector... | crates/hyperswitch_connectors/src/connectors/digitalvirgo/transformers.rs | hyperswitch_connectors | full_file | 2,530 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct AvgTicketSize; | crates/api_models/src/analytics/payments.rs | api_models | struct_definition | 6 | rust | AvgTicketSize | null | null | null | null | null | null | null | null | null | null | null |
impl api::PaymentAuthorize for Chargebee {} | crates/hyperswitch_connectors/src/connectors/chargebee.rs | hyperswitch_connectors | impl_block | 9 | rust | null | Chargebee | api::PaymentAuthorize for | impl api::PaymentAuthorize for for Chargebee | null | null | null | null | null | null | null | null |
impl api::MandateSetup for Bitpay {} | crates/hyperswitch_connectors/src/connectors/bitpay.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Bitpay | api::MandateSetup for | impl api::MandateSetup for for Bitpay | null | null | null | null | null | null | null | null |
File: crates/common_types/src/lib.rs
//! Types shared across the request/response types and database types
#![warn(missing_docs, missing_debug_implementations)]
pub mod consts;
pub mod customers;
pub mod domain;
pub mod payment_methods;
pub mod payments;
/// types that are wrappers around primitive types
pub mod pri... | crates/common_types/src/lib.rs | common_types | full_file | 101 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct Authenticate; | crates/hyperswitch_domain_models/src/router_flow_types/unified_authentication_service.rs | hyperswitch_domain_models | struct_definition | 4 | rust | Authenticate | null | null | null | null | null | null | null | null | null | null | null |
pub struct Health; | crates/router/src/bin/scheduler.rs | router | struct_definition | 4 | rust | Health | null | null | null | null | null | null | null | null | null | null | null |
pub(crate) fn should_call_connector_for_dispute_sync(
force_sync: Option<bool>,
dispute_status: storage_enums::DisputeStatus,
) -> bool {
force_sync == Some(true)
&& matches!(
dispute_status,
common_enums::DisputeStatus::DisputeAccepted
| common_enums::Dispute... | crates/router/src/core/disputes.rs | router | function_signature | 96 | rust | null | null | null | null | should_call_connector_for_dispute_sync | null | null | null | null | null | null | null |
let item = data.0;
let mandate_metadata = item
.request
.mandate_id
.as_ref()
.and_then(|mandate_id| mandate_id.mandate_reference_id.as_ref())
.and_then(|reference_id| match reference_id {
payments::MandateReferenceId::Connecto... | crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs#chunk2 | hyperswitch_connectors | chunk | 8,189 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub async fn get_payment_filters(
state: SessionState,
merchant_context: domain::MerchantContext,
profile_id_list: Option<Vec<id_type::ProfileId>>,
) -> RouterResponse<api::PaymentListFiltersV2> {
let merchant_connector_accounts = if let services::ApplicationResponse::Json(data) =
super::admin::... | crates/router/src/core/payments.rs | router | function_signature | 605 | rust | null | null | null | null | get_payment_filters | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.BankRedirectBilling
{
"type": "object",
"required": [
"billing_name",
"email"
],
"properties": {
"billing_name": {
"type": "string",
"description": "The name for which billing is issued",
"example": "John Doe"
},
"email": {
"type... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 116 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"BankRedirectBilling"
] | null | null | null | null |
pub async fn get_decrypted_vault_response_payload(
jwekey: &settings::Jwekey,
jwe_body: encryption::JweBody,
decryption_scheme: settings::DecryptionScheme,
) -> CustomResult<String, errors::VaultError> {
let public_key = jwekey.vault_encryption_key.peek().as_bytes();
let private_key = jwekey.vault_... | crates/router/src/core/payment_methods/transformers.rs | router | function_signature | 326 | rust | null | null | null | null | get_decrypted_vault_response_payload | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.BancontactBankRedirectAdditionalData
{
"type": "object",
"properties": {
"last4": {
"type": "string",
"description": "Last 4 digits of the card number",
"example": "4242",
"nullable": true
},
"card_exp_month": {
"type": "string",
... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 200 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"BancontactBankRedirectAdditionalData"
] | null | null | null | null |
pub async fn update_by_id(
conn: &PgPooledConn,
id: id_type::GlobalCustomerId,
customer: CustomerUpdateInternal,
) -> StorageResult<Self> {
match generics::generic_update_by_id::<<Self as HasTable>::Table, _, _, _>(
conn,
id.clone(),
customer,
... | crates/diesel_models/src/query/customers.rs | diesel_models | function_signature | 145 | rust | null | null | null | null | update_by_id | null | null | null | null | null | null | null |
pub struct CardSecurityCode(StrongSecret<u16>); | crates/cards/src/lib.rs | cards | struct_definition | 13 | rust | CardSecurityCode | null | null | null | null | null | null | null | null | null | null | null |
Documentation: api-reference/v1/merchant-account/merchant-account--retrieve.mdx
# Type: Doc File
---
openapi: get /accounts/{account_id}
--- | api-reference/v1/merchant-account/merchant-account--retrieve.mdx | null | doc_file | 35 | doc | null | null | null | null | null | null | null | null | null | null | null | null |
Documentation: api-reference/v1/event/events--list.mdx
# Type: Doc File
---
openapi: post /events/{merchant_id}
--- | api-reference/v1/event/events--list.mdx | null | doc_file | 31 | doc | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct DummyConnectorRouterData<T> {
pub amount: MinorUnit,
pub router_data: T,
} | crates/hyperswitch_connectors/src/connectors/dummyconnector/transformers.rs | hyperswitch_connectors | struct_definition | 24 | rust | DummyConnectorRouterData | null | null | null | null | null | null | null | null | null | null | null |
Web Documentation: Advanced Development Env Setup | Hyperswitch
# Type: Web Doc
These setup guides are meant for development. If you want a quick trial of Hyperswitch (without contributing), use
this guide
.
Setup Guides
Hyperswitch Backend
SDK (Frontend)
Control Center
Hyperswitch Components
Hyperswitch is built as a... | https://docs.hyperswitch.io/hyperswitch-open-source/readme-1/local-setup-using-individual-components | null | web_doc_file | 442 | doc | null | null | null | null | null | web | null | null | null | https://docs.hyperswitch.io/hyperswitch-open-source/readme-1/local-setup-using-individual-components | Advanced Development Env Setup | Hyperswitch | null |
pub async fn trigger_refund_outgoing_webhook(
state: &SessionState,
merchant_context: &domain::MerchantContext,
refund: &diesel_models::Refund,
profile_id: id_type::ProfileId,
) -> RouterResult<()> {
let refund_status = refund.refund_status;
let key_manager_state = &(state).into();
let busi... | crates/router/src/utils.rs | router | function_signature | 418 | rust | null | null | null | null | trigger_refund_outgoing_webhook | null | null | null | null | null | null | null |
impl IncomingWebhook for Datatrans {
fn get_webhook_object_reference_id(
&self,
_request: &IncomingWebhookRequestDetails<'_>,
) -> CustomResult<ObjectReferenceId, errors::ConnectorError> {
Err(report!(errors::ConnectorError::WebhooksNotImplemented))
}
fn get_webhook_event_type(
... | crates/hyperswitch_connectors/src/connectors/datatrans.rs | hyperswitch_connectors | impl_block | 186 | rust | null | Datatrans | IncomingWebhook for | impl IncomingWebhook for for Datatrans | null | null | null | null | null | null | null | null |
Documentation: api-reference/v1/gsm/gsm--delete.mdx
# Type: Doc File
---
openapi: post /gsm/delete
--- | api-reference/v1/gsm/gsm--delete.mdx | null | doc_file | 32 | doc | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct DlocalErrorResponse {
pub code: i32,
pub message: String,
pub param: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/dlocal/transformers.rs | hyperswitch_connectors | struct_definition | 28 | rust | DlocalErrorResponse | null | null | null | null | null | null | null | null | null | null | null |
impl api::RefundExecute for Taxjar {} | crates/hyperswitch_connectors/src/connectors/taxjar.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Taxjar | api::RefundExecute for | impl api::RefundExecute for for Taxjar | null | null | null | null | null | null | null | null |
pub fn new() -> &'static Self {
&Self {
amount_converter: &FloatMajorUnitForConnector,
amount_converter_webhooks: &StringMinorUnitForConnector,
}
} | crates/hyperswitch_connectors/src/connectors/rapyd.rs | hyperswitch_connectors | function_signature | 41 | rust | null | null | null | null | new | null | null | null | null | null | null | null |
File: crates/diesel_models/src/query/authentication.rs
Public functions: 4
use diesel::{associations::HasTable, BoolExpressionMethods, ExpressionMethods};
use super::generics;
use crate::{
authentication::{
Authentication, AuthenticationNew, AuthenticationUpdate, AuthenticationUpdateInternal,
},
... | crates/diesel_models/src/query/authentication.rs | diesel_models | full_file | 631 | null | null | null | null | null | null | null | null | null | null | null | null | null |
File: crates/hyperswitch_connectors/src/connectors/coinbase.rs
Public functions: 1
Public structs: 1
pub mod transformers;
use common_enums::enums;
use common_utils::{
crypto,
errors::CustomResult,
ext_traits::ByteSliceExt,
request::{Method, Request, RequestBuilder, RequestContent},
types::{Amou... | crates/hyperswitch_connectors/src/connectors/coinbase.rs | hyperswitch_connectors | full_file | 3,883 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct FetchDisputesRequestData {
pub created_from: time::PrimitiveDateTime,
pub created_till: time::PrimitiveDateTime,
} | crates/hyperswitch_domain_models/src/router_request_types.rs | hyperswitch_domain_models | struct_definition | 31 | rust | FetchDisputesRequestData | null | null | null | null | null | null | null | null | null | null | null |
impl api::PaymentVoid for Santander {} | crates/hyperswitch_connectors/src/connectors/santander.rs | hyperswitch_connectors | impl_block | 9 | rust | null | Santander | api::PaymentVoid for | impl api::PaymentVoid for for Santander | null | null | null | null | null | null | null | null |
pub struct FiuuApplePayData {
#[serde(rename = "TxnChannel")]
txn_channel: TxnChannel,
cc_month: Secret<String>,
cc_year: Secret<String>,
cc_token: CardNumber,
eci: Option<String>,
token_cryptogram: Secret<String>,
token_type: FiuuTokenType,
#[serde(rename = "non_3DS")]
non_3ds: ... | crates/hyperswitch_connectors/src/connectors/fiuu/transformers.rs | hyperswitch_connectors | struct_definition | 95 | rust | FiuuApplePayData | null | null | null | null | null | null | null | null | null | null | null |
pub struct PayeezyAuthType {
pub(super) api_key: Secret<String>,
pub(super) api_secret: Secret<String>,
pub(super) merchant_token: Secret<String>,
} | crates/hyperswitch_connectors/src/connectors/payeezy/transformers.rs | hyperswitch_connectors | struct_definition | 39 | rust | PayeezyAuthType | null | null | null | null | null | null | null | null | null | null | null |
pub struct PaymentMethodSessionUpdateSavedPaymentMethod {
/// The payment method id of the payment method to be updated
#[schema(value_type = String, example = "12345_pm_01926c58bc6e77c09e809964e72af8c8")]
pub payment_method_id: id_type::GlobalPaymentMethodId,
/// The update request for the payment met... | crates/api_models/src/payment_methods.rs | api_models | struct_definition | 116 | rust | PaymentMethodSessionUpdateSavedPaymentMethod | null | null | null | null | null | null | null | null | null | null | null |
pub struct DashboardRequestPayload {
pub connector: api_models::enums::Connector,
pub payment_methods_enabled: Option<Vec<DashboardPaymentMethodPayload>>,
pub metadata: Option<ApiModelMetaData>,
} | crates/connector_configs/src/common_config.rs | connector_configs | struct_definition | 42 | rust | DashboardRequestPayload | null | null | null | null | null | null | null | null | null | null | null |
impl Tokenization {
pub fn is_disabled(&self) -> bool {
self.flag == common_enums::TokenizationFlag::Disabled
}
} | crates/hyperswitch_domain_models/src/tokenization.rs | hyperswitch_domain_models | impl_block | 32 | rust | null | Tokenization | null | impl Tokenization | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.PaymentMethodMetaData
{
"type": "object",
"description": "Represents metadata about the payment method used in the 3DS decision rule.",
"required": [
"card_network"
],
"properties": {
"card_network": {
"$ref": "#/components/schemas/CardNetwork"
}
}
} | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 81 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"PaymentMethodMetaData"
] | null | null | null | null |
pub fn get_current_date_time() -> CustomResult<String, errors::ConnectorError> {
let format = format_description::parse(
"[weekday repr:short], [day] [month repr:short] [year] [hour]:[minute]:[second] GMT",
)
.change_context(errors::ConnectorError::InvalidDateFormat)?;
Offset... | crates/hyperswitch_connectors/src/connectors/worldline.rs | hyperswitch_connectors | function_signature | 98 | rust | null | null | null | null | get_current_date_time | null | null | null | null | null | null | null |
pub async fn new_token(
user_id: String,
merchant_id: id_type::MerchantId,
settings: &Settings,
external_service_type: ExternalServiceType,
) -> UserResult<String> {
let exp_duration = std::time::Duration::from_secs(consts::JWT_TOKEN_TIME_IN_SECS);
let exp = jwt::gene... | crates/router/src/services/authentication.rs | router | function_signature | 122 | rust | null | null | null | null | new_token | null | null | null | null | null | null | null |
File: crates/api_models/src/pm_auth.rs
Public structs: 6
use common_enums::{PaymentMethod, PaymentMethodType};
use common_utils::{
events::{ApiEventMetric, ApiEventsType},
id_type, impl_api_event_type,
};
#[derive(Debug, Clone, serde::Deserialize, serde::Serialize)]
#[serde(rename_all = "snake_case")]
pub st... | crates/api_models/src/pm_auth.rs | api_models | full_file | 470 | null | null | null | null | null | null | null | null | null | null | null | null | null |
impl api::Refund for Affirm {} | crates/hyperswitch_connectors/src/connectors/affirm.rs | hyperswitch_connectors | impl_block | 9 | rust | null | Affirm | api::Refund for | impl api::Refund for for Affirm | null | null | null | null | null | null | null | null |
impl<T, A> EventContext<T, A>
where
A: MessagingInterface<MessageClass = T>,
{
/// Create a new event context.
pub fn new(message_sink: A) -> Self {
Self {
message_sink: Arc::new(message_sink),
metadata: HashMap::new(),
}
}
/// Add metadata to the event conte... | crates/events/src/lib.rs | events | impl_block | 397 | rust | null | EventContext | null | impl EventContext | null | null | null | null | null | null | null | null |
impl api::PaymentToken for Placetopay {} | crates/hyperswitch_connectors/src/connectors/placetopay.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Placetopay | api::PaymentToken for | impl api::PaymentToken for for Placetopay | null | null | null | null | null | null | null | null |
File: crates/storage_impl/src/payouts/payouts.rs
#[cfg(feature = "olap")]
use api_models::enums::PayoutConnectors;
#[cfg(feature = "olap")]
use async_bb8_diesel::{AsyncConnection, AsyncRunQueryDsl};
use common_utils::ext_traits::Encode;
#[cfg(feature = "olap")]
use diesel::{associations::HasTable, ExpressionMethods, Q... | crates/storage_impl/src/payouts/payouts.rs#chunk0 | storage_impl | chunk | 8,191 | null | null | null | null | null | null | null | null | null | null | null | null | null |
File: crates/scheduler/src/metrics.rs
use router_env::{counter_metric, global_meter, histogram_metric_f64};
global_meter!(PT_METER, "PROCESS_TRACKER");
histogram_metric_f64!(CONSUMER_OPS, PT_METER);
counter_metric!(PAYMENT_COUNT, PT_METER); // No. of payments created
counter_metric!(TASKS_PICKED_COUNT, PT_METER); /... | crates/scheduler/src/metrics.rs | scheduler | full_file | 198 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub fn get_cards_bin_records(
form: CardsInfoUpdateForm,
) -> Result<Vec<cards_info_api_types::CardInfoUpdateRequest>, errors::ApiErrorResponse> {
match parse_cards_bin_csv(form.file.data.to_bytes()) {
Ok(records) => Ok(records),
Err(e) => Err(errors::ApiErrorResponse::PreconditionFailed {
... | crates/router/src/core/cards_info.rs | router | function_signature | 84 | rust | null | null | null | null | get_cards_bin_records | null | null | null | null | null | null | null |
pub struct Sharing {
pub code: String,
pub value: f64,
} | crates/hyperswitch_connectors/src/connectors/santander/transformers.rs | hyperswitch_connectors | struct_definition | 19 | rust | Sharing | null | null | null | null | null | null | null | null | null | null | null |
impl api::PaymentVoid for Silverflow {} | crates/hyperswitch_connectors/src/connectors/silverflow.rs | hyperswitch_connectors | impl_block | 9 | rust | null | Silverflow | api::PaymentVoid for | impl api::PaymentVoid for for Silverflow | null | null | null | null | null | null | null | null |
pub struct NTWithNTIRef {
pub network_transaction_id: String,
pub token_exp_month: Option<Secret<String>>,
pub token_exp_year: Option<Secret<String>>,
} | crates/router/src/core/payments.rs | router | struct_definition | 39 | rust | NTWithNTIRef | null | null | null | null | null | null | null | null | null | null | null |
pub async fn api_key_retrieve() {} | crates/openapi/src/routes/api_keys.rs | openapi | function_signature | 9 | rust | null | null | null | null | api_key_retrieve | null | null | null | null | null | null | null |
impl api::ConnectorAccessToken for Noon {} | crates/hyperswitch_connectors/src/connectors/noon.rs | hyperswitch_connectors | impl_block | 8 | rust | null | Noon | api::ConnectorAccessToken for | impl api::ConnectorAccessToken for for Noon | null | null | null | null | null | null | null | null |
pub fn get_pm_authentication_processor_config(key: &str) -> JsResult {
let key: api_model_enums::PmAuthConnectors = api_model_enums::PmAuthConnectors::from_str(key)
.map_err(|_| "Invalid key received".to_string())?;
let res = connector::ConnectorConfig::get_pm_authentication_processor_config(key)?;
... | crates/euclid_wasm/src/lib.rs | euclid_wasm | function_signature | 93 | rust | null | null | null | null | get_pm_authentication_processor_config | null | null | null | null | null | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.