mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-11-02 20:40:12 +08:00
ci: update versions of actions (#1388)
This commit is contained in:
47
.github/workflows/CI.yml
vendored
47
.github/workflows/CI.yml
vendored
@ -56,7 +56,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Rust
|
||||
uses: dtolnay/rust-toolchain@master
|
||||
@ -81,9 +81,10 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: "Fetch base branch"
|
||||
shell: bash
|
||||
run: git fetch origin $GITHUB_BASE_REF --depth 1
|
||||
|
||||
- name: Install mold linker
|
||||
@ -97,12 +98,12 @@ jobs:
|
||||
with:
|
||||
toolchain: 1.65
|
||||
|
||||
- uses: Swatinem/rust-cache@v2.2.0
|
||||
- uses: Swatinem/rust-cache@v2.4.0
|
||||
with:
|
||||
save-if: ${{ github.event_name == 'push' }}
|
||||
|
||||
- name: Install cargo-hack
|
||||
uses: baptiste0928/cargo-install@v1.3.0
|
||||
uses: baptiste0928/cargo-install@v2.0.0
|
||||
with:
|
||||
crate: cargo-hack
|
||||
|
||||
@ -111,6 +112,7 @@ jobs:
|
||||
run: sed -i 's/rustflags = \[/rustflags = \[\n "-Dwarnings",/' .cargo/config.toml
|
||||
|
||||
- name: Check files changed
|
||||
shell: bash
|
||||
run: |
|
||||
if git diff --exit-code --quiet origin/$GITHUB_BASE_REF -- crates/api_models/; then
|
||||
echo "api_models_changes_exist=false" >> $GITHUB_ENV
|
||||
@ -165,42 +167,52 @@ jobs:
|
||||
|
||||
- name: Cargo hack api_models
|
||||
if: env.api_models_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p api_models
|
||||
|
||||
- name: Cargo hack common_enums
|
||||
if: env.common_enums_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p common_enums
|
||||
|
||||
- name: Cargo hack common_utils
|
||||
if: env.common_utils_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p common_utils
|
||||
|
||||
- name: Cargo hack drainer
|
||||
if: env.drainer_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p drainer
|
||||
|
||||
- name: Cargo hack masking
|
||||
if: env.masking_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p masking
|
||||
|
||||
- name: Cargo hack redis_interface
|
||||
if: env.redis_interface_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p redis_interface
|
||||
|
||||
- name: Cargo hack router
|
||||
if: env.router_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --skip kms,basilisk,kv_store,accounts_cache,openapi --no-dev-deps -p router
|
||||
|
||||
- name: Cargo hack router_derive
|
||||
if: env.router_derive_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p router_derive
|
||||
|
||||
- name: Cargo hack router_env
|
||||
if: env.router_env_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p router_env
|
||||
|
||||
- name: Cargo hack storage_models
|
||||
if: env.storage_models_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p storage_models
|
||||
|
||||
# cargo-deny:
|
||||
@ -217,7 +229,7 @@ jobs:
|
||||
|
||||
# steps:
|
||||
# - name: Checkout repository
|
||||
# uses: actions/checkout@v3.1.0
|
||||
# uses: actions/checkout@v3
|
||||
|
||||
# - name: Run cargo-deny
|
||||
# uses: EmbarkStudios/cargo-deny-action@v1.3.2
|
||||
@ -237,9 +249,10 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: "Fetch base branch"
|
||||
shell: bash
|
||||
run: git fetch origin $GITHUB_BASE_REF --depth 1
|
||||
|
||||
- name: Install mold linker
|
||||
@ -252,19 +265,19 @@ jobs:
|
||||
uses: dtolnay/rust-toolchain@master
|
||||
with:
|
||||
toolchain: stable
|
||||
components: clippy, rustfmt
|
||||
components: clippy
|
||||
|
||||
- name: Install cargo-hack
|
||||
uses: baptiste0928/cargo-install@v1.3.0
|
||||
uses: baptiste0928/cargo-install@v2.0.0
|
||||
with:
|
||||
crate: cargo-hack
|
||||
|
||||
# - name: Install cargo-nextest
|
||||
# uses: baptiste0928/cargo-install@v1.3.0
|
||||
# uses: baptiste0928/cargo-install@v2.0.0
|
||||
# with:
|
||||
# crate: cargo-nextest
|
||||
|
||||
- uses: Swatinem/rust-cache@v2.2.0
|
||||
- uses: Swatinem/rust-cache@v2.4.0
|
||||
with:
|
||||
save-if: ${{ github.event_name == 'push' }}
|
||||
|
||||
@ -283,6 +296,7 @@ jobs:
|
||||
run: cargo clippy --all-features --all-targets
|
||||
|
||||
- name: Check files changed
|
||||
shell: bash
|
||||
run: |
|
||||
if git diff --exit-code --quiet origin/$GITHUB_BASE_REF -- crates/api_models/; then
|
||||
echo "api_models_changes_exist=false" >> $GITHUB_ENV
|
||||
@ -337,42 +351,52 @@ jobs:
|
||||
|
||||
- name: Cargo hack api_models
|
||||
if: env.api_models_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p api_models
|
||||
|
||||
- name: Cargo hack common_enums
|
||||
if: env.common_enums_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p common_enums
|
||||
|
||||
- name: Cargo hack common_utils
|
||||
if: env.common_utils_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p common_utils
|
||||
|
||||
- name: Cargo hack drainer
|
||||
if: env.drainer_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p drainer
|
||||
|
||||
- name: Cargo hack masking
|
||||
if: env.masking_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p masking
|
||||
|
||||
- name: Cargo hack redis_interface
|
||||
if: env.redis_interface_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p redis_interface
|
||||
|
||||
- name: Cargo hack router
|
||||
if: env.router_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --skip kms,basilisk,kv_store,accounts_cache,openapi --no-dev-deps -p router
|
||||
|
||||
- name: Cargo hack router_derive
|
||||
if: env.router_derive_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p router_derive
|
||||
|
||||
- name: Cargo hack router_env
|
||||
if: env.router_env_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p router_env
|
||||
|
||||
- name: Cargo hack storage_models
|
||||
if: env.storage_models_changes_exist == 'true'
|
||||
shell: bash
|
||||
run: cargo hack check --each-feature --no-dev-deps -p storage_models
|
||||
|
||||
typos:
|
||||
@ -380,8 +404,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Spell check
|
||||
uses: crate-ci/typos@master
|
||||
|
||||
|
||||
14
.github/workflows/connector-sanity-tests.yml
vendored
14
.github/workflows/connector-sanity-tests.yml
vendored
@ -79,25 +79,25 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Rust
|
||||
uses: dtolnay/rust-toolchain@master
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- uses: Swatinem/rust-cache@v2.2.0
|
||||
- uses: Swatinem/rust-cache@v2.4.0
|
||||
|
||||
- name: Decrypt connector auth file
|
||||
run: ./scripts/decrypt_connector_auth.sh
|
||||
env:
|
||||
CONNECTOR_AUTH_PASSPHRASE: ${{ secrets.CONNECTOR_AUTH_PASSPHRASE }}
|
||||
shell: bash
|
||||
run: ./scripts/decrypt_connector_auth.sh
|
||||
|
||||
- name: Set connector auth file path in env
|
||||
shell: bash
|
||||
run: echo "CONNECTOR_AUTH_FILE_PATH=$HOME/target/test/connector_auth.toml" >> $GITHUB_ENV
|
||||
|
||||
- name: Run connector tests
|
||||
uses: actions-rs/cargo@v1
|
||||
with:
|
||||
command: test
|
||||
args: --package router --test connectors -- "${{ matrix.connector }}::" --test-threads=1
|
||||
shell: bash
|
||||
run: cargo test --package router --test connectors -- "${{ matrix.connector }}::" --test-threads=1
|
||||
|
||||
14
.github/workflows/conventional-commit-check.yml
vendored
14
.github/workflows/conventional-commit-check.yml
vendored
@ -45,19 +45,9 @@ jobs:
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- uses: Swatinem/rust-cache@v2.2.0
|
||||
- uses: baptiste0928/cargo-install@v2.0.0
|
||||
with:
|
||||
# We can use a single cache entry for all runs of this check, as only cocogitto needs to be cached
|
||||
shared-key: "pr_title_check"
|
||||
# We don't build any crates in this repository, no need to cache target directories
|
||||
cache-targets: "false"
|
||||
# Save cache even if commit message verification fails.
|
||||
# Only failure not considered is failures in installing cocogitto itself.
|
||||
cache-on-failure: "true"
|
||||
|
||||
- name: Install cocogitto
|
||||
shell: bash
|
||||
run: cargo install cocogitto
|
||||
crate: cocogitto
|
||||
|
||||
- name: Verify PR title follows conventional commit standards
|
||||
id: pr_title_check
|
||||
|
||||
18
.github/workflows/migration-check.yaml
vendored
18
.github/workflows/migration-check.yaml
vendored
@ -40,26 +40,18 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Rust
|
||||
uses: dtolnay/rust-toolchain@master
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- uses: Swatinem/rust-cache@v2.2.0
|
||||
- uses: baptiste0928/cargo-install@v2.0.0
|
||||
with:
|
||||
# We can use a single cache entry for all runs of this check, as only diesel CLI needs to be cached
|
||||
shared-key: "migration_verify"
|
||||
# We don't build any crates in this repository, no need to cache target directories
|
||||
cache-targets: "false"
|
||||
# Save cache even if migration verification fails.
|
||||
# Only failure not considered is failures in installing diesel CLI itself.
|
||||
cache-on-failure: "true"
|
||||
|
||||
- name: Install diesel_cli
|
||||
shell: bash
|
||||
run: cargo install diesel_cli --no-default-features --features postgres
|
||||
crate: diesel_cli
|
||||
features: postgres
|
||||
args: "--no-default-features"
|
||||
|
||||
- name: Verify `diesel migration run`
|
||||
shell: bash
|
||||
|
||||
@ -17,7 +17,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3.1.0
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Rust
|
||||
uses: dtolnay/rust-toolchain@master
|
||||
|
||||
@ -3,14 +3,18 @@ check-filename = true
|
||||
|
||||
[default.extend-identifiers]
|
||||
BA = "BA" # Bosnia and Herzegovina country code
|
||||
CAF = "CAF" # Central African Republic country code
|
||||
flate2 = "flate2"
|
||||
FO = "FO" # Faroe Islands (the) country code
|
||||
payment_vas = "payment_vas"
|
||||
PaymentVas = "PaymentVas"
|
||||
HypoNoeLbFurNiederosterreichUWien = "HypoNoeLbFurNiederosterreichUWien"
|
||||
hypo_noe_lb_fur_niederosterreich_u_wien = "hypo_noe_lb_fur_niederosterreich_u_wien"
|
||||
NAM = "NAM" # Namibia country code
|
||||
payment_vas = "payment_vas"
|
||||
PaymentVas = "PaymentVas"
|
||||
RegioBank = "RegioBank"
|
||||
SOM = "SOM" # Somalia country code
|
||||
THA = "THA" # Thailand country code
|
||||
ZAR = "ZAR" # South African Rand currency code
|
||||
|
||||
[default.extend-words]
|
||||
aci = "aci" # Name of a connector
|
||||
@ -21,4 +25,5 @@ substituters = "substituters" # Present in `flake.nix`
|
||||
[files]
|
||||
extend-exclude = [
|
||||
"config/redis.conf", # `typos` also checked "AKE" in the file, which is present as a quoted string
|
||||
"openapi/open_api_spec.yaml", # no longer updated
|
||||
]
|
||||
|
||||
@ -4,7 +4,7 @@ pub mod capture_flow;
|
||||
pub mod complete_authorize_flow;
|
||||
pub mod psync_flow;
|
||||
pub mod session_flow;
|
||||
pub mod verfiy_flow;
|
||||
pub mod verify_flow;
|
||||
|
||||
use async_trait::async_trait;
|
||||
|
||||
|
||||
@ -129,7 +129,7 @@ async fn should_sync_authorized_payment() {
|
||||
assert_eq!(response.status, enums::AttemptStatus::Charged);
|
||||
}
|
||||
|
||||
// Synchronizes a unresovled(underpaid) transaction.
|
||||
// Synchronizes a unresolved(underpaid) transaction.
|
||||
#[actix_web::test]
|
||||
async fn should_sync_unresolved_payment() {
|
||||
let response = CONNECTOR
|
||||
|
||||
@ -128,7 +128,7 @@ async fn should_sync_authorized_payment() {
|
||||
assert_eq!(response.status, enums::AttemptStatus::Charged);
|
||||
}
|
||||
|
||||
// Synchronizes a unresovled(underpaid) transaction.
|
||||
// Synchronizes a unresolved(underpaid) transaction.
|
||||
#[actix_web::test]
|
||||
async fn should_sync_unresolved_payment() {
|
||||
let response = CONNECTOR
|
||||
|
||||
@ -1797,6 +1797,7 @@
|
||||
"type": "object",
|
||||
"required": [
|
||||
"label",
|
||||
"type",
|
||||
"amount"
|
||||
],
|
||||
"properties": {
|
||||
@ -1806,8 +1807,7 @@
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "A value that indicates whether the line item(Ex: total, tax, discount, or grand total) is final or pending.",
|
||||
"nullable": true
|
||||
"description": "A value that indicates whether the line item(Ex: total, tax, discount, or grand total) is final or pending."
|
||||
},
|
||||
"amount": {
|
||||
"type": "string",
|
||||
@ -1836,7 +1836,8 @@
|
||||
"currency_code",
|
||||
"total",
|
||||
"merchant_capabilities",
|
||||
"supported_networks"
|
||||
"supported_networks",
|
||||
"merchant_identifier"
|
||||
],
|
||||
"properties": {
|
||||
"country_code": {
|
||||
@ -1864,8 +1865,7 @@
|
||||
"description": "The list of supported networks"
|
||||
},
|
||||
"merchant_identifier": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -1873,24 +1873,72 @@
|
||||
"type": "object"
|
||||
},
|
||||
"ApplePaySessionResponse": {
|
||||
"oneOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/ThirdPartySdkSessionResponse"
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/NoThirdPartySdkSessionResponse"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"default": null,
|
||||
"nullable": true
|
||||
"required": [
|
||||
"epoch_timestamp",
|
||||
"expires_at",
|
||||
"merchant_session_identifier",
|
||||
"nonce",
|
||||
"merchant_identifier",
|
||||
"domain_name",
|
||||
"display_name",
|
||||
"signature",
|
||||
"operational_analytics_identifier",
|
||||
"retries",
|
||||
"psp_id"
|
||||
],
|
||||
"properties": {
|
||||
"epoch_timestamp": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "Timestamp at which session is requested",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"expires_at": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "Timestamp at which session expires",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"merchant_session_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the merchant session"
|
||||
},
|
||||
"nonce": {
|
||||
"type": "string",
|
||||
"description": "Apple pay generated unique ID (UUID) value"
|
||||
},
|
||||
"merchant_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the merchant"
|
||||
},
|
||||
"domain_name": {
|
||||
"type": "string",
|
||||
"description": "The domain name of the merchant which is registered in Apple Pay"
|
||||
},
|
||||
"display_name": {
|
||||
"type": "string",
|
||||
"description": "The name to be displayed on Apple Pay button"
|
||||
},
|
||||
"signature": {
|
||||
"type": "string",
|
||||
"description": "A string which represents the properties of a payment"
|
||||
},
|
||||
"operational_analytics_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the operational analytics"
|
||||
},
|
||||
"retries": {
|
||||
"type": "integer",
|
||||
"format": "int32",
|
||||
"description": "The number of retries to get the session response",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"psp_id": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the connector transaction"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"ApplePayWalletData": {
|
||||
"type": "object",
|
||||
@ -1939,32 +1987,18 @@
|
||||
"type": "object",
|
||||
"required": [
|
||||
"session_token_data",
|
||||
"connector",
|
||||
"delayed_session_token",
|
||||
"sdk_next_action"
|
||||
"payment_request_data",
|
||||
"connector"
|
||||
],
|
||||
"properties": {
|
||||
"session_token_data": {
|
||||
"$ref": "#/components/schemas/ApplePaySessionResponse"
|
||||
},
|
||||
"payment_request_data": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/ApplePayPaymentRequest"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"connector": {
|
||||
"type": "string",
|
||||
"description": "The session token is w.r.t this connector"
|
||||
},
|
||||
"delayed_session_token": {
|
||||
"type": "boolean",
|
||||
"description": "Identifier for the delayed session response"
|
||||
},
|
||||
"sdk_next_action": {
|
||||
"$ref": "#/components/schemas/SdkNextAction"
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -5296,14 +5330,6 @@
|
||||
"MobilePayRedirection": {
|
||||
"type": "object"
|
||||
},
|
||||
"NextActionCall": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"confirm",
|
||||
"sync",
|
||||
"session_token"
|
||||
]
|
||||
},
|
||||
"NextActionData": {
|
||||
"oneOf": [
|
||||
{
|
||||
@ -5359,74 +5385,6 @@
|
||||
"display_bank_transfer_information"
|
||||
]
|
||||
},
|
||||
"NoThirdPartySdkSessionResponse": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"epoch_timestamp",
|
||||
"expires_at",
|
||||
"merchant_session_identifier",
|
||||
"nonce",
|
||||
"merchant_identifier",
|
||||
"domain_name",
|
||||
"display_name",
|
||||
"signature",
|
||||
"operational_analytics_identifier",
|
||||
"retries",
|
||||
"psp_id"
|
||||
],
|
||||
"properties": {
|
||||
"epoch_timestamp": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "Timestamp at which session is requested",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"expires_at": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "Timestamp at which session expires",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"merchant_session_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the merchant session"
|
||||
},
|
||||
"nonce": {
|
||||
"type": "string",
|
||||
"description": "Apple pay generated unique ID (UUID) value"
|
||||
},
|
||||
"merchant_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the merchant"
|
||||
},
|
||||
"domain_name": {
|
||||
"type": "string",
|
||||
"description": "The domain name of the merchant which is registered in Apple Pay"
|
||||
},
|
||||
"display_name": {
|
||||
"type": "string",
|
||||
"description": "The name to be displayed on Apple Pay button"
|
||||
},
|
||||
"signature": {
|
||||
"type": "string",
|
||||
"description": "A string which represents the properties of a payment"
|
||||
},
|
||||
"operational_analytics_identifier": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the operational analytics"
|
||||
},
|
||||
"retries": {
|
||||
"type": "integer",
|
||||
"format": "int32",
|
||||
"description": "The number of retries to get the session response",
|
||||
"minimum": 0.0
|
||||
},
|
||||
"psp_id": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the connector transaction"
|
||||
}
|
||||
}
|
||||
},
|
||||
"OnlineMandate": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
@ -6229,25 +6187,19 @@
|
||||
"PaymentsCreateRequest": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"currency",
|
||||
"manual_retry",
|
||||
"currency",
|
||||
"amount"
|
||||
],
|
||||
"properties": {
|
||||
"currency": {
|
||||
"payment_method_data": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/Currency"
|
||||
"$ref": "#/components/schemas/PaymentMethodData"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "A description of the payment",
|
||||
"example": "It's my first payment request",
|
||||
"nullable": true
|
||||
},
|
||||
"capture_method": {
|
||||
"allOf": [
|
||||
{
|
||||
@ -6256,21 +6208,13 @@
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"statement_descriptor_suffix": {
|
||||
"customer_id": {
|
||||
"type": "string",
|
||||
"description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.",
|
||||
"example": "Payment for shoes purchase",
|
||||
"description": "The identifier for the customer object. If not provided the customer ID will be autogenerated.",
|
||||
"example": "cus_y3oqhf46pyzuxjbcn2giaqnb44",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"metadata": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/Metadata"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_method": {
|
||||
"allOf": [
|
||||
{
|
||||
@ -6279,53 +6223,13 @@
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"email": {
|
||||
"type": "string",
|
||||
"description": "description: The customer's email address",
|
||||
"example": "johntest@test.com",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"customer_id": {
|
||||
"type": "string",
|
||||
"description": "The identifier for the customer object. If not provided the customer ID will be autogenerated.",
|
||||
"example": "cus_y3oqhf46pyzuxjbcn2giaqnb44",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"card_cvc": {
|
||||
"type": "string",
|
||||
"description": "This is used when payment is to be confirmed and the card is not saved",
|
||||
"confirm": {
|
||||
"type": "boolean",
|
||||
"description": "Whether to confirm the payment (if applicable)",
|
||||
"default": false,
|
||||
"example": true,
|
||||
"nullable": true
|
||||
},
|
||||
"business_country": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/CountryAlpha2"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"browser_info": {
|
||||
"type": "object",
|
||||
"description": "Additional details required by 3DS 2.0",
|
||||
"nullable": true
|
||||
},
|
||||
"routing": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/RoutingAlgorithm"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"merchant_id": {
|
||||
"type": "string",
|
||||
"description": "This is an identifier for the merchant account. This is inferred from the API key\nprovided during the request",
|
||||
"example": "merchant_1668273825",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"shipping": {
|
||||
"allOf": [
|
||||
{
|
||||
@ -6334,12 +6238,106 @@
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_id": {
|
||||
"type": "string",
|
||||
"description": "Unique identifier for the payment. This ensures idempotency for multiple payments\nthat have been done by a single merchant. This field is auto generated and is returned in the API response.",
|
||||
"example": "pay_mbabizu24mvu3mela5njyhpit4",
|
||||
"nullable": true,
|
||||
"maxLength": 30,
|
||||
"minLength": 30
|
||||
},
|
||||
"payment_method_type": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PaymentMethodType"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_experience": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PaymentExperience"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_token": {
|
||||
"type": "string",
|
||||
"description": "Provide a reference to a stored payment method",
|
||||
"example": "187282ab-40ef-47a9-9206-5099ba31e432",
|
||||
"nullable": true
|
||||
},
|
||||
"authentication_type": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/AuthenticationType"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"routing": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/RoutingAlgorithm"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"business_country": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/CountryAlpha2"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"manual_retry": {
|
||||
"type": "boolean",
|
||||
"description": "If enabled payment can be retried from the client side until the payment is successful or payment expires or the attempts(configured by the merchant) for payment are exhausted."
|
||||
},
|
||||
"capture_on": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "A timestamp (ISO 8601 code) that determines when the payment should be captured.\nProviding this field will automatically set `capture` to true",
|
||||
"example": "2022-09-10T10:11:12Z",
|
||||
"nullable": true
|
||||
},
|
||||
"statement_descriptor_suffix": {
|
||||
"type": "string",
|
||||
"description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.",
|
||||
"example": "Payment for shoes purchase",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"merchant_connector_details": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/MerchantConnectorDetailsWrap"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"business_sub_label": {
|
||||
"type": "string",
|
||||
"description": "Business sub label for the payment",
|
||||
"nullable": true
|
||||
},
|
||||
"email": {
|
||||
"type": "string",
|
||||
"description": "description: The customer's email address",
|
||||
"example": "johntest@test.com",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"setup_future_usage": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/FutureUsage"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"allowed_payment_method_types": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
@ -6348,42 +6346,10 @@
|
||||
"description": "Allowed Payment Method Types for a given PaymentIntent",
|
||||
"nullable": true
|
||||
},
|
||||
"manual_retry": {
|
||||
"type": "boolean",
|
||||
"description": "If enabled payment can be retried from the client side until the payment is successful or payment expires or the attempts(configured by the merchant) for payment are exhausted."
|
||||
},
|
||||
"payment_id": {
|
||||
"type": "string",
|
||||
"description": "Unique identifier for the payment. This ensures idempotency for multiple payments\nthat have been done by a single merchant. This field is auto generated and is returned in the API response.",
|
||||
"example": "pay_mbabizu24mvu3mela5njyhpit4",
|
||||
"nullable": true,
|
||||
"maxLength": 30,
|
||||
"minLength": 30
|
||||
},
|
||||
"business_sub_label": {
|
||||
"type": "string",
|
||||
"description": "Business sub label for the payment",
|
||||
"nullable": true
|
||||
},
|
||||
"amount": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "The payment amount. Amount for the payment in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc.,",
|
||||
"example": 6540,
|
||||
"nullable": true,
|
||||
"minimum": 0.0
|
||||
},
|
||||
"statement_descriptor_name": {
|
||||
"type": "string",
|
||||
"description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.",
|
||||
"example": "Hyperswitch Router",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"merchant_connector_details": {
|
||||
"currency": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/MerchantConnectorDetailsWrap"
|
||||
"$ref": "#/components/schemas/Currency"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
@ -6396,20 +6362,70 @@
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"capture_on": {
|
||||
"phone_country_code": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "A timestamp (ISO 8601 code) that determines when the payment should be captured.\nProviding this field will automatically set `capture` to true",
|
||||
"example": "2022-09-10T10:11:12Z",
|
||||
"description": "The country code for the customer phone number",
|
||||
"example": "+1",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"return_url": {
|
||||
"type": "string",
|
||||
"description": "The URL to redirect after the completion of the operation",
|
||||
"example": "https://hyperswitch.io",
|
||||
"nullable": true
|
||||
},
|
||||
"confirm": {
|
||||
"type": "boolean",
|
||||
"description": "Whether to confirm the payment (if applicable)",
|
||||
"default": false,
|
||||
"example": true,
|
||||
"statement_descriptor_name": {
|
||||
"type": "string",
|
||||
"description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.",
|
||||
"example": "Hyperswitch Router",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "description: The customer's name",
|
||||
"example": "John Test",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"amount": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "The payment amount. Amount for the payment in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc.,",
|
||||
"example": 6540,
|
||||
"nullable": true,
|
||||
"minimum": 0.0
|
||||
},
|
||||
"amount_to_capture": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "The Amount to be captured/ debited from the users payment method. It shall be in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc.,\nIf not provided, the default amount_to_capture will be the payment amount.",
|
||||
"example": 6540,
|
||||
"nullable": true
|
||||
},
|
||||
"metadata": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/Metadata"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"merchant_id": {
|
||||
"type": "string",
|
||||
"description": "This is an identifier for the merchant account. This is inferred from the API key\nprovided during the request",
|
||||
"example": "merchant_1668273825",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"phone": {
|
||||
"type": "string",
|
||||
"description": "The customer's phone number",
|
||||
"example": "3141592653",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"client_secret": {
|
||||
"type": "string",
|
||||
"description": "It's a token used for client side verification.",
|
||||
@ -6431,18 +6447,33 @@
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"browser_info": {
|
||||
"type": "object",
|
||||
"description": "Additional details required by 3DS 2.0",
|
||||
"nullable": true
|
||||
},
|
||||
"business_label": {
|
||||
"type": "string",
|
||||
"description": "Business label of the merchant for this payment",
|
||||
"example": "food",
|
||||
"nullable": true
|
||||
},
|
||||
"name": {
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "description: The customer's name",
|
||||
"example": "John Test",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
"description": "A description of the payment",
|
||||
"example": "It's my first payment request",
|
||||
"nullable": true
|
||||
},
|
||||
"card_cvc": {
|
||||
"type": "string",
|
||||
"description": "This is used when payment is to be confirmed and the card is not saved",
|
||||
"nullable": true
|
||||
},
|
||||
"off_session": {
|
||||
"type": "boolean",
|
||||
"description": "Set to true to indicate that the customer is not in your checkout flow during this payment, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and charge them later. This parameter can only be used with `confirm: true`.",
|
||||
"example": true,
|
||||
"nullable": true
|
||||
},
|
||||
"connector": {
|
||||
"type": "array",
|
||||
@ -6455,79 +6486,6 @@
|
||||
"adyen"
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"authentication_type": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/AuthenticationType"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"phone": {
|
||||
"type": "string",
|
||||
"description": "The customer's phone number",
|
||||
"example": "3141592653",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"amount_to_capture": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "The Amount to be captured/ debited from the users payment method. It shall be in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc.,\nIf not provided, the default amount_to_capture will be the payment amount.",
|
||||
"example": 6540,
|
||||
"nullable": true
|
||||
},
|
||||
"return_url": {
|
||||
"type": "string",
|
||||
"description": "The URL to redirect after the completion of the operation",
|
||||
"example": "https://hyperswitch.io",
|
||||
"nullable": true
|
||||
},
|
||||
"setup_future_usage": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/FutureUsage"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_method_data": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PaymentMethodData"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"phone_country_code": {
|
||||
"type": "string",
|
||||
"description": "The country code for the customer phone number",
|
||||
"example": "+1",
|
||||
"nullable": true,
|
||||
"maxLength": 255
|
||||
},
|
||||
"payment_experience": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PaymentExperience"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"payment_method_type": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PaymentMethodType"
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"off_session": {
|
||||
"type": "boolean",
|
||||
"description": "Set to true to indicate that the customer is not in your checkout flow during this payment, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and charge them later. This parameter can only be used with `confirm: true`.",
|
||||
"example": true,
|
||||
"nullable": true
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -7210,11 +7168,6 @@
|
||||
}
|
||||
],
|
||||
"nullable": true
|
||||
},
|
||||
"delayed_session_token": {
|
||||
"type": "boolean",
|
||||
"description": "Identifier for the delayed session response",
|
||||
"nullable": true
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -7680,32 +7633,6 @@
|
||||
],
|
||||
"example": "custom"
|
||||
},
|
||||
"SdkNextAction": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"next_action"
|
||||
],
|
||||
"properties": {
|
||||
"next_action": {
|
||||
"$ref": "#/components/schemas/NextActionCall"
|
||||
}
|
||||
}
|
||||
},
|
||||
"SecretInfoToInitiateSdk": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"display",
|
||||
"payment"
|
||||
],
|
||||
"properties": {
|
||||
"display": {
|
||||
"type": "string"
|
||||
},
|
||||
"payment": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"SepaAndBacsBillingDetails": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
@ -7842,17 +7769,6 @@
|
||||
"propertyName": "wallet_name"
|
||||
}
|
||||
},
|
||||
"ThirdPartySdkSessionResponse": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"secrets"
|
||||
],
|
||||
"properties": {
|
||||
"secrets": {
|
||||
"$ref": "#/components/schemas/SecretInfoToInitiateSdk"
|
||||
}
|
||||
}
|
||||
},
|
||||
"UpdateApiKeyRequest": {
|
||||
"type": "object",
|
||||
"description": "The request body for updating an API Key.",
|
||||
|
||||
Reference in New Issue
Block a user