API Services Settings

API Services

API Services

API Services will available if you activate API Services module from Add-ons page.

ARMember - API Services

After activating this module, you will able to use API to get membership plans, membership plan details, member details, member’s purchase plan/post, member’s plan/post payment transactions, check coupon code, add transaction, cancel member’s plan, and check members plan.

API Services Settings

You can check API services and details from ARMember -> General Settings -> API Services Settings page.

Security Key

API security key is useful to secure the API Services and API will be return the data successfully only if the correct “Security Key” is used for the API Calls. Security key is required parameter for all API call.

ARMember General Settings ( API Service )

Get Membership Plans List

This API get all membership plans and returns JSON array, and if the parameter is successful it responds with status “1” along with all plans id, name, and description.

API Service Membership Plan List

Get Membership Plan Details

To get the membership plan details, enter the valid Plan ID which will then return the JSON array, and if the parameter is successful it responds with status “1” along with all plans id, plan name, subscription type, plan amount, trial, etc…

Field Name Parameters
Plan ID arm_plan_id (Required)

API Service Membership Plan Details

Get Member Details

This Service will return the member details for the provided User ID in the request.

To get member’s custom details, you can request the API to arm_metakeys parameter where the User ID is a required parameter and the arm_metakeys parameter is optional. You can also send request to API with multiple custom field details by comma separated arm_metakeys.

This API will return JSON array. If API response returned successfully then “status” will received “1” with member details username, email, display name, first name, last name, status, and registretion date.

Field Name Parameters
Member ID arm_user_id (Required)
Field Metakeys arm_metakeys (Optional)

API Service Member's detail

Get Member’s Membership Plans

Get memberโ€™s purchased membership plans and details with a given User ID (mandatory/required parameter). The default record per page to be displayed first will be 5 records which you can set according to your requirement to show the numbers of records, and if the parameter is successful it returns JSON array with all the plan details, plan ID, plan name, plan start date, plan renew date, plan end date, etc…

Field Name Parameters
Member ID arm_user_id (Required)
Per Page arm_perpage (Optional) (Default: 5)
Page Number arm_page (Optional) (Default: 1)

API Service Member's Membership Plans

Get Member’s Paid Posts

Get memberโ€™s purchased Paid Post details with a given User ID (mandatory/required parameter). The default record per page to be displayed first will be 5 records which you can set according to your requirement to show the numbers of records, and if the parameter is successful it returns JSON array with all the paid post’s details, post name, post’s start date, post’s renew date, post’s end date, etc…

Field Name Parameters
Member ID arm_user_id (Required)
Per Page arm_perpage (Optional) (Default: 5)
Page Number arm_page (Optional) (Default: 1)

API Service Member's Paid Posts

Get Member’s Plan Payment Transactions

Get memberโ€™s purchased plan payment transaction details with a given User ID (mandatory/required parameter). The default record per page to be displayed first will be 5 records which you can set according to your requirement to show the numbers of records, and if the parameter is successful it returns JSON array with memberโ€™s transactions detail log id, transaction id, plan name, payment gateway name, payment type, status, plan amount, paid amount, tax, discount, etc…

Field Name Parameters
Member ID arm_user_id (Required)
Per Page arm_perpage (Optional) (Default: 5)
Page Number arm_page (Optional) (Default: 1)

API Service Member's Plan Payment Transactions

Get Member’s Paid Post Payment Transactions

Get memberโ€™s purchased pay per post payment transaction details with a given User ID (mandatory/required parameter). The default record per page to be displayed first will be 5 records which you can set according to your requirement to show the numbers of records, and if the parameter is successful it returns JSON array response with memberโ€™s transactions detail log id, transaction id, plan name, payment gateway name, payment type, status, plan amount, paid amount, tax, discount, etc…

Field Name Parameters
Member ID arm_user_id (Required)
Per Page arm_perpage (Optional) (Default: 5)
Page Number arm_page (Optional) (Default: 1)

API Service Member's Paid Post Payment Transactions

Verify/Check Coupon Code

Checks if the coupon code is available for plan and discount amount of plan, and if the coupon code is available, it returns JSON array response with discount amount, total plan amount after discount, type of discount, discount, and coupon applying information for each subscriptions.

Field Name Parameters
Coupon Code coupon_code (Required)
Plan ID plan_id (Required)
Payment Gateway gateway (Optional)

API Service Check Coupon Code

Assign/Add Plan to Member

Add plan to member with given User ID along with Plan ID (mandatory/required parameters), and if the parameters are correct, it returns status as “1” if successfully assigns plan to the member.

Field Name Parameters
Member ID arm_user_id (Required)
Plan ID arm_plan_id (Required)

API Service Add Plan to Member

Add Payment Transaction

Add membership plan and pay per post purchase transaction to member with given User ID along with Plan ID (mandatory/required parameters) along with other parameters as per given below.
Status parameter (Default is pending) varies when status is either successful, canceled, or failed.
Amount parameter passes value without the tax amount. Total parameter passes the value with the tax amount.

Field Name Parameters
Member ID arm_user_id (Required)
Plan ID plan_id (Required)
Transaction ID arm_trans_id (Optional)
Payment Gateway gateway (Optional) (Default: manual)
Status arm_status (Optional) (Default: pending)
Amount arm_amount (Optional) (Default: 0)
Total arm_total (Optional) (Default: 0)
Tax Amount arm_tax_amount (Optional) (Default: 0)
Coupon Code coupon_code (Optional)
Paid Post Payment is_post_payment (Optional) (Default: 0)
Paid Post ID is_post_id (Optional) (Default: 0)

API Service Add Transaction

Cancel Member’s Membership plan

Cancel the membership plan for member with given User ID along with Plan ID (mandatory/required parameters). And if the parameters are correct and the member’s plan is cancelled, it returns “1” indicating the success status.

Field Name Parameters
Member ID arm_user_id (Required)
Plan ID arm_plan_id (Required)

API Service Cancel Member's plan

Check Member’s Membership

Check whether the memberโ€™s membership plan is Active/Suspend with given User ID along with Plan ID (mandatory/required parameters). And if the parameters are correct and if there was plan found with member id or if the plan is suspended,it returns “1” indicating the success status.

Field Name Parameters
Member ID arm_user_id (Required)
Plan ID arm_plan_id (Required)

API Service Check Member's Membership