GeoServer Namespace
A namespace is a uniquely identifiable grouping of feature types. It is identified by a prefix and a URI.
Version: 1.0.0
BasePath:/geoserver/rest
All rights reserved
http://apache.org/licenses/LICENSE-2.0.html
Access
[ Jump to Models ]
Table of Contents
Up
delete /namespaces/{namespaceName}
Delete a namespace (deleteNamespace)
Path parameters
namespaceName (required)
Path Parameter — Name of the namespace
Responses
200
Success. Namespace deleted
403
Namespace or related Workspace is not empty (and recurse not true)
404
Namespace doesn't exist
405
Can't delete default namespace
(deleteNamespaces)
Responses
405
Not permitted
Up
get /namespaces/{namespaceName}
Retrieve a namespace (getNamespace)
Retrieves a single namespace definition. Use the "Accept:" header to specify format or append an extension to the endpoint (example "/namespaces/{namespace}.xml" for XML).
Path parameters
namespaceName (required)
Path Parameter — The name of the namespace to fetch, or "default" to get the default namespace.
Return type
Example data
Content-Type: application/xml
" topp http://www.openplans.org/topp "
Example data
Content-Type: application/json
"{ \"namespace\": { \"prefix\": \"topp\", \"uri\": \"http://www.openplans.org/topp\", \"featureTypes\": \"http://localhost:8080/geoserver/rest/workspaces/topp/featuretypes.json\" } }"
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the response header.
application/xml
application/json
text/html
Responses
200
OK
NamespaceResponse
Example data
Content-Type: application/xml
topp http://www.openplans.org/topp
Example data
Content-Type: application/json
{ "namespace": { "prefix": "topp", "uri": "http://www.openplans.org/topp", "featureTypes": "http://localhost:8080/geoserver/rest/workspaces/topp/featuretypes.json" } }
404
namespace does not exist
Get a list of namespaces (getNamespaces)
Displays a list of all namespaces on the server. Use the "Accept:" header to specify format or append an extension to the endpoint (example "/namespaces.xml" for XML)
Return type
Example data
Content-Type: application/xml
"\n \n topp\n \n \n \n it.geosolutions\n \n \n\n"
Example data
Content-Type: application/json
"{\n \"namespaces\": {\n \"namespace\": [\n {\n \"name\": \"topp\",\n \"href\": \"http://localhost:8080/geoserver/rest/namespaces/topp.json\"\n },\n {\n \"name\": \"it.geosolutions\",\n \"href\": \"http://localhost:8080/geoserver/rest/namespaces/it.geosolutions.json\"\n }\n ]\n }\n}\n"
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the response header.
text/html
application/json
application/xml
Responses
200
OK
NamespacesResponse
Example data
Content-Type: application/xml
topp
it.geosolutions
Example data
Content-Type: application/json
{
"namespaces": {
"namespace": [
{
"name": "topp",
"href": "http://localhost:8080/geoserver/rest/namespaces/topp.json"
},
{
"name": "it.geosolutions",
"href": "http://localhost:8080/geoserver/rest/namespaces/it.geosolutions.json"
}
]
}
}
401
Unauthorized
Up
post /namespaces/{namespaceName}
(postNamespace)
Responses
405
Forbidden to post to an existing namespace (use PUT)
Add a new namespace to GeoServer (postNamespaces)
Adds a new namespace to the server
Consumes
This API call consumes the following media types via the request header:
application/json
application/xml
Request body
Body Parameter — The layer group body information to upload.
Return type
String
Example data
Content-Type: application/json
""
Example data
Content-Type: application/xml
aeiou
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the response header.
text/html
application/json
application/xml
Responses
201
Created
String
401
Unable to add namespace as it already exists
Up
put /namespaces/{namespaceName}
Update a namespace (putNamespace)
Takes the body of the put and modifies the namespace from it.
Path parameters
namespaceName (required)
Path Parameter — Name of namespace, or "default" to set the default namespace using the namespace prefix in the body of the post.
Consumes
This API call consumes the following media types via the request header:
application/json
application/xml
Responses
200
Modified
404
Namespace not found
405
Forbidden to change the name of the namespace
(putNamespaces)
Responses
405
Not permitted
[ Jump to Methods ]
Table of Contents
Namespace
- Namespace
NamespaceResponse
- Namespace Response
NamespacesResponse
- Namespaces
prefix (optional)
String Name/prefix of the namespace
uri (optional)
String URI that identifies the namespace
prefix (optional)
uri (optional)
featureTypes (optional)
String URL to featureTypes associated with this namespace