Kartra Documentation TECHNICAL DOCUMENTATION

Section 26: Action: Retrieve all the custom fields in your account

Type Parameters Values
POST cmd* retrieve_custom_fields

* Required fields

Here is an example:

'actions' => [
    '0' => [
        'cmd' => 'retrieve_custom_fields'
    ]
]

Here are the results returned by the request:

Parameters Values
custom_fields String (JSON encoded array containing the details of all the custom fields in your account, empty array if no custom fields)

Example of the returned array:

"custom_fields": [
        {
            "field_id": "1",
            "field_identifier": "gender",
            "field_type": "radio_button",
	    "field_value":[
		{
		    "option_id":"1",
		    "option_value":"male",
		},
		{
		    "option_id":"2",
		    "option_value":"female",
		}
	    ]
        },
        {
            "field_id": "2",
            "field_identifier": "fruits",
            "field_type": "checkbox",
	    "field_value":[
		{
		    "option_id":"1",
		    "option_value":"apple",
		},
		{
		    "option_id":"2",
		    "option_value":"pear",
		}
	    ]
        },
        {
            "field_id": "3",
            "field_identifier": "field_3",
            "field_type": "input_field"
        },
        {
            "field_id": "4",
            "field_identifier": "field_4",
            "field_type": "drop_down"
	    "field_value":[
		{
		    "option_id":"1",
		    "option_value":"male",
		},
		{
		    "option_id":"2",
		    "option_value":"female",
		}
	    ]            
        },
        {
            "field_id": "5",
            "field_identifier": "field_5",
            "field_type": "text_area"
        }
]

© 2020 Kartra All Rights Reserved