← Back to team overview

dhis2-devs team mailing list archive

Re: Filtering fields on /api/metadata

 

Hi Mahendra

Field filtering has never worked on /api/metadata endpoint, it only
supports viewClasses.. I do want to rewrite that endpoint to support field
filtering, but its not something that can be done quickly (unless we hacked
it in)

You can however do something like this (I think this is close to what you
want)
/api/metadata?attributes=false&options=false

This will disable those types.

--
Morten

On Wed, Mar 18, 2015 at 1:40 PM, Mahendra Kariya <
mahendra.kariya@xxxxxxxxxxxxxxxx> wrote:

> Hi,
>
> We want all the fields from /api/metadata except a few.
> We tried
> http://localhost:8080/api/metaData?fields=:all,!attributes,!options
> expecting that the "attributes" and "options" fields will be filtered out.
> But that's not the case. Earlier this used to work.
>
> Has the API changed recently?
>
>
>
> Thanks,
> Mahendra.
>