Lookup Table Services

This section is for rewriting the API documentation written by CCB. It should only include sections that are included in the API documentation, although additional examples, etc. may be appended to the documentation.
Post Reply
User avatar
ccbug_admin
Member
Posts: 106
Joined: Wed Oct 14, 2015 8:06 pm

Lookup Table Services

Post by ccbug_admin » Mon Oct 03, 2016 10:32 am

Each lookup table service has four actions once can execute with it: list, detail, update, or insert. One could perhaps associate them with CRUD (Create, Read, Update, Delete) like so:
  • Create = Insert
  • Read = List, Detail
  • Update = Update
  • Delete = Not Available
You always access these lookup tables using tablename_actionname, you'll never call tablename by itself. See below:
  • tablename_list (e.g. ability_list)
  • tablename_detail (e.g. ability_detail)
  • tablename_update (e.g. ability_update)
  • tablename_insert (e.g. ability_insert)
CCB Lookup Table Services include:
  • ability
  • activity
  • age_bracket
  • area
  • church_service
  • event_grouping
  • gift
  • group_grouping
  • group_type
  • how_joined_church
  • how_they_heard
  • meet_day
  • meet_time
  • membership_type
  • passion
  • reason_left_church
  • school
  • school_grade
  • significant_event
  • spiritual_maturity
  • style
  • transaction_grouping
  • udf_grp_pulldown_1 (or 2 or 3)
  • udf_ind_pulldown_1 (or 2 or 3 or 4 or 5 or 6)
  • udf_resource_pulldown_1
Example Usage
  • To Get A Single Record's Details:

    Code: Select all

    curl -u username:password -d "" "https://yourchurch.ccbchurch.com/api.php?srv=nameoftable_detail&nameoftable_id=1"
  • To Insert A Single Record Into A Lookup Table:

    Code: Select all

    curl -u username:password -d "" "https://yourchurch.ccbchurch.com/api.php?srv=nameoftable_insert&name=newRecord&order_by=3"
  • To List All of the Records in A Lookup Table:

    Code: Select all

    curl -u username:password -d "" "https://yourchurch.ccbchurch.com/api.php?srv=tablename_list"
  • To Update A Record In A Lookup Table:

    Code: Select all

    curl -u username:password -d "" "https://yourchurch.ccbchurch.com/api.php?srv=table_name_update&tablename_id=1&name=newName"

Post Reply