Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Data store improvements [2.37-2.38]

The data store API has received numerous improvements to make it a fully-fledged data store and more useful to web apps and other clients. Video | DHIS2 documentation

Field filtering

Allows you to return only specific keys and values of entries in the data store using the fields parameter. Works similar to fields filtering in the metadata API. The filtering takes place at the namespace level and is useful when a client needs to list many entries with specific keys/values in a single query.

Paging

In query responses, paging is supported and enabled by default. You can specify paging explicitly with the page and pageSize parameters. Paging is useful to work with namespaces with high numbers of entries.

Entry filtering

Allows you to match and filter entries in a namespace based on a variety of operators, such as eq, lt, le, gt, ge, like, null, using the filter parameter. Works similar to object filtering in the metadata API. The filtering is useful when a client wants to list many entries which match one or many criteria.

Sorting

Allows you to sort entries in a namespace ascending or descending based on a specific key/value using the order parameter. This is useful when clients have specific requirements for sorting a list of entries.

Request logging in http header [2.38]

Clients of the API can now submit a value with the ‘X-Request-ID’ HTTP header which is included in all log statements. This is useful when looking at DHIS2 logs and trying to understand which client/app made a request, for example when debugging an issue which applies to a specific installation of an Android app on a phone. Docs

Personal (API) access tokens

You can now create personal API access tokens for your account. API access tokens are useful for authentication of software API clients such as integration services and web portals. When authenticating with an access token, a client will only get access to the API and not the user interface. Tokens can be restricted to specific HTTP methods (e.g. GET, POST) and IP addresses. There are to types of tokens, one for server-side clients and one for web browser-based clients. To create a token, navigate to the profile menu > Edit profile > Personal access tokens.

Video | API docs

  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.