Skip to content

list-payment-methods

Method: GET
Path: /payments/payment-methods

Tags: Payments

Summary

List all payment methods

Description

List all payment methods

TypeScript Definition

typescript
"list-payment-methods": {
        parameters: {
            query: {
                /** @description payment gateway code */
                payment_gateway: components["schemas"]["PaymentGateway"];
            };
            header?: never;
            path?: never;
            cookie?: never;
        };
        requestBody?: never;
        responses: {
            /** @description OK */
            200: {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": {
                        message?: string;
                        success?: boolean;
                        content?: {
                            payment_methods?: (components["schemas"]["PayuPaymentMethod"] | components["schemas"]["JuspayPaymentMethod"])[];
                        };
                    };
                };
            };
            400: components["responses"]["BadRequest"];
            401: components["responses"]["Unauthorized"];
            404: components["responses"]["NotFound"];
        };
    };

Component References

ReferenceResolves To
components["schemas"]["PaymentGateway"]PaymentGateway
components["schemas"]["PayuPaymentMethod"]PayuPaymentMethod
components["schemas"]["JuspayPaymentMethod"]JuspayPaymentMethod
components["responses"]["BadRequest"]BadRequest
components["responses"]["Unauthorized"]Unauthorized
components["responses"]["NotFound"]NotFound

Parameters

  • payment_gateway (query): payment gateway code

Responses

200

OK

400

Bad request

401

Not authorized for given operation on the Resource

404

Requested resource not found

OpenAPI Definition

json
{
  "tags": [
    "Payments"
  ],
  "operationId": "list-payment-methods",
  "summary": "List all payment methods",
  "description": "List all payment methods",
  "externalDocs": {
    "url": "https://llm-docs.commercengine.io/storefront/operations/list-payment-methods",
    "description": "API reference for the list-payment-methods operation"
  },
  "parameters": [
    {
      "name": "payment_gateway",
      "in": "query",
      "description": "payment gateway code",
      "required": true,
      "schema": {
        "$ref": "#/components/schemas/PaymentGateway"
      }
    }
  ],
  "responses": {
    "200": {
      "description": "OK",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "message": {
                "type": "string"
              },
              "success": {
                "type": "boolean"
              },
              "content": {
                "properties": {
                  "payment_methods": {
                    "type": "array",
                    "items": {
                      "oneOf": [
                        {
                          "$ref": "#/components/schemas/PayuPaymentMethod"
                        },
                        {
                          "$ref": "#/components/schemas/JuspayPaymentMethod"
                        }
                      ]
                    }
                  }
                },
                "type": "object"
              }
            }
          }
        }
      }
    },
    "400": {
      "$ref": "#/components/responses/BadRequest"
    },
    "401": {
      "$ref": "#/components/responses/Unauthorized"
    },
    "404": {
      "$ref": "#/components/responses/NotFound"
    }
  },
  "security": [
    {
      "Authorization": []
    }
  ],
  "x-speakeasy-group": "payments",
  "x-speakeasy-ignore": true,
  "x-speakeasy-name-override": "listPaymentMethods"
}

Auto-generated from OpenAPI spec and TypeScript definitions

Last updated: