CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Custom Data Metadata API
Pages: [1]

Author Topic: Custom Data Metadata API  (Read 1102 times)

outinsun

  • Guest
Custom Data Metadata API
August 17, 2009, 08:31:49 am
It appears that CiviCRM has an API for creating/delete custom groups and fields, but not for querying them. It would be great to be able to retrieve the details of existing custom group and field definitions. Does such a thing exist?

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Custom Data Metadata API
August 17, 2009, 09:58:04 am

not via the API. There are some internal functions that we use to retrive this information. You can potentially use those or package it and expose as an API. if you do the latter, please publish your code so others may benefit

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

outinsun

  • Guest
Re: Custom Data Metadata API
August 17, 2009, 11:58:19 am
Quote from: Donald Lobo on August 17, 2009, 09:58:04 am

not via the API. There are some internal functions that we use to retrive this information. You can potentially use those or package it and expose as an API. if you do the latter, please publish your code so others may benefit

lobo

Can you point me to the internal functions? We will happily make an API wrapper around them available to others.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Custom Data Metadata API
August 17, 2009, 01:21:21 pm

CRM/Core/BAO/CustomGroup.php, function getTree, function getGroupDetail

that code has not been revisited in a long long time. so its got quite a bit of legacy and is fairly complicated (IMO)

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Custom Data Metadata API

This forum was archived on 2017-11-26.