Skip to content

pos-verify-vpa ​

Method: GET
Path: /pos/payments/verify-vpa

Tags: Payments

Summary ​

Verify VPA

Description ​

The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service to send or receive money. In the case of UPI collect VPA is the mandatory param and merchants are always advised to check if the VPA is valid or not. Validating the VPA will help in reducing the failure rate due to incorrect vpa.

Pos SDK Usage ​

SDK Method: pos.verifyVpa()

Example:

typescript
const { data, error } = await pos.verifyVpa({ vpa: "customer@upi" });

if (error) {
  console.error("VPA verification failed:", error.message);
} else if (data.status === "valid") {
  console.log("Paying to:", data.customer_name);
}

TypeScript Definition ​

typescript
"pos-verify-vpa": {
        parameters: {
            query: {
                /** @description The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service. */
                vpa: string;
            };
            header?: never;
            path?: never;
            cookie?: never;
        };
        requestBody?: never;
        responses: {
            /** @description OK */
            200: {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": {
                        message: string;
                        success: boolean;
                        content: {
                            vpa: string;
                            /** @enum {string} */
                            status: "valid" | "invalid" | "unknown";
                            customer_name: string;
                            /** @description Mandate details if available. */
                            mandate_details: {
                                /** @description Indicates whether the specific VPA handle is supported by the merchant's account. */
                                is_handle_supported?: boolean;
                            };
                        };
                    };
                };
            };
            /** @description The payment input or authentication attempt is invalid. */
            400: {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": {
                        message: string;
                        success: boolean;
                        code?: string;
                        errors?: Record<string, never>;
                    };
                };
            };
            401: components["responses"]["Unauthorized"];
            403: components["responses"]["Forbidden"];
            408: components["responses"]["RequestTimeout"];
            500: components["responses"]["InternalServerError"];
            504: components["responses"]["GatewayTimeout"];
        };
    };

Component References ​

ReferenceResolves To
components["responses"]["Unauthorized"]Unauthorized
components["responses"]["Forbidden"]Forbidden
components["responses"]["RequestTimeout"]RequestTimeout
components["responses"]["InternalServerError"]InternalServerError
components["responses"]["GatewayTimeout"]GatewayTimeout

Parameters ​

  • vpa (query): The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service.

Responses ​

200 ​

OK

400 ​

The payment input or authentication attempt is invalid.

401 ​

Authentication failed. Codes include token-required, token-expired and token_not_valid for an invalid or expired token.

403 ​

Access denied. token-required requires an authenticated session; permission-denied means the caller cannot access this resource. On POS, session-expired requires signing in again.

408 ​

500 ​

The request failed because of an unexpected error.

504 ​

The request timed out.

OpenAPI Definition ​

json
{
  "operationId": "pos-verify-vpa",
  "summary": "Verify VPA",
  "description": "The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service to send or receive money. In the case of UPI collect VPA is the mandatory param and merchants are always advised to check if the VPA is valid or not.\nValidating the VPA will help in reducing the failure rate due to incorrect vpa. ",
  "parameters": [
    {
      "name": "vpa",
      "in": "query",
      "description": "The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service.",
      "required": true,
      "schema": {
        "type": "string"
      }
    }
  ],
  "responses": {
    "200": {
      "description": "OK",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "message": {
                "type": "string"
              },
              "success": {
                "type": "boolean"
              },
              "content": {
                "properties": {
                  "vpa": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string",
                    "enum": [
                      "valid",
                      "invalid",
                      "unknown"
                    ]
                  },
                  "customer_name": {
                    "type": "string"
                  },
                  "mandate_details": {
                    "description": "Mandate details if available.",
                    "type": "object",
                    "properties": {
                      "is_handle_supported": {
                        "description": "Indicates whether the specific VPA handle is supported by the merchant's account.",
                        "type": "boolean"
                      }
                    }
                  }
                },
                "required": [
                  "vpa",
                  "status",
                  "customer_name",
                  "mandate_details"
                ],
                "type": "object"
              }
            },
            "required": [
              "message",
              "success",
              "content"
            ]
          }
        }
      },
      "links": {
        "CreateOrderWithUpiCollect": {
          "operationId": "create-pos-order",
          "description": "Create a POS order from a cart."
        }
      }
    },
    "400": {
      "description": "The payment input or authentication attempt is invalid.",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "message": {
                "type": "string",
                "x-speakeasy-error-message": true
              },
              "success": {
                "type": "boolean"
              },
              "code": {
                "type": "string"
              },
              "errors": {
                "type": "object"
              }
            },
            "required": [
              "message",
              "success"
            ]
          }
        }
      }
    },
    "401": {
      "$ref": "#/components/responses/Unauthorized"
    },
    "403": {
      "$ref": "#/components/responses/Forbidden"
    },
    "408": {
      "$ref": "#/components/responses/RequestTimeout"
    },
    "500": {
      "$ref": "#/components/responses/InternalServerError"
    },
    "504": {
      "$ref": "#/components/responses/GatewayTimeout"
    }
  },
  "externalDocs": {
    "url": "https://llm-docs.commercengine.io/admin-pos/operations/pos-verify-vpa"
  },
  "security": [
    {
      "Authorization": []
    }
  ],
  "tags": [
    "Payments"
  ],
  "x-speakeasy-group": "pos",
  "x-speakeasy-name-override": "verifyVpa"
}

Auto-generated from OpenAPI spec and TypeScript definitions

Last updated: