Nomad
Namespace HTTP API
The /namespace endpoints are used to query for and interact with namespaces.
List Namespaces
This endpoint lists all namespaces.
| Method | Path | Produces |
|---|---|---|
GET | /v1/namespaces | application/json |
The table below shows this endpoint's support for blocking queries and required ACLs.
| Blocking Queries | ACL Required |
|---|---|
YES | namespace:*Any capability on the namespace authorizes the endpoint |
Parameters
prefix(string: "")- Specifies a string to filter namespaces on based on an index prefix. This is specified as a query string parameter.
Sample Request
$ curl \
https://localhost:4646/v1/namespaces
$ curl \
https://localhost:4646/v1/namespaces?prefix=prod
Sample Response
[
{
"Capabilities": null,
"CreateIndex": 1,
"Description": "Default shared namespace",
"Meta": null,
"ModifyIndex": 1,
"Name": "default",
"Quota": ""
},
{
"Capabilities": null,
"CreateIndex": 17,
"Description": "Development Staging Namespace",
"Meta": {
"type": "dev",
"contact": "[email protected]"
},
"ModifyIndex": 17,
"Name": "staging",
"Quota": ""
}
]
Read Namespace
This endpoint reads information about a specific namespace.
| Method | Path | Produces |
|---|---|---|
GET | /v1/namespace/:namespace | application/json |
The table below shows this endpoint's support for blocking queries and required ACLs.
| Blocking Queries | ACL Required |
|---|---|
YES | namespace:*Any capability on the namespace authorizes the endpoint |