List Macros


                https://api.ocamba.com/v1/hood/macros
            

Returns a list of Macros currently available on Hood


Name
Description
fieldsstring
Fields parameter represents array of dimensions and measures. Dimensions are used to categorize, segment, and reveal the details of the data. Measures contain numeric, quantitative values that can be measured. At least one measure is required.


Example: fields=field1,field2,field3

pagestring
The page number indicates which set of items will be returned in the response. The format of request is "page=N,M" where 'N' (required) represents page number and 'M' (optional) is number of items per page.

Examples:
N=1, M=20 → returns page 1 with 20 items
N=2, M=20 → returns page 2 with 20 items (items 21-40)
N=3 → returns page 3. The number of objects returned depends on the resource settings.


Example: page=1,10

sortstring
Sorts the response by specified field(s) with the option to specify sorting order (ascending by default, add prefix "-" for descending).

Examples:
GET /VERSION/hood/RESOURCE_NAME?sort=name → sorts per name, ascending
GET /VERSION/hood/RESOURCE_NAME?sort=-id → sorts per id descending
GET /VERSION/hood/RESOURCE_NAME?sort=id,-name → sorts per id ascending, then name descending

See tips for the list of sortable fields.


Example: sort=-field1,field2

deprecatedinteger
Describes if a macro is deprecated or not.


Example: 1

200 - OK
Arrow
Name
Description
items[ macros ]
An array of all created items.
Macro
Name
Description
create_timestring
Timezone: GMT.


Example: 2021-10-29 12:47:00

deprecatedinteger
Describes if a macro is deprecated.


Example: 1

Possible values: 0 | 1

idstring
The ID of the macro, generated by Ocamba.


Example: 11

namestring
The name of the macro.


Example: OCMH_USER_ID

typestring
Describes the type of the macro.


Example: system

Possible values: system | dynamic

update_timestring
Timezone: GMT.


Example: 2021-10-30 14:27:26

totalinteger
A total number of items.


Example: 12
tip
1 Searchable fields are name and description.

2 Sortable fields are: name, create_time and update_time.

3 Filterable fields are: id, name, type, create_time and update_time.
200 Arrow
{
  "total": 12,
  "items": [
    {
      "id": "1",
      "name": "OCMH_USER_ID",
      "deprecated": 0,
      "type": "system",
      "create_time": "2024-03-11 08:37:25",
      "update_time": "2024-03-11 08:37:25"
    },
    {
      "id": "2",
      "name": "OCMH_USER_UNIX_DSUB",
      "deprecated": 0,
      "type": "system",
      "create_time": "2024-03-11 08:37:25",
      "update_time": "2024-03-11 10:47:16"
    },
    {
      "id": "3",
      "name": "OCMH_USER_COUNTRY_CODE",
      "deprecated": 0,
      "type": "system",
      "create_time": "2024-03-11 08:37:25",
      "update_time": "2024-03-11 08:37:25"
    }
  ]
}
{
  "total": 12,
  "items": [
    {
      "id": "11",
      "name": "OCMH_USER_ID",
      "deprecated": 1,
      "type": "system",
      "create_time": "2021-10-29 12:47:00",
      "update_time": "2021-10-30 14:27:26"
    }
  ]
}