mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-28 12:15:40 +08:00
docs(openapi): Fixed API documentation for V2 (#6496)
This commit is contained in:
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/api_keys/{key_id}
|
openapi: get /v2/api_keys/{id}
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: delete /v2/api_keys/{key_id}
|
openapi: delete /v2/api_keys/{id}
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: put /v2/api_keys/{key_id}
|
openapi: put /v2/api_keys/{id}
|
||||||
---
|
---
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/merchant_accounts/{account_id}/profiles
|
openapi: get /v2/merchant_accounts/{id}/profiles
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: post /v2/payments/{payment_id}/create_external_sdk_tokens
|
openapi: post /v2/payments/{payment_id}/create-external-sdk-tokens
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/profiles/{profile_id}/connector_accounts
|
openapi: get /v2/profiles/{id}/connector_accounts
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: patch /v2/profiles/{profile_id}/activate_routing_algorithm
|
openapi: patch /v2/profiles/{id}/activate_routing_algorithm
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: patch /v2/profiles/{profile_id}/deactivate_routing_algorithm
|
openapi: patch /v2/profiles/{id}/deactivate_routing_algorithm
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/profiles/{profile_id}/routing_algorithm
|
openapi: get /v2/profiles/{id}/routing_algorithm
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/profiles/{profile_id}/fallback_routing
|
openapi: get /v2/profiles/{id}/fallback_routing
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/profiles/{profile_id}
|
openapi: get /v2/profiles/{id}
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: patch /v2/profiles/{profile_id}/fallback_routing
|
openapi: patch /v2/profiles/{id}/fallback_routing
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: put /v2/profiles/{profile_id}
|
openapi: put /v2/profiles/{id}
|
||||||
---
|
---
|
||||||
@ -1,3 +1,3 @@
|
|||||||
---
|
---
|
||||||
openapi: get /v2/routing_algorithm/{routing_algorithm_id}
|
openapi: get /v2/routing_algorithm/{id}
|
||||||
---
|
---
|
||||||
@ -76,11 +76,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"group": "Merchant Connector Account",
|
"group": "Connector Account",
|
||||||
"pages": [
|
"pages": [
|
||||||
"api-reference/merchant-connector-account/merchant-connector--create",
|
"api-reference/connector-account/connector-account--create",
|
||||||
"api-reference/merchant-connector-account/merchant-connector--retrieve",
|
"api-reference/connector-account/connector-account--retrieve",
|
||||||
"api-reference/merchant-connector-account/merchant-connector--update"
|
"api-reference/connector-account/connector-account--update"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@ -213,8 +213,8 @@
|
|||||||
"tags": [
|
"tags": [
|
||||||
"Merchant Connector Account"
|
"Merchant Connector Account"
|
||||||
],
|
],
|
||||||
"summary": "Merchant Connector - Create",
|
"summary": "Connector Account - Create",
|
||||||
"description": "Creates a new Merchant Connector for the merchant account. The connector could be a payment processor/facilitator/acquirer or a provider of specialized services like Fraud/Accounting etc.",
|
"description": "Creates a new Connector Account for the merchant account. The connector could be a payment processor/facilitator/acquirer or a provider of specialized services like Fraud/Accounting etc.",
|
||||||
"operationId": "Create a Merchant Connector",
|
"operationId": "Create a Merchant Connector",
|
||||||
"requestBody": {
|
"requestBody": {
|
||||||
"content": {
|
"content": {
|
||||||
@ -290,7 +290,7 @@
|
|||||||
"tags": [
|
"tags": [
|
||||||
"Merchant Connector Account"
|
"Merchant Connector Account"
|
||||||
],
|
],
|
||||||
"summary": "Merchant Connector - Retrieve",
|
"summary": "Connector Account - Retrieve",
|
||||||
"description": "Retrieves details of a Connector account",
|
"description": "Retrieves details of a Connector account",
|
||||||
"operationId": "Retrieve a Merchant Connector",
|
"operationId": "Retrieve a Merchant Connector",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
@ -333,8 +333,8 @@
|
|||||||
"tags": [
|
"tags": [
|
||||||
"Merchant Connector Account"
|
"Merchant Connector Account"
|
||||||
],
|
],
|
||||||
"summary": "Merchant Connector - Update",
|
"summary": "Connector Account - Update",
|
||||||
"description": "To update an existing Merchant Connector account. Helpful in enabling/disabling different payment methods and other settings for the connector",
|
"description": "To update an existing Connector account. Helpful in enabling/disabling different payment methods and other settings for the connector",
|
||||||
"operationId": "Update a Merchant Connector",
|
"operationId": "Update a Merchant Connector",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
@ -573,7 +573,7 @@
|
|||||||
"operationId": "Update a Merchant Account",
|
"operationId": "Update a Merchant Account",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "account_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the merchant account",
|
"description": "The unique identifier for the merchant account",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -630,17 +630,17 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/merchant_accounts/{account_id}/profiles": {
|
"/v2/merchant_accounts/{id}/profiles": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Merchant Account"
|
"Merchant Account"
|
||||||
],
|
],
|
||||||
"summary": "Profile - List",
|
"summary": "Merchant Account - Profile List",
|
||||||
"description": "List profiles for an Merchant",
|
"description": "List profiles for an Merchant",
|
||||||
"operationId": "List Profiles",
|
"operationId": "List Profiles",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "account_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the Merchant",
|
"description": "The unique identifier for the Merchant",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -682,6 +682,17 @@
|
|||||||
"summary": "Payments - Session token",
|
"summary": "Payments - Session token",
|
||||||
"description": "Creates a session object or a session token for wallets like Apple Pay, Google Pay, etc. These tokens are used by Hyperswitch's SDK to initiate these wallets' SDK.",
|
"description": "Creates a session object or a session token for wallets like Apple Pay, Google Pay, etc. These tokens are used by Hyperswitch's SDK to initiate these wallets' SDK.",
|
||||||
"operationId": "Create Session tokens for a Payment",
|
"operationId": "Create Session tokens for a Payment",
|
||||||
|
"parameters": [
|
||||||
|
{
|
||||||
|
"name": "payment_id",
|
||||||
|
"in": "path",
|
||||||
|
"description": "The identifier for payment",
|
||||||
|
"required": true,
|
||||||
|
"schema": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
"requestBody": {
|
"requestBody": {
|
||||||
"content": {
|
"content": {
|
||||||
"application/json": {
|
"application/json": {
|
||||||
@ -775,7 +786,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}": {
|
"/v2/profiles/{id}": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Profile"
|
"Profile"
|
||||||
@ -785,7 +796,7 @@
|
|||||||
"operationId": "Retrieve a Profile",
|
"operationId": "Retrieve a Profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -836,7 +847,7 @@
|
|||||||
"operationId": "Update a Profile",
|
"operationId": "Update a Profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -896,17 +907,17 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}/connector_accounts": {
|
"/v2/profiles/{id}/connector_accounts": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Business Profile"
|
"Business Profile"
|
||||||
],
|
],
|
||||||
"summary": "Merchant Connector - List",
|
"summary": "Profile - Connector Accounts List",
|
||||||
"description": "List Merchant Connector Details for the business profile",
|
"description": "List Connector Accounts for the profile",
|
||||||
"operationId": "List all Merchant Connectors",
|
"operationId": "List all Merchant Connectors",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the business profile",
|
"description": "The unique identifier for the business profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -955,7 +966,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}/activate_routing_algorithm": {
|
"/v2/profiles/{id}/activate_routing_algorithm": {
|
||||||
"patch": {
|
"patch": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Profile"
|
"Profile"
|
||||||
@ -965,7 +976,7 @@
|
|||||||
"operationId": "Activates a routing algorithm under a profile",
|
"operationId": "Activates a routing algorithm under a profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1022,7 +1033,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}/deactivate_routing_algorithm": {
|
"/v2/profiles/{id}/deactivate_routing_algorithm": {
|
||||||
"patch": {
|
"patch": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Profile"
|
"Profile"
|
||||||
@ -1032,7 +1043,7 @@
|
|||||||
"operationId": " Deactivates a routing algorithm under a profile",
|
"operationId": " Deactivates a routing algorithm under a profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1075,7 +1086,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}/fallback_routing": {
|
"/v2/profiles/{id}/fallback_routing": {
|
||||||
"patch": {
|
"patch": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Profile"
|
"Profile"
|
||||||
@ -1085,7 +1096,7 @@
|
|||||||
"operationId": "Update the default fallback routing algorithm for the profile",
|
"operationId": "Update the default fallback routing algorithm for the profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1149,7 +1160,7 @@
|
|||||||
"operationId": "Retrieve the default fallback routing algorithm for the profile",
|
"operationId": "Retrieve the default fallback routing algorithm for the profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1186,7 +1197,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/profiles/{profile_id}/routing_algorithm": {
|
"/v2/profiles/{id}/routing_algorithm": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Profile"
|
"Profile"
|
||||||
@ -1196,7 +1207,7 @@
|
|||||||
"operationId": "Retrieve the active routing algorithm under the profile",
|
"operationId": "Retrieve the active routing algorithm under the profile",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "profile_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the profile",
|
"description": "The unique identifier for the profile",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1315,7 +1326,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/routing_algorithm/{routing_algorithm_id}": {
|
"/v2/routing_algorithm/{id}": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"Routing"
|
"Routing"
|
||||||
@ -1325,7 +1336,7 @@
|
|||||||
"operationId": "Retrieve a routing algorithm with its algorithm id",
|
"operationId": "Retrieve a routing algorithm with its algorithm id",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "routing_algorithm_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for a routing algorithm",
|
"description": "The unique identifier for a routing algorithm",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1405,7 +1416,7 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"/v2/api_keys/{key_id}": {
|
"/v2/api_keys/{id}": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"API Key"
|
"API Key"
|
||||||
@ -1415,7 +1426,7 @@
|
|||||||
"operationId": "Retrieve an API Key",
|
"operationId": "Retrieve an API Key",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "key_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the API Key",
|
"description": "The unique identifier for the API Key",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1454,7 +1465,7 @@
|
|||||||
"operationId": "Update an API Key",
|
"operationId": "Update an API Key",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "key_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the API Key",
|
"description": "The unique identifier for the API Key",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -1503,7 +1514,7 @@
|
|||||||
"operationId": "Revoke an API Key",
|
"operationId": "Revoke an API Key",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "key_id",
|
"name": "id",
|
||||||
"in": "path",
|
"in": "path",
|
||||||
"description": "The unique identifier for the API Key",
|
"description": "The unique identifier for the API Key",
|
||||||
"required": true,
|
"required": true,
|
||||||
@ -20054,7 +20065,7 @@
|
|||||||
"type": "apiKey",
|
"type": "apiKey",
|
||||||
"in": "header",
|
"in": "header",
|
||||||
"name": "api-key",
|
"name": "api-key",
|
||||||
"description": "Admin API keys allow you to perform some privileged actions such as creating a merchant account and Merchant Connector account."
|
"description": "Admin API keys allow you to perform some privileged actions such as creating a merchant account and Connector account."
|
||||||
},
|
},
|
||||||
"api_key": {
|
"api_key": {
|
||||||
"type": "apiKey",
|
"type": "apiKey",
|
||||||
|
|||||||
@ -614,7 +614,7 @@ impl utoipa::Modify for SecurityAddon {
|
|||||||
SecurityScheme::ApiKey(ApiKey::Header(ApiKeyValue::with_description(
|
SecurityScheme::ApiKey(ApiKey::Header(ApiKeyValue::with_description(
|
||||||
"api-key",
|
"api-key",
|
||||||
"Admin API keys allow you to perform some privileged actions such as \
|
"Admin API keys allow you to perform some privileged actions such as \
|
||||||
creating a merchant account and Merchant Connector account."
|
creating a merchant account and Connector account."
|
||||||
))),
|
))),
|
||||||
),
|
),
|
||||||
(
|
(
|
||||||
|
|||||||
@ -64,9 +64,9 @@ pub async fn api_key_retrieve() {}
|
|||||||
/// Retrieve information about the specified API Key.
|
/// Retrieve information about the specified API Key.
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/api_keys/{key_id}",
|
path = "/v2/api_keys/{id}",
|
||||||
params (
|
params (
|
||||||
("key_id" = String, Path, description = "The unique identifier for the API Key")
|
("id" = String, Path, description = "The unique identifier for the API Key")
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "API Key retrieved", body = RetrieveApiKeyResponse),
|
(status = 200, description = "API Key retrieved", body = RetrieveApiKeyResponse),
|
||||||
@ -106,10 +106,10 @@ pub async fn api_key_update() {}
|
|||||||
/// Update information for the specified API Key.
|
/// Update information for the specified API Key.
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
put,
|
put,
|
||||||
path = "/v2/api_keys/{key_id}",
|
path = "/v2/api_keys/{id}",
|
||||||
request_body = UpdateApiKeyRequest,
|
request_body = UpdateApiKeyRequest,
|
||||||
params (
|
params (
|
||||||
("key_id" = String, Path, description = "The unique identifier for the API Key")
|
("id" = String, Path, description = "The unique identifier for the API Key")
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "API Key updated", body = RetrieveApiKeyResponse),
|
(status = 200, description = "API Key updated", body = RetrieveApiKeyResponse),
|
||||||
@ -150,9 +150,9 @@ pub async fn api_key_revoke() {}
|
|||||||
/// authenticating with our APIs.
|
/// authenticating with our APIs.
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
delete,
|
delete,
|
||||||
path = "/v2/api_keys/{key_id}",
|
path = "/v2/api_keys/{id}",
|
||||||
params (
|
params (
|
||||||
("key_id" = String, Path, description = "The unique identifier for the API Key")
|
("id" = String, Path, description = "The unique identifier for the API Key")
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "API Key revoked", body = RevokeApiKeyResponse),
|
(status = 200, description = "API Key revoked", body = RevokeApiKeyResponse),
|
||||||
|
|||||||
@ -212,7 +212,7 @@ pub async fn update_merchant_account() {}
|
|||||||
)
|
)
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
params (("account_id" = String, Path, description = "The unique identifier for the merchant account")),
|
params (("id" = String, Path, description = "The unique identifier for the merchant account")),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Merchant Account Updated", body = MerchantAccountResponse),
|
(status = 200, description = "Merchant Account Updated", body = MerchantAccountResponse),
|
||||||
(status = 404, description = "Merchant account not found")
|
(status = 404, description = "Merchant account not found")
|
||||||
@ -295,13 +295,13 @@ pub async fn merchant_account_kv_status() {}
|
|||||||
pub async fn payment_connector_list_profile() {}
|
pub async fn payment_connector_list_profile() {}
|
||||||
|
|
||||||
#[cfg(feature = "v2")]
|
#[cfg(feature = "v2")]
|
||||||
/// Profile - List
|
/// Merchant Account - Profile List
|
||||||
///
|
///
|
||||||
/// List profiles for an Merchant
|
/// List profiles for an Merchant
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/merchant_accounts/{account_id}/profiles",
|
path = "/v2/merchant_accounts/{id}/profiles",
|
||||||
params (("account_id" = String, Path, description = "The unique identifier for the Merchant")),
|
params (("id" = String, Path, description = "The unique identifier for the Merchant")),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "profile list retrieved successfully", body = Vec<ProfileResponse>),
|
(status = 200, description = "profile list retrieved successfully", body = Vec<ProfileResponse>),
|
||||||
(status = 400, description = "Invalid data")
|
(status = 400, description = "Invalid data")
|
||||||
|
|||||||
@ -61,9 +61,9 @@
|
|||||||
)]
|
)]
|
||||||
pub async fn connector_create() {}
|
pub async fn connector_create() {}
|
||||||
|
|
||||||
/// Merchant Connector - Create
|
/// Connector Account - Create
|
||||||
///
|
///
|
||||||
/// Creates a new Merchant Connector for the merchant account. The connector could be a payment processor/facilitator/acquirer or a provider of specialized services like Fraud/Accounting etc.
|
/// Creates a new Connector Account for the merchant account. The connector could be a payment processor/facilitator/acquirer or a provider of specialized services like Fraud/Accounting etc.
|
||||||
#[cfg(feature = "v2")]
|
#[cfg(feature = "v2")]
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
post,
|
post,
|
||||||
@ -146,7 +146,7 @@ pub async fn connector_create() {}
|
|||||||
)]
|
)]
|
||||||
pub async fn connector_retrieve() {}
|
pub async fn connector_retrieve() {}
|
||||||
|
|
||||||
/// Merchant Connector - Retrieve
|
/// Connector Account - Retrieve
|
||||||
///
|
///
|
||||||
/// Retrieves details of a Connector account
|
/// Retrieves details of a Connector account
|
||||||
#[cfg(feature = "v2")]
|
#[cfg(feature = "v2")]
|
||||||
@ -235,9 +235,9 @@ pub async fn connector_list() {}
|
|||||||
)]
|
)]
|
||||||
pub async fn connector_update() {}
|
pub async fn connector_update() {}
|
||||||
|
|
||||||
/// Merchant Connector - Update
|
/// Connector Account - Update
|
||||||
///
|
///
|
||||||
/// To update an existing Merchant Connector account. Helpful in enabling/disabling different payment methods and other settings for the connector
|
/// To update an existing Connector account. Helpful in enabling/disabling different payment methods and other settings for the connector
|
||||||
#[cfg(feature = "v2")]
|
#[cfg(feature = "v2")]
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
put,
|
put,
|
||||||
|
|||||||
@ -406,6 +406,9 @@ pub fn payments_connector_session() {}
|
|||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
post,
|
post,
|
||||||
path = "/v2/payments/{payment_id}/create-external-sdk-tokens",
|
path = "/v2/payments/{payment_id}/create-external-sdk-tokens",
|
||||||
|
params(
|
||||||
|
("payment_id" = String, Path, description = "The identifier for payment")
|
||||||
|
),
|
||||||
request_body=PaymentsSessionRequest,
|
request_body=PaymentsSessionRequest,
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Payment session object created or session token was retrieved from wallets", body = PaymentsSessionResponse),
|
(status = 200, description = "Payment session object created or session token was retrieved from wallets", body = PaymentsSessionResponse),
|
||||||
|
|||||||
@ -174,9 +174,9 @@ pub async fn profile_create() {}
|
|||||||
/// Update the *profile*
|
/// Update the *profile*
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
put,
|
put,
|
||||||
path = "/v2/profiles/{profile_id}",
|
path = "/v2/profiles/{id}",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
(
|
(
|
||||||
"X-Merchant-Id" = String, Header,
|
"X-Merchant-Id" = String, Header,
|
||||||
description = "Merchant ID of the profile.",
|
description = "Merchant ID of the profile.",
|
||||||
@ -210,7 +210,7 @@ pub async fn profile_update() {}
|
|||||||
/// Activates a routing algorithm under a profile
|
/// Activates a routing algorithm under a profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
patch,
|
patch,
|
||||||
path = "/v2/profiles/{profile_id}/activate_routing_algorithm",
|
path = "/v2/profiles/{id}/activate_routing_algorithm",
|
||||||
request_body ( content = RoutingAlgorithmId,
|
request_body ( content = RoutingAlgorithmId,
|
||||||
examples( (
|
examples( (
|
||||||
"Activate a routing algorithm" = (
|
"Activate a routing algorithm" = (
|
||||||
@ -220,7 +220,7 @@ pub async fn profile_update() {}
|
|||||||
)
|
)
|
||||||
))),
|
))),
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Routing Algorithm is activated", body = RoutingDictionaryRecord),
|
(status = 200, description = "Routing Algorithm is activated", body = RoutingDictionaryRecord),
|
||||||
@ -240,9 +240,9 @@ pub async fn routing_link_config() {}
|
|||||||
/// Deactivates a routing algorithm under a profile
|
/// Deactivates a routing algorithm under a profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
patch,
|
patch,
|
||||||
path = "/v2/profiles/{profile_id}/deactivate_routing_algorithm",
|
path = "/v2/profiles/{id}/deactivate_routing_algorithm",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Successfully deactivated routing config", body = RoutingDictionaryRecord),
|
(status = 200, description = "Successfully deactivated routing config", body = RoutingDictionaryRecord),
|
||||||
@ -263,10 +263,10 @@ pub async fn routing_unlink_config() {}
|
|||||||
/// Update the default fallback routing algorithm for the profile
|
/// Update the default fallback routing algorithm for the profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
patch,
|
patch,
|
||||||
path = "/v2/profiles/{profile_id}/fallback_routing",
|
path = "/v2/profiles/{id}/fallback_routing",
|
||||||
request_body = Vec<RoutableConnectorChoice>,
|
request_body = Vec<RoutableConnectorChoice>,
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Successfully updated the default fallback routing algorithm", body = Vec<RoutableConnectorChoice>),
|
(status = 200, description = "Successfully updated the default fallback routing algorithm", body = Vec<RoutableConnectorChoice>),
|
||||||
@ -286,9 +286,9 @@ pub async fn routing_update_default_config() {}
|
|||||||
/// Retrieve existing *profile*
|
/// Retrieve existing *profile*
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/profiles/{profile_id}",
|
path = "/v2/profiles/{id}",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
(
|
(
|
||||||
"X-Merchant-Id" = String, Header,
|
"X-Merchant-Id" = String, Header,
|
||||||
description = "Merchant ID of the profile.",
|
description = "Merchant ID of the profile.",
|
||||||
@ -311,9 +311,9 @@ pub async fn profile_retrieve() {}
|
|||||||
/// Retrieve active routing algorithm under the profile
|
/// Retrieve active routing algorithm under the profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/profiles/{profile_id}/routing_algorithm",
|
path = "/v2/profiles/{id}/routing_algorithm",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
("limit" = Option<u16>, Query, description = "The number of records of the algorithms to be returned"),
|
("limit" = Option<u16>, Query, description = "The number of records of the algorithms to be returned"),
|
||||||
("offset" = Option<u8>, Query, description = "The record offset of the algorithm from which to start gathering the results")),
|
("offset" = Option<u8>, Query, description = "The record offset of the algorithm from which to start gathering the results")),
|
||||||
responses(
|
responses(
|
||||||
@ -334,9 +334,9 @@ pub async fn routing_retrieve_linked_config() {}
|
|||||||
/// Retrieve the default fallback routing algorithm for the profile
|
/// Retrieve the default fallback routing algorithm for the profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/profiles/{profile_id}/fallback_routing",
|
path = "/v2/profiles/{id}/fallback_routing",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the profile"),
|
("id" = String, Path, description = "The unique identifier for the profile"),
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Successfully retrieved default fallback routing algorithm", body = Vec<RoutableConnectorChoice>),
|
(status = 200, description = "Successfully retrieved default fallback routing algorithm", body = Vec<RoutableConnectorChoice>),
|
||||||
@ -348,14 +348,14 @@ pub async fn routing_retrieve_linked_config() {}
|
|||||||
)]
|
)]
|
||||||
pub async fn routing_retrieve_default_config() {}
|
pub async fn routing_retrieve_default_config() {}
|
||||||
|
|
||||||
/// Merchant Connector - List
|
/// Profile - Connector Accounts List
|
||||||
///
|
///
|
||||||
/// List Merchant Connector Details for the business profile
|
/// List Connector Accounts for the profile
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/profiles/{profile_id}/connector_accounts",
|
path = "/v2/profiles/{id}/connector_accounts",
|
||||||
params(
|
params(
|
||||||
("profile_id" = String, Path, description = "The unique identifier for the business profile"),
|
("id" = String, Path, description = "The unique identifier for the business profile"),
|
||||||
(
|
(
|
||||||
"X-Merchant-Id" = String, Header,
|
"X-Merchant-Id" = String, Header,
|
||||||
description = "Merchant ID of the profile.",
|
description = "Merchant ID of the profile.",
|
||||||
|
|||||||
@ -94,9 +94,9 @@ pub async fn routing_retrieve_config() {}
|
|||||||
|
|
||||||
#[utoipa::path(
|
#[utoipa::path(
|
||||||
get,
|
get,
|
||||||
path = "/v2/routing_algorithm/{routing_algorithm_id}",
|
path = "/v2/routing_algorithm/{id}",
|
||||||
params(
|
params(
|
||||||
("routing_algorithm_id" = String, Path, description = "The unique identifier for a routing algorithm"),
|
("id" = String, Path, description = "The unique identifier for a routing algorithm"),
|
||||||
),
|
),
|
||||||
responses(
|
responses(
|
||||||
(status = 200, description = "Successfully fetched routing algorithm", body = MerchantRoutingAlgorithm),
|
(status = 200, description = "Successfully fetched routing algorithm", body = MerchantRoutingAlgorithm),
|
||||||
|
|||||||
Reference in New Issue
Block a user