Getting data out of DirectGov

Mashing up Direct GovOn Saturday at BarCampUKGovWeb I asked whether it was possible to use the data from DirectGov to direct website users to their local government services, without needing to send them via the pretty orange pages of local.direct.gov.uk.

Thanks for a tip-off from Paul Clarke, I got in touch with Andy Key from Hampshire who has helped out with a few pointers to some currently unofficial (but possibly soon-to-be-supported) ways of making use of Local Direct Gov data:

The answer is No, Yes, and Maybe.

Web services: not yet. This is something I've been asking for and the Local Directgov team are looking at doing. […]

What is possible now is simple link redirection. This involves linking to a Directgov URL and passing it the code number of the service you want, the code number for the interaction type you want (normally 8 for “finding information”) and the code number of the local authority whose service you want to access. The service codes are a subset of the standard Local Government Service List (LGSL); interaction codes are from the Local Government Interaction List (LGIL).

Here's an example:

Find information (LGIL code 8) about the Youth Opportunies Fund (LGSL code 1116) at Bristol City Council (authority code 558):
http://local.direct.gov.uk/LDGRedirect/index.jsp?LGSL=1116&LGIL=8&AgencyId=558&Type=Single

Find information (8) about volunteering opportunities for young people (629) in Nottinghamshire (239):
http://local.direct.gov.uk/LDGRedirect/index.jsp?LGSL=629&LGIL=8&AgencyId=239&Type=Single

Obviously this only works for services that are included in the Local Directgov service list, and for authorities in England and Wales. Local Directgov relies on the authority having provided a URL for the service in question. If a particular authority has failed to do so, the link defaults to the “Contact us” page of the authority's website.

This facility has a few obvious drawbacks:

  • The website user has to know which council area they're in.
  • You, the website owner, have to know what the code number is for that council.
  • It doesn't work well with services delivered by more than one tier of local authority (e.g. services provided by both county and district council in an area).

[…] LDG have their own numbering system for local authorities.

As it stands, then, the facility is quite usable for a council website where I only have to know the codes for a handful of authorities in my area – see http://www3.hants.gov.uk/redirect-district?lgsl=372 for instance – but not much good for a national website.

The alternative, for now, is to recreate the input form at http://local.direct.gov.uk/LDGRedirect/index.jsp?LGSL=1116&LGIL=8 on your own website. So you prompt the user for their postcode, then use that to send them to Directgov with the postcode already set – for example, like this: http://local.direct.gov.uk/LDGRedirect/LocationSearch.do?searchtype=1&LGSL=1116&LGIL=8&Style=&formsub=t&text=bs1

5 thoughts on “Getting data out of DirectGov”

  1. I agree with Harry Harold and I know that it will take much longer to create the website, but I think that you are trying to provide a great service to the youth of America and I applaud you for that.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.