NAV
shell php python

Introduction

Welcome to the Paymattic API document. This document will describe the REST API Endpoints of Paymattic.

The example API documentation page was created with Slate. If you find any typo or would like contribute please send a pull request with improvements. Please note that, All endpoints are not added to this doc (Work in progress).

Authentication

Example API Call for forms:



# With shell, you can just pass the correct header with each request, Basic Auth credentials need to be base64 encoded.
curl "https://yourdomain.com/wp-json/wppayform/v2/forms" \
  -H "Authorization: Basic $(echo -n 'USERNAME:APPLICATION_PASSWORD' | base64)"

Make sure to replace USERNAME & APPLICATION_PASSWORD with your username & application password and have base64 encoded.

Paymattic uses WordPress REST API. So you can use any authorization method that supports WordPress. The easiest way to connect is application password. To create a application password go to the Users and click on the user and create a new application password for this user so that this person can easily access the REST API endpoint by using WP Username & Application password in basic auth system.

Once you create your Application Password in WordPress, Add Authorization Header to every request.

In the basic auth username section use your WP Username and in the password section use the created Application Password.

Api Base URL: https://yourdomain.com/wp-json/wppayform/v2

Forms

Get All Forms



curl "https://yourdomain.com/wp-json/wppayform/v2/forms" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"

The above command returns JSON structured like this:

[
  {
    "ID": "32",
    "post_author": "1",
    "post_date": "2022-07-21 05:02:56",
    "post_date_gmt": "2022-07-21 05:02:56",
    "post_content": "",
    "post_title": "Event Registration Form (#32)",
    "post_excerpt": "",
    "post_status": "publish",
    "comment_status": "closed",
    "ping_status": "closed",
    "post_password": "",
    "post_name": "event-registration-form",
    "to_ping": "",
    "pinged": "",
    "post_modified": "2022-07-21 05:02:56",
    "post_modified_gmt": "2022-07-21 05:02:56",
    "post_content_filtered": "",
    "post_parent": "0",
    "guid": "http://wp.test/?p=32",
    "menu_order": "0",
    "post_type": "wp_payform",
    "post_mime_type": "",
    "comment_count": "0",
    "preview_url": "http://wp.test/?wp_paymentform_preview=32",
    "entries_count": 0
  },
  {
    "ID": "30",
    "post_author": "1",
    "post_date": "2022-07-20 05:38:14",
    "post_date_gmt": "2022-07-20 05:38:14",
    "post_content": "",
    "post_title": "Blank Form (#30)",
    "post_excerpt": "",
    "post_status": "publish",
    "comment_status": "closed",
    "ping_status": "closed",
    "post_password": "",
    "post_name": "blank-form-2",
    "to_ping": "",
    "pinged": "",
    "post_modified": "2022-07-20 05:38:14",
    "post_modified_gmt": "2022-07-20 05:38:14",
    "post_content_filtered": "",
    "post_parent": "0",
    "guid": "http://wp.test/?p=30",
    "menu_order": "0",
    "post_type": "wp_payform",
    "post_mime_type": "",
    "comment_count": "0",
    "preview_url": "http://wp.test/?wp_paymentform_preview=30",
    "entries_count": 2
  },
]

This endpoint retrieves all forms.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/forms

Query Parameters

Parameter Type Description Required Default
per_page int Forms per page. false 20
page int Page number of pagination false 1
search string Search by forms title false
order_type string ASC/DESC false ASC

Create a form



curl "https://yourdomain.com/wp-json/wppayform/v2/forms" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
    "message":"Form successfully created.",
    "form_id":34
}

The second command returns JSON structured like this:

{
    "message":"Setting successfully created.",
}

This first endpoint creates a new blank form. Using this endpoint you will be able to create a new blank form with required params. However, to create a full workable form run the second endpoint providing form fields as builder_settings param and submit button settings as submit_button_settings.

HTTP Requests

POST https://yourdomain.com/wp-json/wppayform/v2/forms

POST https://yourdomain.com/wp-json/wppayform/v2/form/{id}/

URL Parameters for first end point

Parameter type Required Description
post_title string true The title of the form
template string true Name of the form template

URL Parameters for second end point

Parameter type Required Description
id int true The newly created form id.
builder_settings json true All the fields and settings in a json format
submit_button_settings json true Submit button settings in a json format

Get a specific form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
    "ID": 35,
    "post_author": "1",
    "post_date": "2022-07-26 08:36:37",
    "post_date_gmt": "2022-07-26 08:36:37",
    "post_content": "",
    "post_title": "Thanksgiving Donation Form (#35)",
    "post_excerpt": "",
    "post_status": "publish",
    "comment_status": "closed",
    "ping_status": "closed",
    "post_password": "",
    "post_name": "thanksgiving-donation-form",
    "to_ping": "",
    "pinged": "",
    "post_modified": "2022-07-26 08:36:37",
    "post_modified_gmt": "2022-07-26 08:36:37",
    "post_content_filtered": "",
    "post_parent": 0,
    "guid": "http://wp.test/?p=35",
    "menu_order": 0,
    "post_type": "wp_payform",
    "post_mime_type": "",
    "comment_count": "0",
    "filter": "raw",
    "show_title_description": "yes",
    "preview_url": "http://wp.test/?wp_paymentform_preview=35"
}

The endpoint return a specific form in a json format. Using this endpoint you will get all the data of a form.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}

URL Parameters for first end point

Parameter type Required Description
id string true The specific form id

Update a form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The above command returns JSON structured like this:

{
   "message" : "Settings successfully updated"
}

The endpoint update a specific form. Using this endpoint you will get to update a form.

HTTP Request

POST https://yourdomain.com/wp-json/wppayform/v2/form/{id}

URL Parameters for first end point

Parameter type Required Description
id int true The newly created form id.
builder_settings json object true All the fields and settings in a json format
submit_button_settings json object true Submit button settings in a json format

Delete a form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The above command returns JSON structured like this:

{
    "message" : "Selected form successfully deleted"
}

The endpoint delete a specific form.

HTTP Request

DELETE https://yourdomain.com/wp-json/wppayform/v2/form/{id}

URL Parameters for first end point

Parameter type Required Description
id string true The specific form id

Get demo forms



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/demo" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
   "demo_forms": {
        "blank_form": {
            "label": "Blank Form",
            "description": "Create a blank form",
            "category": "Basic",
            "preview_image": "http://wp.test/wp-content/plugins/wp-payment-form/assets/images/forms/demo_blank.png",
            "is_pro": false
        },
        "contact_form": {
            "label": "Contact Form",
            "description": "Create a simple contact form.",
            "category": "Basic",
            "preview_image": "http://wp.test/wp-content/plugins/wp-payment-form/assets/images/forms/demo_form2.png",
            "is_pro": false
        },
        "donation_form": {
            "label": "Donation Form",
            "description": "Create a simple Donation form.",
            "category": "Donation",
            "preview_image": "http://wp.test/wp-content/plugins/wp-payment-form/assets/images/forms/demo_form.png",
            "is_pro": false
        },
   }
}

This endpoint return demo froms. Using this endpoint you will be able to get different demo forms.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/demo

List of available forms



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/formatted" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
  "available_forms": [
        {
            "ID": "35",
            "post_title": "Thanksgiving Donation Form (#35)"
        },
        {
            "ID": "34",
            "post_title": "Collect Donations(#34)"
        },
        {
            "ID": "33",
            "post_title": "Make a subscription (#33)"
        },
    ]
}

This endpoint return list of available forms. No url paramaters required.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/formatted

Export a form



curl "https://yourdomain.com/wp-json/wppayform/v2/tools/form/{id}/export/" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns a downloadable json file:

This endpoint make a form get downloaded as a json file.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/tools/form/{id}/export/

URL Parameters for first end point

Parameter type Required Description
id string true The specific form id

Coupons

Get coupons



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/coupon" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command return json structured like this.

{
    "coupon_status": "yes",
    "coupons": [
        {
            "id": 1,
            "title": "Eid",
            "code": "123",
            "coupon_type": "percent",
            "amount": "5.00",
            "status": "active",
            "stackable": "no",
            "settings": {
                "allowed_form_ids": []
            },
            "created_by": "1",
            "min_amount": "455",
            "max_use": "0",
            "start_date": "2022-07-03",
            "expire_date": "2022-07-30",
            "created_at": "2022-07-29 04:04:52",
            "updated_at": "2022-07-29 04:04:52"
        }
    ],
    "total": 1,
    "available_forms": {
        "38": "Donate For Education Forms (#38)",
        "37": "Blank Form (#37)",
        "36": "Walk-a-Thon Registration Form (#36)",
        "35": "Thanksgiving Donation Form (#35)",
        "34": "Contact Form (#34)",
        "33": "Blank Form (#33)",
        "32": "Event Registration Form (#32)",
        "30": "Blank Form (#30)",
        "29": "Credit Card Donation Form (#29)",
        "8": "Contact Form (#8)",
        "7": "Blank Form (#7)"
    }
}

This endpoint retrieves all available coupons.

HTTP Request

GET https://yourdomain.com/wp-json/wppayform/v2/settings/coupon

URL Parameters for first end point

Parameter type Required Description
pagination object true The pagination object consists of per_page, current_page fields.
per_page int true Ex: per page 15,20
current_page int true Ex: current page 1

Save coupons



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/coupon" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The above command returns json structured like this.

{
    "message": "Coupon has been created successfully"
}

This endpoint will create a coupon upon providing the required values.

HTTP Request

POST https://yourdomain.com/wp-json/wppayform/v2/settings/coupon

URL Parameters for first end point

Parameter type Required Description
coupon json object true The coupon object consists of title, code, amount, coupon_type, status, start_date, expire_date, settings fields.
title string true Title of the coupon.
code string true Unique coupon code.
coupon_type string true Coupon type percent, fixed.
amount int true Coupon percentage.
status string true The coupon status active, inactive
settings json object true Allowed form ids will be included in settings, default: [].
start_date date false Coupon starting date.
expire_date date false Couon expire Date.

Delete a coupon



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/coupon" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The above command returns json structured like this:

{
    "message": "Coupon has been successfully deleted"
}

This endpoint delete a coupon upon providing the coupon id.

HTTP Request

DELETE https://yourdomain.com/wp-json/wppayform/v2/settings/coupon

URL Parameters for first end point

Parameter type Required Description
coupon_id int true ID of the coupon

Form Settings

Get Form settings



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "confirmation_settings":{
      "confirmation_type":"custom",
      "redirectTo":"samePage",
      "customUrl":"",
      "messageToShow":"<p>Form has been successfully submitted</p>",
      "samePageFormBehavior":"hide_form"
   },
   "receipt_settings":{
      "receipt_header":"Thanks for your submission. Here are the details of your submission:",
      "receipt_footer":"",
      "info_modules":{
         "input_details":"yes",
         "payment_info":"yes"
      }
   },
   "currency_settings":{
      "currency":"USD",
      "locale":"auto",
      "currency_sign_position":"left",
      "currency_separator":"dot_comma",
      "decimal_points":0,
      "settings_type":"global",
      "is_zero_decimal":false
   },
   "editor_shortcodes":{
      "submission":{
         "title":"Submission Info",
         "placeholders":{
            "submission.id":{
               "tag":"{submission.id}",
               "label":"Submission ID",
               "callback":null
            },
            "submission.submission_hash":{
               "tag":"{submission.submission_hash}",
               "label":"Submission Hash ID",
               "callback":null
            },
            "submission.customer_name":{
               "tag":"{submission.customer_name}",
               "label":"Customer Name",
               "callback":null
            },
            "submission.customer_email":{
               "tag":"{submission.customer_email}",
               "label":"Customer Email",
               "callback":null
            },
            "submission.payment_method":{
               "tag":"{submission.payment_method}",
               "label":"Payment Method",
               "callback":null
            },
            "submission.all_input_field_html":{
               "tag":"{submission.all_input_field_html}",
               "label":"All Input Field",
               "callback":null
            },
            "submission.all_input_field_html_with_empty":{
               "tag":"{submission.all_input_field_html_with_empty}",
               "label":"All Input Field With Empty Fields",
               "callback":null
            },
            "submission.payment_receipt":{
               "tag":"{submission.payment_receipt}",
               "label":"Payment Receipt",
               "callback":null
            }
         }
      },
      "input":{
         "title":"Inputs",
         "placeholders":{
            "input.customer_name":{
               "tag":"{input.customer_name}",
               "label":"Name",
               "callback":null
            },
            "input.customer_email":{
               "tag":"{input.customer_email}",
               "label":"Email Address",
               "callback":null
            }
         }
      },
      "payment":{
         "title":"Payment Items",
         "placeholders":[

         ]
      },
      "wp":{
         "title":"WordPress",
         "placeholders":{
            "post_id":{
               "id":"id",
               "tag":"{wp:post_id}",
               "label":"Post ID",
               "callback":"post_id"
            },
            "post_title":{
               "id":"title",
               "tag":"{wp:post_title}",
               "label":"Post Title",
               "callback":"post_title"
            },
            "post_url":{
               "id":"url",
               "tag":"{wp:post_url}",
               "label":"Post URL",
               "callback":"post_url"
            },
            "post_author":{
               "id":"author",
               "tag":"{wp:post_author}",
               "label":"Post Author",
               "callback":"post_author"
            },
            "post_author_email":{
               "id":"author_email",
               "tag":"{wp:post_author_email}",
               "label":"Post Author Email",
               "callback":"post_author_email"
            },
            "post_meta":{
               "id":"post_meta",
               "tag":"{post_meta:YOUR_META_KEY}",
               "label":"Post Meta",
               "callback":null
            },
            "user_id":{
               "id":"user_id",
               "tag":"{wp:user_id}",
               "label":"User ID",
               "callback":"user_id"
            },
            "user_first_name":{
               "id":"first_name",
               "tag":"{wp:user_first_name}",
               "label":"User First Name",
               "callback":"user_first_name"
            },
            "user_last_name":{
               "id":"last_name",
               "tag":"{wp:user_last_name}",
               "label":"User Last Name",
               "callback":"user_last_name"
            },
            "user_display_name":{
               "id":"display_name",
               "tag":"{wp:user_display_name}",
               "label":"User Display Name",
               "callback":"user_display_name"
            },
            "user_email":{
               "id":"user_email",
               "tag":"{wp:user_email}",
               "label":"User Email",
               "callback":"user_email"
            },
            "user_url":{
               "id":"user_url",
               "tag":"{wp:user_url}",
               "label":"User URL",
               "callback":"user_url"
            },
            "user_meta":{
               "id":"user_meta",
               "tag":"{user_meta:YOUR_META_KEY}",
               "label":"User Meta",
               "callback":null
            },
            "site_title":{
               "id":"site_title",
               "tag":"{wp:site_title}",
               "label":"Site Title",
               "callback":"site_title"
            },
            "site_url":{
               "id":"site_url",
               "tag":"{wp:site_url}",
               "label":"Site URL",
               "callback":"site_url"
            },
            "admin_email":{
               "id":"admin_email",
               "tag":"{wp:admin_email}",
               "label":"Admin Email",
               "callback":"admin_email"
            }
         }
      },
      "other":{
         "title":"Other",
         "placeholders":{
            "querystring":{
               "tag":"{querystring:YOUR_KEY}",
               "label":"Query String",
               "callback":null
            },
            "date":{
               "id":"date",
               "tag":"{other:date}",
               "label":"Date",
               "callback":"system_date"
            },
            "time":{
               "id":"time",
               "tag":"{other:time}",
               "label":"Time",
               "callback":"system_time"
            },
            "ip":{
               "id":"ip",
               "tag":"{other:user_ip}",
               "label":"User IP Address",
               "callback":"user_ip"
            }
         }
      }
   },
   "currencies":{
      "AED":"United Arab Emirates Dirham",
      "AFN":"Afghan Afghani",
      "ALL":"Albanian Lek"
   },
   "locales":{
      "":"English (en) (default)",
      "auto":"Auto-detect locale",
      "zh":"Simplified Chinese (zh)",
      "da":"Danish (da)",
      "nl":"Dutch (nl)",
      "fi":"Finnish (fi)",
      "fr":"French (fr)",
      "de":"German (de)",
      "it":"Italian (it)",
      "ja":"Japanese (ja)",
      "no":"Norwegian (no)",
      "es":"Spanish (es)",
      "sv":"Swedish (sv)"
   },
   "pages":[
      {
         "ID":"2",
         "post_title":"Sample Page"
      },
      {
         "ID":"5",
         "post_title":"Payment Confirmation"
      },
      {
         "ID":"6",
         "post_title":"Payment Failed"
      }
   ],
   "recaptcha_settings":{
      "recaptcha_version":"none",
      "site_key":"",
      "secret_key":"",
      "all_forms":"no"
   },
   "form_recaptcha_status":""
}

This endpoint retrieves all the related settings of a form.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings

URL parameters

Parameter type Required Description
id int true The form id

Get Form design settings



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings/design" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "layout_settings": {
        "labelPlacement": "top",
        "asteriskPlacement": "none",
        "submit_button_position": "left",
        "extra_styles": {
            "wpf_default_form_styles": "yes",
            "wpf_bold_labels": "no"
        }
    }
}

This endpoint retreives all the design settings of a form.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings/design

URL parameters

Parameter type Required Description
id int true The form id

Save Form design settings



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings/design" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
    "message": "Settings successfully updated"
}

This endpoitn save the design settings of a form.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/form/{id}/settings/design

URL parameters

Parameter type Required Description
id int true The form id
layout_settings json object true Layout settings has fields labelPlacement, asteriskPlacement, submit_button_position

Global Settings

Get currency settings



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "currency_settings": {
        "currency": "USD",
        "locale": "auto",
        "currency_sign_position": "left",
        "currency_separator": "dot_comma",
        "decimal_points": 0,
        "settings_type": "global",
        "is_zero_decimal": false
        },
    "currencies": {
        "AED": "United Arab Emirates Dirham",
        "AFN": "Afghan Afghani",
        "ALL": "Albanian Lek",
        "AMD": "Armenian Dram",
        "ANG": "Netherlands Antillean Gulden",
        "AOA": "Angolan Kwanza",
        "ARS": "Argentine Peso",
        "AUD": "Australian Dollar",
        "AWG": "Aruban Florin",
        "AZN": "Azerbaijani Manat",
        "BAM": "Bosnia & Herzegovina Convertible Mark",
        "BBD": "Barbadian Dollar",
        "BDT": "Bangladeshi Taka",
        "BIF": "Burundian Franc",
        "BGN": "Bulgarian Lev",
        "BMD": "Bermudian Dollar",
        "BND": "Brunei Dollar",
        "BOB": "Bolivian Boliviano",
        "BRL": "Brazilian Real",
        "BSD": "Bahamian Dollar",
        "BWP": "Botswana Pula",
        "BZD": "Belize Dollar",
        "CAD": "Canadian Dollar",
        "CDF": "Congolese Franc",
        "CHF": "Swiss Franc",
        "CLP": "Chilean Peso",
        "CNY": "Chinese Renminbi Yuan",
        "COP": "Colombian Peso",
        "CRC": "Costa Rican Colón",
        "CVE": "Cape Verdean Escudo",
        "CZK": "Czech Koruna",
        "DJF": "Djiboutian Franc",
        "DKK": "Danish Krone",
        "DOP": "Dominican Peso",
        "DZD": "Algerian Dinar",
        "EGP": "Egyptian Pound",
        "ETB": "Ethiopian Birr",
        "EUR": "Euro",
        "FJD": "Fijian Dollar",
        "FKP": "Falkland Islands Pound",
        "GBP": "British Pound",
        "GEL": "Georgian Lari",
        "GIP": "Gibraltar Pound",
        "GMD": "Gambian Dalasi",
        "GNF": "Guinean Franc",
        "GTQ": "Guatemalan Quetzal",
        "GYD": "Guyanese Dollar",
        "HKD": "Hong Kong Dollar",
        "HNL": "Honduran Lempira",
        "HRK": "Croatian Kuna",
        "HTG": "Haitian Gourde",
        "HUF": "Hungarian Forint",
        "IDR": "Indonesian Rupiah",
        "ILS": "Israeli New Sheqel",
        "INR": "Indian Rupee",
        "ISK": "Icelandic Króna",
        "JMD": "Jamaican Dollar",
        "JPY": "Japanese Yen",
        "KES": "Kenyan Shilling",
        "KGS": "Kyrgyzstani Som",
        "KHR": "Cambodian Riel",
        "KMF": "Comorian Franc",
        "KRW": "South Korean Won",
        "KYD": "Cayman Islands Dollar",
        "KZT": "Kazakhstani Tenge",
        "LAK": "Lao Kip",
        "LBP": "Lebanese Pound",
        "LKR": "Sri Lankan Rupee",
        "LRD": "Liberian Dollar",
        "LSL": "Lesotho Loti",
        "MAD": "Moroccan Dirham",
        "MDL": "Moldovan Leu",
        "MGA": "Malagasy Ariary",
        "MKD": "Macedonian Denar",
        "MNT": "Mongolian Tögrög",
        "MOP": "Macanese Pataca",
        "MRO": "Mauritanian Ouguiya",
        "MUR": "Mauritian Rupee",
        "MVR": "Maldivian Rufiyaa",
        "MWK": "Malawian Kwacha",
        "MXN": "Mexican Peso",
        "MYR": "Malaysian Ringgit",
        "MZN": "Mozambican Metical",
        "NAD": "Namibian Dollar",
        "NGN": "Nigerian Naira",
        "NIO": "Nicaraguan Córdoba",
        "NOK": "Norwegian Krone",
        "NPR": "Nepalese Rupee",
        "NZD": "New Zealand Dollar",
        "PAB": "Panamanian Balboa",
        "PEN": "Peruvian Nuevo Sol",
        "PGK": "Papua New Guinean Kina",
        "PHP": "Philippine Peso",
        "PKR": "Pakistani Rupee",
        "PLN": "Polish Złoty",
        "PYG": "Paraguayan Guaraní",
        "QAR": "Qatari Riyal",
        "RON": "Romanian Leu",
        "RSD": "Serbian Dinar",
        "RUB": "Russian Ruble",
        "RWF": "Rwandan Franc",
        "SAR": "Saudi Riyal",
        "SBD": "Solomon Islands Dollar",
        "SCR": "Seychellois Rupee",
        "SEK": "Swedish Krona",
        "SGD": "Singapore Dollar",
        "SHP": "Saint Helenian Pound",
        "SLL": "Sierra Leonean Leone",
        "SOS": "Somali Shilling",
        "SRD": "Surinamese Dollar",
        "STD": "São Tomé and Príncipe Dobra",
        "SVC": "Salvadoran Colón",
        "SZL": "Swazi Lilangeni",
        "THB": "Thai Baht",
        "TJS": "Tajikistani Somoni",
        "TOP": "Tongan Paʻanga",
        "TRY": "Turkish Lira",
        "TTD": "Trinidad and Tobago Dollar",
        "TWD": "New Taiwan Dollar",
        "TZS": "Tanzanian Shilling",
        "UAH": "Ukrainian Hryvnia",
        "UGX": "Ugandan Shilling",
        "USD": "United States Dollar",
        "UYU": "Uruguayan Peso",
        "UZS": "Uzbekistani Som",
        "VND": "Vietnamese Đồng",
        "VUV": "Vanuatu Vatu",
        "WST": "Samoan Tala",
        "XAF": "Central African Cfa Franc",
        "XCD": "East Caribbean Dollar",
        "XOF": "West African Cfa Franc",
        "XPF": "Cfp Franc",
        "YER": "Yemeni Rial",
        "ZAR": "South African Rand",
        "ZMW": "Zambian Kwacha"
    },
    "locales": {
        "": "English (en) (default)",
        "auto": "Auto-detect locale",
        "zh": "Simplified Chinese (zh)",
        "da": "Danish (da)",
        "nl": "Dutch (nl)",
        "fi": "Finnish (fi)",
        "fr": "French (fr)",
        "de": "German (de)",
        "it": "Italian (it)",
        "ja": "Japanese (ja)",
        "no": "Norwegian (no)",
        "es": "Spanish (es)",
        "sv": "Swedish (sv)"
        },
    "ip_logging_status": "yes",
    "honeypot_status": "yes",
    "abandoned_time": 3
}

This endpoint return global currecny settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies

Save global currency settings



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
    "message": "Successfully updated settings"
}

This endpoint saves global currency settings.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies

URL parameters

Parameter type Required Description
settings json object true The currency settings

Get access roles



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "roles": {
        "capability": [],
        "roles": []
    }
}

This endpoint gets access roles.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/settings/rules

Set access roles



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/currencies" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
   "message": "Successfully updated the role(s)."
}

This endpoint set global roles.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/forms/settings/rules

URL paramaters

Parameter type Required Description
capability array true The capabilities : admin, moderator

Get stripe settings



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/stripe" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "settings": {
        "payment_mode": "test",
        "live_pub_key": "",
        "live_secret_key": "",
        "test_pub_key": "pk_test_8cp7uwcwXqjYxowDJnuNH8az",
        "test_secret_key": "sk_test_R1ANXvGZyZ1omGhmXXRUIVul",
        "company_name": "",
        "checkout_logo": "",
        "send_meta_data": "no"
    },
    "webhook_url": "https://wp.test/?wpf_stripe_listener=1",
    "is_key_defined": false
}

This endpoint return stripe settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/settings/stripe

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/forms/settings/stripe

URL parameters

Parameter type Required Description
settings json true The settings - payment_mode, test_public_key, test_secret_key, live_pub_key, live_secret_key

Get integrations



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/integrations" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
  "success": false,
  "data": {
    "settings": [],
    "settings_key": "",
    "message": "Sorry! No integration failed found with: "
   }
}

This endpoint return all global integration addons.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/settings/integrations

License

license settings



curl "https://yourdomain.com/wp-json/wppayform/v2/license" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "price_id": "",
    "expires": "",
    "status": "unregistered",
    "purchase_url": "https://wpmanageninja.com/downloads/wppayform-pro-wordpress-payments-form-builder/"
}

This endpoint returns the License settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/license

Save/Update license



curl "https://yourdomain.com/wp-json/wppayform/v2/license" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
    "message" : "Your license key has been successfully updated"
}

This endpoint saves/updates license.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/license

URL parameters

Parameter type Required Description
license_key string true The given license key after purchasing.

Deactivate license



curl "https://yourdomain.com/wp-json/wppayform/v2/license" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The first command returns JSON structured like this:

{
    "message" : "Your license key has been successfully deactivated"
}

This endpoint deactivate license.

Http request

DELETE https://yourdomain.com/wp-json/wppayform/v2/license

Entries

Get entries



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns json structured like this:

{
   "success":true,
   "data":{
      "submissions":[
         {
            "id":72,
            "form_id":"29",
            "user_id":"1",
            "customer_id":null,
            "customer_name":"ENIWeop5dD",
            "customer_email":"1c5jc@k1zw.com",
            "form_data_raw":{
               "__wpf_form_id":"29",
               "__wpf_current_url":"http://wp.test/?wp_paymentform_preview=29",
               "__wpf_current_page_id":"",
               "custom_payment_input":"512560",
               "customer_name":"ENIWeop5dD",
               "customer_name_1":"IA4IGMhVEY",
               "customer_email":"1c5jc@k1zw.com",
               "number":"034341",
               "address_input":{
                  "address_line_1":"8ZgDyq1xEC",
                  "address_line_2":"4iIftJAnDH",
                  "city":"crVOXHdCP1",
                  "state":"vyI8J5dZcU",
                  "zip_code":"mB98SQ8j6W",
                  "country":"AF"
               },
               "__stripe_payment_method_id":"pm_1LPP4yIyGOUknw8lkvqYV2gC"
            },
            "form_data_formatted":{
               "customer_name":"ENIWeop5dD",
               "customer_name_1":"IA4IGMhVEY",
               "customer_email":"1c5jc@k1zw.com",
               "number":"034341",
               "address_input":"8ZgDyq1xEC, 4iIftJAnDH, crVOXHdCP1, vyI8J5dZcU, mB98SQ8j6W, Afghanistan"
            },
            "currency":"USD",
            "payment_status":"paid",
            "submission_hash":"wpf_165874704462de78a4a943d134",
            "payment_total":51256000,
            "payment_mode":"test",
            "payment_method":"stripe",
            "status":"new",
            "ip_address":"127.0.0.1",
            "browser":"Chrome",
            "device":"Apple",
            "city":null,
            "country":null,
            "created_at":"2022-07-25 11:04:04",
            "updated_at":"2022-07-25 11:04:08",
            "post_title":"Credit Card Donation Form (#29)",
            "currencySettings":{
               "currency":"USD",
               "locale":"auto",
               "currency_sign_position":"left",
               "currency_separator":"dot_comma",
               "decimal_points":0,
               "settings_type":"global",
               "is_zero_decimal":false,
               "currency_sign":"&#36;"
            }
         },
         {
            "id":71,
            "form_id":"29",
            "user_id":"1",
            "customer_id":null,
            "customer_name":"arQcun2rs4",
            "customer_email":"1c5jc@k1zw.com",
            "form_data_raw":{
               "__wpf_form_id":"29",
               "__wpf_current_url":"http://wp.test/?wp_paymentform_preview=29",
               "__wpf_current_page_id":"",
               "custom_payment_input":"857256",
               "customer_name":"arQcun2rs4",
               "customer_name_1":"IA4IGMhVEY",
               "customer_email":"1c5jc@k1zw.com",
               "number":"960626",
               "address_input":{
                  "address_line_1":"ZADnMPsvVf",
                  "address_line_2":"CUxW3y53X0",
                  "city":"nydm5OvArI",
                  "state":"LBooT59e2y",
                  "zip_code":"b6PTKElzMw",
                  "country":"AF"
               },
               "__stripe_payment_method_id":"pm_1LOJDcIyGOUknw8lxpdXF5C6"
            },
            "form_data_formatted":{
               "customer_name":"arQcun2rs4",
               "customer_name_1":"IA4IGMhVEY",
               "customer_email":"1c5jc@k1zw.com",
               "number":"960626",
               "address_input":"ZADnMPsvVf, CUxW3y53X0, nydm5OvArI, LBooT59e2y, b6PTKElzMw, Afghanistan"
            },
            "currency":"USD",
            "payment_status":"paid",
            "submission_hash":"wpf_165848618962da7dad15ff2135",
            "payment_total":85725600,
            "payment_mode":"test",
            "payment_method":"stripe",
            "status":"new",
            "ip_address":"127.0.0.1",
            "browser":"Chrome",
            "device":"Apple",
            "city":null,
            "country":null,
            "created_at":"2022-05-06 10:36:29",
            "updated_at":"2022-05-22 10:36:32",
            "post_title":"Credit Card Donation Form (#29)",
            "currencySettings":{
               "currency":"USD",
               "locale":"auto",
               "currency_sign_position":"left",
               "currency_separator":"dot_comma",
               "decimal_points":0,
               "settings_type":"global",
               "is_zero_decimal":false,
               "currency_sign":"&#36;"
            }
         }
      ]
   }
}

This endpoint return all the entries/submissions for the given form id.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries

URL parameters

Parameter type Required Description
id int true The form ID which entries you are gonna fetch
per_page int flase Entries per page ex: 15, 20
page_number int false Page number of pagination
search_string string false Search by cutsomer_name,customer_email,payment method
payment_status string false Values are: paid, pending, failed
status string false Values are: read, unread

Get a form reports



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/reports" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns json structured like this:

{
    "success": true,
    "data": {
        "reports": {
            "total": {
                "label": "All",
                "submission_count": 7,
                "payment_total": 381758400
            },
            "paid": {
                "label": "Paid",
                "submission_count": 4,
                "payment_total": 205150900
            },
            "processing": {
                "label": "Processing",
                "submission_count": 0,
                "payment_total": 0
            },
            "pending": {
                "label": "Pending",
                "submission_count": 2,
                "payment_total": "96731700"
            },
            "failed": {
                "label": "Failed",
                "submission_count": 0,
                "payment_total": 0
            },
            "refunded": {
                "label": "Refunded",
                "submission_count": 1,
                "payment_total": "79875800"
            },
            "abandoned": {
                "label": "Abandoned",
                "submission_count": 2,
                "payment_total": "96731700"
            }
        },
        "currencySettings": {
            "currency": "USD",
            "locale": "auto",
            "currency_sign_position": "left",
            "currency_separator": "dot_comma",
            "decimal_points": 0,
            "settings_type": "global",
            "is_zero_decimal": false,
            "currency_sign": "&#36;"
        },
        "is_payment_form": true
    }
}

This endpoint generates reports for a specific form.

Https request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/reports

URL parameters

Parameter type Required Description
id int true The form ID

Get a specific entry



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns json structured like this:

{
   "success":true,
   "data":{
      "submission":{
         "id":1,
         "form_id":"8",
         "user_id":"1",
         "customer_id":null,
         "customer_name":"tupsfrXOcd",
         "customer_email":"bdbhg@tl1w.com",
         "form_data_raw":{
            "__wpf_form_id":"8",
            "__wpf_current_url":"http://wp.test/?wp_paymentform_preview=8",
            "__wpf_current_page_id":"",
            "customer_name":"tupsfrXOcd",
            "customer_email":"bdbhg@tl1w.com",
            "text":"tRndFZTPqS",
            "textarea":"niKtsJAW3O"
         },
         "form_data_formatted":{
            "customer_name":"tupsfrXOcd",
            "customer_email":"bdbhg@tl1w.com",
            "text":"tRndFZTPqS",
            "textarea":"niKtsJAW3O"
         },
         "currency":"USD",
         "payment_status":"pending",
         "submission_hash":"wpf_165829447062d790c6e1977395",
         "payment_total":"0",
         "payment_mode":null,
         "payment_method":"",
         "status":"read",
         "ip_address":"127.0.0.1",
         "browser":"Chrome",
         "device":"Apple",
         "city":null,
         "country":null,
         "created_at":"2022-07-20 05:21:10",
         "updated_at":"2022-07-27 07:29:30",
         "post_title":"Contact Form (#8)",
         "user_profile_url":"",
         "transactions":[

         ],
         "order_items":[

         ],
         "discounts":{
            "applied":[

            ],
            "total":0,
            "percent":0
         },
         "tax_items":[

         ],
         "activities":[

         ],
         "refunds":[

         ],
         "refundTotal":0,
         "currencySetting":{
            "currency":"USD",
            "locale":"auto",
            "currency_sign_position":"left",
            "currency_separator":"dot_comma",
            "decimal_points":0,
            "settings_type":"global",
            "is_zero_decimal":false,
            "currency_sign":"&#36;"
         },
         "user":{
            "display_name":"elias",
            "email":"elias@gmail.com",
            "profile_url":""
         },
         "subscription_payment_total":0,
         "subscriptions":[

         ],
         "widgets":[

         ]
      },
      "entry":{
         "customer_name":{
            "label":"Name",
            "value":"tupsfrXOcd",
            "type":"customer_name"
         },
         "customer_email":{
            "label":"Email Address",
            "value":"bdbhg@tl1w.com",
            "type":"customer_email"
         },
         "text":{
            "label":"Subject",
            "value":"tRndFZTPqS",
            "type":"text"
         },
         "textarea":{
            "label":"Your Message",
            "value":"niKtsJAW3O",
            "type":"textarea"
         }
      }
   }
}

This endpoint will return a specific entry for the given form id and entryID.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}

URL paramaters

Parameter type Required Description
id int true The form ID of the entry
entryId int true The specific entry id

Delete note from entry



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}/notes/{noteId}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The above command returns json structured like this:

{
    "success": true,
    "message": "Log deleted successfully!"
}

This endpoint delete a note from a specific entry. With given entry id and note id.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}/notes/{noteId}

URL parameters

Parameter type Required Description
id int true The form ID of the entry
entryId int true The specific entry id
noteId int true The specific note id

Change entry status



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}/status" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The above command returns json structured like this:

{
    "success": true,
    "message": "Log deleted successfully!"
}

This endpoint delete a note from a specific entry. With given entry id and note id.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/form/{id}/entries/{entryId}/status

URL parameters

Parameter type Required Description
id int true The form ID of the entry
entryId int true The specific entry id
status string true Entry status

Remove entry



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/entries/remove" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The above command returns json structured like this:

{
  "message": "Selected submission deleted successfully"
}

This end point removes/deletes an entry/submission for the given form id. You also need to provide the entry id.

Http request

DELETE https://yourdomain.com/wp-json/wppayform/v2/forms/entries/remove

URL parameters

Parameter type Required Description
submission_id int true The specific entry id
form_id int true The form ID of the entry

Integrations

Get form integrations



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "feeds":[

   ],
   "available_integrations":{
      "UserRegistration":{
         "category":"wp_core",
         "disable_global_settings":"yes",
         "logo":"https://wp.test/wp-content/plugins/wp-payment-form/assets/images/integrations/user_registration.png",
         "title":"User Registration Integration",
         "is_active":true
      },
      "lifterlms":{
         "title":"LifterLMS Integration",
         "logo":"https://wp.test/wp-content/plugins/wp-payment-form/assets/images/integrations/lifterlms.png",
         "is_active":true,
         "configure_title":"Configuration required!",
         "global_configure_url":"#",
         "configure_message":"LifterLMS is not configured yet! Please configure your LifterLMS api first",
         "configure_button_text":"Set LifterLMS"
      },
      "fluentcrm":{
         "title":"FluentCRM Integration",
         "logo":"https://wp.test/wp-content/plugins/wp-payment-form/assets/images/integrations/fluentcrm-logo.png",
         "is_active":true,
         "configure_title":"Configuration required!",
         "global_configure_url":"#",
         "configure_message":"FluentCRM is not configured yet! Please configure your FluentCRM api first",
         "configure_button_text":"Set FluentCRM"
      },
      "sms_notification":{
         "title":"SMS Notification by Twilio",
         "logo":"https://wp.test/wp-content/plugins/wp-payment-form/assets/images/integrations/twilio.png",
         "is_active":false,
         "configure_title":"Configuration required!",
         "global_configure_url":"https://wp.test/wp-admin/admin.php?page=fluent_forms_settings#general-sms_notification-settings",
         "configure_message":"SMS Notification is not configured yet! Please configure your SMS api first",
         "configure_button_text":"Set SMS Notification API"
      }
   },
   "all_module_config_url":"https://wp.test/wp-admin/admin.php?page=wppayform.php#/integrations"
}

This endpoint retrieves all available integrations of a form.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration

URL parameters

Parameter type Required Description
id int true The form id

Get integration settings of a form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "settings":{
      "conditionals":{
         "conditions":[

         ],
         "status":false,
         "type":"all"
      },
      "enabled":true,
      "list_id":"",
      "list_name":"",
      "name":"",
      "merge_fields":[

      ]
   },
   "settings_fields":[

   ],
   "shortcodes":[
      {
         "title":"Inputs",
         "shortcodes":{
            "{input.customer_name}":"Name",
            "{input.customer_email}":"Email Address"
         }
      },
      {
         "title":"Submission Info",
         "shortcodes":{
            "{submission.id}":"Submission ID",
            "{submission.submission_hash}":"Submission Hash ID",
            "{submission.customer_name}":"Customer Name",
            "{submission.customer_email}":"Customer Email",
            "{submission.payment_method}":"Payment Method"
         }
      },
      {
         "title":"Payment Items",
         "shortcodes":[

         ]
      },
      {
         "title":"WordPress",
         "shortcodes":{
            "{wp:post_id}":"Post ID",
            "{wp:post_title}":"Post Title",
            "{wp:post_url}":"Post URL",
            "{wp:post_author}":"Post Author",
            "{wp:post_author_email}":"Post Author Email",
            "{post_meta:YOUR_META_KEY}":"Post Meta",
            "{wp:user_id}":"User ID",
            "{wp:user_first_name}":"User First Name",
            "{wp:user_last_name}":"User Last Name",
            "{wp:user_display_name}":"User Display Name",
            "{wp:user_email}":"User Email",
            "{wp:user_url}":"User URL",
            "{user_meta:YOUR_META_KEY}":"User Meta",
            "{wp:site_title}":"Site Title",
            "{wp:site_url}":"Site URL",
            "{wp:admin_email}":"Admin Email"
         }
      },
      {
         "title":"Other",
         "shortcodes":{
            "{querystring:YOUR_KEY}":"Query String",
            "{other:date}":"Date",
            "{other:time}":"Time",
            "{other:user_ip}":"User IP Address"
         }
      }
   ],
   "inputs":{
      "customer_name":{
         "element":"customer_name",
         "admin_label":"Name",
         "options":[

         ],
         "attributes":{
            "name":"Name",
            "code":"{input.customer_name}",
            "type":"customer_name"
         }
      },
      "customer_email":{
         "element":"customer_email",
         "admin_label":null,
         "options":[

         ],
         "attributes":{
            "name":"Email Address",
            "code":"{input.customer_email}",
            "type":"customer_email"
         }
      }
   },
   "merge_fields":false
}

This endpoint retrieves all integration settings of a form.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration

URL parameters

Parameter type Required Description
id int true The form id

Delete an Integration of a form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration/settings" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The first command returns JSON structured like this:

{
     "message": "Selected integration feed successfully deleted",

}

This endpoint delete an integration feed of a form upon providing form id and integration_id

Http request

DELETE https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration/settings

URL parameters

Parameter type Required Description
id int true The form id
integration_id int true The integration id of the integration.

Get slack integration settings of a form



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration/slack" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "settings": [],
    "id": 0
}

This endpoint retreives slack integration settings of a form. If there is a slack integration.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration/slack"

URL parameters

Parameter type Required Description
id int true The form id

Get webhooks



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integration/slack" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
   "success":true,
   "data":{
      "integrations":[

      ],
      "request_headers":[
         {
            "label":"Accept",
            "value":"Accept",
            "possible_values":{
               "title":"Accept Header Samples",
               "shortcodes":{
                  "Accept: text/plain":"text/plain",
                  "Accept: text/html":"text/html",
                  "Accept: text/*":"text/*"
               }
            }
         },
         {
            "label":"Accept-Charset",
            "value":"Accept-Charset",
            "possible_values":{
               "title":"Accept-Charset Header Samples",
               "shortcodes":{
                  "Accept-Charset: utf-8":"utf-8",
                  "Accept-Charset: iso-8859-1":"iso-8859-1"
               }
            }
         },
         {
            "label":"Accept-Encoding",
            "value":"Accept-Encoding",
            "possible_values":{
               "title":"Accept-Encoding Header Samples",
               "shortcodes":{
                  "Accept-Encoding: gzip":"gzip",
                  "Accept-Encoding: compress":"compress",
                  "Accept-Encoding: deflate":"deflate",
                  "Accept-Encoding: br":"br",
                  "Accept-Encoding: identity":"identity",
                  "Accept-Encoding: *":"*"
               }
            }
         },
         {
            "label":"Accept-Language",
            "value":"Accept-Language",
            "possible_values":{
               "title":"Accept-Language Header Samples",
               "shortcodes":{
                  "Accept-Language: en":"en",
                  "Accept-Language: en-US":"en-US",
                  "Accept-Language: en-GR":"en-GR",
                  "Accept-Language: en-US,en;q=0.5":"en-US,en;q=0.5"
               }
            }
         },
         {
            "label":"Accept-Datetime",
            "value":"Accept-Datetime"
         },
         {
            "label":"Authorization",
            "value":"Authorization"
         },
         {
            "label":"Cache-Control",
            "value":"Cache-Control"
         },
         {
            "label":"Connection",
            "value":"Connection"
         },
         {
            "label":"Cookie",
            "value":"Cookie"
         },
         {
            "label":"Content-Length",
            "value":"Content-Length"
         },
         {
            "label":"Content-Type",
            "value":"Content-Type"
         },
         {
            "label":"Date",
            "value":"Date"
         },
         {
            "label":"Expect",
            "value":"Expect"
         },
         {
            "label":"Forwarded",
            "value":"Forwarded"
         },
         {
            "label":"From",
            "value":"From"
         },
         {
            "label":"Host",
            "value":"Host"
         },
         {
            "label":"If-Match",
            "value":"If-Match"
         },
         {
            "label":"If-Modified-Since",
            "value":"If-Modified-Since"
         },
         {
            "label":"If-None-Match",
            "value":"If-None-Match"
         },
         {
            "label":"If-Range",
            "value":"If-Range"
         },
         {
            "label":"If-Unmodified-Since",
            "value":"If-Unmodified-Since"
         },
         {
            "label":"Max-Forwards",
            "value":"Max-Forwards"
         },
         {
            "label":"Origin",
            "value":"Origin"
         },
         {
            "label":"Pragma",
            "value":"Pragma"
         },
         {
            "label":"Proxy-Authorization",
            "value":"Proxy-Authorization"
         },
         {
            "label":"Range",
            "value":"Range"
         },
         {
            "label":"Referer",
            "value":"Referer"
         },
         {
            "label":"TE",
            "value":"TE"
         },
         {
            "label":"User-Agent",
            "value":"User-Agent"
         },
         {
            "label":"Upgrade",
            "value":"Upgrade"
         },
         {
            "label":"Via",
            "value":"Via"
         },
         {
            "label":"Warning",
            "value":"Warning"
         }
      ],
      "inputs":{
         "customer_name":{
            "element":"customer_name",
            "admin_label":"Name",
            "options":[

            ],
            "attributes":{
               "name":"Name",
               "code":"{input.customer_name}",
               "type":"customer_name"
            }
         },
         "customer_email":{
            "element":"customer_email",
            "admin_label":null,
            "options":[

            ],
            "attributes":{
               "name":"Email Address",
               "code":"{input.customer_email}",
               "type":"customer_email"
            }
         }
      }
   }
}

This endpoint retreives all the webhooks settings of form.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/webhook

URL parameters

Parameter type Required Description
id int true The form id

Delete webhook



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/webhook" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The first command returns JSON structured like this:

{
   "message": "Selected WebHook Feed is deleted",
}

This endpoint delete a webhook feed from a form.

Http request

DELETE https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/webhook

URL parameters

Parameter type Required Description
id int true The form id
id int true The webhook settings id , provide with the request.

Get Zapier notification settings

``php


```python

curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/zapier" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
   "data":[

   ],
   "inputs":{
      "customer_name":{
         "element":"customer_name",
         "admin_label":"Name",
         "options":[

         ],
         "attributes":{
            "name":"Name",
            "code":"{input.customer_name}",
            "type":"customer_name"
         }
      },
      "customer_email":{
         "element":"customer_email",
         "admin_label":null,
         "options":[

         ],
         "attributes":{
            "name":"Email Address",
            "code":"{input.customer_email}",
            "type":"customer_email"
         }
      }
   }
}

This endpoint retreives all zapier settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/zapier

URL parameters

Parameter type Required Description
id int true The form id

Delete zapier notification settin



curl "https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/webhook" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: DELETE"

The first command returns JSON structured like this:

{
   "message": "Deleted successfully!",
}

This endpoint delete a webhook feed from a form.

Http request

DELETE https://yourdomain.com/wp-json/wppayform/v2/form/{id}/integrations/webhook

URL parameters

Parameter type Required Description
id int true The form id
meta_id int true The zapier notification settings id , provide with the request.

Payments

Get payment method settings



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/payments/{payMethod}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "payment_mode": "test",
    "test_api_key": "",
    "live_api_key": ""
}

This endpoint retrieves specific paymeny method settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/settings/payments/{payMethod}

URL parameters

Parameter type Required Description
payMethod string true The name of the payment method mollie, payrexx, square, paystack

Global stripe settings



curl "https://yourdomain.com/wp-json/wppayform/v2/forms/settings/stripe" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "settings": {
        "payment_mode": "test",
        "live_pub_key": "",
        "live_secret_key": "",
        "test_pub_key": "your pub key",
        "test_secret_key": "your secret key",
        "company_name": "",
        "checkout_logo": "",
        "send_meta_data": "no"
    },
    "webhook_url": "https://wp.test/?wpf_stripe_listener=1",
    "is_key_defined": false
}

This endpoint retrieves specific paymeny method settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/forms/settings/stripe

Get paypal settings



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/payments/{payMethod}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The first command returns JSON structured like this:

{
    "settings": {
        "payment_mode": "live",
        "paypal_email": "",
        "disable_ipn_verification": "no",
        "checkout_logo": ""
    },
    "confirmation_pages": {
        "confirmation": 5,
        "failed": 6
    },
    "pages": [
        {
            "ID": "2",
            "post_title": "Sample Page"
        },
        {
            "ID": "5",
            "post_title": "Payment Confirmation"
        },
        {
            "ID": "6",
            "post_title": "Payment Failed"
        },
        {
            "ID": "18",
            "post_title": "Course Catalog"
        },
        {
            "ID": "19",
            "post_title": "Membership Catalog"
        },
        {
            "ID": "20",
            "post_title": "Purchase"
        },
        {
            "ID": "21",
            "post_title": "Dashboard"
        },
        {
            "ID": "25",
            "post_title": "Dashboard"
        },
        {
            "ID": "26",
            "post_title": "Student Registration"
        },
        {
            "ID": "27",
            "post_title": "Instructor Registration"
        }
    ]
}

This endpoint retrieves paypal settings.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/settings/paypal

Save/Update a payment method settings



curl "https://yourdomain.com/wp-json/wppayform/v2/settings/payments/{payMethod}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: POST"

The first command returns JSON structured like this:

{
   "message": "Settings successfully updated"
}

This endpoint save/update a specific payment method settings.

Http request

POST https://yourdomain.com/wp-json/wppayform/v2/settings/payments/{payMethod}

URL parameters

Parameter type Required Description
payMethod string true The name of the payment method ex: mollie, payrexx, square, paystack
settings json object true The settings which consist of payment_mode, test_api_key, live_api_key fields.
payment_mode text true Modes are live, test
test_api_key json object true Test api key consist of public key, secret key.
live_api_key json object true Live api key consist of public key, secret key

Reports

Get reports



curl "https://yourdomain.com/wp-json/wppayform/v2/reports" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
    "payments": [
        {
            "id": 1,
            "form_id": "8",
            "customer_name": "tupsfrXOcd",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-27 07:29:30",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 60,
            "form_id": "8",
            "customer_name": "F3tkI6NQcC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 11:07:00",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 59,
            "form_id": "29",
            "customer_name": "3pMcTkn2Jp",
            "payment_total": "23954600",
            "payment_status": "pending",
            "payment_method": "stripe",
            "updated_at": "2022-07-21 10:41:56",
            "post_title": "Credit Card Donation Form (#29)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;239,546"
        },
        {
            "id": 58,
            "form_id": "29",
            "customer_name": "IA4IGMhVEY",
            "payment_total": "16659000",
            "payment_status": "paid",
            "payment_method": "stripe",
            "updated_at": "2022-07-21 10:37:25",
            "post_title": "Credit Card Donation Form (#29)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;166,590"
        },
        {
            "id": 57,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:15:29",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 56,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:15:00",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 55,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:14:42",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 54,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:14:25",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 53,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:14:07",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        },
        {
            "id": 52,
            "form_id": "8",
            "customer_name": "87o169SlXC",
            "payment_total": "0",
            "payment_status": "pending",
            "payment_method": "",
            "updated_at": "2022-07-21 09:13:33",
            "post_title": "Contact Form (#8)",
            "recurring_amount": null,
            "initial_amount": null,
            "quantity": null,
            "status": null,
            "formattedTotal": "&#36;0"
        }
    ],
    "customer": {
        "yptn5@a7tw.com": {
            "count": 1,
            "items": [
                {
                    "currency": "USD",
                    "total_paid": 166590,
                    "submissions": "1"
                }
            ],
            "name": "IA4IGMhVEY"
        }
    },
    "currency_base": [
        {
            "currency": "USD",
            "form_id": "29",
            "total_paid": "16659000",
            "formattedTotal": "&#36;166,590"
        }
    ],
    "chart": {
        "labels": [],
        "data": [
            166590
        ],
        "label": [
            "USD"
        ]
    },
    "entries_count": 60
}

This endpoint retreives whole reports in a json format.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports

Get Todays data



curl "https://yourdomain.com/wp-json/wppayform/v2/reports/todays-data" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
    "revenueWeekly": {
        "id": "revenue_overview",
        "title": "Revenue This Week",
        "type": "bar",
        "height": "70",
        "value": [
            {
                "form_id": "0",
                "currency": "USD",
                "total_paid": "0",
                "formattedTotal": "0 USD"
            }
        ],
        "change": "",
        "label": [],
        "data": [],
        "color": "rgb(22,198,114)",
        "backgroundColor": "rgb(233,247,239)"
    },
    "customersStats": [
        {
            "id": "total_customers",
            "title": "Total Customers",
            "type": "line",
            "height": "70",
            "value": 1,
            "change": "0% of last week",
            "label": [
                "2022-07-21"
            ],
            "data": [
                "1"
            ],
            "color": "rgb(255,184,36)",
            "backgroundColor": "rgb(254,245,232)"
        },
        {
            "id": "customer_new",
            "title": "New Customers",
            "type": "line",
            "height": "70",
            "value": "0/week",
            "change": "-100% of last week",
            "label": [
                1,
                2,
                3,
                4,
                5,
                6
            ],
            "data": [
                -100,
                -200,
                -300,
                -400,
                -500,
                -600
            ],
            "color": "rgb(192 161 232)",
            "backgroundColor": "rgb(233 220 250)"
        }
    ]
}

This endpoint retrieves Todays reports with customer stats.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports/todays-data

Recent revenues



curl "https://yourdomain.com/wp-json/wppayform/v2/reports/recent-revenues" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
    "data": {
        "USD": [
            {
                "currency": "USD",
                "payment_status": "paid",
                "date": "2022-07-21",
                "total_paid": "166590.00",
                "submissions": "1"
            }
        ]
    },
    "options": [
        {
            "label": "USD",
            "value": "USD"
        }
    ],
    "chartData": {
        "USD": {
            "label": [
                "2022-07-21"
            ],
            "data": [
                166590
            ]
        }
    }
}

This endpoint retieves recent revenues reports in a json format.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports/recent-revenues

Get customers



curl "https://yourdomain.com/wp-json/wppayform/v2/reports/customers" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

The above command returns JSON structured like this:

{
    "customers": [
        {
            "customer_email": "u4diz@x9w5.com",
            "customer_name": "F3tkI6NQcC",
            "created": "21-July-2022",
            "submissions": "1",
            "date": "8"
        },
        {
            "customer_email": "yptn5@a7tw.com",
            "customer_name": "IA4IGMhVEY",
            "created": "21-July-2022",
            "submissions": "2",
            "date": "8"
        },
        {
            "customer_email": "dxdss@acvt.com",
            "customer_name": "87o169SlXC",
            "created": "21-July-2022",
            "submissions": "7",
            "date": "8"
        },
        {
            "customer_email": "levpd@lmqw.com",
            "customer_name": "ZqxEeuzC9V",
            "created": "20-July-2022",
            "submissions": "2",
            "date": "9"
        },
        {
            "customer_email": "foxvt@vfjo.com",
            "customer_name": "5TilImF7d3",
            "created": "20-July-2022",
            "submissions": "5",
            "date": "9"
        },
        {
            "customer_email": "tozrb@zzou.com",
            "customer_name": "ylW56KzPYU",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "af5pw@sfoe.com",
            "customer_name": "XU53cOkBo1",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "y4cwp@5fjr.com",
            "customer_name": "R0X2OiBCQs",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "snwwo@mp8t.com",
            "customer_name": "FOMg5XM8c4",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "pydbn@6swu.com",
            "customer_name": "U5ivMuDNPX",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "71xyf@cjkx.com",
            "customer_name": "elias",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "ftjdo@lc3y.com",
            "customer_name": "hF0zgFgvpF",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "rk6hy@w1es.com",
            "customer_name": "uh6FJPN0tG",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "yd2z1@x0ui.com",
            "customer_name": "v8uwcheDfK",
            "created": "20-July-2022",
            "submissions": "2",
            "date": "9"
        },
        {
            "customer_email": "nvxww@9nva.com",
            "customer_name": "c9rSdAAwMR",
            "created": "20-July-2022",
            "submissions": "1",
            "date": "9"
        },
        {
            "customer_email": "hm8jr@aw4q.com",
            "customer_name": "r9mtx2UE62",
            "created": "20-July-2022",
            "submissions": "6",
            "date": "9"
        },
        {
            "customer_email": "aehbe@xugp.com",
            "customer_name": "ffeAo0yJqC",
            "created": "20-July-2022",
            "submissions": "7",
            "date": "9"
        },
        {
            "customer_email": "bl2q7@4l1k.com",
            "customer_name": "U564mkHlDu",
            "created": "20-July-2022",
            "submissions": "3",
            "date": "9"
        },
        {
            "customer_email": "xygux@quik.com",
            "customer_name": "Zf77jGvgyw",
            "created": "20-July-2022",
            "submissions": "2",
            "date": "9"
        },
        {
            "customer_email": "1c5jc@k1zw.com",
            "customer_name": "ewu9AeGkIw",
            "created": "20-July-2022",
            "submissions": "9",
            "date": "9"
        },
        {
            "customer_email": "bdbhg@tl1w.com",
            "customer_name": "tupsfrXOcd",
            "created": "20-July-2022",
            "submissions": "5",
            "date": "9"
        }
    ],
    "total": 21
}

This endpoint retieves all the customers and their data in a json format.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports/customers

Get a customer



curl "https://yourdomain.com/wp-json/wppayform/v2/reports/customers/{customer_email}" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

This above command return a json structured like this.

{
    "entries": [
        {
            "id": 60,
            "form_id": "8",
            "user_id": "1",
            "customer_id": null,
            "customer_name": "F3tkI6NQcC",
            "customer_email": "u4diz@x9w5.com",
            "form_data_raw": {
                "__wpf_form_id": "8",
                "__wpf_current_url": "http://wp.test/?wp_paymentform_preview=8",
                "__wpf_current_page_id": "",
                "customer_name": "F3tkI6NQcC",
                "customer_email": "u4diz@x9w5.com",
                "text": "JXvcqdQjEy",
                "textarea": "JeEFJyeAoe"
            },
            "form_data_formatted": {
                "customer_name": "F3tkI6NQcC",
                "customer_email": "u4diz@x9w5.com",
                "text": "JXvcqdQjEy",
                "textarea": "JeEFJyeAoe"
            },
            "currency": "USD",
            "payment_status": "pending",
            "submission_hash": "wpf_165840162062d93354e7992251",
            "payment_total": "0",
            "payment_mode": null,
            "payment_method": "",
            "status": "new",
            "ip_address": "127.0.0.1",
            "browser": "Chrome",
            "device": "Apple",
            "city": null,
            "country": null,
            "created_at": "2022-07-21 11:07:00",
            "updated_at": "2022-07-21 11:07:00",
            "has_subscription": false,
            "currency_settings": {
                "currency": "USD",
                "locale": "auto",
                "currency_sign_position": "left",
                "currency_separator": "dot_comma",
                "decimal_points": 0,
                "settings_type": "global",
                "is_zero_decimal": false,
                "currency_sign": "&#36;"
            },
        }
    ],
    "info": {
        "id": 60,
        "form_id": "8",
        "user_id": "1",
        "customer_id": null,
        "customer_name": "F3tkI6NQcC",
        "customer_email": "u4diz@x9w5.com",
        "form_data_raw": {
            "__wpf_form_id": "8",
            "__wpf_current_url": "http://wp.test/?wp_paymentform_preview=8",
            "__wpf_current_page_id": "",
            "customer_name": "F3tkI6NQcC",
            "customer_email": "u4diz@x9w5.com",
            "text": "JXvcqdQjEy",
            "textarea": "JeEFJyeAoe"
        },
        "form_data_formatted": {
            "customer_name": "F3tkI6NQcC",
            "customer_email": "u4diz@x9w5.com",
            "text": "JXvcqdQjEy",
            "textarea": "JeEFJyeAoe"
        },
        "currency": "USD",
        "payment_status": "pending",
        "submission_hash": "wpf_165840162062d93354e7992251",
        "payment_total": "0",
        "payment_mode": null,
        "payment_method": "",
        "status": "new",
        "ip_address": "127.0.0.1",
        "browser": "Chrome",
        "device": "Apple",
        "city": null,
        "country": null,
        "created_at": "2022-07-21 11:07:00",
        "updated_at": "2022-07-21 11:07:00",
        "has_subscription": false,
        "currency_settings": {
            "currency": "USD",
            "locale": "auto",
            "currency_sign_position": "left",
            "currency_separator": "dot_comma",
            "decimal_points": 0,
            "settings_type": "global",
            "is_zero_decimal": false,
            "currency_sign": "&#36;"
        },
    },
    "subscriptions": [],
    "orders": []
}

This endpoint retieves all the data of a customer in json format.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports/customers/{customer_email}

URL parameters

Parameter Type Required Description
customer_email string/email true The email of the customer.

Get customer profile

``php


```python

curl "https://yourdomain.com/wp-json/wppayform/v2/reports/customers/{customer_email}/profile" \
  -H "Authorization: BASIC USERNAME:APPLICATION_PASSWORD"
  -H "Request type: GET"

This above command return a json structured like this.

{
    "spends": [],
    "permissions": {
        "roles": [
            "subscriber"
        ],
        "user_id": 7,
        "display_name": "u4diz@x9w5.com",
        "manage_user": false
    }
}

This endpoint retrieves a customer's profile.

Http request

GET https://yourdomain.com/wp-json/wppayform/v2/reports/customers/{customer_email}/profile

URL parameters

Parameter Type Required Description
customer_email string/email true The email of the customer.

Errors

Error Code Meaning
400 Bad Request -- Your request is invalid.
401 Unauthorized --- -- Your application password/username is wrong.
403 Forbidden -- The form/settings requested is hidden for administrators users only.
404 Not Found -- The specified form/entry/setting could not be found.
405 Method Not Allowed -- You tried to access form/entry/setting with an invalid method.
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.