Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am new to GeoServer and wonder how I can create OGC Services via Geoserver automatically. I have to publish my data (Shapefiles) with a Java program as OGC Services. How can I do that?

I checked out the source code of GeoServer, but I don't know how to package as right jar file to use.

share|improve this question
up vote 3 down vote accepted

If by OGC services you mean WMS and WFS then you could use GeoServers REST configuration API, which lets you create workspaces, stores, styles, upload shapefiles etc. You can see a list of operations here:

REST Configuration API Reference

GeoServer have examples of how to do this in cURL:

GeoServer cURL REST examples

I don't know much Java, but I am pretty sure you can convert the cURL examples to Java.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.