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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
pub struct CustomerDefaultPaymentMethodResponse {
/// The unique identifier of the Payment method
#[schema(example = "card_rGK4Vi5iSW70MY7J2mIg")]
pub default_payment_method_id: Option<String>,
/// The unique identifier of the customer.
#[schema(value_type = String, max_length = 64, min_length = 1, ... | crates/api_models/src/payment_methods.rs | api_models | struct_definition | 200 | rust | CustomerDefaultPaymentMethodResponse | null | null | null | null | null | null | null | null | null | null | null |
pub struct PaymentGetIntent; | crates/router/src/core/payments/operations/payment_get_intent.rs | router | struct_definition | 6 | rust | PaymentGetIntent | null | null | null | null | null | null | null | null | null | null | null |
pub struct UserTransferKeyResponse {
pub total_transferred: usize,
} | crates/api_models/src/user.rs | api_models | struct_definition | 16 | rust | UserTransferKeyResponse | null | null | null | null | null | null | null | null | null | null | null |
pub fn is_transaction_event(event: &Shift4WebhookEvent) -> bool {
matches!(
event,
Shift4WebhookEvent::ChargeCaptured
| Shift4WebhookEvent::ChargeFailed
| Shift4WebhookEvent::ChargeSucceeded
| Shift4WebhookEvent::ChargeUpdated
)
} | crates/hyperswitch_connectors/src/connectors/shift4/transformers.rs | hyperswitch_connectors | function_signature | 71 | rust | null | null | null | null | is_transaction_event | null | null | null | null | null | null | null |
impl Configs {
pub fn server(config: AppState) -> Scope {
web::scope("/v2/configs")
.app_data(web::Data::new(config))
.service(web::resource("/").route(web::post().to(config_key_create)))
.service(
web::resource("/{key}")
.route(web::ge... | crates/router/src/routes/app.rs | router | impl_block | 107 | rust | null | Configs | null | impl Configs | null | null | null | null | null | null | null | null |
pub fn get_connector_customer_id(
&self,
merchant_connector_account: &MerchantConnectorAccountTypeDetails,
) -> Option<&str> {
match merchant_connector_account {
MerchantConnectorAccountTypeDetails::MerchantConnectorAccount(account) => {
let connector_account_id =... | crates/hyperswitch_domain_models/src/customer.rs | hyperswitch_domain_models | function_signature | 114 | rust | null | null | null | null | get_connector_customer_id | null | null | null | null | null | null | null |
impl api::PaymentsPreProcessing for Barclaycard {} | crates/hyperswitch_connectors/src/connectors/barclaycard.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Barclaycard | api::PaymentsPreProcessing for | impl api::PaymentsPreProcessing for for Barclaycard | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.SurchargePercentage
{
"type": "object",
"required": [
"percentage"
],
"properties": {
"percentage": {
"type": "number",
"format": "float"
}
}
} | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 61 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"SurchargePercentage"
] | null | null | null | null |
impl ProcessTracker {
#[instrument(skip(conn))]
pub async fn update(
self,
conn: &PgPooledConn,
process: ProcessTrackerUpdate,
) -> StorageResult<Self> {
match generics::generic_update_by_id::<<Self as HasTable>::Table, _, _, _>(
conn,
self.id.clone(),... | crates/diesel_models/src/query/process_tracker.rs | diesel_models | impl_block | 805 | rust | null | ProcessTracker | null | impl ProcessTracker | null | null | null | null | null | null | null | null |
pub fn server(state: AppState) -> Scope {
let mut route = web::scope("/v2/customers").app_data(web::Data::new(state));
#[cfg(all(feature = "olap", feature = "v2"))]
{
route = route
.service(web::resource("/list").route(web::get().to(customers::customers_list)))
... | crates/router/src/routes/app.rs | router | function_signature | 254 | rust | null | null | null | null | server | null | null | null | null | null | null | null |
impl api::MandateSetup for Getnet {} | crates/hyperswitch_connectors/src/connectors/getnet.rs | hyperswitch_connectors | impl_block | 11 | rust | null | Getnet | api::MandateSetup for | impl api::MandateSetup for for Getnet | null | null | null | null | null | null | null | null |
pub async fn merchant_account_retrieve() {} | crates/openapi/src/routes/merchant_account.rs | openapi | function_signature | 9 | rust | null | null | null | null | merchant_account_retrieve | null | null | null | null | null | null | null |
File: crates/scheduler/src/settings.rs
Public functions: 2
Public structs: 3
use common_utils::ext_traits::ConfigExt;
use serde::Deserialize;
use storage_impl::errors::ApplicationError;
pub use crate::configs::settings::SchedulerSettings;
#[derive(Debug, Clone, Deserialize)]
pub struct ProducerSettings {
pub u... | crates/scheduler/src/settings.rs | scheduler | full_file | 545 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct PaymentMethodCollectLinkRenderRequest {
/// Unique identifier for a merchant.
#[schema(example = "merchant_1671528864", value_type = String)]
pub merchant_id: id_type::MerchantId,
/// The unique identifier for the collect link.
#[schema(value_type = String, example = "pm_collect_link_2bd... | crates/api_models/src/payment_methods.rs | api_models | struct_definition | 104 | rust | PaymentMethodCollectLinkRenderRequest | null | null | null | null | null | null | null | null | null | null | null |
pub fn get_merchant_category_code_with_name() -> JsResult {
let merchant_category_codes_with_name = MerchantCategoryCode::iter()
.map(|mcc_value| MerchantCategoryCodeWithName {
code: mcc_value,
name: mcc_value.to_merchant_category_name(),
})
.collect::<Vec<_>>();
... | crates/euclid_wasm/src/lib.rs | euclid_wasm | function_signature | 91 | rust | null | null | null | null | get_merchant_category_code_with_name | null | null | null | null | null | null | null |
pub async fn upload_file_to_theme_bucket(
state: &SessionState,
path: &PathBuf,
data: Vec<u8>,
) -> UserResult<()> {
state
.theme_storage_client
.upload_file(path_buf_to_str(path)?, data)
.await
.change_context(UserErrors::ErrorUploadingFile)
} | crates/router/src/utils/user/theme.rs | router | function_signature | 75 | rust | null | null | null | null | upload_file_to_theme_bucket | null | null | null | null | null | null | null |
pub fn construct_event_builder(
self,
url: String,
routing_engine: routing_events::RoutingEngine,
method: routing_events::ApiMethod,
) -> RoutingResult<Self> {
let mut wrapper = self;
let request = wrapper
.request
.clone()
.ok_or(e... | crates/router/src/core/payments/routing/utils.rs | router | function_signature | 247 | rust | null | null | null | null | construct_event_builder | null | null | null | null | null | null | null |
pub async fn find_by_merchant_id_file_id(
conn: &PgPooledConn,
merchant_id: &common_utils::id_type::MerchantId,
file_id: &str,
) -> StorageResult<Self> {
generics::generic_find_one::<<Self as HasTable>::Table, _, _>(
conn,
dsl::merchant_id
.eq(... | crates/diesel_models/src/query/file.rs | diesel_models | function_signature | 108 | rust | null | null | null | null | find_by_merchant_id_file_id | null | null | null | null | null | null | null |
File: crates/diesel_models/src/query/reverse_lookup.rs
Public functions: 3
use diesel::{associations::HasTable, ExpressionMethods};
use super::generics;
use crate::{
reverse_lookup::{ReverseLookup, ReverseLookupNew},
schema::reverse_lookup::dsl,
PgPooledConn, StorageResult,
};
impl ReverseLookupNew {
... | crates/diesel_models/src/query/reverse_lookup.rs | diesel_models | full_file | 242 | null | null | null | null | null | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.PaymentExperience
{
"type": "string",
"description": "To indicate the type of payment experience that the customer would go through",
"enum": [
"redirect_to_url",
"invoke_sdk_client",
"display_qr_code",
"one_click",
"link_wallet",
"invoke_payment_app"... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 93 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"PaymentExperience"
] | null | null | null | null |
File: crates/hyperswitch_connectors/src/connectors/phonepe.rs
Public functions: 1
Public structs: 1
pub mod transformers;
use common_enums::enums;
use common_utils::{
errors::CustomResult,
ext_traits::BytesExt,
request::{Method, Request, RequestBuilder, RequestContent},
types::{AmountConvertor, Stri... | crates/hyperswitch_connectors/src/connectors/phonepe.rs | hyperswitch_connectors | full_file | 4,855 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub async fn signup_token_only_flow(
state: SessionState,
request: user_api::SignUpRequest,
) -> UserResponse<user_api::TokenResponse> {
let user_email = domain::UserEmail::from_pii_email(request.email.clone())?;
utils::user::validate_email_domain_auth_type_using_db(
&state,
&user_email,... | crates/router/src/core/user.rs | router | function_signature | 303 | rust | null | null | null | null | signup_token_only_flow | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.PayoutListConstraints
{
"allOf": [
{
"allOf": [
{
"$ref": "#/components/schemas/TimeRange"
}
],
"nullable": true
},
{
"type": "object",
"properties": {
"customer_id": {
"type": "string",
... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 375 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"PayoutListConstraints"
] | null | null | null | null |
impl ActivePaymentsMetricAccumulator for CountAccumulator {
type MetricOutput = Option<u64>;
#[inline]
fn add_metrics_bucket(&mut self, metrics: &ActivePaymentsMetricRow) {
self.count = match (self.count, metrics.count) {
(None, None) => None,
(None, i @ Some(_)) | (i @ Some(... | crates/analytics/src/active_payments/accumulator.rs | analytics | impl_block | 142 | rust | null | CountAccumulator | ActivePaymentsMetricAccumulator for | impl ActivePaymentsMetricAccumulator for for CountAccumulator | null | null | null | null | null | null | null | null |
pub struct PaymentRequestNetworkToken {
pub amount: StringMajorUnit,
pub currency: enums::Currency,
pub pan: NetworkTokenNumber,
#[serde(rename = "exp")]
pub expiry_date: Secret<String>,
#[serde(rename = "RedirectUrl")]
pub redirect_url: String,
#[serde(rename = "threeDSecureEnrollmentSt... | crates/hyperswitch_connectors/src/connectors/trustpay/transformers.rs | hyperswitch_connectors | struct_definition | 142 | rust | PaymentRequestNetworkToken | null | null | null | null | null | null | null | null | null | null | null |
pub struct NmiPaymentsRequest {
#[serde(rename = "type")]
transaction_type: TransactionType,
amount: FloatMajorUnit,
security_key: Secret<String>,
currency: Currency,
#[serde(flatten)]
payment_method: PaymentMethod,
#[serde(flatten)]
merchant_defined_field: Option<NmiMerchantDefinedF... | crates/hyperswitch_connectors/src/connectors/nmi/transformers.rs | hyperswitch_connectors | struct_definition | 102 | rust | NmiPaymentsRequest | null | null | null | null | null | null | null | null | null | null | null |
pub struct FrmFilterRow {
pub frm_status: Option<DBEnumWrapper<FraudCheckStatus>>,
pub frm_transaction_type: Option<DBEnumWrapper<FrmTransactionType>>,
pub frm_name: Option<String>,
} | crates/analytics/src/frm/filters.rs | analytics | struct_definition | 46 | rust | FrmFilterRow | null | null | null | null | null | null | null | null | null | null | null |
pub async fn signin_token_only_flow(
state: SessionState,
request: user_api::SignInRequest,
) -> UserResponse<user_api::TokenResponse> {
let user_email = domain::UserEmail::from_pii_email(request.email)?;
utils::user::validate_email_domain_auth_type_using_db(
&state,
&user_email,
... | crates/router/src/core/user.rs | router | function_signature | 230 | rust | null | null | null | null | signin_token_only_flow | null | null | null | null | null | null | null |
/// Constructor expecting config path set explicitly.
pub fn new_with_config_path(
explicit_config_path: Option<PathBuf>,
) -> Result<Self, config::ConfigError> {
// Configuration values are picked up in the following priority order (1 being least
// priority):
// 1. Defaults fro... | crates/router_env/src/logger/config.rs | router_env | function_signature | 366 | rust | null | null | null | null | new_with_config_path | null | null | null | null | null | null | null |
pub struct ResponseIndicators {
pub alternate_route_debit_indicator: Option<bool>,
pub signature_line_indicator: Option<bool>,
pub signature_debit_route_indicator: Option<bool>,
} | crates/hyperswitch_connectors/src/connectors/fiserv/transformers.rs | hyperswitch_connectors | struct_definition | 38 | rust | ResponseIndicators | null | null | null | null | null | null | null | null | null | null | null |
self.build_error_response(res, event_builder)
}
}
#[async_trait::async_trait]
impl webhooks::IncomingWebhook for Bankofamerica {
fn get_webhook_object_reference_id(
&self,
_request: &webhooks::IncomingWebhookRequestDetails<'_>,
) -> CustomResult<api_models::webhooks::ObjectReference... | crates/hyperswitch_connectors/src/connectors/bankofamerica.rs#chunk1 | hyperswitch_connectors | chunk | 1,191 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub async fn set_sso_id_in_redis(
state: &SessionState,
oidc_state: Secret<String>,
sso_id: String,
) -> UserResult<()> {
let connection = get_redis_connection_for_global_tenant(state)?;
let key = get_oidc_key(&oidc_state.expose());
connection
.set_key_with_expiry(&key.into(), sso_id, RE... | crates/router/src/utils/user.rs | router | function_signature | 119 | rust | null | null | null | null | set_sso_id_in_redis | null | null | null | null | null | null | null |
pub async fn send_recon_request(
state: SessionState,
auth_data: authentication::AuthenticationDataWithUser,
) -> RouterResponse<recon_api::ReconStatusResponse> {
#[cfg(not(feature = "email"))]
return Ok(service_api::ApplicationResponse::Json(
recon_api::ReconStatusResponse {
recon_s... | crates/router/src/core/recon.rs | router | function_signature | 748 | rust | null | null | null | null | send_recon_request | null | null | null | null | null | null | null |
pub struct CardInfo {
pub card_number: Option<cards::CardNumber>,
pub card_holder_name: Option<Secret<String>>,
pub card_expiry_date: Option<Secret<i32>>,
pub card_cvc: Option<Secret<String>>,
pub flexible_3d: Option<bool>,
pub moto: Option<bool>,
pub term_url: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/multisafepay/transformers.rs | hyperswitch_connectors | struct_definition | 78 | rust | CardInfo | null | null | null | null | null | null | null | null | null | null | null |
pub struct CustomerPaymentMethodListResponse {
pub object: &'static str,
pub data: Vec<PaymentMethodData>,
} | crates/router/src/compatibility/stripe/customers/types.rs | router | struct_definition | 27 | rust | CustomerPaymentMethodListResponse | null | null | null | null | null | null | null | null | null | null | null |
pub struct USBankAccount {
country_code: CountryAlpha2,
account_number: Secret<String>,
bank_code: Secret<String>,
account_type: AccountType,
account_holder_name: Secret<String>,
} | crates/hyperswitch_connectors/src/connectors/gocardless/transformers.rs | hyperswitch_connectors | struct_definition | 44 | rust | USBankAccount | null | null | null | null | null | null | null | null | null | null | null |
Documentation: api-reference/v1/business-profile/business-profile--list.mdx
# Type: Doc File
---
openapi: get /account/{account_id}/business_profile
---
| api-reference/v1/business-profile/business-profile--list.mdx | null | doc_file | 36 | doc | null | null | null | null | null | null | null | null | null | null | null | null |
pub async fn insert_disputes(
conn: &PgPooledConn,
batch: Vec<DisputeNew>,
) -> StorageResult<Vec<Dispute>> {
let query = diesel::insert_into(<Dispute>::table()).values(batch);
logger::debug!(query = %debug_query::<diesel::pg::Pg,_>(&query).to_string());
query
.get_results_async(conn)
... | crates/diesel_models/src/query/user/sample_data.rs | diesel_models | function_signature | 114 | rust | null | null | null | null | insert_disputes | null | null | null | null | null | null | null |
pub fn new() -> &'static Self {
&Self {
amount_converter: &MinorUnitForConnector,
}
} | crates/hyperswitch_connectors/src/connectors/affirm.rs | hyperswitch_connectors | function_signature | 27 | rust | null | null | null | null | new | null | null | null | null | null | null | null |
pub struct DataResponse {
charge_credit_card: AuthChargeCreditCard,
} | crates/hyperswitch_connectors/src/connectors/braintree/transformers.rs | hyperswitch_connectors | struct_definition | 16 | rust | DataResponse | null | null | null | null | null | null | null | null | null | null | null |
pub async fn get_connector_tokenization_action_when_confirm_true<F, Req, D>(
_state: &SessionState,
_operation: &BoxedOperation<'_, F, Req, D>,
payment_data: &mut D,
_validate_result: &operations::ValidateResult,
_merchant_key_store: &domain::MerchantKeyStore,
_customer: &Option<domain::Customer... | crates/router/src/core/payments.rs | router | function_signature | 172 | rust | null | null | null | null | get_connector_tokenization_action_when_confirm_true | null | null | null | null | null | null | null |
pub async fn payouts_list_profile(
state: web::Data<AppState>,
req: HttpRequest,
json_payload: web::Query<payout_types::PayoutListConstraints>,
) -> HttpResponse {
let flow = Flow::PayoutsList;
let payload = json_payload.into_inner();
Box::pin(api::server_wrap(
flow,
state,
... | crates/router/src/routes/payouts.rs | router | function_signature | 239 | rust | null | null | null | null | payouts_list_profile | null | null | null | null | null | null | null |
impl api::PaymentSync for Wise {} | crates/hyperswitch_connectors/src/connectors/wise.rs | hyperswitch_connectors | impl_block | 8 | rust | null | Wise | api::PaymentSync for | impl api::PaymentSync for for Wise | null | null | null | null | null | null | null | null |
pub struct PaystackRefundsResponseData {
status: bool,
message: String,
data: PaystackRefundsData,
} | crates/hyperswitch_connectors/src/connectors/paystack/transformers.rs | hyperswitch_connectors | struct_definition | 29 | rust | PaystackRefundsResponseData | null | null | null | null | null | null | null | null | null | null | null |
Documentation: api-reference/intelligent-router-api-reference/success-rate/fetch-entity-and-global-success-rates.mdx
# Type: Doc File
---
openapi: post /success_rate.SuccessRateCalculator/FetchEntityAndGlobalSuccessRate
--- | api-reference/intelligent-router-api-reference/success-rate/fetch-entity-and-global-success-rates.mdx | null | doc_file | 49 | doc | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct AdminApiAuthWithMerchantIdFromHeader; | crates/router/src/services/authentication.rs | router | struct_definition | 11 | rust | AdminApiAuthWithMerchantIdFromHeader | null | null | null | null | null | null | null | null | null | null | null |
pub struct TokenioAuthType {
pub(super) merchant_id: Secret<String>,
pub(super) private_key: Secret<String>,
pub(super) key_id: Secret<String>,
pub(super) key_algorithm: CryptoAlgorithm,
} | crates/hyperswitch_connectors/src/connectors/tokenio/transformers.rs | hyperswitch_connectors | struct_definition | 48 | rust | TokenioAuthType | null | null | null | null | null | null | null | null | null | null | null |
pub struct GlobalpayCaptureRequest {
pub amount: Option<StringMinorUnit>,
pub capture_sequence: Option<Sequence>,
pub reference: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/globalpay/requests.rs | hyperswitch_connectors | struct_definition | 33 | rust | GlobalpayCaptureRequest | null | null | null | null | null | null | null | null | null | null | null |
pub fn new(org_new: OrganizationNew) -> Self {
let OrganizationNew {
id,
organization_name,
organization_details,
metadata,
created_at,
modified_at,
version,
organization_type,
platform_merchant_id,
... | crates/diesel_models/src/organization.rs | diesel_models | function_signature | 105 | rust | null | null | null | null | new | null | null | null | null | null | null | null |
impl IncomingWebhook for Nmi {
fn get_webhook_source_verification_algorithm(
&self,
_request: &IncomingWebhookRequestDetails<'_>,
) -> CustomResult<Box<dyn crypto::VerifySignature + Send>, ConnectorError> {
Ok(Box::new(crypto::HmacSha256))
}
fn get_webhook_source_verification_si... | crates/hyperswitch_connectors/src/connectors/nmi.rs | hyperswitch_connectors | impl_block | 1,190 | rust | null | Nmi | IncomingWebhook for | impl IncomingWebhook for for Nmi | null | null | null | null | null | null | null | null |
File: crates/test_utils/tests/connectors/main.rs
#![allow(
clippy::expect_used,
clippy::panic,
clippy::unwrap_in_result,
clippy::unwrap_used,
clippy::print_stderr
)]
mod aci_ui;
mod adyen_uk_ui;
mod adyen_uk_wh_ui;
mod airwallex_ui;
mod authorizedotnet_ui;
mod authorizedotnet_wh_ui;
mod bambora_ui;... | crates/test_utils/tests/connectors/main.rs | test_utils | full_file | 190 | null | null | null | null | null | null | null | null | null | null | null | null | null |
impl api::PaymentSync for Helcim {} | crates/hyperswitch_connectors/src/connectors/helcim.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Helcim | api::PaymentSync for | impl api::PaymentSync for for Helcim | null | null | null | null | null | null | null | null |
File: crates/analytics/src/sdk_events/metrics/payment_data_filled_count.rs
use std::collections::HashSet;
use api_models::analytics::{
sdk_events::{
SdkEventDimensions, SdkEventFilters, SdkEventMetricsBucketIdentifier, SdkEventNames,
},
Granularity, TimeRange,
};
use common_utils::errors::ReportSw... | crates/analytics/src/sdk_events/metrics/payment_data_filled_count.rs | analytics | full_file | 798 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct CustomerUpdateInternal {
pub name: Option<Encryption>,
pub email: Option<Encryption>,
pub phone: Option<Encryption>,
pub description: Option<Description>,
pub phone_country_code: Option<String>,
pub metadata: Option<pii::SecretSerdeValue>,
pub modified_at: PrimitiveDateTime,
p... | crates/diesel_models/src/customers.rs | diesel_models | struct_definition | 153 | rust | CustomerUpdateInternal | null | null | null | null | null | null | null | null | null | null | null |
pub async fn create_theme(
state: web::Data<AppState>,
req: HttpRequest,
payload: web::Json<theme_api::CreateThemeRequest>,
) -> HttpResponse {
let flow = Flow::CreateTheme;
let payload = payload.into_inner();
Box::pin(api::server_wrap(
flow,
state,
&req,
payload... | crates/router/src/routes/user/theme.rs | router | function_signature | 121 | rust | null | null | null | null | create_theme | null | null | null | null | null | null | null |
pub fn set_tenancy(&mut self, tenant_config: &dyn TenantConfig) {
self.ckh_database_name = Some(tenant_config.get_clickhouse_database().to_string());
} | crates/router/src/services/kafka.rs | router | function_signature | 40 | rust | null | null | null | null | set_tenancy | null | null | null | null | null | null | null |
pub struct Refunds; | crates/router/src/routes/app.rs | router | struct_definition | 5 | rust | Refunds | null | null | null | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.RefundUpdateRequest
{
"type": "object",
"properties": {
"reason": {
"type": "string",
"description": "An arbitrary string attached to the object. Often useful for displaying to users and your customer support executive",
"example": "Customer returned the ... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 169 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"RefundUpdateRequest"
] | null | null | null | null |
pub struct User {
pub client_user_id: id_type::CustomerId,
} | crates/pm_auth/src/connector/plaid/transformers.rs | pm_auth | struct_definition | 16 | rust | User | null | null | null | null | null | null | null | null | null | null | null |
File: crates/router/src/middleware.rs
Public functions: 1
Public structs: 10
use common_utils::consts::TENANT_HEADER;
use futures::StreamExt;
use router_env::{
logger,
tracing::{field::Empty, Instrument},
};
use crate::{headers, routes::metrics};
/// Middleware to include request ID in response header.
pub... | crates/router/src/middleware.rs | router | full_file | 4,066 | null | null | null | null | null | null | null | null | null | null | null | null | null |
impl api::RefundExecute for Checkbook {} | crates/hyperswitch_connectors/src/connectors/checkbook.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Checkbook | api::RefundExecute for | impl api::RefundExecute for for Checkbook | null | null | null | null | null | null | null | null |
pub struct FraudDetails {
pub final_decision: String,
} | crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs | hyperswitch_connectors | struct_definition | 13 | rust | FraudDetails | null | null | null | null | null | null | null | null | null | null | null |
pub struct CybersourceConsumerAuthInformationResponse {
access_token: String,
device_data_collection_url: String,
reference_id: String,
} | crates/hyperswitch_connectors/src/connectors/cybersource/transformers.rs | hyperswitch_connectors | struct_definition | 31 | rust | CybersourceConsumerAuthInformationResponse | null | null | null | null | null | null | null | null | null | null | null |
File: crates/router/src/services/kafka/dispute.rs
Public functions: 1
Public structs: 1
use common_utils::{
ext_traits::StringExt,
id_type,
types::{AmountConvertor, MinorUnit, StringMinorUnitForConnector},
};
use diesel_models::enums as storage_enums;
use masking::Secret;
use time::OffsetDateTime;
use c... | crates/router/src/services/kafka/dispute.rs | router | full_file | 903 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct HeaderKey {
pub api_key: Secret<String>,
} | crates/test_utils/src/connector_auth.rs | test_utils | struct_definition | 14 | rust | HeaderKey | null | null | null | null | null | null | null | null | null | null | null |
impl api::RefundExecute for Opayo {} | crates/hyperswitch_connectors/src/connectors/opayo.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Opayo | api::RefundExecute for | impl api::RefundExecute for for Opayo | null | null | null | null | null | null | null | null |
impl Responder {
let flow = AnalyticsFlow::GetPaymentFilters;
Box::pin(api::server_wrap(
flow,
state,
&req,
json_payload.into_inner(),
|state, auth: AuthenticationData, req, _| async move {
let org_id = auth.merchant_account.get... | crates/router/src/analytics.rs | router | impl_block | 181 | rust | null | Responder | null | impl Responder | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.PlatformAccountCreateRequest
{
"type": "object",
"required": [
"organization_name"
],
"properties": {
"organization_name": {
"type": "string",
"example": "organization_abc",
"maxLength": 64
}
}
} | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 73 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"PlatformAccountCreateRequest"
] | null | null | null | null |
OpenAPI Block Path: components.schemas.GpayEcryptedTokenizationData
{
"type": "object",
"description": "This struct represents the encrypted Gpay payment data",
"required": [
"type",
"token"
],
"properties": {
"type": {
"type": "string",
"description": "The type of the token"
},
... | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 112 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"GpayEcryptedTokenizationData"
] | null | null | null | null |
pub struct DynamicRoutingStats {
pub payment_id: common_utils::id_type::PaymentId,
pub attempt_id: String,
pub merchant_id: common_utils::id_type::MerchantId,
pub profile_id: common_utils::id_type::ProfileId,
pub amount: common_utils::types::MinorUnit,
pub success_based_routing_connector: String... | crates/diesel_models/src/dynamic_routing_stats.rs | diesel_models | struct_definition | 202 | rust | DynamicRoutingStats | null | null | null | null | null | null | null | null | null | null | null |
File: crates/router/tests/connectors/elavon.rs
use hyperswitch_domain_models::payment_method_data::{Card, PaymentMethodData};
use masking::Secret;
use router::types::{self, api, storage::enums};
use test_utils::connector_auth;
use crate::utils::{self, ConnectorActions};
#[derive(Clone, Copy)]
struct ElavonTest;
impl... | crates/router/tests/connectors/elavon.rs | router | full_file | 2,998 | null | null | null | null | null | null | null | null | null | null | null | null | null |
OpenAPI Block Path: components.schemas.ApplePayThirdPartySdkData
{
"type": "object"
} | ./hyperswitch/api-reference/v1/openapi_spec_v1.json | null | openapi_block | 25 | .json | null | null | null | null | null | openapi_spec | components | [
"schemas",
"ApplePayThirdPartySdkData"
] | null | null | null | null |
pub struct SubError {
pub code: String,
pub message: String,
pub http_status_code: u16,
} | crates/hyperswitch_connectors/src/connectors/payone/transformers.rs | hyperswitch_connectors | struct_definition | 28 | rust | SubError | null | null | null | null | null | null | null | null | null | null | null |
pub struct NexixpayErrorResponse {
pub errors: Vec<NexixpayErrorBody>,
} | crates/hyperswitch_connectors/src/connectors/nexixpay/transformers.rs | hyperswitch_connectors | struct_definition | 20 | rust | NexixpayErrorResponse | null | null | null | null | null | null | null | null | null | null | null |
pub async fn find_by_profile_name_merchant_id(
conn: &PgPooledConn,
profile_name: &str,
merchant_id: &common_utils::id_type::MerchantId,
) -> StorageResult<Self> {
generics::generic_find_one::<<Self as HasTable>::Table, _, _>(
conn,
dsl::profile_name
... | crates/diesel_models/src/query/business_profile.rs | diesel_models | function_signature | 108 | rust | null | null | null | null | find_by_profile_name_merchant_id | null | null | null | null | null | null | null |
impl std::fmt::Display for RedisError {
/// fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
/// match self {
/// Self::UnknownResult => write!(f, "Unknown result")
/// }
/// }
/// } | crates/router_derive/src/lib.rs | router_derive | impl_block | 67 | rust | null | RedisError | std::fmt::Display for | impl std::fmt::Display for for RedisError | null | null | null | null | null | null | null | null |
pub async fn should_call_frm<F, D>(
_merchant_context: &domain::MerchantContext,
_payment_data: &D,
_state: &SessionState,
) -> RouterResult<(
bool,
Option<FrmRoutingAlgorithm>,
Option<common_utils::id_type::ProfileId>,
Option<FrmConfigsObject>,
)>
where
F: Send + Clone,
D: payments:... | crates/router/src/core/fraud_check.rs | router | function_signature | 131 | rust | null | null | null | null | should_call_frm | null | null | null | null | null | null | null |
pub struct PaymentResponse {
ssl_result: SslResult,
ssl_txn_id: String,
ssl_result_message: String,
ssl_token: Option<Secret<String>>,
} | crates/hyperswitch_connectors/src/connectors/elavon/transformers.rs | hyperswitch_connectors | struct_definition | 37 | rust | PaymentResponse | null | null | null | null | null | null | null | null | null | null | null |
pub struct Notification {
pub kind: String, // xml parse only string to fields
pub timestamp: String,
pub dispute: Option<BraintreeDisputeData>,
} | crates/hyperswitch_connectors/src/connectors/braintree/transformers.rs | hyperswitch_connectors | struct_definition | 37 | rust | Notification | null | null | null | null | null | null | null | null | null | null | null |
pub async fn generate_profile_authentication_report(
state: web::Data<AppState>,
req: actix_web::HttpRequest,
json_payload: web::Json<ReportRequest>,
) -> impl Responder {
let flow = AnalyticsFlow::GenerateAuthenticationReport;
Box::pin(api::server_wrap(
flow,
... | crates/router/src/analytics.rs | router | function_signature | 410 | rust | null | null | null | null | generate_profile_authentication_report | null | null | null | null | null | null | null |
File: crates/diesel_models/src/user_role.rs
Public functions: 1
Public structs: 3
use std::hash::Hash;
use common_enums::EntityType;
use common_utils::{consts, id_type};
use diesel::{AsChangeset, Identifiable, Insertable, Queryable, Selectable};
use time::PrimitiveDateTime;
use crate::{enums, schema::user_roles};
... | crates/diesel_models/src/user_role.rs | diesel_models | full_file | 1,061 | null | null | null | null | null | null | null | null | null | null | null | null | null |
pub struct ApiEvent {
tenant_id: common_utils::id_type::TenantId,
merchant_id: Option<common_utils::id_type::MerchantId>,
api_flow: String,
created_at_timestamp: i128,
request_id: String,
latency: u128,
status_code: i64,
#[serde(flatten)]
auth_type: AuthenticationType,
request: S... | crates/router/src/events/api_logs.rs | router | struct_definition | 173 | rust | ApiEvent | null | null | null | null | null | null | null | null | null | null | null |
impl<V> ConstraintGraph<V>
where
V: ValueNode + NodeViz,
<V as ValueNode>::Key: NodeViz,
{
fn get_node_label(node: &types::Node<V>) -> String {
let label = match &node.node_type {
types::NodeType::Value(types::NodeValue::Key(key)) => format!("any {}", key.viz(... | crates/hyperswitch_constraint_graph/src/graph.rs | hyperswitch_constraint_graph | impl_block | 613 | rust | null | ConstraintGraph | null | impl ConstraintGraph | null | null | null | null | null | null | null | null |
/// Here the `self` takes precedence
pub fn unify_with_payment_data_billing(
self,
other_payment_method_billing: Option<Address>,
) -> Self {
let unified_payment_method_billing = self
.get_payment_method_billing()
.map(|payment_method_billing| {
pa... | crates/hyperswitch_domain_models/src/payment_address.rs | hyperswitch_domain_models | function_signature | 128 | rust | null | null | null | null | unify_with_payment_data_billing | null | null | null | null | null | null | null |
pub async fn find_by_merchant_id(
conn: &PgPooledConn,
merchant_id: &common_utils::id_type::MerchantId,
get_disabled: bool,
) -> StorageResult<Vec<Self>> {
if get_disabled {
generics::generic_filter::<<Self as HasTable>::Table, _, _, _>(
conn,
... | crates/diesel_models/src/query/merchant_connector_account.rs | diesel_models | function_signature | 197 | rust | null | null | null | null | find_by_merchant_id | null | null | null | null | null | null | null |
File: crates/router/src/workflows/process_dispute.rs
Public functions: 2
Public structs: 1
use common_utils::ext_traits::{StringExt, ValueExt};
use diesel_models::process_tracker::business_status;
use error_stack::ResultExt;
use router_env::logger;
use scheduler::{
consumer::{self, types::process_data, workflows... | crates/router/src/workflows/process_dispute.rs | router | full_file | 1,370 | null | null | null | null | null | null | null | null | null | null | null | null | null |
File: crates/router/tests/connectors/utils.rs
Public functions: 5
Public structs: 11
use std::{fmt::Debug, marker::PhantomData, str::FromStr, sync::Arc, time::Duration};
use async_trait::async_trait;
use common_utils::{id_type::GenerateId, pii::Email};
use error_stack::Report;
use masking::Secret;
use router::{
... | crates/router/tests/connectors/utils.rs#chunk0 | router | chunk | 8,190 | null | null | null | null | null | null | null | null | null | null | null | null | null |
impl EventInfo for AuditEvent {
type Data = Self;
fn data(&self) -> error_stack::Result<Self::Data, events::EventsError> {
Ok(self.clone())
}
fn key(&self) -> String {
"event".to_string()
}
} | crates/router/src/events/audit_events.rs | router | impl_block | 60 | rust | null | AuditEvent | EventInfo for | impl EventInfo for for AuditEvent | null | null | null | null | null | null | null | null |
pub async fn routing_update_default_config_for_profile() {} | crates/openapi/src/routes/routing.rs | openapi | function_signature | 11 | rust | null | null | null | null | routing_update_default_config_for_profile | null | null | null | null | null | null | null |
pub struct MonerisAuthErrorResponse {
pub error: String,
pub error_description: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/moneris/transformers.rs | hyperswitch_connectors | struct_definition | 23 | rust | MonerisAuthErrorResponse | null | null | null | null | null | null | null | null | null | null | null |
impl webhooks::IncomingWebhook for Cashtocode {
fn get_webhook_source_verification_signature(
&self,
request: &webhooks::IncomingWebhookRequestDetails<'_>,
_connector_webhook_secrets: &api_models::webhooks::ConnectorWebhookSecrets,
) -> CustomResult<Vec<u8>, errors::ConnectorError> {
... | crates/hyperswitch_connectors/src/connectors/cashtocode.rs | hyperswitch_connectors | impl_block | 880 | rust | null | Cashtocode | webhooks::IncomingWebhook for | impl webhooks::IncomingWebhook for for Cashtocode | null | null | null | null | null | null | null | null |
impl api::Refund for Jpmorgan {} | crates/hyperswitch_connectors/src/connectors/jpmorgan.rs | hyperswitch_connectors | impl_block | 10 | rust | null | Jpmorgan | api::Refund for | impl api::Refund for for Jpmorgan | null | null | null | null | null | null | null | null |
impl api::PaymentCapture for Amazonpay {} | crates/hyperswitch_connectors/src/connectors/amazonpay.rs | hyperswitch_connectors | impl_block | 9 | rust | null | Amazonpay | api::PaymentCapture for | impl api::PaymentCapture for for Amazonpay | null | null | null | null | null | null | null | null |
pub struct MerchantKeyStoreNew {
pub merchant_id: common_utils::id_type::MerchantId,
pub key: Encryption,
pub created_at: PrimitiveDateTime,
} | crates/diesel_models/src/merchant_key_store.rs | diesel_models | struct_definition | 36 | rust | MerchantKeyStoreNew | null | null | null | null | null | null | null | null | null | null | null |
pub struct DlocalPaymentsSyncResponse {
status: DlocalPaymentStatus,
id: String,
order_id: Option<String>,
} | crates/hyperswitch_connectors/src/connectors/dlocal/transformers.rs | hyperswitch_connectors | struct_definition | 29 | rust | DlocalPaymentsSyncResponse | null | null | null | null | null | null | null | null | null | null | null |
impl std::fmt::Display for AnalyticsProvider {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let analytics_provider = match self {
Self::Clickhouse(_) => "Clickhouse",
Self::Sqlx(_) => "Sqlx",
Self::CombinedCkh(_, _) => "CombinedCkh",
Se... | crates/analytics/src/lib.rs | analytics | impl_block | 107 | rust | null | AnalyticsProvider | std::fmt::Display for | impl std::fmt::Display for for AnalyticsProvider | null | null | null | null | null | null | null | null |
pub struct Operation {
pub op: PaypalOperationType,
pub path: String,
pub value: Value,
} | crates/hyperswitch_connectors/src/connectors/paypal/transformers.rs | hyperswitch_connectors | struct_definition | 25 | rust | Operation | null | null | null | null | null | null | null | null | null | null | null |
impl MerchantKeyStoreNew {
pub async fn insert(self, conn: &PgPooledConn) -> StorageResult<MerchantKeyStore> {
generics::generic_insert(conn, self).await
}
} | crates/diesel_models/src/query/merchant_key_store.rs | diesel_models | impl_block | 44 | rust | null | MerchantKeyStoreNew | null | impl MerchantKeyStoreNew | null | null | null | null | null | null | null | null |
pub async fn log_payment_intent_delete(
&self,
delete_old_intent: &PaymentIntent,
tenant_id: TenantID,
infra_values: Option<Value>,
) -> MQResult<()> {
self.log_event(&KafkaEvent::old(
&KafkaPaymentIntent::from_storage(delete_old_intent, infra_values),
... | crates/router/src/services/kafka.rs | router | function_signature | 112 | rust | null | null | null | null | log_payment_intent_delete | null | null | null | null | null | null | null |
pub struct ItaubankPixExpireTime {
#[serde(with = "common_utils::custom_serde::iso8601")]
criacao: PrimitiveDateTime,
expiracao: i64,
} | crates/hyperswitch_connectors/src/connectors/itaubank/transformers.rs | hyperswitch_connectors | struct_definition | 46 | rust | ItaubankPixExpireTime | null | null | null | null | 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.