Payment Method Resource

Payment Method Resource

Attention

PaymentMethod resources are read-only by default. Please contact us if you need write permissions.


Get Payment Methods

GET /api/payment_methods.json

  • GET /api/payment_methods.json will return the first 150 (default limit) payment methods. You can increase the limit to a maximum of 250 payment methods. See the Filter Payment Methods endpoint for more info.
Example:
$ curl -s \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-u APP_API_KEY:APP_API_PASSWORD \
-X GET \
http://shop_subdomain.versacommerce.de/api/payment_methods.json

Status: 200 OK

[
  {
    "payment_method": {
      "active": true,
      "cost": "2.5",
      "description": "Der DHL - Bote nimmt den Betrag bei Auslieferung entgegen.",
      "gateway": "0",
      "id": 100,
      "name": "cod",
      "registered_customer_only": false,
      "title": "Nachnahme"
    }
  },
  {
    "payment_method": {
      "active": true,
      "cost": "0.0",
      "description": "",
      "gateway": "paypal",
      "id": 101,
      "name": "paypal",
      "registered_customer_only": false,
      "title": "PayPal"
    }
  },
  {
    "payment_method": {
      "active": true,
      "cost": "0.0",
      "description": "",
      "gateway": "stripe",
      "id": 102,
      "name": "cc",
      "registered_customer_only": false,
      "title": "Kreditkarte"
    }
  }
]


Get Payment Method

GET /api/payment_methods/:payment_method_id.json

  • GET /api/payment_methods/:payment_method_id.json will return the specified payment method.
Example:
$ curl -s \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-u APP_API_KEY:APP_API_PASSWORD \
-X GET \
http://shop_subdomain.versacommerce.de/api/payment_methods/:payment_method_id.json

Status: 200 OK

{
  "payment_method": {
    "active": true,
    "cost": "0.0",
    "description": "",
    "gateway": "paypal",
    "id": 101,
    "name": "paypal",
    "registered_customer_only": false,
    "title": "PayPal"
  }
}


Get Payment Methods Count

GET /api/payment_methods/count.json

  • GET /api/payment_methods/count.json will return the payment methods count.
Example:
$ curl -s \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-u APP_API_KEY:APP_API_PASSWORD \
-X GET \
http://shop_subdomain.versacommerce.de/api/payment_methods/count.json

Status: 200 OK

{
  "count": 3
}


Filter Payment Methods

GET /api/payment_methods.json?filter_name 1 = filter_value 1 & filter_name 2 = filter_value 2

  • GET /api/payment_methods.json?filter_name_1=filter_value_1&filter_name_2=filter_value_2 will return a filtered list of products. See the Get Payment Methods endpoint for more info about the output.

Available Filters and Options

Filter-/Optionname
Description
Type
Parameter
limit
The amount of results, defaults to 150, maximum are 250
Integer
limit=10
offset
The amount of results to omit
Integer
offset=10
active
Filter by active
Boolean
active=true
name
Filter by name
String
name=paypal
registered_customer_only
Filter by registered_customer_only
Boolean
registered_customer_only =true
id_min
Filter payment methods by the minimum id
Integer
id_min=10
id_max
Filter payment methods by the maximum id
Integer
id_max=10
cost_min
Filter payment methods by the minimum price
BigDecimal
cost_min=100.0
cost_max
Filter payment methods by the maximum price
BigDecimal
cost_max=100.0


  • GET /api/payment_methods.json?active=true&cost_max=0.00 will return all products and variants (not nested). See the Get Payment Methods endpoint for more info about the output.
Example:
$ curl -s \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-u APP_API_KEY:APP_API_PASSWORD \
-X GET \
http://shop_subdomain.versacommerce.de/api/payment_methods.json?active=true&cost_max=0.00

Status: 200 OK

[
  {
    "payment_method": {
      "active": true,
      "cost": "0.0",
      "description": "",
      "gateway": "paypal",
      "id": 101,
      "name": "paypal",
      "registered_customer_only": false,
      "title": "PayPal"
    }
  },
  {
    "payment_method": {
      "active": true,
      "cost": "0.0",
      "description": "",
      "gateway": "stripe",
      "id": 102,
      "name": "cc",
      "registered_customer_only": false,
      "title": "Kreditkarte"
    }
  }
]


    • Related Articles

    • Payment Resource

      Payment resources are read-only by default. Please contact us if you need write permissions. Payment Categories Payment category English German cod Cash on delivery Bezahlung bei Lieferung custom Custom Eigene Zahlart bank_deposit Bank deposit ...
    • Order Resource

      Attention Order resources are read-only by default. Please contact us for access. ​ Order Statuses Order Status English German open new order Neue Bestellung in_progress in progress, started processing Bearbeitung begonnen cancelled order was ...
    • Shop Resource

      Current Shop Informations GET /api/shop.json GET /api/shop.json​ will return informations about the current shop. Example: $ curl -s \ -H 'Accept: application/json' \ -H 'Content-Type: application/json' \ -u APP_API_KEY:APP_API_PASSWORD \ -X GET \ ...
    • Metafield Resource

      Metafield Resource Get Metafields Get Metafield Create Metafield Update Metafield Delete Metafield Get Metafield Count Filter Metafields Get Metfields GET /api/metafields.json GET /api/metafields.json will return all Metafields. See the Filter ...
    • Product Image Resource

      Product Image Resource Bulk Create Or Update Delete Product Images Bulk Create or Update PUT /api/products/1/.json PUT /api/products/1.json will create or update the product images from the parameters passed. Example: $ curl -s \ -H 'Accept: ...