官术网_书友最值得收藏!

  • Learning Couchbase
  • Henry Potsangbam
  • 163字
  • 2021-07-30 10:25:03

Couchbase administrative REST API

Another way to administrate Couchbase clusters is by using the REST API. It provides all the features we have discussed in the web console. In fact, the REST API is being used behind the scenes for most of the options displayed in the web console. You can perform all administrative functionalities using the REST API too.

You need some REST API tools to use this feature. In our case, we will use curl. It can be downloaded and installed from http://curl.haxx.se/download.html.

We will see an example as follows. You can refer the Couchbase documentation for comprehensive details on the REST API usages and syntax:

curl -u Administrator:root123 http://localhost:8091/pools/default

This command provides cluster details in a JSON document.

The REST API output

You can get information about a specific bucket that is LearningCouchbase using the following command:

curl -u Administrator:root123 http://localhost:8091/pools/default/buckets/LearningCouchbase

You need to pass the user ID and password credentials to connect to the cluster using the -u parameter.

主站蜘蛛池模板: 依安县| 汝州市| 阜新市| 股票| 准格尔旗| 黄石市| 太白县| 朔州市| 原平市| 保德县| 乌什县| 峨山| 河源市| 商丘市| 阜宁县| 寻甸| 利川市| 平顺县| 三穗县| 绍兴市| 南皮县| 阿合奇县| 乐清市| 依兰县| 石渠县| 宣恩县| 淳化县| 喀喇沁旗| 古丈县| 连山| 铁岭县| 辉县市| 伊宁市| 平顺县| 桦南县| 建阳市| 乌拉特前旗| 仲巴县| 隆尧县| 黑龙江省| 永康市|