Updating macros to use a new field
We currently have a large, unknown number of macros using the ID for a field that was set up as an integer but should have been set up as a decimal. We've created the replacement to that field but can't roll out the change until we review all the macros referencing the field and updating to the new field.
This change means that any placeholder insert needs to be replaced and every action reconfigured.
How do you accomplish this with the API? As we are doing a lot of backend cleanup, it looks like this method will need to be reusable.
-
Hi Matthew,
You can list down all the macros you have by using List Macro endpoint, then do the necessary update by using Update Many Macro endpoint.
-
I need to replace a long text address field (street+city+state) with a set of segmented address fields (street, city, state). This will impact all macros using the long text, since it will be deprecated for the segmented fields, but I don't know which macros those are.
Does the macros API search functionality have the ability to loop through the macro actions object to find a value?
I'm trying to pull a JSON of macro data* where the long address field id placeholder is being used in either the comment_value, comment_value_html, or side_conversation actions (ie a "text contains..." query).
I can't find documentation related to the query format referenced in the dev documentation:
GET /api/v2/macros/search?query={query}
Is there a page in the documentation that provides a reference for the search?
*Hopefully I can just limit it to macro name, url, description, and comment_value, comment_value_html, or side_conversation actions.
-
Hi Matthew,
The macros API search functionality is not capable of looping through the macro actions object to find a value.
There are only a several number of parameters that can used to search for a Macro. See here.
Please sign in to leave a comment.
3 Comments