Title: Adding a element to a custom associative array
Last modified: September 1, 2016

---

# Adding a element to a custom associative array

 *  [nickb](https://wordpress.org/support/users/nickbuc/)
 * (@nickbuc)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/adding-a-element-to-a-custom-associative-array/)
 * Thanks a lot for the plugin!!!
 * I use a custom field in “User” to store a list of users. Using ACF I can store
   multiple “users” in the custom field, and GET the list of associative arrays (
   with all user fields) with the plugin.
    I can use PUT or POST to add the first
   user to an empty list. However, I have not found out how to add a user to an 
   existing list. I always overwrite the first one.
 * Any idea about what I should do?
 * Thanks a lot!
 * [https://wordpress.org/plugins/acf-to-rest-api/](https://wordpress.org/plugins/acf-to-rest-api/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [nickb](https://wordpress.org/support/users/nickbuc/)
 * (@nickbuc)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/adding-a-element-to-a-custom-associative-array/#post-7642561)
 * I have not found any simply way to add or delete one field in the array, so I
   guess I need to GET the full list of users, then add or delete one of them, then
   POST the full updated list back.
 * Is this my best option?
 * Thanks!
 *  Plugin Author [airesvsg](https://wordpress.org/support/users/airesvsg/)
 * (@airesvsg)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/adding-a-element-to-a-custom-associative-array/#post-8813666)
 * Hi [@nickbuc](https://wordpress.org/support/users/nickbuc/),
    please, use the
   filter **acf/rest_api/{type}/get_fields**.
 * How to use the filter:
    [https://github.com/airesvsg/acf-to-rest-api/issues/9#issuecomment-175110946](https://github.com/airesvsg/acf-to-rest-api/issues/9#issuecomment-175110946)
 * List with others filters:
    [https://github.com/airesvsg/acf-to-rest-api#filters](https://github.com/airesvsg/acf-to-rest-api#filters)
 * Follow link below with an example how to edit the data:
    [https://github.com/airesvsg/acf-to-rest-api-example](https://github.com/airesvsg/acf-to-rest-api-example)
 * Thanks

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Adding a element to a custom associative array’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/acf-to-rest-api_cc0001.svg)
 * [ACF to REST API](https://wordpress.org/plugins/acf-to-rest-api/)
 * [Support Threads](https://wordpress.org/support/plugin/acf-to-rest-api/)
 * [Active Topics](https://wordpress.org/support/plugin/acf-to-rest-api/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/acf-to-rest-api/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/acf-to-rest-api/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [airesvsg](https://wordpress.org/support/users/airesvsg/)
 * Last activity: [9 years, 3 months ago](https://wordpress.org/support/topic/adding-a-element-to-a-custom-associative-array/#post-8813666)
 * Status: not resolved