Back to top

SocialEngine REST API

What is REST API? Simply, REST API is the set of functions to which the developers can perform requests and receive responses. The interaction is performed via the HTTP/HTTPS protocol. An advantage of such an approach is the wide usage of HTTP/HTTPS that’s why REST API can be used practically for any programming language.

Below are the characteristics of the SocialEngineAddOns REST API:

  • When a request is sent to the REST API server, the server will return a response that contains either the data you requested, or the status code, or both.

  • oauth_consumer_key / oauth_consumer_secret? The Consumer Key and Consumer Secret Key are used to make a connection between API client and server. These keys are also used for creating OAuth Tokens for site members to access server resources without sharing their credentials.

Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
  • oauth_token / oauth_secret? The OAuth Token and OAuth Secret are used for identifying site members.
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478

Base URL

All requests to this REST API should have the base URL: [https://example.com/api/rest/]

HTTP Verbs

In REST API, there are four verbs that are used to manage resources: GET, POST, PUT, and DELETE. You can get the contents of a data using GET, delete the data using DELETE, and create or update the data using POST/PUT.

Supported Features

Official SocialEngine Plugins

  • Blogs Plugin

  • Photo Albums Plugin

  • Classifieds Plugin

  • Groups Plugin

  • Events Plugin

  • Forums Plugin

  • Polls Plugin

  • Video Sharing Plugin

  • Music Sharing Plugin

SocialEngineAddOns Plugins:

  • Advanced Activity Feeds / Wall Plugin

  • Geo-Location, Geo-Tagging, Check-Ins & Proximity Search Plugin [only for Advanced Activity Feed’s location features]

Advanced Members Plugin - Better Browse & Search, User Reviews, Ratings & Location Plugin

These are the APIs for the SocialEngineAddOns Plugin: Advanced Members Plugin - Better Browse & Search, User Reviews, Ratings & Location Plugin.

Browse Members

Browse Members
GET/members{&displayname}{&page}{&limit}

Get the members listing. Members can also be browsed and searched based on profile field values.

In case of pagination, we need to use 2 parameters limit and page. Use limit to set the number of users in response and use page for the page number. [i.e: If you have 100 users and the first request has limit=20 and page=1, then in that case the recent 20 users will be returned in response, and if limit=20 and page=2 is sent in request, then the next 20 recent users will be returned.]

Example URI

GET /members&displayname=displayname=michal&page=page=2&limit=limit=20
URI Parameters
HideShow
profile_type (optional, integer, `profile_type
string (required) Default: 1`) 

get members of this profile type.

displayname
string (optional) Example: displayname=michal

get members with matching name.

has_photo (optional, boolean, `has_photo
string (required) Default: 1`) 

get members with / without profile photo.

is_online (optional, boolean, `is_online
string (required) Default: 1`) 

get members who are online / offline.

1_1_3_alias_first_name (optional, string, `1_1_3_alias_first_name
string (required) Default: michal`) 

get members with matching value for this profile field. You can get the key name for profile field from the response of member search form.

1_1_4_alias_last_name (optional, string, `1_1_4_alias_last_name
string (required) Default: x`) 

get members with matching value for this profile field. You can get the key name for profile field from the response of member search form.

page
integer (optional) Example: page=2

return the ‘limit’ number of users of that page of member listings.

limit
integer (optional) Example: limit=20

number of users. Default limit is 20.

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
Response  200
HideShow
Headers
Content-Type: application/json
Body
{
        "isSitemember":1,
        "page":1,
        "totalItemCount":1119,
        "response":[
            {
                "user_id":20613,
                "username":"petview",
                "displayname":"Dugald McCulloch ",
                "photo_id":0,
                "status":null,
                "status_date":null,
                "locale":"en",
                "language":"en",
                "timezone":"Australia/Sydney",
                "search":1,
                "show_profileviewers":1,
                "level_id":7,
                "invites_used":0,
                "extra_invites":0,
                "enabled":1,
                "verified":1,
                "approved":1,
                "creation_date":"2017-06-12 10:41:58",
                "modified_date":"2017-06-12 10:41:58",
                "lastlogin_date":"2017-06-12 10:41:59",
                "update_date":null,
                "member_count":0,
                "view_count":0,
                "comment_count":0,
                "like_count":0,
                "seao_locationid":0,
                "location":"",
                "user_cover":0,
                "featured":null,
                "sponsored":null,
                "rating_avg":null,
                "rating_users":null,
                "review_count":null,
                "user_rated_id":null,
                "friendship_type":"add_friend",
                "isVerified":1,
                "image":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_normal":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_profile":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_icon":"http://example.comUser/externals/images/nophoto_user_thumb_icon.png",
                "content_url":"http://example.com/profile/petview",
                "menus":{
                    "label":"Add Friend",
                    "name":"add_friend",
                    "url":"user/add",
                    "urlParams":{
                        "user_id":20613
                    }
                },
                "mutualFriendCount":0,
                "profileField":{
                    "Personal Information":{
                        "First Name":"Dugald",
                        "Last Name":"McCulloch ",
                        "Studied At":"School",
                        "Interests":"animals",
                        "Country":"Australia"
                    },
                    "Contact Information":{
                        "Website":"petview.org "
                    }
                }
            },
            {
                "user_id":20612,
                "username":"happy169",
                "displayname":"Julia Robert",
                "photo_id":0,
                "status":null,
                "status_date":null,
                "locale":"en",
                "language":"en",
                "timezone":"America/Anchorage",
                "search":1,
                "show_profileviewers":1,
                "level_id":7,
                "invites_used":0,
                "extra_invites":0,
                "enabled":1,
                "verified":1,
                "approved":1,
                "creation_date":"2017-06-12 08:29:32",
                "modified_date":"2017-06-12 08:29:33",
                "lastlogin_date":"2017-06-12 08:29:33",
                "update_date":null,
                "member_count":0,
                "view_count":0,
                "comment_count":0,
                "like_count":0,
                "seao_locationid":0,
                "location":"",
                "user_cover":0,
                "featured":null,
                "sponsored":null,
                "rating_avg":null,
                "rating_users":null,
                "review_count":null,
                "user_rated_id":null,
                "friendship_type":"add_friend",
                "isVerified":1,
                "image":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_normal":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_profile":"http://example.comUser/externals/images/nophoto_user_thumb_profile.png",
                "image_icon":"http://example.comUser/externals/images/nophoto_user_thumb_icon.png",
                "content_url":"http://example.com/profile/test169",
                "menus":{
                    "label":"Add Friend",
                    "name":"add_friend",
                    "url":"user/add",
                    "urlParams":{
                        "user_id":20612
                    }
                },
                "mutualFriendCount":0,
                "age":39,
                "profileField":{
                    "Personal Information":{
                        "First Name":"Julia",
                        "Last Name":"Robert",
                        "Birthday":"June 13,1977"
                    }
                }
            }
    }
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}

Members Search Form

Members Search Form
GET/members/search-form

Get the search / filter members form. The search / filter parameters from this form will be used by ‘Browse Members’ API call to return results.

Example URI

GET /members/search-form
Response  200
HideShow
Headers
Accept: application/json
Body
{
  "whatWhereWithinmile": 1,
  "form": [
    {
      "type": "Select",
      "name": "profile_type",
      "label": "What",
      "multiOptions": {
        "0": "",
        "1": "Regular Member",
        "4": "Sound Crew",
        "5": "Singer",
        "6": "Record Producer",
        "7": "Musician",
        "8": "Instrumentalist",
        "9": "Freelance Artist",
        "10": "Composer",
        "12": "Vocalist"
      }
    },
    {
      "type": "Text",
      "name": "search",
      "label": "Who"
    },
    {
      "type": "Text",
      "name": "location",
      "label": "Where"
    },
    {
      "type": "Select",
      "name": "locationmiles",
      "label": "Within Miles",
      "multiOptions": {
        "0": "",
        "1": "1 Mile",
        "2": "2 Miles",
        "5": "5 Miles",
        "10": "10 Miles",
        "20": "20 Miles",
        "50": "50 Miles",
        "100": "100 Miles",
        "250": "250 Miles",
        "500": "500 Miles",
        "750": "750 Miles",
        "1000": "1000 Miles"
      }
    },
    {
      "type": "Select",
      "name": "show",
      "label": "Show",
      "multiOptions": {
        "1": "All Members",
        "2": "Only My Friends",
        "4": "Members I Like",
        "5": "Only Featured",
        "6": "Only Sponsored",
        "7": "Both Featured & Sponsored"
      }
    },
    {
      "type": "Select",
      "name": "network_id",
      "label": "Networks",
      "multiOptions": [
        "",
        "North America",
        "South America",
        "Europe",
        "Asia",
        "Africa",
        "Australia",
        "Antarctica"
      ]
    },
    {
      "type": "Select",
      "name": "orderby",
      "label": "Browse By",
      "multiOptions": {
        "": "",
        "creation_date": "Most Recent",
        "view_count": "Most Viewed",
        "like_count": "Most Liked",
        "member_count": "Most Popular",
        "title": "Alphabetical (A-Z)",
        "title_reverse": "Alphabetical (Z-A)",
        "distance": "Distance"
      }
    },
    {
      "type": "Checkbox",
      "name": "is_online",
      "label": "Only Online Members"
    },
    {
      "type": "Checkbox",
      "name": "has_photo",
      "label": "Only Members With Photos"
    },
    {
      "type": "Submit",
      "name": "done",
      "label": "Search"
    }
  ],
  "fields": {
    "1": [
      {
        "type": "Text",
        "name": "1_1_3_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_1_4_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_1_5_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "2": "Male",
          "3": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_1_6_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_1_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "4": [
      {
        "type": "Text",
        "name": "1_4_14_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_4_15_field_15",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_4_16_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "13": "Male",
          "14": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_4_6_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_4_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "5": [
      {
        "type": "Text",
        "name": "1_5_17_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_5_18_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_5_19_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "15": "Male",
          "16": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_5_20_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_5_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "6": [
      {
        "type": "Text",
        "name": "1_6_37_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_6_38_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_6_39_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "25": "Male",
          "26": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_6_40_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_6_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "7": [
      {
        "type": "Text",
        "name": "1_7_41_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_7_42_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_7_43_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "27": "Male",
          "28": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_7_44_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_7_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "8": [
      {
        "type": "Text",
        "name": "1_8_33_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_8_34_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_8_35_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "23": "Male",
          "24": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_8_36_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_8_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      },
      {
        "type": "Text",
        "name": "1_8_62_alias_location",
        "label": "City",
        "description": ""
      }
    ],
    "9": [
      {
        "type": "Text",
        "name": "1_9_29_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_9_30_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Date",
        "name": "1_9_32_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_9_31_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "21": "Male",
          "22": "Female"
        }
      },
      {
        "type": "Select",
        "name": "1_9_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "10": [
      {
        "type": "Text",
        "name": "1_10_45_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_10_46_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_10_47_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "29": "Male",
          "30": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_10_48_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_10_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ],
    "12": [
      {
        "type": "Text",
        "name": "1_12_21_alias_first_name",
        "label": "First Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Text",
        "name": "1_12_22_alias_last_name",
        "label": "Last Name",
        "description": "",
        "hasValidator": true
      },
      {
        "type": "Select",
        "name": "1_12_23_alias_gender",
        "label": "Gender",
        "description": "",
        "multiOptions": {
          "17": "Male",
          "18": "Female"
        }
      },
      {
        "type": "Date",
        "name": "1_12_24_alias_birthdate",
        "label": "Birthday",
        "description": "",
        "format": "date"
      },
      {
        "type": "Select",
        "name": "1_12_51_field_51",
        "label": "Experience",
        "description": "",
        "multiOptions": {
          "38": "0 - 3 years",
          "39": "3 - 5 years",
          "40": "5 - 10 years",
          "41": "10 - 20 years",
          "42": "20+ years"
        }
      }
    ]
  }
}

Advanced Members Plugin - Follow Feature

Member Following

Member Following
GET/advancedmember/following{&resource_id}{&resource_id}{&page}{&limit}

Get the members listing who are following a particular member.

In case of pagination, we need to use 2 parameters limit and page. Use limit to set the number of users in response and use page for the page number. [i.e: If you have 100 users and the first request has limit=20 and page=1, then in that case the recent 20 users will be returned in response, and if limit=20 and page=2 is sent in request, then the next 20 recent users will be returned.]

Example URI

GET /advancedmember/following&resource_id=244&resource_id=244&page=page=2&limit=limit=20
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 1`) 

get members following this user.

resource_id
integer (required) Example: 244

resource id

resource_type (required, string, `sitepage_page`)
string (required) 

resource type

page
integer (optional) Example: page=2

return the ‘limit’ number of users of that page of member listings.

limit
integer (optional) Example: limit=20

number of users. Default limit is 20.

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
Response  200
HideShow
Headers
Content-Type: application/json
Body
{
  "isSitemember": 1,
  "totalItemCount": 29,
  "response": [
    {
      "user_id": 20288,
      "username": "John",
      "displayname": "Ziaur Rijal",
      "photo_id": 118073,
      "status": null,
      "status_date": null,
      "locale": "id_ID",
      "language": "en",
      "timezone": "Asia/Krasnoyarsk",
      "search": 1,
      "show_profileviewers": 1,
      "level_id": 7,
      "invites_used": 0,
      "extra_invites": 0,
      "enabled": 1,
      "verified": 1,
      "approved": 1,
      "creation_date": "2017-03-17 08:42:26",
      "modified_date": "2017-03-17 08:42:27",
      "lastlogin_date": null,
      "update_date": null,
      "member_count": 0,
      "view_count": 0,
      "seao_locationid": 0,
      "location": "",
      "user_cover": 0,
      "featured": null,
      "sponsored": null,
      "rating_avg": null,
      "rating_users": null,
      "review_count": null,
      "user_rated_id": null,
      "friendship_type": "add_friend",
      "image": "http://www.example.com/user/08/d0/01/1cd39_0067.jpg?c=b2a8",
      "image_normal": "http://www.example.com/user/0a/d0/01/1cd3b_ed9a.jpg?c=1178",
      "image_profile": "http://www.example.com/user/09/d0/01/1cd3a_0067.jpg?c=b2a8",
      "image_icon": "http://www.example.com/user/0b/d0/01/1cd3c_19b0.jpg?c=7f32",
      "content_url": "http://www.example.com/profile/Rijalbagong82",
      "menus": {
        "label": "Add Friend",
        "name": "add_friend",
        "url": "user/add",
        "urlParams": {
          "user_id": 20288
        }
      },
      "mutualFriendCount": 0,
      "age": 34,
      "profileField": {
        "Personal Information": {
          "First Name": "Ziaur",
          "Last Name": "Rijal",
          "Birthday": "May 6,1982",
          "Country": "Indonesia"
        },
        "Contact Information": {
          "Website": "www.paytrentnt.com/rijalbagong"
        }
      }
    },
    {
      "user_id": 20287,
      "username": "regular",
      "displayname": "regular",
      "photo_id": 0,
      "status": null,
      "status_date": null,
      "locale": "en",
      "language": "en",
      "timezone": "America/Anchorage",
      "search": 1,
      "show_profileviewers": 1,
      "level_id": 7,
      "invites_used": 0,
      "extra_invites": 0,
      "enabled": 1,
      "verified": 1,
      "approved": 1,
      "creation_date": "2017-03-17 05:01:14",
      "modified_date": "2017-03-17 05:01:14",
      "lastlogin_date": "2017-03-17 05:01:16",
      "update_date": null,
      "member_count": 0,
      "view_count": 0,
      "seao_locationid": 0,
      "location": "",
      "user_cover": 0,
      "featured": null,
      "sponsored": null,
      "rating_avg": null,
      "rating_users": null,
      "review_count": null,
      "user_rated_id": null,
      "friendship_type": "add_friend",
      "image": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_normal": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_profile": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_icon": "http://www.example.comUser/externals/images/nophoto_user_thumb_icon.png",
      "content_url": "http://www.example.com/profile/regular",
      "menus": {
        "label": "Add Friend",
        "name": "add_friend",
        "url": "user/add",
        "urlParams": {
          "user_id": 20287
        }
      },
      "mutualFriendCount": 0,
      "profileField": []
    }
  ]
}
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}

Member Followers

Member Followers
GET/advancedmember/followers{&resource_id}{&resource_id}{&page}{&limit}

Get the members listing who are followers of a particular member.

In case of pagination, we need to use 2 parameters limit and page. Use limit to set the number of users in response and use page for the page number. [i.e: If you have 100 users and the first request has limit=20 and page=1, then in that case the recent 20 users will be returned in response, and if limit=20 and page=2 is sent in request, then the next 20 recent users will be returned.]

Example URI

GET /advancedmember/followers&resource_id=244&resource_id=244&page=page=2&limit=limit=20
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 1`) 

get members following this user.

resource_id
integer (required) Example: 244

resource id

resource_type (required, string, `sitepage_page`)
string (required) 

resource type

page
integer (optional) Example: page=2

return the ‘limit’ number of users of that page of member listings.

limit
integer (optional) Example: limit=20

number of users. Default limit is 20.

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
Response  200
HideShow
Headers
Content-Type: application/json
Body
{
  "isSitemember": 1,
  "totalItemCount": 29,
  "response": [
    {
      "user_id": 20288,
      "username": "John",
      "displayname": "Ziaur Rijal",
      "photo_id": 118073,
      "status": null,
      "status_date": null,
      "locale": "id_ID",
      "language": "en",
      "timezone": "Asia/Krasnoyarsk",
      "search": 1,
      "show_profileviewers": 1,
      "level_id": 7,
      "invites_used": 0,
      "extra_invites": 0,
      "enabled": 1,
      "verified": 1,
      "approved": 1,
      "creation_date": "2017-03-17 08:42:26",
      "modified_date": "2017-03-17 08:42:27",
      "lastlogin_date": null,
      "update_date": null,
      "member_count": 0,
      "view_count": 0,
      "seao_locationid": 0,
      "location": "",
      "user_cover": 0,
      "featured": null,
      "sponsored": null,
      "rating_avg": null,
      "rating_users": null,
      "review_count": null,
      "user_rated_id": null,
      "friendship_type": "add_friend",
      "image": "http://www.example.com/user/08/d0/01/1cd39_0067.jpg?c=b2a8",
      "image_normal": "http://www.example.com/user/0a/d0/01/1cd3b_ed9a.jpg?c=1178",
      "image_profile": "http://www.example.com/user/09/d0/01/1cd3a_0067.jpg?c=b2a8",
      "image_icon": "http://www.example.com/user/0b/d0/01/1cd3c_19b0.jpg?c=7f32",
      "content_url": "http://www.example.com/profile/Rijalbagong82",
      "menus": {
        "label": "Add Friend",
        "name": "add_friend",
        "url": "user/add",
        "urlParams": {
          "user_id": 20288
        }
      },
      "mutualFriendCount": 0,
      "age": 34,
      "profileField": {
        "Personal Information": {
          "First Name": "Ziaur",
          "Last Name": "Rijal",
          "Birthday": "May 6,1982",
          "Country": "Indonesia"
        },
        "Contact Information": {
          "Website": "www.paytrentnt.com/rijalbagong"
        }
      }
    },
    {
      "user_id": 20287,
      "username": "regular",
      "displayname": "regular",
      "photo_id": 0,
      "status": null,
      "status_date": null,
      "locale": "en",
      "language": "en",
      "timezone": "America/Anchorage",
      "search": 1,
      "show_profileviewers": 1,
      "level_id": 7,
      "invites_used": 0,
      "extra_invites": 0,
      "enabled": 1,
      "verified": 1,
      "approved": 1,
      "creation_date": "2017-03-17 05:01:14",
      "modified_date": "2017-03-17 05:01:14",
      "lastlogin_date": "2017-03-17 05:01:16",
      "update_date": null,
      "member_count": 0,
      "view_count": 0,
      "seao_locationid": 0,
      "location": "",
      "user_cover": 0,
      "featured": null,
      "sponsored": null,
      "rating_avg": null,
      "rating_users": null,
      "review_count": null,
      "user_rated_id": null,
      "friendship_type": "add_friend",
      "image": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_normal": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_profile": "http://www.example.comUser/externals/images/nophoto_user_thumb_profile.png",
      "image_icon": "http://www.example.comUser/externals/images/nophoto_user_thumb_icon.png",
      "content_url": "http://www.example.com/profile/regular",
      "menus": {
        "label": "Add Friend",
        "name": "add_friend",
        "url": "user/add",
        "urlParams": {
          "user_id": 20287
        }
      },
      "mutualFriendCount": 0,
      "profileField": []
    }
  ]
}
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}

Follow / Unfollow Member

Follow / Unfollow Member
POST/advancedmember/follow{?resource_id}{&resource_type}

Follow Unfollow Member , If a member is already following the user on using this API it will unfollow the member & vice versa.

Example URI

POST /advancedmember/follow?resource_id=244&resource_type=user
URI Parameters
HideShow
resource_id
integer (required) Example: 244

resource id

resource_type
string (required) Example: user

resource type

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478
Response  204
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}
Response  404
HideShow
Body
{
  "status_code": 404,
  "error": true,
  "error_code": "no_record",
  "message": "No record found"
}

Advanced Members Plugin - Location Feature

Edit Address

Edit Address Form
GET/memberlocation/edit-location

Edit Address form.

Returns the form & formvalues as response.form we get the Address edit form.formvalues we get the value of current Address.

Example URI

GET /memberlocation/edit-location
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 129`) 

user_id

seao_locationid (optional, integer, `seao_locationid
string (required) Default: 129`) 

seao_locationid

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478
Response  200
HideShow
Headers
Accept: application/json
Body
{
  "form": [
    {
      "type": "Text",
      "name": "formatted_address",
      "label": "Formatted Address"
    },
    {
      "type": "Text",
      "name": "longitude",
      "label": "Longitude"
    },
    {
      "type": "Text",
      "name": "latitude",
      "label": "Latitude"
    },
    {
      "type": "Text",
      "name": "address",
      "label": "Street Address"
    },
    {
      "type": "Text",
      "name": "city",
      "label": "City"
    },
    {
      "type": "Text",
      "name": "address",
      "label": "Street Address"
    },
    {
      "type": "Text",
      "name": "zipcode",
      "label": "Zipcode"
    },
    {
      "type": "Text",
      "name": "state",
      "label": "State"
    },
    {
      "type": "Text",
      "name": "state",
      "label": "State"
    },
    {
      "type": "Text",
      "name": "country",
      "label": "Country"
    },
    {
      "type": "Text",
      "name": "submit",
      "label": "Save Changes"
    }
  ],
  "formValues": {
    "locationitem_id": 13,
    "resource_type": "user",
    "resource_id": 106,
    "location": "Denmark",
    "latitude": 56.26392,
    "longitude": 9.501785,
    "formatted_address": "Denmark",
    "country": "Denmark",
    "state": "",
    "zipcode": "",
    "city": "",
    "address": "",
    "zoom": 16
  }
}
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}
Response  404
HideShow
Body
{
  "status_code": 404,
  "error": true,
  "error_code": "no_record",
  "message": "No record found"
}

Edit Address
POST/memberlocation/edit-location

Edit Address

Parameter Required Type Example Description
formatted_address no string Street 7, Denmark Location title
longitude no string 46
latitude no string 32
address no string Street 7, Denmark Location address
city no string Aarhus Location city
zipcode no integer 8000 Location zip code
state no string Copenhagen Location state
country no string Denmark Location Country

Example URI

POST /memberlocation/edit-location
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 129`) 

user_id

seao_locationid (optional, integer, `seao_locationid
string (required) Default: 129`) 

seao_locationid

Request  valid
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478
Body
{
    "formatted_address":"Nice"
    "country":"Denmark"
}
Response  204
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}

Edit Location

Edit Location Form
GET/memberlocation/edit-address

Edit Location form.

Returns the form & formvalues as response.form we get the location edit form.formvalues we get the value of current location.

Example URI

GET /memberlocation/edit-address
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 129`) 

user_id

seao_locationid (optional, integer, `seao_locationid
string (required) Default: 129`) 

seao_locationid

Request
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478
Response  200
HideShow
Headers
Accept: application/json
Body
{
  "form": [
    {
      "type": "Text",
      "name": "location",
      "label": "Location"
    },
    {
      "type": "Select",
      "name": "location_privacy",
      "label": "Privacy",
      "multiOptions": {
        "everyone": "Everyone",
        "registered": "Members",
        "friends": "Friends",
        "self": "Only Me"
      }
    },
    {
      "type": "Submit",
      "name": "submit",
      "label": "Submit"
    }
  ],
  "formValues": {
    "location": "Denmark",
    "location_privacy": "everyone"
  }
}
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}
Response  404
HideShow
Body
{
  "status_code": 404,
  "error": true,
  "error_code": "no_record",
  "message": "No record found"
}

Edit Location
POST/memberlocation/edit-address

Edit Location

Parameter Required Type Example Description
location yes string Street 7, Denmark Location title
location_privacy no string everyone

Example URI

POST /memberlocation/edit-address
URI Parameters
HideShow
user_id (required, integer, `user_id
string (required) Default: 129`) 

user_id

seao_locationid (optional, integer, `seao_locationid
string (required) Default: 129`) 

seao_locationid

Request  valid
HideShow
Headers
Accept: application/json
oauth_consumer_key: e6a5845684bf49df63d9eef489acfee1
oauth_consumer_secret: 42b9eef48e96c65f9ca29d07712d39fb
oauth_token: 276ed9327d0478c2606adea438f4fd15
oauth_secret: ffaff6754b5d4ca5f2fc4cc2a3a75478
Body
{
  "location": "Denmark",
  "location_privacy": "everyone"
}
Response  204
Response  401
HideShow
Body
{
  "status_code": 401,
  "error": true,
  "error_code": "unauthorized",
  "message": "User does not have access to this resource."
}

Generated by aglio on 07 Jul 2017